aboutsummaryrefslogtreecommitdiffstats
path: root/arch
diff options
context:
space:
mode:
authorRoderick Colenbrander <thunderbird2k@gmail.com>2009-06-06 12:15:24 -0400
committerGrant Likely <grant.likely@secretlab.ca>2009-06-06 12:15:24 -0400
commite52ba9c54176c9757ab6b18bea7b7ed51e2faf16 (patch)
tree6efb90176a3401f15dd3e914fdc3c682946533b4 /arch
parent1745fbc744a934b235c2e5ecb5380079fa54be38 (diff)
powerpc/virtex: Add Xilinx ML510 reference design support
Signed-off-by: Roderick Colenbrander <thunderbird2k@gmail.com> Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'arch')
-rw-r--r--arch/powerpc/platforms/44x/Kconfig13
-rw-r--r--arch/powerpc/platforms/44x/Makefile1
-rw-r--r--arch/powerpc/platforms/44x/virtex_ml510.c29
-rw-r--r--arch/powerpc/sysdev/xilinx_intc.c5
4 files changed, 47 insertions, 1 deletions
diff --git a/arch/powerpc/platforms/44x/Kconfig b/arch/powerpc/platforms/44x/Kconfig
index 0d83a6a0397d..90e3192611a4 100644
--- a/arch/powerpc/platforms/44x/Kconfig
+++ b/arch/powerpc/platforms/44x/Kconfig
@@ -156,7 +156,7 @@ config YOSEMITE
156# This option enables support for the IBM PPC440GX evaluation board. 156# This option enables support for the IBM PPC440GX evaluation board.
157 157
158config XILINX_VIRTEX440_GENERIC_BOARD 158config XILINX_VIRTEX440_GENERIC_BOARD
159 bool "Generic Xilinx Virtex 440 board" 159 bool "Generic Xilinx Virtex 5 FXT board support"
160 depends on 44x 160 depends on 44x
161 default n 161 default n
162 select XILINX_VIRTEX_5_FXT 162 select XILINX_VIRTEX_5_FXT
@@ -171,6 +171,17 @@ config XILINX_VIRTEX440_GENERIC_BOARD
171 Most Virtex 5 designs should use this unless it needs to do some 171 Most Virtex 5 designs should use this unless it needs to do some
172 special configuration at board probe time. 172 special configuration at board probe time.
173 173
174config XILINX_ML510
175 bool "Xilinx ML510 extra support"
176 depends on XILINX_VIRTEX440_GENERIC_BOARD
177 select PPC_PCI_CHOICE
178 select XILINX_PCI if PCI
179 select PPC_INDIRECT_PCI if PCI
180 select PPC_I8259 if PCI
181 help
182 This option enables extra support for features on the Xilinx ML510
183 board. The ML510 has a PCI bus with ALI south bridge.
184
174config PPC44x_SIMPLE 185config PPC44x_SIMPLE
175 bool "Simple PowerPC 44x board support" 186 bool "Simple PowerPC 44x board support"
176 depends on 44x 187 depends on 44x
diff --git a/arch/powerpc/platforms/44x/Makefile b/arch/powerpc/platforms/44x/Makefile
index 01f51daace13..ee6185aeaa3b 100644
--- a/arch/powerpc/platforms/44x/Makefile
+++ b/arch/powerpc/platforms/44x/Makefile
@@ -4,3 +4,4 @@ obj-$(CONFIG_EBONY) += ebony.o
4obj-$(CONFIG_SAM440EP) += sam440ep.o 4obj-$(CONFIG_SAM440EP) += sam440ep.o
5obj-$(CONFIG_WARP) += warp.o 5obj-$(CONFIG_WARP) += warp.o
6obj-$(CONFIG_XILINX_VIRTEX_5_FXT) += virtex.o 6obj-$(CONFIG_XILINX_VIRTEX_5_FXT) += virtex.o
7obj-$(CONFIG_XILINX_ML510) += virtex_ml510.o
diff --git a/arch/powerpc/platforms/44x/virtex_ml510.c b/arch/powerpc/platforms/44x/virtex_ml510.c
new file mode 100644
index 000000000000..ba4a6e388a46
--- /dev/null
+++ b/arch/powerpc/platforms/44x/virtex_ml510.c
@@ -0,0 +1,29 @@
1#include <asm/i8259.h>
2#include <linux/pci.h>
3#include "44x.h"
4
5/**
6 * ml510_ail_quirk
7 */
8static void __devinit ml510_ali_quirk(struct pci_dev *dev)
9{
10 /* Enable the IDE controller */
11 pci_write_config_byte(dev, 0x58, 0x4c);
12 /* Assign irq 14 to the primary ide channel */
13 pci_write_config_byte(dev, 0x44, 0x0d);
14 /* Assign irq 15 to the secondary ide channel */
15 pci_write_config_byte(dev, 0x75, 0x0f);
16 /* Set the ide controller in native mode */
17 pci_write_config_byte(dev, 0x09, 0xff);
18
19 /* INTB = disabled, INTA = disabled */
20 pci_write_config_byte(dev, 0x48, 0x00);
21 /* INTD = disabled, INTC = disabled */
22 pci_write_config_byte(dev, 0x4a, 0x00);
23 /* Audio = INT7, Modem = disabled. */
24 pci_write_config_byte(dev, 0x4b, 0x60);
25 /* USB = INT7 */
26 pci_write_config_byte(dev, 0x74, 0x06);
27}
28DECLARE_PCI_FIXUP_EARLY(0x10b9, 0x1533, ml510_ali_quirk);
29
diff --git a/arch/powerpc/sysdev/xilinx_intc.c b/arch/powerpc/sysdev/xilinx_intc.c
index 90b57724a5e4..3ee1fd37bbfc 100644
--- a/arch/powerpc/sysdev/xilinx_intc.c
+++ b/arch/powerpc/sysdev/xilinx_intc.c
@@ -257,6 +257,11 @@ static void __init xilinx_i8259_setup_cascade(void)
257 i8259_init(cascade_node, 0); 257 i8259_init(cascade_node, 0);
258 set_irq_chained_handler(cascade_irq, xilinx_i8259_cascade); 258 set_irq_chained_handler(cascade_irq, xilinx_i8259_cascade);
259 259
260 /* Program irq 7 (usb/audio), 14/15 (ide) to level sensitive */
261 /* This looks like a dirty hack to me --gcl */
262 outb(0xc0, 0x4d0);
263 outb(0xc0, 0x4d1);
264
260 out: 265 out:
261 of_node_put(cascade_node); 266 of_node_put(cascade_node);
262} 267}