Commit ef319d4f authored by David S. Miller's avatar David S. Miller

Merge branch 'net-sysfs-related-cleanups'

Stephen Hemminger says:

====================
net: sysfs related cleanups

Network sysfs infrastructure changes. Mostly related to using ro_after_init
to make function tables immutable.
====================
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parents 01d300c5 6648c65e
......@@ -2376,7 +2376,7 @@ static int init_vqs(struct virtnet_info *vi)
#ifdef CONFIG_SYSFS
static ssize_t mergeable_rx_buffer_size_show(struct netdev_rx_queue *queue,
struct rx_queue_attribute *attribute, char *buf)
char *buf)
{
struct virtnet_info *vi = netdev_priv(queue->dev);
unsigned int queue_index = get_netdev_rx_queue_index(queue);
......
......@@ -694,10 +694,9 @@ struct netdev_rx_queue {
*/
struct rx_queue_attribute {
struct attribute attr;
ssize_t (*show)(struct netdev_rx_queue *queue,
struct rx_queue_attribute *attr, char *buf);
ssize_t (*show)(struct netdev_rx_queue *queue, char *buf);
ssize_t (*store)(struct netdev_rx_queue *queue,
struct rx_queue_attribute *attr, const char *buf, size_t len);
const char *buf, size_t len);
};
#ifdef CONFIG_XPS
......@@ -4013,22 +4012,22 @@ static inline netdev_tx_t netdev_start_xmit(struct sk_buff *skb, struct net_devi
return rc;
}
int netdev_class_create_file_ns(struct class_attribute *class_attr,
int netdev_class_create_file_ns(const struct class_attribute *class_attr,
const void *ns);
void netdev_class_remove_file_ns(struct class_attribute *class_attr,
void netdev_class_remove_file_ns(const struct class_attribute *class_attr,
const void *ns);
static inline int netdev_class_create_file(struct class_attribute *class_attr)
static inline int netdev_class_create_file(const struct class_attribute *class_attr)
{
return netdev_class_create_file_ns(class_attr, NULL);
}
static inline void netdev_class_remove_file(struct class_attribute *class_attr)
static inline void netdev_class_remove_file(const struct class_attribute *class_attr)
{
netdev_class_remove_file_ns(class_attr, NULL);
}
extern struct kobj_ns_type_operations net_ns_type_operations;
extern const struct kobj_ns_type_operations net_ns_type_operations;
const char *netdev_drivername(const struct net_device *dev);
......
This diff is collapsed.
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment