[PATCH v4] Staging: ccree: Merge assignment with return

2017-09-09 Thread Srishti Sharma
Merge the assignment and the return statements to return the value directly. Done using coccinelle. @@ local idexpression ret; expression e; @@ -ret = +return e; -return ret; Signed-off-by: Srishti Sharma --- Changes in v4: -Edit commit message so that it respects

Re: [Outreachy kernel] [PATCH v3] Staging: ccree: Merge assignment with return

2017-09-09 Thread Srishti Sharma
On Sat, Sep 9, 2017 at 12:26 PM, Julia Lawall wrote: > > > On Sat, 9 Sep 2017, Srishti Sharma wrote: > >> Merge the assignment and return statements to return the value >> directly. Done using coccinelle. >> >> @@ >> local idexpression ret; >> expression e; >> @@ >> >> -ret

Re: [Outreachy kernel] [PATCH] Staging: ccree: Merge assignment with return

2017-09-09 Thread Julia Lawall
On Sat, 9 Sep 2017, Srishti Sharma wrote: > Merge the assignment and return statements to return the value > directly. Done using coccinelle. Coccinelle is not always perfect about pretty printing, so you have to watch out for it. > > @@ > local idexpression ret; > expression e; > @@ > > -ret

Re: [Outreachy kernel] [PATCH v4] Staging: ccree: Merge assignment with return

2017-09-09 Thread Julia Lawall
On Sat, 9 Sep 2017, Srishti Sharma wrote: > Merge the assignment and the return statements to return the value > directly. Done using coccinelle. > > @@ > local idexpression ret; > expression e; > @@ > > -ret = > +return > e; > -return ret; > > Signed-off-by: Srishti Sharma

[PATCH v2] Staging: ccree: Merge assignment with return

2017-09-09 Thread Srishti Sharma
Merge the assignment and return statements to return the value directly. Done using the following semantic patch by coccinelle. @@ local idexpression ret; expression e; @@ -ret = +return e; -return ret; Signed-off-by: Srishti Sharma --- Changes in v2: -Correct

Re: [Outreachy kernel] [PATCH] Staging: ccree: Merge assignment with return

2017-09-09 Thread Srishti Sharma
On Sat, Sep 9, 2017 at 10:29 PM, Julia Lawall wrote: > > > On Sat, 9 Sep 2017, Srishti Sharma wrote: > >> Merge the assignment and return statements to return the value >> directly. Done using coccinelle. > > Coccinelle is not always perfect about pretty printing, so you

Re: [PATCH 7/8] staging: ccree: replace noop macro with inline

2017-09-09 Thread Dan Carpenter
On Sun, Sep 03, 2017 at 11:56:49AM +0300, Gilad Ben-Yossef wrote: > Replace noop macro with a noop inline function > > Signed-off-by: Gilad Ben-Yossef > --- > drivers/staging/ccree/ssi_driver.h | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git

[PATCH] Staging: ccree: Merge assignment with return

2017-09-09 Thread Srishti Sharma
Merge the assignment and return statements to return the value directly. Done using coccinelle. @@ local idexpression ret; expression e; @@ -ret = +return e; -return ret; Signed-off-by: Srishti Sharma --- drivers/staging/ccree/ssi_sysfs.c | 4 +--- 1 file changed,

Re: [Outreachy kernel] [PATCH v3] Staging: ccree: Merge assignment with return

2017-09-09 Thread Julia Lawall
On Sat, 9 Sep 2017, Srishti Sharma wrote: > Merge the assignment and return statements to return the value > directly. Done using coccinelle. > > @@ > local idexpression ret; > expression e; > @@ > > -ret = > +return > e; > -return ret; > > Signed-off-by: Srishti Sharma