[PATCH] drm/amd/display: remove an unused file

2023-07-17 Thread Aurabindo Pillai
[Why] Internal subvp state is not referenced in driver code, so it can be removed. Signed-off-by: Aurabindo Pillai --- .../drm/amd/display/dc/dcn32/dcn32_hwseq.c| 2 - .../amd/display/dmub/inc/dmub_subvp_state.h | 183 -- 2 files changed, 185 deletions(-) delete mode

RE: [PATCH 4/4] drm/amdgpu: use a macro to define no xcp partition case

2023-07-17 Thread Chen, Guchun
[Public] Thank you for review, Felix. Hi Christian, I forgot to add your RB in patch 2/patch3 when posting this series for review. I will add it back when pushing. Hope it's fine to you. Regards, Guchun > -Original Message- > From: Kuehling, Felix > Sent: Monday, July 17, 2023 10:58

Re: [PATCH] drm/amd/display: remove an unused file

2023-07-17 Thread Rodrigo Siqueira
On 7/17/23 17:01, Aurabindo Pillai wrote: [Why] Internal subvp state is not referenced in driver code, so it can be removed. Signed-off-by: Aurabindo Pillai --- .../drm/amd/display/dc/dcn32/dcn32_hwseq.c| 2 - .../amd/display/dmub/inc/dmub_subvp_state.h | 183 --

