Re: sendfile data corruption

From: Fabian Keil <freebsd-listen_at_fabiankeil.de>
Date: Mon, 13 Nov 2006 13:11:39 +0100
Robert Watson <rwatson_at_FreeBSD.org> wrote:

> 
> On Sun, 12 Nov 2006, Fabian Keil wrote:
> 
> > Fabian Keil <freebsd-listen_at_fabiankeil.de> wrote:
> >
> >> Andre Oppermann <andre_at_freebsd.org> wrote:
> >
> >>> Please try this patch:
> >>>
> >>>   http://people.freebsd.org/~andre/sendfile_fix-20061112.diff
> >>>
> >>> It fixes apache 2.0.59 for me.
> >>
> >> For me too, but I'm still seeing problems with Gatling/0.8.
> >
> > I just had to reboot the system and noticed several LORs before
> > the login prompt. Because of this one:
> >
> > lock order reversal:
> > 1st 0xc070b6a8 Giant (sleep mutex)
> > _at_ /usr/src/sys/kern/uipc_syscalls.c:1335 2nd 0xc27e5b10 inp (udpinp)
> > _at_ /usr/src/sys/netinet/udp_usrreq.c:1120 3rd 0xc27e30e0 so_snd (sleep
> > mutex) _at_ /usr/src/sys/kern/uipc_sockbuf.c:95
> 
> This is the correct lock order, so there must be a new lock order
> occuring earlier that gets added as the first order causing this one to
> appear as the incorrect order.  The following patch may help in making
> the right lock order problem come to surface:
> 
> Index: subr_witness.c
> ===================================================================
> RCS file: /home/ncvs/src/sys/kern/subr_witness.c,v
> retrieving revision 1.220
> diff -u -r1.220 subr_witness.c
> --- subr_witness.c	11 Nov 2006 03:18:06 -0000	1.220
> +++ subr_witness.c	13 Nov 2006 11:14:15 -0000
> _at__at_ -325,6 +325,7 _at__at_
>   	/*
>   	 * UDP/IP
>   	 */
> +	{ "Giant", &lock_class_mtx_sleep },
>   	{ "udp", &lock_class_mtx_sleep },
>   	{ "udpinp", &lock_class_mtx_sleep },
>   	{ "so_snd", &lock_class_mtx_sleep },

Thanks, but the LORs are already gone in:
FreeBSD 7.0-CURRENT #22: Mon Nov 13 12:47:19 CET 2006

Fabian
-- 
http://www.fabiankeil.de/

Received on Mon Nov 13 2006 - 11:12:19 UTC

This archive was generated by hypermail 2.4.0 : Wed May 19 2021 - 11:39:02 UTC