summaryrefslogtreecommitdiffstats
path: root/sys/compat/linux/linux_socket.c (follow)
Commit message (Collapse)AuthorAgeFilesLines
* remove the Linux emulation code, no longer referenced by anythingnaddy2016-03-021-1511/+0
|
* Pass a thread pointer instead of its file descriptor table to getsock(9).mpi2015-05-061-2/+2
| | | | | | Diff from Vitaliy Makkoveev. Manpage tweak and ok millert@
* Fix mbuf leak in Linux compat setsockopt() in the error path whenmillert2015-01-301-4/+5
| | | | optval is not valid. Found by Maxime Villard. OK bluhm@
* Ubreak the tree by using "struct ifreq" instead of "struct linux_ifreq".mpi2015-01-211-2/+2
|
* Delete option COMPAT_43: support for pre-sa_len binaries has been obsoleteguenther2015-01-211-8/+22
| | | | | | | | for a couple decades. Keep the OSIOCGIFCONF ioctl to support COMPAT_LINUX but move the rest of the Linux-specific ioctl() handling into linux_socket.c This lets struct osockaddr finally move from sys/socket.h to protocols/talkd.h ok krw@ deraadt@ mpi@
* Prefer linux_sockaddr over osockaddr, so the latter can go away.guenther2015-01-191-183/+58
| | | | | | | | | | | sys_socket() supports SOCK_{CLOEXEC,NONBLOCK} now, so build on that. doaccept() supports the non-inheriting-of-O_NONBLOCK, so build on that. Merge compat_sys_{accept,send,recv}() into their only callers. Lie a little and use struct sockaddr in the linux socket syscall args when it's a return argument to avoid a bunch a casts. Delete many other unnecessary sockaddr casts verified with a curl Linux binary
* Explicitly include <net/if_var.h> instead of pulling it in <net/if.h>.mpi2014-12-051-1/+2
| | | | ok mikeb@, krw@, bluhm@, tedu@
* Remove unnecessary netinet/in_systm.h include.lteo2014-10-251-2/+1
| | | | | | | Compiles on i386, which is the only architecture where COMPAT_LINUX is enabled at the moment. "If it compiles, go ahead" pirofti@
* Avoid possible use of uninitialized variable.mlarkin2014-09-101-2/+2
| | | | | | From Maxime Villard via a post to tech@ a long time ago ok guenther@, doug@
* add a size argument to free. will be used soon, but for now default to 0.tedu2014-07-121-2/+2
| | | | after discussions with beck deraadt kettenis.
* Retire kernel support for SO_DONTROUTE, this time without breakingmpi2014-04-071-3/+1
| | | | | | | | | | | localhost connections. The plan is to always use the routing table for addresses and routes resolutions, so there is no future for an option that wants to bypass it. This option has never been implemented for IPv6 anyway, so let's just remove the IPv4 bits that you weren't aware of. Tested a least by lteo@, guenther@ and chrisz@, ok mikeb@, benno@
* revert "Retire kernel support for SO_DONTROUTE" diff, which does bad thingssthen2014-03-281-1/+3
| | | | for localhost connections. discussed with deraadt@
* Retire kernel support for SO_DONTROUTE, since the plan is to alwaysmpi2014-03-271-3/+1
| | | | | | | | use the routing table there's no future for an option that wants to bypass it. This option has never been implemented for IPv6 anyway, so let's just remove the IPv4 bits that you weren't aware of. Tested by florian@, man pages inputs from jmc@, ok benno@
* Move p_emul and p_sigcode from proc to process.guenther2014-03-261-5/+5
| | | | | | | | | Tweak the handling of ktrace EMUL when changing ktracing: only generate one per process (not one per thread) and pass the correct proc pointer down to the VFS layer. Permit generating of NAMI and CSW records inside ktrace(2) itself. ok deraadt@ millert@
* Instead of iterating over the per-interface list of addresses tompi2014-02-131-12/+9
| | | | | | | find the link-layer address of an interface, use the pointer to the sockaddr_dl already present in the interface's descriptor. Tested for regression by pirofti@ with opera.
* adjust a comment or twotedu2014-01-231-8/+8
|
* Don't ignore SOCK_CLOEXEC and SOCK_NONBLOCK.pirofti2012-06-261-3/+36
| | | | | | | CAVEATS: Assumes that a new socket can't have any of the FCNTLFLAGS set on it, which _is_ true, currently... (guenther@) Okay guenther@, deraadt@.
* Add socket type mask to filter out implementation specific flags.pirofti2012-06-191-2/+2
| | | | | | | | | | | The newer glibc's, when creating a socket, add some higher bit flags to the type argument that are used for debug, statistics, profiling whatever. They are not useful and implementation specific. This is needed for DNS resolving, otherwise the nss library from glibc will always fail to do the right thing. Okay jasper@
* Add struct proc * argument to FRELE() and FILE_SET_MATURE() inguenther2012-04-221-3/+3
| | | | | | anticipation of further changes to closef(). No binary change. ok krw@ miod@ deraadt@
* add support for MSG_NOSIGNAL.fgsch2011-12-031-7/+32
| | | | linux bits compiled on i386 by sebastia@, mikeb@ ok
* Fix Unix socket handling when the length is too large by trimming.pirofti2011-09-191-2/+6
| | | | Okay claudio@
* begone, fucking rotten appletalk shit. ok roomhenning2011-07-091-2/+2
|
* remove all the old COMPAT_43 syscalls. The option itself remains fortedu2011-07-071-8/+92
| | | | | | the other things it enables. Move a few old wrappers into linux compat where they are still being used. ok deraadt guenther
* Fix various cases of stackgap_alloc() size arguments not being computedmiod2009-09-051-2/+2
| | | | | correctly, usually yielding the right value on 32 bit machines because sizeof int == sizeof pointer.
* sys/types.h or sys/param.h MUST BE FIRSTderaadt2009-02-191-2/+2
|
* Allow linux binaries to call setsockopt(,TCPNODELAY,) on a AF_LOCALmatthieu2008-06-101-16/+44
| | | | socket, since some of them do that. ok deraadt@, henning@.
* put IPX in the unsupported boathenning2007-06-061-2/+2
|
* Use more queue macros rather than doing it by hand; ok otto@ krw@miod2006-03-051-5/+3
|
* Move contents of sys/select.h to sys/selinfo.h in preparation for amillert2005-11-211-2/+2
| | | | | userland-visible sys/select.h. Consistent with what Net and Free do. OK deraadt@, tested with full ports build by naddy@.
* remove CCITT handlinghenning2005-06-071-4/+4
|
* we don't care about copyout's success. add a comment to appease sturm@tedu2004-07-081-1/+2
|
* Make SIOCGIFHWADDR work. ok mickey@nordin2003-11-251-2/+3
|
* after sys_sendmsg, change control message level back in case somebody lookstedu2003-07-241-3/+15
| | | | | at it. we don't use stackgap because control messages can be larger than the gap, and it's just easier this way. ok deraadt@
* Do not do multiple stackgap_init calls in the same syscall execution,niklas2003-01-211-23/+20
| | | | | | | chances are big that entities allocated early should live longer than later stackgap_init invocations. This fixes UDP problems in Linux emulation, most notably YP, and some DNS issues. ok fgsch@, jasoni@ & pvalchev@
* pass p->p_emul to stackgap_init(), not 0 to be consistent.fgsch2002-12-101-5/+5
|
* fix setsockopt SO_REUSEADDR under linux emul; from NetBSD.fgsch2002-12-101-2/+9
| | | | thanks to jpmp@fibertel.com.ar for the testbed. ish@ ok
* do address translation for for socket syscalls that pass addresses inish2002-11-271-42/+323
| | | | | | or out - this allows linux programs that use IPv6 to work (not ipv4 mapped addresses though) - from NetBSD
* Correct the size arg to copyout.aaron2002-08-091-2/+2
|
* socket flags are not inherited via accept() on linux; found and testedfgsch2002-08-091-2/+17
| | | | by gustavo, several ppl ok@
* First round of __P removal in sysmillert2002-03-141-29/+29
|
* FREF/FRELE where required due to fd_getfile.jasoni2002-02-131-5/+9
| | | | - ok art@
* emulate linux behaviour by passing ioctl's down to the underlying devicejasoni2002-02-061-4/+48
| | | | > From NetBSD; ok art@
* translate LINUX_AF_INET6 (10) into AF_INET6.itojun2001-06-211-1/+3
|
* style/cleanup (of function headers)jasoni2001-05-241-100/+108
|
* OpenBSD -> NetBSD where previously missed.jasoni2000-07-231-6/+6
|
* more ioctl supportderaadt1999-02-101-1/+21
|
* IP_HDRINCL support, will need tweaking; freebsdderaadt1999-02-101-1/+201
|
* no; linux connect() appears busted in blocking mode tooderaadt1998-07-191-1/+5
|
* oops; mwp@aba.net.auderaadt1998-07-131-2/+2
|
* Aparently the socketpair bug is fixed in current Linux kernels somillert1998-04-251-9/+1
| | | | back out my last change.