diff options
author | Emily.Deng <Emily.Deng@amd.com> | 2020-12-11 11:38:54 +0800 |
---|---|---|
committer | Alex Deucher <alexander.deucher@amd.com> | 2021-01-08 15:18:05 -0500 |
commit | 1eb2aae31e9fdf32142cc8d5446aca2dfe5b58cb (patch) | |
tree | f7f6a8ae799f22363221fbebe196071d4732191f /drivers/gpu/drm/amd/amdgpu/dce_virtual.c | |
parent | 8768ff5efae35acea81b3f0c7db6a7ef519b0861 (diff) | |
download | linux-stable-1eb2aae31e9fdf32142cc8d5446aca2dfe5b58cb.tar.gz linux-stable-1eb2aae31e9fdf32142cc8d5446aca2dfe5b58cb.tar.bz2 linux-stable-1eb2aae31e9fdf32142cc8d5446aca2dfe5b58cb.zip |
drm/amdgpu: Add new mode 2560x1440
Add one more 2k resolution which appears frequently in market.
Signed-off-by: Emily.Deng <Emily.Deng@amd.com>
Acked-by: Alex Deucher <alexander.deucher@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd/amdgpu/dce_virtual.c')
-rw-r--r-- | drivers/gpu/drm/amd/amdgpu/dce_virtual.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/dce_virtual.c b/drivers/gpu/drm/amd/amdgpu/dce_virtual.c index ffcc64ec6473..9810af712cc0 100644 --- a/drivers/gpu/drm/amd/amdgpu/dce_virtual.c +++ b/drivers/gpu/drm/amd/amdgpu/dce_virtual.c @@ -294,7 +294,7 @@ static int dce_virtual_get_modes(struct drm_connector *connector) static const struct mode_size { int w; int h; - } common_modes[21] = { + } common_modes[] = { { 640, 480}, { 720, 480}, { 800, 600}, @@ -312,13 +312,14 @@ static int dce_virtual_get_modes(struct drm_connector *connector) {1600, 1200}, {1920, 1080}, {1920, 1200}, + {2560, 1440}, {4096, 3112}, {3656, 2664}, {3840, 2160}, {4096, 2160}, }; - for (i = 0; i < 21; i++) { + for (i = 0; i < ARRAY_SIZE(common_modes); i++) { mode = drm_cvt_mode(dev, common_modes[i].w, common_modes[i].h, 60, false, false, false); drm_mode_probed_add(connector, mode); } |