network - Completely revamp the netisr / dispatch code
authorMatthew Dillon <dillon@apollo.backplane.com>
Thu, 9 Sep 2010 22:13:36 +0000 (15:13 -0700)
committerMatthew Dillon <dillon@apollo.backplane.com>
Thu, 9 Sep 2010 22:13:36 +0000 (15:13 -0700)
commitc3c96e4421a1087a390825eac6c01c9ed9182387
treee0efed9390fe0d1a8c3a82d1ef1af5934347cdf4
parent9389fe19d45e77003cc88f25a4890dde38d8718a
network - Completely revamp the netisr / dispatch code

* All netisrs are dispatched MPSAFE (followup in later commits)

* Centralize the protocol threads.  There is now just one thread
  per cpu managed by the netisr code.  No more separate tcp/udp threads
  on each cpu.

* Make the mbuf M_HASH/m_pkthdr.hash mechanic the central routing
  mechanic for netmsgs.

* Remove the netisr ip_mport and pktinfo_portfn stuff and replace with a
  cpufn function which handles M_HASH/m_pkthdr.hash when M_HASH is not
  already set.

* Seriously clean up the packet input paths.  Adjust ether_input_chain() and
  friends to not have to adjust the mbuf forwards and backwards, instead
  pass a header offset to the ni_cpufn function.  The ip pullup and other
  related code will use the offset to determine where the ip header is
  within the packet.
64 files changed:
sys/bus/usb/usb_ethersubr.c
sys/dev/acpica5/acpi_cpu_pstate.c
sys/dev/netif/ic/if_ic.c
sys/kern/kern_poll.c
sys/net/bpf.c
sys/net/bridge/if_bridge.c
sys/net/ef/if_ef.c
sys/net/faith/if_faith.c
sys/net/gif/if_gif.c
sys/net/if.c
sys/net/if_atmsubr.c
sys/net/if_ethersubr.c
sys/net/if_poll.c
sys/net/if_var.h
sys/net/ipfw/ip_fw2.c
sys/net/netisr.c
sys/net/netisr.h
sys/net/netmsg.h
sys/net/netmsg2.h
sys/net/ppp/if_ppp.c
sys/net/sppp/if_spppsubr.c
sys/net/stf/if_stf.c
sys/net/tun/if_tun.c
sys/netbt/bt_input.c
sys/netbt/bt_proto.c
sys/netgraph/iface/ng_iface.c
sys/netgraph/netgraph/ng_base.c
sys/netgraph7/ng_base.c
sys/netgraph7/ng_iface.c
sys/netgraph7/ng_ip_input.c
sys/netinet/if_ether.c
sys/netinet/in_proto.c
sys/netinet/ip_demux.c
sys/netinet/ip_divert.c
sys/netinet/ip_flow.c
sys/netinet/ip_gre.c
sys/netinet/ip_input.c
sys/netinet/ip_var.h
sys/netinet/tcp_subr.c
sys/netinet/tcp_syncache.c
sys/netinet/tcp_usrreq.c
sys/netinet/tcp_var.h
sys/netinet/udp_usrreq.c
sys/netinet6/ah_input.c
sys/netinet6/esp_input.c
sys/netinet6/frag6.c
sys/netinet6/in6_proto.c
sys/netinet6/ip6_input.c
sys/netinet6/ip6_var.h
sys/netproto/atalk/aarp.c
sys/netproto/atalk/ddp_input.c
sys/netproto/atalk/ddp_usrreq.c
sys/netproto/atm/atm_subr.c
sys/netproto/atm/ipatm/ipatm_input.c
sys/netproto/ipx/ipx_input.c
sys/netproto/ipx/ipx_ip.c
sys/netproto/mpls/mpls_demux.c
sys/netproto/mpls/mpls_input.c
sys/netproto/mpls/mpls_var.h
sys/netproto/natm/natm.c
sys/netproto/ns/ns_input.c
sys/netproto/ns/ns_ip.c
sys/sys/mbuf.h
sys/sys/thread.h