Re: [PATCH v3 2/5] drm: Add drm_get_acpi_edid() helper

2024-02-02 Thread Pranjal Ramajor Asha Kanojiya
On 2/2/2024 3:41 AM, Mario Limonciello wrote: Some manufacturers have intentionally put an EDID that differs from the EDID on the internal panel on laptops. Drivers can call this helper to attempt to fetch the EDID from the BIOS's ACPI _DDC method. Signed-off-by: Mario Limonciello --- v1->v2

Re: [PATCH v3 5/5] drm: Drop unneeded selects in DRM drivers

2024-02-02 Thread Pranjal Ramajor Asha Kanojiya
On 2/2/2024 3:41 AM, Mario Limonciello wrote: All of the selects on ACPI_VIDEO are unnecessary when DRM does the select for ACPI_VIDEO as it provides a helper for acpi based EDID. Signed-off-by: Mario Limonciello Reviewed-by: Pranjal Ramajor Asha Kanojiya

Re: [PATCH][V2][next] accel/qaic: remove redundant pointer pexec

2023-08-01 Thread Pranjal Ramajor Asha Kanojiya
: Pranjal Ramajor Asha Kanojiya

Re: [PATCH][next] accel/qaic: remove redundant assignment to pointer pexec

2023-07-26 Thread Pranjal Ramajor Asha Kanojiya
On 7/26/2023 8:30 AM, Jeffrey Hugo wrote: On 7/25/2023 5:40 AM, Colin Ian King wrote: Pointer pexec is being assigned a value however it is never read. The assignment is redundant and can be removed. Signed-off-by: Colin Ian King ---   drivers/accel/qaic/qaic_data.c | 1 -   1 file changed,

Re: [PATCH 5/5 v4] accel/qaic: Fix a leak in map_user_pages()

2023-07-14 Thread Pranjal Ramajor Asha Kanojiya
Carpenter Reviewed-by: Pranjal Ramajor Asha Kanojiya

Re: [PATCH 4/5 v4] accel/qaic: move and expand integer overflow checks for map_user_pages()

2023-07-14 Thread Pranjal Ramajor Asha Kanojiya
On 7/11/2023 1:51 PM, Dan Carpenter wrote: The integer overflow checking for find_and_map_user_pages() was done in encode_dma(). Presumably this was to do it before the allocation. But it's not super important that the failure path is a fast path and it hurts readability to put the check so

Re: [PATCH 3/5 v4] accel/qaic: Add consistent integer overflow checks

2023-07-14 Thread Pranjal Ramajor Asha Kanojiya
;hdr.len > QAIC_MANAGE_MAX_MSG_LENGTH) + if (size_add(msg_hdr_len, in_trans->hdr.len) > QAIC_MANAGE_MAX_MSG_LENGTH) return -ENOSPC; trans_wrapper = add_wrapper(wrappers, sizeof(*trans_wrapper)); Reviewed-by: Pranjal Ramajor Asha Kanojiya

Re: [PATCH 2/5 v4] accel/qaic: tighten bounds checking in decode_message()

2023-07-14 Thread Pranjal Ramajor Asha Kanojiya
gt; msg_hdr_len) Fixes: 129776ac2e38 ("accel/qaic: Add control path") Signed-off-by: Dan Carpenter Reviewed-by: Pranjal Ramajor Asha Kanojiya

Re: [PATCH 1/5 v4] accel/qaic: tighten bounds checking in encode_message()

2023-07-14 Thread Pranjal Ramajor Asha Kanojiya
gt; user_msg->len) { Fixes: 129776ac2e38 ("accel/qaic: Add control path") Signed-off-by: Dan Carpenter Reviewed-by: Pranjal Ramajor Asha Kanojiya

Re: [PATCH 3/5] accel/qaic: Add consistent integer overflow checks

2023-07-07 Thread Pranjal Ramajor Asha Kanojiya
integer overflow checking in encode_dma() to use size_add() so everything is consistent. Fixes: 129776ac2e38 ("accel/qaic: Add control path") Signed-off-by: Dan Carpenter Reviewed-by: Jeffrey Hugo Looks good to me. Just the #include as Jeff suggested. Reviewed-by: Pranjal Ra

Re: [PATCH 5/5] accel/qaic: Fix a leak in map_user_pages()

2023-07-07 Thread Pranjal Ramajor Asha Kanojiya
goto free_page_list; + if (ret != nr_pages) { + nr_pages = ret; + ret = -EFAULT; + goto put_pages; } sgt = kmalloc(sizeof(*sgt), GFP_KERNEL); Thank you for catching this :) Reviewed-by: Pranjal Ramajor Asha Kanojiya

Re: [PATCH 1/5] accel/qaic: tighten bounds checking in encode_message()

