OSDN Git Service

drm/amd/display: DC VM Fixes
authorEryk Brol <eryk.brol@amd.com>
Mon, 21 Jan 2019 19:40:16 +0000 (14:40 -0500)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 6 Feb 2019 18:30:12 +0000 (13:30 -0500)
commit00fbeb4e2f9eda0ebd57eefdcf25e41958f98fa5
tree16ca74fccf53575c3b022aa7bffc47cdb3981141
parentb9d4b33059b86147bcde8f53ad19b97792837f75
drm/amd/display: DC VM Fixes

[Why]
VM_helper needs to be intialized with the dc struct in order to fix
an unallocated memory issue. System aperture settings should be
initialized to 0 and guarded with a check to make sure vm_config
is valid.

[How]
Allocate and free memory for vm_helper with other dc members.
Check whether the vm_config valid bit is set before initializing
aperture settings.

Signed-off-by: Eryk Brol <eryk.brol@amd.com>
Reviewed-by: Jun Lei <Jun.Lei@amd.com>
Acked-by: Bhawanpreet Lakha <Bhawanpreet.Lakha@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/display/dc/core/dc.c
drivers/gpu/drm/amd/display/dc/core/dc_vm_helper.c
drivers/gpu/drm/amd/display/dc/dc.h
drivers/gpu/drm/amd/display/dc/inc/vm_helper.h