Commit d534ca71 authored by Alex Deucher's avatar Alex Deucher

drm/amdgpu: differentiate between LP and non-LP DDR memory

Some applications want to know whether the memory is LP or
not.
Reviewed-by: default avatarHawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent a5457087
...@@ -188,13 +188,17 @@ static int convert_atom_mem_type_to_vram_type(struct amdgpu_device *adev, ...@@ -188,13 +188,17 @@ static int convert_atom_mem_type_to_vram_type(struct amdgpu_device *adev,
vram_type = AMDGPU_VRAM_TYPE_DDR3; vram_type = AMDGPU_VRAM_TYPE_DDR3;
break; break;
case Ddr4MemType: case Ddr4MemType:
case LpDdr4MemType:
vram_type = AMDGPU_VRAM_TYPE_DDR4; vram_type = AMDGPU_VRAM_TYPE_DDR4;
break; break;
case LpDdr4MemType:
vram_type = AMDGPU_VRAM_TYPE_LPDDR4;
break;
case Ddr5MemType: case Ddr5MemType:
case LpDdr5MemType:
vram_type = AMDGPU_VRAM_TYPE_DDR5; vram_type = AMDGPU_VRAM_TYPE_DDR5;
break; break;
case LpDdr5MemType:
vram_type = AMDGPU_VRAM_TYPE_LPDDR5;
break;
default: default:
vram_type = AMDGPU_VRAM_TYPE_UNKNOWN; vram_type = AMDGPU_VRAM_TYPE_UNKNOWN;
break; break;
......
...@@ -1018,7 +1018,9 @@ static const char *amdgpu_vram_names[] = { ...@@ -1018,7 +1018,9 @@ static const char *amdgpu_vram_names[] = {
"DDR3", "DDR3",
"DDR4", "DDR4",
"GDDR6", "GDDR6",
"DDR5" "DDR5",
"LPDDR4",
"LPDDR5"
}; };
/** /**
......
...@@ -988,6 +988,8 @@ struct drm_amdgpu_info_vbios { ...@@ -988,6 +988,8 @@ struct drm_amdgpu_info_vbios {
#define AMDGPU_VRAM_TYPE_DDR4 8 #define AMDGPU_VRAM_TYPE_DDR4 8
#define AMDGPU_VRAM_TYPE_GDDR6 9 #define AMDGPU_VRAM_TYPE_GDDR6 9
#define AMDGPU_VRAM_TYPE_DDR5 10 #define AMDGPU_VRAM_TYPE_DDR5 10
#define AMDGPU_VRAM_TYPE_LPDDR4 11
#define AMDGPU_VRAM_TYPE_LPDDR5 12
struct drm_amdgpu_info_device { struct drm_amdgpu_info_device {
/** PCI Device ID */ /** PCI Device ID */
......
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