Skip to content
Commit 73cef6ce authored by Jérémy Lefaure's avatar Jérémy Lefaure Committed by Ben Skeggs
Browse files

drm/nouveau/bios/init: use ARRAY_SIZE



Using the ARRAY_SIZE macro improves the readability of the code. Also,
it is useless to re-invent it.

Found with Coccinelle with the following semantic patch:
@r depends on (org || report)@
type T;
T[] E;
position p;
@@
(
 (sizeof(E)@p /sizeof(*E))
|
 (sizeof(E)@p /sizeof(E[...]))
|
 (sizeof(E)@p /sizeof(T))
)

Reviewed-by: default avatarThierry Reding <treding@nvidia.com>
Signed-off-by: default avatarJérémy Lefaure <jeremy.lefaure@lse.epita.fr>
Signed-off-by: default avatarBen Skeggs <bskeggs@redhat.com>
parent f5a5b523
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment