linux-arm-kernel.lists.infradead.org archive mirror
 help / color / mirror / Atom feed
From: shawn.guo@linaro.org (Shawn Guo)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH 01/15] ARM: provide a late_initcall hook for platform initialization
Date: Wed,  2 May 2012 19:33:26 +0800	[thread overview]
Message-ID: <1335958420-5193-2-git-send-email-shawn.guo@linaro.org> (raw)
In-Reply-To: <1335958420-5193-1-git-send-email-shawn.guo@linaro.org>

This allows platforms to set up things that need to be done at
late_initcall time.

Cc: Russell King <linux@arm.linux.org.uk>
Signed-off-by: Shawn Guo <shawn.guo@linaro.org>
Tested-by: Robert Lee <rob.lee@linaro.org>
---
 arch/arm/include/asm/mach/arch.h |    1 +
 arch/arm/kernel/setup.c          |    8 ++++++++
 2 files changed, 9 insertions(+), 0 deletions(-)

diff --git a/arch/arm/include/asm/mach/arch.h b/arch/arm/include/asm/mach/arch.h
index d7692ca..0b1c94b 100644
--- a/arch/arm/include/asm/mach/arch.h
+++ b/arch/arm/include/asm/mach/arch.h
@@ -43,6 +43,7 @@ struct machine_desc {
 	void			(*init_irq)(void);
 	struct sys_timer	*timer;		/* system tick timer	*/
 	void			(*init_machine)(void);
+	void			(*init_late)(void);
 #ifdef CONFIG_MULTI_IRQ_HANDLER
 	void			(*handle_irq)(struct pt_regs *);
 #endif
diff --git a/arch/arm/kernel/setup.c b/arch/arm/kernel/setup.c
index ebfac78..549f036 100644
--- a/arch/arm/kernel/setup.c
+++ b/arch/arm/kernel/setup.c
@@ -800,6 +800,14 @@ static int __init customize_machine(void)
 }
 arch_initcall(customize_machine);
 
+static int __init init_machine_late(void)
+{
+	if (machine_desc->init_late)
+		machine_desc->init_late();
+	return 0;
+}
+late_initcall(init_machine_late);
+
 #ifdef CONFIG_KEXEC
 static inline unsigned long long get_total_mem(void)
 {
-- 
1.7.5.4

  reply	other threads:[~2012-05-02 11:33 UTC|newest]

Thread overview: 34+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-05-02 11:33 [PATCH 00/15] arch/arm/mach-* late_initcall cleanup Shawn Guo
2012-05-02 11:33 ` Shawn Guo [this message]
2012-05-02 13:14   ` [PATCH 01/15] ARM: provide a late_initcall hook for platform initialization Shawn Guo
2012-05-03 14:55     ` Shawn Guo
2012-05-03 14:58     ` Russell King - ARM Linux
2012-05-02 17:47   ` H Hartley Sweeten
2012-05-02 11:33 ` [PATCH 02/15] ARM: davinci: use machine specific hook for late init Shawn Guo
2012-05-04 19:58   ` Sekhar Nori
2012-05-05  6:27     ` Shawn Guo
2012-05-02 11:33 ` [PATCH 03/15] ARM: ep93xx: " Shawn Guo
2012-05-02 17:45   ` H Hartley Sweeten
2012-05-03 15:05     ` Shawn Guo
2012-05-02 11:33 ` [PATCH 04/15] ARM: exynos: " Shawn Guo
2012-05-02 11:33 ` [PATCH 05/15] ARM: imx: " Shawn Guo
2012-05-02 12:36   ` Sascha Hauer
2012-05-02 11:33 ` [PATCH 06/15] ARM: msm: " Shawn Guo
2012-05-02 18:28   ` David Brown
2012-05-02 11:33 ` [PATCH 07/15] ARM: omap1: " Shawn Guo
2012-05-02 11:33 ` [PATCH 08/15] ARM: omap2: " Shawn Guo
2012-05-02 11:33 ` [PATCH 09/15] ARM: pnx4008: " Shawn Guo
2012-05-02 11:33 ` [PATCH 10/15] ARM: prima2: " Shawn Guo
2012-05-02 11:33 ` [PATCH 11/15] ARM: s3c64xx: " Shawn Guo
2012-05-02 11:33 ` [PATCH 12/15] ARM: sa1100: " Shawn Guo
2012-05-02 11:33 ` [PATCH 13/15] ARM: shmobile: " Shawn Guo
2012-05-02 11:33 ` [PATCH 14/15] ARM: tegra: " Shawn Guo
2012-05-02 15:57   ` Stephen Warren
2012-05-02 11:33 ` [PATCH 15/15] ARM: ux500: " Shawn Guo
2012-05-07 12:19   ` Linus Walleij
2012-05-08 12:39     ` Shawn Guo
2012-05-02 12:45 ` [PATCH 00/15] arch/arm/mach-* late_initcall cleanup Arnd Bergmann
2012-05-02 13:37   ` Shawn Guo
2012-05-02 13:41     ` Arnd Bergmann
2012-05-04 23:56     ` Tony Lindgren
2012-05-05  6:25       ` Shawn Guo

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=1335958420-5193-2-git-send-email-shawn.guo@linaro.org \
    --to=shawn.guo@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.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;
as well as URLs for NNTP newsgroup(s).