Catégorie : Linux

cxgb4: Delete an unnecessary check before the function call « release_firmware »

Author: Markus Elfring <elfring@users.sourceforge.net> The release_firmware() 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 Signed-off-by: David S. Miller — drivers/net/ethernet/chelsio/cxgb4/cxgb4_main.c | 3 +– 1 file changed, 1 insertion(+), 2 deletions(-)   …

Lire la suite

NetCP: Deletion of unnecessary checks before two function calls

Author: Markus Elfring <elfring@users.sourceforge.net> The functions cpsw_ale_destroy() and of_dev_put() test whether their argument is NULL and then return immediately. Thus the test around the call is not needed. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring Signed-off-by: David S. Miller — drivers/net/ethernet/ti/netcp_ethss.c | 6 ++—- 1 file changed, 2 insertions(+), 4 …

Lire la suite

IBM-EMAC: Delete an unnecessary check before the function call « of_dev_put »

Author: Markus Elfring <elfring@users.sourceforge.net> The of_dev_put() 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 Signed-off-by: David S. Miller — drivers/net/ethernet/ibm/emac/core.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)   …

Lire la suite

cpufreq-dt: Drop unnecessary check before cpufreq_cooling_unregister() invocation

Author: Markus Elfring <elfring@users.sourceforge.net> The cpufreq_cooling_unregister() 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 [ rjw: Subject ] Signed-off-by: Rafael J. Wysocki — drivers/cpufreq/cpufreq-dt.c | 3 +– 1 file changed, 1 …

Lire la suite

[media] au0828: Delete unnecessary checks before the function call « video_unregister_device »

Author: Markus Elfring <elfring@users.sourceforge.net> The video_unregister_device() 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 Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab — drivers/media/usb/au0828/au0828-video.c | 8 ++—— 1 file changed, 2 insertions(+), …

Lire la suite

[media] stk-webcam: Delete an unnecessary check before the function call « vfree »

Author: Markus Elfring <elfring@users.sourceforge.net> The vfree() function performs also input parameter validation. Thus the test around the call is not needed. This issue was detected by using the Coccinelle software. Signed-off-by: Markus Elfring Signed-off-by: Hans Verkuil Signed-off-by: Mauro Carvalho Chehab — drivers/media/usb/stkwebcam/stk-webcam.c | 6 ++—- 1 file changed, 2 insertions(+), 4 deletions(-)   diff –git …

Lire la suite

[media] DVB: Delete an unnecessary check before the function call « dvb_unregister_device »

Author: Markus Elfring <elfring@users.sourceforge.net> The dvb_unregister_device() 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 Signed-off-by: Mauro Carvalho Chehab — drivers/media/dvb-core/dvb_ca_en50221.c | 3 +– 1 file changed, 1 insertion(+), 2 deletions(-)   …

Lire la suite

[media] V4L2: Delete an unnecessary check before the function call « media_entity_put »

Author: Markus Elfring <elfring@users.sourceforge.net> The media_entity_put() 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 Signed-off-by: Mauro Carvalho Chehab — drivers/media/v4l2-core/v4l2-subdev.c | 3 +– 1 file changed, 1 insertion(+), 2 deletions(-)   …

Lire la suite

[media] sp2: Delete an unnecessary check before the function call « kfree »

Author: Markus Elfring <elfring@users.sourceforge.net> The kfree() 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 Signed-off-by: Mauro Carvalho Chehab — drivers/media/dvb-frontends/sp2.c | 5 +—- 1 file changed, 1 insertion(+), 4 deletions(-)   …

Lire la suite

powerpc: Delete unnecessary checks before kfree()

Author: Markus Elfring <elfring@users.sourceforge.net> The kfree() 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 Signed-off-by: Michael Ellerman — arch/powerpc/lib/rheap.c | 2 +- arch/powerpc/platforms/cell/celleb_pci.c | 5 ++— 2 files changed, 3 insertions(+), …

Lire la suite