lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <aAuqgiSxrh24-L-D@stanley.mountain>
Date: Fri, 25 Apr 2025 18:30:10 +0300
From: Dan Carpenter <dan.carpenter@...aro.org>
To: Laurent Pinchart <laurent.pinchart@...asonboard.com>
Cc: "zhangzekun (A)" <zhangzekun11@...wei.com>,
	Oleksij Rempel <o.rempel@...gutronix.de>, robh@...nel.org,
	saravanak@...gle.com, justin.chen@...adcom.com,
	florian.fainelli@...adcom.com, andrew+netdev@...n.ch,
	kuba@...nel.org, kory.maincent@...tlin.com,
	jacopo+renesas@...ndi.org, kieran.bingham+renesas@...asonboard.com,
	maddy@...ux.ibm.com, mpe@...erman.id.au, npiggin@...il.com,
	olteanv@...il.com, davem@...emloft.net, taras.chornyi@...ision.eu,
	edumazet@...gle.com, pabeni@...hat.com, sudeep.holla@....com,
	cristian.marussi@....com, arm-scmi@...r.kernel.org,
	linuxppc-dev@...ts.ozlabs.org, linux-media@...r.kernel.org,
	netdev@...r.kernel.org, devicetree@...r.kernel.org,
	chenjun102@...wei.com, Joe Hattori <joe@...is.s.u-tokyo.ac.jp>,
	Krzysztof Kozlowski <krzk@...nel.org>
Subject: Re: [PATCH 1/9] of: Add warpper function
 of_find_node_by_name_balanced()

Whatever happened with this thread from Feb.
https://lore.kernel.org/all/20250207013117.104205-1-zhangzekun11@huawei.com/

The issue was that people weren't expecting of_find_node_by_name() to
drop the reference on the of_node.  The patchset introduced a wrapper
which basically worked as expected except no liked the naming.  Krzysztof
suggested that maybe the callers should be using of_get_child_by_name()
instead.

I created a Smatch warning for this and here are the four issues it
found.  The line numbers are from linux-next.

drivers/net/ethernet/broadcom/asp2/bcmasp.c:1370 bcmasp_probe() warn: 'dev->of_node' was not incremented
drivers/net/pse-pd/tps23881.c:505 tps23881_get_of_channels() warn: 'priv->np' was not incremented
drivers/media/platform/qcom/venus/core.c:301 venus_add_video_core() warn: 'dev->of_node' was not incremented
drivers/regulator/tps6594-regulator.c:618 tps6594_regulator_probe() warn: 'tps->dev->of_node' was not incremented

regards,
dan carpenter


Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