Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 3 Nov 2008 22:20:03 +0100
From:      "Attilio Rao" <attilio@freebsd.org>
To:        "Robert Watson" <rwatson@freebsd.org>
Cc:        Yuri Pankov <yuri.pankov@gmail.com>, freebsd-fs@freebsd.org, freebsd-current@freebsd.org, developers@freebsd.org
Subject:   Re: reproducible panic with mount_smbfs
Message-ID:  <3bbf2fe10811031320o5d977babpe37bcf22836b8d34@mail.gmail.com>
In-Reply-To: <alpine.BSF.1.10.0811032106110.48320@fledge.watson.org>
References:  <20081102123100.GA1434@darklight.homeunix.org> <3bbf2fe10811020737g211dfb3fs54b48e4071db2393@mail.gmail.com> <3bbf2fe10811020817g1409a38ep26c1ee8edf075201@mail.gmail.com> <200811031458.42549.jhb@freebsd.org> <alpine.BSF.1.10.0811032106110.48320@fledge.watson.org>

next in thread | previous in thread | raw e-mail | index | archive | help
2008/11/3, Robert Watson <rwatson@freebsd.org>:
> On Mon, 3 Nov 2008, John Baldwin wrote:
>
>
> >
> > > Yuri, could you please test this fix:
> http://www.freebsd.org/~attilio/netsmb.diff
> > >
> > > and report if it works? You could get a KASSERT running but this is
> expected as I want to identify on the callers who passes a malformed request
> and fix it.
> > >
> >
> > This allows all smb locks to recurse unlike the original code I think.  It
> may be better if smb_vclist was initialized with LK_RECURSE, but not all the
> other smb locks.  Also, in smb_co_addchild() I think you should just replace
> the existing asserts with appropriate lockmgr_assert() (you could add a
> smb_co_assert() to preserve the layering) rather than removing assertions
> altogether.
> >
>
>  My general feeling is that the locking in netsmb needs a bit of cleanup,
> updating, etc.  I'm reluctant to change the underlying primitives (as this
> patch does) without first clarifying what's going on in the code a layer or
> two above.

I agree with Robert.
We need to make an upper layers analysis and decide what is the best
solution for locks.
This was a quick hack just to let it not panic when mounting.

Thanks,
Attilio


-- 
Peace can only be achieved by understanding - A. Einstein



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?3bbf2fe10811031320o5d977babpe37bcf22836b8d34>