diff options
author | Sujith <Sujith.Manoharan@atheros.com> | 2009-08-26 01:41:57 -0400 |
---|---|---|
committer | John W. Linville <linville@tuxdriver.com> | 2009-08-28 14:40:48 -0400 |
commit | 7cf4a2e778ab18c66cd8dd4785aceb2800d49f79 (patch) | |
tree | 1c13278e7b802fc00bf1e3361b48f95d5dd9d33f /drivers/net/wireless/ath/ath9k/debug.c | |
parent | b264c673a03329b5e5bab79b705b5bb5ab1fe965 (diff) |
ath9k: Wrap DMA dump function with PS wakeup/restore
When dumping register contents, HW has to be awake.
Signed-off-by: Sujith <Sujith.Manoharan@atheros.com>
Signed-off-by: John W. Linville <linville@tuxdriver.com>
Diffstat (limited to 'drivers/net/wireless/ath/ath9k/debug.c')
-rw-r--r-- | drivers/net/wireless/ath/ath9k/debug.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/drivers/net/wireless/ath/ath9k/debug.c b/drivers/net/wireless/ath/ath9k/debug.c index 9e369208f7dc..2be4c2252047 100644 --- a/drivers/net/wireless/ath/ath9k/debug.c +++ b/drivers/net/wireless/ath/ath9k/debug.c | |||
@@ -93,6 +93,8 @@ static ssize_t read_file_dma(struct file *file, char __user *user_buf, | |||
93 | int i, qcuOffset = 0, dcuOffset = 0; | 93 | int i, qcuOffset = 0, dcuOffset = 0; |
94 | u32 *qcuBase = &val[0], *dcuBase = &val[4]; | 94 | u32 *qcuBase = &val[0], *dcuBase = &val[4]; |
95 | 95 | ||
96 | ath9k_ps_wakeup(sc); | ||
97 | |||
96 | REG_WRITE(ah, AR_MACMISC, | 98 | REG_WRITE(ah, AR_MACMISC, |
97 | ((AR_MACMISC_DMA_OBS_LINE_8 << AR_MACMISC_DMA_OBS_S) | | 99 | ((AR_MACMISC_DMA_OBS_LINE_8 << AR_MACMISC_DMA_OBS_S) | |
98 | (AR_MACMISC_MISC_OBS_BUS_1 << | 100 | (AR_MACMISC_MISC_OBS_BUS_1 << |
@@ -159,6 +161,8 @@ static ssize_t read_file_dma(struct file *file, char __user *user_buf, | |||
159 | len += snprintf(buf + len, sizeof(buf) - len, | 161 | len += snprintf(buf + len, sizeof(buf) - len, |
160 | "AR_CR: 0x%x \n", REG_READ(ah, AR_CR)); | 162 | "AR_CR: 0x%x \n", REG_READ(ah, AR_CR)); |
161 | 163 | ||
164 | ath9k_ps_restore(sc); | ||
165 | |||
162 | return simple_read_from_buffer(user_buf, count, ppos, buf, len); | 166 | return simple_read_from_buffer(user_buf, count, ppos, buf, len); |
163 | } | 167 | } |
164 | 168 | ||