aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorCarlo Caione2017-03-03 09:17:58 -0600
committerKevin Hilman2017-03-23 14:22:32 -0500
commit83e007a0c6a3f4bfdf8f3f8d0fc266cda189b3d6 (patch)
tree7f5abab493f662317dc23ae0bf857e750c2917ff /include
parentc1ae3cfa0e89fa1a7ecc4c99031f5e9ae99d9201 (diff)
downloadkernel-83e007a0c6a3f4bfdf8f3f8d0fc266cda189b3d6.tar.gz
kernel-83e007a0c6a3f4bfdf8f3f8d0fc266cda189b3d6.tar.xz
kernel-83e007a0c6a3f4bfdf8f3f8d0fc266cda189b3d6.zip
firmware: meson-sm: Check for buffer output size
After the data is read by the secure monitor driver it is being copied in the output buffer checking only the size of the bounce buffer but not the size of the output buffer. Fix this in the secure monitor driver slightly changing the API. Fix also the efuse driver that it is the only driver using this API to not break bisectability. Signed-off-by: Carlo Caione <carlo@endlessm.com> Acked-by: Srinivas Kandagatla <srinivas.kandagatla@linaro.org> # for nvmem Acked-by: Mark Rutland <mark.rutland@arm.com> Signed-off-by: Kevin Hilman <khilman@baylibre.com>
Diffstat (limited to 'include')
-rw-r--r--include/linux/firmware/meson/meson_sm.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/include/linux/firmware/meson/meson_sm.h b/include/linux/firmware/meson/meson_sm.h
index 8e953c6f394a..37a5eaea69dd 100644
--- a/include/linux/firmware/meson/meson_sm.h
+++ b/include/linux/firmware/meson/meson_sm.h
@@ -25,7 +25,7 @@ int meson_sm_call(unsigned int cmd_index, u32 *ret, u32 arg0, u32 arg1,
25 u32 arg2, u32 arg3, u32 arg4); 25 u32 arg2, u32 arg3, u32 arg4);
26int meson_sm_call_write(void *buffer, unsigned int b_size, unsigned int cmd_index, 26int meson_sm_call_write(void *buffer, unsigned int b_size, unsigned int cmd_index,
27 u32 arg0, u32 arg1, u32 arg2, u32 arg3, u32 arg4); 27 u32 arg0, u32 arg1, u32 arg2, u32 arg3, u32 arg4);
28int meson_sm_call_read(void *buffer, unsigned int cmd_index, u32 arg0, u32 arg1, 28int meson_sm_call_read(void *buffer, unsigned int bsize, unsigned int cmd_index,
29 u32 arg2, u32 arg3, u32 arg4); 29 u32 arg0, u32 arg1, u32 arg2, u32 arg3, u32 arg4);
30 30
31#endif /* _MESON_SM_FW_H_ */ 31#endif /* _MESON_SM_FW_H_ */