drm/exynos: Use ERR_CAST inlined function instead of ERR_PTR(PTR_ERR(.. [1]

Author: Thomas Meyer <thomas@m3y3r.de> The semantic patch that makes this change is available in scripts/coccinelle/api/err_cast.cocci. More information about semantic patching is available at http://coccinelle.lip6.fr/ Signed-off-by: Thomas Meyer Signed-off-by: Inki Dae Signed-off-by: Kyungmin Park — drivers/gpu/drm/exynos/exynos_drm_gem.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)   diff –git a/drivers/gpu/drm/exynos/exynos_drm_gem.c b/drivers/gpu/drm/exynos/exynos_drm_gem.c index f9efde4..da4e3ca 100644 — a/drivers/gpu/drm/exynos/exynos_drm_gem.c …

Lire la suite

m68k/amiga: Use PTR_RET rather than if(IS_ERR(…)) + PTR_ERR

Author: Thomas Meyer <thomas@m3y3r.de> The semantic patch that makes this change is available in scripts/coccinelle/api/ptr_ret.cocci. More information about semantic patching is available at http://coccinelle.lip6.fr/ Signed-off-by: Thomas Meyer Signed-off-by: Geert Uytterhoeven — arch/m68k/amiga/platform.c | 5 +—- 1 file changed, 1 insertion(+), 4 deletions(-)   diff –git a/arch/m68k/amiga/platform.c b/arch/m68k/amiga/platform.c index 80076d3..6083088 100644 — a/arch/m68k/amiga/platform.c +++ b/arch/m68k/amiga/platform.c @@ …

Lire la suite

m68k/q40: Use PTR_RET rather than if(IS_ERR(…)) + PTR_ERR

Author: Thomas Meyer <thomas@m3y3r.de> The semantic patch that makes this change is available in scripts/coccinelle/api/ptr_ret.cocci. More information about semantic patching is available at http://coccinelle.lip6.fr/ Signed-off-by: Thomas Meyer Signed-off-by: Geert Uytterhoeven — arch/m68k/q40/config.c | 5 +—- 1 file changed, 1 insertion(+), 4 deletions(-)   diff –git a/arch/m68k/q40/config.c b/arch/m68k/q40/config.c index 8a1ce32..1adb5b7 100644 — a/arch/m68k/q40/config.c +++ b/arch/m68k/q40/config.c @@ …

Lire la suite

m68k: Use PTR_RET rather than if(IS_ERR(…)) + PTR_ERR

Author: Thomas Meyer <thomas@m3y3r.de> The semantic patch that makes this change is available in scripts/coccinelle/api/ptr_ret.cocci. More information about semantic patching is available at http://coccinelle.lip6.fr/ Signed-off-by: Thomas Meyer Signed-off-by: Geert Uytterhoeven — arch/m68k/kernel/time.c | 5 +—- 1 file changed, 1 insertion(+), 4 deletions(-)   diff –git a/arch/m68k/kernel/time.c b/arch/m68k/kernel/time.c index 707f057..5d0bcaa 100644 — a/arch/m68k/kernel/time.c +++ b/arch/m68k/kernel/time.c @@ …

Lire la suite

net: Use PTR_RET rather than if(IS_ERR(.. [1]

Author: Thomas Meyer <thomas@m3y3r.de> The semantic patch that makes this change is available in scripts/coccinelle/api/ptr_ret.cocci. More information about semantic patching is available at http://coccinelle.lip6.fr/ Signed-off-by: Thomas Meyer Signed-off-by: David S. Miller — drivers/net/appletalk/cops.c | 4 +— drivers/net/appletalk/ltpc.c | 4 +— 2 files changed, 2 insertions(+), 6 deletions(-)   diff –git a/drivers/net/appletalk/cops.c b/drivers/net/appletalk/cops.c index 545c09e..cff6f02 100644 …

Lire la suite

drivers/cpufreq/pcc-cpufreq.c: fix error return code

Author: Julia Lawall <julia@diku.dk> Convert a 0 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/) // @@ identifier ret; expression e,e1,e2,e3,e4,x; @@ ( if (\(ret != 0\|ret < 0\) || ...) { ... return ...; …

Lire la suite

drivers/char/tlclk.c: fix error return code

Author: Julia Lawall <julia@diku.dk> Convert a 0 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/) // @@ identifier ret; expression e,e1,e2,e3,e4,x; @@ ( if (\(ret != 0\|ret < 0\) || ...) { ... return ...; …

Lire la suite

drivers/gpio/gpio-langwell.c: fix error return code

Author: Julia Lawall <julia@diku.dk> Convert a 0 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/) // @@ identifier ret; expression e,e1,e2,e3,e4,x; @@ ( if (\(ret != 0\|ret < 0\) || ...) { ... return ...; …

Lire la suite

drivers/atm/iphase.c: fix error return code

Author: Julia Lawall <julia@diku.dk> Convert a 0 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/) // @@ identifier ret; expression e,e1,e2,e3,e4,x; @@ ( if (\(ret != 0\|ret < 0\) || ...) { ... return ...; …

Lire la suite

arch/powerpc/kvm/e500_tlb.c: fix error return code

Author: Julia Lawall <julia@diku.dk> Convert a 0 error return code to a negative one, as returned elsewhere in the function. A new label is also added to avoid freeing things that are known to not yet be allocated. A simplified version of the semantic match that finds the first problem is as follows: (http://coccinelle.lip6.fr/) // …

Lire la suite