Commit Graph

14487 Commits

Author SHA1 Message Date
pooka dda8526653 fix lp64 snafu (hopefully)
from pgoyette
2011-01-18 23:43:21 +00:00
pooka d36a58c27d hook librumphijack to the build 2011-01-18 20:09:37 +00:00
pooka 35dfb75868 comment out DBG and NOGCCERROR, use proper LIBDPLIBS form 2011-01-18 19:53:23 +00:00
pooka f6eee6f557 * attempt to match libc non-compat names (XXX: needs work)
* make shutdown() a dual-stack call
* flip the default to use host for PF_UNIX, since that's generally
  the desired case (because of X)
2011-01-18 19:41:02 +00:00
matt 2f86908fcf Use PRINTOBJDIR to get the object directory of libc and use that with -I. 2011-01-18 16:41:51 +00:00
pooka 2c78c39d6a pollts:
Since fds[] does not go to both kernels, set revents to 0 when
splitting the vector.  Now any stale revents passed by the caller
do not get counted as results for the kernel which did not "win"
the poll.

This fixes a situation where a firefox transfer would occasionally
stall.  Now firefox works full speed with a rump networking stack.
2011-01-18 16:00:04 +00:00
pooka 81ca4f22d1 use -D_REENTRANT (should currently have no effect, but better safe
than sorry if someone adds uses of stdio macros)
2011-01-18 15:00:22 +00:00
pooka 613ebae808 Don't count sparse elements in the poll vector for host fds. 2011-01-18 14:51:14 +00:00
pooka ac1dfbf509 Fix conversion: there are 1000*1000 nanoseconds in a millisecond, not 1000. 2011-01-18 14:45:30 +00:00
pooka 07d03119a0 Fix dup2 mask so that dup2'ing a rump kernel fd to 1 does not cause
stderr to be treated as a rump kernel fd as well.  Makes e.g.
bozohttpd work better with stderr logging.

