Commit Graph

1373 Commits

Author SHA1 Message Date
cgd 9cc30ed036 needs mount.h 1999-05-01 04:38:39 +00:00
cgd 2d25ceb2d2 pull in compat_util.h 1999-05-01 04:38:20 +00:00
cgd e42f7d331f move mmap() and related functions into their own file 1999-05-01 04:34:20 +00:00
cgd 170b003d0b shuffle bits around. separate conversion conversion functions and tables
from the code that uses them, just as I previously separated out the
OSF/1 definitions and structures from the code that translates to and
from them.
1999-05-01 02:57:08 +00:00
cgd 38da682259 Moved to osf1_cvt_errno.c,v 1999-05-01 02:16:01 +00:00
cgd 333154d794 Moved from osf1_errno.c,v 1999-05-01 02:16:00 +00:00
cgd af8a9059d3 compute the value to be used for e_arglen via howmany(value, sizeof (char *)),
rather than just "value / sizeof (char *)".  While in these cases the latter
works as well, the former's a better example for other uses to copy (since
it handles the non-integral multiple case correctly).
1999-04-30 23:07:01 +00:00
cgd 1bce8c40fc ep_arglen is in units of 'sizeof (char *)', not in units of bytes. use
howmany(value, sizeof (char *)) to get the right value.
1999-04-30 23:02:06 +00:00
cgd 5a93f3c9b1 emulate wait4(), put some guts into sysinfo(), and redo fcntl()
F_{GET,SET}FL emulation.
1999-04-30 05:25:34 +00:00
cgd 28410181b2 return error if unsupported sigaltstack flags used 1999-04-30 05:24:04 +00:00
cgd a928d381b2 regen 1999-04-30 04:36:04 +00:00
cgd d2d8e961fe emulate wait4, clean up sigreturn args, emulate {get,set}domainname 1999-04-30 04:33:51 +00:00
cgd e836b093b4 nuke most fcntl() F* flags, and note that O_* should be used instead. 1999-04-30 04:31:45 +00:00
cgd c21c5d0c2d systeminfo.h SI_* constants, wait.h W{NOHANG,UNTRACED}, plus spacing cleanup 1999-04-30 02:12:03 +00:00
cgd afe914207b we can actually setitimer() now 1999-04-30 01:57:27 +00:00
cgd 94a4e36ed2 use osf1-specific sigcode 1999-04-30 01:46:09 +00:00
cgd 6abb3f7b37 regen 1999-04-29 23:39:55 +00:00
cgd 59c243a0b7 emulate setitimer(), but for now just return EINVAL. stub sysinfo() (XXX). 1999-04-29 23:37:23 +00:00
cgd e9bc2c7ae3 need to emulate setitimer and sysinfo 1999-04-29 22:08:49 +00:00
cgd 2b9f4ca12d in NetBSD, top 32 bits of ioctl com are always 0 1999-04-29 17:34:49 +00:00
thorpej 0792acce0d Regen. 1999-04-29 17:20:37 +00:00
thorpej fb1f070eba Add entry for set_program_attributes(). 1999-04-29 17:19:47 +00:00
thorpej 8ef6e2a635 Implement set_program_attributes(). 1999-04-29 17:18:59 +00:00
christos 4c1bb7794a Need sunos_sigcode and sunos_esigcode now that our sigreturn is
different.
1999-04-29 16:14:04 +00:00
christos a38ee86714 Make ss_size something reasonable (not 0) so sigaltstack does not fail.
Pull me up plz!
1999-04-29 16:09:12 +00:00
cgd a509481404 itimerval and related constants 1999-04-29 05:54:13 +00:00
cgd ee325de1bb regen for syscalls.master 1999-04-29 02:11:51 +00:00
cgd 1041a1c770 emulate access() and mprotect(), hook into COMPAT_43 get{peer,sock}name 1999-04-29 02:10:07 +00:00
cgd f4507cddca mprotect() and access() 1999-04-29 02:08:58 +00:00
cgd cc4f9f6afb access() flags 1999-04-29 02:06:50 +00:00
cgd 52b80ff167 fix some bugs (good to get to the point where bug-fixing is an issue!):
* when copying out the timezone in gettimeofday, don't accidentally copy
  out the timeval again (into the timezone buffer).
