rtnetlink.h (9e9fd65d1fa51d919d54d731be0e66492b5b6c5a) rtnetlink.h (d40156aa5ecbd51fed932ed4813df82b56e5ff4d)
1#ifndef __NET_RTNETLINK_H
2#define __NET_RTNETLINK_H
3
4#include <linux/rtnetlink.h>
5#include <net/netlink.h>
6
7typedef int (*rtnl_doit_func)(struct sk_buff *, struct nlmsghdr *, void *);
8typedef int (*rtnl_dumpit_func)(struct sk_buff *, struct netlink_callback *);

--- 30 unchanged lines hidden (view full) ---

39 * @changelink: Function for changing parameters of an existing device
40 * @dellink: Function to remove a device
41 * @get_size: Function to calculate required room for dumping device
42 * specific netlink attributes
43 * @fill_info: Function to dump device specific netlink attributes
44 * @get_xstats_size: Function to calculate required room for dumping device
45 * specific statistics
46 * @fill_xstats: Function to dump device specific statistics
1#ifndef __NET_RTNETLINK_H
2#define __NET_RTNETLINK_H
3
4#include <linux/rtnetlink.h>
5#include <net/netlink.h>
6
7typedef int (*rtnl_doit_func)(struct sk_buff *, struct nlmsghdr *, void *);
8typedef int (*rtnl_dumpit_func)(struct sk_buff *, struct netlink_callback *);

--- 30 unchanged lines hidden (view full) ---

39 * @changelink: Function for changing parameters of an existing device
40 * @dellink: Function to remove a device
41 * @get_size: Function to calculate required room for dumping device
42 * specific netlink attributes
43 * @fill_info: Function to dump device specific netlink attributes
44 * @get_xstats_size: Function to calculate required room for dumping device
45 * specific statistics
46 * @fill_xstats: Function to dump device specific statistics
47 * @get_tx_queues: Function to determine number of transmit queues to create when
48 * creating a new device.
47 * @get_num_tx_queues: Function to determine number of transmit queues
48 * to create when creating a new device.
49 * @get_num_rx_queues: Function to determine number of receive queues
50 * to create when creating a new device.
49 */
50struct rtnl_link_ops {
51 struct list_head list;
52
53 const char *kind;
54
55 size_t priv_size;
56 void (*setup)(struct net_device *dev);

--- 15 unchanged lines hidden (view full) ---

72
73 size_t (*get_size)(const struct net_device *dev);
74 int (*fill_info)(struct sk_buff *skb,
75 const struct net_device *dev);
76
77 size_t (*get_xstats_size)(const struct net_device *dev);
78 int (*fill_xstats)(struct sk_buff *skb,
79 const struct net_device *dev);
51 */
52struct rtnl_link_ops {
53 struct list_head list;
54
55 const char *kind;
56
57 size_t priv_size;
58 void (*setup)(struct net_device *dev);

--- 15 unchanged lines hidden (view full) ---

74
75 size_t (*get_size)(const struct net_device *dev);
76 int (*fill_info)(struct sk_buff *skb,
77 const struct net_device *dev);
78
79 size_t (*get_xstats_size)(const struct net_device *dev);
80 int (*fill_xstats)(struct sk_buff *skb,
81 const struct net_device *dev);
80 int (*get_tx_queues)(struct net *net,
81 struct nlattr *tb[]);
82 unsigned int (*get_num_tx_queues)(void);
83 unsigned int (*get_num_rx_queues)(void);
82};
83
84extern int __rtnl_link_register(struct rtnl_link_ops *ops);
85extern void __rtnl_link_unregister(struct rtnl_link_ops *ops);
86
87extern int rtnl_link_register(struct rtnl_link_ops *ops);
88extern void rtnl_link_unregister(struct rtnl_link_ops *ops);
89

--- 45 unchanged lines hidden ---
84};
85
86extern int __rtnl_link_register(struct rtnl_link_ops *ops);
87extern void __rtnl_link_unregister(struct rtnl_link_ops *ops);
88
89extern int rtnl_link_register(struct rtnl_link_ops *ops);
90extern void rtnl_link_unregister(struct rtnl_link_ops *ops);
91

--- 45 unchanged lines hidden ---