RE: [bug/bisected] commit a2848d08742c8e8494675892c02c0d22acbe3cf8 cause general protection fault, probably for non-canonical address 0xdffffc0000000000: 0000 [#1] PREEMPT SMP KASAN NOPTI

2023-07-17 Thread Chen, Guchun
[Public] Hello Mike, I guess this patch can resolve your problem. https://patchwork.freedesktop.org/patch/547897/ Regards, Guchun > -Original Message- > From: amd-gfx On Behalf Of > Mikhail Gavrilov > Sent: Tuesday, July 18, 2023 3:34 AM > To: Koenig, Christian ; Pelloux-Prayer,

[PATCH] drm/ttm: check null pointer before accessing when swapping

2023-07-17 Thread Guchun Chen
Add a check to avoid null pointer dereference. Fixes: a2848d08742c ("drm/ttm: never consider pinned BOs for eviction") Signed-off-by: Guchun Chen --- drivers/gpu/drm/ttm/ttm_bo.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/ttm/ttm_bo.c

[PATCH] drm/amdgpu: Enabling FW workaround through shared memory for VCN4_0_2

2023-07-17 Thread sguttula
This patch will enable VCN FW workaround using DRM KEY INJECT WORKAROUND method, which is helping in fixing the secure playback. Signed-off-by: sguttula --- Changes in v2: -updated commit message as per veera's feedback Changes in v3: -updated commit message as enabling for 402 -updated the

RE: [PATCH 3/7] drm/amdgpu/vcn: sriov support for vcn_v4_0_3

2023-07-17 Thread Chen, Guchun
[Public] > -Original Message- > From: amd-gfx On Behalf Of > Samir Dhume > Sent: Monday, July 17, 2023 11:59 PM > To: amd-gfx@lists.freedesktop.org > Cc: Dhume, Samir > Subject: [PATCH 3/7] drm/amdgpu/vcn: sriov support for vcn_v4_0_3 > > initialization table handshake with mmsch > >

RE: [PATCH v2] drm/amd/pm: Vangogh: Add new gpu_metrics_v2_4 to acquire gpu_metrics

2023-07-17 Thread Quan, Evan
[AMD Official Use Only - General] Hi Wenyou, I think you already got the greenlight(RB from Mario and ACK from me) to land the change. Go ahead please. Evan > -Original Message- > From: Yang, WenYou > Sent: Thursday, July 13, 2023 8:56 AM > To: Yang, WenYou ; Deucher, Alexander > ;

[PATCH 2/4] drm/amdgpu: fix slab-out-of-bounds issue in amdgpu_vm_pt_create

2023-07-17 Thread Guchun Chen
Recent code set xcp_id stored from file private data when opening device to amdgpu bo for accounting memory usage etc, but not all VMs are attached to this fpriv structure like the vm cases in amdgpu_mes_self_test, otherwise, KASAN will complain below out of bound access. And more importantly, VM

[PATCH 3/4] drm/amdgpu/vm: use the same xcp_id from root PD

2023-07-17 Thread Guchun Chen
Other PDs/PTs allocation should just use the same xcp_id as that stored in root PD. Suggested-by: Christian König Signed-off-by: Guchun Chen Reviewed-by: Felix Kuehling Reviewed-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_vm_pt.c | 3 ++- 1 file changed, 2 insertions(+), 1

[PATCH 4/4] drm/amdgpu: use a macro to define no xcp partition case

2023-07-17 Thread Guchun Chen
~0 as no xcp partition is used in several places, so improve its definition by a macro for code consistency. Suggested-by: Christian König Signed-off-by: Guchun Chen Reviewed-by: Felix Kuehling --- drivers/gpu/drm/amd/amdgpu/amdgpu_amdkfd_gpuvm.c | 3 ++-

[PATCH 1/4] drm/amdgpu: Allocate root PD on correct partition

2023-07-17 Thread Guchun Chen
file_priv needs to be setup firstly, otherwise, root PD will always be allocated on partition 0, even if opening the device from other partitions. Fixes: ffc6deb773f7 ("drm/amdkfd: Store xcp partition id to amdgpu bo") Signed-off-by: Guchun Chen Reviewed-by: Felix Kuehling ---

[PATCH] drm/amdgpu: allow secure submission on VCN4 ring

2023-07-17 Thread sguttula
This patch will enable secure decode playback on VCN4_0_2 Signed-off-by: sguttula --- Changes in v2: -updated commit message only enabling for VCN402 -updated the logic as per Leo's feedback --- drivers/gpu/drm/amd/amdgpu/vcn_v4_0.c | 8 ++-- 1 file changed, 6 insertions(+), 2 deletions(-)

Re: [PATCH 1/2] drm/amdgpu: allow secure submission on VCN4 ring

2023-07-17 Thread Leo Liu
Since the changes will affect multiple ASICs, if you only tested with VCN4_0_4, please just apply the set to that HW. Regards, Leo On 2023-07-16 23:15, Guttula, Suresh wrote: Hi Leo, There are two issues here. This change fixing the Crash while secure playback and we see below error:

[PATCH v2] drm/amdgpu: load sdma ucode in the guest machine

2023-07-17 Thread YuanShang
[why] User mode driver need to check the sdma ucode version to see whether the sdma engine supports a new type of PM4 packet. In SRIOV, sdma is loaded by the host. And, there is no way to check the sdma ucode version of CHIP_NAVI12 and CHIP_SIENNA_CICHLID of the host in the guest machine. [how]

[PATCH] drm/connector: mark enum counter value as private

2023-07-17 Thread Randy Dunlap
Mark the DRM_MODE_COLORIMETRY_COUNT enum value as private in kernel-doc to prevent a build warning: include/drm/drm_connector.h:527: warning: Enum value 'DRM_MODE_COLORIMETRY_COUNT' not described in enum 'drm_colorspace' Fixes: c627087cb164 ("drm/connector: Use common colorspace_names array")

Re: [PATCH v4 12/18] staging: Remove flag FBINFO_FLAG_DEFAULT from fbdev drivers

2023-07-17 Thread Greg Kroah-Hartman
On Sat, Jul 15, 2023 at 08:51:54PM +0200, Thomas Zimmermann wrote: > The flag FBINFO_FLAG_DEFAULT is 0 and has no effect, as struct > fbinfo.flags has been allocated to zero by framebuffer_alloc(). So do > not set it. > > Flags should signal differences from the default values. After cleaning >

[PATCH v5 06/11] drm/radeon: Use RMW accessors for changing LNKCTL

2023-07-17 Thread Ilpo Järvinen
Don't assume that only the driver would be accessing LNKCTL. ASPM policy changes can trigger write to LNKCTL outside of driver's control. And in the case of upstream bridge, the driver does not even own the device it's changing the registers for. Use RMW capability accessors which do proper

[PATCH v5 05/11] drm/amdgpu: Use RMW accessors for changing LNKCTL

2023-07-17 Thread Ilpo Järvinen
Don't assume that only the driver would be accessing LNKCTL. ASPM policy changes can trigger write to LNKCTL outside of driver's control. And in the case of upstream bridge, the driver does not even own the device it's changing the registers for. Use RMW capability accessors which do proper

Re: [PATCH 1/5] mm: introduce vma_is_stack() and vma_is_heap()

2023-07-17 Thread David Hildenbrand
On 12.07.23 16:38, Kefeng Wang wrote: Introduce the two helpers for general use. Signed-off-by: Kefeng Wang --- include/linux/mm.h | 12 1 file changed, 12 insertions(+) diff --git a/include/linux/mm.h b/include/linux/mm.h index 1462cf15badf..0bbeb31ac750 100644 ---

Re: [PATCH 2/5] mm: use vma_is_stack() and vma_is_heap()

2023-07-17 Thread David Hildenbrand
On 12.07.23 16:38, Kefeng Wang wrote: Use the helpers to simplify code. Signed-off-by: Kefeng Wang --- fs/proc/task_mmu.c | 24 fs/proc/task_nommu.c | 15 +-- 2 files changed, 5 insertions(+), 34 deletions(-) Please squash patch #1 and this patch

Re: [PATCH 28/29] drm/amdkfd: Refactor migrate init to support partition switch

2023-07-17 Thread Michel Dänzer
On 5/10/23 23:23, Alex Deucher wrote: > From: Philip Yang > > Rename smv_migrate_init to a better name kgd2kfd_init_zone_device > because it setup zone devive pgmap for page migration and keep it in > kfd_migrate.c to access static functions svm_migrate_pgmap_ops. Call it > only once in

[PATCH v2] drm: Spelling s/sempahore/semaphore/

2023-07-17 Thread Geert Uytterhoeven
Fix misspellings of "semaphore". Signed-off-by: Geert Uytterhoeven Reviewed-by: Hamza Mahfooz --- v2: - Add Reviewed-by. --- drivers/gpu/drm/i915/i915_request.c | 2 +- drivers/gpu/drm/radeon/cik.c| 2 +- drivers/gpu/drm/radeon/r600.c | 2 +- include/drm/task_barrier.h

Re: [PATCH v2] drm: Spelling s/sempahore/semaphore/

2023-07-17 Thread Rodrigo Vivi
On Mon, Jul 17, 2023 at 03:23:20PM +0200, Geert Uytterhoeven wrote: > Fix misspellings of "semaphore". > > Signed-off-by: Geert Uytterhoeven > Reviewed-by: Hamza Mahfooz > --- > v2: > - Add Reviewed-by. > --- > drivers/gpu/drm/i915/i915_request.c | 2 +- > drivers/gpu/drm/radeon/cik.c

Re: [PATCH v3 4/9] PCI/VGA: Improve the default VGA device selection

2023-07-17 Thread suijingfeng
Hi, Fixes: f6b1772b2555 ('vgaarb: remove the unused irq_set_state argument to vga_client_register') Because after applied that patch, there have only one callback mechanism we can use, not two anymore. On 2023/7/12 00:43, Sui Jingfeng wrote: From: Sui Jingfeng Currently, the strategy

Re: [PATCH 4/4] drm/amdgpu: use a macro to define no xcp partition case

2023-07-17 Thread Felix Kuehling
On 2023-07-16 22:26, Guchun Chen wrote: ~0 as no xcp partition is used in several places, so improve its definition by a macro for code consistency. Suggested-by: Christian König Signed-off-by: Guchun Chen The series is Reviewed-by: Felix Kuehling ---

Re: radeon.ko/i586: BUG: kernel NULL pointer dereference,address:00000004

2023-07-17 Thread Steven Rostedt
On Sat, 15 Jul 2023 11:39:11 +0900 wrote: > Yes, this is puzzling. That's why I need other people's opinion on this. > Does it matter the DUT is a slow machine (Pentium 120MHz)? > Hmm, I wonder because the workqueue is running __init functions, could it possibly be that it didn't finish

Re: radeon.ko/i586: BUG: kernel NULL pointer dereference, address:00000004

2023-07-17 Thread Steven Rostedt
On Fri, 14 Jul 2023 14:34:04 +0900 wrote: > Patch in > https://bugzilla.kernel.org/show_bug.cgi?id=217669#c4 > fixed the problem in freedesktop.org kernel 5.18.0-rc2 . > This may explain that in kernel.org tree, the said commit is in kernel-5.19. You mean the patch that adds: #if

[PATCH 3/7] drm/amdgpu/vcn: sriov support for vcn_v4_0_3

2023-07-17 Thread Samir Dhume
initialization table handshake with mmsch Signed-off-by: Samir Dhume --- drivers/gpu/drm/amd/amdgpu/vcn_v4_0_3.c | 264 +--- 1 file changed, 240 insertions(+), 24 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/vcn_v4_0_3.c b/drivers/gpu/drm/amd/amdgpu/vcn_v4_0_3.c

[PATCH 4/7] drm/amdgpu/vcn: mmsch_v3_0_4 requires doorbell on 32 byte boundary

2023-07-17 Thread Samir Dhume
Signed-off-by: Samir Dhume --- drivers/gpu/drm/amd/amdgpu/vcn_v4_0_3.c | 13 ++--- 1 file changed, 10 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/vcn_v4_0_3.c b/drivers/gpu/drm/amd/amdgpu/vcn_v4_0_3.c index ac405dfcfaf1..fa9abcb08c22 100644 ---

[PATCH 6/7] drm/amdgpu/jpeg: mmsch_v3_0_4 requires doorbell on 32 byte boundary

2023-07-17 Thread Samir Dhume
Signed-off-by: Samir Dhume --- drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_3.c | 17 ++--- 1 file changed, 14 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_3.c b/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_3.c index 85ee74fdb7e3..896e2f895884 100644 ---

[PATCH 5/7] drm/amdgpu/jpeg: sriov support for jpeg_v4_0_3

2023-07-17 Thread Samir Dhume
initialization table handshake with mmsch Signed-off-by: Samir Dhume --- drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_3.c | 171 --- 1 file changed, 150 insertions(+), 21 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_3.c b/drivers/gpu/drm/amd/amdgpu/jpeg_v4_0_3.c

[PATCH 2/7] drm/amdgpu/vcn : Skip vcn power-gating change for sriov

2023-07-17 Thread Samir Dhume
Signed-off-by: Samir Dhume --- drivers/gpu/drm/amd/amdgpu/vcn_v4_0_3.c | 9 + 1 file changed, 9 insertions(+) diff --git a/drivers/gpu/drm/amd/amdgpu/vcn_v4_0_3.c b/drivers/gpu/drm/amd/amdgpu/vcn_v4_0_3.c index 550ac040b4be..411c1d802823 100644 ---

[PATCH 1/7] drm/amdgpu/vcn: Add MMSCH v4_0_3 support for sriov

2023-07-17 Thread Samir Dhume
The structures are the same as v4_0 except for the init header Signed-off-by: Samir Dhume --- drivers/gpu/drm/amd/amdgpu/mmsch_v4_0_3.h | 37 +++ 1 file changed, 37 insertions(+) create mode 100644 drivers/gpu/drm/amd/amdgpu/mmsch_v4_0_3.h diff --git

[PATCH 7/7] drm/amdgpu/vcn: change end doorbell index for vcn_v4_0_3

2023-07-17 Thread Samir Dhume
For sriov, doorbell index for vcn0 for AID needs to be on 32 byte boundary so we need to move the vcn end doorbell Signed-off-by: Samir Dhume --- drivers/gpu/drm/amd/amdgpu/amdgpu_doorbell.h | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git

Re: [PATCH 4/5] selinux: use vma_is_stack() and vma_is_heap()

2023-07-17 Thread Paul Moore
On Wed, Jul 12, 2023 at 10:25 AM Kefeng Wang wrote: > > Use the helpers to simplify code. > > Signed-off-by: Kefeng Wang > --- > security/selinux/hooks.c | 7 ++- > 1 file changed, 2 insertions(+), 5 deletions(-) > > diff --git a/security/selinux/hooks.c b/security/selinux/hooks.c > index