[PATCH] drm/xe/hwmon: fix uninitialised access in xe_hwmon_pcode_write_power_limit

2025-06-03 Thread Qasim Ijaz
power limits though mailbox") Signed-off-by: Qasim Ijaz --- drivers/gpu/drm/xe/xe_hwmon.c | 6 -- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/drivers/gpu/drm/xe/xe_hwmon.c b/drivers/gpu/drm/xe/xe_hwmon.c index 0d32e977537c..04acb47488a0 100644 --- a/drivers/gpu/drm/xe/

[PATCH v2 RESEND] drm/msm/dpu: reorder pointer operations after sanity checks to avoid NULL deref

2025-04-08 Thread Qasim Ijaz
d start for CWB") Reviewed-by: Dmitry Baryshkov Signed-off-by: Qasim Ijaz --- v2: - Moved Signed-off tag below Fixes tag - Moved dpu_enc declaration to the top and initialisation below sanity checks drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 4 +++- 1 file changed, 3 insertions(+), 1 del

[PATCH v2 RESEND] drm/msm/dpu: reorder pointer operations after sanity checks to avoid NULL deref

2025-03-29 Thread Qasim Ijaz
d start for CWB") Reviewed-by: Dmitry Baryshkov Signed-off-by: Qasim Ijaz --- v2: - Moved Signed-off tag below Fixes tag - Moved dpu_enc declaration to the top and initialisation below sanity checks drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 4 +++- 1 file changed, 3 insertions(+), 1 del

[PATCH v2 RESEND] drm/msm/dpu: reorder pointer operations after sanity checks to avoid NULL deref

2025-03-17 Thread Qasim Ijaz
d start for CWB") Reviewed-by: Dmitry Baryshkov Signed-off-by: Qasim Ijaz --- v2: - Moved Signed-off tag below Fixes tag - Moved dpu_enc declaration to the top and initialisation below sanity checks drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 4 +++- 1 file changed, 3 insertions(+), 1 del

Re: [PATCH] drm/ttm/tests: fix potential null pointer dereference in ttm_bo_unreserve_bulk()

2025-03-13 Thread Qasim Ijaz
On Thu, Mar 13, 2025 at 03:20:34PM +0100, Christian König wrote: > Am 11.03.25 um 20:01 schrieb Qasim Ijaz: > > In the ttm_bo_unreserve_bulk() test function, resv is allocated > > using kunit_kzalloc(), but the subsequent assertion mistakenly > > verifies the ttm_dev pointe

[PATCH] drm/ttm/tests: fix incorrect assert in ttm_bo_unreserve_bulk()

2025-03-13 Thread Qasim Ijaz
In the ttm_bo_unreserve_bulk() test function, resv is allocated using kunit_kzalloc(), but the subsequent assertion mistakenly verifies the ttm_dev pointer instead of the resv pointer. Fix the assertion to properly verify the resv pointer. Signed-off-by: Qasim Ijaz --- drivers/gpu/drm/ttm

[PATCH] drm/ttm/tests: fix potential null pointer dereference in ttm_bo_unreserve_bulk()

2025-03-11 Thread Qasim Ijaz
NULL and a call to dma_resv_init(resv) will dereference a NULL pointer. Fix the assertion to properly verify the resv pointer. Fixes: 588c4c8d58c4 ("drm/ttm/tests: Fix a warning in ttm_bo_unreserve_bulk") Cc: sta...@vger.kernel.org Signed-off-by: Qasim Ijaz --- drivers/gpu/drm

[PATCH v2] drm/msm/dpu: reorder pointer operations after sanity checks to avoid NULL deref

2025-03-09 Thread Qasim Ijaz
d start for CWB") Signed-off-by: Qasim Ijaz --- v2: - Moved Signed-off tag below Fixes tag - Moved dpu_enc declaration to the top and initialisation below sanity checks drivers/gpu/drm/msm/disp/dpu1/dpu_encoder.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/driv

[PATCH] drm/msm/dpu: reorder pointer operations after sanity checks to avoid NULL deref

2025-03-08 Thread Qasim Ijaz
_dpu_encoder_trigger_start dereferences "struct dpu_encoder_phys *phys" before the sanity checks which can lead to a NULL pointer dereference if phys is NULL. Fix this by reordering the dereference after the sanity checks. Signed-off-by: Qasim Ijaz Fixes: 8144d17a81d9 ("dr

[PATCH] dma-buf: Use max3() instead of nested max()

2025-02-25 Thread Qasim Ijaz
Use the well-known max3() macro instead of nesting max() to find the maximum between in_size, out_size and drv_size. Signed-off-by: Qasim Ijaz --- drivers/dma-buf/dma-heap.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/dma-buf/dma-heap.c b/drivers/dma-buf/dma