Category: Linux

drivers/usb/host/ohci-nxp.c: adjust inconsistent IS_ERR and PTR_ERR

Author: Julia Lawall <Julia.Lawall@lip6.fr> Change the call to PTR_ERR to access the value just tested by IS_ERR. The semantic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // @@ expression e,e1; @@ ( if (IS_ERR(e)) { … PTR_ERR(e) … } | if (IS_ERR(e=e1)) { … PTR_ERR(e) … } | *if (IS_ERR(e)) { … * …

Continue reading

drivers/usb/gadget/lpc32xx_udc.c: adjust inconsistent IS_ERR and PTR_ERR

Author: Julia Lawall <Julia.Lawall@lip6.fr> Change the call to PTR_ERR to access the value just tested by IS_ERR. The semantic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // @@ expression e,e1; @@ ( if (IS_ERR(e)) { … PTR_ERR(e) … } | if (IS_ERR(e=e1)) { … PTR_ERR(e) … } | *if (IS_ERR(e)) { … * …

Continue reading

usb: gadget: lpc32xx_udc.c: adjust inconsistent IS_ERR and PTR_ERR

Author: Julia Lawall <Julia.Lawall@lip6.fr> Change the call to PTR_ERR to access the value just tested by IS_ERR. The semantic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // @@ expression e,e1; @@ ( if (IS_ERR(e)) { … PTR_ERR(e) … } | if (IS_ERR(e=e1)) { … PTR_ERR(e) … } | *if (IS_ERR(e)) { … * …

Continue reading

fs/nfsd/nfs4idmap.c: adjust inconsistent IS_ERR and PTR_ERR

Author: Julia Lawall <Julia.Lawall@lip6.fr> Change the call to PTR_ERR to access the value just tested by IS_ERR. The semantic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // @@ expression e,e1; @@ ( if (IS_ERR(e)) { … PTR_ERR(e) … } | if (IS_ERR(e=e1)) { … PTR_ERR(e) … } | *if (IS_ERR(e)) { … * …

Continue reading

[media] drivers/media/platform/mx2_emmaprp.c: adjust inconsistent IS_ERR and PTR_ERR

Author: Julia Lawall <Julia.Lawall@lip6.fr> Change the call to IS_ERR to test the value that was just initialized and is returned using PTR_ERR. The semantic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // @@ expression e,e1; @@ ( if (IS_ERR(e)) { … PTR_ERR(e) … } | if (IS_ERR(e=e1)) { … PTR_ERR(e) … } | …

Continue reading

staging: csr: use is_zero_ether_addr() instead of memcmp()

Author: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Using is_zero_ether_addr() instead of directly use memcmp() to determine if the ethernet address is all zeros. spatch with a semantic match is used to found this problem. (http://coccinelle.lip6.fr/) Signed-off-by: Wei Yongjun Signed-off-by: Greg Kroah-Hartman — drivers/staging/csr/sme_wext.c | 4 +— 1 file changed, 1 insertion(+), 3 deletions(-)   diff –git a/drivers/staging/csr/sme_wext.c b/drivers/staging/csr/sme_wext.c …

Continue reading

[SCSI] megaraid_sas: combine kmalloc+memset into kzalloc

Author: Fengguang Wu <fengguang.wu@intel.com> Use kzalloc rather than kmalloc followed by memset with 0. Generated by: scripts/coccinelle/api/alloc/kzalloc-simple.cocci Signed-off-by: Fengguang Wu Acked-by: Adam Radford Signed-off-by: James Bottomley — drivers/scsi/megaraid/megaraid_sas_fusion.c | 7 ++—– 1 file changed, 2 insertions(+), 5 deletions(-)   diff –git a/drivers/scsi/megaraid/megaraid_sas_fusion.c b/drivers/scsi/megaraid/megaraid_sas_fusion.c index 788115b..ddf094e 100644 — a/drivers/scsi/megaraid/megaraid_sas_fusion.c +++ b/drivers/scsi/megaraid/megaraid_sas_fusion.c @@ -462,8 +462,8 @@ megasas_alloc_cmds_fusion(struct …

Continue reading

staging: r8712u: rtl871x_mlme.c: use is_zero_ether_addr() instead of memcmp()

Author: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Using is_zero_ether_addr() instead of directly use memcmp() to determine if the ethernet address is all zeros. spatch with a semantic match is used to found this problem. (http://coccinelle.lip6.fr/) Signed-off-by: Wei Yongjun Acked-by: Larry Finger Signed-off-by: Greg Kroah-Hartman — drivers/staging/rtl8712/rtl871x_mlme.c | 5 +++– 1 file changed, 3 insertions(+), 2 deletions(-)   diff …

Continue reading

mwifiex: use is_zero_ether_addr() instead of memcmp()

Author: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Using is_zero_ether_addr() instead of directly use memcmp() to determine if the ethernet address is all zeros. spatch with a semantic match is used to found this problem. (http://coccinelle.lip6.fr/) Signed-off-by: Wei Yongjun Acked-by: Bing Zhao Signed-off-by: John W. Linville — drivers/net/wireless/mwifiex/sta_cmdresp.c | 3 +– 1 file changed, 1 insertion(+), 2 deletions(-)   …

Continue reading

twl4030_charger: Use IRQF_ONESHOT

Author: Fengguang Wu <fengguang.wu@intel.com> Generated by: scripts/coccinelle/misc/irqf_oneshot.cocci Make sure threaded IRQs without a primary handler are always request with IRQF_ONESHOT Signed-off-by: Fengguang Wu Acked-by: Felipe Balbi Signed-off-by: Anton Vorontsov — drivers/power/twl4030_charger.c | 5 +++– 1 file changed, 3 insertions(+), 2 deletions(-)   diff –git a/drivers/power/twl4030_charger.c b/drivers/power/twl4030_charger.c index 8d6bc68..f9e70cf 100644 — a/drivers/power/twl4030_charger.c +++ b/drivers/power/twl4030_charger.c @@ -534,7 …

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.