Re: [PATCH v1 1/8] iio: accel: bma220: Fix returned codes from bma220_init(), bma220_deinit()

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

 



On Thu, Sep 3, 2020 at 11:23 AM Jonathan Cameron
<Jonathan.Cameron@xxxxxxxxxx> wrote:
> On Mon, 31 Aug 2020 15:12:01 +0100
> Jonathan Cameron <jic23@xxxxxxxxxx> wrote:
> > On Mon, 31 Aug 2020 14:49:04 +0300
> > Andy Shevchenko <andriy.shevchenko@xxxxxxxxxxxxxxx> wrote:
> > > On Mon, Aug 31, 2020 at 10:21:45AM +0100, Jonathan Cameron wrote:

...

> > > P.S. Consider this series as an example what can be done to many IIO drivers
> > > in order to clean them up. My focus, of course, ACPI interaction:
> > >  - use of ACPI_PTR / ifdeffery
> > >  - inclusion of acpi.h
> > >  - ...

> > Thanks.  This is probably a good one for anyone who wants to grow their
> > experience in kernel patches etc.  I'll add it to my more or less
> > never ending list if not and get to it eventually.
> >
> > In the meantime we'll try to avoid introducing any new variants!

> Andy, one thing that might want adjusting is the docs that suggest
> doing ACPI_PTR and ifdeffery.
>
> https://elixir.bootlin.com/linux/v5.9-rc3/source/Documentation/firmware-guide/acpi/enumeration.rst#L254

I briefly looked at the text and it seems that there is not one
problem (typo, etc) in it. The entire document needs to be revisited.
Unfortunately I have no time right now to do that.
Regarding ACPI_PTR() it looks like case by case, because in the
example you pointed out it's just a style preference (and somebody may
actually want to save few dozen of bytes in their driver to reduce
memory footprint). That said, we rather need to describe both options
and tell the difference.

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