SYS_TIMES, SYS_SETALARM, SYS_SETGRANT, \
SYS_PROFBUF, SYS_DIAGCTL, SYS_STATECTL, SYS_SAFEMEMSET
-/* Field names for SYS_MEMSET. */
-#define MEM_PTR m2_p1 /* base */
-#define MEM_COUNT m2_l1 /* count */
-#define MEM_PATTERN m2_l2 /* pattern to write */
-#define MEM_PROCESS m2_i1 /* NONE (phys) or process id (vir) */
-
/* Field names for SYS_DEVIO, SYS_VDEVIO, SYS_SDEVIO. */
#define DIO_REQUEST m2_i3 /* device in or output */
# define _DIO_INPUT 0x001
} mess_lsys_krn_schedctl;
_ASSERT_MSG_SIZE(mess_lsys_krn_schedctl);
+typedef struct {
+ phys_bytes base;
+ phys_bytes count;
+ unsigned long pattern;
+ endpoint_t process;
+
+ uint8_t padding[40];
+} mess_lsys_krn_sys_memset;
+_ASSERT_MSG_SIZE(mess_lsys_krn_sys_memset);
+
typedef struct {
int devind;
int port;
mess_lsys_krn_schedctl m_lsys_krn_schedctl;
mess_lsys_krn_schedule m_lsys_krn_schedule;
+ mess_lsys_krn_sys_memset m_lsys_krn_sys_memset;
mess_lsys_pci_busc_get_bar m_lsys_pci_busc_get_bar;
* m_type: SYS_MEMSET
*
* The parameters for this kernel call are:
- * m2_p1: MEM_PTR (virtual address)
- * m2_l1: MEM_COUNT (returns physical address)
- * m2_l2: MEM_PATTERN (pattern byte to be written)
+ * m_lsys_krn_sys_memset.base (virtual address)
+ * m_lsys_krn_sys_memset.count (returns physical address)
+ * m_lsys_krn_sys_memset.pattern (pattern byte to be written)
*/
#include "kernel/system.h"
int do_memset(struct proc * caller, message * m_ptr)
{
/* Handle sys_memset(). This writes a pattern into the specified memory. */
- vm_memset(caller, m_ptr->MEM_PROCESS, (phys_bytes) m_ptr->MEM_PTR,
- m_ptr->MEM_PATTERN, (phys_bytes) m_ptr->MEM_COUNT);
+ vm_memset(caller, m_ptr->m_lsys_krn_sys_memset.process,
+ m_ptr->m_lsys_krn_sys_memset.base,
+ m_ptr->m_lsys_krn_sys_memset.pattern,
+ m_ptr->m_lsys_krn_sys_memset.count);
return(OK);
}
if (bytes == 0L) return(OK);
- mess.MEM_PTR = (char *) base;
- mess.MEM_COUNT = bytes;
- mess.MEM_PATTERN = pattern;
- mess.MEM_PROCESS = who;
+ mess.m_lsys_krn_sys_memset.base = base;
+ mess.m_lsys_krn_sys_memset.count = bytes;
+ mess.m_lsys_krn_sys_memset.pattern = pattern;
+ mess.m_lsys_krn_sys_memset.process = who;
return(_kernel_call(SYS_MEMSET, &mess));
}