Re: [PATCH v2] gpio: Avoid kernel.h inclusion where it's possible

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

 



On Thu, Feb 06, 2020 at 02:47:29PM -0700, Rob Herring wrote:
> On Wed, Feb 05, 2020 at 03:43:36PM +0200, Andy Shevchenko wrote:
> > Inclusion of kernel.h increases the mess with the header dependencies.
> > Avoid kernel.h inclusion where it's possible.

> > Besides that, clean up a bit other inclusions inside GPIO subsystem headers.
> > It includes:
> >  - removal pin control bits (forward declaration and header) from linux/gpio.h
> >  - removal of.h from asm-generic/gpio.h
> >  - use of explicit headers in gpio/consumer.h
> >  - add FIXME note with regard to gpio.h inclusion in of_gpio,h

...

> >  #else	/* !CONFIG_GPIOLIB */
> >  
> > +#include <linux/kernel.h>
> > +
> 
> I don't really think moving the includes inside #ifdef's is an 
> improvment.

I also not a big fun, but for now it removes in most cases when
CONFIG_GPIOLIB=y. And this is already an improvement. Next step is to replace
it with newly created (when it will be created) header might_sleep.h.

> But I'll leave it to Linus.

-- 
With Best Regards,
Andy Shevchenko





[Index of Archives]     [Linux SPI]     [Linux Kernel]     [Linux ARM (vger)]     [Linux ARM MSM]     [Linux Omap]     [Linux Arm]     [Linux Tegra]     [Fedora ARM]     [Linux for Samsung SOC]     [eCos]     [Linux Fastboot]     [Gcc Help]     [Git]     [DCCP]     [IETF Announce]     [Security]     [Linux MIPS]     [Yosemite Campsites]

  Powered by Linux