aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAndy Green <andy@openmoko.com>2009-01-27 14:39:01 +0000
committerAndy Green <agreen@octopus.localdomain>2009-01-27 14:39:01 +0000
commitd5119bd8f7a606c9e05b022a703b9df7dcc14730 (patch)
tree0ecb9d4fd9149adae186d058ca41751a2505aae2
parent4d91e0b5eb559594e4201e60b3cf4eb4c6127859 (diff)
tracking-2.6.29-rc2-ar6001-net-device-priv-gone.patch
Signed-off-by: Andy Green <andy@openmoko.com>
-rw-r--r--drivers/ar6000/ar6000/ar6000_drv.c16
-rw-r--r--drivers/ar6000/ar6000/ioctl.c74
-rw-r--r--drivers/ar6000/ar6000/wireless_ext.c48
3 files changed, 69 insertions, 69 deletions
diff --git a/drivers/ar6000/ar6000/ar6000_drv.c b/drivers/ar6000/ar6000/ar6000_drv.c
index 06042367379..816557641de 100644
--- a/drivers/ar6000/ar6000/ar6000_drv.c
+++ b/drivers/ar6000/ar6000/ar6000_drv.c
@@ -736,14 +736,14 @@ ar6000_avail_ev(HTC_HANDLE HTCHandle)
ether_setup(dev);
- if (dev->priv == NULL) {
+ if (netdev_priv(dev) == NULL) {
printk(KERN_CRIT "ar6000_available: Could not allocate memory\n");
return;
}
- A_MEMZERO(dev->priv, sizeof(AR_SOFTC_T));
+ A_MEMZERO(netdev_priv(dev), sizeof(AR_SOFTC_T));
- ar = (AR_SOFTC_T *)dev->priv;
+ ar = (AR_SOFTC_T *)netdev_priv(dev);
ar->arNetDev = dev;
ar->arHtcTarget = HTCHandle;
ar->arHifDevice = HTCGetHifDevice(HTCHandle);
@@ -1067,7 +1067,7 @@ ar6000_destroy(struct net_device *dev, unsigned int unregister)
static void ar6000_detect_error(unsigned long ptr)
{
struct net_device *dev = (struct net_device *)ptr;
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_TARGET_ERROR_REPORT_EVENT errEvent;
AR6000_SPIN_LOCK(&ar->arLock, 0);
@@ -1472,7 +1472,7 @@ ar6000_channelList_rx(void *devt, A_INT8 numChan, A_UINT16 *chanList)
A_UINT8
ar6000_ibss_map_epid(struct sk_buff *skb, struct net_device *dev, A_UINT32 * mapNo)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
A_UINT8 *datap;
ATH_MAC_HDR *macHdr;
A_UINT32 i, eptMap;
@@ -1543,7 +1543,7 @@ static void ar6000_dump_skb(struct sk_buff *skb)
static int
ar6000_data_tx(struct sk_buff *skb, struct net_device *dev)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_PRI_STREAM_ID streamID = WMI_NOT_MAPPED;
A_UINT32 mapNo = 0;
int len;
@@ -2091,14 +2091,14 @@ ar6000_rx_refill(void *Context, HTC_ENDPOINT_ID Endpoint)
static struct net_device_stats *
ar6000_get_stats(struct net_device *dev)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
return &ar->arNetStats;
}
static struct iw_statistics *
ar6000_get_iwstats(struct net_device * dev)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
TARGET_STATS *pStats = &ar->arTargetStats;
struct iw_statistics * pIwStats = &ar->arIwStats;
diff --git a/drivers/ar6000/ar6000/ioctl.c b/drivers/ar6000/ar6000/ioctl.c
index eb712b4ffc9..0b6e91ad09e 100644
--- a/drivers/ar6000/ar6000/ioctl.c
+++ b/drivers/ar6000/ar6000/ioctl.c
@@ -31,7 +31,7 @@ extern int bypasswmi;
static int
ar6000_ioctl_get_roam_tbl(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
if (ar->arWmiReady == FALSE) {
return -EIO;
@@ -47,7 +47,7 @@ ar6000_ioctl_get_roam_tbl(struct net_device *dev, struct ifreq *rq)
static int
ar6000_ioctl_get_roam_data(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
if (ar->arWmiReady == FALSE) {
return -EIO;
@@ -66,7 +66,7 @@ ar6000_ioctl_get_roam_data(struct net_device *dev, struct ifreq *rq)
static int
ar6000_ioctl_set_roam_ctrl(struct net_device *dev, char *userdata)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_SET_ROAM_CTRL_CMD cmd;
A_UINT8 size = sizeof(cmd);
@@ -99,7 +99,7 @@ ar6000_ioctl_set_roam_ctrl(struct net_device *dev, char *userdata)
static int
ar6000_ioctl_set_powersave_timers(struct net_device *dev, char *userdata)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_POWERSAVE_TIMERS_POLICY_CMD cmd;
A_UINT8 size = sizeof(cmd);
@@ -125,7 +125,7 @@ ar6000_ioctl_set_powersave_timers(struct net_device *dev, char *userdata)
static int
ar6000_ioctl_set_wmm(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_SET_WMM_CMD cmd;
A_STATUS ret;
@@ -166,7 +166,7 @@ ar6000_ioctl_set_wmm(struct net_device *dev, struct ifreq *rq)
static int
ar6000_ioctl_set_txop(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_SET_WMM_TXOP_CMD cmd;
A_STATUS ret;
@@ -201,7 +201,7 @@ ar6000_ioctl_set_txop(struct net_device *dev, struct ifreq *rq)
static int
ar6000_ioctl_get_rd(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
A_STATUS ret = 0;
if ((dev->flags & IFF_UP) != IFF_UP || ar->arWmiReady == FALSE) {
@@ -220,7 +220,7 @@ ar6000_ioctl_get_rd(struct net_device *dev, struct ifreq *rq)
static int
ar6000_ioctl_get_power_mode(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_POWER_MODE_CMD power_mode;
int ret = 0;
@@ -240,7 +240,7 @@ ar6000_ioctl_get_power_mode(struct net_device *dev, struct ifreq *rq)
static int
ar6000_ioctl_set_channelParams(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_CHANNEL_PARAMS_CMD cmd, *cmdp;
int ret = 0;
@@ -291,7 +291,7 @@ static int
ar6000_ioctl_set_snr_threshold(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_SNR_THRESHOLD_PARAMS_CMD cmd;
int ret = 0;
@@ -323,7 +323,7 @@ ar6000_ioctl_set_rssi_threshold(struct net_device *dev, struct ifreq *rq)
thold2.rssi = tmpThold.rssi; \
} while (0)
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_RSSI_THRESHOLD_PARAMS_CMD cmd;
USER_RSSI_PARAMS rssiParams;
A_INT32 i, j;
@@ -393,7 +393,7 @@ static int
ar6000_ioctl_set_lq_threshold(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_LQ_THRESHOLD_PARAMS_CMD cmd;
int ret = 0;
@@ -416,7 +416,7 @@ ar6000_ioctl_set_lq_threshold(struct net_device *dev, struct ifreq *rq)
static int
ar6000_ioctl_set_probedSsid(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_PROBED_SSID_CMD cmd;
int ret = 0;
@@ -440,7 +440,7 @@ ar6000_ioctl_set_probedSsid(struct net_device *dev, struct ifreq *rq)
static int
ar6000_ioctl_set_badAp(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_ADD_BAD_AP_CMD cmd;
int ret = 0;
@@ -476,7 +476,7 @@ ar6000_ioctl_set_badAp(struct net_device *dev, struct ifreq *rq)
static int
ar6000_ioctl_create_qos(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_CREATE_PSTREAM_CMD cmd;
A_STATUS ret;
@@ -509,7 +509,7 @@ ar6000_ioctl_create_qos(struct net_device *dev, struct ifreq *rq)
static int
ar6000_ioctl_delete_qos(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_DELETE_PSTREAM_CMD cmd;
int ret = 0;
@@ -539,7 +539,7 @@ ar6000_ioctl_delete_qos(struct net_device *dev, struct ifreq *rq)
static int
ar6000_ioctl_get_qos_queue(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
struct ar6000_queuereq qreq;
int ret = 0;
@@ -567,7 +567,7 @@ static A_STATUS
ar6000_ioctl_tcmd_get_rx_report(struct net_device *dev,
struct ifreq *rq, A_UINT8 *data, A_UINT32 len)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
A_UINT32 buf[2];
int ret = 0;
@@ -618,7 +618,7 @@ ar6000_tcmd_rx_report_event(void *devt, A_UINT8 * results, int len)
static int
ar6000_ioctl_set_error_report_bitmask(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_TARGET_ERROR_REPORT_BITMASK cmd;
int ret = 0;
@@ -638,7 +638,7 @@ ar6000_ioctl_set_error_report_bitmask(struct net_device *dev, struct ifreq *rq)
static int
ar6000_clear_target_stats(struct net_device *dev)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
TARGET_STATS *pStats = &ar->arTargetStats;
int ret = 0;
@@ -654,7 +654,7 @@ ar6000_clear_target_stats(struct net_device *dev)
static int
ar6000_ioctl_get_target_stats(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
TARGET_STATS_CMD cmd;
TARGET_STATS *pStats = &ar->arTargetStats;
int ret = 0;
@@ -698,7 +698,7 @@ ar6000_ioctl_get_target_stats(struct net_device *dev, struct ifreq *rq)
static int
ar6000_ioctl_set_access_params(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_SET_ACCESS_PARAMS_CMD cmd;
int ret = 0;
@@ -724,7 +724,7 @@ ar6000_ioctl_set_access_params(struct net_device *dev, struct ifreq *rq)
static int
ar6000_ioctl_set_disconnect_timeout(struct net_device *dev, struct ifreq *rq)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_DISC_TIMEOUT_CMD cmd;
int ret = 0;
@@ -749,7 +749,7 @@ ar6000_ioctl_set_disconnect_timeout(struct net_device *dev, struct ifreq *rq)
static int
ar6000_xioctl_set_voice_pkt_size(struct net_device *dev, char * userdata)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_SET_VOICE_PKT_SIZE_CMD cmd;
int ret = 0;
@@ -775,7 +775,7 @@ ar6000_xioctl_set_voice_pkt_size(struct net_device *dev, char * userdata)
static int
ar6000_xioctl_set_max_sp_len(struct net_device *dev, char * userdata)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_SET_MAX_SP_LEN_CMD cmd;
int ret = 0;
@@ -801,7 +801,7 @@ ar6000_xioctl_set_max_sp_len(struct net_device *dev, char * userdata)
static int
ar6000_xioctl_set_bt_status_cmd(struct net_device *dev, char * userdata)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_SET_BT_STATUS_CMD cmd;
int ret = 0;
@@ -826,7 +826,7 @@ ar6000_xioctl_set_bt_status_cmd(struct net_device *dev, char * userdata)
static int
ar6000_xioctl_set_bt_params_cmd(struct net_device *dev, char * userdata)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_SET_BT_PARAMS_CMD cmd;
int ret = 0;
@@ -911,7 +911,7 @@ ar6000_gpio_output_set(struct net_device *dev,
A_UINT32 enable_mask,
A_UINT32 disable_mask)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
gpio_ack_received = FALSE;
return wmi_gpio_output_set(ar->arWmi,
@@ -921,7 +921,7 @@ ar6000_gpio_output_set(struct net_device *dev,
static A_STATUS
ar6000_gpio_input_get(struct net_device *dev)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
*((volatile A_BOOL *)&gpio_data_available) = FALSE;
return wmi_gpio_input_get(ar->arWmi);
@@ -932,7 +932,7 @@ ar6000_gpio_register_set(struct net_device *dev,
A_UINT32 gpioreg_id,
A_UINT32 value)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
gpio_ack_received = FALSE;
return wmi_gpio_register_set(ar->arWmi, gpioreg_id, value);
@@ -942,7 +942,7 @@ static A_STATUS
ar6000_gpio_register_get(struct net_device *dev,
A_UINT32 gpioreg_id)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
*((volatile A_BOOL *)&gpio_data_available) = FALSE;
return wmi_gpio_register_get(ar->arWmi, gpioreg_id);
@@ -952,7 +952,7 @@ static A_STATUS
ar6000_gpio_intr_ack(struct net_device *dev,
A_UINT32 ack_mask)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
gpio_intr_available = FALSE;
return wmi_gpio_intr_ack(ar->arWmi, ack_mask);
@@ -961,7 +961,7 @@ ar6000_gpio_intr_ack(struct net_device *dev,
int ar6000_ioctl(struct net_device *dev, struct ifreq *rq, int cmd)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
HIF_DEVICE *hifDevice = ar->arHifDevice;
int ret, param, param2;
unsigned int address = 0;
@@ -1827,7 +1827,7 @@ int ar6000_ioctl(struct net_device *dev, struct ifreq *rq, int cmd)
case AR6000_XIOCTL_SET_OPT_MODE:
{
WMI_SET_OPT_MODE_CMD optModeCmd;
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
if (ar->arWmiReady == FALSE) {
ret = -EIO;
@@ -1917,7 +1917,7 @@ int ar6000_ioctl(struct net_device *dev, struct ifreq *rq, int cmd)
}
case IEEE80211_IOCTL_SETAUTHALG:
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
struct ieee80211req_authalg req;
if (ar->arWmiReady == FALSE) {
@@ -2068,7 +2068,7 @@ int ar6000_ioctl(struct net_device *dev, struct ifreq *rq, int cmd)
case AR6000_XIOCTL_WMI_GETFIXRATES:
{
WMI_FIX_RATES_CMD getFixRatesCmd;
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
int ret = 0;
if (ar->arWmiReady == FALSE) {
@@ -2180,7 +2180,7 @@ int ar6000_ioctl(struct net_device *dev, struct ifreq *rq, int cmd)
}
case AR6000_XIOCTL_WMI_GET_KEEPALIVE:
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
WMI_GET_KEEPALIVE_CMD getKeepAlive;
int ret = 0;
if (ar->arWmiReady == FALSE) {
diff --git a/drivers/ar6000/ar6000/wireless_ext.c b/drivers/ar6000/ar6000/wireless_ext.c
index da82ad0c02a..d9a592038e6 100644
--- a/drivers/ar6000/ar6000/wireless_ext.c
+++ b/drivers/ar6000/ar6000/wireless_ext.c
@@ -208,7 +208,7 @@ ar6000_ioctl_giwscan(struct net_device *dev,
struct iw_request_info *info,
struct iw_point *data, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
struct ar_giwscan_param param;
int i;
@@ -256,7 +256,7 @@ ar6000_ioctl_siwessid(struct net_device *dev,
struct iw_request_info *info,
struct iw_point *data, char *ssid)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
A_STATUS status;
A_UINT8 arNetworkType;
@@ -434,7 +434,7 @@ ar6000_ioctl_giwessid(struct net_device *dev,
struct iw_request_info *info,
struct iw_point *data, char *essid)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
if (ar->arWlanState == WLAN_DISABLED) {
return -EIO;
@@ -482,7 +482,7 @@ int
ar6000_ioctl_setmlme(struct net_device *dev, struct iw_request_info *info,
void *w, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
struct ieee80211req_mlme *mlme = (struct ieee80211req_mlme *)extra;
if ((ar->arWmiReady == FALSE) || (ar->arConnected != TRUE))
@@ -525,7 +525,7 @@ int
ar6000_ioctl_setauthalg(struct net_device *dev, struct iw_request_info *info,
void *w, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
struct ieee80211req_authalg *req = (struct ieee80211req_authalg *)extra;
int ret = 0;
@@ -550,7 +550,7 @@ static int
ar6000_ioctl_addpmkid(struct net_device *dev, struct iw_request_info *info,
void *w, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
struct ieee80211req_addpmkid *req = (struct ieee80211req_addpmkid *)extra;
A_STATUS status;
@@ -581,7 +581,7 @@ ar6000_ioctl_siwrate(struct net_device *dev,
struct iw_request_info *info,
struct iw_param *rrq, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
A_UINT32 kbps;
if (rrq->fixed) {
@@ -612,7 +612,7 @@ ar6000_ioctl_giwrate(struct net_device *dev,
struct iw_request_info *info,
struct iw_param *rrq, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
int ret = 0;
if (down_interruptible(&ar->arSem)) {
@@ -654,7 +654,7 @@ ar6000_ioctl_siwtxpow(struct net_device *dev,
struct iw_request_info *info,
struct iw_param *rrq, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
A_UINT8 dbM;
if (ar->arWlanState == WLAN_DISABLED) {
@@ -699,7 +699,7 @@ ar6000_ioctl_giwtxpow(struct net_device *dev,
struct iw_request_info *info,
struct iw_param *rrq, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
int ret = 0;
if (ar->arWlanState == WLAN_DISABLED) {
@@ -755,7 +755,7 @@ ar6000_ioctl_siwretry(struct net_device *dev,
struct iw_request_info *info,
struct iw_param *rrq, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
if (ar->arWlanState == WLAN_DISABLED) {
return -EIO;
@@ -791,7 +791,7 @@ ar6000_ioctl_giwretry(struct net_device *dev,
struct iw_request_info *info,
struct iw_param *rrq, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
if (ar->arWlanState == WLAN_DISABLED) {
return -EIO;
@@ -827,7 +827,7 @@ ar6000_ioctl_siwencode(struct net_device *dev,
struct iw_request_info *info,
struct iw_point *erq, char *keybuf)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
int index;
A_INT32 auth = ar->arDot11AuthMode;
@@ -1219,7 +1219,7 @@ ar6000_ioctl_setparam(struct net_device *dev,
struct iw_request_info *info,
void *erq, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
int *i = (int *)extra;
int param = i[0];
int value = i[1];
@@ -1362,7 +1362,7 @@ int
ar6000_ioctl_setkey(struct net_device *dev, struct iw_request_info *info,
void *w, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
struct ieee80211req_key *ik = (struct ieee80211req_key *)extra;
KEY_USAGE keyUsage;
A_STATUS status;
@@ -1431,7 +1431,7 @@ ar6000_ioctl_giwname(struct net_device *dev,
struct iw_request_info *info,
char *name, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
if (ar->arWlanState == WLAN_DISABLED) {
return -EIO;
@@ -1463,7 +1463,7 @@ ar6000_ioctl_siwfreq(struct net_device *dev,
struct iw_request_info *info,
struct iw_freq *freq, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
if (ar->arWlanState == WLAN_DISABLED) {
return -EIO;
@@ -1496,7 +1496,7 @@ ar6000_ioctl_giwfreq(struct net_device *dev,
struct iw_request_info *info,
struct iw_freq *freq, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
if (ar->arWlanState == WLAN_DISABLED) {
return -EIO;
@@ -1520,7 +1520,7 @@ ar6000_ioctl_siwmode(struct net_device *dev,
struct iw_request_info *info,
__u32 *mode, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
if (ar->arWlanState == WLAN_DISABLED) {
return -EIO;
@@ -1548,7 +1548,7 @@ ar6000_ioctl_giwmode(struct net_device *dev,
struct iw_request_info *info,
__u32 *mode, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
if (ar->arWlanState == WLAN_DISABLED) {
return -EIO;
@@ -1600,7 +1600,7 @@ ar6000_ioctl_giwrange(struct net_device *dev,
struct iw_request_info *info,
struct iw_point *data, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
struct iw_range *range = (struct iw_range *) extra;
int i, ret = 0;
@@ -1712,7 +1712,7 @@ ar6000_ioctl_siwap(struct net_device *dev,
struct iw_request_info *info,
struct sockaddr *ap_addr, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
if (ar->arWlanState == WLAN_DISABLED) {
return -EIO;
@@ -1739,7 +1739,7 @@ ar6000_ioctl_giwap(struct net_device *dev,
struct iw_request_info *info,
struct sockaddr *ap_addr, char *extra)
{
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
if (ar->arWlanState == WLAN_DISABLED) {
return -EIO;
@@ -1777,7 +1777,7 @@ ar6000_ioctl_siwscan(struct net_device *dev,
#define ACT_DWELLTIME_DEFAULT 105
#define HOME_TXDRAIN_TIME 100
#define SCAN_INT HOME_TXDRAIN_TIME + ACT_DWELLTIME_DEFAULT
- AR_SOFTC_T *ar = (AR_SOFTC_T *)dev->priv;
+ AR_SOFTC_T *ar = (AR_SOFTC_T *)netdev_priv(dev);
int ret = 0;
if (ar->arWmiReady == FALSE) {