Fixed coding style issues
cover Fixed coding style issues
Fixed warnings and errors generated by checkpatch about missing/extra characters.
After applying this patch, 1 error and 2 warnings don't show up in the file.
Shivani Bhardwaj (2):
Staging: vt6655: rxtx: Removed unnecessary space character
Staging: vt6655: rxtx: Removed unnecessary parentheses
drivers/staging/vt6655/rxtx.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-)
Signature · 1 line
2.1.0
PATCH 1/2 Staging: vt6655: rxtx: Removed unnecessary space character
Fixed the warning generated by checkpatch : space prohibited before that ',' (ctx:WxW) , by removing space character after the variable RATE_16M.
--- drivers/staging/vt6655/rxtx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/staging/vt6655/rxtx.c +1 -1
@@ -78,7 +78,7 @@ static const unsigned short wFB_Opt0[2][5] = { };static const unsigned short wFB_Opt1[2 ][5 ] = { {RATE_12M ,RATE_18M ,RATE_24M ,RATE_24M ,RATE_36M },/* fallback_rate0 */ - {RATE_6M ,RATE_6M ,RATE_12M ,RATE_12M ,RATE_18M },/* fallback_rate1 */ + {RATE_6M ,RATE_6M ,RATE_12M ,RATE_12M ,RATE_18M },/* fallback_rate1 */ };#define RTSDUR_BB 0
Signature · 1 line
2.1.0
PATCH 2/2 Staging: vt6655: rxtx: Removed unnecessary parentheses
In reply to Shivani BhardwajFixed the warning generated by checkpatch: unnecessary parentheses ,by removing extra pair of parentheses from if statements.
--- drivers/staging/vt6655/rxtx.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
drivers/staging/vt6655/rxtx.c +2 -2
@@ -566,7 +566,7 @@ s_uFillDataHead(return buf->duration_a; }/* if (byFBOption == AUTO_FB_NONE) */ }else if (byPktType ==PK_TYPE_11A ) { -if ((byFBOption !=AUTO_FB_NONE )) { +if (byFBOption !=AUTO_FB_NONE ) {/* Auto Fallback */ struct vnt_tx_datahead_a_fb *buf = pTxDataHead;/* Get SignalField, ServiceField & Length */
@@ -1008,7 +1008,7 @@ s_vGenerateTxParameter( buf->rrv_time =vnt_rxtx_rsvtime_le16 (pDevice,PK_TYPE_11A , cbFrameSize, wCurrentRate, bNeedACK); } }else if (byPktType ==PK_TYPE_11B ) { -if ((pvRTS !=NULL )) {/* RTS_need, non PCF mode */ +if (pvRTS !=NULL ) {/* RTS_need, non PCF mode */ struct vnt_rrv_time_ab *buf = pvRrvTime; buf->rts_rrv_time =s_uGetRTSCTSRsvTime (pDevice,0 , byPktType, cbFrameSize, wCurrentRate);
Signature · 1 line
2.1.0
Re: [Outreachy kernel] [PATCH 1/2] Staging: vt6655: rxtx: Removed unnecessary space character
In reply to Shivani BhardwajQuoted 3 lines · Shivani Bhardwaj
Fixed the warning generated by checkpatch : space prohibited before that ',' (ctx:WxW) , by removing space character after the variable
RATE_16M.
Remember to use the imperative, and to avoid making the main point "fix". One wants to know what you did. The justification can come after. So this could be: "Remove space before comma. Fixes checkpatch warning "...""
julia
Quoted 29 lines
Signed-off-by Shivani Bhardwaj <[email protected]>--- drivers/staging/vt6655/rxtx.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)drivers/staging/vt6655/rxtx.c +1
-1@@ -78,7 +78,7 @@ static const unsigned short wFB_Opt0[2][5] = { };static const unsigned short wFB_Opt1[2 ][5 ] = { {RATE_12M ,RATE_18M ,RATE_24M ,RATE_24M ,RATE_36M },/* fallback_rate0 */ - {RATE_6M ,RATE_6M ,RATE_12M ,RATE_12M ,RATE_18M },/* fallback_rate1 */ + {RATE_6M ,RATE_6M ,RATE_12M ,RATE_12M ,RATE_18M },/* fallback_rate1 */ };#define RTSDUR_BB 0Signature · 8 lines
2.1.0 -- You received this message because you are subscribed to the Google Groups "outreachy-kernel" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/3ae4b94df52e3ada9fd74b65178961ac4d185a4c.1444459442.git.shivanib134%40gmail.com. For more options, visit https://groups.google.com/d/optout.
Re: [Outreachy kernel] [PATCH 2/2] Staging: vt6655: rxtx: Removed unnecessary parentheses
In reply to Shivani BhardwajQuoted 2 lines · Shivani Bhardwaj
Fixed the warning generated by checkpatch: unnecessary parentheses ,by removing extra pair of parentheses from if statements.
Same here. Also, it would be more precise to say something like "if tests" or "if test expressions", since it is not the whole statement.
julia
Quoted 38 lines
Signed-off-by Shivani Bhardwaj <[email protected]>--- drivers/staging/vt6655/rxtx.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)drivers/staging/vt6655/rxtx.c +2
-2@@ -566,7 +566,7 @@ s_uFillDataHead(return buf->duration_a; }/* if (byFBOption == AUTO_FB_NONE) */ }else if (byPktType ==PK_TYPE_11A ) { -if ((byFBOption !=AUTO_FB_NONE )) { +if (byFBOption !=AUTO_FB_NONE ) {/* Auto Fallback */ struct vnt_tx_datahead_a_fb *buf = pTxDataHead;/* Get SignalField, ServiceField & Length */ @@ -1008,7 +1008,7 @@ s_vGenerateTxParameter( buf->rrv_time =vnt_rxtx_rsvtime_le16 (pDevice,PK_TYPE_11A , cbFrameSize, wCurrentRate, bNeedACK); } }else if (byPktType ==PK_TYPE_11B ) { -if ((pvRTS !=NULL )) {/* RTS_need, non PCF mode */ +if (pvRTS !=NULL ) {/* RTS_need, non PCF mode */ struct vnt_rrv_time_ab *buf = pvRrvTime; buf->rts_rrv_time =s_uGetRTSCTSRsvTime (pDevice,0 , byPktType, cbFrameSize, wCurrentRate);Signature · 8 lines
2.1.0 -- You received this message because you are subscribed to the Google Groups "outreachy-kernel" group. To unsubscribe from this group and stop receiving emails from it, send an email to [email protected]. To post to this group, send email to [email protected]. To view this discussion on the web visit https://groups.google.com/d/msgid/outreachy-kernel/9c601c11ccb65c7789bb750fd9e357672015bd11.1444459442.git.shivanib134%40gmail.com. For more options, visit https://groups.google.com/d/optout.