aboutsummaryrefslogtreecommitdiff
path: root/pfinet/linux-src
Commit message (Collapse)AuthorAgeFilesLines
* pfinet: Also accept MSG_NOSIGNAL in udpv6_sendmsgSamuel Thibault2023-08-311-1/+1
| | | | The implementation is shared with IPv4
* pfinet: Fix x86_64 prototypesSamuel Thibault2023-06-111-2/+2
|
* pfinet: Add x86_64 checksum supportSamuel Thibault2023-05-292-0/+278
|
* Modernize code by removing use of old style definitions.Flavio Cruz2023-04-032-3/+3
| | | | | Also add -Werror=old-style-definition to enforce new code. Message-Id: <ZBZ+8xf7GHy2RT/h@jupiter.tail36e24.ts.net>
* pfinet: Fix shifting left into bit 31Samuel Thibault2023-02-233-5/+5
|
* pfinet: Align packetsSamuel Thibault2023-02-191-0/+24
| | | | | | The Ethernet header is 14 bytes long, and thus leads to IP header misalignment. This uses skb_reserve to introduce 2 bytes of padding to realign IP headers.
* Remove duplicate pfinet linux headers that have glue versionsFlavio Cruz2022-11-0633-5044/+0
| | | | Message-Id: <Y2NNAegVOKg/X7OC@viriathus>
* Use route.h from glibcSamuel Thibault2022-09-211-0/+3
| | | | | | Unfortunately the Linux source also uses <net/route.h>, so we have to both make that include the glibc-provided one, and avoid making it emit Linuxish definitions when they would conflict with glibc definitions.
* Add new RPC for pfinet network routesDamien Zammit2022-09-112-0/+82
| | | | Message-Id: <20220909094234.517165-1-damien@zamaudio.com>
* pfinet: Increase default max buffer size to 256k, like on LinuxSamuel Thibault2022-08-131-2/+2
|
* pfinet: Avoid returning udp errors unless requestedSamuel Thibault2017-09-261-21/+6
| | | | | | | This comes from Linux 2.3.40 to 2.3.41 changes, to fix its behavior according to common practice. Unconnected udp sockets notably should not report errors, since the application doesn't have a way to relate it with previous sends.
* pfinet: select UDP/TCP ports randomlySamuel Thibault2017-09-106-21/+10
| | | | | | | | | | | | | | * pfinet/linux-src/include/net/tcp.h (tcp_port_rover): Remove declaration * pfinet/linux-src/include/net/udp.h (udp_port_rover): Likewise. * pfinet/linux-src/net/ipv4/tcp_ipv4.c (tcp_port_rover): Remove variable. (tcp_v4_get_port): Take port hint from net_random() instead of tcp_port_rover. * pfinet/linux-src/net/ipv4/udp.c (udp_port_rover, udp_v4_get_port): Likewise. * pfinet/linux-src/net/ipv6/tcp_ipv6.c (tcp_v6_get_port): Likewise. * pfinet/linux-src/net/ipv6/udp_ipv6.c (udp_v6_get_port): Likewise.
* Fix supporting >4GiB files in ext2fsSamuel Thibault2016-04-261-1/+0
| | | | | | | | | | * ext2fs/inode.c (diskfs_user_read_node): When sizeof(off_t) >= 8, add di->i_size_high as high-64bit part to st->st_size. Drop setting unused info->i_high_size. (write_node): When sizeof(off_t) >= 8, write high-64bit part of st->st_size to di->i_size_high. * ext2fs/ext2_fs_i.h (ext2_inode_info): Remove i_high_size field. * pfinet/linux-src/include/linux/ext2_fs_i.h (ext2_inode_info): Likewise.
* Fix gcc signedness warningsSamuel Thibault2016-01-141-1/+1
| | | | | * pfinet/linux-src/include/linux/skbuff.h (__skb_pull): Return unsigned char * instead of char *.
* allow pfinet to link using -O0Flavio Cruz2016-01-0241-246/+229
| | | | | This fixes a long list of undefined references when compiling with -O0 by using static instead of extern in header files.
* Allow dhcp trafic and configurationSamuel Thibault2015-02-021-0/+2
| | | | | | | | | | | | | | | | | | | | | | | | | 2007-10-14 Christian Dietrich <stettberger@dokucode.de> * options.c (options): Marked -a, -g -m, -p, -A, -G OPTION_ARG_OPTIONAL. (parse_interface_copy_device): New function. (parse_opt): When selecting another interface with -i set the options from e.g. a prior fsysopts call as default values. For -a, -g, -p, -g, -A, -G set the optional argument as value. When there is no argument, delete the value (e.g. unset default gateway). Delete delete default gateways only if the set gateway is on an interface modified in this call. Add always an route for dhcp packages on all devices. By doing this we can send dhcp renew packages. (trivfs_append_args): Add --gateway only once. 2007-10-14 Marco Gerards <metgerards@student.han.nl> * options.c (parse_opt): Add the route for `0.0.0.0' so broadcasting works. * linux-src/net/ipv4/devinet.c (inet_insert_ifa) [_HURD_]: Don't fail when the address is `0.0.0.0'.
* Backport Linux changes for proper TCP EOF handlingSamuel Thibault2015-01-033-32/+31
| | | | | | | | | | | | | Notably when remote eagerly sends a RST: we want to return EOF to the application, not EPIPE. * pfinet/linux-src/net/ipv4/tcp_output.c (tcp_connect): Set sk->done to 0. * pfinet/linux-src/net/ipv4/tcp_input.c (tcp_fin): Set RCV_SHUTDOWN, and sk->done to 1. * pfinet/linux-src/net/ipv4/tcp.c (tcp_recv_urg): Only return ENOTCONN when we never actually connect. Always return 0 when reception is closed. (tcp_recvmsg): When any data is available, ignore errors and EOF. When no data is available, first check for reception being closed, then for errors.
* BSD apps want sin_zero cleared in sys_getname.Alexey Kuznetsov2014-09-281-0/+1
| | | | | | | Cherry-picked from Linux c1e9dcb37795b08a1f50b8de7b2ad5efcb15728f * pfinet/linux-src/net/ipv4/af_inet.c (inet_getname): Clear `sin_zero' part of `sin'.
* Avoid compiler warning about empty bodiesJustus Winter2014-05-261-1/+1
| | | | | | | | | | | | | Make empty bodies of control flow statements more explicit. Doing so will allow us to use stricter compiler settings. This would have cought 4ece292c. * console-client/xkb/xkb.c: Make empty bodies more explicit * libpipe/pipe.c: Likewise. * mach-defpager/default_pager.c: Likewise. * pfinet/linux-src/net/ipv4/fib_hash.c: Likewise. * pflocal/connq.c: Likewise. * pflocal/socket.c: Likewise.
* pfinet: add missing includeJustus Winter2014-05-261-0/+2
| | | | * pfinet/linux-src/include/net/addrconf.h: Include ipv6.h.
* Normalize whitespace at the end of each file to '\n'Justus Winter2013-11-0959-84/+2
| | | | | Some files were not normalized. In console/motd.UTF8 the additional newline is intentional. Empty files were excluded as well.
* pfinet: Fix call to kfree_sSamuel Thibault2013-07-201-1/+1
| | | | | | | | | | | | | | kfree_s expects a pointer and a size argument. Currently the sizeof(cache) is used as size argument, this is certainly not what was intented. For reference, this code was present in Linux up to version 2.3.14 and was replaced in 2.3.15. Found using coccinelle and https://raw.github.com/coccinelle/coccinellery/master/sz/sz.cocci. * pfinet/linux-src/net/ipv4/ipmr.c (ipmr_cache_delete): Fix kfree_s call.
* Fix tunnel and dummy interfacesSamuel Thibault2013-03-262-2/+4
| | | | | | | | | | | * pfinet/linux-src/include/linux/netdevice.h (netdevice): Add `change_flags' field. * pfinet/ethernet.c (ethernet_change_flags): Make function static. (setup_ethernet_device): Set `change_flags' field of `dev' to ethernet_change_flags. * pfinet/linux-src/net/core/dev.c (dev_change_flags): Call `change_flags' field of `dev' if non-nul, instead of calling ethernet_change_flags. * pfinet/pfinet.h (ethernet_change_flags): Remove function prototype.
* Always set flags on ethernet interfaceSamuel Thibault2013-02-241-0/+3
| | | | | | | * pfinet/linux-src/net/core/dev.c (dev_change_flags): Call ethernet_change_flags. * pfinet/iioctl-ops.c (S_iioctl_siocsifflags): Do not call ethernet_change_flags after calling dev_change_flags.
* [IPV6]: Add IPV6_V6ONLY socket option support.Samuel Thibault2013-01-1311-34/+162
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Cherry-picked from Linux 524354b4d086a4f013343d727eaccb7b4c39eb25 * pfinet/glue-include/linux/ipv6.h: Include linux/config.h> (__ipv6_only_sock, ipv6_only_sock): New macros * pfinet/linux-src/include/linux/ipv6.h: Likewise. * pfinet/linux-src/include/linux/in6.h (IPV6_V6ONLY): New macro. * pfinet/linux-src/include/linux/sysctl.h (NET_IPV6_BINDV6ONLY): New macro. * pfinet/linux-src/include/net/ipv6.h (sysctl_ipv6_bindv6only): Declare variable. * pfinet/linux-src/include/net/sock.h (ipv6_pinfo): Add ipv6only field. * pfinet/linux-src/net/ipv4/tcp_ipv4.c: Include linux/ipv6.h. (tcp_v4_get_port, tcp_v4_lookup_listener): Test for ipv6_only_sock. * pfinet/linux-src/net/ipv4/udp.c: Include linux/ipv6.h. (udp_v4_get_port, udp_v4_lookup_longway, udp_v4_mcast_next): Test for ipv6_only_sock. * pfinet/linux-src/net/ipv6/af_inet6.c (sysctl_ipv6_bindv6only): New variable. (inet6_create): Initialize ipv6only field to sysctl_ipv6_bindv6only. * pfinet/linux-src/net/ipv6/ipv6_sockglue.c (ipv6_setsockopt): Test for ipv6_only_sock. (ipv6_setsockopt, ipv6_getsockopt): Support IPV6_V6ONLY case. * pfinet/linux-src/net/ipv6/tcp_ipv6.c (ipv6_rcv_saddr_equal): New inline function. (tcp_v6_get_port): Replace old tests with ipv6_rcv_saddr_equal. (tcp_v6_connect): Test for __ipv6_only_sock. * pfinet/linux-src/net/ipv6/udp_ipv6.c (udv6_rcv_saddr_equal): New inline function. (udp_v6_get_port): Replace old tests with udv6_rcv_saddr_equal. (udpv6_connect, udpv6_sendmsg): Test for __ipv6_only_sock.
* pfinet: increase local port rangeRichard Braun2012-12-061-0/+4
| | | | | * pfinet/linux-src/net/ipv4/tcp_ipv4.c (sysctl_local_port_range): Set port range to 32768-61000.
* Add missing format strings for error, printk, problemPino Toscano2011-10-191-2/+2
| | | | | | | | | | | | | | | | | | | Some calls to `error', `printk', and `problem' lacked a format string, leading to build failure when compiling with stricter CFLAGS. * nfs/mount.c (mount_root): Add format string for `error' calls which lacked it. * pfinet/main.c (pfinet_bind): Likewise. * term/main.c (main): Likewise. * utils/shd.c (run): Likewise. * utils/storeinfo.c (main): Likewise. * pfinet/linux-src/include/net/tcp.h (tcp_clear_xmit_timer): Add format string for `printk' call which lacked it. (tcp_timer_is_set): Likewise. * ufs-fsck/utilities.c (punt): Add format string for `problem' call which lacked it.
* fix common misspellingsJonathan Neuschäfer2011-08-2047-64/+64
| | | | | | * Fix spelling with codespell[1] and manually review it. [1] http://git.profusion.mobi/cgit.cgi/lucas/codespell/
* pfinet/linux-src: fix a memory leakJonathan Neuschäfer2011-08-201-3/+6
| | | | | * pfinet/linux-src/net/ipv4/ip_options.c (ip_options_get): calculate the size of opt only once, free opt before returning -EFAULT.
* Fix NULL dereferenceSamuel Thibault2010-12-251-1/+1
| | | | | * pfinet/linux-src/net/ipv6/ip6_fib.c (fib6_locate): Do not dereference fn when it is NULL.
* Fix connect(AF_UNSPEC)Samuel Thibault2010-10-301-0/+8
| | | | | | | | | | Fixes sshd startup on inet6-enabled systems. * pfinet/socket-ops.c (S_socket_create_address): Accept creating AF_UNSPEC addresses too. * pfinet/linux-src/net/ipv6/udp_ipv6.c (udpv6_connect): When address family is AF_UNSPEC, call udp_connect() and clear daddr, saddr, and rcv_saddr.
* Fix ipv6 pfinet buildSamuel Thibault2010-10-291-1/+1
| | | | | * pfinet/linux-src/net/ipv6/raw_ipv6.c (rawv6_init_sk): Replace yet-undefined raw6_sk with proper translation.
* ipv6 raw fixesAlexey Kuznetsov2010-10-291-2/+21
| | | | | | | | | | | | | - RFC2292 bis compliance: enable checksumming of ICMPv6 raw sockets by default, reject odd offsets - calculate checksum correctly when user forgets to uninitialize checksum word * net/ipv6/raw_ipv6.c (rawv6_frag_cksum): Fix offset check. Compensate for any user-provided checksum. (rawv6_setsockopt): Reject odd checkum offsets with EINVAL. (rawv6_init_sk): Enable kernel-computed checksum by default for IPPROTO_ICMPV6 sockets.
* Add memory clobbers to assembly snippetsSamuel Thibault2009-09-261-2/+4
| | | | | | * pfinet/linux-src/include/asm-i386/checksum.h (ip_fast_csum): Add memory clobber to assembly snippet. (csum_ipv6_magic): Likewise.
* Fix assignment from incompatible pointer typeSamuel Thibault2009-09-221-1/+1
| | | | | * pfinet/linux-src/net/ipv4/tcp_ipv4.c (tcp_v4_connect): xchg &rt->u.dst instead of just rt with sk->dst_cache.
* 2009-02-24 Samuel Thibault <samuel.thibault@ens-lyon.org>Samuel Thibault2009-02-242-19/+19
| | | | | | | * linux-src/net/ipv6/addrconf.c (ipv6_addr_type): Use __in6_u.__u6_addr32 member instead of in6_u.u6_addr32. * linux-src/net/ipv6/icmpv6.c (icmpv6_rcv): Use __in6_u.__u6_addr16 member instead of in6_u.u6_addr16.
* 2007-10-14 Stefan Siegl <stesie@brokenpipe.de>Stefan Siegl2007-10-141-1/+2
| | | | | | | | | | | * options.c (ipv6_get_dflt_router) [CONFIG_IPV6]: New function. (parse_opt) [CONFIG_IPV6]: Don't delete IPv6 interface address, if it would be re-added immediately, but delete if otherwise. Do not touch inet6_ifaddr after inet6_addr_del was called. Don't purge and re-add IPv6 default router unless necessary. (trivfs_append_args) [CONFIG_IPV6]: Use ipv6_get_dflt_router. * linux-src/net/ipv6/addrconf.c (ipv6_del_addr): Call del_timer on ifp->timer.
* 2007-10-13 Stefan Siegl <stesie@brokenpipe.de>Stefan Siegl2007-10-135-5/+114
| | | | | | | | | | | | | | | | | | | | * linux-src/net/ipv6/af_inet6.c (inet6_getname): Initialize sin6_scope_id. * linux-src/net/ipv6/datagram_ipv6.c (ipv6_recv_error): Likewise. * linux-src/net/ipv6/tcp_ipv6.c (v6_addr2sockaddr): Likewise. * linux-src/net/ipv6/udp_ipv6.c (udpv6_recvmsg): Likewise. * linux-src/net/ipv6/raw_ipv6.c (rawv6_recvmsg): Likewise. * linux-src/net/ipv6/af_inet6.c (inet6_bind): For link-local IPv6 addresses copy sin6_scope_id to bound_dev_if and error out unless bound. * linux-src/net/ipv6/tcp_ipv6.c (tcp_v6_connect): Likewise. * linux-src/net/ipv6/udp_ipv6.c (udpv6_connect): Likewise. * linux-src/net/ipv6/raw_ipv6.c (rawv6_bind): Likewise. * linux-src/net/ipv6/raw_ipv6.c (rawv6_sendmsg): For link-local IPv6 addresses bind packet to interface specified by sin6_scope_id. * linux-src/net/ipv6/udp_ipv6.c (udpv6_sendmsg): Likewise.
* 2007-10-08 Stefan Siegl <stesie@brokenpipe.de>Stefan Siegl2007-10-0810-13/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | * config.h (CONFIG_IPV6, CONFIG_IPV6_EUI64): New defines, set to 1. * Makefile (ipv6-srcs): New variable. (LINUXSRCS): Add ipv6-srcs. * ethernet.c (ethernet_demuxer): Call skb_put instead of changing skb->len directly, and thus now update skb->tail accordingly. * pfinet.h (PORTCLASS_INET, PORTCLASS_INET6): New enums. (trivfs_protid_portclasses, trivfs_protid_nportclasses) (trivfs_cntl_portclasses, trivfs_cntl_nportclasses): Declare these. (pfinet_bootstrap_portclass): New variable. (pfinet_bind): New function. * main.c: Define _HACK_ERRNO_H. Include <errno.h>. (trivfs_protid_portclasses, trivfs_cntl_portclasses): New slots for PORTCLASS_INET6. (trivfs_protid_nportclasses, trivfs_cntl_nportclasses): Set to 2. (pfinet_bootstrap_portclass): New variable. (pfinet_bind): New function. (pfinet_activate_ipv6) [CONFIG_IPV6]: New function. (main) [CONFIG_IPV6]: Call inet6_proto_init. (main): Reordered to allow pfinet to not be started as a translator, if pfinet_bind is used. If started as a translator, treat pfinet_bootstrap_portclass when calling trivfs_startup. * options.c: Include <net/sock.h>, <net/ip6_fib.h>, <net/ip6_route.h> and <net/addrconf.h>. (options): New option `ipv4'. (options) [CONFIG_IPV6]: New options `ipv6', `address6' and `gateway6'. (parse_interface) [CONFIG_IPV6]: Add address6 and gateway6. (parse_hook_add_interface) [CONFIG_IPV6]: Initialize address6 and gateway6. (parse_opt): Parse new args. * socket-ops.c (S_socket_create): Call either net_families[PF_INET]->create or net_families[PF_INET6]->create, depending on receiving master. (S_socket_create_address): Allow creation of AF_INET6 addresses. * glue-include/asm/delay.h: New stub file. * glue-include/linux/ipv6.h: Merged many bits unmodified from Linux header file. * glue-include/linux/in6.h: Likewise. (ipv6mr_ifindex): New define, glue to ipv6mr_interface. * glue-include/linux/socket.h (SOL_IPV6, SOL_ICMPV6): New defines. * linux-src/net/ipv6/addrconf.c (ipv6_find_idev, inet6_addr_add) (inet6_addr_del) [_HURD_]: Make these non-static. (addrconf_set_dstaddr, addrconf_add_ifaddr, addrconf_del_ifaddr) [_HURD_]: Don't define these functions. * linux-src/net/ipv6/route_ipv6.c (ipv6_route_ioctl) [_HURD_]: Likewise. * linux-src/net/ipv6/af_inet6.c (inet6_ioctl) [_HURD_]: Don't define the function, instead #define it to 0. (inet6_proto_init) [_HURD_]: Don't call sit_init. * linux-src/net/ipv6/udp_ipv6.c (udp_ioctl) [_HURD_]: Define to 0. (udp_v6_get_port): Put empty statement after label to silence compiler. * linux-src/net/ipv6/tcp_ipv6.c (tcp_v6_get_port, tcp_v6_rcv): Likewise. * linux-src/net/ipv6/icmpv6.c (icmpv6_rcv): Likewise. (icmpv6_init) [_HURD_]: Don't initialize i_uid and i_gid. * linux-src/net/ipv6/mcast.c (igmp6_init): Likewise. * linux-src/net/ipv6/ndisc.c (ndisc_init): Likewise. * linux-src/net/ipv6/ip6_fib.c (BUG_TRAP): Don't use __FUNCTION__ as a string but a variable, to keep gcc happy. (fib6_walker_list): Make it non-static, to keep gcc happy. * linux-src/net/ipv6/ip6_flowlabel.c (fl_create) [_HURD_]: Drop IPV6_FL_S_USER support, since current->euid is not available.
* 2007-10-08 Stefan Siegl <stesie@brokenpipe.de>Stefan Siegl2007-10-0818-0/+15512
| | | | | | | | | | | | | | | | | | | | | | | | Import a number of files from Linux 2.2.14. Renamed some of them, to have unique filenames as required by the make system. * linux-src/net/ipv6/addrconf.c: Import file. * linux-src/net/ipv6/af_inet6.c: Likewise. * linux-src/net/ipv6/exthdrs.c: Likewise. * linux-src/net/ipv6/ip6_fib.c: Likewise. * linux-src/net/ipv6/ip6_flowlabel.c: Likewise. * linux-src/net/ipv6/ip6_input.c: Likewise. * linux-src/net/ipv6/ip6_output.c: Likewise. * linux-src/net/ipv6/ipv6_sockglue.c: Likewise. * linux-src/net/ipv6/mcast.c: Likewise. * linux-src/net/ipv6/ndisc.c: Likewise. * linux-src/net/ipv6/reassembly.c: Likewise. * linux-src/net/ipv6/tcp_ipv6.c: Likewise. * linux-src/net/ipv6/datagram_ipv6.c: Import file (was datagram.c). * linux-src/net/ipv6/icmpv6.c: Import file (was icmp.c). * linux-src/net/ipv6/protocol_ipv6.c: Import file (was protocol.c). * linux-src/net/ipv6/raw_ipv6.c: Import file (was raw.c). * linux-src/net/ipv6/route_ipv6.c: Import file (was route.c). * linux-src/net/ipv6/udp_ipv6.c: Import file (was udp.c).
* 2006-03-15 Thomas Schwinge <tschwinge@gnu.org>Thomas Schwinge2006-03-141-1/+4
| | | | | | * glue-include/asm/system.h (xchg): Fix invalid lvalue. * linux-src/net/ipv4/tcp_ipv4.c (tcp_v4_rst_req): Don't use ?: as a lvalue.
* 2004-09-03 Alfred M. Szmidt <ams@kemisten.nu>Roland McGrath2004-09-104-2/+7
| | | | | | | | | * linux-src/net/ipv4/udp.c (udp_v4_get_port): Put empty statement after label to silence compiler warning. * linux-src/net/ipv4/tcp_ipv4.c (tcp_v4_get_port, tcp_v4_connect, tcp_v4_rcv): Likewise. * linux-src/net/ipv4/route.c (ip_rt_redirect): Likewise. * linux-src/net/ipv4/arp.c (arp_constructor): Likewise.
* 2004-02-10 Roland McGrath <roland@frob.com>Roland McGrath2004-02-111-3/+3
| | | | * linux-src/arch/i386/lib/checksum.S: Fix comment syntax.
* 2003-05-07 Ognyan Kulev <ogi@fmi.uni-sofia.bg>Marcus Brinkmann2003-05-072-43/+37
| | | | | | | | | | | | * linux-src/include/asm-i386/checksum.h (ip_fast_csum): Use string literals concatenation instead of multi-line string literal. (csum_fold): Likewise. (csum_tcpudp_nofold): Likewise. (csum_ipv6_magic): Likewise. * linux-src/include/net/sock.h (SOCK_DEBUG): Don't use ## to concatenate string literals.
* 2002-06-13 Roland McGrath <roland@frob.com>Roland McGrath2002-06-131-1/+1
| | | | * linux-src/include/net/ip_fib.h: Fix obsolescent #endif syntax.
* 2002-05-29 Roland McGrath <roland@frob.com>Roland McGrath2002-05-291-0/+384
| | | | | | | | | | * linux-src/arch/alpha/lib/csum_partial_copy.c: New file, taken verbatim from Linux 2.2.14. * Makefile (arch-lib-srcs): Add csum_partial_copy.c. (LINUXSRCS): Match $(arch-lib-srcs) subset in arch/$(asm_syntax)/lib. (OBJS): Use delayed evaluation. * glue-include/asm/uaccess.h (__get_user): New macro. (__m): New macro.
* 2002-05-29 Roland McGrath <roland@frob.com>Roland McGrath2002-05-291-0/+1
| | | | | | | * linux-src/include/linux/net.h (struct socket) [_HURD_]: New member `st_ino'. * io-ops.c (S_io_stat, S_io_identity): Use that. * socket.c (sock_alloc): Initialize it with a monotonic counter.
* 2001-07-18 Marcus Brinkmann <marcus@gnu.org>Marcus Brinkmann2001-07-181-4/+6
| | | | | | | * linux-src/net/ipv4/devinit.c (configure_device): Initialize IFA correctly. If we are setting the peer on an IFF_POINTOPOINT link, force the netmask to 255.255.255.255. By Neal H Walfield <neal@cs.uml.edu>.
* 2001-02-25 Roland McGrath <roland@frob.com>Roland McGrath2001-02-261-1/+1
| | | | | * linux-src/include/linux/net.h (struct file): Move forward decl outside of `struct socket' type definition, for gcc-2.96 syntax.
* hurd/Marcus Brinkmann2001-01-112-3/+20
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-01-07 Marcus Brinkmann <marcus@gnu.org> * ioctl_types.h: Include <net/if.h>, define types sockaddr_t and ifname_t for iioctl.defs. * iioctl.defs: New file for network interface ioctls. * pfinet.defs: Remove old RPCs, fix subsystem number, add RPC for SIOCGIFCONF. pfinet/ 2001-01-07 Marcus Brinkmann <marcus@gnu.org> * pfinet-ops.c: New file to implement hurd/pfinet.defs. * iioctl-ops.c: New file to implement iioctl.defs. * linux-src/net/core/dev.c: If _HURD_, don't define netdev_chain as static. * glue-include/linux/if.h: New file, to avoid conflict between <net/if.h> (imported by iioctl.defs) and linux version of it. * main.c (pfinet_demuxer): Prototype pfinet_server and iioctl_server, use them. * pfinet.h: New global variables pfinetctl, pfinet_owner and pfinet_group. * main.c (main): New variable ST. Request pfinetctl from trivfs_startup. Use it to determine the owner and group of the underlying node. * io-ops.c (S_io_reauthenticate): New index variable j. Set newuser->isroot also for owners of the underlying file and group owners. (S_io_restrict_auth): Likewise. * socket-ops.c: Include <sys/stat.h> and <hurd/fshelp.h>. (S_socket_create): New variable isroot. If master->isroot is not set, use fshelp_isowner to check ownership and if to set it. Pass isroot to make_sock_user instead master->isroot. * linux-src/net/ipv4/devinet.c (configure_device): Accept new parameter BROADCAST, set ifa_broadcast if this is not INADDR_NONE. (inquire_device): Accept new parameter broadcast, set it. * main.c: Add new paramter to prototype of configure_device. (main): Add new parameter to call to configure_device. * options.c: Add new parameters to prototypes of configure_device and inquire_device. (trivfs_append_args): Define new variable BROAD, use its address as the new parameter for inquire_device. * linux-src/net/core/dev.c (dev_ifconf): Don't declare static if _HURD_. * linux-src/net/ipv4/devinet.c (inet_gifconf): If _HURD_, set sin_len member. * Makefile (MIGSRCS): Add pfinetServer.c and iioctlServer.c. (SRCS): Add pfinet-ops.c, iioctl-ops.c.