* mmap() PROT_WRITE and PROT_EXECUTE imply PROT_READ.
1999-04-28 06:01:51 +00:00
cgd 278f92716f regen for updated syscalls.master 1999-04-28 05:10:38 +00:00
cgd d3708a1699 more timeval-related lossage. fixed some fns, added settimeofday & utimes 1999-04-28 05:09:47 +00:00
cgd fc1142ac44 be more careful about getting the exec_name emul arg field 1999-04-28 02:49:38 +00:00
cgd a61beae31e regen for changed syscalls.master 1999-04-28 02:34:47 +00:00
cgd a9deaa593a emulate select(), to get the timeval right.
And CGD said, "Let there be eyes!"  And there were eyes, and it was good.
1999-04-28 02:34:25 +00:00
cgd 4c9a03c3b3 do easy 'f'-class ioctls 1999-04-28 02:16:07 +00:00
cgd 3cca776d42 regen for changed syscalls.master 1999-04-28 02:03:45 +00:00
cgd 28561f9679 can't use system gettimeofday, and need to implement uname 1999-04-28 02:03:13 +00:00
cgd 93e2cb1a1e uname, gettimeofday 1999-04-28 02:02:50 +00:00
cgd ccd0018aca uname and timezone structures, and some minor cleanup 1999-04-28 02:00:36 +00:00
cgd 6e5469dc42 implement osf1_sys_madvise() 1999-04-27 18:45:22 +00:00
cgd 3cb15b5b9b regen for changed syscalls.master 1999-04-27 18:41:37 +00:00
cgd df6ae494ef fix madvise args 1999-04-27 18:40:53 +00:00
cgd 99df19a561 madvise operation definitions 1999-04-27 18:38:07 +00:00
cgd 3d0c9ec2a8 kill a couple of debugging printfs i accidentally left in 1999-04-27 17:56:52 +00:00
cgd 8f40430549 regen for changed syscalls.master 1999-04-27 17:53:11 +00:00
cgd 6b9bb2a3cb fix getrusage args 1999-04-27 17:52:44 +00:00
cgd 009c460d25 emulate getrusage, add some XXXs 1999-04-27 17:50:59 +00:00
cgd 9a71b695bd osf1_timeval and osf1_rusage and related constants 1999-04-27 17:50:23 +00:00
cgd 44cbebec30 note that his should be shot from a cannon 1999-04-27 16:09:28 +00:00
cgd 1f9cfb5d53 update for current reality 1999-04-27 16:08:40 +00:00
christos b69c7692af From cgd again: pbuf == path on failure. 1999-04-27 15:42:37 +00:00
christos c4f1bab08e Make the usage consistant and document it:
if the path was given in a user buffer, return the new path in
a user buffer.
if the path was given in a kernel buffer, allocate a new kernel buffer
to return the new path; the caller is responsible for freeing the buffer
if we fail always set the new path to NULL.
This usage broke when I adde the /../ shortcut. Noted by cgd.
1999-04-27 11:36:47 +00:00
cgd f355b96b7a note that this document is now out of date 1999-04-27 06:39:49 +00:00
cgd 7e3ad9e963 evil hack to work around non-fixed mmap requests 1999-04-27 06:37:12 +00:00
cgd 6ef8f59ae6 dynamic executable/loader handling, done right 1999-04-27 05:38:08 +00:00
cgd 743038a6cb clean up for ecoff_machdep.h changes, look for the loader 1999-04-27 03:19:44 +00:00
cgd fe6198f6e2 do special OSF/1-specific ECOFF recognition (not yet complete), and
implement a copyargs function to do special argument copying for
emulated processes.
1999-04-27 01:45:03 +00:00
cgd bd33916784 exec internals have been moved (and improved) to osf1_exec.c. Not much
there yet, but more to come.
1999-04-26 18:34:05 +00:00
cgd bd947212ac major(), minor(), and makedev() 1999-04-26 06:10:36 +00:00
cgd 9524149336 use fcntl() flags from osf1.h, map all of them 1999-04-26 05:57:53 +00:00
cgd 1904f78fb5 fcntl() flags 1999-04-26 05:56:34 +00:00
cgd 6d24aedc2c table-based translation of sigaction and sigaltstack flags 1999-04-26 05:35:08 +00:00
cgd 635a7843a1 copyright notice 1999-04-26 05:32:18 +00:00
cgd 6dbaac99f9 slight cleanup of spacing 1999-04-26 04:29:43 +00:00
cgd 35a22b65fc rlimit stuff 1999-04-26 03:30:48 +00:00
cgd 646c8f519a resource limit definitions 1999-04-26 03:29:05 +00:00
cgd 5d3c1d0c49 use osf1.h definitions and some table-based flag translation 1999-04-26 03:10:58 +00:00
cgd 32c9cd9866 exec and mount structs/defns, and some cleanup 1999-04-26 03:07:40 +00:00
cgd 445556f304 add a section of OSF/1 types, and add many more OSF/1 structures and
definitions.
1999-04-26 01:24:26 +00:00
cgd 1d0207c926 const-ify flags translation tables.
kill some cruft, and move various flags and structure definitions into
  osf1.h (not done yet).
