diff options
author | Mohamed Abbas <mabbas@linux.intel.com> | 2008-03-28 19:21:05 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2008-04-01 17:13:18 -0400 |
commit | c8381fdcab98b74f670d879097bab35d97d88400 (patch) | |
tree | ad2622cb396c700377dbeb26f3e36b280225bc8d /drivers/net/wireless/iwlwifi/iwl4965-base.c | |
parent | 0675abdbfbcb8e0253a970c0dfe8d23b112888f3 (diff) |
iwlwifi: add notification infrastructure to iwlcore
This patch add notification function to be called by low level
iwl driver to notify iwlcore with current state. This function
will call iwlcore subsystem with the new state. This will
help make the code more consistent and easy to extend. For example
the rf-kill need to know when the driver in init, start, stop or
remove state. Instead doing the same call in 3945 and 4965, we
just do it from this function.
Signed-off-by: Mohamed Abbas <mabbas@linux.intel.com>
Signed-off-by: Reinette Chatre <reinette.chatre@intel.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl4965-base.c')
-rw-r--r-- | drivers/net/wireless/iwlwifi/iwl4965-base.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl4965-base.c b/drivers/net/wireless/iwlwifi/iwl4965-base.c index cf56b95dd221..5261b6179a86 100644 --- a/drivers/net/wireless/iwlwifi/iwl4965-base.c +++ b/drivers/net/wireless/iwlwifi/iwl4965-base.c | |||
@@ -5724,6 +5724,7 @@ static void iwl4965_alive_start(struct iwl_priv *priv) | |||
5724 | if (priv->error_recovering) | 5724 | if (priv->error_recovering) |
5725 | iwl4965_error_recovery(priv); | 5725 | iwl4965_error_recovery(priv); |
5726 | 5726 | ||
5727 | iwlcore_low_level_notify(priv, IWLCORE_START_EVT); | ||
5727 | return; | 5728 | return; |
5728 | 5729 | ||
5729 | restart: | 5730 | restart: |
@@ -5747,6 +5748,8 @@ static void __iwl4965_down(struct iwl_priv *priv) | |||
5747 | 5748 | ||
5748 | iwl_leds_unregister(priv); | 5749 | iwl_leds_unregister(priv); |
5749 | 5750 | ||
5751 | iwlcore_low_level_notify(priv, IWLCORE_STOP_EVT); | ||
5752 | |||
5750 | iwlcore_clear_stations_table(priv); | 5753 | iwlcore_clear_stations_table(priv); |
5751 | 5754 | ||
5752 | /* Unblock any waiting calls */ | 5755 | /* Unblock any waiting calls */ |
@@ -8167,6 +8170,8 @@ static int iwl4965_pci_probe(struct pci_dev *pdev, const struct pci_device_id *e | |||
8167 | pci_save_state(pdev); | 8170 | pci_save_state(pdev); |
8168 | pci_disable_device(pdev); | 8171 | pci_disable_device(pdev); |
8169 | 8172 | ||
8173 | /* notify iwlcore to init */ | ||
8174 | iwlcore_low_level_notify(priv, IWLCORE_INIT_EVT); | ||
8170 | return 0; | 8175 | return 0; |
8171 | 8176 | ||
8172 | out_remove_sysfs: | 8177 | out_remove_sysfs: |
@@ -8209,6 +8214,7 @@ static void __devexit iwl4965_pci_remove(struct pci_dev *pdev) | |||
8209 | } | 8214 | } |
8210 | } | 8215 | } |
8211 | 8216 | ||
8217 | iwlcore_low_level_notify(priv, IWLCORE_REMOVE_EVT); | ||
8212 | iwl_dbgfs_unregister(priv); | 8218 | iwl_dbgfs_unregister(priv); |
8213 | sysfs_remove_group(&pdev->dev.kobj, &iwl4965_attribute_group); | 8219 | sysfs_remove_group(&pdev->dev.kobj, &iwl4965_attribute_group); |
8214 | 8220 | ||