diff options
author | Tomas Winkler <tomas.winkler@intel.com> | 2008-09-03 11:26:49 +0800 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2008-09-08 14:23:19 -0400 |
commit | e7b635814b640c6fd9dca1c254dc22fac6fb9a1a (patch) | |
tree | ff09a16f4a704b81dedde80a68728ddc4e423505 /drivers/net/wireless/iwlwifi/iwl-4965.c | |
parent | 926f0b2ef24041db876ec7213fbddd7cd4555951 (diff) | |
download | lwn-e7b635814b640c6fd9dca1c254dc22fac6fb9a1a.tar.gz lwn-e7b635814b640c6fd9dca1c254dc22fac6fb9a1a.zip |
iwlwifi: cleanup PCI register handling
This patch cleans up pci registers handling.
Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
Signed-off-by: Zhu Yi <yi.zhu@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-4965.c')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-4965.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-4965.c b/drivers/net/wireless/iwlwifi/iwl-4965.c index e2581229d8b2..46e076af8f7e 100644 --- a/drivers/net/wireless/iwlwifi/iwl-4965.c +++ b/drivers/net/wireless/iwlwifi/iwl-4965.c @@ -399,7 +399,7 @@ static void iwl4965_nic_config(struct iwl_priv *priv) unsigned long flags; u32 val; u16 radio_cfg; - u8 val_link; + u16 link; spin_lock_irqsave(&priv->lock, flags); @@ -410,10 +410,10 @@ static void iwl4965_nic_config(struct iwl_priv *priv) val & ~(1 << 11)); } - pci_read_config_byte(priv->pci_dev, PCI_LINK_CTRL, &val_link); + pci_read_config_word(priv->pci_dev, PCI_CFG_LINK_CTRL, &link); /* L1 is enabled by BIOS */ - if ((val_link & PCI_LINK_VAL_L1_EN) == PCI_LINK_VAL_L1_EN) + if ((link & PCI_CFG_LINK_CTRL_VAL_L1_EN) == PCI_CFG_LINK_CTRL_VAL_L1_EN) /* diable L0S disabled L1A enabled */ iwl_set_bit(priv, CSR_GIO_REG, CSR_GIO_REG_VAL_L0S_ENABLED); else |