Also, add aborty stubs for kqueue.
(implementing kqueue is even trickier than implementing select/poll
since we need to keep state for two kqueue fd's)
2011-01-18 11:04:10 +00:00
matt 57d93d8715 Cleanup the o32 compat build test. 2011-01-18 08:12:05 +00:00
matt dfe29b1db4 Change to deal with callframe changes 2011-01-18 01:23:24 +00:00
matt bd081d44b9 Make the MIPS N32/N64 ABIs properly support 128-bit long doubles. With this
change, we should be fully conformant with the N32 and N64 ABIs.
Add {fpclassify,infinity,isnan,ininf,signbit}l_ieee754.c back to lib/libc/gen.
Note that infinityl_ieee754.c will work with either 64-bit, 80-bit, or
128-bit long doubles.
2011-01-17 23:53:03 +00:00
matt 7d92b19968 Make __cerror hidden. 2011-01-17 23:34:44 +00:00
matt e4100763e4 cleanup format of #ifdef 2011-01-17 23:32:31 +00:00
agc f9dd05cc12 Hook libisns into the build, and modify the set lists accordingly.
Note the addition of iSNS protocol support in doc/CHANGES

With thanks to Wasabi Systems for contributing the code.
2011-01-17 20:39:03 +00:00
pooka d8244e0b17 Use host_close() instead of close() where we know it to be the
right interface.
2011-01-17 16:30:09 +00:00
pooka 6054dbc060 Adapt to rump syscall changes. The correct rump compat syscall is
now automatically picked based on the ABI of the target the library
is compiled for.

(the host libc symbolname to override still needs a little attention
based on the system version)
2011-01-17 16:27:54 +00:00
matt 50078c4d66 Add long double functions for eq,ne,gt,le,ge,lt,neg ops. 2011-01-17 10:08:35 +00:00
matt cbf89944a0 Add -D_REENTRANT 2011-01-17 09:43:56 +00:00
matt 51db1c5cf3 Kill _NOREGNAMES. Everything should be using %rX now. If it doesn't it
soon will.
2011-01-17 08:23:53 +00:00
wiz 83a6212df8 Typo fixes, use more markup. 2011-01-16 08:00:01 +00:00
matt 2dd1b647a7 For cerror, allow -I../libc to allow inclusion of any assym.h, if up. 2011-01-16 03:29:36 +00:00
christos 7350622ee8 off by one in fetching history data. From: Gerry Swislow 2011-01-16 03:05:51 +00:00
matt 36cd488617 align comments 2011-01-16 02:45:48 +00:00
matt b79441d450 Switch to the PIC_GOTSETUP/PIC_TOCSETUP macros for PIC code. Now libc
will be built to use secureplt by default.
2011-01-16 02:43:10 +00:00
agc dc2ecebec9 Initial import of libisns, contributed to the NetBSD Foundation by
Wasabi Systems, Inc.

libisns(3) is an implementation of the iSNS protocol as defined in
IETF RFC 4171, exporting an API that simplifies Internet Storage Name
Service (iSNS) client implementations.
2011-01-16 01:22:50 +00:00
christos b163cf8017 Fix reversed oveflow check. 2011-01-15 15:42:10 +00:00
martin cca650856d Backout previous, it breaks the build big time and causes e.g. date(1)
and top(1) to dump core.
2011-01-15 12:31:56 +00:00
plunky f14c3542ea add sdp_put_[u]int64() .Fn prototypes to list 2011-01-15 11:51:25 +00:00
matt cf88c3890b Use END(foo) everywhere.
Make __cerror hidden.
Use non-PLT calls to __cerror.
Use assym.h when appropriate.
Use addi to adjust stack instead of loading it.
Add __RCSIDs
Force -D_NOREGNAMES for all .S files.
[this is all in preperation for secure plt support]
2011-01-15 07:31:11 +00:00
christos dd5b7b1566 don't depend on integer oveflow wrapping to detect it. From Paul Eggert in
the tz mailing list.
2011-01-14 23:35:07 +00:00
pooka 9fba158b8b Add RUMPSP_RAISE: the kernel sends a signal to the client. 2011-01-14 13:12:14 +00:00
jruoho b19fbfbfda Xref strsuftoll(3) and orders(7). 2011-01-14 10:08:57 +00:00
matt 958d64ed82 Generate symbol constants for UC_GREGS_* and CALLFRAME*. 2011-01-14 06:15:27 +00:00
matt 2c2c9e807e Change __cerror to be marked hidden and change callers to avoid the PLT. 2011-01-14 06:12:16 +00:00
matt 314296c406 Let libposix and librt have their own version of __cerror (__posix_cerror and
__rt_cerror).  This enables each library (including libc) the oppurtunity to
make its __cerror hidden and avoid being called via the PLT.  No user visible
differences to no need to bump the minor number.
2011-01-14 05:19:59 +00:00
joerg d3a052c472 Allow use of traditional CPP to be set on a per platform base in sys.mk.
Honour this for dependency processing in bsd.dep.mk.  Switch i386 and
amd64 assembly to use ISO C90 preprocessor concat and drop the
-traditional-cpp on this platform.
2011-01-12 23:12:10 +00:00
joerg 0e4ac962b5 Remove NOMANDOC, the documents are at least parsed somewhat sensible. 2011-01-12 23:03:55 +00:00
pooka 3626eb4b01 call procexit when a connection closes 2011-01-12 12:52:16 +00:00
yamt 79d46db770 typo in a comment 2011-01-10 23:20:45 +00:00
pooka 5064fa59e6 A bunch of improvements:
* don't hold spc mutex while sending data
* use send() for the banner to avoid SIGPIPE in case a client
  connects and immediately goes away
* fix error path locking
* use kevent() instead of pollts() in the client.  Apparently that
  is the only sensible way for a library to support both multithreading
  and signal-reentrancy in a race-free manner.
  (can I catch all signals with one kevent instead of installing
  NSIG different ones??)
* mark client comm descriptor non-blocking so that clients have
  better signal-interruptibility (we now sleep in signal-accepting
  kevent() instead of signal-masked recvfrom())
2011-01-10 19:49:43 +00:00
christos 880fe46bea remove clauses 3/4 2011-01-10 16:42:36 +00:00
pooka 52fffe2163 g/c code which is unused in the server 2011-01-10 11:57:53 +00:00
wiz e348791317 Sort errors, fix xref, don't xref itself. 2011-01-10 06:26:30 +00:00
christos c5aa3a8776 add sigqueue 2011-01-10 04:41:27 +00:00
pooka 81131c3a38 Networked X11 clients have the annoying property that they need to
contact the X server.  Since most of the useful cases these days
are local, add a toggle which forwards PF_LOCAL sockets to the host
and all other protocol families to the rump kernel.

This makes an unmodified firefox work with a rump TCP/IP stack.
I'm sure someone will find applications for being able to run
multiple web browser profiles on one OS with each browser having
a different IP address in the same subnet ...
2011-01-09 19:56:33 +00:00
pooka 2ec0087d6f Don't depend on malloc(0) returning non-NULL. 2011-01-09 14:15:06 +00:00
pooka 55d21df89f Separate rw_data and rw_done. Otherwise we don't get wakeups for
requests which have a 0-length response (such as copyin 0/0).

This change makes links(1) work against a rump kernel which contains
rumpnet_local.  The presence of unix domain sockets caused links
to select() with 0 fds and a timeout, and because copyin never woke
up in the kernel the application blocked indefinitely.
2011-01-09 14:10:03 +00:00
pooka bfa098ff96 dprintf to stderr. stop doing it if stderr_fileno gets dup2()'d 2011-01-09 10:28:46 +00:00