[PATCH 3/3] staging: rtl8188eu: rename variable isCCKrate - style

Joe Perches joe at perches.com
Sun Oct 21 12:26:52 UTC 2018


On Sat, 2018-10-20 at 13:08 +0200, Michael Straube wrote:
> Rename the variable isCCKrate to avoid CamelCase.
> isCCKrate -> is_cck_rate
[]
> diff --git a/drivers/staging/rtl8188eu/hal/odm_hwconfig.c b/drivers/staging/rtl8188eu/hal/odm_hwconfig.c
[]
> @@ -71,19 +71,20 @@ static void odm_RxPhyStatus92CSeries_Parsing(struct odm_dm_struct *dm_odm,
>  	s8 rx_pwr[4], rx_pwr_all = 0;
>  	u8 EVM, PWDB_ALL = 0, PWDB_ALL_BT;
>  	u8 RSSI, total_rssi = 0;
> -	u8 isCCKrate = 0;
> +	u8 is_cck_rate = 0;
>  	u8 rf_rx_num = 0;
>  	u8 cck_highpwr = 0;
>  	u8 LNA_idx, VGA_idx;
>  
>  	struct phy_status_rpt *pPhyStaRpt = (struct phy_status_rpt *)pPhyStatus;
>  
> -	isCCKrate = ((pPktinfo->Rate >= DESC92C_RATE1M) && (pPktinfo->Rate <= DESC92C_RATE11M)) ? true : false;
> +	is_cck_rate = ((pPktinfo->Rate >= DESC92C_RATE1M) &&
> +		       (pPktinfo->Rate <= DESC92C_RATE11M)) ? true : false;

It would be sensible to convert is_cck_rate from u8 to bool at the
same
time and remove the ternary ? true : false too.

As well, perhaps remove its apparently unnecessary initialization.




More information about the devel mailing list