2023-07-04 Thread Pranjal Ramajor Asha Kanojiya
On 7/4/2023 2:08 PM, Dan Carpenter wrote: On Tue, Jul 04, 2023 at 11:57:51AM +0530, Pranjal Ramajor Asha Kanojiya wrote: diff --git a/drivers/accel/qaic/qaic_control.c b/drivers/accel/qaic/qaic_control.c index 5c57f7b4494e..a51b1594dcfa 100644 --- a/drivers/accel/qaic/qaic_control.c +++ b

Re: [PATCH 1/5] accel/qaic: tighten bounds checking in encode_message()

2023-07-03 Thread Pranjal Ramajor Asha Kanojiya
On 7/4/2023 11:57 AM, Pranjal Ramajor Asha Kanojiya wrote: On 6/21/2023 12:51 PM, Dan Carpenter wrote: There are several issues in this code.  The check at the start of the loop: if (user_len >= user_msg->len) { This check does not ensure that we have enough space for the tra

Re: [PATCH 2/5] accel/qaic: tighten bounds checking in decode_message()

2023-07-03 Thread Pranjal Ramajor Asha Kanojiya
On 6/21/2023 12:51 PM, Dan Carpenter wrote: Copy the bounds checking from encode_message() to decode_message(). This patch addresses the following concerns. Ensure that there is enough space for at least one header so that we don't have a negative size later. if (msg_hdr_len < sizeo

Re: [PATCH 1/5] accel/qaic: tighten bounds checking in encode_message()

2023-07-03 Thread Pranjal Ramajor Asha Kanojiya
On 6/21/2023 12:51 PM, Dan Carpenter wrote: There are several issues in this code. The check at the start of the loop: if (user_len >= user_msg->len) { This check does not ensure that we have enough space for the trans_hdr (8 bytes). Instead the check needs to be: if (user

Re: [PATCH 1/5] accel/qaic: tighten bounds checking in encode_message()

2023-06-22 Thread Pranjal Ramajor Asha Kanojiya
On 6/21/2023 12:51 PM, Dan Carpenter wrote: There are several issues in this code. The check at the start of the loop: if (user_len >= user_msg->len) { This check does not ensure that we have enough space for the trans_hdr (8 bytes). Instead the check needs to be: if (user

Re: [PATCH] accel/qaic: Fix dereferencing freed memory

2023-06-13 Thread Pranjal Ramajor Asha Kanojiya
On 6/12/2023 8:39 PM, Jeffrey Hugo wrote: On 6/12/2023 7:21 AM, Christian König wrote: Am 12.06.23 um 15:03 schrieb Pranjal Ramajor Asha Kanojiya: On 6/12/2023 4:52 PM, Christian König wrote: Am 10.06.23 um 04:12 schrieb Sukrut Bellary: smatch warning: drivers/accel/qaic

Re: [PATCH] accel/qaic: Fix dereferencing freed memory

2023-06-13 Thread Pranjal Ramajor Asha Kanojiya
ort_attach); - dma_buf_put(obj->import_attach->dmabuf); + dma_buf_put(dmabuf); } else { /* Private buffer allocation path */ qaic_free_sgt(bo->sgt); Reviewed-by: Pranjal Ramajor Asha Kanojiya

Re: [PATCH] accel/qaic: Fix dereferencing freed memory

2023-06-13 Thread Pranjal Ramajor Asha Kanojiya
On 6/12/2023 4:52 PM, Christian König wrote: Am 10.06.23 um 04:12 schrieb Sukrut Bellary: smatch warning: drivers/accel/qaic/qaic_data.c:620 qaic_free_object() error:     dereferencing freed memory 'obj->import_attach' obj->import_attach is detached and freed using dma_buf_detach()

Re: [PATCH] MAINTAINERS: Add Carl/Pranjal as QAIC reviewers

2023-05-24 Thread Pranjal Ramajor Asha Kanojiya
: Pranjal Ramajor Asha Kanojiya L:linux-arm-...@vger.kernel.org L:dri-devel@lists.freedesktop.org S:Supported ACK Reviewed-by: Pranjal Ramajor Asha Kanojiya

Re: [PATCH v2] accel/qaic: initialize ret variable to 0

2023-05-18 Thread Pranjal Ramajor Asha Kanojiya
int ret = 0; if (obj->import_attach) return -EINVAL; Reviewed-by: Pranjal Ramajor Asha Kanojiya

Re: [PATCH] accel/qaic: silence some uninitialized variable warnings

2023-05-12 Thread Pranjal Ramajor Asha Kanojiya
int ret; /* Thank you Dan for the patch. Reviewed-by: Pranjal Ramajor Asha Kanojiya I agree with Jeff's comment to sort the variable declaration length wise.