1 /*
2  * Copyright (c) 2017 Intel Corporation
3  *
4  * SPDX-License-Identifier: Apache-2.0
5  */
6 
7 #include <syscall_handler.h>
8 #include <drivers/ipm.h>
9 
z_vrfy_ipm_send(const struct device * dev,int wait,uint32_t id,const void * data,int size)10 static inline int z_vrfy_ipm_send(const struct device *dev, int wait,
11 				  uint32_t id,
12 				  const void *data, int size)
13 {
14 	Z_OOPS(Z_SYSCALL_DRIVER_IPM(dev, send));
15 	Z_OOPS(Z_SYSCALL_MEMORY_READ(data, size));
16 	return z_impl_ipm_send((const struct device *)dev, wait, id,
17 			       (const void *)data, size);
18 }
19 #include <syscalls/ipm_send_mrsh.c>
20 
z_vrfy_ipm_max_data_size_get(const struct device * dev)21 static inline int z_vrfy_ipm_max_data_size_get(const struct device *dev)
22 {
23 	Z_OOPS(Z_SYSCALL_DRIVER_IPM(dev, max_data_size_get));
24 	return z_impl_ipm_max_data_size_get((const struct device *)dev);
25 }
26 #include <syscalls/ipm_max_data_size_get_mrsh.c>
27 
z_vrfy_ipm_max_id_val_get(const struct device * dev)28 static inline uint32_t z_vrfy_ipm_max_id_val_get(const struct device *dev)
29 {
30 	Z_OOPS(Z_SYSCALL_DRIVER_IPM(dev, max_id_val_get));
31 	return z_impl_ipm_max_id_val_get((const struct device *)dev);
32 }
33 #include <syscalls/ipm_max_id_val_get_mrsh.c>
34 
z_vrfy_ipm_set_enabled(const struct device * dev,int enable)35 static inline int z_vrfy_ipm_set_enabled(const struct device *dev, int enable)
36 {
37 	Z_OOPS(Z_SYSCALL_DRIVER_IPM(dev, set_enabled));
38 	return z_impl_ipm_set_enabled((const struct device *)dev, enable);
39 }
40 #include <syscalls/ipm_set_enabled_mrsh.c>
41