diff options
author | Stanislaw Gruszka <sgruszka@redhat.com> | 2011-10-24 10:49:25 -0400 |
---|---|---|
committer | Stanislaw Gruszka <sgruszka@redhat.com> | 2011-11-15 05:17:00 -0500 |
commit | 46bc8d4b0e73ac75de323646d75a2333f47b84c3 (patch) | |
tree | a11a89b1a3480135e1510aacd5909485ab2e5be7 /drivers/net/wireless/iwlegacy/iwl-dev.h | |
parent | e2ebc8337d116acdc25469ec8547ae665f50a4c1 (diff) |
iwlegacy: rename priv to il
Make code shorter.
Signed-off-by: Stanislaw Gruszka <sgruszka@redhat.com>
Diffstat (limited to 'drivers/net/wireless/iwlegacy/iwl-dev.h')
-rw-r--r-- | drivers/net/wireless/iwlegacy/iwl-dev.h | 62 |
1 files changed, 31 insertions, 31 deletions
diff --git a/drivers/net/wireless/iwlegacy/iwl-dev.h b/drivers/net/wireless/iwlegacy/iwl-dev.h index 20c44f36ba7..824d1934a7a 100644 --- a/drivers/net/wireless/iwlegacy/iwl-dev.h +++ b/drivers/net/wireless/iwlegacy/iwl-dev.h | |||
@@ -106,7 +106,7 @@ struct il_cmd_meta { | |||
106 | * invoked for SYNC commands, if it were and its result passed | 106 | * invoked for SYNC commands, if it were and its result passed |
107 | * through it would be simpler...) | 107 | * through it would be simpler...) |
108 | */ | 108 | */ |
109 | void (*callback)(struct il_priv *priv, | 109 | void (*callback)(struct il_priv *il, |
110 | struct il_device_cmd *cmd, | 110 | struct il_device_cmd *cmd, |
111 | struct il_rx_packet *pkt); | 111 | struct il_rx_packet *pkt); |
112 | 112 | ||
@@ -321,7 +321,7 @@ struct il_device_cmd { | |||
321 | struct il_host_cmd { | 321 | struct il_host_cmd { |
322 | const void *data; | 322 | const void *data; |
323 | unsigned long reply_page; | 323 | unsigned long reply_page; |
324 | void (*callback)(struct il_priv *priv, | 324 | void (*callback)(struct il_priv *il, |
325 | struct il_device_cmd *cmd, | 325 | struct il_device_cmd *cmd, |
326 | struct il_rx_packet *pkt); | 326 | struct il_rx_packet *pkt); |
327 | u32 flags; | 327 | u32 flags; |
@@ -476,7 +476,7 @@ struct il_station_priv_common { | |||
476 | }; | 476 | }; |
477 | 477 | ||
478 | /* | 478 | /* |
479 | * il_station_priv: Driver's private station information | 479 | * il_station_priv: Driver's ilate station information |
480 | * | 480 | * |
481 | * When mac80211 creates a station it reserves some space (hw->sta_data_size) | 481 | * When mac80211 creates a station it reserves some space (hw->sta_data_size) |
482 | * in the structure for use by driver. This structure is places in that | 482 | * in the structure for use by driver. This structure is places in that |
@@ -494,7 +494,7 @@ struct il_station_priv { | |||
494 | }; | 494 | }; |
495 | 495 | ||
496 | /** | 496 | /** |
497 | * struct il_vif_priv - driver's private per-interface information | 497 | * struct il_vif_priv - driver's ilate per-interface information |
498 | * | 498 | * |
499 | * When mac80211 allocates a virtual interface, it can allocate | 499 | * When mac80211 allocates a virtual interface, it can allocate |
500 | * space for us to put data into. | 500 | * space for us to put data into. |
@@ -625,7 +625,7 @@ struct il_hw_params { | |||
625 | * il4965_mac_ <-- mac80211 callback | 625 | * il4965_mac_ <-- mac80211 callback |
626 | * | 626 | * |
627 | ****************************************************************************/ | 627 | ****************************************************************************/ |
628 | extern void il4965_update_chain_flags(struct il_priv *priv); | 628 | extern void il4965_update_chain_flags(struct il_priv *il); |
629 | extern const u8 iwlegacy_bcast_addr[ETH_ALEN]; | 629 | extern const u8 iwlegacy_bcast_addr[ETH_ALEN]; |
630 | extern int il_queue_space(const struct il_queue *q); | 630 | extern int il_queue_space(const struct il_queue *q); |
631 | static inline int il_queue_used(const struct il_queue *q, int i) | 631 | static inline int il_queue_used(const struct il_queue *q, int i) |
@@ -973,7 +973,7 @@ struct il_priv { | |||
973 | enum ieee80211_band band; | 973 | enum ieee80211_band band; |
974 | int alloc_rxb_page; | 974 | int alloc_rxb_page; |
975 | 975 | ||
976 | void (*rx_handlers[REPLY_MAX])(struct il_priv *priv, | 976 | void (*rx_handlers[REPLY_MAX])(struct il_priv *il, |
977 | struct il_rx_mem_buffer *rxb); | 977 | struct il_rx_mem_buffer *rxb); |
978 | 978 | ||
979 | struct ieee80211_supported_band bands[IEEE80211_NUM_BANDS]; | 979 | struct ieee80211_supported_band bands[IEEE80211_NUM_BANDS]; |
@@ -1247,14 +1247,14 @@ struct il_priv { | |||
1247 | bool led_registered; | 1247 | bool led_registered; |
1248 | }; /*il_priv */ | 1248 | }; /*il_priv */ |
1249 | 1249 | ||
1250 | static inline void il_txq_ctx_activate(struct il_priv *priv, int txq_id) | 1250 | static inline void il_txq_ctx_activate(struct il_priv *il, int txq_id) |
1251 | { | 1251 | { |
1252 | set_bit(txq_id, &priv->txq_ctx_active_msk); | 1252 | set_bit(txq_id, &il->txq_ctx_active_msk); |
1253 | } | 1253 | } |
1254 | 1254 | ||
1255 | static inline void il_txq_ctx_deactivate(struct il_priv *priv, int txq_id) | 1255 | static inline void il_txq_ctx_deactivate(struct il_priv *il, int txq_id) |
1256 | { | 1256 | { |
1257 | clear_bit(txq_id, &priv->txq_ctx_active_msk); | 1257 | clear_bit(txq_id, &il->txq_ctx_active_msk); |
1258 | } | 1258 | } |
1259 | 1259 | ||
1260 | #ifdef CONFIG_IWLWIFI_LEGACY_DEBUG | 1260 | #ifdef CONFIG_IWLWIFI_LEGACY_DEBUG |
@@ -1265,15 +1265,15 @@ static inline void il_txq_ctx_deactivate(struct il_priv *priv, int txq_id) | |||
1265 | * level will be used if set, otherwise the global debug level which can be | 1265 | * level will be used if set, otherwise the global debug level which can be |
1266 | * set via module parameter is used. | 1266 | * set via module parameter is used. |
1267 | */ | 1267 | */ |
1268 | static inline u32 il_get_debug_level(struct il_priv *priv) | 1268 | static inline u32 il_get_debug_level(struct il_priv *il) |
1269 | { | 1269 | { |
1270 | if (priv->debug_level) | 1270 | if (il->debug_level) |
1271 | return priv->debug_level; | 1271 | return il->debug_level; |
1272 | else | 1272 | else |
1273 | return iwlegacy_debug_level; | 1273 | return iwlegacy_debug_level; |
1274 | } | 1274 | } |
1275 | #else | 1275 | #else |
1276 | static inline u32 il_get_debug_level(struct il_priv *priv) | 1276 | static inline u32 il_get_debug_level(struct il_priv *il) |
1277 | { | 1277 | { |
1278 | return iwlegacy_debug_level; | 1278 | return iwlegacy_debug_level; |
1279 | } | 1279 | } |
@@ -1281,11 +1281,11 @@ static inline u32 il_get_debug_level(struct il_priv *priv) | |||
1281 | 1281 | ||
1282 | 1282 | ||
1283 | static inline struct ieee80211_hdr * | 1283 | static inline struct ieee80211_hdr * |
1284 | il_tx_queue_get_hdr(struct il_priv *priv, | 1284 | il_tx_queue_get_hdr(struct il_priv *il, |
1285 | int txq_id, int idx) | 1285 | int txq_id, int idx) |
1286 | { | 1286 | { |
1287 | if (priv->txq[txq_id].txb[idx].skb) | 1287 | if (il->txq[txq_id].txb[idx].skb) |
1288 | return (struct ieee80211_hdr *)priv->txq[txq_id]. | 1288 | return (struct ieee80211_hdr *)il->txq[txq_id]. |
1289 | txb[idx].skb->data; | 1289 | txb[idx].skb->data; |
1290 | return NULL; | 1290 | return NULL; |
1291 | } | 1291 | } |
@@ -1298,21 +1298,21 @@ il_rxon_ctx_from_vif(struct ieee80211_vif *vif) | |||
1298 | return vif_priv->ctx; | 1298 | return vif_priv->ctx; |
1299 | } | 1299 | } |
1300 | 1300 | ||
1301 | #define for_each_context(priv, ctx) \ | 1301 | #define for_each_context(il, ctx) \ |
1302 | for (ctx = &priv->contexts[IL_RXON_CTX_BSS]; \ | 1302 | for (ctx = &il->contexts[IL_RXON_CTX_BSS]; \ |
1303 | ctx < &priv->contexts[NUM_IL_RXON_CTX]; ctx++) \ | 1303 | ctx < &il->contexts[NUM_IL_RXON_CTX]; ctx++) \ |
1304 | if (priv->valid_contexts & BIT(ctx->ctxid)) | 1304 | if (il->valid_contexts & BIT(ctx->ctxid)) |
1305 | 1305 | ||
1306 | static inline int il_is_associated(struct il_priv *priv, | 1306 | static inline int il_is_associated(struct il_priv *il, |
1307 | enum il_rxon_context_id ctxid) | 1307 | enum il_rxon_context_id ctxid) |
1308 | { | 1308 | { |
1309 | return (priv->contexts[ctxid].active.filter_flags & | 1309 | return (il->contexts[ctxid].active.filter_flags & |
1310 | RXON_FILTER_ASSOC_MSK) ? 1 : 0; | 1310 | RXON_FILTER_ASSOC_MSK) ? 1 : 0; |
1311 | } | 1311 | } |
1312 | 1312 | ||
1313 | static inline int il_is_any_associated(struct il_priv *priv) | 1313 | static inline int il_is_any_associated(struct il_priv *il) |
1314 | { | 1314 | { |
1315 | return il_is_associated(priv, IL_RXON_CTX_BSS); | 1315 | return il_is_associated(il, IL_RXON_CTX_BSS); |
1316 | } | 1316 | } |
1317 | 1317 | ||
1318 | static inline int il_is_associated_ctx(struct il_rxon_context *ctx) | 1318 | static inline int il_is_associated_ctx(struct il_rxon_context *ctx) |
@@ -1350,15 +1350,15 @@ il_is_channel_ibss(const struct il_channel_info *ch) | |||
1350 | } | 1350 | } |
1351 | 1351 | ||
1352 | static inline void | 1352 | static inline void |
1353 | __il_free_pages(struct il_priv *priv, struct page *page) | 1353 | __il_free_pages(struct il_priv *il, struct page *page) |
1354 | { | 1354 | { |
1355 | __free_pages(page, priv->hw_params.rx_page_order); | 1355 | __free_pages(page, il->hw_params.rx_page_order); |
1356 | priv->alloc_rxb_page--; | 1356 | il->alloc_rxb_page--; |
1357 | } | 1357 | } |
1358 | 1358 | ||
1359 | static inline void il_free_pages(struct il_priv *priv, unsigned long page) | 1359 | static inline void il_free_pages(struct il_priv *il, unsigned long page) |
1360 | { | 1360 | { |
1361 | free_pages(page, priv->hw_params.rx_page_order); | 1361 | free_pages(page, il->hw_params.rx_page_order); |
1362 | priv->alloc_rxb_page--; | 1362 | il->alloc_rxb_page--; |
1363 | } | 1363 | } |
1364 | #endif /* __il_dev_h__ */ | 1364 | #endif /* __il_dev_h__ */ |