Articles de cet auteur
Mar 31 2015
Staging: iio: meter: Remove explicit NULL comparison
Author: Cristina Opriceana <cristina.opriceana@gmail.com> This patch removes explicit NULL comparison and replaces it with its shorter form. Detected with coccinelle. @replace_rule@ expression e; @@ -e == NULL + !e Signed-off-by: Cristina Opriceana Signed-off-by: Greg Kroah-Hartman — drivers/staging/iio/meter/ade7758_core.c | 2 +- drivers/staging/iio/meter/ade7758_ring.c | 2 +- drivers/staging/iio/meter/ade7758_trigger.c | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) …
Mar 31 2015
Staging: iio: iio_simple_dummy: Remove explicit NULL comparison
Author: Cristina Opriceana <cristina.opriceana@gmail.com> This patch removes explicit NULL comparison and writes it in its simpler form. Done with coccinelle: @replace_rule@ expression e; @@ -e == NULL + !e Signed-off-by: Cristina Opriceana Signed-off-by: Greg Kroah-Hartman — drivers/staging/iio/iio_simple_dummy.c | 2 +- drivers/staging/iio/iio_simple_dummy_buffer.c | 6 +++— 2 files changed, 4 insertions(+), 4 deletions(-) diff –git a/drivers/staging/iio/iio_simple_dummy.c …
Mar 31 2015
Staging: iio: iio_dummy_evgen: Simplify NULL comparison
Author: Cristina Opriceana <cristina.opriceana@gmail.com> Remove explicit NULL comparison and write it in its simpler form. Replacement done with coccinelle: @replace_rule@ expression e; @@ -e == NULL + !e Signed-off-by: Cristina Opriceana Signed-off-by: Greg Kroah-Hartman — drivers/staging/iio/iio_dummy_evgen.c | 4 ++– 1 file changed, 2 insertions(+), 2 deletions(-) diff –git a/drivers/staging/iio/iio_dummy_evgen.c b/drivers/staging/iio/iio_dummy_evgen.c index 59ad5a3..0c9c86d 100644 — …
Mar 31 2015
module: add extra argument for parse_params() callback
Author: Luis R. Rodriguez <mcgrof@suse.com> This adds an extra argument onto parse_params() to be used as a way to make the unused callback a bit more useful and generic by allowing the caller to pass on a data structure of its choice. An example use case is to allow us to easily make module parameters …
Mar 29 2015
staging: ft1000: Drop unneeded cast on netdev_priv
Author: Julia Lawall <Julia.Lawall@lip6.fr> The result of netdev_priv is already implicitly cast to the type of the left side of the assignment. The semantic patch that fixes this problem is as follows: (http://coccinelle.lip6.fr/) // @@ type T; T *x; @@ x = – (T *) netdev_priv(…) // Signed-off-by: Julia Lawall Signed-off-by: Greg Kroah-Hartman — drivers/staging/ft1000/ft1000-pcmcia/ft1000_dnld.c …
Mar 29 2015
n_gsm: Drop unneeded cast on netdev_priv
Author: Julia Lawall <Julia.Lawall@lip6.fr> The result of netdev_priv is already implicitly cast to the type of the left side of the assignment. The semantic patch that fixes this problem is as follows: (http://coccinelle.lip6.fr/) // @@ type T; T *x; @@ x = – (T *) netdev_priv(…) // Signed-off-by: Julia Lawall Signed-off-by: Greg Kroah-Hartman — drivers/tty/n_gsm.c …
Mar 29 2015
staging: rtl8712: Drop unneeded cast on netdev_priv
Author: Julia Lawall <Julia.Lawall@lip6.fr> The result of netdev_priv is already implicitly cast to the type of the left side of the assignment. The semantic patch that fixes this problem is as follows: (http://coccinelle.lip6.fr/) // @@ type T; T *x; @@ x = – (T *) netdev_priv(…) // Signed-off-by: Julia Lawall Signed-off-by: Greg Kroah-Hartman — drivers/staging/rtl8712/os_intfs.c …
Mar 28 2015
Staging: rtl8712: Remove duplicated argument to |
Author: Cristina Opriceana <cristina.opriceana@gmail.com> Delete duplicated argument to | for the state argument in the _clr_fwstate_() function call as it is redundant. Detected with coccinelle. Signed-off-by: Cristina Opriceana Signed-off-by: Greg Kroah-Hartman — drivers/staging/rtl8712/rtl871x_ioctl_set.c | 3 +– 1 file changed, 1 insertion(+), 2 deletions(-) diff –git a/drivers/staging/rtl8712/rtl871x_ioctl_set.c b/drivers/staging/rtl8712/rtl871x_ioctl_set.c index bd1d1b7..22262b3 100644 — a/drivers/staging/rtl8712/rtl871x_ioctl_set.c +++ b/drivers/staging/rtl8712/rtl871x_ioctl_set.c …
Mar 28 2015
Staging: rtl8712: Use memdup_user() instead of copy_from_user()
Author: Cristina Opriceana <cristina.opriceana@gmail.com> Use memdup_user() to avoid its duplicated implementation and simplify code. memdup_user() uses GFP_KERNEL instead of GFP_ATOMIC, which is valid because copy_from_user() might sleep and it’s useless to make the allocation atomic. Found with coccinelle. Signed-off-by: Cristina Opriceana Signed-off-by: Greg Kroah-Hartman — drivers/staging/rtl8712/rtl871x_ioctl_linux.c | 10 +++——- 1 file changed, 3 insertions(+), 7 …
Mar 27 2015
drm/i915: fix simple_return.cocci warnings
Author: kbuild test robot <fengguang.wu@intel.com> drivers/gpu/drm/i915/i915_gem_gtt.c:1349:1-4: WARNING: end returns can be simpified and declaration on line 1347 can be dropped Simplify a trivial if-return sequence. Possibly combine with a preceding function call. Generated by: scripts/coccinelle/misc/simple_return.cocci CC: Michel Thierry Signed-off-by: Fengguang Wu Signed-off-by: Daniel Vetter — drivers/gpu/drm/i915/i915_gem_gtt.c | 8 +——- 1 file changed, 1 insertion(+), 7 …