aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/platforms/44x/virtex.c
diff options
context:
space:
mode:
authorBenjamin Herrenschmidt <benh@kernel.crashing.org>2008-07-14 21:54:57 -0400
committerBenjamin Herrenschmidt <benh@kernel.crashing.org>2008-07-14 21:54:57 -0400
commit930074b6b9c4895d20cdadba5aff97907e28728d (patch)
tree3725eca121188f2e9c3b8bb4d4b8ba35e92640c7 /arch/powerpc/platforms/44x/virtex.c
parent3fd44736db9a5bf33e4a216b9cd43c9cfd57c459 (diff)
parent2bf3016f89344d4cd8b2c96bbec2b642a2bde413 (diff)
Merge commit 'jwb/jwb-next'
Diffstat (limited to 'arch/powerpc/platforms/44x/virtex.c')
-rw-r--r--arch/powerpc/platforms/44x/virtex.c60
1 files changed, 60 insertions, 0 deletions
diff --git a/arch/powerpc/platforms/44x/virtex.c b/arch/powerpc/platforms/44x/virtex.c
new file mode 100644
index 00000000000..68637faf70a
--- /dev/null
+++ b/arch/powerpc/platforms/44x/virtex.c
@@ -0,0 +1,60 @@
1/*
2 * Xilinx Virtex 5FXT based board support, derived from
3 * the Xilinx Virtex (IIpro & 4FX) based board support
4 *
5 * Copyright 2007 Secret Lab Technologies Ltd.
6 * Copyright 2008 Xilinx, Inc.
7 *
8 * This file is licensed under the terms of the GNU General Public License
9 * version 2. This program is licensed "as is" without any warranty of any
10 * kind, whether express or implied.
11 */
12
13#include <linux/init.h>
14#include <linux/of_platform.h>
15#include <asm/machdep.h>
16#include <asm/prom.h>
17#include <asm/time.h>
18#include <asm/xilinx_intc.h>
19#include <asm/reg.h>
20#include <asm/ppc4xx.h>
21#include "44x.h"
22
23static struct of_device_id xilinx_of_bus_ids[] __initdata = {
24 { .compatible = "simple-bus", },
25 { .compatible = "xlnx,plb-v46-1.00.a", },
26 { .compatible = "xlnx,plb-v46-1.02.a", },
27 { .compatible = "xlnx,plb-v34-1.01.a", },
28 { .compatible = "xlnx,plb-v34-1.02.a", },
29 { .compatible = "xlnx,opb-v20-1.10.c", },
30 { .compatible = "xlnx,dcr-v29-1.00.a", },
31 { .compatible = "xlnx,compound", },
32 {}
33};
34
35static int __init virtex_device_probe(void)
36{
37 of_platform_bus_probe(NULL, xilinx_of_bus_ids, NULL);
38
39 return 0;
40}
41machine_device_initcall(virtex, virtex_device_probe);
42
43static int __init virtex_probe(void)
44{
45 unsigned long root = of_get_flat_dt_root();
46
47 if (!of_flat_dt_is_compatible(root, "xlnx,virtex440"))
48 return 0;
49
50 return 1;
51}
52
53define_machine(virtex) {
54 .name = "Xilinx Virtex440",
55 .probe = virtex_probe,
56 .init_IRQ = xilinx_intc_init_tree,
57 .get_irq = xilinx_intc_get_irq,
58 .calibrate_decr = generic_calibrate_decr,
59 .restart = ppc4xx_reset_system,
60};