[PATCH] amd/amdgpu: optimise CONFIG_X||CONFIG_X_MODULE to IS_ENABLED(X)

2020-11-18 Thread Bernard Zhao
Optimise CONFIG_ || CONFIG__MODULE to IS_ENABLED(). This change also fix check_patch.pl warning: WARNING: Prefer IS_ENABLED() to CONFIG_ || CONFIG__MODULE +#if defined(CONFIG_BACKLIGHT_CLASS_DEVICE) || defined (CONFIG_BACKLIGHT_CLASS_DEVICE_MODULE) Signed-off-by: Bernard Zhao --- drivers/gpu/drm

Re: [PATCH] amdgpu/amdgpu_ids: fix kmalloc_array not uses number as first arg

2020-11-18 Thread Christian König
Am 18.11.20 um 03:42 schrieb Bernard Zhao: Fix check_patch.pl warning: kmalloc_array uses number as first arg, sizeof is generally wrong. +fences = kmalloc_array(sizeof(void *), id_mgr->num_ids, GFP_KERNEL); Signed-off-by: Bernard Zhao Reviewed-by: Christian König --- drivers/gpu/drm/amd

Re: [PATCH] amd/amdgpu: use kmalloc_array to replace kmalloc with multiply

2020-11-18 Thread Christian König
Am 18.11.20 um 03:55 schrieb Bernard Zhao: Fix check_patch.pl warning: WARNING: Prefer kmalloc_array over kmalloc with multiply +bps = kmalloc(align_space * sizeof((*data)->bps), GFP_KERNEL); WARNING: Prefer kmalloc_array over kmalloc with multiply +bps_bo = kmalloc(align_space * sizeof((*data)->

Re: [PATCH] amd/amdgpu: optimise CONFIG_X||CONFIG_X_MODULE to IS_ENABLED(X)

2020-11-18 Thread Christian König
Am 18.11.20 um 04:43 schrieb Bernard Zhao: Optimise CONFIG_ || CONFIG__MODULE to IS_ENABLED(). This change also fix check_patch.pl warning: WARNING: Prefer IS_ENABLED() to CONFIG_ || CONFIG__MODULE +#if defined(CONFIG_BACKLIGHT_CLASS_DEVICE) || defined (CONFIG_BACKLIGHT_CLASS_DEVICE_MODULE) Sign

Re: [PATCH] drm/amdgpu/dc: Pixel encoding DRM property and module parameter

2020-11-18 Thread James Ettle
On 28/09/2020 21:12, Kazlauskas, Nicholas wrote: DRM modes don't specify the encoding. The property as part of this patch lets userspace override it but the userspace GUI support isn't there on Wayland IIRC. I'm fine with adding the properties but I don't think the module parameter is the r

Re: [PATCH v2 8/8] drm/amdgpu: Prevent any job recoveries after device is unplugged.

2020-11-18 Thread Christian König
Am 18.11.20 um 08:39 schrieb Daniel Vetter: On Tue, Nov 17, 2020 at 9:07 PM Andrey Grodzovsky wrote: On 11/17/20 2:49 PM, Daniel Vetter wrote: On Tue, Nov 17, 2020 at 02:18:49PM -0500, Andrey Grodzovsky wrote: On 11/17/20 1:52 PM, Daniel Vetter wrote: On Tue, Nov 17, 2020 at 01:38:14PM -050

[PATCH] drm/amdgpu: Add gfx doorbell setting for Vangogh

2020-11-18 Thread Jinzhou Su
Using KIQ to map GFX queues instead of MMIO for gfx async ring, add missing doorbell range setting. Signed-off-by: Jinzhou.Su --- drivers/gpu/drm/amd/amdgpu/gfx_v10_0.c | 24 ++-- 1 file changed, 14 insertions(+), 10 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v

[PATCH] drm/amdgpu: unpack dma_fence_chain containers during sync

2020-11-18 Thread Christian König
This allows for optimizing the CPU round trip away. Signed-off-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_sync.c | 27 drivers/gpu/drm/amd/amdgpu/amdgpu_sync.h | 1 + 3 files changed, 29 insertions(+), 1 d

Re: [PATCH 04/40] drm/amd/amdgpu/amdgpu_drv: Move 'amdgpu_info_ioctl()'s prototype to shared header

2020-11-18 Thread Lee Jones
On Fri, 13 Nov 2020, Alex Deucher wrote: > On Fri, Nov 13, 2020 at 8:49 AM Lee Jones wrote: > > > > Fixes the following W=1 kernel build warning(s): > > > > drivers/gpu/drm/amd/amdgpu/amdgpu_kms.c:486:5: warning: no previous > > prototype for ‘amdgpu_info_ioctl’ [-Wmissing-prototypes] > > 486

Re: [PATCH v2 8/8] drm/amdgpu: Prevent any job recoveries after device is unplugged.

2020-11-18 Thread Luben Tuikov
On 2020-11-18 07:01, Christian König wrote: > Am 18.11.20 um 08:39 schrieb Daniel Vetter: >> On Tue, Nov 17, 2020 at 9:07 PM Andrey Grodzovsky >> wrote: >>> >>> On 11/17/20 2:49 PM, Daniel Vetter wrote: On Tue, Nov 17, 2020 at 02:18:49PM -0500, Andrey Grodzovsky wrote: > On 11/17/20 1:52

Re: [PATCH v2 8/8] drm/amdgpu: Prevent any job recoveries after device is unplugged.

2020-11-18 Thread Andrey Grodzovsky
On 11/18/20 7:01 AM, Christian König wrote: Am 18.11.20 um 08:39 schrieb Daniel Vetter: On Tue, Nov 17, 2020 at 9:07 PM Andrey Grodzovsky wrote: On 11/17/20 2:49 PM, Daniel Vetter wrote: On Tue, Nov 17, 2020 at 02:18:49PM -0500, Andrey Grodzovsky wrote: On 11/17/20 1:52 PM, Daniel Vetter w

[PATCH v3 0/5] drm/amdgpu/vcn: support dec software ring

2020-11-18 Thread James Zhu
This serials of patches add vcn dec software ring support. v2: clear compilation warning. V3: replace module parameter with macro refactor dec message functions James Zhu (5): drm/amdgpu/vcn: refactor dec message functions drm/amdgpu/vcn: update header to support dec vcn software ring d

[PATCH v3 2/5] drm/amdgpu/vcn: update header to support dec vcn software ring

2020-11-18 Thread James Zhu
Add macro, structure and function prototype to support dec vcn software ring. Signed-off-by: James Zhu Reviewed-by: Leo Liu --- drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.h | 30 ++ 1 file changed, 30 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.h b/

[PATCH v3 3/5] drm/amdgpu/vcn: add test for dec vcn software ring

2020-11-18 Thread James Zhu
Add vcn software ring decode ring test and decode ib test. Signed-off-by: James Zhu Reviewed-by: Leo Liu --- drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.c | 121 1 file changed, 121 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.c b/drivers/gpu/drm

[PATCH v3 1/5] drm/amdgpu/vcn: refactor dec message functions

2020-11-18 Thread James Zhu
refactor dec message functions to add dec software ring support. Signed-off-by: James Zhu --- drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.c | 30 +++--- 1 file changed, 19 insertions(+), 11 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.c b/drivers/gpu/drm/am

[PATCH v3 4/5] drm/amdgpu/vcn3.0: add dec software ring vm functions to support

2020-11-18 Thread James Zhu
Add dec software ring vm functions to support. Signed-off-by: James Zhu Reviewed-by: Leo Liu --- drivers/gpu/drm/amd/amdgpu/vcn_v3_0.c | 101 +- 1 file changed, 99 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/vcn_v3_0.c b/drivers/gpu/dr

[PATCH v3 5/5] drm/amdgpu/vcn3.0: add software ring share memory support

2020-11-18 Thread James Zhu
Support software ring share memory with vcn firmware. Signed-off-by: James Zhu Reviewed-by: Leo Liu --- drivers/gpu/drm/amd/amdgpu/vcn_v3_0.c | 35 +++ 1 file changed, 31 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/vcn_v3_0.c b/drivers

Re: [PATCH v3 2/5] drm/amdgpu/vcn: update header to support dec vcn software ring

2020-11-18 Thread Luben Tuikov
On 2020-11-18 11:23, James Zhu wrote: > Add macro, structure and function prototype to > support dec vcn software ring. > > Signed-off-by: James Zhu > Reviewed-by: Leo Liu > --- > drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.h | 30 ++ > 1 file changed, 30 insertions(+) >

Re: [PATCH v3 2/5] drm/amdgpu/vcn: update header to support dec vcn software ring

2020-11-18 Thread James Zhu
On 2020-11-18 11:47 a.m., Luben Tuikov wrote: On 2020-11-18 11:23, James Zhu wrote: Add macro, structure and function prototype to support dec vcn software ring. Signed-off-by: James Zhu Reviewed-by: Leo Liu --- drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.h | 30 ++

[PATCH] drm/amd/display: Add DPCS regs for dcn302 link encoder

2020-11-18 Thread Bhawanpreet Lakha
dpcs reg are missing for dcn302 link encoder regs list, so add them. Just like dcn3 Signed-off-by: Bhawanpreet Lakha --- drivers/gpu/drm/amd/display/dc/dcn302/dcn302_resource.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/amd/display/dc/dcn302/dcn302_resource.c b/drivers/

[pull] amdgpu drm-fixes-5.10

2020-11-18 Thread Alex Deucher
Hi Dave, Daniel, Fixes for 5.10. The following changes since commit 8f598d15ee6577a56d6617d9e4151591db34d8fa: Merge branch 'linux-5.10' of git://github.com/skeggsb/linux into drm-fixes (2020-11-16 06:36:31 +1000) are available in the Git repository at: git://people.freedesktop.org/~agd5f/

[PATCH] drm/amd/display: change license of color_table.c

2020-11-18 Thread Jonathan Gray
Change the license of color_table.c to match color_table.h granting permission to modify and distribute. Signed-off-by: Jonathan Gray --- .../amd/display/modules/color/color_table.c | 26 +++ 1 file changed, 21 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/amd/dis

Re: [PATCH v3 1/5] drm/amdgpu/vcn: refactor dec message functions

2020-11-18 Thread Christian König
Am 18.11.20 um 17:23 schrieb James Zhu: refactor dec message functions to add dec software ring support. Signed-off-by: James Zhu --- drivers/gpu/drm/amd/amdgpu/amdgpu_vcn.c | 30 +++--- 1 file changed, 19 insertions(+), 11 deletions(-) diff --git a/drivers/gpu/drm/a