Re: [PATCH 2/2] of: Warn when of_property_read_bool() is used on non-boolean properties

From: Krzysztof Kozlowski
Date: Sat Jan 11 2025 - 05:12:53 EST


On Thu, Jan 09, 2025 at 01:42:06PM -0600, Rob Herring (Arm) wrote:
> The use of of_property_read_bool() for non-boolean properties is
> deprecated. The primary use of it was to test property presence, but
> that has been replaced in favor of of_property_present(). With those
> uses now fixed, add a warning to discourage new ones.
>
> Signed-off-by: Rob Herring (Arm) <robh@xxxxxxxxxx>
> ---
> drivers/of/property.c | 26 ++++++++++++++++++++++++++
> include/linux/of.h | 25 +++++++------------------
> 2 files changed, 33 insertions(+), 18 deletions(-)

Reviewed-by: Krzysztof Kozlowski <krzk@xxxxxxxxxx>

Best regards,
Krzysztof