lkml.org 
[lkml]   [2022]   [Dec]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] Input: fm801-gp - Fix an error handling path
Hi Christophe,

On Mon, Dec 19, 2022 at 10:36:47PM +0100, Christophe JAILLET wrote:
> This looks odd to call release_resource() for something allocated with
> request_region().
> Use release_region() instead.

I do not see why it is weird. request_region() gives you an instance of
"resource" structure which can later be freed. If we indeed want to use
release_region() (and hardcode the length in both places) then we should
also remove gp->res_port member. But I really do not find anything wrong
nor do I want to touch these old drivers...

Thanks.

--
Dmitry

\
 
 \ /
  Last update: 2023-03-26 23:16    [W:0.606 / U:0.008 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site