RE: [PATCH v5 3/3] drivers: iio: adc: add support for ad777x family

Nechita, Ramona
2024-10-10T14:36:30Z

Hello Jonathan,

>> >> +
>> >> + ret = ad7779_reset(indio_dev, reset_gpio);
>> >> + if (ret)
>> >> + return ret;
>> >> +
>> >> + ad7779_powerup(st, start_gpio);
>> >> + if (ret)
>> >> + return ret;
>> >What powers the device down again if we hit an error?
>> >
>> >Probably need a devm_add_action_or_reset() or if it self powers down may a comment on that.
>>
>> In the powerup function there are only some register writes and the
>> start gpio is only a synchronization pulse (perhaps the name powerup is not very appropriate), would an action or reset be necessary in this case? Since the regulators are not used in the driver, should there be a function disabling them anyway?
>>
>If there is nothing useful to do indeed not but when I see a power up, I rather expect a power down. Is there anything that can do that or is it a case of it will go to sleep anyway for some other reason?

I don't think there would be anything to do in a powerdown function specifically, but I could rename the powerup function to "_config" or something similar, to make it more intuitive.

>
Best Regards,
Ramona