From: G Pooja Shamili <poojashamili@gmail.com>
To: outreachy-kernel@googlegroups.com
Subject: [PATCH v2] staging: rtl8712: Remove the unnecessary parantheses
Date: Sun, 6 Mar 2016 14:43:09 +0530 [thread overview]
Message-ID: <20160306091309.GA30726@localhost> (raw)
The unnecessary parantheses on the right side of assignments were remove
as in most cases (expect for ==, >=, <=, !=), they are futile.
This was done using Coccinelle, the semantic patch being:
@@
expression E1,E2,E3;
binary operator bin_op = {==,>=,<=,!=};
@@
E1 =
(
-(
+(
E2 bin_op E3
-)
+)
|
-(
E2
-)
)
;
Signed-off-by: G Pooja Shamili <poojashamili@gmail.com>
---
Changes from Version 1:
* Changed the name in the From: and Signed-off-by: to full
name.
drivers/staging/rtl8712/rtl871x_mlme.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/staging/rtl8712/rtl871x_mlme.c b/drivers/staging/rtl8712/rtl871x_mlme.c
index 1b022db..604ef58 100644
--- a/drivers/staging/rtl8712/rtl871x_mlme.c
+++ b/drivers/staging/rtl8712/rtl871x_mlme.c
@@ -1285,7 +1285,7 @@ sint r8712_set_key(struct _adapter *adapter,
}
pcmd->cmdcode = _SetKey_CMD_;
pcmd->parmbuf = (u8 *)psetkeyparm;
- pcmd->cmdsz = (sizeof(struct setkey_parm));
+ pcmd->cmdsz = sizeof(struct setkey_parm);
pcmd->rsp = NULL;
pcmd->rspsz = 0;
INIT_LIST_HEAD(&pcmd->list);
@@ -1748,8 +1748,8 @@ static void update_ht_cap(struct _adapter *padapter, u8 *pie, uint ie_len)
sizeof(struct NDIS_802_11_FIXED_IEs));
if (p && len > 0) {
pht_capie = (struct ieee80211_ht_cap *)(p + 2);
- max_ampdu_sz = (pht_capie->ampdu_params_info &
- IEEE80211_HT_CAP_AMPDU_FACTOR);
+ max_ampdu_sz = pht_capie->ampdu_params_info &
+ IEEE80211_HT_CAP_AMPDU_FACTOR;
/* max_ampdu_sz (kbytes); */
max_ampdu_sz = 1 << (max_ampdu_sz + 3);
phtpriv->rx_ampdu_maxlen = max_ampdu_sz;
--
2.1.4
next reply other threads:[~2016-03-06 9:13 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-03-06 9:13 G Pooja Shamili [this message]
2016-03-06 9:19 ` [Outreachy kernel] [PATCH v2] staging: rtl8712: Remove the unnecessary parantheses Julia Lawall
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20160306091309.GA30726@localhost \
--to=poojashamili@gmail.com \
--cc=outreachy-kernel@googlegroups.com \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.