[PATCH] drm/amd/display: Remove duplicate header.

2022-07-07 Thread Souptick Joarder
From: "Souptick Joarder (HPE)" kernel test robot throws below warning -> includecheck warnings: (new ones prefixed by >>) >> drivers/gpu/drm/amd/display/dc/os_types.h: drm/drm_print.h is included more than once. Remove duplicate header. Reported-by: kernel test robot Signed-off-by: Souptick

[PATCH] drm/amd/display: Remove condition with no effect

2022-07-07 Thread Zhongjun Tan
From: Zhongjun Tan Remove condition with no effect Signed-off-by: Zhongjun Tan --- .../drm/amd/display/dc/dml/dcn32/display_mode_vba_util_32.c | 4 1 file changed, 4 deletions(-) diff --git a/drivers/gpu/drm/amd/display/dc/dml/dcn32/display_mode_vba_util_32.c b/drivers/gpu/drm/amd/di

[PATCH] drm/amd/display: fix 32 bit compilation errors in dc_dmub_srv.c

2022-07-07 Thread Alex Deucher
There are several things wrong here. First, none of these numbers are FP, so there is no need to cast to double. Next make sure to use proper 64 bit division helpers. Fixes: 85f4bc0c333c ("drm/amd/display: Add SubVP required code") Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/display/dc

RE: [PATCH] drm/amd/pm: ac/dc change for smu_v13_0

2022-07-07 Thread Quan, Evan
[AMD Official Use Only - General] > -Original Message- > From: amd-gfx On Behalf Of > Kenneth Feng > Sent: Thursday, July 7, 2022 10:27 PM > To: amd-gfx@lists.freedesktop.org > Cc: Feng, Kenneth > Subject: [PATCH] drm/amd/pm: ac/dc change for smu_v13_0 > > fixed the issue: gpu runs in

RE: [PATCH] drm/amd/display: Revert "drm/amd/display: disable idle optimizations"

2022-07-07 Thread Quan, Evan
[AMD Official Use Only - General] Reviewed-and-tested-by: Evan Quan > -Original Message- > From: amd-gfx On Behalf Of > Aurabindo Pillai > Sent: Friday, July 8, 2022 5:21 AM > To: amd-gfx@lists.freedesktop.org > Cc: Deucher, Alexander ; Siqueira, Rodrigo > ; Pillai, Aurabindo > ; Wentla

[PATCH] drm/amdgpu: Remove one duplicated ef removal

2022-07-07 Thread xinhui pan
That has been done in BO release notify. Signed-off-by: xinhui pan --- drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c | 5 - 1 file changed, 5 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c index 0f9811d02f61.

RE: [PATCH] drm/amdgpu: Fix a NULL pointer of fence

