diff options
author | Magnus Karlsson <magnus.karlsson@intel.com> | 2018-10-01 08:51:33 -0400 |
---|---|---|
committer | Daniel Borkmann <daniel@iogearbox.net> | 2018-10-05 03:31:00 -0400 |
commit | 661b8d1b0e3a745e25f05adef2ebd00d830eeea7 (patch) | |
tree | 97bad9994df284cd9ef1ae1fec8e29336632765a | |
parent | 7ccc4f1887518a392752ad44c014fd6e1f526da7 (diff) |
net: add umem reference in netdev{_rx}_queue
These references to the umem will be used to store information
on what kind of AF_XDP umem that is bound to a queue id, if any.
Signed-off-by: Magnus Karlsson <magnus.karlsson@intel.com>
Signed-off-by: Daniel Borkmann <daniel@iogearbox.net>
-rw-r--r-- | include/linux/netdevice.h | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/netdevice.h b/include/linux/netdevice.h index 1cbbf77a685f..8318f79586c2 100644 --- a/include/linux/netdevice.h +++ b/include/linux/netdevice.h | |||
@@ -609,6 +609,9 @@ struct netdev_queue { | |||
609 | 609 | ||
610 | /* Subordinate device that the queue has been assigned to */ | 610 | /* Subordinate device that the queue has been assigned to */ |
611 | struct net_device *sb_dev; | 611 | struct net_device *sb_dev; |
612 | #ifdef CONFIG_XDP_SOCKETS | ||
613 | struct xdp_umem *umem; | ||
614 | #endif | ||
612 | /* | 615 | /* |
613 | * write-mostly part | 616 | * write-mostly part |
614 | */ | 617 | */ |
@@ -738,6 +741,9 @@ struct netdev_rx_queue { | |||
738 | struct kobject kobj; | 741 | struct kobject kobj; |
739 | struct net_device *dev; | 742 | struct net_device *dev; |
740 | struct xdp_rxq_info xdp_rxq; | 743 | struct xdp_rxq_info xdp_rxq; |
744 | #ifdef CONFIG_XDP_SOCKETS | ||
745 | struct xdp_umem *umem; | ||
746 | #endif | ||
741 | } ____cacheline_aligned_in_smp; | 747 | } ____cacheline_aligned_in_smp; |
742 | 748 | ||
743 | /* | 749 | /* |