diff options
author | Emmanuel Grumbach <emmanuel.grumbach@intel.com> | 2012-03-26 18:03:18 +0200 |
---|---|---|
committer | Wey-Yi Guy <wey-yi.w.guy@intel.com> | 2012-04-18 16:31:23 +0200 |
commit | 87ce05a251227c0b607c6395f24ace96fc592806 (patch) | |
tree | ab9e5437a83d63fecf46bd25476ce6ef56407b61 /drivers/net/wireless/iwlwifi/iwl-pci.c | |
parent | iwlwifi: don't use shared for the logger any more (diff) | |
download | linux-87ce05a251227c0b607c6395f24ace96fc592806.tar.xz linux-87ce05a251227c0b607c6395f24ace96fc592806.zip |
iwlwifi: remove the shared area
It is not needed any more.
Signed-off-by: Emmanuel Grumbach <emmanuel.grumbach@intel.com>
Signed-off-by: Wey-Yi Guy <wey-yi.w.guy@intel.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-pci.c')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl-pci.c | 32 |
1 files changed, 7 insertions, 25 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-pci.c b/drivers/net/wireless/iwlwifi/iwl-pci.c index 68974a996136..47db96f12c90 100644 --- a/drivers/net/wireless/iwlwifi/iwl-pci.c +++ b/drivers/net/wireless/iwlwifi/iwl-pci.c @@ -268,30 +268,17 @@ MODULE_DEVICE_TABLE(pci, iwl_hw_card_ids); static int iwl_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent) { const struct iwl_cfg *cfg = (struct iwl_cfg *)(ent->driver_data); - struct iwl_shared *shrd; struct iwl_trans *iwl_trans; struct iwl_trans_pcie *trans_pcie; - int err; - - shrd = kzalloc(sizeof(*iwl_trans->shrd), GFP_KERNEL); - if (!shrd) { - dev_printk(KERN_ERR, &pdev->dev, - "Couldn't allocate iwl_shared"); - err = -ENOMEM; - goto out_free_bus; - } - - iwl_trans = iwl_trans_pcie_alloc(shrd, pdev, ent, cfg); - if (iwl_trans == NULL) { - err = -ENOMEM; - goto out_free_bus; - } - - shrd->trans = iwl_trans; + + iwl_trans = iwl_trans_pcie_alloc(pdev, ent, cfg); + if (iwl_trans == NULL) + return -ENOMEM; + pci_set_drvdata(pdev, iwl_trans); trans_pcie = IWL_TRANS_GET_PCIE_TRANS(iwl_trans); - trans_pcie->drv = iwl_drv_start(shrd, iwl_trans, cfg); + trans_pcie->drv = iwl_drv_start(iwl_trans, cfg); if (!trans_pcie->drv) goto out_free_trans; @@ -300,23 +287,18 @@ static int iwl_pci_probe(struct pci_dev *pdev, const struct pci_device_id *ent) out_free_trans: iwl_trans_free(iwl_trans); pci_set_drvdata(pdev, NULL); -out_free_bus: - kfree(shrd); - return err; + return -EFAULT; } static void __devexit iwl_pci_remove(struct pci_dev *pdev) { struct iwl_trans *trans = pci_get_drvdata(pdev); struct iwl_trans_pcie *trans_pcie = IWL_TRANS_GET_PCIE_TRANS(trans); - struct iwl_shared *shrd = trans->shrd; iwl_drv_stop(trans_pcie->drv); iwl_trans_free(trans); pci_set_drvdata(pdev, NULL); - - kfree(shrd); } #endif /* CONFIG_IWLWIFI_IDI */ |