[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <5f878cd5-3166-4ddd-9c26-ed913439408c@redhat.com>
Date: Thu, 19 Dec 2024 11:23:32 +0100
From: Paolo Abeni <pabeni@...hat.com>
To: Joe Hattori <joe@...is.s.u-tokyo.ac.jp>, sebastian.hesselbarth@...il.com,
andrew+netdev@...n.ch, davem@...emloft.net, edumazet@...gle.com,
kuba@...nel.org
Cc: netdev@...r.kernel.org, dan.carpenter@...aro.org
Subject: Re: [PATCH v2] net: mv643xx_eth: fix an OF node reference leak
On 12/19/24 11:21, Paolo Abeni wrote:
> On 12/18/24 02:28, Joe Hattori wrote:
>> Current implementation of mv643xx_eth_shared_of_add_port() calls
>> of_parse_phandle(), but does not release the refcount on error. Call
>> of_node_put() in the error path and in mv643xx_eth_shared_of_remove().
>>
>> This bug was found by an experimental verification tool that I am
>> developing.
>>
>> Fixes: 76723bca2802 ("net: mv643xx_eth: add DT parsing support")
>> Signed-off-by: Joe Hattori <joe@...is.s.u-tokyo.ac.jp>
>> ---
>> Changes in v3:
>> - Insert a NULL check for port_platdev[n].
>> Changes in v2:
>> - Insert a NULL check before accessing the platform data.
>
> I'm sorry for nit-picking, but many little things are adding-up and
> should be noticed.
>
> The subj prefix must include the correct revision number (v3 in this case).
Oops, I almost forgot... the patch subj prefix must additionally include
the target tree - 'net' in this case - see:
https://elixir.bootlin.com/linux/v6.12.5/source/Documentation/process/maintainer-netdev.rst#L332
Thanks,
Paolo
Powered by blists - more mailing lists