[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <Y6IGCtw1CHgcBwbB@google.com>
Date: Tue, 20 Dec 2022 10:59:22 -0800
From: Dmitry Torokhov <dmitry.torokhov@...il.com>
To: Christophe JAILLET <christophe.jaillet@...adoo.fr>
Cc: linux-kernel@...r.kernel.org, kernel-janitors@...r.kernel.org,
linux-input@...r.kernel.org
Subject: Re: [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
Powered by blists - more mailing lists