Re: [PATCH 3/4] iio: st_sensors: remove all driver remove functions

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

 



On Mon, Jul 26, 2021 at 10:14 AM Alexandru Ardelean
<aardelean@xxxxxxxxxxx> wrote:
>
> At this point all ST driver remove functions do iio_device_unregister().
> This change removes them from them and replaces all iio_device_register()
> with devm_iio_device_register().
>
> This can be done in a single change relatively easy, since all these remove

easily

> functions are define in st_sensors.h.

defined

>  drivers/iio/imu/st_lsm9ds0/st_lsm9ds0.h      |  1 -
>  drivers/iio/imu/st_lsm9ds0/st_lsm9ds0_core.c | 15 +--------------
>  drivers/iio/imu/st_lsm9ds0/st_lsm9ds0_i2c.c  |  6 ------
>  drivers/iio/imu/st_lsm9ds0/st_lsm9ds0_spi.c  |  6 ------

I will check these later on, but the rule of thumb about devm_*() is
that there shouldn't be gaps (non-devm) before any devm call.

-- 
With Best Regards,
Andy Shevchenko



[Index of Archives]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Input]     [Linux Kernel]     [Linux SCSI]     [X.org]

  Powered by Linux