drm/amd/display: Check bss_data_size before going down legacy DMUB load path
authorNicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Thu, 30 Apr 2020 16:18:16 +0000 (12:18 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Thu, 28 May 2020 18:00:48 +0000 (14:00 -0400)
commit08a512d4ab2f32c6b06ea89bb8a707a66c3ec13d
treecdac3472db582903c20779450b889c9cb2310af2
parent65f9ace4acc1dbfc85e3cecd5aad0fb9ca165ef2
drm/amd/display: Check bss_data_size before going down legacy DMUB load path

[Why]
New unified firmware binary with only inst const still passes down
fw_bss_data != NULL and params->bss_data_size == 0 from DM.

This leads it into the legacy path causing firmware state allocation to
be too small.

[How]
Check bss_data_size as well.

Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com>
Reviewed-by: Zhan Liu <Zhan.Liu@amd.com>
Acked-by: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dmub/src/dmub_srv.c