]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amd/display: fix mapping to non-allocated address
authorBrandon Syu <Brandon.Syu@amd.com>
Thu, 22 Dec 2022 08:43:37 +0000 (16:43 +0800)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 10 Mar 2023 08:33:56 +0000 (09:33 +0100)
commit142009dbf7839c36024c4332e13d7ae9c4171593
tree6a18f06558fc29f875c62cd78e7b72f210dace6e
parent869352c1f482d633a9f707ca4d02ff316dd67c83
drm/amd/display: fix mapping to non-allocated address

[ Upstream commit ea377a0650ea50780c5d5933f1ff679199ddcc25 ]

[Why]
There is an issue mapping non-allocated location of memory.
It would allocate gpio registers from an array out of bounds.

[How]
Patch correct numbers of bounds for using.

Tested-by: Daniel Wheeler <Daniel.Wheeler@amd.com>
Reviewed-by: Martin Leung <Martin.Leung@amd.com>
Acked-by: Rodrigo Siqueira <Rodrigo.Siqueira@amd.com>
Signed-off-by: Brandon Syu <Brandon.Syu@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/gpu/drm/amd/display/dc/gpio/dcn20/hw_factory_dcn20.c
drivers/gpu/drm/amd/display/dc/gpio/dcn30/hw_factory_dcn30.c
drivers/gpu/drm/amd/display/dc/gpio/dcn32/hw_factory_dcn32.c
drivers/gpu/drm/amd/display/dc/gpio/ddc_regs.h