History

remoteproc: mtk_scp: Constify buffer passed to scp_send_ipi()

scp_send_ipi() should only send the passed buffer, without modifying its contents, so mark pointer 'buf' as pointer to const.

Krzysztof Kozlowski committed 8 months ago

Commit 90dacbf1 parent 4251dab2 files · +2 −2Browse files

Unified · Split

2 files
  1. drivers/remoteproc/mtk_scp.c +1 −1
  2. include/linux/rpmsg/mtk_rpmsg.h +1 −1
drivers/remoteproc/mtk_scp.c+1−1
@@ -1078,7 +1078,7 @@ static void scp_unregister_ipi(struct platform_device *pdev, u32 id) · 1077 unmodified lines
10781078 scp_ipi_unregister(scp, id);
10791079 }
10801080
1081−static int scp_send_ipi(struct platform_device *pdev, u32 id, void *buf,
1081+static int scp_send_ipi(struct platform_device *pdev, u32 id, const void *buf,
10821082 unsigned int len, unsigned int wait)
10831083 {
10841084 struct mtk_scp *scp = platform_get_drvdata(pdev);
include/linux/rpmsg/mtk_rpmsg.h+1−1
@@ -25,7 +25,7 @@ struct mtk_rpmsg_info { · 24 unmodified lines
2525 ipi_handler_t handler, void *priv);
2626 void (*unregister_ipi)(struct platform_device *pdev, u32 id);
2727 int (*send_ipi)(struct platform_device *pdev, u32 id,
28− void *buf, unsigned int len, unsigned int wait);
28+ const void *buf, unsigned int len, unsigned int wait);
2929 int ns_ipi_id;
3030 };
3131

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t