Do a better job of translating fcntl(), and translate flags in sento()
  emulation.
1999-04-26 01:23:01 +00:00
cgd 196564f8e3 remove some structs and def'ns; they're moving to osf1.h 1999-04-26 01:22:18 +00:00
cgd 637226f0ad pull in osf1.h 1999-04-26 01:21:43 +00:00
cgd ad10b95967 translate EAGAIN/EWOULDBLOCK properly 1999-04-26 01:16:04 +00:00
simonb 8a8e8d144f Shut 'gcc -Wuninitialized' up. 1999-04-25 02:42:01 +00:00
eeh 96b63fc788 Don't defopt COMPAT_NETBSD32 here; it's done in sys/conf/files. 1999-04-24 19:17:33 +00:00
cgd 45a020863e substantial cleanup, including:
* do more flags conversions, using the table driven converter.
* check for alternate (emulation) path in lots more places.
1999-04-24 07:23:54 +00:00
cgd ed106195ea cleanup: kill syscall args comments 1999-04-24 07:13:23 +00:00
cgd d081124ca2 cleanup: nuke register 1999-04-24 07:09:49 +00:00
cgd d7c211e583 cleanup: kill syscall args comments 1999-04-24 07:06:35 +00:00
cgd dd4d52e331 slight hdr inclusion cleanup, get ioctl-related def'ns from osf1.h 1999-04-24 06:59:11 +00:00
cgd 8b1bcd5e9c pull in osf1.h, not osf1_errno.h 1999-04-24 06:58:26 +00:00
cgd 2fc0019c7a Collected OSF/1 definitions and structures, sorted by OSF/1 header.
Error numbers (errno.h) aren't here, since they're likely to change
(additions) more often.
1999-04-24 06:56:25 +00:00
cgd 5b217baeb1 implement a simple function, emul_flags_translate() to do table-based
flags translation.
1999-04-24 02:56:06 +00:00
cgd f023a00cd1 clean up multiple inclusion protection def'ns 1999-04-23 18:01:05 +00:00
cgd 1c19c07f42 clean up multiple inclusion protection def'ns and whitespace 1999-04-23 18:00:34 +00:00
cgd cc6809bffa regen for 'const poisoning for strings, and minor cleanup' 1999-04-23 06:20:33 +00:00
cgd c95f8f86c1 const poisoning for strings, and minor cleanup 1999-04-23 06:19:51 +00:00
cgd c470144d55 use the errno mapping array 1999-04-23 06:15:35 +00:00
cgd 8ca456cbb3 add osf1_errno.c 1999-04-23 06:07:55 +00:00
cgd f0f87c5554 finish updating this for signal changes, as was started in the
mis-labeled ("const poisoning"?!??!) rev 1.6.
1999-04-23 05:56:28 +00:00
cgd f33ddea5c4 add an OSF1_CHECK_ALT_CREAT, similar to OSF1_CHECK_ALT_EXIST 1999-04-23 05:55:13 +00:00
cgd 4a84f3545a OSF/1 errno definitions, and a NetBSD -> OSF/1 errno mapping table. 1999-04-23 05:37:41 +00:00
cgd f12f795592 a quick hack to make generating errno conversion tables from our and other
systems' headers a bit easier.  leaves much to be desired, but it's better
than nothing.
1999-04-23 05:31:33 +00:00
kleink ed74932033 Add COMPAT_SVR4 for m68k. 1999-04-19 21:22:56 +00:00
kleink 6a9c669828 Move linux_reenter_syscall() to a common location and rename it to
reenter_syscall() - it's going to be shared with COMPAT_SVR4 and soon be
used by native code.
1999-04-19 20:58:37 +00:00
mrg 7007bb40d6 fix errors in the copyright on this. 1999-04-14 02:50:38 +00:00
augustss 1ea49a1848 Make copyright conform. 1999-04-13 20:31:32 +00:00
tv 724f072dde Nuke my copyrights and/or assign them to TNF where appropriate. 1999-04-06 02:55:24 +00:00
drochner 74768f75f4 remove unneeded <vm/*> includes 1999-04-01 18:37:33 +00:00
tron ab9ea90a8e Regen. 1999-03-30 07:37:58 +00:00
tron b46e8732dd Add poll() emulation. 1999-03-30 07:29:05 +00:00
abs bb2d7dd6dc Regenerate (with poll()) 1999-03-30 02:25:32 +00:00
abs 9c2ef08c3e Since NetBSD has poll(), use it.
Linux oracle install now gets far enough that I want our DBA around to
see if we can finish the job.
1999-03-30 02:22:49 +00:00
wrstuden eb10774f2b Explicitly mask mode returned in old stat structure to 16 bits. Also correct
comment (we're converting from a new to an old struct stat).
1999-03-30 00:13:57 +00:00
sommerfe 3e341c9af5 sync with regular syscalls.master: Add getcwd, fchroot, and tweak __getlogin 1999-03-28 21:56:56 +00:00
tron 82f6a3397b Regen. 1999-03-27 01:15:58 +00:00
tron 5b98b641a8 Add emulation for Linux "getcwd" syscall. 1999-03-27 01:10:56 +00:00
eeh 69d1f9d0d3 COMPAT_SPARC32 -> COMPAT_NETBSD32 1999-03-26 04:29:20 +00:00
mrg 54ab2e1e54 clean and up make compile 1999-03-25 17:49:43 +00:00
mrg c3b0d25b27 SPARC32->NETBSD32 1999-03-25 16:58:39 +00:00
mrg 8df6f0c629 regen 1999-03-25 16:32:27 +00:00
mrg 6f5ceb781e include the MD header. 1999-03-25 16:27:56 +00:00
mrg a5867d9385 move sparc32 to netbsd32; split out MD part (signal handling) (mostly via repository copy, rename and perl -pi :-) 1999-03-25 16:22:49 +00:00
mrg 8f32e2fbc8 regen 1999-03-25 15:51:50 +00:00
mrg 7f7d23b4a6 formatting nits 1999-03-25 15:34:37 +00:00
mrg ad412a0e07 make this match the main syscalls.master a bit better. 1999-03-25 15:33:48 +00:00
sommerfe 280a842850 commit fix to PR7072: emulate linux non-blocking connect behavior more correctly 1999-03-25 04:26:45 +00:00
mrg d2397ac5f7 completely remove Mach VM support. all that is left is the all the
header files as UVM still uses (most of) these.
1999-03-24 05:50:49 +00:00
kleink 6558e04aea Translate _PC_FILESIZEBITS. 1999-03-23 14:57:00 +00:00
itohy e4d7e0a023 Update to OSF/1 V4. 1999-03-23 09:19:25 +00:00
thorpej 9d49c8139a Regen; pread(2) and pwrite(2). 1999-03-23 03:01:48 +00:00
thorpej e8a3256e7f Add support for emulating the Linux pread(2) and pwrite(2) system calls;
just call the native NetBSD versions.

PR #7202, Jaromir Dolecek <dolecek@ics.muni.cz>.
1999-03-23 03:00:51 +00:00
sommerfe 166f97ecf3 Use regular system fchroot, now that we have it. 1999-03-22 17:30:37 +00:00
sommerfe 5effda814f Use standard system fchroot instead of emulation-specific copy. 1999-03-22 17:28:21 +00:00
thorpej 8712c97205 Don't do pathname translation for file creation. The real intent here is
just for lookups of existing files.  From Matthew Green <mrg@netbsd.org>.
1999-03-15 23:50:07 +00:00
itohy cfcb284c09 cachectl -> cachectl1 1999-03-02 18:22:29 +00:00
pk 523f9ad292 Don't try to translate the mount point, to avoid e.g. mounting
the /usr filesystem on /emul/aout/usr.
1999-02-28 18:46:13 +00:00
thorpej 0f7073ded3 If we match, and we're COMPAT_AOUT, use the a.out compat syscall switch,
not the "stock" one.
1999-02-20 23:25:55 +00:00
christos 3029ee19e3 Hmm, I forgot to add that.. 1999-02-15 08:48:20 +00:00
christos 5e44086190 Provide a way for compat programs to specify files in the normal tree.
We do this using a trick similar to mach's /../; if a path is given as
/..<absolute-path-name>, then we return <absolute-path-name>
1999-02-14 14:32:02 +00:00
lukem dcab0210a0 convert from NOxxx= to MKxxx=no.
include <bsd.own.mk> if testing a MKxxx variable.
1999-02-13 02:54:17 +00:00
christos 18f4839c63 Gen 1999-02-11 09:43:53 +00:00
christos 5cc7b4c557 A.out compatibility mode; basically /emul/aout/ checking for syscalls
that use pathnames.
1999-02-11 09:41:34 +00:00
itohy da0a919754 Regen. 1999-02-10 10:38:15 +00:00
itohy 5af2655c9d const mania 1999-02-10 10:36:26 +00:00
christos 03ff6653d6 Regen 1999-02-09 20:48:20 +00:00
christos 8087b4fda3 const poisoning and CHECK_ALT_CREAT fixes. 1999-02-09 20:46:41 +00:00
christos ec4586b831 Regen 1999-02-09 20:46:40 +00:00
christos dcee031682 const poisoning and CHECK_ALT_CREAT fixes. 1999-02-09 20:46:40 +00:00
christos c3ae7cb2a9 Regen 1999-02-09 20:38:38 +00:00
christos c8216580df const poisoning. 1999-02-09 20:37:19 +00:00
christos 8024779058 const poisoning 1999-02-09 20:37:00 +00:00
christos bcca34b4fa Regen. 1999-02-09 20:36:17 +00:00
christos 090a9bebbc const poisoning. 1999-02-09 20:34:16 +00:00
christos 908adf3eef Regen 1999-02-09 20:31:43 +00:00
christos a30a9f3d94 const poisoning and CHECK_ALT_CREAT fixes. 1999-02-09 20:30:38 +00:00
christos 49692434d8 Const poisoning and CHECK_ALT_CREAT fixes 1999-02-09 20:29:24 +00:00
christos f3be801e5c Regen 1999-02-09 20:26:55 +00:00