Commit b91fbdc1 authored by kernel test robot's avatar kernel test robot Committed by Noralf Trønnes

drm/gud: fix sizeof use

drivers/gpu/drm/gud/gud_connector.c:710:37-43: 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

Fixes: 40e1a70b ("drm: Add GUD USB Display driver")
Reported-by: default avatarkernel test robot <lkp@intel.com>
Signed-off-by: default avatarkernel test robot <lkp@intel.com>
[fix subject]
Signed-off-by: default avatarNoralf Trønnes <noralf@tronnes.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20210322174434.58849-1-noralf@tronnes.org
parent 458025f6
......@@ -707,7 +707,7 @@ int gud_get_connectors(struct gud_device *gdrm)
return -ENOMEM;
ret = gud_usb_get(gdrm, GUD_REQ_GET_CONNECTORS, 0,
descs, GUD_CONNECTORS_MAX_NUM * sizeof(descs));
descs, GUD_CONNECTORS_MAX_NUM * sizeof(*descs));
if (ret < 0)
goto free;
if (!ret || ret % sizeof(*descs)) {
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment