diff options
author | Eric Brower <ebrower@nvidia.com> | 2012-01-19 16:44:25 -0800 |
---|---|---|
committer | Lokesh Pathak <lpathak@nvidia.com> | 2012-02-10 08:35:28 -0800 |
commit | c892abe5e61645f41dca11189a1b473f26e73c17 (patch) | |
tree | 1ad8560a7e347e2ef99da2e1def3c9e0f21751c2 /drivers/net/wireless/bcm4329/dhd_linux.c | |
parent | a4aa0557adc774bb364c3533986aef052dd58073 (diff) |
net: wireless: bcm4329: set reference to physical device
Set the parent field of the netdevice, which causes sysfs
to create a device subdirectory under the netdevice. Without
this subdirectory the user-space NetworkManager cannot manage
the network device.
Implemented using void * to maintain current driver implementation
of segregated OS-specific implementation.
Bug 929960
Signed-off-by: Eric Brower <ebrower@nvidia.com>
Reviewed-on: http://git-master/r/77889
(cherry picked from commit 5055320be16c36557e1ab9966ff7537500ca6d4d)
Change-Id: Ia5ea298c32823f896428905a779a734140306861
Signed-off-by: Pritesh Raithatha <praithatha@nvidia.com>
Reviewed-on: http://git-master/r/82720
Reviewed-by: Automatic_Commit_Validation_User
Reviewed-by: Varun Wadekar <vwadekar@nvidia.com>
Tested-by: Varun Wadekar <vwadekar@nvidia.com>
Diffstat (limited to 'drivers/net/wireless/bcm4329/dhd_linux.c')
-rw-r--r-- | drivers/net/wireless/bcm4329/dhd_linux.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/net/wireless/bcm4329/dhd_linux.c b/drivers/net/wireless/bcm4329/dhd_linux.c index 26bbb74ba7b7..2327ad5fa406 100644 --- a/drivers/net/wireless/bcm4329/dhd_linux.c +++ b/drivers/net/wireless/bcm4329/dhd_linux.c @@ -42,6 +42,7 @@ #include <linux/fs.h> #include <linux/inetdevice.h> #include <linux/mutex.h> +#include <linux/device.h> #include <asm/uaccess.h> #include <asm/unaligned.h> @@ -2054,7 +2055,7 @@ dhd_del_if(dhd_info_t *dhd, int ifidx) dhd_pub_t * -dhd_attach(osl_t *osh, struct dhd_bus *bus, uint bus_hdrlen) +dhd_attach(osl_t *osh, struct dhd_bus *bus, uint bus_hdrlen, void *dev) { dhd_info_t *dhd = NULL; struct net_device *net; @@ -2071,7 +2072,7 @@ dhd_attach(osl_t *osh, struct dhd_bus *bus, uint bus_hdrlen) DHD_ERROR(("%s: OOM - alloc_etherdev\n", __FUNCTION__)); goto fail; } - + SET_NETDEV_DEV(net, (struct device *)dev); /* Allocate primary dhd_info */ if (!(dhd = MALLOC(osh, sizeof(dhd_info_t)))) { DHD_ERROR(("%s: OOM - alloc dhd_info\n", __FUNCTION__)); |