[PATCH DISCUSSION 8/8] drivers: Makefile: reorder driver initialization
Francesco Valla <[email protected]> Wed, 26 Nov 2025 23:54:36 +0100
| Newsgroups | org.kernel.vger.linux-embedded |
|---|---|
| Message-ID | <[email protected]> |
Reorder drivers at Makefile level to have the critical ones (fot the platform in exam, i.e. AM62x) to ptobe and initialize early. This avoids useless deferrals and saves some milliseconds. Signed-off-by: Francesco Valla <[email protected]> --- drivers/Makefile | 30 ++++++++++++++++-------------- 1 file changed, 16 insertions(+), 14 deletions(-) diff --git a/drivers/Makefile b/drivers/Makefile index 8e1ffa4358d5f1aadb0b1559ba3b41b44de6daa4..7dccffff7a126e2b1983467875d6b24ae7156075 100644 --- a/drivers/Makefile +++ b/drivers/Makefile @@ -7,14 +7,30 @@ # obj-y += cache/ +obj-$(CONFIG_MAILBOX) += mailbox/ +obj-y += firmware/ obj-y += irqchip/ obj-y += bus/ obj-$(CONFIG_GENERIC_PHY) += phy/ +# SOC specific infrastructure drivers. +obj-y += soc/ +obj-$(CONFIG_PM_GENERIC_DOMAINS) += pmdomain/ + +obj-y += clk/ +# Many drivers will want to use DMA so this has to be made available +# really early. +obj-$(CONFIG_DMADEVICES) += dma/ + + # GPIO must come after pinctrl as gpios may need to mux pins etc obj-$(CONFIG_PINCTRL) += pinctrl/ obj-$(CONFIG_GPIOLIB) += gpio/ + +# regulators early, since some subsystems rely on them to initialize +obj-$(CONFIG_REGULATOR) += regulator/ + obj-y += pwm/ # LEDs must come before PCI, it is needed by NPEM driver @@ -37,22 +53,10 @@ obj-$(CONFIG_ACPI) += acpi/ obj-$(CONFIG_PNP) += pnp/ obj-y += amba/ -obj-y += clk/ -# Many drivers will want to use DMA so this has to be made available -# really early. -obj-$(CONFIG_DMADEVICES) += dma/ - -# SOC specific infrastructure drivers. -obj-y += soc/ -obj-$(CONFIG_PM_GENERIC_DOMAINS) += pmdomain/ - obj-y += virtio/ obj-$(CONFIG_VDPA) += vdpa/ obj-$(CONFIG_XEN) += xen/ -# regulators early, since some subsystems rely on them to initialize -obj-$(CONFIG_REGULATOR) += regulator/ - # reset controllers early, since gpu drivers might rely on them to initialize obj-$(CONFIG_RESET_CONTROLLER) += reset/ @@ -134,7 +138,6 @@ obj-y += mmc/ obj-y += ufs/ obj-$(CONFIG_MEMSTICK) += memstick/ obj-$(CONFIG_INFINIBAND) += infiniband/ -obj-y += firmware/ obj-$(CONFIG_FWCTL) += fwctl/ obj-$(CONFIG_CRYPTO) += crypto/ obj-$(CONFIG_SUPERH) += sh/ @@ -153,7 +156,6 @@ obj-$(CONFIG_COMEDI) += comedi/ obj-$(CONFIG_STAGING) += staging/ obj-y += platform/ -obj-$(CONFIG_MAILBOX) += mailbox/ obj-$(CONFIG_HWSPINLOCK) += hwspinlock/ obj-$(CONFIG_REMOTEPROC) += remoteproc/ obj-$(CONFIG_RPMSG) += rpmsg/ -- 2.52.0