]> CyberLeo.Net >> Repos - FreeBSD/FreeBSD.git/commit
Apply error and success logic consistently to the function netisr_queue() and
authorandre <andre@FreeBSD.org>
Fri, 27 Aug 2004 18:33:08 +0000 (18:33 +0000)
committerandre <andre@FreeBSD.org>
Fri, 27 Aug 2004 18:33:08 +0000 (18:33 +0000)
commit21264022388cc795478511d03b72ddc0ce213c5b
tree5e40bb2ff1fccfd1425f4b8ada947f22f8df6605
parent4e16b35c5bbfa63f8794131592ae3b1ac4d05cfd
Apply error and success logic consistently to the function netisr_queue() and
its users.

netisr_queue() now returns (0) on success and ERRNO on failure.  At the
moment ENXIO (netisr queue not functional) and ENOBUFS (netisr queue full)
are supported.

Previously it would return (1) on success but the return value of IF_HANDOFF()
was interpreted wrongly and (0) was actually returned on success.  Due to this
schednetisr() was never called to kick the scheduling of the isr.  However this
was masked by other normal packets coming through netisr_dispatch() causing the
dequeueing of waiting packets.

PR: kern/70988
Found by: MOROHOSHI Akihiko <moro@remus.dti.ne.jp>
MFC after: 3 days
16 files changed:
sys/dev/hfa/fore_receive.c
sys/dev/idt/idt_harp.c
sys/dev/ppbus/if_plip.c
sys/i4b/driver/i4b_ipr.c
sys/net/if_loop.c
sys/net/if_ppp.c
sys/net/if_sl.c
sys/net/if_spppsubr.c
sys/net/netisr.c
sys/net/rtsock.c
sys/netgraph/atm/atmpif/ng_atmpif_harp.c
sys/netinet/ip_mroute.c
sys/netinet6/ah_input.c
sys/netinet6/esp_input.c
sys/netipsec/ipsec_input.c
sys/netipsec/xform_ipip.c