MFi386: Use the BSD madvise() syscall implementation for Linux binary

emulation, instead of treating it as an unimplemented syscall.

Requested by:	marcel
This commit is contained in:
Bruce M Simpson 2004-03-29 02:19:43 +00:00
parent 6ea748c0f1
commit d25901b5da
5 changed files with 3 additions and 8 deletions

View File

@ -66,7 +66,6 @@ DUMMY(sendfile);
DUMMY(getdtablesize);
DUMMY(gethostname);
DUMMY(getpagesize);
DUMMY(madvise);
DUMMY(mincore);
DUMMY(old_adjtimex);
DUMMY(pciconfig_iobase);

View File

@ -150,9 +150,6 @@ struct linux_mprotect_args {
char len_l_[PADL_(l_size_t)]; l_size_t len; char len_r_[PADR_(l_size_t)];
char prot_l_[PADL_(l_ulong)]; l_ulong prot; char prot_r_[PADR_(l_ulong)];
};
struct linux_madvise_args {
register_t dummy;
};
struct linux_vhangup_args {
register_t dummy;
};
@ -612,7 +609,6 @@ int linux_newlstat(struct thread *, struct linux_newlstat_args *);
int linux_mmap(struct thread *, struct linux_mmap_args *);
int linux_munmap(struct thread *, struct linux_munmap_args *);
int linux_mprotect(struct thread *, struct linux_mprotect_args *);
int linux_madvise(struct thread *, struct linux_madvise_args *);
int linux_vhangup(struct thread *, struct linux_vhangup_args *);
int linux_setgroups(struct thread *, struct linux_setgroups_args *);
int linux_getgroups(struct thread *, struct linux_getgroups_args *);

View File

@ -51,7 +51,7 @@
#define LINUX_SYS_linux_mmap 71
#define LINUX_SYS_linux_munmap 73
#define LINUX_SYS_linux_mprotect 74
#define LINUX_SYS_linux_madvise 75
#define LINUX_SYS_madvise 75
#define LINUX_SYS_linux_vhangup 76
#define LINUX_SYS_linux_setgroups 79
#define LINUX_SYS_linux_getgroups 80

View File

@ -92,7 +92,7 @@ struct sysent linux_sysent[] = {
{ 0, (sy_call_t *)nosys }, /* 72 = */
{ AS(linux_munmap_args), (sy_call_t *)linux_munmap }, /* 73 = linux_munmap */
{ AS(linux_mprotect_args), (sy_call_t *)linux_mprotect }, /* 74 = linux_mprotect */
{ 0, (sy_call_t *)linux_madvise }, /* 75 = linux_madvise */
{ SYF_MPSAFE | AS(madvise_args), (sy_call_t *)madvise }, /* 75 = madvise */
{ 0, (sy_call_t *)linux_vhangup }, /* 76 = linux_vhangup */
{ 0, (sy_call_t *)nosys }, /* 77 = */
{ 0, (sy_call_t *)nosys }, /* 78 = */

View File

@ -114,7 +114,7 @@
73 STD { int linux_munmap(l_ulong addr, l_size_t len); }
74 STD { int linux_mprotect(l_ulong addr, l_size_t len, \
l_ulong prot); }
75 STD { int linux_madvise(void); }
75 MNOPROTO { int madvise(void *addr, size_t len, int behav); }
76 STD { int linux_vhangup(void); }
77 UNIMPL
78 UNIMPL