Skip site navigation (1)Skip section navigation (2)
Date:      Tue, 19 Dec 2006 22:21:16 +1100 (EST)
From:      Bruce Evans <bde@zeta.org.au>
To:        Craig Rodrigues <rodrigc@freebsd.org>
Cc:        cvs-src@freebsd.org, src-committers@freebsd.org, cvs-all@freebsd.org
Subject:   Re: cvs commit: src/sys/fs/msdosfs bpb.h
Message-ID:  <20061219202608.B9060@delplex.bde.org>
In-Reply-To: <200612190155.kBJ1tkFh076892@repoman.freebsd.org>
References:  <200612190155.kBJ1tkFh076892@repoman.freebsd.org>

next in thread | previous in thread | raw e-mail | index | archive | help
On Tue, 19 Dec 2006, Craig Rodrigues wrote:

> rodrigc     2006-12-19 01:55:45 UTC
>
>  FreeBSD src repository
>
>  Modified files:
>    sys/fs/msdosfs       bpb.h
>  Log:
>  Fix get_ulong() macro on AMD64 (or any little-endian 64-bit platform).
>  This bug caused vn_stat() to fail on files larger than 2gb on msdosfs
>  filesystems on AMD64.
>
>  PR:             106703
>  Tested by:      Axel Gonzalez <loox e-shell net>
>  MFC after:      3 days
>
>  Revision  Changes    Path
>  1.12      +1 -5      src/sys/fs/msdosfs/bpb.h

This breaks many more cases than it fixes, by removing support for
arches with strict alignment requirements.  It fixes little-endian
arches with 64-bit longs and no strict alignment requirements (mainly
amd64) almost accidentally by not using the broken generic getulong()
macro for them.  It freshly breaks all little-endian arches with strict
alignment requirements (mainly ia64).

The overflow bug remains unchanged.  It now affects all non-little-endian
arches with 64-bit longs (mainly sparc64).  It is fixed in practice
by the patch in the PR which is in the next commit (rev.1.13), but
that patch has has some style bugs and is logically wrong.  It makes
a line too long and fixes up overflow after overflow has already
occurred.  I discussed this with another committer in private (?) mail
but apparently frightened him by trying to explain the bug and various
correct fixes for it in detail.

Bruce



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