struct minix_ipcvecs - pretty-print
- the _ptr suffix is not needed anymore :-)
This commit is contained in:
parent
dedb53fb10
commit
10f30159a9
4 changed files with 49 additions and 49 deletions
|
@ -173,13 +173,13 @@ int _minix_kernel_info_struct(struct minix_kerninfo **);
|
|||
#define senda _senda
|
||||
|
||||
struct minix_ipcvecs {
|
||||
int (*send_ptr)(endpoint_t dest, message *m_ptr);
|
||||
int (*receive_ptr)(endpoint_t src, message *m_ptr, int *st);
|
||||
int (*sendrec_ptr)(endpoint_t src_dest, message *m_ptr);
|
||||
int (*sendnb_ptr)(endpoint_t dest, message *m_ptr);
|
||||
int (*notify_ptr)(endpoint_t dest);
|
||||
int (*do_kernel_call_ptr)(message *m_ptr);
|
||||
int (*senda_ptr)(asynmsg_t *table, size_t count);
|
||||
int (*send)(endpoint_t dest, message *m_ptr);
|
||||
int (*receive)(endpoint_t src, message *m_ptr, int *st);
|
||||
int (*sendrec)(endpoint_t src_dest, message *m_ptr);
|
||||
int (*sendnb)(endpoint_t dest, message *m_ptr);
|
||||
int (*notify)(endpoint_t dest);
|
||||
int (*do_kernel_call)(message *m_ptr);
|
||||
int (*senda)(asynmsg_t *table, size_t count);
|
||||
};
|
||||
|
||||
/* kernel-set IPC vectors retrieved by a constructor in libc/sys-minix/init.c */
|
||||
|
@ -187,37 +187,37 @@ extern struct minix_ipcvecs _minix_ipcvecs;
|
|||
|
||||
static inline int _send(endpoint_t dest, message *m_ptr)
|
||||
{
|
||||
return _minix_ipcvecs.send_ptr(dest, m_ptr);
|
||||
return _minix_ipcvecs.send(dest, m_ptr);
|
||||
}
|
||||
|
||||
static inline int _receive(endpoint_t src, message *m_ptr, int *st)
|
||||
{
|
||||
return _minix_ipcvecs.receive_ptr(src, m_ptr, st);
|
||||
return _minix_ipcvecs.receive(src, m_ptr, st);
|
||||
}
|
||||
|
||||
static inline int _sendrec(endpoint_t src_dest, message *m_ptr)
|
||||
{
|
||||
return _minix_ipcvecs.sendrec_ptr(src_dest, m_ptr);
|
||||
return _minix_ipcvecs.sendrec(src_dest, m_ptr);
|
||||
}
|
||||
|
||||
static inline int _sendnb(endpoint_t dest, message *m_ptr)
|
||||
{
|
||||
return _minix_ipcvecs.send_ptr(dest, m_ptr);
|
||||
return _minix_ipcvecs.send(dest, m_ptr);
|
||||
}
|
||||
|
||||
static inline int _notify(endpoint_t dest)
|
||||
{
|
||||
return _minix_ipcvecs.notify_ptr(dest);
|
||||
return _minix_ipcvecs.notify(dest);
|
||||
}
|
||||
|
||||
static inline int do_kernel_call(message *m_ptr)
|
||||
{
|
||||
return _minix_ipcvecs.do_kernel_call_ptr(m_ptr);
|
||||
return _minix_ipcvecs.do_kernel_call(m_ptr);
|
||||
}
|
||||
|
||||
static inline int _senda(asynmsg_t *table, size_t count)
|
||||
{
|
||||
return _minix_ipcvecs.senda_ptr(table, count);
|
||||
return _minix_ipcvecs.senda(table, count);
|
||||
}
|
||||
|
||||
#endif /* _IPC_H */
|
||||
|
|
|
@ -942,13 +942,13 @@ int arch_phys_map_reply(const int index, const vir_bytes addr)
|
|||
/* adjust the pointers of the functions and the struct
|
||||
* itself to the user-accessible mapping
|
||||
*/
|
||||
FIXPTR(minix_kerninfo.minix_ipcvecs->send_ptr);
|
||||
FIXPTR(minix_kerninfo.minix_ipcvecs->receive_ptr);
|
||||
FIXPTR(minix_kerninfo.minix_ipcvecs->sendrec_ptr);
|
||||
FIXPTR(minix_kerninfo.minix_ipcvecs->senda_ptr);
|
||||
FIXPTR(minix_kerninfo.minix_ipcvecs->sendnb_ptr);
|
||||
FIXPTR(minix_kerninfo.minix_ipcvecs->notify_ptr);
|
||||
FIXPTR(minix_kerninfo.minix_ipcvecs->do_kernel_call_ptr);
|
||||
FIXPTR(minix_kerninfo.minix_ipcvecs->send);
|
||||
FIXPTR(minix_kerninfo.minix_ipcvecs->receive);
|
||||
FIXPTR(minix_kerninfo.minix_ipcvecs->sendrec);
|
||||
FIXPTR(minix_kerninfo.minix_ipcvecs->senda);
|
||||
FIXPTR(minix_kerninfo.minix_ipcvecs->sendnb);
|
||||
FIXPTR(minix_kerninfo.minix_ipcvecs->notify);
|
||||
FIXPTR(minix_kerninfo.minix_ipcvecs->do_kernel_call);
|
||||
FIXPTR(minix_kerninfo.minix_ipcvecs);
|
||||
|
||||
minix_kerninfo.kerninfo_magic = KERNINFO_MAGIC;
|
||||
|
|
|
@ -2,32 +2,32 @@
|
|||
#include "arch_proto.h"
|
||||
|
||||
struct minix_ipcvecs minix_ipcvecs_softint = {
|
||||
.send_ptr = usermapped_send_softint,
|
||||
.receive_ptr = usermapped_receive_softint,
|
||||
.sendrec_ptr = usermapped_sendrec_softint,
|
||||
.sendnb_ptr = usermapped_sendnb_softint,
|
||||
.notify_ptr = usermapped_notify_softint,
|
||||
.do_kernel_call_ptr = usermapped_do_kernel_call_softint,
|
||||
.senda_ptr = usermapped_senda_softint
|
||||
.send = usermapped_send_softint,
|
||||
.receive = usermapped_receive_softint,
|
||||
.sendrec = usermapped_sendrec_softint,
|
||||
.sendnb = usermapped_sendnb_softint,
|
||||
.notify = usermapped_notify_softint,
|
||||
.do_kernel_call = usermapped_do_kernel_call_softint,
|
||||
.senda = usermapped_senda_softint
|
||||
};
|
||||
|
||||
struct minix_ipcvecs minix_ipcvecs_sysenter = {
|
||||
.send_ptr = usermapped_send_sysenter,
|
||||
.receive_ptr = usermapped_receive_sysenter,
|
||||
.sendrec_ptr = usermapped_sendrec_sysenter,
|
||||
.sendnb_ptr = usermapped_sendnb_sysenter,
|
||||
.notify_ptr = usermapped_notify_sysenter,
|
||||
.do_kernel_call_ptr = usermapped_do_kernel_call_sysenter,
|
||||
.senda_ptr = usermapped_senda_sysenter
|
||||
.send = usermapped_send_sysenter,
|
||||
.receive = usermapped_receive_sysenter,
|
||||
.sendrec = usermapped_sendrec_sysenter,
|
||||
.sendnb = usermapped_sendnb_sysenter,
|
||||
.notify = usermapped_notify_sysenter,
|
||||
.do_kernel_call = usermapped_do_kernel_call_sysenter,
|
||||
.senda = usermapped_senda_sysenter
|
||||
};
|
||||
|
||||
struct minix_ipcvecs minix_ipcvecs_syscall = {
|
||||
.send_ptr = usermapped_send_syscall,
|
||||
.receive_ptr = usermapped_receive_syscall,
|
||||
.sendrec_ptr = usermapped_sendrec_syscall,
|
||||
.sendnb_ptr = usermapped_sendnb_syscall,
|
||||
.notify_ptr = usermapped_notify_syscall,
|
||||
.do_kernel_call_ptr = usermapped_do_kernel_call_syscall,
|
||||
.senda_ptr = usermapped_senda_syscall
|
||||
.send = usermapped_send_syscall,
|
||||
.receive = usermapped_receive_syscall,
|
||||
.sendrec = usermapped_sendrec_syscall,
|
||||
.sendnb = usermapped_sendnb_syscall,
|
||||
.notify = usermapped_notify_syscall,
|
||||
.do_kernel_call = usermapped_do_kernel_call_syscall,
|
||||
.senda = usermapped_senda_syscall
|
||||
};
|
||||
|
||||
|
|
|
@ -8,13 +8,13 @@ struct minix_kerninfo *_minix_kerninfo = NULL;
|
|||
void __minix_init(void) __attribute__((__constructor__, __used__));
|
||||
|
||||
struct minix_ipcvecs _minix_ipcvecs = {
|
||||
.sendrec_ptr = _sendrec_orig,
|
||||
.send_ptr = _send_orig,
|
||||
.notify_ptr = _notify_orig,
|
||||
.senda_ptr = _senda_orig,
|
||||
.sendnb_ptr = _sendnb_orig,
|
||||
.receive_ptr = _receive_orig,
|
||||
.do_kernel_call_ptr = _do_kernel_call_orig,
|
||||
.sendrec = _sendrec_orig,
|
||||
.send = _send_orig,
|
||||
.notify = _notify_orig,
|
||||
.senda = _senda_orig,
|
||||
.sendnb = _sendnb_orig,
|
||||
.receive = _receive_orig,
|
||||
.do_kernel_call = _do_kernel_call_orig,
|
||||
};
|
||||
|
||||
void __minix_init(void)
|
||||
|
|
Loading…
Reference in a new issue