[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <CAOLZvyGujvpnCFxe7x82Y91kRRNM1-P165jMXXWryFqY3g-RXw@mail.gmail.com>
Date: Sat, 21 Jan 2012 15:00:46 +0100
From: Manuel Lauss <manuel.lauss@...glemail.com>
To: Florian Tobias Schandinat <FlorianSchandinat@....de>
Cc: Julia Lawall <Julia.Lawall@...6.fr>,
kernel-janitors@...r.kernel.org, linux-fbdev@...r.kernel.org,
LKML <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH 2/4] drivers/video/au*fb.c: use devm_ functions
Hello,
On Sat, Jan 21, 2012 at 2:53 PM, Florian Tobias Schandinat
<FlorianSchandinat@....de> wrote:
> [CC'ing Manuel Lauss as he knows those drivers better than I do]
>
> On 01/20/2012 09:25 PM, Julia Lawall wrote:
>> From: Julia Lawall <Julia.Lawall@...6.fr>
>>
>> The various devm_ functions allocate memory that is released when a driver
>> detaches. This patch uses these functions for data that is allocated in
>> the probe function of a platform device and is only freed in the remove
>> function.
>>
>> Signed-off-by: Julia Lawall <Julia.Lawall@...6.fr>
>>
>> ---
>> In the case of au1100fb.c, should the failed label return something other
>> than 0?
>> In the case of au1200fb.c, should the error-handling code under the new
>> call to dma_alloc_noncoherent jump to failed, like the other error handling
>> code? I was not sure that there was actually anything for failed to do at
>> this point in the function.
>
> Maybe Manuel is able to answer these questions. I've queued this patch and if he
> doesn't respond I'll apply it after some time.
au1100fb: Yes, a -ENODEV instead of 0 in the error case is probably a
good idea.
au1200fb: The error path(s) are buggy; they don't free all windows if
creation of
the 4th fails for example. It has been this way
since the driver appeared
but for all current use cases (demoboards and in
the field) it actually works.
I'm working on a rewrite which is however
progressing rather slowly.
>> drivers/video/au1100fb.c | 30 +++++++++++-------------------
>> drivers/video/au1200fb.c | 9 +--------
>> 2 files changed, 12 insertions(+), 27 deletions(-)
Acked-by: Manuel Lauss <manuel.lauss@...glemail.com>
[...]
Thanks!
Manuel Lauss
--
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