aboutsummaryrefslogtreecommitdiffstats
path: root/arch/powerpc/platforms/85xx
diff options
context:
space:
mode:
Diffstat (limited to 'arch/powerpc/platforms/85xx')
-rw-r--r--arch/powerpc/platforms/85xx/Kconfig6
-rw-r--r--arch/powerpc/platforms/85xx/Makefile1
-rw-r--r--arch/powerpc/platforms/85xx/c293pcie.c75
3 files changed, 82 insertions, 0 deletions
diff --git a/arch/powerpc/platforms/85xx/Kconfig b/arch/powerpc/platforms/85xx/Kconfig
index b8f0d3270d7a..de2eb9320993 100644
--- a/arch/powerpc/platforms/85xx/Kconfig
+++ b/arch/powerpc/platforms/85xx/Kconfig
@@ -32,6 +32,12 @@ config BSC9131_RDB
32 StarCore SC3850 DSP 32 StarCore SC3850 DSP
33 Manufacturer : Freescale Semiconductor, Inc 33 Manufacturer : Freescale Semiconductor, Inc
34 34
35config C293_PCIE
36 bool "Freescale C293PCIE"
37 select DEFAULT_UIMAGE
38 help
39 This option enables support for the C293PCIE board
40
35config MPC8540_ADS 41config MPC8540_ADS
36 bool "Freescale MPC8540 ADS" 42 bool "Freescale MPC8540 ADS"
37 select DEFAULT_UIMAGE 43 select DEFAULT_UIMAGE
diff --git a/arch/powerpc/platforms/85xx/Makefile b/arch/powerpc/platforms/85xx/Makefile
index 2eab37ea4a9d..53c9f75a6907 100644
--- a/arch/powerpc/platforms/85xx/Makefile
+++ b/arch/powerpc/platforms/85xx/Makefile
@@ -6,6 +6,7 @@ obj-$(CONFIG_SMP) += smp.o
6obj-y += common.o 6obj-y += common.o
7 7
8obj-$(CONFIG_BSC9131_RDB) += bsc913x_rdb.o 8obj-$(CONFIG_BSC9131_RDB) += bsc913x_rdb.o
9obj-$(CONFIG_C293_PCIE) += c293pcie.o
9obj-$(CONFIG_MPC8540_ADS) += mpc85xx_ads.o 10obj-$(CONFIG_MPC8540_ADS) += mpc85xx_ads.o
10obj-$(CONFIG_MPC8560_ADS) += mpc85xx_ads.o 11obj-$(CONFIG_MPC8560_ADS) += mpc85xx_ads.o
11obj-$(CONFIG_MPC85xx_CDS) += mpc85xx_cds.o 12obj-$(CONFIG_MPC85xx_CDS) += mpc85xx_cds.o
diff --git a/arch/powerpc/platforms/85xx/c293pcie.c b/arch/powerpc/platforms/85xx/c293pcie.c
new file mode 100644
index 000000000000..6208e49142bf
--- /dev/null
+++ b/arch/powerpc/platforms/85xx/c293pcie.c
@@ -0,0 +1,75 @@
1/*
2 * C293PCIE Board Setup
3 *
4 * Copyright 2013 Freescale Semiconductor Inc.
5 *
6 * This program is free software; you can redistribute it and/or modify it
7 * under the terms of the GNU General Public License as published by the
8 * Free Software Foundation; either version 2 of the License, or (at your
9 * option) any later version.
10 */
11
12#include <linux/stddef.h>
13#include <linux/kernel.h>
14#include <linux/of_platform.h>
15
16#include <asm/machdep.h>
17#include <asm/udbg.h>
18#include <asm/mpic.h>
19
20#include <sysdev/fsl_soc.h>
21#include <sysdev/fsl_pci.h>
22
23#include "mpc85xx.h"
24
25void __init c293_pcie_pic_init(void)
26{
27 struct mpic *mpic = mpic_alloc(NULL, 0, MPIC_BIG_ENDIAN |
28 MPIC_SINGLE_DEST_CPU, 0, 256, " OpenPIC ");
29
30 BUG_ON(mpic == NULL);
31
32 mpic_init(mpic);
33}
34
35
36/*
37 * Setup the architecture
38 */
39static void __init c293_pcie_setup_arch(void)
40{
41 if (ppc_md.progress)
42 ppc_md.progress("c293_pcie_setup_arch()", 0);
43
44 fsl_pci_assign_primary();
45
46 printk(KERN_INFO "C293 PCIE board from Freescale Semiconductor\n");
47}
48
49machine_arch_initcall(c293_pcie, mpc85xx_common_publish_devices);
50
51/*
52 * Called very early, device-tree isn't unflattened
53 */
54static int __init c293_pcie_probe(void)
55{
56 unsigned long root = of_get_flat_dt_root();
57
58 if (of_flat_dt_is_compatible(root, "fsl,C293PCIE"))
59 return 1;
60 return 0;
61}
62
63define_machine(c293_pcie) {
64 .name = "C293 PCIE",
65 .probe = c293_pcie_probe,
66 .setup_arch = c293_pcie_setup_arch,
67 .init_IRQ = c293_pcie_pic_init,
68#ifdef CONFIG_PCI
69 .pcibios_fixup_bus = fsl_pcibios_fixup_bus,
70#endif
71 .get_irq = mpic_get_irq,
72 .restart = fsl_rstcr_restart,
73 .calibrate_decr = generic_calibrate_decr,
74 .progress = udbg_progress,
75};