Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 335861
b: refs/heads/master
c: 38c1a01
h: refs/heads/master
i:
  335859: d422729
v: v3
  • Loading branch information
Johannes Berg committed Nov 16, 2012
1 parent 27e4de5 commit 0d50afa
Show file tree
Hide file tree
Showing 2 changed files with 21 additions and 1 deletion.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: b78a4932f5fb11fadf41e69c606a33fa6787574c
refs/heads/master: 38c1a01cf10c6e4049b4ffbd4a6af655df2a46e1
20 changes: 20 additions & 0 deletions trunk/net/core/net-sysfs.c
Original file line number Diff line number Diff line change
Expand Up @@ -429,6 +429,17 @@ static struct attribute_group netstat_group = {
.name = "statistics",
.attrs = netstat_attrs,
};

#if IS_ENABLED(CONFIG_WIRELESS_EXT) || IS_ENABLED(CONFIG_CFG80211)
static struct attribute *wireless_attrs[] = {
NULL
};

static struct attribute_group wireless_group = {
.name = "wireless",
.attrs = wireless_attrs,
};
#endif
#endif /* CONFIG_SYSFS */

#ifdef CONFIG_RPS
Expand Down Expand Up @@ -1409,6 +1420,15 @@ int netdev_register_kobject(struct net_device *net)
groups++;

*groups++ = &netstat_group;

#if IS_ENABLED(CONFIG_WIRELESS_EXT) || IS_ENABLED(CONFIG_CFG80211)
if (net->ieee80211_ptr)
*groups++ = &wireless_group;
#if IS_ENABLED(CONFIG_WIRELESS_EXT)
else if (net->wireless_handlers)
*groups++ = &wireless_group;
#endif
#endif
#endif /* CONFIG_SYSFS */

error = device_add(dev);
Expand Down

0 comments on commit 0d50afa

Please sign in to comment.