]> git.baikalelectronics.ru Git - kernel.git/commit
net: export netdev_txq_to_tc to allow sch_mqprio to compile as module
authorHenrik Austad <henrik@austad.us>
Tue, 17 Oct 2017 10:10:10 +0000 (12:10 +0200)
committerDavid S. Miller <davem@davemloft.net>
Tue, 17 Oct 2017 16:00:08 +0000 (17:00 +0100)
commitc5802a139cef546fdf5491abb83b762ee18575a0
tree48693323b1c0a1f473b78bfc185620b73d9ee147
parentebc1035eb1d477f865c79f85a79f321e1ea3cf12
net: export netdev_txq_to_tc to allow sch_mqprio to compile as module

In commit 71800f0d9ae0 ("mqprio: Reserve last 32 classid values for HW
traffic classes and misc IDs") sch_mqprio started using netdev_txq_to_tc
to find the correct tc instead of dev->tc_to_txq[]

However, when mqprio is compiled as a module, it cannot resolve the
symbol, leading to this error:

     ERROR: "netdev_txq_to_tc" [net/sched/sch_mqprio.ko] undefined!

This adds an EXPORT_SYMBOL() since the other user in the kernel
(netif_set_xps_queue) is also EXPORT_SYMBOL() (and not _GPL) or in a
sysfs-callback.

Cc: Alexander Duyck <alexander.h.duyck@intel.com>
Cc: Jesus Sanchez-Palencia <jesus.sanchez-palencia@intel.com>
Cc: David S. Miller <davem@davemloft.net>
Signed-off-by: Henrik Austad <haustad@cisco.com>
Reviewed-by: Eric Dumazet <edumazet@google.com>
Acked-by: Alexander Duyck <alexander.h.duyck@intel.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/core/dev.c