2022-07-07 Thread Pan, Xinhui
[AMD Official Use Only - General] Felix, Shared fences depend on exclusive fence, so add a new exclusive fence, say NULL would also remove all shared fences. That works before 5.18 . 😉 From 5.18, adding a new exclusive fence(the write usage fence) did not remove any shared fences(the read usage

[linux-next:master] BUILD REGRESSION 75d7bf5eae277f32dd952276aa41ae7915dba1b2

2022-07-07 Thread kernel test robot
tree/branch: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master branch HEAD: 75d7bf5eae277f32dd952276aa41ae7915dba1b2 Add linux-next specific files for 20220707 Error/Warning: (recently discovered and may have been fixed) arm-linux-gnueabi-ld: dc_dmub_srv.c:(.text

RE: [PATCH] drm/amdkfd: Select PCI_P2PDMA and DMABUF_MOVE_NOTIFY instead of depending

2022-07-07 Thread Errabolu, Ramesh
[Public] Follow the dependency chain of either CONFIG_DMABUF_MOVE_NOTIFY or CONFIG_PCI_P2PDMA. What happens if you enable CONFIG_DMABUF_MOVE_NOTIFY but its dependency CONFIG_DMA_SHARED_BUFFER is not enabled. Therefore using "selects" is not the right way to go about it. Regards, Ramesh -

[PATCH 1/1] drm/amdkfd: Process notifier release callback don't take mutex

2022-07-07 Thread Philip Yang
Move process queues cleanup to deferred work kfd_process_wq_release, to avoid potential deadlock circular locking warning: WARNING: possible circular locking dependency detected the existing dependency chain (in reverse order) is: -> #2 ((work_completion)(&svms->defer

[PATCH] drm/amd/display: Revert "drm/amd/display: disable idle optimizations"

2022-07-07 Thread Aurabindo Pillai
This reverts commit e7ef5569e71bf3fec01ea513c27c6081c0dbbc64. Idle optimization was disabled due to SMU and firmware bugs. Enable it back for DCN32. DCN321 has them enabled already Fixes: e7ef5569e71b ("drm/amd/display: disable idle optimizations") Signed-off-by: Aurabindo Pillai --- drivers/gp

[PATCH] drm/amdgpu/gmc10: adjust gart size for parts that support S/G display

2022-07-07 Thread Alex Deucher
For GMC 10 parts which support scatter/gather display (display from system memory), we should allocate a larger gart size to better handler larger displays. This mirrors what we already do for GMC 9 parts. v2: fix typo (Alex) Signed-off-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/gmc_v10_0

Re: [PATCH] drm/amd/display: Fix unsigned expression compared with zero

2022-07-07 Thread Alex Deucher
On Thu, Jul 7, 2022 at 4:38 PM Harry Wentland wrote: > > > > On 2022-07-07 14:22, Alex Deucher wrote: > > On Wed, Jul 6, 2022 at 3:41 AM Zhongjun Tan wrote: > >> > >> From: Zhongjun Tan > >> > >> Fix unsigned expression compared with zero > >> > >> Signed-off-by: Zhongjun Tan > >> --- > >> ...

Re: [PATCH] drm/amd/display: Fix unsigned expression compared with zero

2022-07-07 Thread Harry Wentland
On 2022-07-07 14:22, Alex Deucher wrote: > On Wed, Jul 6, 2022 at 3:41 AM Zhongjun Tan wrote: >> >> From: Zhongjun Tan >> >> Fix unsigned expression compared with zero >> >> Signed-off-by: Zhongjun Tan >> --- >> .../gpu/drm/amd/display/dc/dml/dcn20/display_rq_dlg_calc_20.c | 4 ++-- >> 1 fil

RE: [PATCH] drm/amdkfd: Select PCI_P2PDMA and DMABUF_MOVE_NOTIFY instead of depending

2022-07-07 Thread Limonciello, Mario
[Public] > -Original Message- > From: Errabolu, Ramesh > Sent: Thursday, July 7, 2022 15:30 > To: Limonciello, Mario ; amd- > g...@lists.freedesktop.org; Kuehling, Felix > Cc: Limonciello, Mario > Subject: RE: [PATCH] drm/amdkfd: Select PCI_P2PDMA and > DMABUF_MOVE_NOTIFY instead of dep

RE: [PATCH] drm/amdkfd: Select PCI_P2PDMA and DMABUF_MOVE_NOTIFY instead of depending

2022-07-07 Thread Errabolu, Ramesh
[AMD Official Use Only - General] Using "depends" prevents shallow binding. Applying "select" can cause trouble. Regards, Ramesh -Original Message- From: amd-gfx On Behalf Of Mario Limonciello Sent: Thursday, July 7, 2022 3:12 PM To: amd-gfx@lists.freedesktop.org; Kuehling, Felix Cc:

[PATCH] drm/amdkfd: Select PCI_P2PDMA and DMABUF_MOVE_NOTIFY instead of depending

2022-07-07 Thread Mario Limonciello
By having dependencies on PCI_P2PDMA and DMABUF_MOVE_NOTIFY the option HSA_AMD_P2P is not discoverable. The kernel menu configuration hides it if the dependencies aren't satisfied, making it harder to find. Instead select these options when enabling HSA_AMD_P2P. This way distributions and users

[PATCH] drm/amd/display: Drop dm_sw_gfx7_2d_thin_l_vp and dm_sw_gfx7_2d_thin_gl

2022-07-07 Thread Maíra Canal
As the enum dm_sw_gfx7_2d_thin_gl and dm_sw_gfx7_2d_thin_l_vp are not used on the codebase, this commit drops those entries from enum dm_swizzle_mode. Signed-off-by: Maíra Canal --- .../dc/dml/dcn20/display_mode_vba_20.c| 26 +- .../dc/dml/dcn20/display_mode_vba_20v2.c

[PATCH v8 15/15] tools: add selftests to hmm for COW in device memory

2022-07-07 Thread Alex Sierra
The objective is to test device migration mechanism in pages marked as COW, for private and coherent device type. In case of writing to COW private page(s), a page fault will migrate pages back to system memory first. Then, these pages will be duplicated. In case of COW device coherent type, pages

[PATCH v8 12/15] tools: update hmm-test to support device coherent type

2022-07-07 Thread Alex Sierra
Test cases such as migrate_fault and migrate_multiple, were modified to explicit migrate from device to sys memory without the need of page faults, when using device coherent type. Snapshot test case updated to read memory device type first and based on that, get the proper returned results migrat

[PATCH v8 14/15] tools: add hmm gup tests for device coherent type

2022-07-07 Thread Alex Sierra
The intention is to test hmm device coherent type under different get user pages paths. Also, test gup with FOLL_LONGTERM flag set in device coherent pages. These pages should get migrated back to system memory. Signed-off-by: Alex Sierra Reviewed-by: Alistair Popple --- tools/testing/selftests

[PATCH v8 10/15] lib: test_hmm add module param for zone device type

2022-07-07 Thread Alex Sierra
In order to configure device coherent in test_hmm, two module parameters should be passed, which correspond to the SP start address of each device (2) spm_addr_dev0 & spm_addr_dev1. If no parameters are passed, private device type is configured. Signed-off-by: Alex Sierra Acked-by: Felix Kuehling

[PATCH v8 13/15] tools: update test_hmm script to support SP config

2022-07-07 Thread Alex Sierra
Add two more parameters to set spm_addr_dev0 & spm_addr_dev1 addresses. These two parameters configure the start SP addresses for each device in test_hmm driver. Consequently, this configures zone device type as coherent. Signed-off-by: Alex Sierra Acked-by: Felix Kuehling Reviewed-by: Alistair

[PATCH v8 11/15] lib: add support for device coherent type in test_hmm

2022-07-07 Thread Alex Sierra
Device Coherent type uses device memory that is coherently accesible by the CPU. This could be shown as SP (special purpose) memory range at the BIOS-e820 memory enumeration. If no SP memory is supported in system, this could be faked by setting CONFIG_EFI_FAKE_MEMMAP. Currently, test_hmm only sup

[PATCH v8 09/15] lib: test_hmm add ioctl to get zone device type

2022-07-07 Thread Alex Sierra
new ioctl cmd added to query zone device type. This will be used once the test_hmm adds zone device coherent type. Signed-off-by: Alex Sierra Acked-by: Felix Kuehling Reviewed-by: Alistair Poppple Signed-off-by: Christoph Hellwig --- lib/test_hmm.c | 11 +-- lib/test_hmm_uapi.h |

[PATCH v8 07/15] mm/gup: migrate device coherent pages when pinning instead of failing

2022-07-07 Thread Alex Sierra
From: Alistair Popple Currently any attempts to pin a device coherent page will fail. This is because device coherent pages need to be managed by a device driver, and pinning them would prevent a driver from migrating them off the device. However this is no reason to fail pinning of these pages.

[PATCH v8 08/15] drm/amdkfd: add SPM support for SVM

2022-07-07 Thread Alex Sierra
When CPU is connected throug XGMI, it has coherent access to VRAM resource. In this case that resource is taken from a table in the device gmc aperture base. This resource is used along with the device type, which could be DEVICE_PRIVATE or DEVICE_COHERENT to create the device page map region. Also

[PATCH v8 06/15] mm: remove the vma check in migrate_vma_setup()

2022-07-07 Thread Alex Sierra
From: Alistair Popple migrate_vma_setup() checks that a valid vma is passed so that the page tables can be walked to find the pfns associated with a given address range. However in some cases the pfns are already known, such as when migrating device coherent pages during pin_user_pages() meaning

[PATCH v8 01/15] mm: rename is_pinnable_pages to is_longterm_pinnable_pages

2022-07-07 Thread Alex Sierra
is_pinnable_page() and folio_is_pinnable() were renamed to is_longterm_pinnable_page() and folio_is_longterm_pinnable() respectively. These functions are used in the FOLL_LONGTERM flag context. Signed-off-by: Alex Sierra --- include/linux/mm.h | 8 mm/gup.c | 4 ++-- mm/gup_te

[PATCH v8 04/15] mm: handling Non-LRU pages returned by vm_normal_pages

2022-07-07 Thread Alex Sierra
With DEVICE_COHERENT, we'll soon have vm_normal_pages() return device-managed anonymous pages that are not LRU pages. Although they behave like normal pages for purposes of mapping in CPU page, and for COW. They do not support LRU lists, NUMA migration or THP. Callers to follow_page() currently do

[PATCH v8 05/15] mm: add device coherent vma selection for memory migration

2022-07-07 Thread Alex Sierra
This case is used to migrate pages from device memory, back to system memory. Device coherent type memory is cache coherent from device and CPU point of view. Signed-off-by: Alex Sierra Acked-by: Felix Kuehling Reviewed-by: Alistair Poppple Signed-off-by: Christoph Hellwig Reviewed-by: David H

[PATCH v8 02/15] mm: move page zone helpers into new header-specific file

2022-07-07 Thread Alex Sierra
[WHY] Have a cleaner way to expose all page zone helpers in one header file, rather than split them between mm.h and memremap.h files. Signed-off-by: Alex Sierra --- drivers/infiniband/core/rw.c | 1 - drivers/nvme/target/io-cmd-bdev.c | 1 - include/linux/memremap.h | 113 +---

[PATCH v8 03/15] mm: add zone device coherent type memory support

2022-07-07 Thread Alex Sierra
Device memory that is cache coherent from device and CPU point of view. This is used on platforms that have an advanced system bus (like CAPI or CXL). Any page of a process can be migrated to such memory. However, no one should be allowed to pin such memory so that it can always be evicted. Signed

[PATCH v8 00/15] Add MEMORY_DEVICE_COHERENT for coherent device memory mapping

2022-07-07 Thread Alex Sierra
This is our MEMORY_DEVICE_COHERENT patch series rebased and updated for current 5.19.0-rc5 Changes since the last version: - Fixed problems with migration during long-term pinning in get_user_pages - Open coded vm_normal_lru_pages as suggested in previous code review - Update hmm_gup_test with mor

Re: [PATCH 1/1] drm/amdgpu: Don't clear memory when PTB BO is released

2022-07-07 Thread Christian König
Am 07.07.22 um 18:45 schrieb Philip Yang: MMU notifier callback unmap the svm range update page table may free the PTB BO, then amdgpu_fill_buffer zero BO memory could cause deadlock as kmalloc may trigger MMU notifier. Uff that means the whole free BO code path can't allocate anything. I don'

Re: [PATCH] drm/amd/display: Enable ODM combine default policy

2022-07-07 Thread Alex Deucher
Acked-by: Alex Deucher On Thu, Jul 7, 2022 at 2:43 PM Aurabindo Pillai wrote: > > [Why&How] > Output Data Mapping is a power saving feature that allows us to run at > reduced DPP and DISP clocks compared to what could be achieved with a > single pipe. > > Set the default policy for single displa

[PATCH] drm/amd/display: Enable ODM combine default policy

2022-07-07 Thread Aurabindo Pillai
[Why&How] Output Data Mapping is a power saving feature that allows us to run at reduced DPP and DISP clocks compared to what could be achieved with a single pipe. Set the default policy for single display use case to use 2 to 1 ODM combine. The options are queried by DC and appropriate register p

Re: [PATCH] drm/amdgpu: Fix a NULL pointer of fence

2022-07-07 Thread Mike Lothian
Hi This appears to fix https://gitlab.freedesktop.org/drm/amd/-/issues/2074 Feel free to add my tested by Thanks Mike On Thu, 7 Jul 2022 at 10:51, xinhui pan wrote: > > Fence is accessed by dma_resv_add_fence() now. > Use amdgpu_amdkfd_remove_eviction_fence instead. > > Signed-off-by: xinhui

Re: [PATCH] drm/amd/display: Fix unsigned expression compared with zero

2022-07-07 Thread Alex Deucher
On Wed, Jul 6, 2022 at 3:41 AM Zhongjun Tan wrote: > > From: Zhongjun Tan > > Fix unsigned expression compared with zero > > Signed-off-by: Zhongjun Tan > --- > .../gpu/drm/amd/display/dc/dml/dcn20/display_rq_dlg_calc_20.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --g

Re: [PATCH] drm/amd/display: Remove redundant header file references.

2022-07-07 Thread Alex Deucher
Thanks for the patch, but someone else beat you to it. Alex On Thu, Jul 7, 2022 at 9:05 AM sunliming wrote: > > Fixes the following includecheck warning: > > drivers/gpu/drm/amd/display/dc/os_types.h: drm/drm_print.h is included more > than once. > > Reported-by: kernel test robot > Signed-off

Re: [PATCH -next] drm/amd/display: clean up some inconsistent indenting

2022-07-07 Thread Alex Deucher
Applied. Thanks! Alex On Wed, Jul 6, 2022 at 9:38 PM Yang Li wrote: > > Eliminate the follow smatch warnings: > drivers/gpu/drm/amd/amdgpu/../display/dc/bios/bios_parser2.c:405 > get_bios_object_from_path_v3() warn: inconsistent indenting > drivers/gpu/drm/amd/amdgpu/../display/dc/bios/bios_pa

Re: [PATCH] drm/amd/display: Add callback to set dig mode

2022-07-07 Thread Alex Deucher
Acked-by: Alex Deucher On Thu, Jul 7, 2022 at 2:03 PM Aurabindo Pillai wrote: > > [Why&How] > Add a missing callback to set DIG FIFO output pixel mode. This is used > when ODM combine is activated. > > Fixes: e40fcd4afb3f ("drm/amd/display: add DCN32/321 specific files for > Display Core") > Si

Re: [PATCH 1/1] drm/amdgpu: Don't clear memory when PTB BO is released

2022-07-07 Thread Felix Kuehling
On 2022-07-07 12:45, Philip Yang wrote: MMU notifier callback unmap the svm range update page table may free the PTB BO, then amdgpu_fill_buffer zero BO memory could cause deadlock as kmalloc may trigger MMU notifier. amdgpu_vm_pt_clear setup PTB BO memory with initial value, and no sensitive da

[PATCH] drm/amd/display: Add callback to set dig mode

2022-07-07 Thread Aurabindo Pillai
[Why&How] Add a missing callback to set DIG FIFO output pixel mode. This is used when ODM combine is activated. Fixes: e40fcd4afb3f ("drm/amd/display: add DCN32/321 specific files for Display Core") Signed-off-by: Aurabindo Pillai --- .../amd/display/dc/dcn32/dcn32_dio_stream_encoder.c | 12 ++

Re: [Intel-gfx] [PATCH 1/6] drm/ttm: rename and cleanup ttm_bo_init_reserved

2022-07-07 Thread kernel test robot
Hi "Christian, I love your patch! Perhaps something to improve: [auto build test WARNING on drm-tip/drm-tip] url: https://github.com/intel-lab-lkp/linux/commits/Christian-K-nig/drm-ttm-rename-and-cleanup-ttm_bo_init_reserved/20220707-192538 base: git://anongit.freedesktop.org/drm/dr

[PATCH 1/1] drm/amdgpu: Don't clear memory when PTB BO is released

2022-07-07 Thread Philip Yang
MMU notifier callback unmap the svm range update page table may free the PTB BO, then amdgpu_fill_buffer zero BO memory could cause deadlock as kmalloc may trigger MMU notifier. amdgpu_vm_pt_clear setup PTB BO memory with initial value, and no sensitive data in page table that must be wiped out be

Re: [PATCH] drm/amdgpu: Fix one list corruption when create queue fails

2022-07-07 Thread Felix Kuehling
Am 2022-07-07 um 09:39 schrieb philip yang: On 2022-07-07 06:28, xinhui pan wrote: Queue would be freed when create_queue_cpsch fails So lets do queue cleanup otherwise various list and memory issues happen. This bug was introduced when adding MES support, as we used to ignore execute_queue

Re: [PATCH] drm/amdgpu: Fix a NULL pointer of fence

2022-07-07 Thread Felix Kuehling
Am 2022-07-07 um 05:54 schrieb Christian König: Am 07.07.22 um 11:50 schrieb xinhui pan: Fence is accessed by dma_resv_add_fence() now. Use amdgpu_amdkfd_remove_eviction_fence instead. Signed-off-by: xinhui pan ---   drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c | 4 ++--   1 file changed, 2

Re: [PATCH 1/2] drm/amd/display: Add visualconfirm module parameter

2022-07-07 Thread Rodrigo Siqueira Jordao
On 07/07/2022 10:56, sunpeng...@amd.com wrote: From: Leo Li [Why] Being able to configure visual confirm at boot or in cmdline is helpful when debugging. [How] Add a module parameter to configure DC visual confirm, which works the same way as the equivalent debugfs entry. Signed-off-by:

[PATCH 2/2] drm/amd/display: Add dcdebugmask option for disabling MPO

2022-07-07 Thread sunpeng.li
From: Leo Li [Why & How] It's useful to disable MPO when debugging or testing. Therefore, add a dcdebugmask option to disable MPO. Signed-off-by: Leo Li --- drivers/gpu/drm/amd/display/amdgpu_dm/amdgpu_dm.c | 4 drivers/gpu/drm/amd/include/amd_shared.h | 1 + 2 files changed, 5

[PATCH 1/2] drm/amd/display: Add visualconfirm module parameter

2022-07-07 Thread sunpeng.li
From: Leo Li [Why] Being able to configure visual confirm at boot or in cmdline is helpful when debugging. [How] Add a module parameter to configure DC visual confirm, which works the same way as the equivalent debugfs entry. Signed-off-by: Leo Li --- drivers/gpu/drm/amd/amdgpu/amdgpu.h

Re: [PATCH] drm/amd/pm: ac/dc change for smu_v13_0

2022-07-07 Thread Deucher, Alexander
[Public] Acked-by: Alex Deucher From: amd-gfx on behalf of Kenneth Feng Sent: Thursday, July 7, 2022 10:27 AM To: amd-gfx@lists.freedesktop.org Cc: Feng, Kenneth Subject: [PATCH] drm/amd/pm: ac/dc change for smu_v13_0 fixed the issue: gpu runs in dc mode but

[PATCH] drm/amd/pm: ac/dc change for smu_v13_0

2022-07-07 Thread Kenneth Feng
fixed the issue: gpu runs in dc mode but it is expected to be in ac mode. this causes the lower performance on smu_v13_0 Signed-off-by: Kenneth Feng --- .../pm/swsmu/inc/pmfw_if/smu_v13_0_7_ppsmc.h | 9 -- drivers/gpu/drm/amd/pm/swsmu/inc/smu_types.h | 1 + .../gpu/drm/amd/pm/swsmu/smu13

Re: [PATCH] drm/amd/display: fix non-x86/PPC64 compilation

2022-07-07 Thread Harry Wentland
On 2022-07-06 17:42, Alex Deucher wrote: > Need to protect FP DMCUB code with CONFIG_DRM_AMD_DC_DCN. > Fixes build failures like the following on arm64: > ERROR: modpost: "__floatunsidf" [drivers/gpu/drm/amd/amdgpu/amdgpu.ko] > undefined! > ERROR: modpost: "__divdf3" [drivers/gpu/drm/amd/amdgpu/am

Re: [linux-next:master] BUILD REGRESSION 088b9c375534d905a4d337c78db3b3bfbb52c4a0

2022-07-07 Thread Guenter Roeck
On Thu, Jul 07, 2022 at 10:08:33AM +0200, Greg KH wrote: [ ... ] > > > > Unverified Error/Warning (likely false positive, please contact us if > > interested): > > > > arch/x86/events/core.c:2114 init_hw_perf_events() warn: missing error code > > 'err' > > drivers/android/binder.c:1481:19-23:

Re: [PATCH] drm/amdgpu: Fix one list corruption when create queue fails

2022-07-07 Thread philip yang
On 2022-07-07 06:28, xinhui pan wrote: Queue would be freed when create_queue_cpsch fails So lets do queue cleanup otherwise various list and memory issues happen. This bug was introduced when adding MES support, as we used to ignore execute_queues_

Re: CONFIG_ANDROID (was: rcu_sched detected expedited stalls in amdgpu after suspend)

2022-07-07 Thread Paul E. McKenney
On Thu, Jul 07, 2022 at 09:30:39AM +0200, Christian König wrote: > Am 06.07.22 um 22:42 schrieb Paul E. McKenney: > > On Wed, Jul 06, 2022 at 08:09:49PM +0200, Uladzislau Rezki wrote: > > > On Wed, Jul 06, 2022 at 10:58:36AM -0700, Paul E. McKenney wrote: > > > > On Wed, Jul 06, 2022 at 07:48:20PM

[PATCH] drm/amd/display: Remove redundant header file references.

2022-07-07 Thread sunliming
Fixes the following includecheck warning: drivers/gpu/drm/amd/display/dc/os_types.h: drm/drm_print.h is included more than once. Reported-by: kernel test robot Signed-off-by: sunliming --- drivers/gpu/drm/amd/display/dc/os_types.h | 2 -- 1 file changed, 2 deletions(-) diff --git a/drivers/g

Re: [PATCH] drm/amd/display: Fix new dmub notification enabling in DM

2022-07-07 Thread Harry Wentland
On 2022-07-07 04:23, Stylon Wang wrote: > [Why] > Changes from "Fix for dmub outbox notification enable" need to land > in DM or DMUB outbox notification would be disabled. > > [How] > Enable outbox notification only after interrupt are enabled and IRQ > handlers registered. Any pending notificati

Re: [PATCH 1/6] drm/ttm: rename and cleanup ttm_bo_init_reserved

2022-07-07 Thread Christian König
Am 07.07.22 um 12:24 schrieb Christian König: Rename ttm_bo_init_reserved to ttm_bo_init_validate since that better Ah, crap. Here is a typo, that should read "Rename ttm_bo_init to ttm_bo_init_validate" Please ignore during review, Christian. matches what the function is actually doin

[PATCH] drm/amdgpu: Fix one list corruption when create queue fails

2022-07-07 Thread xinhui pan
Queue would be freed when create_queue_cpsch fails So lets do queue cleanup otherwise various list and memory issues happen. Signed-off-by: xinhui pan --- drivers/gpu/drm/amd/amdkfd/kfd_device_queue_manager.c | 11 +-- 1 file changed, 5 insertions(+), 6 deletions(-) diff --git a/drivers

[PATCH 4/6] drm/ttm: audit bo->resource usage v2

2022-07-07 Thread Christian König
Allow BOs to exist without backing store. v2: handle ttm_bo_move_memcpy as well. Signed-off-by: Christian König --- drivers/gpu/drm/ttm/ttm_bo.c | 16 drivers/gpu/drm/ttm/ttm_bo_util.c | 7 +-- 2 files changed, 13 insertions(+), 10 deletions(-) diff --git a/drivers/g

[PATCH 1/6] drm/ttm: rename and cleanup ttm_bo_init_reserved

2022-07-07 Thread Christian König
Rename ttm_bo_init_reserved to ttm_bo_init_validate since that better matches what the function is actually doing. Remove the unused size parameter, move the function's kerneldoc to the implementation and cleanup the whole error handling. Signed-off-by: Christian König --- drivers/gpu/drm/amd/a

[PATCH 3/6] drm/nouveau: audit bo->resource usage

2022-07-07 Thread Christian König
Make sure we can at least move and release BOs without backing store. Signed-off-by: Christian König --- drivers/gpu/drm/nouveau/nouveau_bo.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/nouveau/nouveau_bo.c b/drivers/gpu/drm/nouveau/nouveau_bo.c index 9

[PATCH 5/6] drm/ttm: stop allocating dummy resources during BO creation

2022-07-07 Thread Christian König
That should not be necessary any more when drivers should at least be able to handle the move without a resource. Signed-off-by: Christian König --- drivers/gpu/drm/ttm/ttm_bo.c | 7 --- 1 file changed, 7 deletions(-) diff --git a/drivers/gpu/drm/ttm/ttm_bo.c b/drivers/gpu/drm/ttm/ttm_bo.c

[PATCH 2/6] drm/amdgpu: audit bo->resource usage

2022-07-07 Thread Christian König
Make sure we can at least move and release BOs without backing store. Signed-off-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_object.c | 2 +- drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c| 3 ++- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgp

[PATCH 6/6] drm/ttm: stop allocating a dummy resource for pipelined gutting

2022-07-07 Thread Christian König
That should not be necessary any more when drivers should at least be able to handle a move without a resource. Signed-off-by: Christian König --- drivers/gpu/drm/ttm/ttm_bo_util.c | 15 ++- 1 file changed, 2 insertions(+), 13 deletions(-) diff --git a/drivers/gpu/drm/ttm/ttm_bo_uti

Cleanup of TTM NULL resources

2022-07-07 Thread Christian König
Hi guys, sending this out once more since it was requested that the Intel CI systems can take a run of this as well. The last version had a couple of merge/rebase leftovers which are now fixed as well. Please review and/or comment, Christian.

Re: [Bug][5.19-rc0] Between commits fdaf9a5840ac and babf0bb978e3 GPU stopped entering in graphic mode.

2022-07-07 Thread Thomas Zimmermann
Hi Am 07.07.22 um 02:20 schrieb Mikhail Gavrilov: On Tue, Jun 28, 2022 at 2:21 PM Mikhail Gavrilov wrote: Christian can you look why drm_aperture_remove_conflicting_pci_framebuffers cause this kernel bug on my machine? Thanks for reporting. This bug has been fixed in https://cgit.freede

Re: [PATCH] drm/amdgpu: Fix a NULL pointer of fence

2022-07-07 Thread Christian König
Am 07.07.22 um 11:50 schrieb xinhui pan: Fence is accessed by dma_resv_add_fence() now. Use amdgpu_amdkfd_remove_eviction_fence instead. Signed-off-by: xinhui pan --- drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/driv

[PATCH] drm/amdgpu: Fix a NULL pointer of fence

2022-07-07 Thread xinhui pan
Fence is accessed by dma_resv_add_fence() now. Use amdgpu_amdkfd_remove_eviction_fence instead. Signed-off-by: xinhui pan --- drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c

Re: [Bug][5.19-rc0] Between commits fdaf9a5840ac and babf0bb978e3 GPU stopped entering in graphic mode.

2022-07-07 Thread Christian König
Am 07.07.22 um 02:20 schrieb Mikhail Gavrilov: On Tue, Jun 28, 2022 at 2:21 PM Mikhail Gavrilov wrote: Christian can you look why drm_aperture_remove_conflicting_pci_framebuffers cause this kernel bug on my machine? That looks like a problem outside of the amdgpu driver. What happens is that

Re: [linux-next:master] BUILD REGRESSION 088b9c375534d905a4d337c78db3b3bfbb52c4a0

2022-07-07 Thread Chen, Rong A
On 7/7/2022 4:08 PM, Greg KH wrote: On Thu, Jul 07, 2022 at 02:56:34PM +0800, kernel test robot wrote: tree/branch: https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master branch HEAD: 088b9c375534d905a4d337c78db3b3bfbb52c4a0 Add linux-next specific files for 20220706 E

[PATCH] drm/amd/display: Fix new dmub notification enabling in DM

2022-07-07 Thread Stylon Wang
[Why] Changes from "Fix for dmub outbox notification enable" need to land in DM or DMUB outbox notification would be disabled. [How] Enable outbox notification only after interrupt are enabled and IRQ handlers registered. Any pending notification will be sent by DMUB once outbox notification is en

Re: [linux-next:master] BUILD REGRESSION 088b9c375534d905a4d337c78db3b3bfbb52c4a0

2022-07-07 Thread Greg KH
On Thu, Jul 07, 2022 at 02:56:34PM +0800, kernel test robot wrote: > tree/branch: > https://git.kernel.org/pub/scm/linux/kernel/git/next/linux-next.git master > branch HEAD: 088b9c375534d905a4d337c78db3b3bfbb52c4a0 Add linux-next > specific files for 20220706 > > Error/Warning reports: > > htt

Re: [PATCH] dma-buf: Fix one use-after-free of fence

2022-07-07 Thread Christian König
Am 07.07.22 um 10:02 schrieb xinhui pan: Need get the new fence when we replace the old one. Fixes: 047a1b877ed48 ("dma-buf & drm/amdgpu: remove dma_resv workaround") Signed-off-by: xinhui pan Good catch, Reviewed-by: Christian König Going to push that in a minute. Christian. --- drive

[PATCH] dma-buf: Fix one use-after-free of fence

2022-07-07 Thread xinhui pan
Need get the new fence when we replace the old one. Fixes: 047a1b877ed48 ("dma-buf & drm/amdgpu: remove dma_resv workaround") Signed-off-by: xinhui pan --- drivers/dma-buf/dma-resv.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/dma-buf/dma-resv.c b/drivers/dma-buf/

Re: CONFIG_ANDROID (was: rcu_sched detected expedited stalls in amdgpu after suspend)

2022-07-07 Thread Christian König
Am 06.07.22 um 22:42 schrieb Paul E. McKenney: On Wed, Jul 06, 2022 at 08:09:49PM +0200, Uladzislau Rezki wrote: On Wed, Jul 06, 2022 at 10:58:36AM -0700, Paul E. McKenney wrote: On Wed, Jul 06, 2022 at 07:48:20PM +0200, Uladzislau Rezki wrote: Hello. On Mon, Jul 04, 2022 at 01:30:50PM +0200,