[PATCH] drm/amdgpu: Fix type mismatch in amdgpu_gfx_kiq_init_ring

2024-05-24 Thread Srinivasan Shanmugam
This commit fixes a type mismatch in the amdgpu_gfx_kiq_init_ring function triggered by the snprintf function expecting unsigned char arguments due to the '%hhu' format specifier, but receiving int and u32 arguments. The issue occurred because the arguments xcc_id, ring->me, ring->pipe, and ring->

Re: [RFC PATCH] drm/amdgpu: Refactor sysfs attr functions in AMDGPU for reusability

2024-05-24 Thread Christian König
Am 23.05.24 um 11:18 schrieb Srinivasan Shanmugam: This commit refactors the sysfs attribute management functions (`amdgpu_device_attr_create`, `amdgpu_device_attr_remove`, `amdgpu_device_attr_create_groups`, `amdgpu_device_attr_remove_groups`) into `amdgpu_sysfs.c`, which were originally in `amd

RE: [PATCH 4/4] drm/amdgpu: prevent gpu access during reset recovery

2024-05-24 Thread Li, Yunxiang (Teddy)
[AMD Official Use Only - AMD Internal Distribution Only] Yes, the two places are 1. In debugfs and 2. In MI100's en/disable_debug_trap, and evidently someone is testing the debugfs interface because there's a bug fix for a race condition of it. Teddy

Re: [PATCH 4/4] drm/amdgpu: prevent gpu access during reset recovery

2024-05-24 Thread Christian König
Am 24.05.24 um 15:35 schrieb Li, Yunxiang (Teddy): [AMD Official Use Only - AMD Internal Distribution Only] If that is true you could in theory lower the locked area of the existing lock, but adding a new one is strict no-go from my side. I'll try this, right now I see two places where this w

[PATCH] drm/amdkfd: simplify APU VRAM handling

2024-05-24 Thread Alex Deucher
With commit 89773b85599a ("drm/amdkfd: Let VRAM allocations go to GTT domain on small APUs") big and small APU "VRAM" handling in KFD was unified. Since AMD_IS_APU is set for both big and small APUs, we can simplify the checks in the code. v2: clean up a few more places (Lang) Signed-off-by: Ale

RE: [PATCH] drm/amdgpu: drop MES 10.1 support v3

2024-05-24 Thread Kasiviswanathan, Harish
Ah yes. Missed it. Reviewed-by: Harish Kasiviswanathan -Original Message- From: Alex Deucher Sent: Friday, May 24, 2024 9:22 AM To: Kasiviswanathan, Harish Cc: Deucher, Alexander ; amd-gfx@lists.freedesktop.org Subject: Re: [PATCH] drm/amdgpu: drop MES 10.1 support v3 On Thu, May 23,

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

2024-05-24 Thread Alex Deucher
Applied. Thanks! On Thu, May 23, 2024 at 10:37 PM Jiapeng Chong wrote: > > No functional modification involved. > > drivers/gpu/drm/amd/amdgpu/../display/dc/core/dc.c:5200 > dc_power_down_on_boot() warn: inconsistent indenting. > > Reported-by: Abaci Robot > Closes: https://bugzilla.openanolis

RE: [PATCH 4/4] drm/amdgpu: prevent gpu access during reset recovery

2024-05-24 Thread Li, Yunxiang (Teddy)
[AMD Official Use Only - AMD Internal Distribution Only] > If that is true you could in theory lower the locked area of the existing > lock, but adding a new one is strict no-go from my side. I'll try this, right now I see two places where this would be problematic because they are trying to su

Re: [PATCH] drm/amdgpu: drop MES 10.1 support v3

2024-05-24 Thread Alex Deucher
On Thu, May 23, 2024 at 7:22 PM Kasiviswanathan, Harish wrote: > > [AMD Official Use Only - AMD Internal Distribution Only] > > I had one more comment. With that fixed this patch is Reviewed-by: Harish > Kasiviswanathan > > static gfx_v10_0_ring_invalidate_tlbs() function can be removed since it

Re: [PATCH v4 13/15] drm/amd/display: Use ARCH_HAS_KERNEL_FPU_SUPPORT

2024-05-24 Thread Alex Deucher
On Fri, May 24, 2024 at 9:17 AM Alex Deucher wrote: > > On Fri, May 24, 2024 at 5:16 AM Guenter Roeck wrote: > > > > Hi, > > > > On Fri, Mar 29, 2024 at 12:18:28AM -0700, Samuel Holland wrote: > > > Now that all previously-supported architectures select > > > ARCH_HAS_KERNEL_FPU_SUPPORT, this cod

Re: [PATCH v4 13/15] drm/amd/display: Use ARCH_HAS_KERNEL_FPU_SUPPORT

2024-05-24 Thread Alex Deucher
On Fri, May 24, 2024 at 5:16 AM Guenter Roeck wrote: > > Hi, > > On Fri, Mar 29, 2024 at 12:18:28AM -0700, Samuel Holland wrote: > > Now that all previously-supported architectures select > > ARCH_HAS_KERNEL_FPU_SUPPORT, this code can depend on that symbol instead > > of the existing list of archi

[bug report] drm/amd/display: Find max flickerless instant vtotal delta

2024-05-24 Thread Dan Carpenter
Hello Ethan Bitnun, Commit bd051aa2fcfb ("drm/amd/display: Find max flickerless instant vtotal delta") from Apr 1, 2024 (linux-next), leads to the following Smatch static checker warning: drivers/gpu/drm/amd/amdgpu/../display/dc/core/dc_stream.c:1006 dc_stream_get_max_flickerless_instant_vtotal_

Re: [PATCH 3/4] drm/imx: fix -Wformat-truncation warning in imx_ldb_probe()

2024-05-24 Thread Jani Nikula
On Thu, 23 May 2024, Ville Syrjälä wrote: > On Thu, May 23, 2024 at 06:51:08PM +0300, Jani Nikula wrote: >> Enabling -Wformat-truncation yields the following warning: >> >> ../drivers/gpu/drm/imx/ipuv3/imx-ldb.c: In function ‘imx_ldb_probe’: >> ../drivers/gpu/drm/imx/ipuv3/imx-ldb.c:658:57: error

Re: [PATCH 4/4] drm: enable -Wformat-truncation across the subsystem

2024-05-24 Thread Jani Nikula
On Thu, 23 May 2024, Sam Ravnborg wrote: > Hi Jani, > > On Thu, May 23, 2024 at 06:51:09PM +0300, Jani Nikula wrote: >> With the -Wformat-truncation warnings fixed, finish the job started in >> commit a61ddb4393ad ("drm: enable (most) W=1 warnings by default across >> the subsystem"), and enable t

Re: [PATCH v4 13/15] drm/amd/display: Use ARCH_HAS_KERNEL_FPU_SUPPORT

2024-05-24 Thread Guenter Roeck
Hi, On Fri, Mar 29, 2024 at 12:18:28AM -0700, Samuel Holland wrote: > Now that all previously-supported architectures select > ARCH_HAS_KERNEL_FPU_SUPPORT, this code can depend on that symbol instead > of the existing list of architectures. It can also take advantage of the > common kernel-mode FP

Re: [PATCH 1/4] drm/amdgpu: fix -Wformat-truncation warning in amdgpu_gfx_kiq_init_ring()

2024-05-24 Thread Jani Nikula
On Thu, 23 May 2024, Alex Deucher wrote: > Already fixed with this patch: > https://patchwork.freedesktop.org/patch/594864/ Great, thanks! BR, Jani. -- Jani Nikula, Intel

[PATCH] Revert "drm/amdgpu: init iommu after amdkfd device init"

2024-05-24 Thread Armin Wolf
This reverts commit 56b522f4668167096a50c39446d6263c96219f5f. A user reported that this commit breaks the integrated gpu of his notebook, causing a black screen. He was able to bisect the problematic commit and verified that by reverting it the notebook works again. He also confirmed that kernel 6

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

2024-05-24 Thread Jiapeng Chong
No functional modification involved. drivers/gpu/drm/amd/amdgpu/../display/dc/core/dc.c:5200 dc_power_down_on_boot() warn: inconsistent indenting. Reported-by: Abaci Robot Closes: https://bugzilla.openanolis.cn/show_bug.cgi?id=9166 Signed-off-by: Jiapeng Chong --- drivers/gpu/drm/amd/display/

Re: Kernel 5.15.150 black screen with AMD Raven/Picasso GPU

2024-05-24 Thread Greg KH
On Thu, May 23, 2024 at 05:59:39PM +0200, Armin Wolf wrote: > Am 23.05.24 um 15:13 schrieb Barry Kauler: > > > On Wed, May 22, 2024 at 12:58 AM Armin Wolf wrote: > > > Am 20.05.24 um 18:22 schrieb Alex Deucher: > > > > > > > On Sat, May 18, 2024 at 8:17 PM Armin Wolf wrote: > > > > > Am 17.05.2

Re: [PATCH] drm/amdgpu: silence UBSAN warning

2024-05-24 Thread Christian König
Am 16.05.24 um 15:55 schrieb Alex Deucher: Convert a variable sized array from [1] to []. Signed-off-by: Alex Deucher Reviewed-by: Christian König --- drivers/gpu/drm/amd/include/atomfirmware.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/amd/inclu

Re: [PATCH] drm/amdgpu: Adjust logic in amdgpu_device_partner_bandwidth()

2024-05-24 Thread Christian König
Am 16.05.24 um 17:05 schrieb Alex Deucher: Use current speed/width on devices which don't support dynamic PCIe switching. Closes: https://gitlab.freedesktop.org/drm/amd/-/issues/3289 Signed-off-by: Alex Deucher Acked-by: Christian König --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 19

Re: [PATCH 4/4] drm/amdgpu: prevent gpu access during reset recovery

2024-05-24 Thread Christian König
Am 23.05.24 um 17:35 schrieb Li, Yunxiang (Teddy): [Public] Here is taking a different lock than the reset_domain->sem. It is a seperate reset_domain->gpu_sem that is only locked when we will actuall do reset, it is not taken in the skip_hw_reset path. Exactly that is what you should *not* d