Jakub Kicinski | 4e16b6a | 2023-03-15 16:03:50 -0700 | [diff] [blame] | 1 | /* SPDX-License-Identifier: ((GPL-2.0 WITH Linux-syscall-note) OR BSD-3-Clause) */ |
Jakub Kicinski | d3d854f | 2023-02-01 11:24:17 +0100 | [diff] [blame] | 2 | /* Do not edit directly, auto-generated from: */ |
| 3 | /* Documentation/netlink/specs/netdev.yaml */ |
| 4 | /* YNL-GEN kernel header */ |
| 5 | |
| 6 | #ifndef _LINUX_NETDEV_GEN_H |
| 7 | #define _LINUX_NETDEV_GEN_H |
| 8 | |
| 9 | #include <net/netlink.h> |
| 10 | #include <net/genetlink.h> |
| 11 | |
Jakub Kicinski | 9b66ee0 | 2023-05-24 10:09:01 -0700 | [diff] [blame] | 12 | #include <uapi/linux/netdev.h> |
Mina Almasry | 170aafe | 2024-09-10 17:14:47 +0000 | [diff] [blame] | 13 | #include <linux/list.h> |
Jakub Kicinski | d3d854f | 2023-02-01 11:24:17 +0100 | [diff] [blame] | 14 | |
Jakub Kicinski | d49010a | 2023-11-26 15:07:38 -0800 | [diff] [blame] | 15 | /* Common nested types */ |
| 16 | extern const struct nla_policy netdev_page_pool_info_nl_policy[NETDEV_A_PAGE_POOL_IFINDEX + 1]; |
Mina Almasry | 3efd7ab | 2024-09-10 17:14:46 +0000 | [diff] [blame] | 17 | extern const struct nla_policy netdev_queue_id_nl_policy[NETDEV_A_QUEUE_TYPE + 1]; |
Jakub Kicinski | d49010a | 2023-11-26 15:07:38 -0800 | [diff] [blame] | 18 | |
Jakub Kicinski | d3d854f | 2023-02-01 11:24:17 +0100 | [diff] [blame] | 19 | int netdev_nl_dev_get_doit(struct sk_buff *skb, struct genl_info *info); |
| 20 | int netdev_nl_dev_get_dumpit(struct sk_buff *skb, struct netlink_callback *cb); |
Jakub Kicinski | 950ab53 | 2023-11-26 15:07:34 -0800 | [diff] [blame] | 21 | int netdev_nl_page_pool_get_doit(struct sk_buff *skb, struct genl_info *info); |
| 22 | int netdev_nl_page_pool_get_dumpit(struct sk_buff *skb, |
| 23 | struct netlink_callback *cb); |
Jakub Kicinski | d49010a | 2023-11-26 15:07:38 -0800 | [diff] [blame] | 24 | int netdev_nl_page_pool_stats_get_doit(struct sk_buff *skb, |
| 25 | struct genl_info *info); |
| 26 | int netdev_nl_page_pool_stats_get_dumpit(struct sk_buff *skb, |
| 27 | struct netlink_callback *cb); |
Amritha Nambiar | bc87795 | 2023-12-01 15:28:29 -0800 | [diff] [blame] | 28 | int netdev_nl_queue_get_doit(struct sk_buff *skb, struct genl_info *info); |
| 29 | int netdev_nl_queue_get_dumpit(struct sk_buff *skb, |
| 30 | struct netlink_callback *cb); |
Amritha Nambiar | ff99914 | 2023-12-01 15:28:51 -0800 | [diff] [blame] | 31 | int netdev_nl_napi_get_doit(struct sk_buff *skb, struct genl_info *info); |
| 32 | int netdev_nl_napi_get_dumpit(struct sk_buff *skb, struct netlink_callback *cb); |
Jakub Kicinski | ab63a23 | 2024-03-06 11:55:07 -0800 | [diff] [blame] | 33 | int netdev_nl_qstats_get_dumpit(struct sk_buff *skb, |
| 34 | struct netlink_callback *cb); |
Mina Almasry | 3efd7ab | 2024-09-10 17:14:46 +0000 | [diff] [blame] | 35 | int netdev_nl_bind_rx_doit(struct sk_buff *skb, struct genl_info *info); |
Jakub Kicinski | d3d854f | 2023-02-01 11:24:17 +0100 | [diff] [blame] | 36 | |
| 37 | enum { |
| 38 | NETDEV_NLGRP_MGMT, |
Jakub Kicinski | d2ef6aa | 2023-11-26 15:07:35 -0800 | [diff] [blame] | 39 | NETDEV_NLGRP_PAGE_POOL, |
Jakub Kicinski | d3d854f | 2023-02-01 11:24:17 +0100 | [diff] [blame] | 40 | }; |
| 41 | |
| 42 | extern struct genl_family netdev_nl_family; |
| 43 | |
Mina Almasry | 170aafe | 2024-09-10 17:14:47 +0000 | [diff] [blame] | 44 | void netdev_nl_sock_priv_init(struct list_head *priv); |
| 45 | void netdev_nl_sock_priv_destroy(struct list_head *priv); |
| 46 | |
Jakub Kicinski | d3d854f | 2023-02-01 11:24:17 +0100 | [diff] [blame] | 47 | #endif /* _LINUX_NETDEV_GEN_H */ |