Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Skip to content
Commit 3c250821 authored by Jeff Hugo's avatar Jeff Hugo
Browse files

soc: qcom: smp2p: Copy the entry name out of smem for comparison



Shared memory is configured as device memory, and thus has specific access
requirements.  Functions like strcmp() are not guaranteed to do the proper
accesses.  Searching for a SMP2P entry involves a strcmp() call with the
entry name stored in shared memory used as one of the parameters.

To ensure safe device memory accesses, use a safe memcpy function to copy
the entry name into local memory, and use that copy for the comparison.

Change-Id: I3edb236090ce21201330485acd54c6de18ece3b6
Signed-off-by: default avatarJeffrey Hugo <jhugo@codeaurora.org>
parent e589fedd
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment