Thread (28 messages) 28 messages, 6 authors, 2012-07-09

Re: [PATCH] pwm-backlight: add regulator and GPIO support

From: Alex Courbot <acourbot@nvidia.com>
Date: 2012-07-04 15:03:11
Also in: linux-tegra, lkml

On Wed 04 Jul 2012 10:00:56 PM JST, Sascha Hauer wrote:
quoted
That's very bad indeed. I assumed that the kernel would free
devm-allocated resources after probe returned -EPROBE_DEFER,
It indeed does free devm allocated resources, but neither the gpio nor
the pwm are devm allocated.
As far as I can tell the gpio is allocated through devm as well:

 > +		ret = devm_gpio_request_one(&pdev->dev, data->enable_gpio,
 > +				GPIOF_OUT_INIT_HIGH, "backlight_enable");

Thus if it is not reclaimed with probe returns with -EPROBE_DEFER, then 
I guess something is going wrong elsewhere. You are right that the PWM 
should be freed by the driver thought.
Also please be aware that using a regulator in the pwm backlight will
instantly break all existing users. That's hardly your fault though.
Sorry, I don't see why. Could you elaborate on this?

Thanks,
Alex.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help