Catégorie : Linux

IB/hfi1: Move constant to the right in bitwise operations

Author: Harish Chegondi <harish.chegondi@intel.com> Implement changes recommended by the Coccinelle tool to move constant to the right in bitwise operations -bash-4.2$ make coccicheck MODE=report M=drivers/infiniband/hw/hfi1/ drivers/infiniband/hw/hfi1/pio.c:765:4-16: Move constant to right. drivers/infiniband/hw/hfi1/rc.c:2503:19-29: Move constant to right. drivers/infiniband/hw/hfi1/chip.c:9813:11-22: Move constant to right. drivers/infiniband/hw/hfi1/chip.c:14468:29-40: Move constant to right. Reviewed-by: Jubin John Reviewed-by: Dennis Dalessandro Signed-off-by: Harish Chegondi Signed-off-by: …

Lire la suite

Staging: most: Replace pr_err with dev_err

Author: Bhumika Goyal <bhumirks@gmail.com> All devm functions has a device structure as the first argument which is required by dev_{err,info,dbg} printing functions. This patch converts pr_err to dev_err as dev_* is preferred after calls to devm functions. Done using coccinelle: @r1 exists@ expression e,e1; identifier f =~ « ^devm_ »; identifier g =~ « ^pcim_ »; identifier h =~ …

Lire la suite

staging: rdma: hfi1: file_ops: Replace ALIGN with PAGE_ALIGN

Author: Amitoj Kaur Chawla <amitoj1606@gmail.com> mm.h contains a helper function PAGE_ALIGN which aligns the pointer to the page boundary instead of using ALIGN(expression, PAGE_SIZE) This change was made with the help of the following Coccinelle semantic patch: // @@ expression e; symbol PAGE_SIZE; @@ ( – ALIGN(e, PAGE_SIZE) + PAGE_ALIGN(e) | – IS_ALIGNED(e, PAGE_SIZE) + …

Lire la suite

staging: rdma: hfi1: driver: Replace IS_ALIGNED with PAGE_ALIGNED

Author: Amitoj Kaur Chawla <amitoj1606@gmail.com> mm.h contains a helper function PAGE_ALIGNED which tests whether an address is aligned to PAGE_SIZE instead of using IS_ALIGNED(expression, PAGE_SIZE) This change was made with the help of the following Coccinelle semantic patch: // @@ expression e; symbol PAGE_SIZE; @@ ( – ALIGN(e, PAGE_SIZE) + PAGE_ALIGN(e) | – IS_ALIGNED(e, PAGE_SIZE) …

Lire la suite

staging: rdma: hfi1: Replace ALIGN with PAGE_ALIGN

Author: Amitoj Kaur Chawla <amitoj1606@gmail.com> mm.h contains a helper function PAGE_ALIGN which aligns the pointer to the page boundary instead of using ALIGN(expression, PAGE_SIZE) This change was made with the help of the following Coccinelle semantic patch: // @@ expression e; symbol PAGE_SIZE; @@ ( – ALIGN(e, PAGE_SIZE) + PAGE_ALIGN(e) | – IS_ALIGNED(e, PAGE_SIZE) + …

Lire la suite

Staging: fsl-mc: Replace pr_err with dev_err

Author: Bhumika Goyal <bhumirks@gmail.com> This patch replaces pr_err calls with dev_err when the device structure is available as dev_* prints identifying information about the struct device. Done using coccinelle: @r exists@ identifier f, s; identifier x; position p; @@ f(…,struct s *x,…) { } @r2@ identifier fld2; identifier r.s; @@ struct s { … struct …

Lire la suite

Staging: fsl-mc: Replace pr_debug with dev_dbg

Author: Bhumika Goyal <bhumirks@gmail.com> This patch replaces pr_debug calls with dev_dbg when the device structure is available as dev_* prints identifying information about the struct device. Done using coccinelle: @r exists@ identifier f, s; identifier x; position p; @@ f(…,struct s *x,…) { } @r2@ identifier fld2; identifier r.s; @@ struct s { … struct …

Lire la suite

drivers: staging: rtl8723au: remove unneeded null test

Author: Cihangir Akturk <cakturk@gmail.com> null test on pnetwork removed, because the iterator variable list_for_each_entry_safe cannot be null. This commit fixes the following error reported by coccinelle: drivers/staging/rtl8723au/core/rtw_mlme.c:1621:7-15: ERROR: iterator variable bound on line 1620 cannot be NULL Signed-off-by: Cihangir Akturk Acked-by: Jes Sorensen Signed-off-by: Greg Kroah-Hartman — drivers/staging/rtl8723au/core/rtw_mlme.c | 13 ++———– 1 file changed, 2 …

Lire la suite

tipc: safely copy UDP netlink data from user

Author: Richard Alpe <richard.alpe@ericsson.com> The netlink policy for TIPC_NLA_UDP_LOCAL and TIPC_NLA_UDP_REMOTE is of type binary with a defined length. This causes the policy framework to threat the defined length as maximum length. There is however no protection against a user sending a smaller amount of data. Prior to this patch this wasn’t handled which could …

Lire la suite

stmmac: fix noderef.cocci warnings

Author: Wu Fengguang <fengguang.wu@intel.com> drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c:115:15-21: ERROR: application of sizeof to pointer sizeof when applied to a pointer typed expression gives the size of the pointer Generated by: scripts/coccinelle/misc/noderef.cocci CC: Giuseppe Cavallaro Signed-off-by: Fengguang Wu Signed-off-by: David S. Miller — drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)   diff –git a/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c b/drivers/net/ethernet/stmicro/stmmac/stmmac_platform.c …

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.