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: NThierry Reding <treding@nvidia.com> Signed-off-by: NJérémy Lefaure <jeremy.lefaure@lse.epita.fr> Signed-off-by: NBen Skeggs <bskeggs@redhat.com>
Showing
想要评论请 注册 或 登录