[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <804da030-ff7e-4bf2-84f8-2784fc93e9e8@lunn.ch>
Date: Tue, 27 Aug 2024 14:52:59 +0200
From: Andrew Lunn <andrew@...n.ch>
To: Jinjie Ruan <ruanjinjie@...wei.com>
Cc: woojung.huh@...rochip.com, f.fainelli@...il.com, olteanv@...il.com,
davem@...emloft.net, edumazet@...gle.com, kuba@...nel.org,
pabeni@...hat.com, linus.walleij@...aro.org, alsi@...g-olufsen.dk,
justin.chen@...adcom.com, sebastian.hesselbarth@...il.com,
alexandre.torgue@...s.st.com, joabreu@...opsys.com,
mcoquelin.stm32@...il.com, wens@...e.org, jernej.skrabec@...il.com,
samuel@...lland.org, hkallweit1@...il.com, linux@...linux.org.uk,
ansuelsmth@...il.com, UNGLinuxDriver@...rochip.com,
netdev@...r.kernel.org, linux-kernel@...r.kernel.org,
bcm-kernel-feedback-list@...adcom.com,
linux-arm-kernel@...ts.infradead.org, linux-sunxi@...ts.linux.dev,
linux-stm32@...md-mailman.stormreply.com, krzk@...nel.org,
jic23@...nel.org
Subject: Re: [PATCH -next 1/7] net: stmmac: dwmac-sun8i: Use
for_each_child_of_node_scoped() and __free()
On Tue, Aug 27, 2024 at 03:52:13PM +0800, Jinjie Ruan wrote:
> Avoid need to manually handle of_node_put() by using
> for_each_child_of_node_scoped() and __free(), which can simplfy code.
Please could you split this in two. for_each_child_of_node_scoped() is
fine, it solves a common bug, forgetting to do a node_put() on a early
exit from the loop.
I personally find __free() ugly, and would prefer to reject those
changes.
Andrew
Powered by blists - more mailing lists