ifb: fix building without CONFIG_NET_CLS_ACT

commit 7444d706be upstream.

The driver no longer depends on this option, but it fails to
build if it's disabled because the skb->tc_skip_classify is
hidden behind an #ifdef:

drivers/net/ifb.c:81:8: error: no member named 'tc_skip_classify' in 'struct sk_buff'
                skb->tc_skip_classify = 1;

Use the same #ifdef around the assignment.

Fixes: 046178e726 ("ifb: Depend on netfilter alternatively to tc")
Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
Arnd Bergmann 2021-10-29 13:30:51 +02:00 коммит произвёл Greg Kroah-Hartman
Родитель ea531d52fa
Коммит 013fa93c79
1 изменённых файлов: 2 добавлений и 0 удалений

Просмотреть файл

@ -76,7 +76,9 @@ static void ifb_ri_tasklet(struct tasklet_struct *t)
while ((skb = __skb_dequeue(&txp->tq)) != NULL) {
skb->redirected = 0;
#ifdef CONFIG_NET_CLS_ACT
skb->tc_skip_classify = 1;
#endif
u64_stats_update_begin(&txp->tsync);
txp->tx_packets++;