Re: [PATCH v2 3/4] iio: gyro: mpu3050: Move iio_device_register() to correct location

From: Linus Walleij

Date: Tue Feb 24 2026 - 04:57:09 EST


On Tue, Feb 24, 2026 at 3:35 AM Ethan Tidmore <ethantidmore06@xxxxxxxxx> wrote:

> iio_device_register() should be at the end of the probe function to
> prevent race conditions.
>
> Place iio_device_register() at end of probe function and place
> iio_device_unregister() accordingly.
>
> Fixes: 3904b28efb2c7 ("iio: gyro: Add driver for the MPU-3050 gyroscope")
> Suggested-by: Jonathan Cameron <jic23@xxxxxxxxxx>
> Signed-off-by: Ethan Tidmore <ethantidmore06@xxxxxxxxx>

Reviewed-by: Linus Walleij <linusw@xxxxxxxxxx>

Yours,
Linus Walleij