mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-10 18:40:25 -04:00
drm/amd/display: Guard against NULL link encoder in log hw state
[Why & How] Check lenc is not NULL since dynamic link encoder assignment could end up assigning a NULL link encoder. Reviewed-by: Michael Strauss <Michael.Strauss@amd.com> Acked-by: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com> Signed-off-by: Nicholas Kazlauskas <nicholas.kazlauskas@amd.com> Tested-by: Daniel Wheeler <daniel.wheeler@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
committed by
Alex Deucher
parent
0c7ea6f824
commit
1daf740137
@@ -444,7 +444,7 @@ void dcn10_log_hw_state(struct dc *dc,
|
||||
|
||||
struct link_enc_state s = {0};
|
||||
|
||||
if (lenc->funcs->read_state) {
|
||||
if (lenc && lenc->funcs->read_state) {
|
||||
lenc->funcs->read_state(lenc, &s);
|
||||
DTN_INFO("[%-3d]: %-12d %-22d %-22d %-25d\n",
|
||||
i,
|
||||
|
||||
Reference in New Issue
Block a user