git: network - Move socket from netmsg ext to netmsg header, add

看板DFBSD_commit作者時間16年前 (2009/12/06 04:01), 編輯推噓0(000)
留言0則, 0人參與, 最新討論串1/1
commit 48e7b118aed5eb70d42bdbf2ca5a938ef1f371b6 Author: Matthew Dillon <dillon@apollo.backplane.com> Date: Sat Dec 5 11:45:34 2009 -0800 network - Move socket from netmsg ext to netmsg header, add port to socket These changes should make it easier to debug mbufs routed to the wrong protocol threads. Note that IPV6 is routed to netisr0, even for tcp and udp packets, so for now we do not KKASSERT that the port matches directly. The TCP code still KKASSERTs that the timers are running on the correct cpu, since the cpu is still correct for IPV6 TCP/UDP packets even when the protocol thread is wrong (netisr_cpu 0 instead of tcp_thread 0 or udp_thread 0). * Instead of recalculating the port based on the inp or mbuf all the time, add a so_port field to the socket structure directly. * The socket pointer is now part of the netmsg header, even though some subsystems do not need it. This allows us to validate the message port more easily. Summary of changes: sys/dev/acpica5/acpi_cpu_pstate.c | 10 +- sys/dev/netif/iwl/if_iwl.c | 2 +- sys/kern/kern_poll.c | 34 ++-- sys/kern/kern_timeout.c | 3 + sys/kern/uipc_msg.c | 237 ++++++++++--------------- sys/kern/uipc_socket.c | 12 ++ sys/kern/uipc_socket2.c | 12 ++ sys/kern/uipc_syscalls.c | 16 +-- sys/kern/uipc_usrreq.c | 1 + sys/net/bpf.c | 4 +- sys/net/bridge/if_bridge.c | 47 +++--- sys/net/dummynet/ip_dummynet.c | 9 +- sys/net/dummynet/ip_dummynet_glue.c | 20 ++- sys/net/if.c | 16 +- sys/net/if_ethersubr.c | 4 +- sys/net/if_poll.c | 40 ++-- sys/net/ipfw/ip_fw2.c | 64 ++++--- sys/net/ipfw/ip_fw2_glue.c | 3 +- sys/net/netisr.c | 45 ++++- sys/net/netmsg.h | 21 +-- sys/net/netmsg2.h | 12 +- sys/net/pf/pf.c | 4 +- sys/net/pfil.c | 6 +- sys/net/route.c | 22 ++- sys/net/rtsock.c | 4 +- sys/net/vlan/if_vlan.c | 24 ++- sys/netinet/if_ether.c | 11 +- sys/netinet/in.c | 16 +- sys/netinet/ip_demux.c | 91 ++++------ sys/netinet/ip_divert.c | 8 +- sys/netinet/ip_divert.h | 3 +- sys/netinet/ip_flow.c | 6 +- sys/netinet/ip_input.c | 4 +- sys/netinet/ip_var.h | 11 +- sys/netinet/tcp_subr.c | 12 +- sys/netinet/tcp_syncache.c | 32 +++- sys/netinet/tcp_timer.c | 2 +- sys/netinet/tcp_usrreq.c | 326 +++++++++++++++++++---------------- sys/netinet/tcp_var.h | 5 +- sys/netinet/udp_usrreq.c | 125 +++++++++++--- sys/netinet/udp_var.h | 5 +- sys/netinet6/ip6_demux.c | 11 +- sys/netinet6/ip6protosw.h | 2 +- sys/netinet6/tcp6_var.h | 2 +- sys/netinet6/udp6_usrreq.c | 2 + sys/netproto/atm/atm_proto.c | 2 +- sys/sys/protosw.h | 6 +- sys/sys/socketops.h | 8 +- sys/sys/socketvar.h | 2 + 49 files changed, 755 insertions(+), 609 deletions(-) http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/48e7b118aed5eb70d42bdbf2ca5a938ef1f371b6 -- DragonFly BSD source repository
文章代碼(AID): #1B6hm4_c (DFBSD_commit)