summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYilun Lin <yllin@google.com>2019-02-26 15:55:49 +0800
committerchrome-bot <chrome-bot@chromium.org>2019-03-07 20:21:39 -0800
commit1283fc7316d211853f7293f1dae83be44e7fb82e (patch)
treea94f5869fc7dced4b199625ab431a9658bedc77d
parent8b1b74c10a87c8477bc65b7be1f6943676bd56bb (diff)
downloadchrome-ec-1283fc7316d211853f7293f1dae83be44e7fb82e.tar.gz
kukui_scp/ipi: Clarify ipi_send() signature.
ipi_send() shuold not modify the buffer argument. This CL changes argument type from 'void *' to 'const void *'. TEST=make BOARD=kukui_scp -j BUG=b:120808999 BRANCH=None Change-Id: I1e629c7d6ba6902df1e8e2a21b7ac29bf3dffebf Signed-off-by: Yilun Lin <yllin@google.com> Reviewed-on: https://chromium-review.googlesource.com/1490796 Commit-Ready: ChromeOS CL Exonerator Bot <chromiumos-cl-exonerator@appspot.gserviceaccount.com> Tested-by: Yilun Lin <yllin@chromium.org> Reviewed-by: Pi-Hsun Shih <pihsun@chromium.org>
-rw-r--r--chip/mt_scp/ipi.c2
-rw-r--r--chip/mt_scp/ipi_chip.h2
2 files changed, 2 insertions, 2 deletions
diff --git a/chip/mt_scp/ipi.c b/chip/mt_scp/ipi.c
index 5ec49d318d..05bbed890b 100644
--- a/chip/mt_scp/ipi.c
+++ b/chip/mt_scp/ipi.c
@@ -59,7 +59,7 @@ static inline void try_to_wakeup_ap(int32_t id)
}
/* Send data from SCP to AP. */
-int ipi_send(int32_t id, void *buf, uint32_t len, int wait)
+int ipi_send(int32_t id, const void *buf, uint32_t len, int wait)
{
/*
* TODO(b:117917141): Evaluate if we can remove this once we have the
diff --git a/chip/mt_scp/ipi_chip.h b/chip/mt_scp/ipi_chip.h
index b6eeddfc87..085c1415af 100644
--- a/chip/mt_scp/ipi_chip.h
+++ b/chip/mt_scp/ipi_chip.h
@@ -47,7 +47,7 @@ struct ipc_shared_obj {
};
/* Send a IPI contents to AP. */
-int ipi_send(int32_t id, void *buf, uint32_t len, int wait);
+int ipi_send(int32_t id, const void *buf, uint32_t len, int wait);
/* Size of the rpmsg device name, should sync across kernel and EC. */
#define RPMSG_NAME_SIZE 32