]> pilppa.com Git - linux-2.6-omap-h63xx.git/commit
staging-p80211: Kill directly reference of netdev->priv
authorWang Chen <wangchen@cn.fujitsu.com>
Sun, 7 Dec 2008 07:58:37 +0000 (23:58 -0800)
committerDavid S. Miller <davem@davemloft.net>
Sun, 7 Dec 2008 07:58:37 +0000 (23:58 -0800)
commit979123d5343b4fdcd4c682745b8a0be9b8fac248
tree64cb88ca96912ce9f9fd21ecf51a3a100fb9ccf3
parentad660e2f97e7dc9d0f5627456b37e64bde714a5e
staging-p80211: Kill directly reference of netdev->priv

In this driver, netdev's private data is wlandevice_t.  And the
wlandev(type of wlandevice_t) is exist before netdev be allocated.  So
use netdev->ml_priv to point to the private data.

I am not sure whether I should consider the kernel version older than
2.3.38.  Because in those kernels, netdevice_t is "structure dev"
instead of "structure net_device" and of course "dev->ml_priv" will
cause compile error.  But before my patch, in function wlan_setup(),
there is a ether_setup(net_device) which already broke kernels which
older than 2.3.38.

Signed-off-by: Wang Chen <wangchen@cn.fujitsu.com>
Acked-by: Greg Kroah-Hartman <gregkh@suse.de>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/staging/wlan-ng/p80211netdev.c
drivers/staging/wlan-ng/p80211wext.c