All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] [Outreachy kernel] staging: rtlwifi: Remove unnecessary parentheses
@ 2019-03-30  5:39 Payal Kshirsagar
  0 siblings, 0 replies; only message in thread
From: Payal Kshirsagar @ 2019-03-30  5:39 UTC (permalink / raw)
  To: outreachy-kernel; +Cc: Payal Kshirsagar

Challenge suggested by coccinelle.
Remove unnecessary parentheses around the right hand side of an
assignment.

Signed-off-by: Payal Kshirsagar <payal.s.kshirsagar.98@gmail.com>
---
 drivers/staging/rtlwifi/phydm/phydm.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/staging/rtlwifi/phydm/phydm.c b/drivers/staging/rtlwifi/phydm/phydm.c
index 52b85b3..473eeb6 100644
--- a/drivers/staging/rtlwifi/phydm/phydm.c
+++ b/drivers/staging/rtlwifi/phydm/phydm.c
@@ -1542,7 +1542,7 @@ static void phydm_set_csi_mask_reg(void *dm_void, u32 tone_idx_tmp,
 
 	if (tone_direction == FREQ_POSITIVE) {
 		if (tone_idx_tmp >= (tone_num - 1))
-			tone_idx_tmp = (tone_num - 1);
+			tone_idx_tmp = tone_num - 1;
 
 		byte_offset = (u8)(tone_idx_tmp >> 3);
 		bit_offset = (u8)(tone_idx_tmp & 0x7);
@@ -1767,7 +1767,7 @@ static u8 phydm_calculate_intf_distance(void *dm_void, u32 bw, u32 fc,
 		int_distance = (fc >= f_interference) ? (fc - f_interference) :
 							(f_interference - fc);
 		tone_idx_tmp =
-			(int_distance << 5); /* =10*(int_distance /0.3125) */
+			int_distance << 5; /* =10*(int_distance /0.3125) */
 		ODM_RT_TRACE(
 			dm, ODM_COMP_API,
 			"int_distance = ((%d MHz)) Mhz, tone_idx_tmp = ((%d.%d))\n",
-- 
2.7.4



^ permalink raw reply related	[flat|nested] only message in thread

only message in thread, other threads:[~2019-03-30  5:39 UTC | newest]

Thread overview: (only message) (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2019-03-30  5:39 [PATCH] [Outreachy kernel] staging: rtlwifi: Remove unnecessary parentheses Payal Kshirsagar

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.