ath9k: Fix ath9k prevents CPU to enter C3 states
RFC 1/1 ath9k: Fix ath9k prevents CPU to enter C3 states
From: Mohammed Shafi Shajakhan <[email protected]>
The DMA latency issue is observed only in Intel pinetrail platforms but in the driver we had a default PM-QOS value of 55. This caused unnecessary power consumption and battery drain in other platforms.
Remove the pm-qos thing in the driver code and address the throughput issue in
Intel pinetrail platfroms in user space using any one of the scripts in below links:
http://www.kernel.org/pub/linux/kernel/people/mcgrof/scripts/cpudmalatency.c
http://johannes.sipsolutions.net/files/netlatency.c.txt
More details can be found in the following bugzilla link:
https://bugzilla.kernel.org/show_bug.cgi?id=27532
--- drivers/net/wireless/ath/ath9k/ath9k.h | 5 ----- drivers/net/wireless/ath/ath9k/init.c | 7 ------- drivers/net/wireless/ath/ath9k/main.c | 8 -------- 3 files changed, 0 insertions(+), 20 deletions(-)
drivers/net/wireless/ath/ath9k/ath9k.h +0 -5
@@ -21,7 +21,6 @@#include <linux/device.h> #include <linux/leds.h> #include <linux/completion.h> -#include <linux/pm_qos_params.h> #include "debug.h" #include "common.h"
@@ -57,8 +56,6 @@ struct ath_node;#define A_MAX (a, b) ((a) > (b) ? (a) : (b)) -#define ATH9K_PM_QOS_DEFAULT_VALUE 55 -#define TSF_TO_TU (_h,_l) \ ((((u32)(_h)) << 22) | (((u32)(_l)) >> 10))
@@ -650,7 +647,6 @@ struct ath_softc {struct ath_ant_comb ant_comb; -struct pm_qos_request_list pm_qos_req; };void ath9k_tasklet (unsigned long data);
@@ -665,7 +661,6 @@ static inline void ath_read_cachesize(struct ath_common *common, int *csz)extern struct ieee80211_ops ath9k_ops;extern int ath9k_modparam_nohwcrypt;extern int led_blink; -extern int ath9k_pm_qos_value;extern bool is_ath9k_unloaded;irqreturn_t ath_isr (int irq,void *dev);
drivers/net/wireless/ath/ath9k/init.c +0 -7
@@ -41,9 +41,6 @@ static int ath9k_btcoex_enable;module_param_named (btcoex_enable, ath9k_btcoex_enable, int,0444 );MODULE_PARM_DESC (btcoex_enable,"Enable wifi-BT coexistence" ); -int ath9k_pm_qos_value =ATH9K_PM_QOS_DEFAULT_VALUE ; -module_param_named (pmqos, ath9k_pm_qos_value, int,S_IRUSR |S_IRGRP |S_IROTH ); -MODULE_PARM_DESC (pmqos,"User specified PM-QOS value" );bool is_ath9k_unloaded;/* We use the hw_value as an index into our private channel structure */
@@ -760,9 +757,6 @@ int ath9k_init_device(u16 devid, struct ath_softc *sc, u16 subsysid,ath_init_leds (sc);ath_start_rfkill_poll (sc); -pm_qos_add_request (&sc->pm_qos_req,PM_QOS_CPU_DMA_LATENCY , -PM_QOS_DEFAULT_VALUE ); -return 0 ; error_world:
@@ -819,7 +813,6 @@ void ath9k_deinit_device(struct ath_softc *sc)ath9k_ps_restore (sc);ieee80211_unregister_hw (hw); -pm_qos_remove_request (&sc->pm_qos_req);ath_rx_cleanup (sc);ath_tx_cleanup (sc);ath9k_deinit_softc (sc);
drivers/net/wireless/ath/ath9k/main.c +0 -8
@@ -1117,12 +1117,6 @@ static int ath9k_start(struct ieee80211_hw *hw)ath9k_btcoex_timer_resume (sc); } -/* User has the option to provide pm-qos value as a module -* parameter rather than using the default value of -* 'ATH9K_PM_QOS_DEFAULT_VALUE'. -*/ -pm_qos_update_request (&sc->pm_qos_req, ath9k_pm_qos_value); -if (ah->caps.pcie_lcr_extsync_en && common->bus_ops->extn_synch_en) common->bus_ops->extn_synch_en (common);
@@ -1267,8 +1261,6 @@ static void ath9k_stop(struct ieee80211_hw *hw) sc->sc_flags |=SC_OP_INVALID ; -pm_qos_update_request (&sc->pm_qos_req,PM_QOS_DEFAULT_VALUE ); -mutex_unlock (&sc->mutex);ath_dbg (common,ATH_DBG_CONFIG ,"Driver halt\n" );
Signature · 1 line
1.7.0.4
Despite the [RFC], I am applying this. I should have reverted all of this three weeks ago...
John
Quoted 118 lines · Mohammed Shafi Shajakhan
From: Mohammed Shafi Shajakhan <[email protected]>
The DMA latency issue is observed only in Intel pinetrail platforms but in the driver we had a default PM-QOS value of 55. This caused unnecessary power consumption and battery drain in other platforms.
Remove the pm-qos thing in the driver code and address the throughput issue in
Intel pinetrail platfroms in user space using any one of the scripts in below links:
http://www.kernel.org/pub/linux/kernel/people/mcgrof/scripts/cpudmalatency.c
http://johannes.sipsolutions.net/files/netlatency.c.txt
More details can be found in the following bugzilla link:
https://bugzilla.kernel.org/show_bug.cgi?id=27532Signed-off-by Mohammed Shafi Shajakhan <[email protected]>--- drivers/net/wireless/ath/ath9k/ath9k.h | 5 ----- drivers/net/wireless/ath/ath9k/init.c | 7 ------- drivers/net/wireless/ath/ath9k/main.c | 8 -------- 3 files changed, 0 insertions(+), 20 deletions(-)drivers/net/wireless/ath/ath9k/ath9k.h +0
-5@@ -21,7 +21,6 @@#include <linux/device.h> #include <linux/leds.h> #include <linux/completion.h> -#include <linux/pm_qos_params.h> #include "debug.h" #include "common.h" @@ -57,8 +56,6 @@ struct ath_node;#define A_MAX (a, b) ((a) > (b) ? (a) : (b)) -#define ATH9K_PM_QOS_DEFAULT_VALUE 55 -#define TSF_TO_TU (_h,_l) \ ((((u32)(_h)) << 22) | (((u32)(_l)) >> 10))@@ -650,7 +647,6 @@ struct ath_softc {struct ath_ant_comb ant_comb; -struct pm_qos_request_list pm_qos_req; };void ath9k_tasklet (unsigned long data);@@ -665,7 +661,6 @@ static inline void ath_read_cachesize(struct ath_common *common, int *csz)extern struct ieee80211_ops ath9k_ops;extern int ath9k_modparam_nohwcrypt;extern int led_blink; -extern int ath9k_pm_qos_value;extern bool is_ath9k_unloaded;irqreturn_t ath_isr (int irq,void *dev);drivers/net/wireless/ath/ath9k/init.c +0
-7@@ -41,9 +41,6 @@ static int ath9k_btcoex_enable;module_param_named (btcoex_enable, ath9k_btcoex_enable, int,0444 );MODULE_PARM_DESC (btcoex_enable,"Enable wifi-BT coexistence" ); -int ath9k_pm_qos_value =ATH9K_PM_QOS_DEFAULT_VALUE ; -module_param_named (pmqos, ath9k_pm_qos_value, int,S_IRUSR |S_IRGRP |S_IROTH ); -MODULE_PARM_DESC (pmqos,"User specified PM-QOS value" );bool is_ath9k_unloaded;/* We use the hw_value as an index into our private channel structure */ @@ -760,9 +757,6 @@ int ath9k_init_device(u16 devid, struct ath_softc *sc, u16 subsysid,ath_init_leds (sc);ath_start_rfkill_poll (sc); -pm_qos_add_request (&sc->pm_qos_req,PM_QOS_CPU_DMA_LATENCY , -PM_QOS_DEFAULT_VALUE ); -return 0 ; error_world:@@ -819,7 +813,6 @@ void ath9k_deinit_device(struct ath_softc *sc)ath9k_ps_restore (sc);ieee80211_unregister_hw (hw); -pm_qos_remove_request (&sc->pm_qos_req);ath_rx_cleanup (sc);ath_tx_cleanup (sc);ath9k_deinit_softc (sc);drivers/net/wireless/ath/ath9k/main.c +0
-8@@ -1117,12 +1117,6 @@ static int ath9k_start(struct ieee80211_hw *hw)ath9k_btcoex_timer_resume (sc); } -/* User has the option to provide pm-qos value as a module -* parameter rather than using the default value of -* 'ATH9K_PM_QOS_DEFAULT_VALUE'. -*/ -pm_qos_update_request (&sc->pm_qos_req, ath9k_pm_qos_value); -if (ah->caps.pcie_lcr_extsync_en && common->bus_ops->extn_synch_en) common->bus_ops->extn_synch_en (common);@@ -1267,8 +1261,6 @@ static void ath9k_stop(struct ieee80211_hw *hw) sc->sc_flags |=SC_OP_INVALID ; -pm_qos_update_request (&sc->pm_qos_req,PM_QOS_DEFAULT_VALUE ); -mutex_unlock (&sc->mutex);ath_dbg (common,ATH_DBG_CONFIG ,"Driver halt\n" );Signature · 1 line
1.7.0.4
Signature · 2 lines
John W. Linville Someday the world will need a hero, and you [email protected] might be all we have. Be ready.
Quoted 3 lines · John W. Linville
Despite the [RFC], I am applying this. I should have reverted all of this three weeks ago...
Thanks John.
Quoted 124 lines
John
Quoted 119 lines · Mohammed Shafi Shajakhan
From: Mohammed Shafi Shajakhan<[email protected]>
The DMA latency issue is observed only in Intel pinetrail platforms but in the driver we had a default PM-QOS value of 55. This caused unnecessary power consumption and battery drain in other platforms.
Remove the pm-qos thing in the driver code and address the throughput issue in
Intel pinetrail platfroms in user space using any one of the scripts in below links:
http://www.kernel.org/pub/linux/kernel/people/mcgrof/scripts/cpudmalatency.c
http://johannes.sipsolutions.net/files/netlatency.c.txt
More details can be found in the following bugzilla link:
https://bugzilla.kernel.org/show_bug.cgi?id=27532Signed-off-by Mohammed Shafi Shajakhan<[email protected]>--- drivers/net/wireless/ath/ath9k/ath9k.h | 5 ----- drivers/net/wireless/ath/ath9k/init.c | 7 ------- drivers/net/wireless/ath/ath9k/main.c | 8 -------- 3 files changed, 0 insertions(+), 20 deletions(-)drivers/net/wireless/ath/ath9k/ath9k.h +0
-5@@ -21,7 +21,6 @@#include <linux/device.h> #include <linux/leds.h> #include <linux/completion.h> -#include <linux/pm_qos_params.h> #include "debug.h" #include "common.h" @@ -57,8 +56,6 @@ struct ath_node;#define A_MAX (a, b) ((a)> (b) ? (a) : (b)) -#define ATH9K_PM_QOS_DEFAULT_VALUE 55 -#define TSF_TO_TU (_h,_l) \ ((((u32)(_h))<< 22) | (((u32)(_l))>> 10))@@ -650,7 +647,6 @@ struct ath_softc {struct ath_ant_comb ant_comb; -struct pm_qos_request_list pm_qos_req; };void ath9k_tasklet (unsigned long data);@@ -665,7 +661,6 @@ static inline void ath_read_cachesize(struct ath_common *common, int *csz)extern struct ieee80211_ops ath9k_ops;extern int ath9k_modparam_nohwcrypt;extern int led_blink; -extern int ath9k_pm_qos_value;extern bool is_ath9k_unloaded;irqreturn_t ath_isr (int irq,void *dev);drivers/net/wireless/ath/ath9k/init.c +0
-7@@ -41,9 +41,6 @@ static int ath9k_btcoex_enable;module_param_named (btcoex_enable, ath9k_btcoex_enable, int,0444 );MODULE_PARM_DESC (btcoex_enable,"Enable wifi-BT coexistence" ); -int ath9k_pm_qos_value =ATH9K_PM_QOS_DEFAULT_VALUE ; -module_param_named (pmqos, ath9k_pm_qos_value, int,S_IRUSR |S_IRGRP |S_IROTH ); -MODULE_PARM_DESC (pmqos,"User specified PM-QOS value" );bool is_ath9k_unloaded;/* We use the hw_value as an index into our private channel structure */ @@ -760,9 +757,6 @@ int ath9k_init_device(u16 devid, struct ath_softc *sc, u16 subsysid,ath_init_leds (sc);ath_start_rfkill_poll (sc); -pm_qos_add_request (&sc->pm_qos_req,PM_QOS_CPU_DMA_LATENCY , -PM_QOS_DEFAULT_VALUE ); -return 0 ; error_world:@@ -819,7 +813,6 @@ void ath9k_deinit_device(struct ath_softc *sc)ath9k_ps_restore (sc);ieee80211_unregister_hw (hw); -pm_qos_remove_request (&sc->pm_qos_req);ath_rx_cleanup (sc);ath_tx_cleanup (sc);ath9k_deinit_softc (sc);drivers/net/wireless/ath/ath9k/main.c +0
-8@@ -1117,12 +1117,6 @@ static int ath9k_start(struct ieee80211_hw *hw)ath9k_btcoex_timer_resume (sc); } -/* User has the option to provide pm-qos value as a module -* parameter rather than using the default value of -* 'ATH9K_PM_QOS_DEFAULT_VALUE'. -*/ -pm_qos_update_request (&sc->pm_qos_req, ath9k_pm_qos_value); -if (ah->caps.pcie_lcr_extsync_en&& common->bus_ops->extn_synch_en) common->bus_ops->extn_synch_en (common);@@ -1267,8 +1261,6 @@ static void ath9k_stop(struct ieee80211_hw *hw) sc->sc_flags |=SC_OP_INVALID ; -pm_qos_update_request (&sc->pm_qos_req,PM_QOS_DEFAULT_VALUE ); -mutex_unlock (&sc->mutex);ath_dbg (common,ATH_DBG_CONFIG ,"Driver halt\n" );Signature · 1 line
1.7.0.4
Quoted 3 lines · Mohammed Shafi
Quoted 2 lines · John W. Linville
Despite the [RFC], I am applying this. I should have reverted all of this three weeks ago...
John can you please push this to stable kernel ?
Quoted 129 lines
Thanks John.
Quoted 128 lines
John
Quoted 125 lines · Mohammed Shafi Shajakhan
From: Mohammed Shafi Shajakhan<[email protected]>
The DMA latency issue is observed only in Intel pinetrail platforms but in the driver we had a default PM-QOS value of 55. This caused unnecessary power consumption and battery drain in other platforms.
Remove the pm-qos thing in the driver code and address the
throughput issue in
Intel pinetrail platfroms in user space using any one of the scripts in below links:
http://www.kernel.org/pub/linux/kernel/people/mcgrof/scripts/cpudmalatency.chttp://johannes.sipsolutions.net/files/netlatency.c.txt
More details can be found in the following bugzilla link:
https://bugzilla.kernel.org/show_bug.cgi?id=27532Signed-off-by Mohammed Shafi Shajakhan<[email protected]>--- drivers/net/wireless/ath/ath9k/ath9k.h | 5 ----- drivers/net/wireless/ath/ath9k/init.c | 7 ------- drivers/net/wireless/ath/ath9k/main.c | 8 -------- 3 files changed, 0 insertions(+), 20 deletions(-)drivers/net/wireless/ath/ath9k/ath9k.h +0
-5@@ -21,7 +21,6 @@#include <linux/device.h> #include <linux/leds.h> #include <linux/completion.h> -#include <linux/pm_qos_params.h> #include "debug.h" #include "common.h" @@ -57,8 +56,6 @@ struct ath_node;#define A_MAX (a, b) ((a)> (b) ? (a) : (b)) -#define ATH9K_PM_QOS_DEFAULT_VALUE 55 -#define TSF_TO_TU (_h,_l) \ ((((u32)(_h))<< 22) | (((u32)(_l))>> 10))@@ -650,7 +647,6 @@ struct ath_softc {struct ath_ant_comb ant_comb; -struct pm_qos_request_list pm_qos_req; };void ath9k_tasklet (unsigned long data);@@ -665,7 +661,6 @@ static inline void ath_read_cachesize(struct ath_common *common, int *csz)extern struct ieee80211_ops ath9k_ops;extern int ath9k_modparam_nohwcrypt;extern int led_blink; -extern int ath9k_pm_qos_value;extern bool is_ath9k_unloaded;irqreturn_t ath_isr(int irq, void *dev);drivers/net/wireless/ath/ath9k/init.c +0
-3@@ -41,9 +41,6 @@ static int ath9k_btcoex_enable;module_param_named (btcoex_enable, ath9k_btcoex_enable, int,0444 );MODULE_PARM_DESC (btcoex_enable,"Enable wifi-BT coexistence" ); -int ath9k_pm_qos_value =ATH9K_PM_QOS_DEFAULT_VALUE ; -module_param_named (pmqos, ath9k_pm_qos_value, int,S_IRUSR | S_IRGRP | S_IROTH); -MODULE_PARM_DESC (pmqos,"User specified PM-QOS value" );bool is_ath9k_unloaded;/* We use the
hw_valueas an index into our private channel
structure */drivers/net/wireless/ath/ath9k/init.c +0
-3@@ -760,9 +757,6 @@ int ath9k_init_device(u16 devid, struct ath_softc *sc, u16 subsysid,ath_init_leds (sc );ath_start_rfkill_poll (sc); -pm_qos_add_request (&sc->pm_qos_req,PM_QOS_CPU_DMA_LATENCY , -PM_QOS_DEFAULT_VALUE ); -return 0 ;
error_world:drivers/net/wireless/ath/ath9k/init.c +0
-1@@ -819,7 +813,6 @@ void ath9k_deinit_device(struct ath_softc *sc)ath9k_ps_restore (sc);ieee80211_unregister_hw (hw); -pm_qos_remove_request (&sc->pm_qos_req);ath_rx_cleanup (sc);ath_tx_cleanup (sc);ath9k_deinit_softc (sc);drivers/net/wireless/ath/ath9k/main.c +0
-8@@ -1117,12 +1117,6 @@ static int ath9k_start(struct ieee80211_hw *hw)ath9k_btcoex_timer_resume (sc); } -/* User has the option to provide pm-qos value as a module -* parameter rather than using the default value of -* 'ATH9K_PM_QOS_DEFAULT_VALUE'. -*/ -pm_qos_update_request (&sc->pm_qos_req, ath9k_pm_qos_value); -if (ah->caps.pcie_lcr_extsync_en&& common->bus_ops->extn_synch_en) common->bus_ops->extn_synch_en (common);@@ -1267,8 +1261,6 @@ static void ath9k_stop(struct ieee80211_hw *hw) sc->sc_flags |=SC_OP_INVALID ; -pm_qos_update_request (&sc->pm_qos_req,PM_QOS_DEFAULT_VALUE ); -mutex_unlock (&sc->mutex);ath_dbg (common,ATH_DBG_CONFIG ,"Driver halt\n" );Signature · 1 line
1.7.0.4
Quoted 5 lines · Mohammed Shafi
Quoted 3 lines · Mohammed Shafi
Quoted 2 lines · John W. Linville
Despite the [RFC], I am applying this. I should have reverted all of this three weeks ago...
John can you please push this to stable kernel ?
Stable folks, this is the commit in Linus's tree;
commit 0f5cd45960173ba5b36727decbb4a241cbd35ef9
Author: Mohammed Shafi Shajakhan <[email protected]> Date: Tue Feb 15 21:29:32 2011 +0530
ath9k: Fix ath9k prevents CPU to enter C3 states
The DMA latency issue is observed only in Intel pinetrail platforms but in the driver we had a default PM-QOS value of 55. This caused unnecessary power consumption and battery drain in other platforms.
Remove the pm-qos thing in the driver code and address the throughput issue in Intel pinetrail platfroms in user space using any one of the scripts in below links:
http://www.kernel.org/pub/linux/kernel/people/mcgrof/scripts/cpudmalatency.c
http://johannes.sipsolutions.net/files/netlatency.c.txt
More details can be found in the following bugzilla link:
https://bugzilla.kernel.org/show_bug.cgi?id=27532
This reverts the following commits:
98c316e348bedffa730e6f1e4baeb8a3c3e0f28b
4dc3530df7c0428b41c00399a7ee8c929406d181
10598c124ecabbbfd7522f74de19b8f7d52a1bee
Quoted 139 lines
Quoted 129 lines
Thanks John.
Quoted 128 lines
John
Quoted 124 lines · Mohammed Shafi Shajakhan
From: Mohammed Shafi Shajakhan<[email protected]>
The DMA latency issue is observed only in Intel pinetrail platforms but in the driver we had a default PM-QOS value of 55. This caused unnecessary power consumption and battery drain in other platforms.
Remove the pm-qos thing in the driver code and address the
throughput issue in
Intel pinetrail platfroms in user space using any one of the scripts in below links:
http://www.kernel.org/pub/linux/kernel/people/mcgrof/scripts/cpudmalatency.chttp://johannes.sipsolutions.net/files/netlatency.c.txt
More details can be found in the following bugzilla link:
https://bugzilla.kernel.org/show_bug.cgi?id=27532Signed-off-by Mohammed Shafi Shajakhan<[email protected]>--- drivers/net/wireless/ath/ath9k/ath9k.h | 5 ----- drivers/net/wireless/ath/ath9k/init.c | 7 ------- drivers/net/wireless/ath/ath9k/main.c | 8 -------- 3 files changed, 0 insertions(+), 20 deletions(-)drivers/net/wireless/ath/ath9k/ath9k.h +0
-5@@ -21,7 +21,6 @@#include <linux/device.h> #include <linux/leds.h> #include <linux/completion.h> -#include <linux/pm_qos_params.h> #include "debug.h" #include "common.h" @@ -57,8 +56,6 @@ struct ath_node;#define A_MAX (a, b) ((a)> (b) ? (a) : (b)) -#define ATH9K_PM_QOS_DEFAULT_VALUE 55 -#define TSF_TO_TU (_h,_l) \ ((((u32)(_h))<< 22) | (((u32)(_l))>> 10))@@ -650,7 +647,6 @@ struct ath_softc {struct ath_ant_comb ant_comb; -struct pm_qos_request_list pm_qos_req; };void ath9k_tasklet (unsigned long data);@@ -665,7 +661,6 @@ static inline void ath_read_cachesize(struct ath_common *common, int *csz) extern struct ieee80211_ops ath9k_ops;extern int ath9k_modparam_nohwcrypt;extern int led_blink; -extern int ath9k_pm_qos_value;extern bool is_ath9k_unloaded;
irqreturn_tath_isr(int irq, void *dev);drivers/net/wireless/ath/ath9k/init.c +0
-3@@ -41,9 +41,6 @@ static int ath9k_btcoex_enable;module_param_named (btcoex_enable, ath9k_btcoex_enable, int,0444 );MODULE_PARM_DESC (btcoex_enable,"Enable wifi-BT coexistence" ); -int ath9k_pm_qos_value =ATH9K_PM_QOS_DEFAULT_VALUE ; -module_param_named (pmqos, ath9k_pm_qos_value, int,S_IRUSR | S_IRGRP | S_IROTH); -MODULE_PARM_DESC (pmqos,"User specified PM-QOS value" );bool is_ath9k_unloaded;/* We use the
hw_valueas an index into our private channel
structure */drivers/net/wireless/ath/ath9k/init.c +0
-3@@ -760,9 +757,6 @@ int ath9k_init_device(u16 devid, struct ath_softc *sc, u16 subsysid,ath_init_leds (sc );ath_start_rfkill_poll (sc); -pm_qos_add_request (&sc->pm_qos_req,PM_QOS_CPU_DMA_LATENCY , -PM_QOS_DEFAULT_VALUE ); -return 0 ;
error_world:drivers/net/wireless/ath/ath9k/init.c +0
-1@@ -819,7 +813,6 @@ void ath9k_deinit_device(struct ath_softc *sc)ath9k_ps_restore (sc);ieee80211_unregister_hw (hw); -pm_qos_remove_request (&sc->pm_qos_req);ath_rx_cleanup (sc);ath_tx_cleanup (sc);ath9k_deinit_softc (sc);drivers/net/wireless/ath/ath9k/main.c +0
-8@@ -1117,12 +1117,6 @@ static int ath9k_start(struct ieee80211_hw *hw)ath9k_btcoex_timer_resume (sc); } -/* User has the option to provide pm-qos value as a module -* parameter rather than using the default value of -* 'ATH9K_PM_QOS_DEFAULT_VALUE'. -*/ -pm_qos_update_request (&sc->pm_qos_req, ath9k_pm_qos_value); -if (ah->caps.pcie_lcr_extsync_en&& common->bus_ops->extn_synch_en) common->bus_ops->extn_synch_en (common);@@ -1267,8 +1261,6 @@ static void ath9k_stop(struct ieee80211_hw *hw) sc->sc_flags |=SC_OP_INVALID ; -pm_qos_update_request (&sc->pm_qos_req,PM_QOS_DEFAULT_VALUE ); -mutex_unlock (&sc->mutex);Quoted 5 lines
Quoted 5 lines
Quoted 5 lines
drivers/net/wireless/ath/ath9k/main.c +0
-0ath_dbg (common,ATH_DBG_CONFIG ,"Driver halt\n" );Signature · 1 line
1.7.0.4--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Signature · 2 lines
John W. Linville Someday the world will need a hero, and you [email protected] might be all we have. Be ready.
Quoted 4 lines · John W. Linville
Quoted 2 lines · Mohammed Shafi
On Wednesday 16 February 2011 10:35 AM, Mohammed Shafi wrote:
Quoted 9 lines
Quoted 7 lines
Quoted 5 lines · John W. Linville
Quoted 4 lines
Despite the [RFC], I am applying this. I should have reverted all of this three weeks ago...
John can you please push this to stable kernel ?
Stable folks, this is the commit in Linus's tree;
Thanks a lot John.
Quoted 175 lines
commit
0f5cd45960173ba5b36727decbb4a241cbd35ef9Author: Mohammed Shafi Shajakhan<[email protected]> Date: Tue Feb 15 21:29:32 2011 +0530ath9k: Fix ath9k prevents CPU to enter C3 states
The DMA latency issue is observed only in Intel pinetrail platforms but in the driver we had a default PM-QOS value of 55. This caused unnecessary power consumption and battery drain in other platforms.
Remove the pm-qos thing in the driver code and address the throughput issue in Intel pinetrail platfroms in user space using any one of the scripts in below links:
http://www.kernel.org/pub/linux/kernel/people/mcgrof/scripts/cpudmalatency.c
http://johannes.sipsolutions.net/files/netlatency.c.txtMore details can be found in the following bugzilla link:
https://bugzilla.kernel.org/show_bug.cgi?id=27532
This reverts the following commits:
98c316e348bedffa730e6f1e4baeb8a3c3e0f28b
4dc3530df7c0428b41c00399a7ee8c929406d181
10598c124ecabbbfd7522f74de19b8f7d52a1beeSigned-off-by Mohammed Shafi Shajakhan<[email protected]>Signed-off-by John W. Linville<[email protected]>Quoted 143 lines
Quoted 131 lines
Thanks John.
Quoted 129 lines
John
Quoted 124 lines · Mohammed Shafi Shajakhan
From: Mohammed Shafi Shajakhan<[email protected]>
The DMA latency issue is observed only in Intel pinetrail platforms but in the driver we had a default PM-QOS value of 55. This caused unnecessary power consumption and battery drain in other platforms.
Remove the pm-qos thing in the driver code and address the
throughput issue in
Intel pinetrail platfroms in user space using any one of the scripts in below links:
http://www.kernel.org/pub/linux/kernel/people/mcgrof/scripts/cpudmalatency.chttp://johannes.sipsolutions.net/files/netlatency.c.txt
More details can be found in the following bugzilla link:
https://bugzilla.kernel.org/show_bug.cgi?id=27532Signed-off-by Mohammed Shafi Shajakhan<[email protected]>--- drivers/net/wireless/ath/ath9k/ath9k.h | 5 ----- drivers/net/wireless/ath/ath9k/init.c | 7 ------- drivers/net/wireless/ath/ath9k/main.c | 8 -------- 3 files changed, 0 insertions(+), 20 deletions(-)drivers/net/wireless/ath/ath9k/ath9k.h +0
-5@@ -21,7 +21,6 @@#include <linux/device.h> #include <linux/leds.h> #include <linux/completion.h> -#include <linux/pm_qos_params.h> #include "debug.h" #include "common.h" @@ -57,8 +56,6 @@ struct ath_node;#define A_MAX (a, b) ((a)> (b) ? (a) : (b)) -#define ATH9K_PM_QOS_DEFAULT_VALUE 55 -#define TSF_TO_TU (_h,_l) \ ((((u32)(_h))<< 22) | (((u32)(_l))>> 10))@@ -650,7 +647,6 @@ struct ath_softc {struct ath_ant_comb ant_comb; -struct pm_qos_request_list pm_qos_req; };void ath9k_tasklet (unsigned long data);@@ -665,7 +661,6 @@ static inline void ath_read_cachesize(struct ath_common *common, int *csz) extern struct ieee80211_ops ath9k_ops;extern int ath9k_modparam_nohwcrypt;extern int led_blink; -extern int ath9k_pm_qos_value;extern bool is_ath9k_unloaded;irqreturn_t ath_isr(int irq, void *dev);drivers/net/wireless/ath/ath9k/init.c +0
-3@@ -41,9 +41,6 @@ static int ath9k_btcoex_enable;module_param_named (btcoex_enable, ath9k_btcoex_enable, int,0444 );MODULE_PARM_DESC (btcoex_enable,"Enable wifi-BT coexistence" ); -int ath9k_pm_qos_value =ATH9K_PM_QOS_DEFAULT_VALUE ; -module_param_named (pmqos, ath9k_pm_qos_value, int,S_IRUSR | S_IRGRP | S_IROTH); -MODULE_PARM_DESC (pmqos,"User specified PM-QOS value" );bool is_ath9k_unloaded;/* We use the
hw_valueas an index into our private channel
structure */drivers/net/wireless/ath/ath9k/init.c +0
-3@@ -760,9 +757,6 @@ int ath9k_init_device(u16 devid, struct ath_softc *sc, u16 subsysid,ath_init_leds (sc );ath_start_rfkill_poll (sc); -pm_qos_add_request (&sc->pm_qos_req,PM_QOS_CPU_DMA_LATENCY , -PM_QOS_DEFAULT_VALUE ); -return 0 ;
error_world:drivers/net/wireless/ath/ath9k/init.c +0
-1@@ -819,7 +813,6 @@ void ath9k_deinit_device(struct ath_softc *sc)ath9k_ps_restore (sc);ieee80211_unregister_hw (hw); -pm_qos_remove_request (&sc->pm_qos_req);ath_rx_cleanup (sc);ath_tx_cleanup (sc);ath9k_deinit_softc (sc);drivers/net/wireless/ath/ath9k/main.c +0
-8@@ -1117,12 +1117,6 @@ static int ath9k_start(struct ieee80211_hw *hw)ath9k_btcoex_timer_resume (sc); } -/* User has the option to provide pm-qos value as a module -* parameter rather than using the default value of -* 'ATH9K_PM_QOS_DEFAULT_VALUE'. -*/ -pm_qos_update_request (&sc->pm_qos_req, ath9k_pm_qos_value); -if (ah->caps.pcie_lcr_extsync_en&& common->bus_ops->extn_synch_en) common->bus_ops->extn_synch_en (common);@@ -1267,8 +1261,6 @@ static void ath9k_stop(struct ieee80211_hw *hw) sc->sc_flags |=SC_OP_INVALID ; -pm_qos_update_request (&sc->pm_qos_req,PM_QOS_DEFAULT_VALUE ); -mutex_unlock (&sc->mutex);Quoted 6 lines
Quoted 6 lines
Quoted 6 lines
drivers/net/wireless/ath/ath9k/main.c +0
-0ath_dbg (common,ATH_DBG_CONFIG ,"Driver halt\n" );Signature · 1 line
1.7.0.4--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in the body of a message to [email protected]
More majordomo info at http://vger.kernel.org/majordomo-info.html
Quoted 10 lines · John W. Linville
Quoted 5 lines · Mohammed Shafi
Quoted 3 lines · Mohammed Shafi
Quoted 2 lines · John W. Linville
Despite the [RFC], I am applying this. I should have reverted all of this three weeks ago...
John can you please push this to stable kernel ?
Stable folks, this is the commit in Linus's tree;
commit
0f5cd45960173ba5b36727decbb4a241cbd35ef9
Too bad this commit doesn't apply to the .37-stable tree :(
Can someone provide [email protected] a backported version of this?
thanks,
greg k-h
PATCH 1/1 ath9k: Fix ath9k prevents CPU to enter C3 states
This is a backport of upstream commit 0f5cd45960173ba5b36727decbb4a241cbd35ef9.
The DMA latency issue is observed only in Intel pinetrail platforms but in the driver we had a default PM-QOS value of 55. This caused unnecessary power consumption and battery drain in other platforms.
Remove the pm-qos thing in the driver code and address the throughput issue in Intel pinetrail platfroms in user space using any one of the scripts in below links:
http://www.kernel.org/pub/linux/kernel/people/mcgrof/scripts/cpudmalatency.c
http://johannes.sipsolutions.net/files/netlatency.c.txt
More details can be found in the following bugzilla link:
https://bugzilla.kernel.org/show_bug.cgi?id=27532
---
I hope this is right, it seems to work for me.
Luis or John, can you sign off on this just
to be sure?
drivers/net/wireless/ath/ath9k/ath9k.h | 3 --- drivers/net/wireless/ath/ath9k/init.c | 4 ---- drivers/net/wireless/ath/ath9k/main.c | 4 ---- 3 files changed, 0 insertions(+), 11 deletions(-)
drivers/net/wireless/ath/ath9k/ath9k.h +0 -3
@@ -21,7 +21,6 @@#include <linux/device.h> #include <linux/leds.h> #include <linux/completion.h> -#include <linux/pm_qos_params.h> #include "debug.h" #include "common.h"
@@ -647,8 +646,6 @@ struct ath_softc {struct ath_descdma txsdma;struct ath_ant_comb ant_comb; - -struct pm_qos_request_list pm_qos_req; };struct ath_wiphy {
drivers/net/wireless/ath/ath9k/init.c +0 -4
@@ -758,9 +758,6 @@ int ath9k_init_device(u16 devid, struct ath_softc *sc, u16 subsysid,ath_init_leds (sc);ath_start_rfkill_poll (sc); -pm_qos_add_request (&sc->pm_qos_req,PM_QOS_CPU_DMA_LATENCY , -PM_QOS_DEFAULT_VALUE ); -return 0 ; error_world:
@@ -829,7 +826,6 @@ void ath9k_deinit_device(struct ath_softc *sc) }ieee80211_unregister_hw (hw); -pm_qos_remove_request (&sc->pm_qos_req);ath_rx_cleanup (sc);ath_tx_cleanup (sc);ath9k_deinit_softc (sc);
drivers/net/wireless/ath/ath9k/main.c +0 -4
@@ -1245,8 +1245,6 @@ static int ath9k_start(struct ieee80211_hw *hw)ath9k_btcoex_timer_resume (sc); } -pm_qos_update_request (&sc->pm_qos_req,55 ); - mutex_unlock:mutex_unlock (&sc->mutex);
@@ -1425,8 +1423,6 @@ static void ath9k_stop(struct ieee80211_hw *hw) sc->sc_flags |=SC_OP_INVALID ; -pm_qos_update_request (&sc->pm_qos_req,PM_QOS_DEFAULT_VALUE ); -mutex_unlock (&sc->mutex);ath_print (common,ATH_DBG_CONFIG ,"Driver halt\n" );
Signature · 1 line
1.7.4.1
Quoted 87 lines · Thomas Bächler
This is a backport of upstream commit
0f5cd45960173ba5b36727decbb4a241cbd35ef9.The DMA latency issue is observed only in Intel pinetrail platforms but in the driver we had a default PM-QOS value of 55. This caused unnecessary power consumption and battery drain in other platforms.
Remove the pm-qos thing in the driver code and address the throughput issue in Intel pinetrail platfroms in user space using any one of the scripts in below links:
http://www.kernel.org/pub/linux/kernel/people/mcgrof/scripts/cpudmalatency.c
http://johannes.sipsolutions.net/files/netlatency.c.txtMore details can be found in the following bugzilla link:
https://bugzilla.kernel.org/show_bug.cgi?id=27532
Signed-off-by Thomas Bächler<[email protected]>---
I hope this is right, it seems to work for me.
Luis or John, can you sign off on this just
to be sure?drivers/net/wireless/ath/ath9k/ath9k.h | 3 --- drivers/net/wireless/ath/ath9k/init.c | 4 ---- drivers/net/wireless/ath/ath9k/main.c | 4 ---- 3 files changed, 0 insertions(+), 11 deletions(-)drivers/net/wireless/ath/ath9k/ath9k.h +0
-3@@ -21,7 +21,6 @@#include <linux/device.h> #include <linux/leds.h> #include <linux/completion.h> -#include <linux/pm_qos_params.h> #include "debug.h" #include "common.h" @@ -647,8 +646,6 @@ struct ath_softc {struct ath_descdma txsdma;struct ath_ant_comb ant_comb; - -struct pm_qos_request_list pm_qos_req; };struct ath_wiphy {drivers/net/wireless/ath/ath9k/init.c +0
-4@@ -758,9 +758,6 @@ int ath9k_init_device(u16 devid, struct ath_softc *sc, u16 subsysid,ath_init_leds (sc);ath_start_rfkill_poll (sc); -pm_qos_add_request (&sc->pm_qos_req,PM_QOS_CPU_DMA_LATENCY , -PM_QOS_DEFAULT_VALUE ); -return 0 ; error_world:@@ -829,7 +826,6 @@ void ath9k_deinit_device(struct ath_softc *sc) }ieee80211_unregister_hw (hw); -pm_qos_remove_request (&sc->pm_qos_req);ath_rx_cleanup (sc);ath_tx_cleanup (sc);ath9k_deinit_softc (sc);drivers/net/wireless/ath/ath9k/main.c +0
-2@@ -1245,8 +1245,6 @@ static int ath9k_start(struct ieee80211_hw *hw)ath9k_btcoex_timer_resume (sc); } -pm_qos_update_request (&sc->pm_qos_req,55 ); - mutex_unlock:mutex_unlock (&sc->mutex);
drivers/net/wireless/ath/ath9k/main.c static void ath9k_stop(struct ieee80211_hw *hw) · line 1428
Quoted 8 lines
drivers/net/wireless/ath/ath9k/main.c +0
-2@@ -1425,8 +1423,6 @@ static void ath9k_stop(struct ieee80211_hw *hw) sc->sc_flags |=SC_OP_INVALID ; -pm_qos_update_request (&sc->pm_qos_req,PM_QOS_DEFAULT_VALUE ); -mutex_unlock (&sc->mutex);ath_print (common,ATH_DBG_CONFIG ,"Driver halt\n" );
Thomas, thanks !
Quoted 11 lines · Greg KH
Quoted 9 lines · John W. Linville
Quoted 7 lines · Mohammed Shafi
Quoted 5 lines · Mohammed Shafi
Quoted 3 lines · John W. Linville
Despite the [RFC], I am applying this. I should have reverted all of this three weeks ago...
Quoted 8 lines
Quoted 6 lines
Quoted 2 lines
John can you please push this to stable kernel ?
Stable folks, this is the commit in Linus's tree;
commit
0f5cd45960173ba5b36727decbb4a241cbd35ef9Too bad this commit doesn't apply to the .37-stable tree :(
This is because of the commit 4dc3530df7c0428b41c00399a7ee8c929406d181. And this is handled by the backport provided by Thomas.
thanks,
shafi
Quoted 8 lines
Can someone provide [email protected] a backported version of this?
thanks,
greg k-h
.