History log of /linux-master/drivers/net/wireless/ath/ath9k/ar9003_aic.c
Revision Date Author Comments
# d27c768f 24-Dec-2019 zhengbin <zhengbin13@huawei.com>

ath9k: use true,false for bool variable

Fixes coccicheck warning:

drivers/net/wireless/ath/ath9k/ar9003_aic.c:409:2-12: WARNING: Assignment of 0/1 to bool variable

Reported-by: Hulk Robot <hulkci@huawei.com>
Signed-off-by: zhengbin <zhengbin13@huawei.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>


# e9a26010 11-Feb-2016 Arnd Bergmann <arnd@arndb.de>

ath9k: reduce stack usage in ar9003_aic_cal_post_process

In some configurations, this function uses more than the warning limit
of 1024 bytes:

drivers/net/wireless/ath/ath9k/ar9003_aic.c: In function 'ar9003_aic_cal_post_process':
drivers/net/wireless/ath/ath9k/ar9003_aic.c:434:1: error: the frame size of 1040 bytes is larger than 1024 bytes [-Werror=frame-larger-than=]

It turns out that there are two large arrays on the stack here, but
almost all the data in them is never used outside of the loop in
which it gets written, so we can replace the array with a single
instance.

The .valid flag is used later, so I'm replacing the array of structures
with an array of bools. An obvious follow-up optimization would be
to replace it with a bitmask and set_bit()/find_first_bit()/
find_last_bit()/... operations. However, I have not tested this patch,
so I sticked to the simpler transformation that does the job of
reducing the stack usage to a harmless level.

Signed-off-by: Arnd Bergmann <arnd@arndb.de>
Signed-off-by: Kalle Valo <kvalo@qca.qualcomm.com>


# 60544603 13-Mar-2015 Sujith Manoharan <c_manoha@qca.qualcomm.com>

ath9k: Handle MCI_STATE_AIC_CAL

Add the main AIC calibration function to
handle MCI_STATE_AIC_CAL.

Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>


# f2ef792a 13-Mar-2015 Sujith Manoharan <c_manoha@qca.qualcomm.com>

ath9k: Handle MCI_STATE_AIC_START

This patch adds a function to handle the
MCI message MCI_STATE_AIC_START.

Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>


# 958b6827 13-Mar-2015 Sujith Manoharan <c_manoha@qca.qualcomm.com>

ath9k: Handle MCI_STATE_AIC_CAL_RESET

Add a routine to handle the MCI_STATE_AIC_CAL_RESET
message.

Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>


# 208837ee 13-Mar-2015 Sujith Manoharan <c_manoha@qca.qualcomm.com>

ath9k: Disable AIC by default

Since various MCI messages need to be
handled, along with driver-level support
in upper layers, disable AIC for now.

Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>


# 188f1a12 13-Mar-2015 Sujith Manoharan <c_manoha@qca.qualcomm.com>

ath9k: Process the AIC calibration results

This patch adds support for post-processing
the AIC calibration results.

Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>


# 716eed4c 13-Mar-2015 Sujith Manoharan <c_manoha@qca.qualcomm.com>

ath9k: Finish AIC calibration

Set the appropriate bits in the HW after
AIC calibration is done.

Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>


# b6ab9ae2 13-Mar-2015 Sujith Manoharan <c_manoha@qca.qualcomm.com>

ath9k: Handle MCI_STATE_AIC_CAL_SINGLE

This patch adds routines to handle the MCI
message AIC_CAL_SINGLE, starting the required
HW calibration.

Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>


# 6dacafea 13-Mar-2015 Sujith Manoharan <c_manoha@qca.qualcomm.com>

ath9k: Add register definitions for AIC

Various registers to control and check AIC
status.

Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>


# 637625f2 13-Mar-2015 Sujith Manoharan <c_manoha@qca.qualcomm.com>

ath9k: Register private AIC ops

AIC can be disabled or enabled on a per-card
basis using MCI configuration, so register a function
to check its status.

Signed-off-by: Sujith Manoharan <c_manoha@qca.qualcomm.com>
Signed-off-by: Kalle Valo <kvalo@codeaurora.org>