kern/85503: panic: wrong dirclust using msdosfs in RELENG_6
Dmitry Pryanishnikov
dmitry at atlantis.dp.ua
Mon Sep 5 04:00:43 PDT 2005
The following reply was made to PR kern/85503; it has been noted by GNATS.
From: Dmitry Pryanishnikov <dmitry at atlantis.dp.ua>
To: Poul-Henning Kamp <phk at haven.freebsd.dk>
Cc: freebsd-arch at freebsd.org, bug-followup at freebsd.org
Subject: Re: kern/85503: panic: wrong dirclust using msdosfs in RELENG_6
Date: Mon, 5 Sep 2005 13:50:01 +0300 (EEST)
Hello!
On Fri, 2 Sep 2005, Poul-Henning Kamp wrote:
>> found the primary error (lack of casts leaded to 32-bit result), but then
>> we should transfer this 64-bit "inode" number to vfs_hash_get(). Oops,
>> it also limited to u_int (32 bits on i386). Finally, I see that the
>> primary shortcoming here: in sys/vnode.h we have
>
> NFS has the same sort of problem, it has 16 or 32 *bytes* filehandles
> that need to hash to 32 bit "inode numbers".
>
> If you look at vfs_hash_get calls in sys/nfsclient you can see that
> it calculates a 32bit hash but then provides a "nfs_vncmpf" function
> to do the actual comparison to resolve hash collisions.
Indeed, I've missed last 2 arguments of vfs_hash_get(). Actually it seems
that the only error here is missing cast. After application of the following
patch:
ftp://external.atlantis.dp.ua/FreeBSD/PR/85503/msdosfs.patch
problem has gone away. Please, if possible, review and commit it. I think this
patch is a good MFC candidate for RELENG_6 and RELENG_6_0, since it prevents
panic in quite common environment.
Sincerely, Dmitry
--
Atlantis ISP, System Administrator
e-mail: dmitry at atlantis.dp.ua
nic-hdl: LYNX-RIPE
More information about the freebsd-bugs
mailing list