aboutsummaryrefslogtreecommitdiffstats
path: root/arch/arm
diff options
context:
space:
mode:
authorKrzysztof Hałasa <khc@pm.waw.pl>2009-11-16 10:02:02 -0500
committerKrzysztof Hałasa <khc@pm.waw.pl>2009-12-05 10:58:39 -0500
commitc1117c63d53cc269193d02383b4275ae5c4cbe49 (patch)
treeff7dc79d9f9653183fa34a6b4a15b702f70cc4b2 /arch/arm
parentf89f44902af4b88e12c5d2c888915749362198e7 (diff)
IXP4xx: move NSLU2 platform macros to the platform code.
Signed-off-by: Krzysztof Hałasa <khc@pm.waw.pl>
Diffstat (limited to 'arch/arm')
-rw-r--r--arch/arm/mach-ixp4xx/include/mach/hardware.h1
-rw-r--r--arch/arm/mach-ixp4xx/include/mach/irqs.h7
-rw-r--r--arch/arm/mach-ixp4xx/include/mach/nslu2.h55
-rw-r--r--arch/arm/mach-ixp4xx/nslu2-pci.c13
-rw-r--r--arch/arm/mach-ixp4xx/nslu2-setup.c21
5 files changed, 32 insertions, 65 deletions
diff --git a/arch/arm/mach-ixp4xx/include/mach/hardware.h b/arch/arm/mach-ixp4xx/include/mach/hardware.h
index 1fbed65731a8..b949cd200918 100644
--- a/arch/arm/mach-ixp4xx/include/mach/hardware.h
+++ b/arch/arm/mach-ixp4xx/include/mach/hardware.h
@@ -45,7 +45,6 @@
45 45
46/* Platform specific details */ 46/* Platform specific details */
47#include "prpmc1100.h" 47#include "prpmc1100.h"
48#include "nslu2.h"
49#include "nas100d.h" 48#include "nas100d.h"
50#include "dsmg600.h" 49#include "dsmg600.h"
51#include "fsg.h" 50#include "fsg.h"
diff --git a/arch/arm/mach-ixp4xx/include/mach/irqs.h b/arch/arm/mach-ixp4xx/include/mach/irqs.h
index e4c6ccaebbfc..b7e372ede240 100644
--- a/arch/arm/mach-ixp4xx/include/mach/irqs.h
+++ b/arch/arm/mach-ixp4xx/include/mach/irqs.h
@@ -79,13 +79,6 @@
79#define IRQ_PRPMC1100_PCI_INTD IRQ_IXP4XX_GPIO8 79#define IRQ_PRPMC1100_PCI_INTD IRQ_IXP4XX_GPIO8
80 80
81/* 81/*
82 * NSLU2 board IRQs
83 */
84#define IRQ_NSLU2_PCI_INTA IRQ_IXP4XX_GPIO11
85#define IRQ_NSLU2_PCI_INTB IRQ_IXP4XX_GPIO10
86#define IRQ_NSLU2_PCI_INTC IRQ_IXP4XX_GPIO9
87
88/*
89 * NAS100D board IRQs 82 * NAS100D board IRQs
90 */ 83 */
91#define IRQ_NAS100D_PCI_INTA IRQ_IXP4XX_GPIO11 84#define IRQ_NAS100D_PCI_INTA IRQ_IXP4XX_GPIO11
diff --git a/arch/arm/mach-ixp4xx/include/mach/nslu2.h b/arch/arm/mach-ixp4xx/include/mach/nslu2.h
deleted file mode 100644
index 85d00adbfb92..000000000000
--- a/arch/arm/mach-ixp4xx/include/mach/nslu2.h
+++ /dev/null
@@ -1,55 +0,0 @@
1/*
2 * arch/arm/mach-ixp4xx/include/mach/nslu2.h
3 *
4 * NSLU2 platform specific definitions
5 *
6 * Author: Mark Rakes <mrakes AT mac.com>
7 * Maintainers: http://www.nslu2-linux.org
8 *
9 * based on ixdp425.h:
10 * Copyright 2004 (c) MontaVista, Software, Inc.
11 *
12 * This file is licensed under the terms of the GNU General Public
13 * License version 2. This program is licensed "as is" without any
14 * warranty of any kind, whether express or implied.
15 */
16
17#ifndef __ASM_ARCH_HARDWARE_H__
18#error "Do not include this directly, instead #include <mach/hardware.h>"
19#endif
20
21#define NSLU2_SDA_PIN 7
22#define NSLU2_SCL_PIN 6
23
24/*
25 * NSLU2 PCI IRQs
26 */
27#define NSLU2_PCI_MAX_DEV 3
28#define NSLU2_PCI_IRQ_LINES 3
29
30
31/* PCI controller GPIO to IRQ pin mappings */
32#define NSLU2_PCI_INTA_PIN 11
33#define NSLU2_PCI_INTB_PIN 10
34#define NSLU2_PCI_INTC_PIN 9
35#define NSLU2_PCI_INTD_PIN 8
36
37/* NSLU2 Timer */
38#define NSLU2_FREQ 66000000
39
40/* Buttons */
41
42#define NSLU2_PB_GPIO 5 /* power button */
43#define NSLU2_PO_GPIO 8 /* power off */
44#define NSLU2_RB_GPIO 12 /* reset button */
45
46/* Buzzer */
47
48#define NSLU2_GPIO_BUZZ 4
49
50/* LEDs */
51
52#define NSLU2_LED_RED_GPIO 0
53#define NSLU2_LED_GRN_GPIO 1
54#define NSLU2_LED_DISK1_GPIO 3
55#define NSLU2_LED_DISK2_GPIO 2
diff --git a/arch/arm/mach-ixp4xx/nslu2-pci.c b/arch/arm/mach-ixp4xx/nslu2-pci.c
index 4429b8448b61..9665bb082107 100644
--- a/arch/arm/mach-ixp4xx/nslu2-pci.c
+++ b/arch/arm/mach-ixp4xx/nslu2-pci.c
@@ -18,10 +18,21 @@
18#include <linux/pci.h> 18#include <linux/pci.h>
19#include <linux/init.h> 19#include <linux/init.h>
20#include <linux/irq.h> 20#include <linux/irq.h>
21
22#include <asm/mach/pci.h> 21#include <asm/mach/pci.h>
23#include <asm/mach-types.h> 22#include <asm/mach-types.h>
24 23
24#define NSLU2_PCI_MAX_DEV 3
25#define NSLU2_PCI_IRQ_LINES 3
26
27/* PCI controller GPIO to IRQ pin mappings */
28#define NSLU2_PCI_INTA_PIN 11
29#define NSLU2_PCI_INTB_PIN 10
30#define NSLU2_PCI_INTC_PIN 9
31#define NSLU2_PCI_INTD_PIN 8
32#define IRQ_NSLU2_PCI_INTA IRQ_IXP4XX_GPIO11
33#define IRQ_NSLU2_PCI_INTB IRQ_IXP4XX_GPIO10
34#define IRQ_NSLU2_PCI_INTC IRQ_IXP4XX_GPIO9
35
25void __init nslu2_pci_preinit(void) 36void __init nslu2_pci_preinit(void)
26{ 37{
27 set_irq_type(IRQ_NSLU2_PCI_INTA, IRQ_TYPE_LEVEL_LOW); 38 set_irq_type(IRQ_NSLU2_PCI_INTA, IRQ_TYPE_LEVEL_LOW);
diff --git a/arch/arm/mach-ixp4xx/nslu2-setup.c b/arch/arm/mach-ixp4xx/nslu2-setup.c
index ff6a08d02cc4..c14e0034be4b 100644
--- a/arch/arm/mach-ixp4xx/nslu2-setup.c
+++ b/arch/arm/mach-ixp4xx/nslu2-setup.c
@@ -26,13 +26,32 @@
26#include <linux/i2c.h> 26#include <linux/i2c.h>
27#include <linux/i2c-gpio.h> 27#include <linux/i2c-gpio.h>
28#include <linux/io.h> 28#include <linux/io.h>
29
30#include <asm/mach-types.h> 29#include <asm/mach-types.h>
31#include <asm/mach/arch.h> 30#include <asm/mach/arch.h>
32#include <asm/mach/flash.h> 31#include <asm/mach/flash.h>
33#include <asm/mach/time.h> 32#include <asm/mach/time.h>
34#include <asm/gpio.h> 33#include <asm/gpio.h>
35 34
35#define NSLU2_SDA_PIN 7
36#define NSLU2_SCL_PIN 6
37
38/* NSLU2 Timer */
39#define NSLU2_FREQ 66000000
40
41/* Buttons */
42#define NSLU2_PB_GPIO 5 /* power button */
43#define NSLU2_PO_GPIO 8 /* power off */
44#define NSLU2_RB_GPIO 12 /* reset button */
45
46/* Buzzer */
47#define NSLU2_GPIO_BUZZ 4
48
49/* LEDs */
50#define NSLU2_LED_RED_GPIO 0
51#define NSLU2_LED_GRN_GPIO 1
52#define NSLU2_LED_DISK1_GPIO 3
53#define NSLU2_LED_DISK2_GPIO 2
54
36static struct flash_platform_data nslu2_flash_data = { 55static struct flash_platform_data nslu2_flash_data = {
37 .map_name = "cfi_probe", 56 .map_name = "cfi_probe",
38 .width = 2, 57 .width = 2,