Re: [GIT PULL] LED updates for 5.4-rc1

From: Linus Torvalds
Date: Tue Sep 17 2019 - 21:19:30 EST


On Mon, Sep 16, 2019 at 3:21 PM Jacek Anaszewski
<jacek.anaszewski@xxxxxxxxx> wrote:
>
> There is one merge of tag with generic_lookup_helpers since
> LED class has been made using class_find_device_by_name() helper:
>
> Merge tag 'generic_lookup_helpers' into for-next
> platform: Add platform_find_device_by_driver() helper
> drivers: Add generic helper to match any device
> drivers: Introduce device lookup variants by ACPI_COMPANION device
> drivers: Introduce device lookup variants by device type
> drivers: Introduce device lookup variants by fwnode
> drivers: Introduce device lookup variants by of_node
> drivers: Introduce device lookup variants by name

So this is fine and I've pulled it, but I have to say that I
absolutely detest how this device.h header keeps just growing
endlessly:

[torvalds@linux]$ wc include/linux/device.h
1921 8252 66021 include/linux/device.h

that's almost 2k of header file, and it's included a _lot_:

[torvalds@linux]$ git grep include.*linux/device.h | wc
2518 5085 144875

and many of those includes are actually from other core header files,
so it's effectively included from even more trees.

Yes, yes, many of those 2k lines are comments. But still... Do we
really want to have that humongous 65kB, 2kloc header file, and keep
growing it forever?

Greg?

Linus