Re: [PATCH v1 1/2] iio: adc: ti-adc128s052: Use get_unaligned_beXX()

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

 



On Fri, Dec 23, 2022 at 03:17:50PM +0000, Jonathan Cameron wrote:
> On Wed, 14 Dec 2022 14:02:01 +0200
> Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx> wrote:
> 
> > This makes the driver code slightly easier to read.
> > While at it, use GENMASK() as well.
> > 
> > Signed-off-by: Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx>
> Hi Andy,
> 
> Patch looks good, but it got me thinking.  Why not just flip this driver
> over to using spi_write_then_read().  Would let us drop the DMA safety
> protections and simplify the code + use a __be16 as the read buffer
> and this would then be the slightly nicer aligned form.
> 
> Worth doing whilst you are here?

OK, I will consider when I have time for this.

-- 
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