Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

misc: fastrpc: use coherent pool for untranslated Compute Banks

Use fastrpc_remote_heap_alloc to allocate from the FastRPC device
instead of the Compute Bank when the session ID is 0. This ensures
that the allocation is inside the coherent DMA pool which is already
accessible to the DSP. This is necessary to support FastRPC devices
which do not have dedicated Compute Banks such as the SLPI on the SDM845.
The latter uses an allocated CMA region instead of FastRPC Compute Banks.

Signed-off-by: Dylan Van Assche <me@dylanvanassche.be>
Reviewed-by: Caleb Connolly <caleb.connolly@linaro.org>
Reviewed-by: Ekansh Gupta <quic_ekangupt@quicinc.com>
Reviewed-by: Dmitry Baryshkov <dmitry.baryshkov@linaro.org>
Signed-off-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org>
Link: https://lore.kernel.org/r/20240705075900.424100-6-srinivas.kandagatla@linaro.org
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Dylan Van Assche and committed by
Greg Kroah-Hartman
ba217405 c3c0363b

+4 -1
+4 -1
drivers/misc/fastrpc.c
··· 953 953 954 954 ctx->msg_sz = pkt_size; 955 955 956 - err = fastrpc_buf_alloc(ctx->fl, dev, pkt_size, &ctx->buf); 956 + if (ctx->fl->sctx->sid) 957 + err = fastrpc_buf_alloc(ctx->fl, dev, pkt_size, &ctx->buf); 958 + else 959 + err = fastrpc_remote_heap_alloc(ctx->fl, dev, pkt_size, &ctx->buf); 957 960 if (err) 958 961 return err; 959 962