[PATCH 1/2] ath10k: Define an enum to enable cycle counter wraparound logic

Valo, Kalle kvalo at qca.qualcomm.com
Sat Jun 4 07:53:54 PDT 2016


Vasanthakumar Thiagarajan <vthiagar at qti.qualcomm.com> writes:

> QCA988X hw implements a different cycle counter wraparound
> behaviour when compared to QCA4019. To properly handle different
> wraparound logic for these chipsets replace already available
> bool hw_params member, has_shifted_cc_wraparound, with an
> enum which could be extended to handle different wraparound
> behaviour. This patch keeps the existing logic functionally
> same and a prepares cycle counter wraparound handling to
> extend for other chips.
>
> Signed-off-by: Vasanthakumar Thiagarajan <vthiagar at qti.qualcomm.com>

[...]

> --- a/drivers/net/wireless/ath/ath10k/core.c
> +++ b/drivers/net/wireless/ath/ath10k/core.c
> @@ -55,7 +55,7 @@ static const struct ath10k_hw_params ath10k_hw_params_list[] = {
>  		.name = "qca988x hw2.0",
>  		.patch_load_addr = QCA988X_HW_2_0_PATCH_LOAD_ADDR,
>  		.uart_pin = 7,
> -		.has_shifted_cc_wraparound = true,
> +		.cc_wraparound_type = ATH10K_HW_CC_WRAP_SHIFTED_ALL,
>  		.otp_exe_param = 0,
>  		.channel_counters_freq_hz = 88000,
>  		.max_probe_resp_desc_thres = 0,
> @@ -224,7 +224,7 @@ static const struct ath10k_hw_params ath10k_hw_params_list[] = {
>  		.name = "qca4019 hw1.0",
>  		.patch_load_addr = QCA4019_HW_1_0_PATCH_LOAD_ADDR,
>  		.uart_pin = 7,
> -		.has_shifted_cc_wraparound = true,
> +		.cc_wraparound_type = ATH10K_HW_CC_WRAP_SHIFTED_ALL,
>  		.otp_exe_param = 0x0010000,
>  		.continuous_frag_desc = true,
>  		.channel_counters_freq_hz = 125000,

As the pending branch has the QCA9887 patch I added
ATH10K_HW_CC_WRAP_SHIFTED_ALL also for QCA9887. Please review my changes
in the pending branch:

https://git.kernel.org/cgit/linux/kernel/git/kvalo/ath.git/commit/?h=pending&id=2fa32dbd9f26e8b2f323ca30ad116ea486840aba

-- 
Kalle Valo


More information about the ath10k mailing list