diff options
author | Wey-Yi Guy <wey-yi.w.guy@intel.com> | 2011-06-06 23:26:43 +0200 |
---|---|---|
committer | Wey-Yi Guy <wey-yi.w.guy@intel.com> | 2011-06-11 16:11:13 +0200 |
commit | 1f8bf0396ae7e63648b210fd197b1a5ab0db51bf (patch) | |
tree | 2fb91fac19f8257b7c57cf457b01e2ade714fc09 /drivers/net/wireless/iwlwifi/iwl-agn.h | |
parent | iwlagn: group similar defines together (diff) | |
download | linux-1f8bf0396ae7e63648b210fd197b1a5ab0db51bf.tar.xz linux-1f8bf0396ae7e63648b210fd197b1a5ab0db51bf.zip |
iwlagn: merge duplicated code into single place
Multiple places have similar code to construct calib header. Merge into
single inline function.
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-agn.h')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-agn.h | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-agn.h b/drivers/net/wireless/iwlwifi/iwl-agn.h index 94ee1416fb99..5d8b2db82a97 100644 --- a/drivers/net/wireless/iwlwifi/iwl-agn.h +++ b/drivers/net/wireless/iwlwifi/iwl-agn.h @@ -129,6 +129,14 @@ static inline void iwl_synchronize_irq(struct iwl_priv *priv) tasklet_kill(&priv->irq_tasklet); } +static inline void iwl_set_calib_hdr(struct iwl_calib_hdr *hdr, u8 cmd) +{ + hdr->op_code = cmd; + hdr->first_group = 0; + hdr->groups_num = 1; + hdr->data_valid = 1; +} + int iwl_prepare_card_hw(struct iwl_priv *priv); int iwlagn_start_device(struct iwl_priv *priv); |