From 8c1449bdb4c7e9c4492ba18ded70fd8669eeffae Mon Sep 17 00:00:00 2001 From: Josh Boyer Date: Mon, 20 Aug 2007 07:30:14 -0500 Subject: [POWERPC] Bamboo board support Add support for the AMCC Bamboo board Signed-off-by: Josh Boyer Acked-by: David Gibson --- arch/powerpc/platforms/44x/bamboo.c | 66 +++++++++++++++++++++++++++++++++++++ 1 file changed, 66 insertions(+) create mode 100644 arch/powerpc/platforms/44x/bamboo.c (limited to 'arch/powerpc/platforms/44x/bamboo.c') diff --git a/arch/powerpc/platforms/44x/bamboo.c b/arch/powerpc/platforms/44x/bamboo.c new file mode 100644 index 000000000000..5522f1f9642e --- /dev/null +++ b/arch/powerpc/platforms/44x/bamboo.c @@ -0,0 +1,66 @@ +/* + * Bamboo board specific routines + * + * Wade Farnsworth + * Copyright 2004 MontaVista Software Inc. + * + * Rewritten and ported to the merged powerpc tree: + * Josh Boyer + * Copyright 2007 IBM Corporation + * + * This program is free software; you can redistribute it and/or modify it + * under the terms of the GNU General Public License as published by the + * Free Software Foundation; either version 2 of the License, or (at your + * option) any later version. + */ +#include +#include +#include +#include +#include +#include +#include +#include "44x.h" + +static struct of_device_id bamboo_of_bus[] = { + { .compatible = "ibm,plb", }, + { .compatible = "ibm,opb", }, + { .compatible = "ibm,ebc", }, + {}, +}; + +static int __init bamboo_device_probe(void) +{ + if (!machine_is(bamboo)) + return 0; + + of_platform_bus_probe(NULL, bamboo_of_bus, NULL); + + return 0; +} +device_initcall(bamboo_device_probe); + +static int __init bamboo_probe(void) +{ + unsigned long root = of_get_flat_dt_root(); + + if (!of_flat_dt_is_compatible(root, "amcc,bamboo")) + return 0; + + return 1; +} + +static void __init bamboo_setup_arch(void) +{ +} + +define_machine(bamboo) { + .name = "Bamboo", + .probe = bamboo_probe, + .setup_arch = bamboo_setup_arch, + .progress = udbg_progress, + .init_IRQ = uic_init_tree, + .get_irq = uic_get_irq, + .restart = ppc44x_reset_system, + .calibrate_decr = generic_calibrate_decr, +}; -- cgit v1.2.3 From 1f6e57952180cd54e245241b74f4b9cb10c24f98 Mon Sep 17 00:00:00 2001 From: Josh Boyer Date: Fri, 7 Sep 2007 07:50:26 -0500 Subject: [POWERPC] Fix bus probe on Bamboo board Commit 804ace8881d21 changed the behavior of how compatible nodes are found. This highlighted a bug on the Bamboo board where it wasn't probing the bus specified in the DTS file. We fix it by being explicit about which bus to probe. Signed-off-by: Josh Boyer Acked-by: David Gibson --- arch/powerpc/platforms/44x/bamboo.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'arch/powerpc/platforms/44x/bamboo.c') diff --git a/arch/powerpc/platforms/44x/bamboo.c b/arch/powerpc/platforms/44x/bamboo.c index 5522f1f9642e..9bc45dea078f 100644 --- a/arch/powerpc/platforms/44x/bamboo.c +++ b/arch/powerpc/platforms/44x/bamboo.c @@ -23,7 +23,7 @@ #include "44x.h" static struct of_device_id bamboo_of_bus[] = { - { .compatible = "ibm,plb", }, + { .compatible = "ibm,plb4", }, { .compatible = "ibm,opb", }, { .compatible = "ibm,ebc", }, {}, -- cgit v1.2.3 From d27c1cedc0e4faed2c0fce9d82d4c17695e43e90 Mon Sep 17 00:00:00 2001 From: Grant Likely Date: Thu, 11 Oct 2007 04:48:23 +1000 Subject: [POWERPC] Remove empty ppc_md.setup_arch hooks Signed-off-by: Grant Likely Acked-by: Josh Boyer Signed-off-by: Paul Mackerras --- arch/powerpc/platforms/40x/virtex.c | 5 ----- arch/powerpc/platforms/40x/walnut.c | 5 ----- arch/powerpc/platforms/44x/bamboo.c | 5 ----- arch/powerpc/platforms/44x/ebony.c | 5 ----- arch/powerpc/platforms/44x/sequoia.c | 5 ----- 5 files changed, 25 deletions(-) (limited to 'arch/powerpc/platforms/44x/bamboo.c') diff --git a/arch/powerpc/platforms/40x/virtex.c b/arch/powerpc/platforms/40x/virtex.c index b52aa94abd78..14bbc328170f 100644 --- a/arch/powerpc/platforms/40x/virtex.c +++ b/arch/powerpc/platforms/40x/virtex.c @@ -36,14 +36,9 @@ static int __init virtex_probe(void) return 1; } -static void __init virtex_setup_arch(void) -{ -} - define_machine(virtex) { .name = "Xilinx Virtex", .probe = virtex_probe, - .setup_arch = virtex_setup_arch, .init_IRQ = xilinx_intc_init_tree, .get_irq = xilinx_intc_get_irq, .calibrate_decr = generic_calibrate_decr, diff --git a/arch/powerpc/platforms/40x/walnut.c b/arch/powerpc/platforms/40x/walnut.c index c17fdf23b492..eb0c136b1c44 100644 --- a/arch/powerpc/platforms/40x/walnut.c +++ b/arch/powerpc/platforms/40x/walnut.c @@ -53,14 +53,9 @@ static int __init walnut_probe(void) return 1; } -static void __init walnut_setup_arch(void) -{ -} - define_machine(walnut) { .name = "Walnut", .probe = walnut_probe, - .setup_arch = walnut_setup_arch, .progress = udbg_progress, .init_IRQ = uic_init_tree, .get_irq = uic_get_irq, diff --git a/arch/powerpc/platforms/44x/bamboo.c b/arch/powerpc/platforms/44x/bamboo.c index 9bc45dea078f..470e1a3fd755 100644 --- a/arch/powerpc/platforms/44x/bamboo.c +++ b/arch/powerpc/platforms/44x/bamboo.c @@ -50,14 +50,9 @@ static int __init bamboo_probe(void) return 1; } -static void __init bamboo_setup_arch(void) -{ -} - define_machine(bamboo) { .name = "Bamboo", .probe = bamboo_probe, - .setup_arch = bamboo_setup_arch, .progress = udbg_progress, .init_IRQ = uic_init_tree, .get_irq = uic_get_irq, diff --git a/arch/powerpc/platforms/44x/ebony.c b/arch/powerpc/platforms/44x/ebony.c index 5a7fec8d10d3..40e18fcb666c 100644 --- a/arch/powerpc/platforms/44x/ebony.c +++ b/arch/powerpc/platforms/44x/ebony.c @@ -57,14 +57,9 @@ static int __init ebony_probe(void) return 1; } -static void __init ebony_setup_arch(void) -{ -} - define_machine(ebony) { .name = "Ebony", .probe = ebony_probe, - .setup_arch = ebony_setup_arch, .progress = udbg_progress, .init_IRQ = uic_init_tree, .get_irq = uic_get_irq, diff --git a/arch/powerpc/platforms/44x/sequoia.c b/arch/powerpc/platforms/44x/sequoia.c index 7d0d9d567d25..30700b31d43b 100644 --- a/arch/powerpc/platforms/44x/sequoia.c +++ b/arch/powerpc/platforms/44x/sequoia.c @@ -50,14 +50,9 @@ static int __init sequoia_probe(void) return 1; } -static void __init sequoia_setup_arch(void) -{ -} - define_machine(sequoia) { .name = "Sequoia", .probe = sequoia_probe, - .setup_arch = sequoia_setup_arch, .progress = udbg_progress, .init_IRQ = uic_init_tree, .get_irq = uic_get_irq, -- cgit v1.2.3