Author: Fengguang Wu <fengguang.wu@intel.com> arch/x86/platform/intel-quark/imr.c:129:1-4: WARNING: end returns can be simpified Simplify a trivial if-return sequence. Possibly combine with a preceding function call. Generated by: scripts/coccinelle/misc/simple_return.cocci Signed-off-by: Fengguang Wu Cc: Andy Shevchenko Cc: Ong, Boon Leong Cc: Bryan O’Donoghue Cc: Darren Hart Cc: kbuild-all@01.org Link: http://lkml.kernel.org/r/20150219081432.GA21996@waimea Signed-off-by: Ingo Molnar — arch/x86/platform/intel-quark/imr.c | 6 +—– 1 …
Catégorie : Linux
Feb 19 2015
x86/intel/quark: Fix ptr_ret.cocci warnings
Author: Fengguang Wu <fengguang.wu@intel.com> arch/x86/platform/intel-quark/imr.c:280:1-3: WARNING: PTR_ERR_OR_ZERO can be used Use PTR_ERR_OR_ZERO rather than if(IS_ERR(…)) + PTR_ERR Generated by: scripts/coccinelle/api/ptr_ret.cocci Signed-off-by: Fengguang Wu Cc: Andy Shevchenko Cc: Ong, Boon Leong Cc: Bryan O’Donoghue Cc: Darren Hart Cc: kbuild-all@01.org Link: http://lkml.kernel.org/r/20150219081432.GA21983@waimea Signed-off-by: Ingo Molnar — arch/x86/platform/intel-quark/imr.c | 5 +—- 1 file changed, 1 insertion(+), 4 deletions(-) …
Feb 19 2015
staging: slicloss: replace init_timer by setup_timer
Author: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com> This patch replaces init_timer and the 2 step initialization of function and data by setup_timer to make the code more concise. The issue was discovered using the following coccinelle script: @@ expression ds, e1, e2; @@ -init_timer (&ds); +setup_timer (&ds, e1, e2); … ( -ds.function = e1; … -ds.data = e2; …
Feb 19 2015
staging: rtl8192u: ieee80211: replace init_timer by setup_timer
Author: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com> This patch replaces init_timer and the 2 step initialization of function and data by setup_timer to make the code more concise. The issue was discovered using the following coccinelle script: @@ expression ds, e1, e2; @@ -init_timer (&ds); +setup_timer (&ds, e1, e2); … ( -ds.function = e1; … -ds.data = e2; …
Feb 19 2015
staging: panel: replace init_timer by setup_timer
Author: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com> This patch replaces init_timer and the 2 step initialization of function and data by setup_timer to make the code more concise. The issue was discovered using the following coccinelle script: @@ expression ds, e1, e2; @@ -init_timer (&ds); +setup_timer (&ds, e1, e2); … ( -ds.function = e1; … -ds.data = e2; …
Feb 19 2015
staging: dgnc: replace init_timer by setup_timer
Author: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com> This patch replaces init_timer and the 2 step initialization of function and data by setup_timer to make the code more concise. The issue was discovered using the following coccinelle script: @@ expression ds, e1, e2; @@ -init_timer (&ds); +setup_timer (&ds, e1, e2); … ( -ds.function = e1; … -ds.data = e2; …
Feb 19 2015
staging: wlan-ng: replace init_timer by setup_timer
Author: Aya Mahfouz <mahfouz.saif.elyazal@gmail.com> This patch replaces init_timer and the 2 step initialization of function and data by setup_timer to make the code more concise. The issue was discovered using the following coccinelle script: @@ expression ds, e1, e2; @@ -init_timer (&ds); +setup_timer (&ds, e1, e2); … ( -ds.function = e1; … -ds.data = e2; …
Feb 18 2015
Staging: media: lirc: Use setup_timer
Author: Vaishali Thakkar <vthakkar1994@gmail.com> This patch introduces the use of function setup_timer instead of structure assignments as it is the preferred way to setup and set the timer. This is done using Coccinelle and semantic patch used is as follows: @@ expression x,y,z; @@ – init_timer (&x); + setup_timer (&x, y, z); – x.function = …
Feb 17 2015
fs/ufs/super.c: remove unnecessary casting
Author: Fabian Frederick <fabf@skynet.be> Fix the following coccinelle warning: fs/ufs/super.c:1418:7-28: WARNING: casting value returned by memory allocation function to (struct ufs_inode_info *) is useless. Signed-off-by: Fabian Frederick Cc: Evgeniy Dushistov Cc: Joe Perches Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds — fs/ufs/super.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff –git a/fs/ufs/super.c …
Feb 17 2015
fs/befs/linuxvfs.c: remove unnecessary casting
Author: Fabian Frederick <fabf@skynet.be> Fix the following coccinelle warning: fs/befs/linuxvfs.c:278:14-36: WARNING: casting value returned by memory allocation function to (struct befs_inode_info *) is useless. [akpm@linux-foundation.org: avoid 80-col ugliness] Signed-off-by: Fabian Frederick Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds — fs/befs/linuxvfs.c | 6 +++— 1 file changed, 3 insertions(+), 3 deletions(-) diff –git a/fs/befs/linuxvfs.c b/fs/befs/linuxvfs.c index …