rebase patch 6 and 7 from 'various fixes' patch-set
cover rebase patch 6 and 7 from 'various fixes' patch-set
* [PATCH v2 6/7] ath10k: reindent ath10k_pci_suspend
* [PATCH v2 7/7] ath10k: return error if suspend command fails
Markowski Bartosz (2):
ath10k: reindent ath10k_pci_suspend
ath10k: return error if suspend command fails
drivers/net/wireless/ath/ath10k/pci.c | 50 +++++++++++++++++---------------- 1 file changed, 26 insertions(+), 24 deletions(-)
Signature · 1 line
1.7.10
PATCH 1/2 ath10k: reindent ath10k_pci_suspend
From: Markowski Bartosz <[email protected]>
--- drivers/net/wireless/ath/ath10k/pci.c | 50 +++++++++++++++++---------------- 1 file changed, 26 insertions(+), 24 deletions(-)
drivers/net/wireless/ath/ath10k/pci.c +26 -24
@@ -2430,33 +2430,35 @@ static int ath10k_pci_suspend(struct device *device)if (!ar_pci)return -ENODEV ; -if (!ath10k_core_target_suspend (ar)) { - left =wait_event_interruptible_timeout (ar->event_queue, - ar->is_target_paused == true, -1 *HZ ); - -if (!left) { -ath10k_warn ("failed to receive target pasused" -" event [left=%d]\n" , left); -return -EIO ; - } -/* -* reset is_target_paused and host can check that in next time, -* or it will always be TRUE and host just skip the waiting -* condition, it causes target assert due to host already -* suspend -*/ - ar->is_target_paused = false; +if (ath10k_core_target_suspend (ar)) +return 0 ; -pci_read_config_dword (pdev,ATH10K_PCI_PM_CONTROL , &val); + left =wait_event_interruptible_timeout (ar->event_queue, + ar->is_target_paused == true, +1 *HZ ); -if ((val &0x000000ff ) !=0x3 ) { -pci_save_state (pdev); -pci_disable_device (pdev); -pci_write_config_dword (pdev,ATH10K_PCI_PM_CONTROL , - (val &0xffffff00 ) |0x03 ); - } +if (!left) { +ath10k_warn ("failed to receive target pasused event [left=%d]\n" , left); +return -EIO ; + } + +/* +* reset is_target_paused and host can check that in next time, +* or it will always be TRUE and host just skip the waiting +* condition, it causes target assert due to host already +* suspend +*/ + ar->is_target_paused = false; + +pci_read_config_dword (pdev,ATH10K_PCI_PM_CONTROL , &val); + +if ((val &0x000000ff ) !=0x3 ) { +pci_save_state (pdev); +pci_disable_device (pdev); +pci_write_config_dword (pdev,ATH10K_PCI_PM_CONTROL , + (val &0xffffff00 ) |0x03 ); } +return 0 ; }
Signature · 1 line
1.7.10
PATCH 2/2 ath10k: return error if suspend command fails
In reply to Bartosz MarkowskiFrom: Markowski Bartosz <[email protected]>
In case the WMI suspend commands fails, return -EBUSY up.
--- drivers/net/wireless/ath/ath10k/pci.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/net/wireless/ath/ath10k/pci.c +1 -1
@@ -2431,7 +2431,7 @@ static int ath10k_pci_suspend(struct device *device)return -ENODEV ;if (ath10k_core_target_suspend (ar)) -return 0 ; +return -EBUSY ; left = wait_event_interruptible_timeout(ar->event_queue, ar->is_target_paused == true,
Signature · 1 line
1.7.10
Kalle Valo
Appliedcover rebase patch 6 and 7 from 'various fixes' patch-set
In reply to Bartosz MarkowskiQuoted 6 lines · Bartosz Markowski
* [PATCH v2 6/7] ath10k: reindent
ath10k_pci_suspend
* [PATCH v2 7/7] ath10k: return error if suspend command failsMarkowski Bartosz (2):
ath10k: reindentath10k_pci_suspend
ath10k: return error if suspend command fails
Thanks, applied.
Signature · 1 line
Kalle Valo