Re: [PATCH 3/4] SWDEV-227979 - Add 4k resolution for virtual display

2020-03-25 Thread Alex Deucher
On Wed, Mar 25, 2020 at 4:33 AM Emily Deng  wrote:
>
> Add 4k resolution for virtual connector.
>
> Signed-off-by: Emily Deng 

Please fix the patch title.  With that fixed:
Reviewed-by: Alex Deucher 

> ---
>  drivers/gpu/drm/amd/amdgpu/dce_virtual.c | 10 +++---
>  1 file changed, 7 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/dce_virtual.c 
> b/drivers/gpu/drm/amd/amdgpu/dce_virtual.c
> index 3c9f2d2..8656cb7 100644
> --- a/drivers/gpu/drm/amd/amdgpu/dce_virtual.c
> +++ b/drivers/gpu/drm/amd/amdgpu/dce_virtual.c
> @@ -281,7 +281,7 @@ static int dce_virtual_get_modes(struct drm_connector 
> *connector)
> static const struct mode_size {
> int w;
> int h;
> -   } common_modes[17] = {
> +   } common_modes[21] = {
> { 640,  480},
> { 720,  480},
> { 800,  600},
> @@ -298,10 +298,14 @@ static int dce_virtual_get_modes(struct drm_connector 
> *connector)
> {1680, 1050},
> {1600, 1200},
> {1920, 1080},
> -   {1920, 1200}
> +   {1920, 1200},
> +   {4096, 3112},
> +   {3656, 2664},
> +   {3840, 2160},
> +   {4096, 2160},
> };
>
> -   for (i = 0; i < 17; i++) {
> +   for (i = 0; i < 21; i++) {
> mode = drm_cvt_mode(dev, common_modes[i].w, 
> common_modes[i].h, 60, false, false, false);
> drm_mode_probed_add(connector, mode);
> }
> --
> 2.7.4
>
> ___
> amd-gfx mailing list
> amd-gfx@lists.freedesktop.org
> https://lists.freedesktop.org/mailman/listinfo/amd-gfx
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx


RE: [PATCH 3/4] SWDEV-227979 - Add 4k resolution for virtual display

2020-03-25 Thread Liu, Monk
Reviewed-by: Monk Liu < monk@amd.com>

_
Monk Liu|GPU Virtualization Team |AMD


-Original Message-
From: amd-gfx  On Behalf Of Emily Deng
Sent: Wednesday, March 25, 2020 4:33 PM
To: amd-gfx@lists.freedesktop.org
Cc: Deng, Emily 
Subject: [PATCH 3/4] SWDEV-227979 - Add 4k resolution for virtual display

Add 4k resolution for virtual connector.

Signed-off-by: Emily Deng 
---
 drivers/gpu/drm/amd/amdgpu/dce_virtual.c | 10 +++---
 1 file changed, 7 insertions(+), 3 deletions(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/dce_virtual.c 
b/drivers/gpu/drm/amd/amdgpu/dce_virtual.c
index 3c9f2d2..8656cb7 100644
--- a/drivers/gpu/drm/amd/amdgpu/dce_virtual.c
+++ b/drivers/gpu/drm/amd/amdgpu/dce_virtual.c
@@ -281,7 +281,7 @@ static int dce_virtual_get_modes(struct drm_connector 
*connector)
static const struct mode_size {
int w;
int h;
-   } common_modes[17] = {
+   } common_modes[21] = {
{ 640,  480},
{ 720,  480},
{ 800,  600},
@@ -298,10 +298,14 @@ static int dce_virtual_get_modes(struct drm_connector 
*connector)
{1680, 1050},
{1600, 1200},
{1920, 1080},
-   {1920, 1200}
+   {1920, 1200},
+   {4096, 3112},
+   {3656, 2664},
+   {3840, 2160},
+   {4096, 2160},
};
 
-   for (i = 0; i < 17; i++) {
+   for (i = 0; i < 21; i++) {
mode = drm_cvt_mode(dev, common_modes[i].w, common_modes[i].h, 
60, false, false, false);
drm_mode_probed_add(connector, mode);
}
-- 
2.7.4

___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://nam11.safelinks.protection.outlook.com/?url=https%3A%2F%2Flists.freedesktop.org%2Fmailman%2Flistinfo%2Famd-gfxdata=02%7C01%7Cmonk.liu%40amd.com%7Cf39c6d882b174facb0b108d7d09740f4%7C3dd8961fe4884e608e11a82d994e183d%7C0%7C0%7C637207220392464369sdata=NV0xdvR4f%2B76237I5pM8Zd02IU1ZzPZHXpeu8%2BlGb70%3Dreserved=0
___
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx