Re: [PATCH v5] iio: frequency: ad9832: Use FIELD_PREP macro to set bit fields

Siddharth Menon
2025-04-01T22:16:28Z

On Sun, 30 Mar 2025 at 21:13, Marcelo Schmitt
<marcelo.schmitt1@gmail.com> wrote:
> The previous implementation would set ctrl_fp if val == 1 and unset it if val == 0.
> This patch seems to be doing the reverse (setting ctrl_fp if val == 0, and
> unsetting it if val != 0). Was the previous implementation potentially buggy?

My apologies, I seem to have made a mistake here.

> Hmm, this is modifying behavior. AD9832_SLEEP and AD9832_CLR were only being
> modified if something other than 0 was written to output enable sysfs file.
> Is the patch code mode appropriate than how the driver was before?

I shall address the aforementioned issues along with the ones pointed out by
Jonathan in my next patch.

Thank you for taking the time to review my patches.

Regards,
Siddharth Menon