mirror of
https://github.com/Telecominfraproject/OpenCellular.git
synced 2026-01-08 16:41:55 +00:00
If the AP ignores the LPC_ST_BUSY bit (which is software-defined) and tries to send a second host command while the first one is still processed, we discard it. This doesn't prevent the host to re-write the command arguments stored in LPC shared mem (aka LPC_POOL_CMD_DATA) but when we will call host_packet_receive, we will have either the old arguments or the new arguments (or even a mix of both, which is less unlikely to pass the checksum check), and we will copy them once before calling the HOSTCMD task. So the host command task will have a single coherent (not changing) view of the arguments when performing its input validation. Signed-off-by: Vincent Palatin <vpalatin@chromium.org> BRANCH=samus BUG=chrome-os-partner:31492 chrome-os-partner:23806 TEST=Boot Samus and play with ectool Change-Id: I9aa1b8cdac05e323b91998188bd873826e83c274 Reviewed-on: https://chromium-review.googlesource.com/242593 Reviewed-by: Randall Spangler <rspangler@chromium.org> Reviewed-by: Alec Berg <alecaberg@chromium.org> Tested-by: Vincent Palatin <vpalatin@chromium.org> Commit-Queue: Vincent Palatin <vpalatin@chromium.org> Trybot-Ready: Vincent Palatin <vpalatin@chromium.org> Reviewed-by: Kees Cook <keescook@chromium.org>