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

2023-07-23 Thread Guchun Chen
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 b/drivers/gpu/drm/ttm/ttm_bo.c index 7139a522b2f3..54e3083076b7 100644 --- a/drivers/gpu/drm/ttm/ttm_bo.c +++ b/drivers/gpu/drm/ttm/ttm_bo.c

[PATCH v3] drm/probe_helper: warning on poll_enabled for issue catching

2023-03-13 Thread Guchun Chen
sted-by: Dmitry Baryshkov Signed-off-by: Guchun Chen --- drivers/gpu/drm/drm_probe_helper.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/drm_probe_helper.c b/drivers/gpu/drm/drm_probe_helper.c index 8127be134c39..d812a4e91760 100644 --- a/drivers/gpu/drm/drm_probe_helper.c +

[PATCH v3 2/2] drm/probe_helper: warning on poll_enabled for issue catching

2023-03-09 Thread Guchun Chen
In order to catch issues in other drivers to ensure proper call sequence of polling function. v2: drop Fixes tag in commit message Bug: https://gitlab.freedesktop.org/drm/amd/-/issues/2411 Reported-by: Bert Karwatzki Suggested-by: Dmitry Baryshkov Signed-off-by: Guchun Chen --- drivers/gpu

[PATCH v3 1/2] drm/amdgpu: move poll enabled/disable into non DC path

2023-03-09 Thread Guchun Chen
xes: a4e771729a51("drm/probe_helper: sort out poll_running vs poll_enabled") Reported-by: Bert Karwatzki Suggested-by: Dmitry Baryshkov Suggested-by: Alex Deucher Signed-off-by: Guchun Chen Reviewed-by: Alex Deucher --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 4 drivers/gpu/d

[PATCH 2/2] drm/probe_helper: warning on poll_enabled for issue catching

2023-03-08 Thread Guchun Chen
Baryshkov Signed-off-by: Guchun Chen --- drivers/gpu/drm/drm_probe_helper.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/drm_probe_helper.c b/drivers/gpu/drm/drm_probe_helper.c index 8127be134c39..85e0e80d4a52 100644 --- a/drivers/gpu/drm/drm_probe_helper.c +++ b/drive

[PATCH 1/2] drm/amdgpu: move poll enabled/disable into non DC path

2023-03-08 Thread Guchun Chen
r Signed-off-by: Guchun Chen --- drivers/gpu/drm/amd/amdgpu/amdgpu_device.c | 4 drivers/gpu/drm/amd/amdgpu/amdgpu_display.c | 4 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_device.c index

[PATCH 2/2] drm/probe_helper: warning on poll_enabled for issue catching

2023-03-08 Thread Guchun Chen
Baryshkov Signed-off-by: Guchun Chen --- drivers/gpu/drm/drm_probe_helper.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/drm_probe_helper.c b/drivers/gpu/drm/drm_probe_helper.c index 8127be134c39..85e0e80d4a52 100644 --- a/drivers/gpu/drm/drm_probe_helper.c +++ b/drive

[PATCH 1/2] drm/amdgpu: add flag to enable/disable poll in suspend/resume path

2023-03-08 Thread Guchun Chen
ble/drm_kms_helper_poll_enable in suspend/resume path. Bug: https://gitlab.freedesktop.org/drm/amd/-/issues/2411 Fixes: a4e771729a51("drm/probe_helper: sort out poll_running vs poll_enabled") Reported-by: Bert Karwatzki Suggested-by: Dmitry Baryshkov Signed-off-by: Guchun Chen --- drivers/gpu/d

[PATCH] drm/ttm: add a WARN_ON in ttm_set_driver_manager when array bounds (v2)

2021-09-10 Thread Guchun Chen
-by: Guchun Chen --- include/drm/ttm/ttm_device.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/drm/ttm/ttm_device.h b/include/drm/ttm/ttm_device.h index 07d722950d5b..aa79953c807c 100644 --- a/include/drm/ttm/ttm_device.h +++ b/include/drm/ttm/ttm_device.h @@ -291,6 +291,7

[PATCH] drm/ttm: add a BUG_ON in ttm_set_driver_manager when array bounds

2021-09-09 Thread Guchun Chen
Vendor will define their own memory types on top of TTM_PL_PRIV, but call ttm_set_driver_manager directly without checking mem_type value when setting up memory manager. So add such check to aware the case when array bounds. Signed-off-by: Leslie Shi Signed-off-by: Guchun Chen --- include/drm