From 0881781e60abdd455354b4354daff66a6ef4a4fe Mon Sep 17 00:00:00 2001 From: Ben Gras Date: Sat, 26 Jul 2014 13:53:50 +0200 Subject: [PATCH] custom message for vm_query_exit --- include/minix/com.h | 1 - include/minix/ipc.h | 7 +++++++ lib/libsys/vm_query_exit.c | 2 +- servers/vm/queryexit.c | 2 +- 4 files changed, 9 insertions(+), 3 deletions(-) diff --git a/include/minix/com.h b/include/minix/com.h index 79b172f07..dca4f0c8c 100644 --- a/include/minix/com.h +++ b/include/minix/com.h @@ -788,7 +788,6 @@ # define VM_RS_MEM_MAKE_VM 1 /* make VM instance */ #define VM_WATCH_EXIT (VM_RQ_BASE+43) -# define VM_WE_EP m1_i1 #define VM_REMAP_RO (VM_RQ_BASE+44) /* same args as VM_REMAP */ diff --git a/include/minix/ipc.h b/include/minix/ipc.h index f5932b4f4..c65982e9c 100644 --- a/include/minix/ipc.h +++ b/include/minix/ipc.h @@ -1758,6 +1758,12 @@ typedef struct { } mess_lsys_vm_update; _ASSERT_MSG_SIZE(mess_lsys_vm_update); +typedef struct { + endpoint_t ep; + uint8_t padding[52]; +} mess_lsys_vm_watch_exit; +_ASSERT_MSG_SIZE(mess_lsys_vm_watch_exit); + typedef struct { endpoint_t m_source; /* who sent the message */ int m_type; /* what kind of message is it */ @@ -1983,6 +1989,7 @@ typedef struct { mess_lsys_vm_query_exit m_lsys_vm_query_exit; mess_lsys_vm_info m_lsys_vm_info; mess_lsys_vm_update m_lsys_vm_update; + mess_lsys_vm_watch_exit m_lsys_vm_watch_exit; mess_vfs_lchardriver_cancel m_vfs_lchardriver_cancel; mess_vfs_lchardriver_openclose m_vfs_lchardriver_openclose; diff --git a/lib/libsys/vm_query_exit.c b/lib/libsys/vm_query_exit.c index 49d1334cf..6d8ca33ef 100644 --- a/lib/libsys/vm_query_exit.c +++ b/lib/libsys/vm_query_exit.c @@ -32,6 +32,6 @@ vm_watch_exit(endpoint_t ep) message m; memset(&m, 0, sizeof(m)); - m.VM_WE_EP = ep; + m.m_lsys_vm_watch_exit.ep = ep; return _taskcall(VM_PROC_NR, VM_WATCH_EXIT, &m); } diff --git a/servers/vm/queryexit.c b/servers/vm/queryexit.c index cff96b5e1..8f21da389 100644 --- a/servers/vm/queryexit.c +++ b/servers/vm/queryexit.c @@ -119,7 +119,7 @@ out: *===========================================================================*/ int do_watch_exit(message *m) { - endpoint_t e = m->VM_WE_EP; + endpoint_t e = m->m_lsys_vm_watch_exit.ep; struct vmproc *vmp; int p; if(vm_isokendpt(e, &p) != OK) return ESRCH;