Search Linux Wireless

Re: [PATCH 08/31] iwlwifi: mvm: rs: print single stream params via debugfs

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sun, 2015-03-01 at 21:31 +0200, Emmanuel Grumbach wrote:
> From: Eyal Shapira <eyal@xxxxxxxxxx>
> 
> Add this to the info printed when reading rate_scale_table.
> Useful for debugging.
[]
> diff --git a/drivers/net/wireless/iwlwifi/mvm/rs.c b/drivers/net/wireless/iwlwifi/mvm/rs.c
[]
> @@ -3369,6 +3370,16 @@ static ssize_t rs_sta_dbgfs_scale_table_read(struct file *file,
>  			lq_sta->lq.agg_frame_cnt_limit);
>  
>  	desc += sprintf(buff+desc, "reduced tpc=%d\n", lq_sta->lq.reduced_tpc);
> +	ss_params = le32_to_cpu(lq_sta->lq.ss_params);
> +	desc += sprintf(buff+desc, "single stream params: %s%s%s%s\n",
> +			(ss_params & LQ_SS_PARAMS_VALID) ?
> +			"VALID," : "INVALID",
> +			(ss_params & LQ_SS_BFER_ALLOWED) ?
> +			"BFER," : "",
> +			(ss_params & LQ_SS_STBC_1SS_ALLOWED) ?
> +			"STBC," : "",
> +			(ss_params & LQ_SS_FORCE) ?
> +			"FORCE" : "");

Are all things exclusive?
If no, the output is not easily readable.

It would probably be better to use:
12345678901234567890123456789012345678901234567890123456789012345678901234567890
	desc += sprintf(buff+desc, "single stream params: %s%s%s%s\n",
			(ss_params & LQ_SS_PARAMS_VALID) ?
			"VALID" : "INVALID",
			(ss_params & LQ_SS_BFER_ALLOWED) ?
			", BFER" : "",
			(ss_params & LQ_SS_STBC_1SS_ALLOWED) ?
			", STBC" : "",
			(ss_params & LQ_SS_FORCE) ?
			", FORCE" : "");


--
To unsubscribe from this list: send the line "unsubscribe linux-wireless" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Linux Host AP]     [ATH6KL]     [Linux Wireless Personal Area Network]     [Linux Bluetooth]     [Linux Netdev]     [Kernel Newbies]     [Linux Kernel]     [IDE]     [Git]     [Netfilter]     [Bugtraq]     [Yosemite Hiking]     [MIPS Linux]     [ARM Linux]     [Linux RAID]

  Powered by Linux