Re: [linux-usb-devel] Container_of considered harmful - was Re: usb storage sddr09

Matthew Dharm (mdharm-kernel@one-eyed-alien.net)
Sun, 20 Oct 2002 21:12:38 -0700


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

Actually, I've seen this one with 2.5.44 and no USB storage devices
attached. Just load usb-storage and it OOPSes.

I haven't been able to find it yet, but I haven't looked as hard as I
could.

Matt

On Sun, Oct 20, 2002 at 08:24:36PM +0200, Andries Brouwer wrote:
> > Both of these are fixed with 2.4.44
>=20
> Yes, there is progress. Not to say that there are no oopses left,
> but with 2.5.44 the oopses are different.
>=20
> Let me just report one, don't know whether I'll have time to track
> what happens.
>=20
> Insert and remove a usb-storage device while usb-storage
> is not loaded. Now load usb-storage. Oops.
>=20
> The oops is a dereference of fffffff0 in base/bus.c:driver_attach().
> I have seen several such oopses lately, various places in the kernel.
> The cause here is a NULL pointer that is turned into fffffff0 by
> container_of() and then fed to get_device(). And get_device() tests
> that it gets a non-NULL pointer, but that does not protect against
> fffffff0.
>=20
> Andries
>=20
>=20
> -------------------------------------------------------
> This sf.net email is sponsored by:
> Access Your PC Securely with GoToMyPC. Try Free Now
> https://www.gotomypc.com/s/OSND/DD
> _______________________________________________
> linux-usb-devel@lists.sourceforge.net
> To unsubscribe, use the last form field at:
> https://lists.sourceforge.net/lists/listinfo/linux-usb-devel

--=20
Matthew Dharm Home: mdharm-usb@one-eyed-alien.=
net=20
Maintainer, Linux USB Mass Storage Driver

What, are you one of those Microsoft-bashing Linux freaks?
-- Customer to Greg
User Friendly, 2/10/1999

--jI8keyz6grp/JLjh
Content-Type: application/pgp-signature
Content-Disposition: inline

-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.0.6 (GNU/Linux)
Comment: For info see http://www.gnupg.org

iD8DBQE9s362IjReC7bSPZARAlYmAJ9ciz8cuixRWHWwgrpvR14PDLsXOACgss+C
hHCkPP7SX2usEuwzChSWYNU=
=vP0+
-----END PGP SIGNATURE-----

--jI8keyz6grp/JLjh--
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/