Category: Linux

logfs: constify logfs_block_ops structures

Author: Julia Lawall <Julia.Lawall@lip6.fr> The logfs_block_ops structures are never modified, so declare them as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall Signed-off-by: Al Viro — fs/logfs/logfs.h | 4 ++– fs/logfs/readwrite.c | 4 ++– fs/logfs/segment.c | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-)   diff –git a/fs/logfs/logfs.h b/fs/logfs/logfs.h index 5f09376..5731361 100644 …

Continue reading

ALSA: usb-audio: constify usb_protocol_ops structures

Author: Julia Lawall <Julia.Lawall@lip6.fr> The usb_protocol_ops structures are never modified, so declare them as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall Acked-by: Clemens Ladisch Signed-off-by: Takashi Iwai — sound/usb/midi.c | 25 +++++++++++++———— 1 file changed, 13 insertions(+), 12 deletions(-)   diff –git a/sound/usb/midi.c b/sound/usb/midi.c index ee212e7..cc39f63 100644 — a/sound/usb/midi.c +++ b/sound/usb/midi.c @@ …

Continue reading

s390-ctcm: Delete unnecessary checks before the function call “channel_remove”

Author: Markus Elfring <elfring@users.sourceforge.net> The channel_remove() function tests whether its argument is NULL and then returns immediately. Thus the test around the calls is not needed. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring Signed-off-by: Ursula Braun Signed-off-by: David S. Miller — drivers/s390/net/ctcm_main.c | 7 ++—– 1 file changed, 2 insertions(+), …

Continue reading

ieee802154-atusb: Delete an unnecessary check before the function call “kfree_skb”

Author: Markus Elfring <elfring@users.sourceforge.net> The kfree_skb() function tests whether its argument is NULL and then returns immediately. Thus the test around the call is not needed. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring Acked-by: Stefan Schmidt Signed-off-by: Marcel Holtmann — drivers/net/ieee802154/atusb.c | 3 +– 1 file changed, 1 insertion(+), 2 …

Continue reading

[media] uapi/media.h: Rename entities types to functions

Author: Mauro Carvalho Chehab <mchehab@osg.samsung.com> Rename the userspace types from MEDIA_ENT_T_ to MEDIA_ENT_F_ and add the backward compatibility bits. The changes at the .c files was generated by the following coccinelle script: @@ @@ -MEDIA_ENT_T_UNKNOWN +MEDIA_ENT_F_UNKNOWN @@ @@ -MEDIA_ENT_T_DVB_BASE +MEDIA_ENT_F_DVB_BASE @@ @@ -MEDIA_ENT_T_V4L2_BASE +MEDIA_ENT_F_V4L2_BASE @@ @@ -MEDIA_ENT_T_V4L2_SUBDEV_BASE +MEDIA_ENT_F_V4L2_SUBDEV_BASE @@ @@ -MEDIA_ENT_T_CONNECTOR_BASE +MEDIA_ENT_F_CONNECTOR_BASE @@ @@ -MEDIA_ENT_T_V4L2_VIDEO …

Continue reading

rtc: rv8803: fix handling return value of i2c_smbus_read_byte_data

Author: Andrzej Hajda <a.hajda@samsung.com> The function can return negative values, so its result should be assigned to signed variable. The problem has been detected using proposed semantic patch scripts/coccinelle/tests/assign_signed_to_unsigned.cocci [1]. [1]: http://permalink.gmane.org/gmane.linux.kernel/2046107 Signed-off-by: Andrzej Hajda Signed-off-by: Alexandre Belloni — drivers/rtc/rtc-rv8803.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)   diff –git a/drivers/rtc/rtc-rv8803.c b/drivers/rtc/rtc-rv8803.c …

Continue reading

drm: Pass ‘name’ to drm_encoder_init()

Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Done with coccinelle for the most part. However, it thinks ‘…’ is part of the semantic patch, so I put an ‘int DOTDOTDOT’ placeholder in its place and got rid of it with sed afterwards. @@ identifier dev, encoder, funcs; @@ int drm_encoder_init(struct drm_device *dev, struct drm_encoder *encoder, const struct drm_encoder_funcs …

Continue reading

drm: Pass ‘name’ to drm_universal_plane_init()

Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Done with coccinelle for the most part. It choked on msm/mdp/mdp5/mdp5_plane.c like so: “BAD:!!!!! enum drm_plane_type type;” No idea how to deal with that, so I just fixed that up by hand. Also it thinks ‘…’ is part of the semantic patch, so I put an ‘int DOTDOTDOT’ placeholder in its …

Continue reading

drm: Pass ‘name’ to drm_crtc_init_with_planes()

Author: Ville Syrjälä <ville.syrjala@linux.intel.com> Done with coccinelle for the most part. However, it thinks ‘…’ is part of the semantic patch, so I put an ‘int DOTDOTDOT’ placeholder in its place and got rid of it with sed afterwards. I didn’t convert drm_crtc_init() since passing the varargs through would mean either cpp macros or va_list, …

Continue reading

drm/i915: constify intel_dvo_dev_ops structures

Author: Julia Lawall <Julia.Lawall@lip6.fr> The intel_dvo_dev_ops structures are never modified, so declare them as const. Done with the help of Coccinelle. Signed-off-by: Julia Lawall Signed-off-by: Daniel Vetter Link: http://patchwork.freedesktop.org/patch/msgid/1449608127-21715-1-git-send-email-Julia.Lawall@lip6.fr — drivers/gpu/drm/i915/dvo.h | 12 ++++++—— drivers/gpu/drm/i915/dvo_ch7017.c | 2 +- drivers/gpu/drm/i915/dvo_ch7xxx.c | 2 +- drivers/gpu/drm/i915/dvo_ivch.c | 2 +- drivers/gpu/drm/i915/dvo_ns2501.c | 2 +- drivers/gpu/drm/i915/dvo_sil164.c | 2 +- drivers/gpu/drm/i915/dvo_tfp410.c …

Continue reading

BtrLinux
Privacy Overview

This website uses cookies so that we can provide you with the best user experience possible. Cookie information is stored in your browser and performs functions such as recognising you when you return to our website and helping our team to understand which sections of the website you find most interesting and useful.