From: Ralf Baechle <ralf@linux-mips.org>
To: linux-mips@linux-mips.org
Cc: Jayachandran C <jchandra@broadcom.com>,
Ganesan Ramalingam <ganesanr@broadcom.com>,
John Crispin <blogic@openwrt.org>
Subject: Fwd: Re: Build breakage in latest -next
Date: Thu, 31 Oct 2013 16:48:17 +0100 [thread overview]
Message-ID: <20131031154816.GX25884@linux-mips.org> (raw)
Comments regarding Rob's build fix below appreciated.
Thanks,
Ralf
Date: Tue, 29 Oct 2013 17:55:04 -0500
From: Rob Herring <rob.herring@calxeda.com>
Subject: Re: Build breakage in latest -next
On 10/29/2013 04:04 PM, Ralf Baechle wrote:
> nlm_xlp_defconfig fails with:
>
> LINK vmlinux
> LD vmlinux.o
> MODPOST vmlinux.o
> GEN .version
> CHK include/generated/compile.h
> UPD include/generated/compile.h
> CC init/version.o
> LD init/built-in.o
> arch/mips/built-in.o: In function `plat_mem_setup':
> (.init.text+0x5b0): undefined reference to `early_init_devtree'
> make[2]: *** [vmlinux] Error 1
> make[1]: *** [sub-make] Error 2
> make: *** [all] Error 2
> make: Leaving directory `/home/ralf/src/linux/obj/nlm_xlp-build'
>
> It appears this was caused by f75813c0127bbef41ac3152f64a72ba212a5514c
> [mips: use early_init_dt_scan] which removes the early_init_devtree
> function but doesn't the call in arch/mips/netlogic/xlp/setup.c.
I could change this to a call to device_tree_init, but the way it was
done results in scanning the DT twice. I would like to move the
device_tree_init call to be earlier instead to avoid this. I think this
should be functionally equivalent, but could use more eyes on it.
Rob
diff --git a/arch/mips/kernel/setup.c b/arch/mips/kernel/setup.c
index c538d6e..f5e5b0a 100644
--- a/arch/mips/kernel/setup.c
+++ b/arch/mips/kernel/setup.c
@@ -602,6 +602,8 @@ static void __init arch_mem_init(char **cmdline_p)
{
extern void plat_mem_setup(void);
+ device_tree_init();
+
/* call board setup routine */
plat_mem_setup();
@@ -662,7 +664,6 @@ static void __init arch_mem_init(char **cmdline_p)
crashk_res.end - crashk_res.start + 1,
BOOTMEM_DEFAULT);
#endif
- device_tree_init();
sparse_init();
plat_swiotlb_setup();
paging_init();
diff --git a/arch/mips/netlogic/xlp/setup.c b/arch/mips/netlogic/xlp/setup.c
index 76a7131..e8938b7 100644
--- a/arch/mips/netlogic/xlp/setup.c
+++ b/arch/mips/netlogic/xlp/setup.c
@@ -97,9 +97,6 @@ void __init plat_mem_setup(void)
_machine_halt = nlm_linux_exit;
pm_power_off = nlm_linux_exit;
- /* memory and bootargs from DT */
- early_init_devtree(initial_boot_params);
-
if (boot_mem_map.nr_map == 0) {
pr_info("Using DRAM BARs for memory map.\n");
xlp_init_mem_from_bars();
next reply other threads:[~2013-10-31 15:48 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-10-31 15:48 Ralf Baechle [this message]
2013-11-04 12:21 ` [PATCH] MIPS: Netlogic: replace early_init_devtree() call Jayachandran C
2013-11-04 16:04 ` Rob Herring
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20131031154816.GX25884@linux-mips.org \
--to=ralf@linux-mips.org \
--cc=blogic@openwrt.org \
--cc=ganesanr@broadcom.com \
--cc=jchandra@broadcom.com \
--cc=linux-mips@linux-mips.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox