Category: Linux

i40e: use correct structure type name in sizeof

Author: Julia Lawall <Julia.Lawall@lip6.fr> Correct typo in the name of the type given to sizeof. Because it is the size of a pointer that is wanted, the typo has no impact on compilation or execution. This problem was found using Coccinelle (http://coccinelle.lip6.fr/). The semantic patch used can be found in message 0 of this patch …

Continue reading

cpupower: Remove redundant error check

Author: Peter Senna Tschudin <peter.senna@gmail.com> Remove double checks, and move the call to print_error to the first check. Replace break by return, and return 0 on success. The simplified version of the coccinelle semantic patch that fixes this issue is as follows: // @@ expression E; identifier pr; expression list es; @@ for(…;…;…){ … – …

Continue reading

cpupower: mperf monitor: Correct use of ! and &

Author: Himangi Saraogi <himangi774@gmail.com> In commit ae91d60ba88ef0bdb1b5e9b2363bd52fc45d2af7, a bug was fixed that involved converting !x & y to !(x & y). The code below shows the same pattern, and thus should perhaps be fixed in the same way. The Coccinelle semantic patch that makes this change is as follows: // @@ expression E1,E2; @@ ( …

Continue reading

uwb/whci: use correct structure type name in sizeof

Author: Julia Lawall <Julia.Lawall@lip6.fr> Correct typo in the name of the type given to sizeof. Because it is the size of a pointer that is wanted, the typo has no impact on compilation or execution. This problem was found using Coccinelle (http://coccinelle.lip6.fr/). The semantic patch used can be found in message 0 of this patch …

Continue reading

iwlegacy: use correct structure type name in sizeof

Author: Julia Lawall <Julia.Lawall@lip6.fr> Correct typo in the name of the type given to sizeof. Because it is the size of a pointer that is wanted, the typo has no impact on compilation or execution. This problem was found using Coccinelle (http://coccinelle.lip6.fr/). The semantic patch used can be found in message 0 of this patch …

Continue reading

gpiolib: devres: use correct structure type name in sizeof

Author: Julia Lawall <Julia.Lawall@lip6.fr> Correct typo in the name of the type given to sizeof. Because it is the size of a pointer that is wanted, the typo has no impact on compilation or execution. This problem was found using Coccinelle (http://coccinelle.lip6.fr/). The semantic patch used can be found in message 0 of this patch …

Continue reading

CAPI: use correct structure type name in sizeof

Author: Julia Lawall <Julia.Lawall@lip6.fr> Correct typo in the name of the type given to sizeof. Because it is the size of a pointer that is wanted, the typo has no impact on compilation or execution. This problem was found using Coccinelle (http://coccinelle.lip6.fr/). The semantic patch used can be found in message 0 of this patch …

Continue reading

[media] drivers/staging/media/davinci_vpfe/vpfe_mc_capture.c: use correct structure type name in sizeof

Author: Julia Lawall <Julia.Lawall@lip6.fr> Correct typo in the name of the type given to sizeof. Because it is the size of a pointer that is wanted, the typo has no impact on compilation or execution. This problem was found using Coccinelle (http://coccinelle.lip6.fr/). The semantic patch used can be found in message 0 of this patch …

Continue reading

net/udp_offload: Use IS_ERR_OR_NULL

Author: Himangi Saraogi <himangi774@gmail.com> This patch introduces the use of the macro IS_ERR_OR_NULL in place of tests for NULL and IS_ERR. The following Coccinelle semantic patch was used for making the change: @@ expression e; @@ – e == NULL || IS_ERR(e) + IS_ERR_OR_NULL(e) || … Signed-off-by: Himangi Saraogi Acked-by: Julia Lawall Signed-off-by: David S. …

Continue reading

openvswitch: Use IS_ERR_OR_NULL

Author: Himangi Saraogi <himangi774@gmail.com> This patch introduces the use of the macro IS_ERR_OR_NULL in place of tests for NULL and IS_ERR. The following Coccinelle semantic patch was used for making the change: @@ expression e; @@ – e == NULL || IS_ERR(e) + IS_ERR_OR_NULL(e) || … Signed-off-by: Himangi Saraogi Acked-by: Julia Lawall Acked-by: Pravin B …

Continue reading