Catégorie : Linux

[media] drivers/media/platform/soc_camera/mx2_camera.c: fix error return code

Author: Peter Senna Tschudin <peter.senna@gmail.com> Convert a nonnegative error return code to a negative one, as returned elsewhere in the function. A simplified version of the semantic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // ( if@p1 (\(ret < 0\|ret != 0\)) { ... return ret; } | ret@p1 = 0 ) ... …

Lire la suite

ctcm: fix error return code

Author: Peter Senna Tschudin <peter.senna@gmail.com> Convert a nonnegative error return code to a negative one, as returned elsewhere in the function. A simplified version of the semantic match that finds this problem is as follows: (http://coccinelle.lip6.fr/) // ( if@p1 (\(ret < 0\|ret != 0\)) { ... return ret; } | ret@p1 = 0 ) ... …

Lire la suite

drivers/s390/net: removes unnecessary semicolon

Author: Peter Senna Tschudin <peter.senna@gmail.com> removes unnecessary semicolon Found by Coccinelle: http://coccinelle.lip6.fr/ Signed-off-by: Peter Senna Tschudin Signed-off-by: Ursula Braun Signed-off-by: Frank Blaschka Signed-off-by: David S. Miller — drivers/s390/net/ctcm_fsms.c | 2 +- drivers/s390/net/qeth_core_main.c | 4 ++– 2 files changed, 3 insertions(+), 3 deletions(-)   diff –git a/drivers/s390/net/ctcm_fsms.c b/drivers/s390/net/ctcm_fsms.c index d4ade9e..fb92524 100644 — a/drivers/s390/net/ctcm_fsms.c +++ b/drivers/s390/net/ctcm_fsms.c @@ …

Lire la suite

qeth: fix possible memory leak in qeth_l3_add_[vipa|rxip]()

Author: Wei Yongjun <yongjun_wei@trendmicro.com.cn> ipaddr has been allocated in function qeth_l3_add_vipa() but does not free before leaving from the error handling cases. The same problem also exists in function qeth_l3_add_rxip(). spatch with a semantic match is used to found this problem. (http://coccinelle.lip6.fr/) Signed-off-by: Wei Yongjun Signed-off-by: Frank Blaschka Signed-off-by: David S. Miller — drivers/s390/net/qeth_l3_main.c | …

Lire la suite

edac_mc: fix messy kfree calls in the error path

Author: Fengguang Wu <fengguang.wu@intel.com> coccinelle warns about: + drivers/edac/edac_mc.c:429:9-23: ERROR: reference preceded by free on line 429 421 if (mci->csrows) { > 422 for (chn = 0; chn < tot_channels; chn++) { 423 csr = mci->csrows[chn]; 424 if (csr) { > 425 for (chn = 0; chn < tot_channels; chn++) 426 kfree(csr->channels[chn]); 427 kfree(csr); 428 …

Lire la suite

staging/rts_pstor: Delete some lines (dev_info() and dev_err()) in rtsx.c

Author: YAMANE Toshiaki <yamanetoshi@gmail.com> fixed some coccinelle warnings. + drivers/staging/rts_pstor/rtsx.c:397:16-19: ERROR: dev is NULL but dereferenced. drivers/staging/rts_pstor/rtsx.c:447:16-19: ERROR: dev is NULL but dereferenced. drivers/staging/rts_pstor/rtsx.c:358:16-19: ERROR: dev is NULL but dereferenced. Signed-off-by: YAMANE Toshiaki Signed-off-by: Greg Kroah-Hartman — drivers/staging/rts_pstor/rtsx.c | 18 +++————— 1 file changed, 3 insertions(+), 15 deletions(-)   diff –git a/drivers/staging/rts_pstor/rtsx.c b/drivers/staging/rts_pstor/rtsx.c index 213829e..afe9c2e …

Lire la suite

USB: serial: fix up bug with missing {}

Author: Greg Kroah-Hartman <gregkh@linuxfoundation.org> As reported by Fengguang: FYI, coccinelle warns about drivers/usb/serial/usb-serial.c:1415:3-51: code aligned with following code on line 1416 vim +1415 drivers/usb/serial/usb-serial.c 1412 /* we only set the reset_resume field if the serial_driver has one */ 1413 for (sd = serial_drivers; *sd; ++sd) { 1414 if ((*sd)->reset_resume) > 1415 udriver->reset_resume = usb_serial_reset_resume; > …

Lire la suite

mfd: Use IRQF_ONESHOT for max8925

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 Signed-off-by: Samuel Ortiz — drivers/mfd/max8925-core.c | 4 ++– 1 file changed, 2 insertions(+), 2 deletions(-)   diff –git a/drivers/mfd/max8925-core.c b/drivers/mfd/max8925-core.c index f2ff31f..e25a242 100644 — a/drivers/mfd/max8925-core.c +++ b/drivers/mfd/max8925-core.c @@ -547,7 +547,7 @@ static …

Lire la suite

staging: ozwpan: compare pointer to NULL rather than 0

Author: Fengguang Wu <fengguang.wu@intel.com> Generated by: scripts/coccinelle/null/badzero.cocci Signed-off-by: Fengguang Wu Signed-off-by: Greg Kroah-Hartman — drivers/staging/ozwpan/ozcdev.c | 14 +++++++——- 1 file changed, 7 insertions(+), 7 deletions(-)   diff –git a/drivers/staging/ozwpan/ozcdev.c b/drivers/staging/ozwpan/ozcdev.c index 758ce0a..64913ae 100644 — a/drivers/staging/ozwpan/ozcdev.c +++ b/drivers/staging/ozwpan/ozcdev.c @@ -104,10 +104,10 @@ ssize_t oz_cdev_read(struct file *filp, char __user *buf, size_t count, if (pd) oz_pd_get(pd); spin_unlock_bh(&g_cdev.lock); – …

Lire la suite

mfd: Use IRQF_ONESHOT for twl6040

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: Peter Ujfalusi Signed-off-by: Samuel Ortiz — drivers/mfd/twl6040-core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)   diff –git a/drivers/mfd/twl6040-core.c b/drivers/mfd/twl6040-core.c index 3dca5c1..348e1de 100644 — a/drivers/mfd/twl6040-core.c +++ b/drivers/mfd/twl6040-core.c @@ -584,7 …

Lire la suite

BtrLinux
Résumé de la politique de confidentialité

Ce site utilise des cookies afin que nous puissions vous fournir la meilleure expérience utilisateur possible. Les informations sur les cookies sont stockées dans votre navigateur et remplissent des fonctions telles que vous reconnaître lorsque vous revenez sur notre site Web et aider notre équipe à comprendre les sections du site que vous trouvez les plus intéressantes et utiles.