Re: [PATCH v4 13/15] iio: dac: ad3552r: Use device_for_each_child_node_scoped()

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Sat, Feb 17, 2024 at 04:42:47PM +0000, Jonathan Cameron wrote:
> From: Jonathan Cameron <Jonathan.Cameron@xxxxxxxxxx>
> 
> Switching to the _scoped() version removes the need for manual
> calling of fwnode_handle_put() in the paths where the code
> exits the loop early. In this case that's all in error paths.
> 
> Removing the goto err; statements also allows more extensive use of
> dev_err_probe() further simplifying the code.

...

>  			err = fwnode_property_read_u32_array(child,
>  							     "adi,output-range-microvolt",
>  							     vals,
>  							     2);

Side note: ARRAY_SIZE()?

-- 
With Best Regards,
Andy Shevchenko






[Index of Archives]     [Linux IBM ACPI]     [Linux Power Management]     [Linux Kernel]     [Linux Laptop]     [Kernel Newbies]     [Share Photos]     [Security]     [Netfilter]     [Bugtraq]     [Yosemite News]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Samba]     [Video 4 Linux]     [Device Mapper]     [Linux Resources]
  Powered by Linux