[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <alpine.DEB.2.00.0904252250230.4291@utopia.booyaka.com>
Date: Sat, 25 Apr 2009 22:53:35 -0600 (MDT)
From: Paul Walmsley <paul@...an.com>
To: linux-omap@...r.kernel.org
cc: lrg@...mlogic.co.uk, broonie@...nsource.wolfsonmicro.com,
linux-kernel@...r.kernel.org, dbrownell@...rs.sourceforge.net
Subject: Re: [PATCH] regulator core: fix double-free in regulator_register()
error path
On Sat, 25 Apr 2009, Paul Walmsley wrote:
> During regulator registration, any error after device_register() will
> cause a double-free on the struct regulator_dev 'rdev'. The bug is in
> drivers/regulator/core.c:regulator_register():
>
> ...
>
> device_unregister() calls regulator_dev_release() which frees rdev. The
> subsequent kfree corrupts memory and causes some OMAP3 systems to oops on
> boot in regulator_get().
For the 3430SDP users out there, this patch also fixes the boot hang after
"regulator_init_complete: incomplete constraints, leaving VAUX3 on"
on that device.
- Paul
--
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists