can: c_can: Use of_property_present() to test existence of DT property
[ Upstream commit ab1bc2290fd8311d49b87c29f1eb123fcb581bee ] of_property_read_bool() should be used only on boolean properties. Cc: Rob Herring <robh@kernel.org> Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@linaro.org> Reviewed-by: Vincent Mailhol <mailhol.vincent@wanadoo.fr> Link: https://patch.msgid.link/20250212-syscon-phandle-args-can-v2-3-ac9a1253396b@linaro.org Signed-off-by: Marc Kleine-Budde <mkl@pengutronix.de> Signed-off-by: Sasha Levin <sashal@kernel.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
ef7ee9b815
commit
00e59d1495
@@ -333,7 +333,7 @@ static int c_can_plat_probe(struct platform_device *pdev)
|
||||
/* Check if we need custom RAMINIT via syscon. Mostly for TI
|
||||
* platforms. Only supported with DT boot.
|
||||
*/
|
||||
if (np && of_property_read_bool(np, "syscon-raminit")) {
|
||||
if (np && of_property_present(np, "syscon-raminit")) {
|
||||
u32 id;
|
||||
struct c_can_raminit *raminit = &priv->raminit_sys;
|
||||
|
||||
|
Reference in New Issue
Block a user