Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 5 Jan 2009 17:52:03 +0200
From:      Kostik Belousov <kostikbel@gmail.com>
To:        Jaakko Heinonen <jh@saunalahti.fi>
Cc:        freebsd-fs@freebsd.org
Subject:   Re: [patch] ext2fs freeze/corruption on amd64
Message-ID:  <20090105155203.GN93900@deviant.kiev.zoral.com.ua>
In-Reply-To: <20090105075009.GB7863@a91-153-125-115.elisa-laajakaista.fi>
References:  <20090103182107.GA4119@a91-153-125-115.elisa-laajakaista.fi> <20090104160043.GI93900@deviant.kiev.zoral.com.ua> <20090105075009.GB7863@a91-153-125-115.elisa-laajakaista.fi>

next in thread | previous in thread | raw e-mail | index | archive | help

--O27Gs9jTTFWz3gAR
Content-Type: text/plain; charset=us-ascii
Content-Disposition: inline
Content-Transfer-Encoding: quoted-printable

On Mon, Jan 05, 2009 at 09:50:10AM +0200, Jaakko Heinonen wrote:
> On 2009-01-04, Kostik Belousov wrote:
> > Please note that find_next_zero_bit() uses gcc extension to perform
> > void-pointer arithmetic. Also, at the +2 line, it performs unaligned
> > access to the uint32_t entities.
>=20
>     76	find_next_zero_bit(void *data, size_t sz, size_t ofs)
>     77	{
>     78		uint32_t *p;
>     79		uint32_t mask;
>     80		int bit;
>     81=09
>     82		p =3D (uint32_t*)data + (ofs >> 5);
>=20
> Hmmm, I don't think so. Did you notice that the type of p is uint32_t *
> (line 78) and that data is casted to uint32_t * for pointer arithmetic
> (line 82)?
You are right, I misparsed that line.

--O27Gs9jTTFWz3gAR
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.9 (FreeBSD)

iEYEARECAAYFAkliLKIACgkQC3+MBN1Mb4gBPgCglxiskeDah2zy8lhzDftT70iB
SS4Anii+3c4sfCZovsTNXaPpcCpDFv3Z
=dYg8
-----END PGP SIGNATURE-----

--O27Gs9jTTFWz3gAR--



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