linuxppc-dev.lists.ozlabs.org archive mirror
 help / color / mirror / Atom feed
From: Andreas Oberritter <obi@saftware.de>
To: Tom Rini <trini@kernel.crashing.org>
Cc: linuxppc-embedded@lists.linuxppc.org
Subject: [PATCH] make platform_init() weak for 8xx
Date: Mon, 19 Jul 2004 18:13:35 +0200	[thread overview]
Message-ID: <1090253615.1415.24.camel@shiva.saftware.de> (raw)

[-- Attachment #1: Type: text/plain, Size: 269 bytes --]

Hi Tom,

this patch renames platform_init to m8xx_init in m8xx_setup.c and adds
new weak platform_init, which can be overridden by boards to allow them
to e.g. register platform_devices like redwood5.c does for 40x.

Signed-off-by: Andreas Oberritter <obi@saftware.de>

[-- Attachment #2: m8xx_setup.diff --]
[-- Type: text/x-patch, Size: 1302 bytes --]

===== arch/ppc/syslib/m8xx_setup.c 1.29 vs edited =====
--- 1.29/arch/ppc/syslib/m8xx_setup.c	2004-05-28 00:37:33 +02:00
+++ edited/arch/ppc/syslib/m8xx_setup.c	2004-07-19 17:54:03 +02:00
@@ -47,6 +47,7 @@
 #include <asm/xmon.h>

 #include "ppc8xx_pic.h"
+#include "m8xx_setup.h"

 static int m8xx_set_rtc_time(unsigned long time);
 static unsigned long m8xx_get_rtc_time(void);
@@ -363,7 +364,7 @@
 }

 void __init
-platform_init(unsigned long r3, unsigned long r4, unsigned long r5,
+m8xx_init(unsigned long r3, unsigned long r4, unsigned long r5,
 		unsigned long r6, unsigned long r7)
 {
 	parse_bootinfo(find_bootinfo());
@@ -413,3 +414,11 @@
 	m8xx_ide_init();
 #endif
 }
+
+void __init __attribute__ ((weak))
+platform_init(unsigned long r3, unsigned long r4, unsigned long r5,
+		unsigned long r6, unsigned long r7)
+{
+	m8xx_init(r3, r4, r5, r6, r7);
+}
+
--- /dev/null	2004-07-17 13:36:50.945552208 +0200
+++ edited/arch/ppc/syslib/m8xx_setup.h	2004-07-19 17:15:37.854994064 +0200
@@ -0,0 +1,12 @@
+/*
+ * arch/ppc/syslib/m8xx_setup.h
+ */
+
+#ifndef _PPC_SYSLIB_M8XX_SETUP_H
+#define _PPC_SYSLIB_M8XX_SETUP_H
+
+void m8xx_init(unsigned long r3, unsigned long r4, unsigned long r5,
+		unsigned long r6, unsigned long r7);
+void m8xx_setup_arch(void);
+
+#endif /* _PPC_SYSLIB_M8XX_SETUP_H */

             reply	other threads:[~2004-07-19 16:13 UTC|newest]

Thread overview: 6+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2004-07-19 16:13 Andreas Oberritter [this message]
2004-07-19 16:32 ` [PATCH] make platform_init() weak for 8xx Tom Rini
2004-07-19 17:34   ` Andreas Oberritter
2004-07-19 18:20     ` Tom Rini
2004-07-23 13:59       ` [PATCH] add board_init() (was [PATCH] make platform_init() weak for 8xx) Andreas Oberritter
2004-07-27 21:01         ` Tom Rini

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=1090253615.1415.24.camel@shiva.saftware.de \
    --to=obi@saftware.de \
    --cc=linuxppc-embedded@lists.linuxppc.org \
    --cc=trini@kernel.crashing.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).