Re: [PATCH v2 16/16] spi: cadence: Remove explicit device node availability check

Jonathan Cameron
2025-09-29T09:54:28Z

On Wed, 24 Sep 2025 10:46:02 +0300
Sakari Ailus <sakari.ailus@linux.intel.com> wrote:

> Don't check the availability of child device nodes explicitly as this is
> now embedded in device_for_each_child_node().
>
> Signed-off-by: Sakari Ailus <sakari.ailus@linux.intel.com>
Reviewed-by: Jonathan Cameron <jonathan.cameron@huawei.com>

> ---
> drivers/spi/spi-cadence-xspi.c | 3 ---
> 1 file changed, 3 deletions(-)
>
> diff --git a/drivers/spi/spi-cadence-xspi.c b/drivers/spi/spi-cadence-xspi.c
> index 6dcba0e0ddaa..23e426ef9b9c 100644
> --- a/drivers/spi/spi-cadence-xspi.c
> +++ b/drivers/spi/spi-cadence-xspi.c
> @@ -908,9 +908,6 @@ static int cdns_xspi_of_get_plat_data(struct platform_device *pdev)
> unsigned int cs;
>
> device_for_each_child_node(&pdev->dev, fwnode_child) {
> - if (!fwnode_device_is_available(fwnode_child))
> - continue;
> -
> if (fwnode_property_read_u32(fwnode_child, "reg", &cs)) {
> dev_err(&pdev->dev, "Couldn't get memory chip select\n");
> fwnode_handle_put(fwnode_child);