From mboxrd@z Thu Jan 1 00:00:00 1970 From: Claude Code Review Bot To: dri-devel-reviews@example.com Subject: Claude review: misc: fastrpc: Fix initial memory allocation for Audio PD memory pool Date: Sat, 16 May 2026 09:09:54 +1000 Message-ID: In-Reply-To: <20260515124217.20723-2-jianping.li@oss.qualcomm.com> References: <20260515124217.20723-1-jianping.li@oss.qualcomm.com> <20260515124217.20723-2-jianping.li@oss.qualcomm.com> X-Mailer: Claude Code Patch Reviewer Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit MIME-Version: 1.0 Patch Review **Verdict: Looks good.** The fix is correct. In the original code, `inbuf.pageslen` is unconditionally set to 0 *after* the remote heap allocation and SCM assignment block, so the DSP never receives the allocated buffer: ```c // original: pageslen always 0 inbuf.client_id = fl->client_id; inbuf.namelen = init.namelen; inbuf.pageslen = 0; ``` The patch moves these assignments before the allocation block and sets `pageslen = 1` when the SCM assignment succeeds: ```c + scm_done = true; + inbuf.pageslen = 1; ``` This ensures the initially allocated buffer is actually registered with the Audio PD. The logic is clean: default `pageslen=0`, set to 1 only when memory is both allocated and SCM-assigned. Note: This code is removed by patch 4, so this fix is primarily for stable backports. --- --- Generated by Claude Code Patch Reviewer