diff options
author | Jiri Pirko <jiri@mellanox.com> | 2017-11-03 06:46:25 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2017-11-03 08:57:24 -0400 |
commit | 46209401f8f6116bd0b2c2d14a63958e83ffca0b (patch) | |
tree | 54915d3a3f2af715f1681da274e3a98f6198e71b /include/linux/netdevice.h | |
parent | c7eb7d7230509ec862d4144f7a831f995bc5d028 (diff) |
net: core: introduce mini_Qdisc and eliminate usage of tp->q for clsact fastpath
In sch_handle_egress and sch_handle_ingress tp->q is used only in order
to update stats. So stats and filter list are the only things that are
needed in clsact qdisc fastpath processing. Introduce new mini_Qdisc
struct to hold those items. Also, introduce a helper to swap the
mini_Qdisc structures in case filter list head changes.
This removes need for tp->q usage without added overhead.
Signed-off-by: Jiri Pirko <jiri@mellanox.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux/netdevice.h')
-rw-r--r-- | include/linux/netdevice.h | 9 |
1 files changed, 6 insertions, 3 deletions
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index 5e02f79b2110..7de7656550c2 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h | |||
@@ -1559,6 +1559,8 @@ enum netdev_priv_flags { | |||
1559 | * | 1559 | * |
1560 | * @rx_handler: handler for received packets | 1560 | * @rx_handler: handler for received packets |
1561 | * @rx_handler_data: XXX: need comments on this one | 1561 | * @rx_handler_data: XXX: need comments on this one |
1562 | * @miniq_ingress: ingress/clsact qdisc specific data for | ||
1563 | * ingress processing | ||
1562 | * @ingress_queue: XXX: need comments on this one | 1564 | * @ingress_queue: XXX: need comments on this one |
1563 | * @broadcast: hw bcast address | 1565 | * @broadcast: hw bcast address |
1564 | * | 1566 | * |
@@ -1576,7 +1578,8 @@ enum netdev_priv_flags { | |||
1576 | * @tx_global_lock: XXX: need comments on this one | 1578 | * @tx_global_lock: XXX: need comments on this one |
1577 | * | 1579 | * |
1578 | * @xps_maps: XXX: need comments on this one | 1580 | * @xps_maps: XXX: need comments on this one |
1579 | * | 1581 | * @miniq_egress: clsact qdisc specific data for |
1582 | * egress processing | ||
1580 | * @watchdog_timeo: Represents the timeout that is used by | 1583 | * @watchdog_timeo: Represents the timeout that is used by |
1581 | * the watchdog (see dev_watchdog()) | 1584 | * the watchdog (see dev_watchdog()) |
1582 | * @watchdog_timer: List of timers | 1585 | * @watchdog_timer: List of timers |
@@ -1795,7 +1798,7 @@ struct net_device { | |||
1795 | void __rcu *rx_handler_data; | 1798 | void __rcu *rx_handler_data; |
1796 | 1799 | ||
1797 | #ifdef CONFIG_NET_CLS_ACT | 1800 | #ifdef CONFIG_NET_CLS_ACT |
1798 | struct tcf_proto __rcu *ingress_cl_list; | 1801 | struct mini_Qdisc __rcu *miniq_ingress; |
1799 | #endif | 1802 | #endif |
1800 | struct netdev_queue __rcu *ingress_queue; | 1803 | struct netdev_queue __rcu *ingress_queue; |
1801 | #ifdef CONFIG_NETFILTER_INGRESS | 1804 | #ifdef CONFIG_NETFILTER_INGRESS |
@@ -1826,7 +1829,7 @@ struct net_device { | |||
1826 | struct xps_dev_maps __rcu *xps_maps; | 1829 | struct xps_dev_maps __rcu *xps_maps; |
1827 | #endif | 1830 | #endif |
1828 | #ifdef CONFIG_NET_CLS_ACT | 1831 | #ifdef CONFIG_NET_CLS_ACT |
1829 | struct tcf_proto __rcu *egress_cl_list; | 1832 | struct mini_Qdisc __rcu *miniq_egress; |
1830 | #endif | 1833 | #endif |
1831 | 1834 | ||
1832 | /* These may be needed for future network-power-down code. */ | 1835 | /* These may be needed for future network-power-down code. */ |