diff options
Diffstat (limited to 'arch/sh')
-rw-r--r-- | arch/sh/boards/board-edosk7705.c | 2 | ||||
-rw-r--r-- | arch/sh/boards/board-edosk7760.c | 2 | ||||
-rw-r--r-- | arch/sh/boards/board-sh7785lcr.c | 2 | ||||
-rw-r--r-- | arch/sh/boards/mach-cayman/setup.c | 2 | ||||
-rw-r--r-- | arch/sh/boards/mach-landisk/irq.c | 59 | ||||
-rw-r--r-- | arch/sh/boards/mach-landisk/setup.c | 4 | ||||
-rw-r--r-- | arch/sh/boards/mach-r2d/setup.c | 2 | ||||
-rw-r--r-- | arch/sh/boards/mach-sdk7786/setup.c | 4 | ||||
-rw-r--r-- | arch/sh/boards/mach-se/7206/setup.c | 2 | ||||
-rw-r--r-- | arch/sh/boards/mach-se/7751/setup.c | 2 | ||||
-rw-r--r-- | arch/sh/boards/mach-sh03/setup.c | 2 | ||||
-rw-r--r-- | arch/sh/boot/romimage/mmcif-sh7724.c | 7 | ||||
-rw-r--r-- | arch/sh/configs/sh7757lcr_defconfig | 11 | ||||
-rw-r--r-- | arch/sh/drivers/pci/fixups-landisk.c | 28 | ||||
-rw-r--r-- | arch/sh/include/asm/io.h | 51 | ||||
-rw-r--r-- | arch/sh/include/mach-landisk/mach/iodata_landisk.h | 6 | ||||
-rw-r--r-- | arch/sh/kernel/cpu/sh4/probe.c | 1 |
17 files changed, 81 insertions, 106 deletions
diff --git a/arch/sh/boards/board-edosk7705.c b/arch/sh/boards/board-edosk7705.c index 4cb3bb74c36f..541d8a281035 100644 --- a/arch/sh/boards/board-edosk7705.c +++ b/arch/sh/boards/board-edosk7705.c | |||
@@ -66,7 +66,7 @@ static int __init init_edosk7705_devices(void) | |||
66 | return platform_add_devices(edosk7705_devices, | 66 | return platform_add_devices(edosk7705_devices, |
67 | ARRAY_SIZE(edosk7705_devices)); | 67 | ARRAY_SIZE(edosk7705_devices)); |
68 | } | 68 | } |
69 | __initcall(init_edosk7705_devices); | 69 | device_initcall(init_edosk7705_devices); |
70 | 70 | ||
71 | /* | 71 | /* |
72 | * The Machine Vector | 72 | * The Machine Vector |
diff --git a/arch/sh/boards/board-edosk7760.c b/arch/sh/boards/board-edosk7760.c index 35dc0994875d..f47ac82da876 100644 --- a/arch/sh/boards/board-edosk7760.c +++ b/arch/sh/boards/board-edosk7760.c | |||
@@ -182,7 +182,7 @@ static int __init init_edosk7760_devices(void) | |||
182 | return platform_add_devices(edosk7760_devices, | 182 | return platform_add_devices(edosk7760_devices, |
183 | ARRAY_SIZE(edosk7760_devices)); | 183 | ARRAY_SIZE(edosk7760_devices)); |
184 | } | 184 | } |
185 | __initcall(init_edosk7760_devices); | 185 | device_initcall(init_edosk7760_devices); |
186 | 186 | ||
187 | /* | 187 | /* |
188 | * The Machine Vector | 188 | * The Machine Vector |
diff --git a/arch/sh/boards/board-sh7785lcr.c b/arch/sh/boards/board-sh7785lcr.c index fe7e686c94ac..ee65ff05c558 100644 --- a/arch/sh/boards/board-sh7785lcr.c +++ b/arch/sh/boards/board-sh7785lcr.c | |||
@@ -284,7 +284,7 @@ static int __init sh7785lcr_devices_setup(void) | |||
284 | return platform_add_devices(sh7785lcr_devices, | 284 | return platform_add_devices(sh7785lcr_devices, |
285 | ARRAY_SIZE(sh7785lcr_devices)); | 285 | ARRAY_SIZE(sh7785lcr_devices)); |
286 | } | 286 | } |
287 | __initcall(sh7785lcr_devices_setup); | 287 | device_initcall(sh7785lcr_devices_setup); |
288 | 288 | ||
289 | /* Initialize IRQ setting */ | 289 | /* Initialize IRQ setting */ |
290 | void __init init_sh7785lcr_IRQ(void) | 290 | void __init init_sh7785lcr_IRQ(void) |
diff --git a/arch/sh/boards/mach-cayman/setup.c b/arch/sh/boards/mach-cayman/setup.c index 7e8216ac31bd..e89e8e122a26 100644 --- a/arch/sh/boards/mach-cayman/setup.c +++ b/arch/sh/boards/mach-cayman/setup.c | |||
@@ -165,7 +165,7 @@ static int __init smsc_superio_setup(void) | |||
165 | 165 | ||
166 | return 0; | 166 | return 0; |
167 | } | 167 | } |
168 | __initcall(smsc_superio_setup); | 168 | device_initcall(smsc_superio_setup); |
169 | 169 | ||
170 | static void __iomem *cayman_ioport_map(unsigned long port, unsigned int len) | 170 | static void __iomem *cayman_ioport_map(unsigned long port, unsigned int len) |
171 | { | 171 | { |
diff --git a/arch/sh/boards/mach-landisk/irq.c b/arch/sh/boards/mach-landisk/irq.c index e79412a40490..c00ace38db3f 100644 --- a/arch/sh/boards/mach-landisk/irq.c +++ b/arch/sh/boards/mach-landisk/irq.c | |||
@@ -1,9 +1,10 @@ | |||
1 | /* | 1 | /* |
2 | * arch/sh/boards/landisk/irq.c | 2 | * arch/sh/boards/mach-landisk/irq.c |
3 | * | 3 | * |
4 | * I-O DATA Device, Inc. LANDISK Support | 4 | * I-O DATA Device, Inc. LANDISK Support |
5 | * | 5 | * |
6 | * Copyright (C) 2005-2007 kogiidena | 6 | * Copyright (C) 2005-2007 kogiidena |
7 | * Copyright (C) 2011 Nobuhiro Iwamatsu | ||
7 | * | 8 | * |
8 | * Copyright (C) 2001 Ian da Silva, Jeremy Siegel | 9 | * Copyright (C) 2001 Ian da Silva, Jeremy Siegel |
9 | * Based largely on io_se.c. | 10 | * Based largely on io_se.c. |
@@ -12,44 +13,54 @@ | |||
12 | * License. See the file "COPYING" in the main directory of this archive | 13 | * License. See the file "COPYING" in the main directory of this archive |
13 | * for more details. | 14 | * for more details. |
14 | */ | 15 | */ |
16 | |||
15 | #include <linux/init.h> | 17 | #include <linux/init.h> |
16 | #include <linux/irq.h> | 18 | #include <linux/irq.h> |
17 | #include <linux/interrupt.h> | 19 | #include <linux/interrupt.h> |
18 | #include <linux/io.h> | 20 | #include <linux/io.h> |
19 | #include <mach-landisk/mach/iodata_landisk.h> | 21 | #include <mach-landisk/mach/iodata_landisk.h> |
20 | 22 | ||
21 | static void disable_landisk_irq(struct irq_data *data) | 23 | enum { |
22 | { | 24 | UNUSED = 0, |
23 | unsigned char mask = 0xff ^ (0x01 << (data->irq - 5)); | ||
24 | 25 | ||
25 | __raw_writeb(__raw_readb(PA_IMASK) & mask, PA_IMASK); | 26 | PCI_INTA, /* PCI int A */ |
26 | } | 27 | PCI_INTB, /* PCI int B */ |
27 | 28 | PCI_INTC, /* PCI int C */ | |
28 | static void enable_landisk_irq(struct irq_data *data) | 29 | PCI_INTD, /* PCI int D */ |
29 | { | 30 | ATA, /* ATA */ |
30 | unsigned char value = (0x01 << (data->irq - 5)); | 31 | FATA, /* CF */ |
32 | POWER, /* Power swtich */ | ||
33 | BUTTON, /* Button swtich */ | ||
34 | }; | ||
31 | 35 | ||
32 | __raw_writeb(__raw_readb(PA_IMASK) | value, PA_IMASK); | 36 | /* Vectors for LANDISK */ |
33 | } | 37 | static struct intc_vect vectors_landisk[] __initdata = { |
38 | INTC_IRQ(PCI_INTA, IRQ_PCIINTA), | ||
39 | INTC_IRQ(PCI_INTB, IRQ_PCIINTB), | ||
40 | INTC_IRQ(PCI_INTC, IRQ_PCIINTC), | ||
41 | INTC_IRQ(PCI_INTD, IRQ_PCIINTD), | ||
42 | INTC_IRQ(ATA, IRQ_ATA), | ||
43 | INTC_IRQ(FATA, IRQ_FATA), | ||
44 | INTC_IRQ(POWER, IRQ_POWER), | ||
45 | INTC_IRQ(BUTTON, IRQ_BUTTON), | ||
46 | }; | ||
34 | 47 | ||
35 | static struct irq_chip landisk_irq_chip __read_mostly = { | 48 | /* IRLMSK mask register layout for LANDISK */ |
36 | .name = "LANDISK", | 49 | static struct intc_mask_reg mask_registers_landisk[] __initdata = { |
37 | .irq_mask = disable_landisk_irq, | 50 | { PA_IMASK, 0, 8, /* IRLMSK */ |
38 | .irq_unmask = enable_landisk_irq, | 51 | { BUTTON, POWER, FATA, ATA, |
52 | PCI_INTD, PCI_INTC, PCI_INTB, PCI_INTA, | ||
53 | } | ||
54 | }, | ||
39 | }; | 55 | }; |
40 | 56 | ||
57 | static DECLARE_INTC_DESC(intc_desc_landisk, "landisk", vectors_landisk, NULL, | ||
58 | mask_registers_landisk, NULL, NULL); | ||
41 | /* | 59 | /* |
42 | * Initialize IRQ setting | 60 | * Initialize IRQ setting |
43 | */ | 61 | */ |
44 | void __init init_landisk_IRQ(void) | 62 | void __init init_landisk_IRQ(void) |
45 | { | 63 | { |
46 | int i; | 64 | register_intc_controller(&intc_desc_landisk); |
47 | |||
48 | for (i = 5; i < 14; i++) { | ||
49 | disable_irq_nosync(i); | ||
50 | set_irq_chip_and_handler_name(i, &landisk_irq_chip, | ||
51 | handle_level_irq, "level"); | ||
52 | enable_landisk_irq(irq_get_irq_data(i)); | ||
53 | } | ||
54 | __raw_writeb(0x00, PA_PWRINT_CLR); | 65 | __raw_writeb(0x00, PA_PWRINT_CLR); |
55 | } | 66 | } |
diff --git a/arch/sh/boards/mach-landisk/setup.c b/arch/sh/boards/mach-landisk/setup.c index 50337acc18c5..94186cf079b6 100644 --- a/arch/sh/boards/mach-landisk/setup.c +++ b/arch/sh/boards/mach-landisk/setup.c | |||
@@ -21,8 +21,6 @@ | |||
21 | #include <mach-landisk/mach/iodata_landisk.h> | 21 | #include <mach-landisk/mach/iodata_landisk.h> |
22 | #include <asm/io.h> | 22 | #include <asm/io.h> |
23 | 23 | ||
24 | void init_landisk_IRQ(void); | ||
25 | |||
26 | static void landisk_power_off(void) | 24 | static void landisk_power_off(void) |
27 | { | 25 | { |
28 | __raw_writeb(0x01, PA_SHUTDOWN); | 26 | __raw_writeb(0x01, PA_SHUTDOWN); |
@@ -83,7 +81,7 @@ static int __init landisk_devices_setup(void) | |||
83 | ARRAY_SIZE(landisk_devices)); | 81 | ARRAY_SIZE(landisk_devices)); |
84 | } | 82 | } |
85 | 83 | ||
86 | __initcall(landisk_devices_setup); | 84 | device_initcall(landisk_devices_setup); |
87 | 85 | ||
88 | static void __init landisk_setup(char **cmdline_p) | 86 | static void __init landisk_setup(char **cmdline_p) |
89 | { | 87 | { |
diff --git a/arch/sh/boards/mach-r2d/setup.c b/arch/sh/boards/mach-r2d/setup.c index b84df6a3a93c..4b98a5251f83 100644 --- a/arch/sh/boards/mach-r2d/setup.c +++ b/arch/sh/boards/mach-r2d/setup.c | |||
@@ -258,7 +258,7 @@ static int __init rts7751r2d_devices_setup(void) | |||
258 | return platform_add_devices(rts7751r2d_devices, | 258 | return platform_add_devices(rts7751r2d_devices, |
259 | ARRAY_SIZE(rts7751r2d_devices)); | 259 | ARRAY_SIZE(rts7751r2d_devices)); |
260 | } | 260 | } |
261 | __initcall(rts7751r2d_devices_setup); | 261 | device_initcall(rts7751r2d_devices_setup); |
262 | 262 | ||
263 | static void rts7751r2d_power_off(void) | 263 | static void rts7751r2d_power_off(void) |
264 | { | 264 | { |
diff --git a/arch/sh/boards/mach-sdk7786/setup.c b/arch/sh/boards/mach-sdk7786/setup.c index 75e4ddbbec3e..1521aa75ee3a 100644 --- a/arch/sh/boards/mach-sdk7786/setup.c +++ b/arch/sh/boards/mach-sdk7786/setup.c | |||
@@ -15,13 +15,13 @@ | |||
15 | #include <linux/i2c.h> | 15 | #include <linux/i2c.h> |
16 | #include <linux/irq.h> | 16 | #include <linux/irq.h> |
17 | #include <linux/clk.h> | 17 | #include <linux/clk.h> |
18 | #include <linux/clkdev.h> | ||
18 | #include <mach/fpga.h> | 19 | #include <mach/fpga.h> |
19 | #include <mach/irq.h> | 20 | #include <mach/irq.h> |
20 | #include <asm/machvec.h> | 21 | #include <asm/machvec.h> |
21 | #include <asm/heartbeat.h> | 22 | #include <asm/heartbeat.h> |
22 | #include <asm/sizes.h> | 23 | #include <asm/sizes.h> |
23 | #include <asm/clock.h> | 24 | #include <asm/clock.h> |
24 | #include <asm/clkdev.h> | ||
25 | #include <asm/reboot.h> | 25 | #include <asm/reboot.h> |
26 | #include <asm/smp-ops.h> | 26 | #include <asm/smp-ops.h> |
27 | 27 | ||
@@ -135,7 +135,7 @@ static int __init sdk7786_devices_setup(void) | |||
135 | 135 | ||
136 | return sdk7786_i2c_setup(); | 136 | return sdk7786_i2c_setup(); |
137 | } | 137 | } |
138 | __initcall(sdk7786_devices_setup); | 138 | device_initcall(sdk7786_devices_setup); |
139 | 139 | ||
140 | static int sdk7786_mode_pins(void) | 140 | static int sdk7786_mode_pins(void) |
141 | { | 141 | { |
diff --git a/arch/sh/boards/mach-se/7206/setup.c b/arch/sh/boards/mach-se/7206/setup.c index 33039e0dc568..8ab8330e3fd1 100644 --- a/arch/sh/boards/mach-se/7206/setup.c +++ b/arch/sh/boards/mach-se/7206/setup.c | |||
@@ -77,7 +77,7 @@ static int __init se7206_devices_setup(void) | |||
77 | { | 77 | { |
78 | return platform_add_devices(se7206_devices, ARRAY_SIZE(se7206_devices)); | 78 | return platform_add_devices(se7206_devices, ARRAY_SIZE(se7206_devices)); |
79 | } | 79 | } |
80 | __initcall(se7206_devices_setup); | 80 | device_initcall(se7206_devices_setup); |
81 | 81 | ||
82 | static int se7206_mode_pins(void) | 82 | static int se7206_mode_pins(void) |
83 | { | 83 | { |
diff --git a/arch/sh/boards/mach-se/7751/setup.c b/arch/sh/boards/mach-se/7751/setup.c index 9fbc51beb181..4ed60c5e221f 100644 --- a/arch/sh/boards/mach-se/7751/setup.c +++ b/arch/sh/boards/mach-se/7751/setup.c | |||
@@ -48,7 +48,7 @@ static int __init se7751_devices_setup(void) | |||
48 | { | 48 | { |
49 | return platform_add_devices(se7751_devices, ARRAY_SIZE(se7751_devices)); | 49 | return platform_add_devices(se7751_devices, ARRAY_SIZE(se7751_devices)); |
50 | } | 50 | } |
51 | __initcall(se7751_devices_setup); | 51 | device_initcall(se7751_devices_setup); |
52 | 52 | ||
53 | /* | 53 | /* |
54 | * The Machine Vector | 54 | * The Machine Vector |
diff --git a/arch/sh/boards/mach-sh03/setup.c b/arch/sh/boards/mach-sh03/setup.c index af4a0c012a96..d4f79b2a6514 100644 --- a/arch/sh/boards/mach-sh03/setup.c +++ b/arch/sh/boards/mach-sh03/setup.c | |||
@@ -96,7 +96,7 @@ static int __init sh03_devices_setup(void) | |||
96 | 96 | ||
97 | return platform_add_devices(sh03_devices, ARRAY_SIZE(sh03_devices)); | 97 | return platform_add_devices(sh03_devices, ARRAY_SIZE(sh03_devices)); |
98 | } | 98 | } |
99 | __initcall(sh03_devices_setup); | 99 | device_initcall(sh03_devices_setup); |
100 | 100 | ||
101 | static struct sh_machine_vector mv_sh03 __initmv = { | 101 | static struct sh_machine_vector mv_sh03 __initmv = { |
102 | .mv_name = "Interface (CTP/PCI-SH03)", | 102 | .mv_name = "Interface (CTP/PCI-SH03)", |
diff --git a/arch/sh/boot/romimage/mmcif-sh7724.c b/arch/sh/boot/romimage/mmcif-sh7724.c index 14863d7292cb..c84e7831018d 100644 --- a/arch/sh/boot/romimage/mmcif-sh7724.c +++ b/arch/sh/boot/romimage/mmcif-sh7724.c | |||
@@ -21,9 +21,6 @@ | |||
21 | #define HIZCRC 0xa405015c | 21 | #define HIZCRC 0xa405015c |
22 | #define DRVCRA 0xa405018a | 22 | #define DRVCRA 0xa405018a |
23 | 23 | ||
24 | enum { MMCIF_PROGRESS_ENTER, MMCIF_PROGRESS_INIT, | ||
25 | MMCIF_PROGRESS_LOAD, MMCIF_PROGRESS_DONE }; | ||
26 | |||
27 | /* SH7724 specific MMCIF loader | 24 | /* SH7724 specific MMCIF loader |
28 | * | 25 | * |
29 | * loads the romImage from an MMC card starting from block 512 | 26 | * loads the romImage from an MMC card starting from block 512 |
@@ -63,7 +60,9 @@ asmlinkage void mmcif_loader(unsigned char *buf, unsigned long no_bytes) | |||
63 | mmcif_update_progress(MMCIF_PROGRESS_LOAD); | 60 | mmcif_update_progress(MMCIF_PROGRESS_LOAD); |
64 | 61 | ||
65 | /* load kernel via MMCIF interface */ | 62 | /* load kernel via MMCIF interface */ |
66 | sh_mmcif_boot_slurp(MMCIF_BASE, buf, no_bytes); | 63 | sh_mmcif_boot_do_read(MMCIF_BASE, 512, |
64 | (no_bytes + SH_MMCIF_BBS - 1) / SH_MMCIF_BBS, | ||
65 | buf); | ||
67 | 66 | ||
68 | /* disable clock to the MMCIF hardware block */ | 67 | /* disable clock to the MMCIF hardware block */ |
69 | __raw_writel(__raw_readl(MSTPCR2) | 0x20000000, MSTPCR2); | 68 | __raw_writel(__raw_readl(MSTPCR2) | 0x20000000, MSTPCR2); |
diff --git a/arch/sh/configs/sh7757lcr_defconfig b/arch/sh/configs/sh7757lcr_defconfig index 273f3fa198f7..5f7f667b9f3b 100644 --- a/arch/sh/configs/sh7757lcr_defconfig +++ b/arch/sh/configs/sh7757lcr_defconfig | |||
@@ -39,21 +39,15 @@ CONFIG_IPV6=y | |||
39 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" | 39 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" |
40 | # CONFIG_FW_LOADER is not set | 40 | # CONFIG_FW_LOADER is not set |
41 | CONFIG_BLK_DEV_RAM=y | 41 | CONFIG_BLK_DEV_RAM=y |
42 | # CONFIG_MISC_DEVICES is not set | ||
43 | CONFIG_NETDEVICES=y | 42 | CONFIG_NETDEVICES=y |
44 | CONFIG_PHYLIB=y | ||
45 | CONFIG_VITESSE_PHY=y | 43 | CONFIG_VITESSE_PHY=y |
46 | CONFIG_MDIO_BITBANG=y | ||
47 | CONFIG_NET_ETHERNET=y | 44 | CONFIG_NET_ETHERNET=y |
48 | CONFIG_MII=y | 45 | CONFIG_SH_ETH=y |
49 | # CONFIG_NETDEV_10000 is not set | 46 | # CONFIG_NETDEV_10000 is not set |
50 | # CONFIG_WLAN is not set | 47 | # CONFIG_WLAN is not set |
51 | # CONFIG_KEYBOARD_ATKBD is not set | 48 | # CONFIG_KEYBOARD_ATKBD is not set |
52 | # CONFIG_MOUSE_PS2 is not set | 49 | # CONFIG_MOUSE_PS2 is not set |
53 | # CONFIG_SERIO is not set | 50 | # CONFIG_SERIO is not set |
54 | CONFIG_SERIAL_8250=y | ||
55 | CONFIG_SERIAL_8250_CONSOLE=y | ||
56 | CONFIG_SERIAL_8250_NR_UARTS=2 | ||
57 | CONFIG_SERIAL_SH_SCI=y | 51 | CONFIG_SERIAL_SH_SCI=y |
58 | CONFIG_SERIAL_SH_SCI_NR_UARTS=3 | 52 | CONFIG_SERIAL_SH_SCI_NR_UARTS=3 |
59 | CONFIG_SERIAL_SH_SCI_CONSOLE=y | 53 | CONFIG_SERIAL_SH_SCI_CONSOLE=y |
@@ -63,7 +57,6 @@ CONFIG_SERIAL_SH_SCI_CONSOLE=y | |||
63 | # CONFIG_USB_SUPPORT is not set | 57 | # CONFIG_USB_SUPPORT is not set |
64 | CONFIG_EXT2_FS=y | 58 | CONFIG_EXT2_FS=y |
65 | CONFIG_EXT3_FS=y | 59 | CONFIG_EXT3_FS=y |
66 | CONFIG_INOTIFY=y | ||
67 | CONFIG_ISO9660_FS=y | 60 | CONFIG_ISO9660_FS=y |
68 | CONFIG_VFAT_FS=y | 61 | CONFIG_VFAT_FS=y |
69 | CONFIG_PROC_KCORE=y | 62 | CONFIG_PROC_KCORE=y |
@@ -76,10 +69,8 @@ CONFIG_NLS_CODEPAGE_437=y | |||
76 | CONFIG_NLS_CODEPAGE_932=y | 69 | CONFIG_NLS_CODEPAGE_932=y |
77 | CONFIG_NLS_ISO8859_1=y | 70 | CONFIG_NLS_ISO8859_1=y |
78 | CONFIG_DEBUG_KERNEL=y | 71 | CONFIG_DEBUG_KERNEL=y |
79 | # CONFIG_DETECT_SOFTLOCKUP is not set | ||
80 | # CONFIG_SCHED_DEBUG is not set | 72 | # CONFIG_SCHED_DEBUG is not set |
81 | # CONFIG_DEBUG_BUGVERBOSE is not set | 73 | # CONFIG_DEBUG_BUGVERBOSE is not set |
82 | CONFIG_DEBUG_INFO=y | 74 | CONFIG_DEBUG_INFO=y |
83 | # CONFIG_RCU_CPU_STALL_DETECTOR is not set | ||
84 | # CONFIG_FTRACE is not set | 75 | # CONFIG_FTRACE is not set |
85 | # CONFIG_CRYPTO_ANSI_CPRNG is not set | 76 | # CONFIG_CRYPTO_ANSI_CPRNG is not set |
diff --git a/arch/sh/drivers/pci/fixups-landisk.c b/arch/sh/drivers/pci/fixups-landisk.c index bb1a6bb5149e..95c6e2d94a0a 100644 --- a/arch/sh/drivers/pci/fixups-landisk.c +++ b/arch/sh/drivers/pci/fixups-landisk.c | |||
@@ -1,9 +1,10 @@ | |||
1 | /* | 1 | /* |
2 | * arch/sh/drivers/pci/ops-landisk.c | 2 | * arch/sh/drivers/pci/fixups-landisk.c |
3 | * | 3 | * |
4 | * PCI initialization for the I-O DATA Device, Inc. LANDISK board | 4 | * PCI initialization for the I-O DATA Device, Inc. LANDISK board |
5 | * | 5 | * |
6 | * Copyright (C) 2006 kogiidena | 6 | * Copyright (C) 2006 kogiidena |
7 | * Copyright (C) 2010 Nobuhiro Iwamatsu | ||
7 | * | 8 | * |
8 | * May be copied or modified under the terms of the GNU General Public | 9 | * May be copied or modified under the terms of the GNU General Public |
9 | * License. See linux/COPYING for more information. | 10 | * License. See linux/COPYING for more information. |
@@ -15,6 +16,9 @@ | |||
15 | #include <linux/pci.h> | 16 | #include <linux/pci.h> |
16 | #include "pci-sh4.h" | 17 | #include "pci-sh4.h" |
17 | 18 | ||
19 | #define PCIMCR_MRSET_OFF 0xBFFFFFFF | ||
20 | #define PCIMCR_RFSH_OFF 0xFFFFFFFB | ||
21 | |||
18 | int pcibios_map_platform_irq(struct pci_dev *pdev, u8 slot, u8 pin) | 22 | int pcibios_map_platform_irq(struct pci_dev *pdev, u8 slot, u8 pin) |
19 | { | 23 | { |
20 | /* | 24 | /* |
@@ -26,9 +30,29 @@ int pcibios_map_platform_irq(struct pci_dev *pdev, u8 slot, u8 pin) | |||
26 | int irq = ((slot + pin - 1) & 0x3) + 5; | 30 | int irq = ((slot + pin - 1) & 0x3) + 5; |
27 | 31 | ||
28 | if ((slot | (pin - 1)) > 0x3) { | 32 | if ((slot | (pin - 1)) > 0x3) { |
29 | printk("PCI: Bad IRQ mapping request for slot %d pin %c\n", | 33 | printk(KERN_WARNING "PCI: Bad IRQ mapping request for slot %d pin %c\n", |
30 | slot, pin - 1 + 'A'); | 34 | slot, pin - 1 + 'A'); |
31 | return -1; | 35 | return -1; |
32 | } | 36 | } |
33 | return irq; | 37 | return irq; |
34 | } | 38 | } |
39 | |||
40 | int pci_fixup_pcic(struct pci_channel *chan) | ||
41 | { | ||
42 | unsigned long bcr1, mcr; | ||
43 | |||
44 | bcr1 = __raw_readl(SH7751_BCR1); | ||
45 | bcr1 |= 0x40080000; /* Enable Bit 19 BREQEN, set PCIC to slave */ | ||
46 | pci_write_reg(chan, bcr1, SH4_PCIBCR1); | ||
47 | |||
48 | mcr = __raw_readl(SH7751_MCR); | ||
49 | mcr = (mcr & PCIMCR_MRSET_OFF) & PCIMCR_RFSH_OFF; | ||
50 | pci_write_reg(chan, mcr, SH4_PCIMCR); | ||
51 | |||
52 | pci_write_reg(chan, 0x0c000000, SH7751_PCICONF5); | ||
53 | pci_write_reg(chan, 0xd0000000, SH7751_PCICONF6); | ||
54 | pci_write_reg(chan, 0x0c000000, SH4_PCILAR0); | ||
55 | pci_write_reg(chan, 0x00000000, SH4_PCILAR1); | ||
56 | |||
57 | return 0; | ||
58 | } | ||
diff --git a/arch/sh/include/asm/io.h b/arch/sh/include/asm/io.h index 89ab2c57a4c2..70c1186b5088 100644 --- a/arch/sh/include/asm/io.h +++ b/arch/sh/include/asm/io.h | |||
@@ -11,11 +11,6 @@ | |||
11 | * | 11 | * |
12 | * While read{b,w,l,q} and write{b,w,l,q} contain memory barriers | 12 | * While read{b,w,l,q} and write{b,w,l,q} contain memory barriers |
13 | * automatically, there are also __raw versions, which do not. | 13 | * automatically, there are also __raw versions, which do not. |
14 | * | ||
15 | * Historically, we have also had ctrl_in{b,w,l,q}/ctrl_out{b,w,l,q} for | ||
16 | * SuperH specific I/O (raw I/O to on-chip CPU peripherals). In practice | ||
17 | * these have the same semantics as the __raw variants, and as such, all | ||
18 | * new code should be using the __raw versions. | ||
19 | */ | 14 | */ |
20 | #include <linux/errno.h> | 15 | #include <linux/errno.h> |
21 | #include <asm/cache.h> | 16 | #include <asm/cache.h> |
@@ -231,52 +226,6 @@ __BUILD_IOPORT_STRING(q, u64) | |||
231 | 226 | ||
232 | #endif | 227 | #endif |
233 | 228 | ||
234 | /* | ||
235 | * Legacy SuperH on-chip I/O functions | ||
236 | * | ||
237 | * These are all deprecated, all new (and especially cross-platform) code | ||
238 | * should be using the __raw_xxx() routines directly. | ||
239 | */ | ||
240 | static inline u8 __deprecated ctrl_inb(unsigned long addr) | ||
241 | { | ||
242 | return __raw_readb(addr); | ||
243 | } | ||
244 | |||
245 | static inline u16 __deprecated ctrl_inw(unsigned long addr) | ||
246 | { | ||
247 | return __raw_readw(addr); | ||
248 | } | ||
249 | |||
250 | static inline u32 __deprecated ctrl_inl(unsigned long addr) | ||
251 | { | ||
252 | return __raw_readl(addr); | ||
253 | } | ||
254 | |||
255 | static inline u64 __deprecated ctrl_inq(unsigned long addr) | ||
256 | { | ||
257 | return __raw_readq(addr); | ||
258 | } | ||
259 | |||
260 | static inline void __deprecated ctrl_outb(u8 v, unsigned long addr) | ||
261 | { | ||
262 | __raw_writeb(v, addr); | ||
263 | } | ||
264 | |||
265 | static inline void __deprecated ctrl_outw(u16 v, unsigned long addr) | ||
266 | { | ||
267 | __raw_writew(v, addr); | ||
268 | } | ||
269 | |||
270 | static inline void __deprecated ctrl_outl(u32 v, unsigned long addr) | ||
271 | { | ||
272 | __raw_writel(v, addr); | ||
273 | } | ||
274 | |||
275 | static inline void __deprecated ctrl_outq(u64 v, unsigned long addr) | ||
276 | { | ||
277 | __raw_writeq(v, addr); | ||
278 | } | ||
279 | |||
280 | #define IO_SPACE_LIMIT 0xffffffff | 229 | #define IO_SPACE_LIMIT 0xffffffff |
281 | 230 | ||
282 | /* synco on SH-4A, otherwise a nop */ | 231 | /* synco on SH-4A, otherwise a nop */ |
diff --git a/arch/sh/include/mach-landisk/mach/iodata_landisk.h b/arch/sh/include/mach-landisk/mach/iodata_landisk.h index 6fb04ab38b9f..f432773a9571 100644 --- a/arch/sh/include/mach-landisk/mach/iodata_landisk.h +++ b/arch/sh/include/mach-landisk/mach/iodata_landisk.h | |||
@@ -2,7 +2,7 @@ | |||
2 | #define __ASM_SH_IODATA_LANDISK_H | 2 | #define __ASM_SH_IODATA_LANDISK_H |
3 | 3 | ||
4 | /* | 4 | /* |
5 | * linux/include/asm-sh/landisk/iodata_landisk.h | 5 | * arch/sh/include/mach-landisk/mach/iodata_landisk.h |
6 | * | 6 | * |
7 | * Copyright (C) 2000 Atom Create Engineering Co., Ltd. | 7 | * Copyright (C) 2000 Atom Create Engineering Co., Ltd. |
8 | * | 8 | * |
@@ -27,7 +27,7 @@ | |||
27 | 27 | ||
28 | #define IRQ_PCIINTA 5 /* PCI INTA IRQ */ | 28 | #define IRQ_PCIINTA 5 /* PCI INTA IRQ */ |
29 | #define IRQ_PCIINTB 6 /* PCI INTB IRQ */ | 29 | #define IRQ_PCIINTB 6 /* PCI INTB IRQ */ |
30 | #define IRQ_PCIINDC 7 /* PCI INTC IRQ */ | 30 | #define IRQ_PCIINTC 7 /* PCI INTC IRQ */ |
31 | #define IRQ_PCIINTD 8 /* PCI INTD IRQ */ | 31 | #define IRQ_PCIINTD 8 /* PCI INTD IRQ */ |
32 | #define IRQ_ATA 9 /* ATA IRQ */ | 32 | #define IRQ_ATA 9 /* ATA IRQ */ |
33 | #define IRQ_FATA 10 /* FATA IRQ */ | 33 | #define IRQ_FATA 10 /* FATA IRQ */ |
@@ -35,6 +35,8 @@ | |||
35 | #define IRQ_BUTTON 12 /* USL-5P Button IRQ */ | 35 | #define IRQ_BUTTON 12 /* USL-5P Button IRQ */ |
36 | #define IRQ_FAULT 13 /* USL-5P Fault IRQ */ | 36 | #define IRQ_FAULT 13 /* USL-5P Fault IRQ */ |
37 | 37 | ||
38 | void init_landisk_IRQ(void); | ||
39 | |||
38 | #define __IO_PREFIX landisk | 40 | #define __IO_PREFIX landisk |
39 | #include <asm/io_generic.h> | 41 | #include <asm/io_generic.h> |
40 | 42 | ||
diff --git a/arch/sh/kernel/cpu/sh4/probe.c b/arch/sh/kernel/cpu/sh4/probe.c index b93458f33b74..b1edc90d482b 100644 --- a/arch/sh/kernel/cpu/sh4/probe.c +++ b/arch/sh/kernel/cpu/sh4/probe.c | |||
@@ -151,6 +151,7 @@ void __cpuinit cpu_probe(void) | |||
151 | boot_cpu_data.flags |= CPU_HAS_L2_CACHE; | 151 | boot_cpu_data.flags |= CPU_HAS_L2_CACHE; |
152 | break; | 152 | break; |
153 | case 0x10: | 153 | case 0x10: |
154 | case 0x11: | ||
154 | boot_cpu_data.type = CPU_SH7757; | 155 | boot_cpu_data.type = CPU_SH7757; |
155 | break; | 156 | break; |
156 | } | 157 | } |