Author: Himangi Saraogi <himangi774@gmail.com> The Linux kernel coding style guidelines suggest not using typedefs for structure types. This patch gets rid of the typedefs for wanc_info and wavnc_port_info. A simplified version of the Coccinelle semantic patch that finds the case is: @tn@ identifier i; type td; @@ -typedef struct i { … } -td ; …
Category: Linux
Aug 06 2014
sound: oss: uart401: Remove typedef uart401_devc
Author: Himangi Saraogi <himangi774@gmail.com> The Linux kernel coding style guidelines suggest not using typedefs for structure types. This patch gets rid of the typedef for uart401_devc. The following Coccinelle semantic patch detects the case. @tn@ identifier i; type td; @@ -typedef struct i { … } -td ; @@ type tn.td; identifier tn.i; @@ -td …
Aug 06 2014
pcmcia: Remove typedef tuple_flags
Author: Himangi Saraogi <himangi774@gmail.com> The Linux kernel coding style guidelines suggest not using typedefs for structure types. This patch gets rid of the typedef for tuple_flags. The following Coccinelle semantic patch makes the transformation. @tn@ identifier i; type td; @@ -typedef struct i { … } -td ; @@ type tn.td; identifier tn.i; @@ -td …
Aug 06 2014
drm: Reduce the amount of dev->vblank[crtc] in the code
Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Declare a local struct drm_vblank_crtc * and use that instead of having to do dig it out via ‘dev->vblank[crtc]’ everywhere. Performed with the following coccinelle incantation, and a few manual whitespace cleanups: @@ identifier func,member; expression num_crtcs; struct drm_device *dev; unsigned int crtc; @@ func (…) { + struct drm_vblank_crtc *vblank; …
Aug 05 2014
sound/oss/pss: Remove typedefs pss_mixerdata and pss_confdata
Author: Himangi Saraogi <himangi774@gmail.com> The Linux kernel coding style guidelines suggest not using typedefs for structure types. This patch gets rid of the typedefs for pss_mixerdata and pss_confdata. The following Coccinelle semantic patch is used to make the change. @tn@ identifier i; type td; @@ -typedef struct i { … } -td ; @@ type …
Aug 05 2014
sound/oss/opl3: Remove typedef opl_devinfo
Author: Himangi Saraogi <himangi774@gmail.com> This typedef is unnecessary and should just be removed as they are never used. The following Coccinelle semantic patch detects the case. @tn@ identifier i; type td; @@ -typedef struct i { … } -td ; @@ type tn.td; identifier tn.i; @@ -td + struct i Signed-off-by: Himangi Saraogi Acked-by: Julia …
Aug 04 2014
perf/x86/uncore: Fix coccinelle warnings
Author: Fengguang Wu <fengguang.wu@intel.com> arch/x86/kernel/cpu/perf_event_intel_uncore_nhmex.c:961:2-3: Unneeded semicolon arch/x86/kernel/cpu/perf_event_intel_uncore_nhmex.c:1100:2-3: Unneeded semicolon arch/x86/kernel/cpu/perf_event_intel_uncore_nhmex.c:1138:2-3: Unneeded semicolon Remove unneeded semicolon. Generated by: scripts/coccinelle/misc/semicolon.cocci Signed-off-by: Fengguang Wu Signed-off-by: Peter Zijlstra Cc: Yan, Zheng Cc: Arnaldo Carvalho de Melo Link: http://lkml.kernel.org/n/tip-ovfvr4nbqjo7nzc16y2lpjy9@git.kernel.org Signed-off-by: Ingo Molnar — arch/x86/kernel/cpu/perf_event_intel_uncore_nhmex.c | 6 +++— 1 file changed, 3 insertions(+), 3 deletions(-) diff –git a/arch/x86/kernel/cpu/perf_event_intel_uncore_nhmex.c b/arch/x86/kernel/cpu/perf_event_intel_uncore_nhmex.c …
Aug 04 2014
xfs: fix coccinelle warnings
Author: kbuild test robot <fengguang.wu@intel.com> Removes unneeded semicolon, introduced by commit a70a4fa5 (“xfs: fix a couple error sequence jumps in xfs_mountfs”): fs/xfs/xfs_mount.c:858:24-25: Unneeded semicolon Generated by: scripts/coccinelle/misc/semicolon.cocci Signed-off-by: Fengguang Wu Reviewed-by: Brian Foster Signed-off-by: Dave Chinner — fs/xfs/xfs_mount.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff –git a/fs/xfs/xfs_mount.c b/fs/xfs/xfs_mount.c index c8a328e..39d84d3 …
Aug 03 2014
cpufreq: integrator: Use set_cpus_allowed_ptr
Author: Himangi Saraogi <himangi774@gmail.com> Several years ago there was an effort to convert all uses of set_cpus_allowed to use set_cpus_allowed_ptr with the goal of eventually removing the current definition of set_cpus_allowed and renaming set_cpus_allowed_ptr as set_cpus_allowed (https://lkml.org/lkml/2010/3/26/59). This is another step in this direction. The Coccinelle semantic patch that makes this change is as follows: …
Jul 30 2014
drivers: CCI: Correct use of ! and &
Author: Himangi Saraogi <himangi774@gmail.com> In commit ae91d60ba88ef0bdb1b5e9b2363bd52fc45d2af7, a bug was fixed that involved converting !x & y to !(x & y). The code below shows the same pattern, and thus should perhaps be fixed in the same way. The Coccinelle semantic patch that makes this change is as follows: // @@ expression E1,E2; @@ ( …