summaryrefslogtreecommitdiffstats
path: root/lib/libc/rpc/svc_tcp.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* Add support for timeconting in userland.pirofti2020-07-061-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | This diff exposes parts of clock_gettime(2) and gettimeofday(2) to userland via libc eliberating processes from the need for a context switch everytime they want to count the passage of time. If a timecounter clock can be exposed to userland than it needs to set its tc_user member to a non-zero value. Tested with one or multiple counters per architecture. The timing data is shared through a pointer found in the new ELF auxiliary vector AUX_openbsd_timekeep containing timehands information that is frequently updated by the kernel. Timing differences between the last kernel update and the current time are adjusted in userland by the tc_get_timecount() function inside the MD usertc.c file. This permits a much more responsive environment, quite visible in browsers, office programs and gaming (apparently one is are able to fly in Minecraft now). Tested by robert@, sthen@, naddy@, kmos@, phessler@, and many others! OK from at least kettenis@, cheloha@, naddy@, sthen@
* When system calls indicate an error they return -1, not some arbitraryderaadt2019-06-281-8/+9
| | | | | | value < 0. errno is only updated in this case. Change all (most?) callers of syscalls to follow this better, and let's see if this strictness helps us in the future.
* Simplify and unify timespec variables used in those event loopsjca2017-12-141-7/+6
| | | | ok millert@
* Use CLOCK_MONOTONIC for the rpc event loopsjca2017-12-141-13/+12
| | | | From Scott Cheloha, ok deraadt@ tb@
* delete old lint ARGSUSED commentsguenther2015-11-011-3/+1
|
* Wrap <rpc/*.h> so that calls go direct and the symbols are all weak.guenther2015-09-131-1/+2
| | | | | | Hide __xprt_register() and _authenticate(); truncate <rpc/svc_auth.h> ok deraadt@
* Remove all bogus writes to stderr. Only explicit requests shouldderaadt2015-09-011-7/+2
| | | | | go that way. ok miod beck
* Remove calls to perror(); the error returns are sufficient, and thesederaadt2015-09-011-5/+2
| | | | | library may not assume stderr is useable. ok millert miod beck
* Remove unnecessary netinet/in_systm.h include.lteo2014-10-251-2/+1
| | | | ok millert@
* Back out r1.17 and its subsequent conversion to poll. Otherwisemillert2013-04-151-27/+6
| | | | | | | we can get into a svc_getreq_poll() -> readtcp() -> svc_getreq_poll() loop until we run out of stack. If we want to avoid blocking on the new fd in readtcp() we need to poll() in svc_getreq_poll(), which will require a more elaborate change. OK tedu@
* handle ECONNABORTED errors from accept(). In many code blocks they can bederaadt2013-03-111-2/+3
| | | | | ignored silently and without aborting, much like EINTR and EWOULDBLOCK are. ok's from various maintainers of these directories...
* Oracle has re-licensed sunrpc under a three-clause BSD license.millert2010-09-011-29/+30
| | | | Update our sources appropriately. OK deraadt@ jsg@
* use calloc() to provide size * nitems safety; ok millertderaadt2009-06-051-3/+2
|
* sprinkle a socklen_tderaadt2006-04-021-2/+3
|
* Remove a few warnings. Those were not apparent thanks to a bug in gcc 2.95.espie2005-10-101-2/+1
| | | | | Patch by Leonardo Chiquitto Filho <leonardo@iken.com.br> Thanks.
* zap remaining rcsid.espie2005-08-081-4/+1
| | | | | | Kill old files that are no longer compiled. okay theo
* ansify. ok deraadt@ jaredy@otto2005-04-011-56/+35
|
* Bit of KNF - replace (<type> *)0 and (<type> *)NULL with NULL. Pointedkrw2005-01-081-6/+6
| | | | | | out by mickey@, seconded by millert@. ok deraadt@.
* Implement svc_getreq_poll(3) and friends and use poll(2) instead of select(2)millert2003-12-311-28/+28
| | | | | | | | | in the libc rpc code. The main difference between this and the previous version is the use of a simple free list that simplifies the logic when adding a socket to svc_pollfd. I've also added code to pack svc_pollfd when the free list gets too big. The idea general idea is to keep svc_pollfd as tightly packed as possible to make poll(2) efficient. Tested by many people and OK deraadt@
* use socklen_t where needed; henning pvalchev okderaadt2002-09-061-3/+3
|
* label abort() from inside library as ILLEGALderaadt2002-01-021-4/+4
|
* prototype cleanupderaadt2001-09-151-23/+23
|
* plug many memory leaksderaadt2001-03-031-3/+13
|
* make svctcp_recv kill sockets that fail in xdr_callmsg(); wpaulderaadt1998-05-221-1/+2
|
* make readtcp() call svc_getreqset2() for activity on other sockets; wpaulderaadt1998-05-221-17/+30
|
* incorrect timeout handlingderaadt1998-05-191-2/+2
|
* avoid close(closed_socket) or close(-1); it looks disgusting in kdumpderaadt1997-07-091-2/+4
|
* Don't do pointer arithmetic on void pointerstholo1997-04-301-2/+2
|
* if a bad socket is accept()ed, bail without trying another accept()deraadt1997-03-291-6/+11
| | | | in svctcp_create(), only close socket if we created it
* do not leak descriptors and memderaadt1997-02-171-7/+7
|
* if i find one more little problem, and have to make one more littlederaadt1997-02-131-2/+2
| | | | | | | | tweak to this ip option handling code I am going to absolutely scream in rage, following which I will rip the bloody innards out of netinet and build my own new incompatible option checking/processing interface that does not make it so hidiously difficult to check if a session has source routes active!
* option handling is a bitchderaadt1997-02-131-2/+3
|
* ok, i finally learned about struct ipoptionderaadt1997-02-131-6/+8
|
* destroy everything with source routesderaadt1997-02-071-1/+28
|
* memset 0; also fix for byte order botch in __svc_fdset handling; thanks to mw@openbsd.orgderaadt1996-08-201-3/+4
|
* Fix RCS idstholo1996-08-191-7/+2
| | | | Make sure everything uses {SYS,}LIBC_SCCS properly
* support descriptors > FD_SETSIZE and correct timeout handlingderaadt1996-08-151-13/+36
|
* if port 20 incoming, kill it and try againderaadt1996-08-051-2/+10
|
* bcopy->memcpy & tagderaadt1996-07-201-1/+2
|
* Pull prototypes into scopetholo1996-03-251-1/+2
| | | | Remove graticious casts
* initial import of NetBSD treederaadt1995-10-181-0/+415