]> git.baikalelectronics.ru Git - kernel.git/commit
drm/bridge: Avoid uninitialized variable warning
authorDan Carpenter <dan.carpenter@oracle.com>
Mon, 4 Jul 2022 10:55:40 +0000 (13:55 +0300)
committerMaxime Ripard <maxime@cerno.tech>
Fri, 8 Jul 2022 11:41:28 +0000 (13:41 +0200)
commit9398fd3c695bb04b7f3135081e32cfea85828cef
tree807e5af2caf60217e840aa522cd62b9d87157e1d
parentc67a9f2b340b5bcb3c601508acbc3c98a0bfa966
drm/bridge: Avoid uninitialized variable warning

This code works, but technically it uses "num_in_bus_fmts" before it
has been initialized so it leads to static checker warnings and probably
KMEMsan warnings at run time.  Initialize the variable to zero to
silence the warning.

Fixes: 9c842e43118f ("drm/bridge: Add the necessary bits to support bus format negotiation")
Signed-off-by: Dan Carpenter <dan.carpenter@oracle.com>
Signed-off-by: Maxime Ripard <maxime@cerno.tech>
Link: https://patchwork.freedesktop.org/patch/msgid/YrrIs3hoGcPVmXc5@kili
drivers/gpu/drm/drm_bridge.c