On Tue, 30 Sep 2008, Linus Torvalds wrote:A clearer (and more flexible) solution might be this patch. It's more explicit about the fact that it simply makes it clear that any drivers that are added by the architecture Makefile will be _first_ in the list of drivers. I suspect we should do the same with 'libs' and 'core' too, for that matter, but we don't really use '*.a' libraries any more so link order doesn't matter apart from initcall ordering. And libraries should hopfully never have that issue. And 'core' is at least right now just the initramfs thing. So in practice, it's probably only drivers/ that coul have issues like this. Sam added to Cc, since this is a build issue. What do people think? Background: We are very careful to add 'drivers/pci' _before_ 'drivers/{acpi,pnp}' in the drivers/Makefile, but what happens now is that since the arch Makefile adds it's own drivers to the very end, the really core PCI initcalls actually get ordered at the end, not the beginning. Linus --- Makefile | 4 +++- 1 files changed, 3 insertions(+), 1 deletions(-) diff --git a/Makefile b/Makefile index 1d03c16..642b9b9 100644 --- a/Makefile +++ b/Makefile @@ -458,7 +458,6 @@ scripts: scripts_basic include/config/auto.conf # Objects we will link into vmlinux / subdirs we need to visit init-y := init/ -drivers-y := drivers/ sound/ firmware/ net-y := net/ libs-y := lib/ core-y := usr/ @@ -517,6 +516,9 @@ endif include $(srctree)/arch/$(SRCARCH)/Makefile +# Do this _after_ the architecture may have added its own core drivers +drivers-y += drivers/ sound/ firmware/ + ifneq (CONFIG_FRAME_WARN,0) KBUILD_CFLAGS += $(call cc-option,-Wframe-larger-than=${CONFIG_FRAME_WARN}) endif --
| Peter Zijlstra | [RFC][PATCH 7/7] lockdep: spin_lock_nest_lock() |
| Gabriel C | Re: 2.6.24-rc2-mm1 |
| Andrew Morton | Re: [PATCH 2.6.21] cramfs: add cramfs Linear XIP |
| Jiri Kosina | Re: 2.6.21-rc5-mm4 |
git: | |
| Gregory Haskins | [RFC PATCH 00/17] virtual-bus |
| Jarek Poplawski | Re: [PATCH] pkt_sched: Destroy gen estimators under rtnl_lock(). |
| David Miller | [GIT]: Networking |
| Gerrit Renker | [PATCH 0/37] dccp: Feature negotiation - last call for comments |
