Commit 836dab85 authored by Alex Deucher's avatar Alex Deucher

drm/amdgpu/atomfirmware: update vram info handling for renoir

Add support for integrated_system_info table v12.  Use the actual
v12 structure.
Acked-by: default avatarEvan Quan <evan.quan@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 2fde24e4
...@@ -111,6 +111,7 @@ int amdgpu_atomfirmware_allocate_fb_scratch(struct amdgpu_device *adev) ...@@ -111,6 +111,7 @@ int amdgpu_atomfirmware_allocate_fb_scratch(struct amdgpu_device *adev)
union igp_info { union igp_info {
struct atom_integrated_system_info_v1_11 v11; struct atom_integrated_system_info_v1_11 v11;
struct atom_integrated_system_info_v1_12 v12;
}; };
union umc_info { union umc_info {
...@@ -206,7 +207,6 @@ amdgpu_atomfirmware_get_vram_info(struct amdgpu_device *adev, ...@@ -206,7 +207,6 @@ amdgpu_atomfirmware_get_vram_info(struct amdgpu_device *adev,
(mode_info->atom_context->bios + data_offset); (mode_info->atom_context->bios + data_offset);
switch (crev) { switch (crev) {
case 11: case 11:
case 12:
mem_channel_number = igp_info->v11.umachannelnumber; mem_channel_number = igp_info->v11.umachannelnumber;
/* channel width is 64 */ /* channel width is 64 */
if (vram_width) if (vram_width)
...@@ -215,6 +215,15 @@ amdgpu_atomfirmware_get_vram_info(struct amdgpu_device *adev, ...@@ -215,6 +215,15 @@ amdgpu_atomfirmware_get_vram_info(struct amdgpu_device *adev,
if (vram_type) if (vram_type)
*vram_type = convert_atom_mem_type_to_vram_type(adev, mem_type); *vram_type = convert_atom_mem_type_to_vram_type(adev, mem_type);
break; break;
case 12:
mem_channel_number = igp_info->v12.umachannelnumber;
/* channel width is 64 */
if (vram_width)
*vram_width = mem_channel_number * 64;
mem_type = igp_info->v12.memorytype;
if (vram_type)
*vram_type = convert_atom_mem_type_to_vram_type(adev, mem_type);
break;
default: default:
return -EINVAL; return -EINVAL;
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment