diff options
81 files changed, 3352 insertions, 1830 deletions
diff --git a/arch/sh/Kconfig b/arch/sh/Kconfig index d87d4bf88803..b3400b5ad5c6 100644 --- a/arch/sh/Kconfig +++ b/arch/sh/Kconfig | |||
| @@ -93,6 +93,9 @@ config ARCH_NO_VIRT_TO_BUS | |||
| 93 | config ARCH_SUPPORTS_AOUT | 93 | config ARCH_SUPPORTS_AOUT |
| 94 | def_bool y | 94 | def_bool y |
| 95 | 95 | ||
| 96 | config IO_TRAPPED | ||
| 97 | bool | ||
| 98 | |||
| 96 | source "init/Kconfig" | 99 | source "init/Kconfig" |
| 97 | 100 | ||
| 98 | menu "System type" | 101 | menu "System type" |
| @@ -312,6 +315,13 @@ config CPU_SUBTYPE_SH7722 | |||
| 312 | select ARCH_SPARSEMEM_ENABLE | 315 | select ARCH_SPARSEMEM_ENABLE |
| 313 | select SYS_SUPPORTS_NUMA | 316 | select SYS_SUPPORTS_NUMA |
| 314 | 317 | ||
| 318 | config CPU_SUBTYPE_SH7366 | ||
| 319 | bool "Support SH7366 processor" | ||
| 320 | select CPU_SH4AL_DSP | ||
| 321 | select CPU_SHX2 | ||
| 322 | select ARCH_SPARSEMEM_ENABLE | ||
| 323 | select SYS_SUPPORTS_NUMA | ||
| 324 | |||
| 315 | # SH-5 Processor Support | 325 | # SH-5 Processor Support |
| 316 | 326 | ||
| 317 | config CPU_SUBTYPE_SH5_101 | 327 | config CPU_SUBTYPE_SH5_101 |
| @@ -456,6 +466,7 @@ config SH_RTS7751R2D | |||
| 456 | bool "RTS7751R2D" | 466 | bool "RTS7751R2D" |
| 457 | depends on CPU_SUBTYPE_SH7751R | 467 | depends on CPU_SUBTYPE_SH7751R |
| 458 | select SYS_SUPPORTS_PCI | 468 | select SYS_SUPPORTS_PCI |
| 469 | select IO_TRAPPED | ||
| 459 | help | 470 | help |
| 460 | Select RTS7751R2D if configuring for a Renesas Technology | 471 | Select RTS7751R2D if configuring for a Renesas Technology |
| 461 | Sales SH-Graphics board. | 472 | Sales SH-Graphics board. |
| @@ -472,6 +483,14 @@ config SH_HIGHLANDER | |||
| 472 | bool "Highlander" | 483 | bool "Highlander" |
| 473 | depends on CPU_SUBTYPE_SH7780 || CPU_SUBTYPE_SH7785 | 484 | depends on CPU_SUBTYPE_SH7780 || CPU_SUBTYPE_SH7785 |
| 474 | select SYS_SUPPORTS_PCI | 485 | select SYS_SUPPORTS_PCI |
| 486 | select IO_TRAPPED | ||
| 487 | |||
| 488 | config SH_MIGOR | ||
| 489 | bool "Migo-R" | ||
| 490 | depends on CPU_SUBTYPE_SH7722 | ||
| 491 | help | ||
| 492 | Select Migo-R if configuring for the SH7722 Migo-R platform | ||
| 493 | by Renesas System Solutions Asia Pte. Ltd. | ||
| 475 | 494 | ||
| 476 | config SH_EDOSK7705 | 495 | config SH_EDOSK7705 |
| 477 | bool "EDOSK7705" | 496 | bool "EDOSK7705" |
diff --git a/arch/sh/Kconfig.cpu b/arch/sh/Kconfig.cpu index d850184d0694..0e27fe3b182b 100644 --- a/arch/sh/Kconfig.cpu +++ b/arch/sh/Kconfig.cpu | |||
| @@ -12,6 +12,7 @@ config CPU_LITTLE_ENDIAN | |||
| 12 | 12 | ||
| 13 | config CPU_BIG_ENDIAN | 13 | config CPU_BIG_ENDIAN |
| 14 | bool "Big Endian" | 14 | bool "Big Endian" |
| 15 | depends on !CPU_SH5 | ||
| 15 | 16 | ||
| 16 | endchoice | 17 | endchoice |
| 17 | 18 | ||
| @@ -87,9 +88,6 @@ config SH64_ID2815_WORKAROUND | |||
| 87 | config CPU_HAS_INTEVT | 88 | config CPU_HAS_INTEVT |
| 88 | bool | 89 | bool |
| 89 | 90 | ||
| 90 | config CPU_HAS_MASKREG_IRQ | ||
| 91 | bool | ||
| 92 | |||
| 93 | config CPU_HAS_IPR_IRQ | 91 | config CPU_HAS_IPR_IRQ |
| 94 | bool | 92 | bool |
| 95 | 93 | ||
diff --git a/arch/sh/Kconfig.debug b/arch/sh/Kconfig.debug index f7c716166ce8..5dcb74b947a9 100644 --- a/arch/sh/Kconfig.debug +++ b/arch/sh/Kconfig.debug | |||
| @@ -29,7 +29,8 @@ config EARLY_SCIF_CONSOLE | |||
| 29 | config EARLY_SCIF_CONSOLE_PORT | 29 | config EARLY_SCIF_CONSOLE_PORT |
| 30 | hex | 30 | hex |
| 31 | depends on EARLY_SCIF_CONSOLE | 31 | depends on EARLY_SCIF_CONSOLE |
| 32 | default "0xffe00000" if CPU_SUBTYPE_SH7780 || CPU_SUBTYPE_SH7763 | 32 | default "0xffe00000" if CPU_SUBTYPE_SH7780 || CPU_SUBTYPE_SH7763 |
| 33 | default "0xffe00000" if CPU_SUBTYPE_SH7722 || CPU_SUBTYPE_SH7366 | ||
| 33 | default "0xffea0000" if CPU_SUBTYPE_SH7785 | 34 | default "0xffea0000" if CPU_SUBTYPE_SH7785 |
| 34 | default "0xfffe8000" if CPU_SUBTYPE_SH7203 | 35 | default "0xfffe8000" if CPU_SUBTYPE_SH7203 |
| 35 | default "0xfffe9800" if CPU_SUBTYPE_SH7206 || CPU_SUBTYPE_SH7263 | 36 | default "0xfffe9800" if CPU_SUBTYPE_SH7206 || CPU_SUBTYPE_SH7263 |
diff --git a/arch/sh/Makefile b/arch/sh/Makefile index 17fc36186bf4..81381e5773c8 100644 --- a/arch/sh/Makefile +++ b/arch/sh/Makefile | |||
| @@ -116,6 +116,7 @@ machdir-$(CONFIG_SH_RTS7751R2D) += renesas/rts7751r2d | |||
| 116 | machdir-$(CONFIG_SH_7751_SYSTEMH) += renesas/systemh | 116 | machdir-$(CONFIG_SH_7751_SYSTEMH) += renesas/systemh |
| 117 | machdir-$(CONFIG_SH_EDOSK7705) += renesas/edosk7705 | 117 | machdir-$(CONFIG_SH_EDOSK7705) += renesas/edosk7705 |
| 118 | machdir-$(CONFIG_SH_HIGHLANDER) += renesas/r7780rp | 118 | machdir-$(CONFIG_SH_HIGHLANDER) += renesas/r7780rp |
| 119 | machdir-$(CONFIG_SH_MIGOR) += renesas/migor | ||
| 119 | machdir-$(CONFIG_SH_SDK7780) += renesas/sdk7780 | 120 | machdir-$(CONFIG_SH_SDK7780) += renesas/sdk7780 |
| 120 | machdir-$(CONFIG_SH_7710VOIPGW) += renesas/sh7710voipgw | 121 | machdir-$(CONFIG_SH_7710VOIPGW) += renesas/sh7710voipgw |
| 121 | machdir-$(CONFIG_SH_X3PROTO) += renesas/x3proto | 122 | machdir-$(CONFIG_SH_X3PROTO) += renesas/x3proto |
diff --git a/arch/sh/boards/renesas/migor/Makefile b/arch/sh/boards/renesas/migor/Makefile new file mode 100644 index 000000000000..77037567633b --- /dev/null +++ b/arch/sh/boards/renesas/migor/Makefile | |||
| @@ -0,0 +1 @@ | |||
| obj-y := setup.o | |||
diff --git a/arch/sh/boards/renesas/migor/setup.c b/arch/sh/boards/renesas/migor/setup.c new file mode 100644 index 000000000000..21ab8c8fb590 --- /dev/null +++ b/arch/sh/boards/renesas/migor/setup.c | |||
| @@ -0,0 +1,61 @@ | |||
| 1 | /* | ||
| 2 | * Renesas System Solutions Asia Pte. Ltd - Migo-R | ||
| 3 | * | ||
| 4 | * Copyright (C) 2008 Magnus Damm | ||
| 5 | * | ||
| 6 | * This file is subject to the terms and conditions of the GNU General Public | ||
| 7 | * License. See the file "COPYING" in the main directory of this archive | ||
| 8 | * for more details. | ||
| 9 | */ | ||
| 10 | #include <linux/init.h> | ||
| 11 | #include <linux/platform_device.h> | ||
| 12 | #include <linux/interrupt.h> | ||
| 13 | #include <asm/machvec.h> | ||
| 14 | #include <asm/io.h> | ||
| 15 | |||
| 16 | /* Address IRQ Size Bus Description | ||
| 17 | * 0x00000000 64MB 16 NOR Flash (SP29PL256N) | ||
| 18 | * 0x0c000000 64MB 64 SDRAM (2xK4M563233G) | ||
| 19 | * 0x10000000 IRQ0 16 Ethernet (SMC91C111) | ||
| 20 | * 0x14000000 IRQ4 16 USB 2.0 Host Controller (M66596) | ||
| 21 | * 0x18000000 8GB 8 NAND Flash (K9K8G08U0A) | ||
| 22 | */ | ||
| 23 | |||
| 24 | static struct resource smc91x_eth_resources[] = { | ||
| 25 | [0] = { | ||
| 26 | .name = "smc91x-regs" , | ||
| 27 | .start = P2SEGADDR(0x10000300), | ||
| 28 | .end = P2SEGADDR(0x1000030f), | ||
| 29 | .flags = IORESOURCE_MEM, | ||
| 30 | }, | ||
| 31 | [1] = { | ||
| 32 | .start = 32, /* IRQ0 */ | ||
| 33 | .flags = IORESOURCE_IRQ | IRQF_TRIGGER_HIGH, | ||
| 34 | }, | ||
| 35 | }; | ||
| 36 | |||
| 37 | static struct platform_device smc91x_eth_device = { | ||
| 38 | .name = "smc91x", | ||
| 39 | .num_resources = ARRAY_SIZE(smc91x_eth_resources), | ||
| 40 | .resource = smc91x_eth_resources, | ||
| 41 | }; | ||
| 42 | |||
| 43 | static struct platform_device *migor_devices[] __initdata = { | ||
| 44 | &smc91x_eth_device, | ||
| 45 | }; | ||
| 46 | |||
| 47 | static int __init migor_devices_setup(void) | ||
| 48 | { | ||
| 49 | return platform_add_devices(migor_devices, ARRAY_SIZE(migor_devices)); | ||
| 50 | } | ||
| 51 | __initcall(migor_devices_setup); | ||
| 52 | |||
| 53 | static void __init migor_setup(char **cmdline_p) | ||
| 54 | { | ||
| 55 | ctrl_outw(0x1000, 0xa4050110); /* Enable IRQ0 in PJCR */ | ||
| 56 | } | ||
| 57 | |||
| 58 | static struct sh_machine_vector mv_migor __initmv = { | ||
| 59 | .mv_name = "Migo-R", | ||
| 60 | .mv_setup = migor_setup, | ||
| 61 | }; | ||
diff --git a/arch/sh/boards/renesas/r7780rp/setup.c b/arch/sh/boards/renesas/r7780rp/setup.c index f7a8d5c9d510..2f68bea7890c 100644 --- a/arch/sh/boards/renesas/r7780rp/setup.c +++ b/arch/sh/boards/renesas/r7780rp/setup.c | |||
| @@ -23,6 +23,7 @@ | |||
| 23 | #include <asm/clock.h> | 23 | #include <asm/clock.h> |
| 24 | #include <asm/heartbeat.h> | 24 | #include <asm/heartbeat.h> |
| 25 | #include <asm/io.h> | 25 | #include <asm/io.h> |
| 26 | #include <asm/io_trapped.h> | ||
| 26 | 27 | ||
| 27 | static struct resource r8a66597_usb_host_resources[] = { | 28 | static struct resource r8a66597_usb_host_resources[] = { |
| 28 | [0] = { | 29 | [0] = { |
| @@ -181,13 +182,27 @@ static struct platform_device *r7780rp_devices[] __initdata = { | |||
| 181 | &m66592_usb_peripheral_device, | 182 | &m66592_usb_peripheral_device, |
| 182 | &heartbeat_device, | 183 | &heartbeat_device, |
| 183 | #ifndef CONFIG_SH_R7780RP | 184 | #ifndef CONFIG_SH_R7780RP |
| 184 | &cf_ide_device, | ||
| 185 | &ax88796_device, | 185 | &ax88796_device, |
| 186 | #endif | 186 | #endif |
| 187 | }; | 187 | }; |
| 188 | 188 | ||
| 189 | /* | ||
| 190 | * The CF is connected using a 16-bit bus where 8-bit operations are | ||
| 191 | * unsupported. The linux ata driver is however using 8-bit operations, so | ||
| 192 | * insert a trapped io filter to convert 8-bit operations into 16-bit. | ||
| 193 | */ | ||
| 194 | static struct trapped_io cf_trapped_io = { | ||
| 195 | .resource = cf_ide_resources, | ||
| 196 | .num_resources = 2, | ||
| 197 | .minimum_bus_width = 16, | ||
| 198 | }; | ||
| 199 | |||
| 189 | static int __init r7780rp_devices_setup(void) | 200 | static int __init r7780rp_devices_setup(void) |
| 190 | { | 201 | { |
| 202 | #ifndef CONFIG_SH_R7780RP | ||
| 203 | if (register_trapped_io(&cf_trapped_io) == 0) | ||
| 204 | platform_device_register(&cf_ide_device); | ||
| 205 | #endif | ||
| 191 | return platform_add_devices(r7780rp_devices, | 206 | return platform_add_devices(r7780rp_devices, |
| 192 | ARRAY_SIZE(r7780rp_devices)); | 207 | ARRAY_SIZE(r7780rp_devices)); |
| 193 | } | 208 | } |
| @@ -226,34 +241,6 @@ static void r7780rp_power_off(void) | |||
| 226 | ctrl_outw(0x0001, PA_POFF); | 241 | ctrl_outw(0x0001, PA_POFF); |
| 227 | } | 242 | } |
| 228 | 243 | ||
| 229 | static inline unsigned char is_ide_ioaddr(unsigned long addr) | ||
| 230 | { | ||
| 231 | return ((cf_ide_resources[0].start <= addr && | ||
| 232 | addr <= cf_ide_resources[0].end) || | ||
| 233 | (cf_ide_resources[1].start <= addr && | ||
| 234 | addr <= cf_ide_resources[1].end)); | ||
| 235 | } | ||
| 236 | |||
| 237 | void highlander_writeb(u8 b, void __iomem *addr) | ||
| 238 | { | ||
| 239 | unsigned long tmp = (unsigned long __force)addr; | ||
| 240 | |||
| 241 | if (is_ide_ioaddr(tmp)) | ||
| 242 | ctrl_outw((u16)b, tmp); | ||
| 243 | else | ||
| 244 | ctrl_outb(b, tmp); | ||
| 245 | } | ||
| 246 | |||
| 247 | u8 highlander_readb(void __iomem *addr) | ||
| 248 | { | ||
| 249 | unsigned long tmp = (unsigned long __force)addr; | ||
| 250 | |||
| 251 | if (is_ide_ioaddr(tmp)) | ||
| 252 | return ctrl_inw(tmp) & 0xff; | ||
| 253 | else | ||
| 254 | return ctrl_inb(tmp); | ||
| 255 | } | ||
| 256 | |||
| 257 | /* | 244 | /* |
| 258 | * Initialize the board | 245 | * Initialize the board |
| 259 | */ | 246 | */ |
| @@ -338,6 +325,4 @@ static struct sh_machine_vector mv_highlander __initmv = { | |||
| 338 | .mv_setup = highlander_setup, | 325 | .mv_setup = highlander_setup, |
| 339 | .mv_init_irq = highlander_init_irq, | 326 | .mv_init_irq = highlander_init_irq, |
| 340 | .mv_irq_demux = highlander_irq_demux, | 327 | .mv_irq_demux = highlander_irq_demux, |
| 341 | .mv_readb = highlander_readb, | ||
| 342 | .mv_writeb = highlander_writeb, | ||
| 343 | }; | 328 | }; |
diff --git a/arch/sh/boards/renesas/rts7751r2d/setup.c b/arch/sh/boards/renesas/rts7751r2d/setup.c index a0ef81b7de37..f21ee49ef3a5 100644 --- a/arch/sh/boards/renesas/rts7751r2d/setup.c +++ b/arch/sh/boards/renesas/rts7751r2d/setup.c | |||
| @@ -21,6 +21,7 @@ | |||
| 21 | #include <asm/machvec.h> | 21 | #include <asm/machvec.h> |
| 22 | #include <asm/rts7751r2d.h> | 22 | #include <asm/rts7751r2d.h> |
| 23 | #include <asm/io.h> | 23 | #include <asm/io.h> |
| 24 | #include <asm/io_trapped.h> | ||
| 24 | #include <asm/spi.h> | 25 | #include <asm/spi.h> |
| 25 | 26 | ||
| 26 | static struct resource cf_ide_resources[] = { | 27 | static struct resource cf_ide_resources[] = { |
| @@ -214,13 +215,25 @@ static struct platform_device *rts7751r2d_devices[] __initdata = { | |||
| 214 | &uart_device, | 215 | &uart_device, |
| 215 | &sm501_device, | 216 | &sm501_device, |
| 216 | #endif | 217 | #endif |
| 217 | &cf_ide_device, | ||
| 218 | &heartbeat_device, | 218 | &heartbeat_device, |
| 219 | &spi_sh_sci_device, | 219 | &spi_sh_sci_device, |
| 220 | }; | 220 | }; |
| 221 | 221 | ||
| 222 | /* | ||
| 223 | * The CF is connected with a 16-bit bus where 8-bit operations are | ||
| 224 | * unsupported. The linux ata driver is however using 8-bit operations, so | ||
| 225 | * insert a trapped io filter to convert 8-bit operations into 16-bit. | ||
| 226 | */ | ||
| 227 | static struct trapped_io cf_trapped_io = { | ||
| 228 | .resource = cf_ide_resources, | ||
| 229 | .num_resources = 2, | ||
| 230 | .minimum_bus_width = 16, | ||
| 231 | }; | ||
| 232 | |||
| 222 | static int __init rts7751r2d_devices_setup(void) | 233 | static int __init rts7751r2d_devices_setup(void) |
| 223 | { | 234 | { |
| 235 | if (register_trapped_io(&cf_trapped_io) == 0) | ||
| 236 | platform_device_register(&cf_ide_device); | ||
| 224 | spi_register_board_info(spi_bus, ARRAY_SIZE(spi_bus)); | 237 | spi_register_board_info(spi_bus, ARRAY_SIZE(spi_bus)); |
| 225 | return platform_add_devices(rts7751r2d_devices, | 238 | return platform_add_devices(rts7751r2d_devices, |
| 226 | ARRAY_SIZE(rts7751r2d_devices)); | 239 | ARRAY_SIZE(rts7751r2d_devices)); |
| @@ -232,34 +245,6 @@ static void rts7751r2d_power_off(void) | |||
| 232 | ctrl_outw(0x0001, PA_POWOFF); | 245 | ctrl_outw(0x0001, PA_POWOFF); |
| 233 | } | 246 | } |
| 234 | 247 | ||
| 235 | static inline unsigned char is_ide_ioaddr(unsigned long addr) | ||
| 236 | { | ||
| 237 | return ((cf_ide_resources[0].start <= addr && | ||
| 238 | addr <= cf_ide_resources[0].end) || | ||
| 239 | (cf_ide_resources[1].start <= addr && | ||
| 240 | addr <= cf_ide_resources[1].end)); | ||
| 241 | } | ||
| 242 | |||
| 243 | void rts7751r2d_writeb(u8 b, void __iomem *addr) | ||
| 244 | { | ||
| 245 | unsigned long tmp = (unsigned long __force)addr; | ||
| 246 | |||
| 247 | if (is_ide_ioaddr(tmp)) | ||
| 248 | ctrl_outw((u16)b, tmp); | ||
| 249 | else | ||
| 250 | ctrl_outb(b, tmp); | ||
| 251 | } | ||
| 252 | |||
| 253 | u8 rts7751r2d_readb(void __iomem *addr) | ||
| 254 | { | ||
| 255 | unsigned long tmp = (unsigned long __force)addr; | ||
| 256 | |||
| 257 | if (is_ide_ioaddr(tmp)) | ||
| 258 | return ctrl_inw(tmp) & 0xff; | ||
| 259 | else | ||
| 260 | return ctrl_inb(tmp); | ||
| 261 | } | ||
| 262 | |||
| 263 | /* | 248 | /* |
| 264 | * Initialize the board | 249 | * Initialize the board |
| 265 | */ | 250 | */ |
| @@ -310,6 +295,4 @@ static struct sh_machine_vector mv_rts7751r2d __initmv = { | |||
| 310 | .mv_setup = rts7751r2d_setup, | 295 | .mv_setup = rts7751r2d_setup, |
| 311 | .mv_init_irq = init_rts7751r2d_IRQ, | 296 | .mv_init_irq = init_rts7751r2d_IRQ, |
| 312 | .mv_irq_demux = rts7751r2d_irq_demux, | 297 | .mv_irq_demux = rts7751r2d_irq_demux, |
| 313 | .mv_writeb = rts7751r2d_writeb, | ||
| 314 | .mv_readb = rts7751r2d_readb, | ||
| 315 | }; | 298 | }; |
diff --git a/arch/sh/boards/renesas/sdk7780/Kconfig b/arch/sh/boards/renesas/sdk7780/Kconfig index e4f5b6985be1..065f1df09bf1 100644 --- a/arch/sh/boards/renesas/sdk7780/Kconfig +++ b/arch/sh/boards/renesas/sdk7780/Kconfig | |||
| @@ -4,13 +4,6 @@ choice | |||
| 4 | prompt "SDK7780 options" | 4 | prompt "SDK7780 options" |
| 5 | default SH_SDK7780_BASE | 5 | default SH_SDK7780_BASE |
| 6 | 6 | ||
| 7 | config SH_SDK7780_STANDALONE | ||
| 8 | bool "SDK7780 board support" | ||
| 9 | depends on CPU_SUBTYPE_SH7780 | ||
| 10 | help | ||
| 11 | Selecting this option will enable support for the | ||
| 12 | standalone version of the SDK7780. If in doubt, say Y. | ||
| 13 | |||
| 14 | config SH_SDK7780_BASE | 7 | config SH_SDK7780_BASE |
| 15 | bool "SDK7780 with base-board support" | 8 | bool "SDK7780 with base-board support" |
| 16 | depends on CPU_SUBTYPE_SH7780 | 9 | depends on CPU_SUBTYPE_SH7780 |
diff --git a/arch/sh/cchips/hd6446x/hd64465/setup.c b/arch/sh/cchips/hd6446x/hd64465/setup.c index 5cef0db4018b..9b8820c36701 100644 --- a/arch/sh/cchips/hd6446x/hd64465/setup.c +++ b/arch/sh/cchips/hd6446x/hd64465/setup.c | |||
| @@ -17,10 +17,8 @@ | |||
| 17 | #include <linux/interrupt.h> | 17 | #include <linux/interrupt.h> |
| 18 | #include <linux/init.h> | 18 | #include <linux/init.h> |
| 19 | #include <linux/irq.h> | 19 | #include <linux/irq.h> |
| 20 | |||
| 21 | #include <asm/io.h> | 20 | #include <asm/io.h> |
| 22 | #include <asm/irq.h> | 21 | #include <asm/irq.h> |
| 23 | |||
| 24 | #include <asm/hd64465/hd64465.h> | 22 | #include <asm/hd64465/hd64465.h> |
| 25 | 23 | ||
| 26 | static void disable_hd64465_irq(unsigned int irq) | 24 | static void disable_hd64465_irq(unsigned int irq) |
| @@ -28,51 +26,45 @@ static void disable_hd64465_irq(unsigned int irq) | |||
| 28 | unsigned short nimr; | 26 | unsigned short nimr; |
| 29 | unsigned short mask = 1 << (irq - HD64465_IRQ_BASE); | 27 | unsigned short mask = 1 << (irq - HD64465_IRQ_BASE); |
| 30 | 28 | ||
| 31 | pr_debug("disable_hd64465_irq(%d): mask=%x\n", irq, mask); | 29 | pr_debug("disable_hd64465_irq(%d): mask=%x\n", irq, mask); |
| 32 | nimr = inw(HD64465_REG_NIMR); | 30 | nimr = inw(HD64465_REG_NIMR); |
| 33 | nimr |= mask; | 31 | nimr |= mask; |
| 34 | outw(nimr, HD64465_REG_NIMR); | 32 | outw(nimr, HD64465_REG_NIMR); |
| 35 | } | 33 | } |
| 36 | 34 | ||
| 37 | |||
| 38 | static void enable_hd64465_irq(unsigned int irq) | 35 | static void enable_hd64465_irq(unsigned int irq) |
| 39 | { | 36 | { |
| 40 | unsigned short nimr; | 37 | unsigned short nimr; |
| 41 | unsigned short mask = 1 << (irq - HD64465_IRQ_BASE); | 38 | unsigned short mask = 1 << (irq - HD64465_IRQ_BASE); |
| 42 | 39 | ||
| 43 | pr_debug("enable_hd64465_irq(%d): mask=%x\n", irq, mask); | 40 | pr_debug("enable_hd64465_irq(%d): mask=%x\n", irq, mask); |
| 44 | nimr = inw(HD64465_REG_NIMR); | 41 | nimr = inw(HD64465_REG_NIMR); |
| 45 | nimr &= ~mask; | 42 | nimr &= ~mask; |
| 46 | outw(nimr, HD64465_REG_NIMR); | 43 | outw(nimr, HD64465_REG_NIMR); |
| 47 | } | 44 | } |
| 48 | 45 | ||
| 49 | |||
| 50 | static void mask_and_ack_hd64465(unsigned int irq) | 46 | static void mask_and_ack_hd64465(unsigned int irq) |
| 51 | { | 47 | { |
| 52 | disable_hd64465_irq(irq); | 48 | disable_hd64465_irq(irq); |
| 53 | } | 49 | } |
| 54 | 50 | ||
| 55 | |||
| 56 | static void end_hd64465_irq(unsigned int irq) | 51 | static void end_hd64465_irq(unsigned int irq) |
| 57 | { | 52 | { |
| 58 | if (!(irq_desc[irq].status & (IRQ_DISABLED|IRQ_INPROGRESS))) | 53 | if (!(irq_desc[irq].status & (IRQ_DISABLED|IRQ_INPROGRESS))) |
| 59 | enable_hd64465_irq(irq); | 54 | enable_hd64465_irq(irq); |
| 60 | } | 55 | } |
| 61 | 56 | ||
| 62 | |||
| 63 | static unsigned int startup_hd64465_irq(unsigned int irq) | 57 | static unsigned int startup_hd64465_irq(unsigned int irq) |
| 64 | { | 58 | { |
| 65 | enable_hd64465_irq(irq); | 59 | enable_hd64465_irq(irq); |
| 66 | return 0; | 60 | return 0; |
| 67 | } | 61 | } |
| 68 | 62 | ||
| 69 | |||
| 70 | static void shutdown_hd64465_irq(unsigned int irq) | 63 | static void shutdown_hd64465_irq(unsigned int irq) |
| 71 | { | 64 | { |
| 72 | disable_hd64465_irq(irq); | 65 | disable_hd64465_irq(irq); |
| 73 | } | 66 | } |
| 74 | 67 | ||
| 75 | |||
| 76 | static struct hw_interrupt_type hd64465_irq_type = { | 68 | static struct hw_interrupt_type hd64465_irq_type = { |
| 77 | .typename = "HD64465-IRQ", | 69 | .typename = "HD64465-IRQ", |
| 78 | .startup = startup_hd64465_irq, | 70 | .startup = startup_hd64465_irq, |
| @@ -83,7 +75,6 @@ static struct hw_interrupt_type hd64465_irq_type = { | |||
| 83 | .end = end_hd64465_irq, | 75 | .end = end_hd64465_irq, |
| 84 | }; | 76 | }; |
| 85 | 77 | ||
| 86 | |||
| 87 | static irqreturn_t hd64465_interrupt(int irq, void *dev_id) | 78 | static irqreturn_t hd64465_interrupt(int irq, void *dev_id) |
| 88 | { | 79 | { |
| 89 | printk(KERN_INFO | 80 | printk(KERN_INFO |
| @@ -93,9 +84,6 @@ static irqreturn_t hd64465_interrupt(int irq, void *dev_id) | |||
| 93 | return IRQ_NONE; | 84 | return IRQ_NONE; |
| 94 | } | 85 | } |
| 95 | 86 | ||
| 96 | |||
| 97 | /*====================================================*/ | ||
| 98 | |||
| 99 | /* | 87 | /* |
| 100 | * Support for a secondary IRQ demux step. This is necessary | 88 | * Support for a secondary IRQ demux step. This is necessary |
| 101 | * because the HD64465 presents a very thin interface to the | 89 | * because the HD64465 presents a very thin interface to the |
| @@ -103,8 +91,7 @@ static irqreturn_t hd64465_interrupt(int irq, void *dev_id) | |||
| 103 | * normally done in hardware by other PCMCIA host bridges is | 91 | * normally done in hardware by other PCMCIA host bridges is |
| 104 | * instead done in software. | 92 | * instead done in software. |
| 105 | */ | 93 | */ |
| 106 | static struct | 94 | static struct { |
| 107 | { | ||
| 108 | int (*func)(int, void *); | 95 | int (*func)(int, void *); |
| 109 | void *dev; | 96 | void *dev; |
| 110 | } hd64465_demux[HD64465_IRQ_NUM]; | 97 | } hd64465_demux[HD64465_IRQ_NUM]; |
| @@ -112,19 +99,17 @@ static struct | |||
| 112 | void hd64465_register_irq_demux(int irq, | 99 | void hd64465_register_irq_demux(int irq, |
| 113 | int (*demux)(int irq, void *dev), void *dev) | 100 | int (*demux)(int irq, void *dev), void *dev) |
| 114 | { | 101 | { |
| 115 | hd64465_demux[irq - HD64465_IRQ_BASE].func = demux; | 102 | hd64465_demux[irq - HD64465_IRQ_BASE].func = demux; |
| 116 | hd64465_demux[irq - HD64465_IRQ_BASE].dev = dev; | 103 | hd64465_demux[irq - HD64465_IRQ_BASE].dev = dev; |
| 117 | } | 104 | } |
| 118 | EXPORT_SYMBOL(hd64465_register_irq_demux); | 105 | EXPORT_SYMBOL(hd64465_register_irq_demux); |
| 119 | 106 | ||
| 120 | void hd64465_unregister_irq_demux(int irq) | 107 | void hd64465_unregister_irq_demux(int irq) |
| 121 | { | 108 | { |
| 122 | hd64465_demux[irq - HD64465_IRQ_BASE].func = 0; | 109 | hd64465_demux[irq - HD64465_IRQ_BASE].func = 0; |
| 123 | } | 110 | } |
| 124 | EXPORT_SYMBOL(hd64465_unregister_irq_demux); | 111 | EXPORT_SYMBOL(hd64465_unregister_irq_demux); |
| 125 | 112 | ||
| 126 | |||
| 127 | |||
| 128 | int hd64465_irq_demux(int irq) | 113 | int hd64465_irq_demux(int irq) |
| 129 | { | 114 | { |
| 130 | if (irq == CONFIG_HD64465_IRQ) { | 115 | if (irq == CONFIG_HD64465_IRQ) { |
| @@ -132,16 +117,16 @@ int hd64465_irq_demux(int irq) | |||
| 132 | unsigned short nirr = inw(HD64465_REG_NIRR); | 117 | unsigned short nirr = inw(HD64465_REG_NIRR); |
| 133 | unsigned short nimr = inw(HD64465_REG_NIMR); | 118 | unsigned short nimr = inw(HD64465_REG_NIMR); |
| 134 | 119 | ||
| 135 | pr_debug("hd64465_irq_demux, nirr=%04x, nimr=%04x\n", nirr, nimr); | 120 | pr_debug("hd64465_irq_demux, nirr=%04x, nimr=%04x\n", nirr, nimr); |
| 136 | nirr &= ~nimr; | 121 | nirr &= ~nimr; |
| 137 | for (bit = 1, i = 0 ; i < HD64465_IRQ_NUM ; bit <<= 1, i++) | 122 | for (bit = 1, i = 0 ; i < HD64465_IRQ_NUM ; bit <<= 1, i++) |
| 138 | if (nirr & bit) | 123 | if (nirr & bit) |
| 139 | break; | 124 | break; |
| 140 | 125 | ||
| 141 | if (i < HD64465_IRQ_NUM) { | 126 | if (i < HD64465_IRQ_NUM) { |
| 142 | irq = HD64465_IRQ_BASE + i; | 127 | irq = HD64465_IRQ_BASE + i; |
| 143 | if (hd64465_demux[i].func != 0) | 128 | if (hd64465_demux[i].func != 0) |
| 144 | irq = hd64465_demux[i].func(irq, hd64465_demux[i].dev); | 129 | irq = hd64465_demux[i].func(irq, hd64465_demux[i].dev); |
| 145 | } | 130 | } |
| 146 | } | 131 | } |
| 147 | return irq; | 132 | return irq; |
| @@ -154,7 +139,6 @@ static struct irqaction irq0 = { | |||
| 154 | .name = "HD64465", | 139 | .name = "HD64465", |
| 155 | }; | 140 | }; |
| 156 | 141 | ||
| 157 | |||
| 158 | static int __init setup_hd64465(void) | 142 | static int __init setup_hd64465(void) |
| 159 | { | 143 | { |
| 160 | int i; | 144 | int i; |
| @@ -176,8 +160,8 @@ static int __init setup_hd64465(void) | |||
| 176 | 160 | ||
| 177 | rev = inw(HD64465_REG_SRR); | 161 | rev = inw(HD64465_REG_SRR); |
| 178 | printk(KERN_INFO "HD64465 hardware revision %d.%d\n", (rev >> 8) & 0xff, rev & 0xff); | 162 | printk(KERN_INFO "HD64465 hardware revision %d.%d\n", (rev >> 8) & 0xff, rev & 0xff); |
| 179 | 163 | ||
| 180 | outw(0xffff, HD64465_REG_NIMR); /* mask all interrupts */ | 164 | outw(0xffff, HD64465_REG_NIMR); /* mask all interrupts */ |
| 181 | 165 | ||
| 182 | for (i = 0; i < HD64465_IRQ_NUM ; i++) { | 166 | for (i = 0; i < HD64465_IRQ_NUM ; i++) { |
| 183 | irq_desc[HD64465_IRQ_BASE + i].chip = &hd64465_irq_type; | 167 | irq_desc[HD64465_IRQ_BASE + i].chip = &hd64465_irq_type; |
| @@ -185,16 +169,13 @@ static int __init setup_hd64465(void) | |||
| 185 | 169 | ||
| 186 | setup_irq(CONFIG_HD64465_IRQ, &irq0); | 170 | setup_irq(CONFIG_HD64465_IRQ, &irq0); |
| 187 | 171 | ||
| 188 | #ifdef CONFIG_SERIAL | ||
| 189 | /* wake up the UART from STANDBY at this point */ | 172 | /* wake up the UART from STANDBY at this point */ |
| 190 | smscr = inw(HD64465_REG_SMSCR); | 173 | smscr = inw(HD64465_REG_SMSCR); |
| 191 | outw(smscr & (~HD64465_SMSCR_UARTST), HD64465_REG_SMSCR); | 174 | outw(smscr & (~HD64465_SMSCR_UARTST), HD64465_REG_SMSCR); |
| 192 | 175 | ||
| 193 | /* remap IO ports for first ISA serial port to HD64465 UART */ | 176 | /* remap IO ports for first ISA serial port to HD64465 UART */ |
| 194 | hd64465_port_map(0x3f8, 8, CONFIG_HD64465_IOBASE + 0x8000, 1); | 177 | hd64465_port_map(0x3f8, 8, CONFIG_HD64465_IOBASE + 0x8000, 1); |
| 195 | #endif | ||
| 196 | 178 | ||
| 197 | return 0; | 179 | return 0; |
| 198 | } | 180 | } |
| 199 | |||
| 200 | module_init(setup_hd64465); | 181 | module_init(setup_hd64465); |
diff --git a/arch/sh/configs/migor_defconfig b/arch/sh/configs/migor_defconfig new file mode 100644 index 000000000000..ee5900817f8f --- /dev/null +++ b/arch/sh/configs/migor_defconfig | |||
| @@ -0,0 +1,824 @@ | |||
| 1 | # | ||
| 2 | # Automatically generated make config: don't edit | ||
| 3 | # Linux kernel version: 2.6.24 | ||
| 4 | # Wed Feb 6 21:52:20 2008 | ||
| 5 | # | ||
| 6 | CONFIG_SUPERH=y | ||
| 7 | CONFIG_SUPERH32=y | ||
| 8 | CONFIG_RWSEM_GENERIC_SPINLOCK=y | ||
| 9 | CONFIG_GENERIC_BUG=y | ||
| 10 | CONFIG_GENERIC_FIND_NEXT_BIT=y | ||
| 11 | CONFIG_GENERIC_HWEIGHT=y | ||
| 12 | CONFIG_GENERIC_HARDIRQS=y | ||
| 13 | CONFIG_GENERIC_IRQ_PROBE=y | ||
| 14 | CONFIG_GENERIC_CALIBRATE_DELAY=y | ||
| 15 | CONFIG_GENERIC_TIME=y | ||
| 16 | CONFIG_GENERIC_CLOCKEVENTS=y | ||
| 17 | CONFIG_SYS_SUPPORTS_NUMA=y | ||
| 18 | CONFIG_STACKTRACE_SUPPORT=y | ||
| 19 | CONFIG_LOCKDEP_SUPPORT=y | ||
| 20 | # CONFIG_ARCH_HAS_ILOG2_U32 is not set | ||
| 21 | # CONFIG_ARCH_HAS_ILOG2_U64 is not set | ||
| 22 | CONFIG_ARCH_NO_VIRT_TO_BUS=y | ||
| 23 | CONFIG_DEFCONFIG_LIST="/lib/modules/$UNAME_RELEASE/.config" | ||
| 24 | |||
| 25 | # | ||
| 26 | # General setup | ||
| 27 | # | ||
| 28 | CONFIG_EXPERIMENTAL=y | ||
| 29 | CONFIG_BROKEN_ON_SMP=y | ||
| 30 | CONFIG_INIT_ENV_ARG_LIMIT=32 | ||
| 31 | CONFIG_LOCALVERSION="" | ||
| 32 | CONFIG_LOCALVERSION_AUTO=y | ||
| 33 | CONFIG_SWAP=y | ||
| 34 | CONFIG_SYSVIPC=y | ||
| 35 | CONFIG_SYSVIPC_SYSCTL=y | ||
| 36 | # CONFIG_POSIX_MQUEUE is not set | ||
| 37 | # CONFIG_BSD_PROCESS_ACCT is not set | ||
| 38 | # CONFIG_TASKSTATS is not set | ||
| 39 | # CONFIG_USER_NS is not set | ||
| 40 | # CONFIG_PID_NS is not set | ||
| 41 | # CONFIG_AUDIT is not set | ||
| 42 | CONFIG_IKCONFIG=y | ||
| 43 | CONFIG_IKCONFIG_PROC=y | ||
| 44 | CONFIG_LOG_BUF_SHIFT=14 | ||
| 45 | # CONFIG_CGROUPS is not set | ||
| 46 | CONFIG_FAIR_GROUP_SCHED=y | ||
| 47 | CONFIG_FAIR_USER_SCHED=y | ||
| 48 | # CONFIG_FAIR_CGROUP_SCHED is not set | ||
| 49 | CONFIG_SYSFS_DEPRECATED=y | ||
| 50 | # CONFIG_RELAY is not set | ||
| 51 | CONFIG_BLK_DEV_INITRD=y | ||
| 52 | CONFIG_INITRAMFS_SOURCE="" | ||
| 53 | # CONFIG_CC_OPTIMIZE_FOR_SIZE is not set | ||
| 54 | CONFIG_SYSCTL=y | ||
| 55 | CONFIG_EMBEDDED=y | ||
| 56 | CONFIG_UID16=y | ||
| 57 | # CONFIG_SYSCTL_SYSCALL is not set | ||
| 58 | CONFIG_KALLSYMS=y | ||
| 59 | # CONFIG_KALLSYMS_EXTRA_PASS is not set | ||
| 60 | CONFIG_HOTPLUG=y | ||
| 61 | CONFIG_PRINTK=y | ||
| 62 | CONFIG_BUG=y | ||
| 63 | CONFIG_ELF_CORE=y | ||
| 64 | CONFIG_BASE_FULL=y | ||
| 65 | CONFIG_FUTEX=y | ||
| 66 | CONFIG_ANON_INODES=y | ||
| 67 | CONFIG_EPOLL=y | ||
| 68 | CONFIG_SIGNALFD=y | ||
| 69 | CONFIG_EVENTFD=y | ||
| 70 | CONFIG_SHMEM=y | ||
| 71 | CONFIG_VM_EVENT_COUNTERS=y | ||
| 72 | CONFIG_SLAB=y | ||
| 73 | # CONFIG_SLUB is not set | ||
| 74 | # CONFIG_SLOB is not set | ||
| 75 | CONFIG_PROFILING=y | ||
| 76 | # CONFIG_MARKERS is not set | ||
| 77 | CONFIG_OPROFILE=y | ||
| 78 | CONFIG_HAVE_OPROFILE=y | ||
| 79 | # CONFIG_HAVE_KPROBES is not set | ||
| 80 | CONFIG_SLABINFO=y | ||
| 81 | CONFIG_RT_MUTEXES=y | ||
| 82 | # CONFIG_TINY_SHMEM is not set | ||
| 83 | CONFIG_BASE_SMALL=0 | ||
| 84 | CONFIG_MODULES=y | ||
| 85 | # CONFIG_MODULE_UNLOAD is not set | ||
| 86 | # CONFIG_MODVERSIONS is not set | ||
| 87 | # CONFIG_MODULE_SRCVERSION_ALL is not set | ||
| 88 | # CONFIG_KMOD is not set | ||
| 89 | CONFIG_BLOCK=y | ||
| 90 | # CONFIG_LBD is not set | ||
| 91 | # CONFIG_BLK_DEV_IO_TRACE is not set | ||
| 92 | # CONFIG_LSF is not set | ||
| 93 | # CONFIG_BLK_DEV_BSG is not set | ||
| 94 | |||
| 95 | # | ||
| 96 | # IO Schedulers | ||
| 97 | # | ||
| 98 | CONFIG_IOSCHED_NOOP=y | ||
| 99 | CONFIG_IOSCHED_AS=y | ||
| 100 | CONFIG_IOSCHED_DEADLINE=y | ||
| 101 | CONFIG_IOSCHED_CFQ=y | ||
| 102 | CONFIG_DEFAULT_AS=y | ||
| 103 | # CONFIG_DEFAULT_DEADLINE is not set | ||
| 104 | # CONFIG_DEFAULT_CFQ is not set | ||
| 105 | # CONFIG_DEFAULT_NOOP is not set | ||
| 106 | CONFIG_DEFAULT_IOSCHED="anticipatory" | ||
| 107 | CONFIG_CLASSIC_RCU=y | ||
| 108 | # CONFIG_PREEMPT_RCU is not set | ||
| 109 | |||
| 110 | # | ||
| 111 | # System type | ||
| 112 | # | ||
| 113 | CONFIG_CPU_SH4=y | ||
| 114 | CONFIG_CPU_SH4A=y | ||
| 115 | CONFIG_CPU_SH4AL_DSP=y | ||
| 116 | CONFIG_CPU_SHX2=y | ||
| 117 | # CONFIG_CPU_SUBTYPE_SH7619 is not set | ||
| 118 | # CONFIG_CPU_SUBTYPE_SH7203 is not set | ||
| 119 | # CONFIG_CPU_SUBTYPE_SH7206 is not set | ||
| 120 | # CONFIG_CPU_SUBTYPE_SH7263 is not set | ||
| 121 | # CONFIG_CPU_SUBTYPE_SH7705 is not set | ||
| 122 | # CONFIG_CPU_SUBTYPE_SH7706 is not set | ||
| 123 | # CONFIG_CPU_SUBTYPE_SH7707 is not set | ||
| 124 | # CONFIG_CPU_SUBTYPE_SH7708 is not set | ||
| 125 | # CONFIG_CPU_SUBTYPE_SH7709 is not set | ||
| 126 | # CONFIG_CPU_SUBTYPE_SH7710 is not set | ||
| 127 | # CONFIG_CPU_SUBTYPE_SH7712 is not set | ||
| 128 | # CONFIG_CPU_SUBTYPE_SH7720 is not set | ||
| 129 | # CONFIG_CPU_SUBTYPE_SH7721 is not set | ||
| 130 | # CONFIG_CPU_SUBTYPE_SH7750 is not set | ||
| 131 | # CONFIG_CPU_SUBTYPE_SH7091 is not set | ||
| 132 | # CONFIG_CPU_SUBTYPE_SH7750R is not set | ||
| 133 | # CONFIG_CPU_SUBTYPE_SH7750S is not set | ||
| 134 | # CONFIG_CPU_SUBTYPE_SH7751 is not set | ||
| 135 | # CONFIG_CPU_SUBTYPE_SH7751R is not set | ||
| 136 | # CONFIG_CPU_SUBTYPE_SH7760 is not set | ||
| 137 | # CONFIG_CPU_SUBTYPE_SH4_202 is not set | ||
| 138 | # CONFIG_CPU_SUBTYPE_SH7763 is not set | ||
| 139 | # CONFIG_CPU_SUBTYPE_SH7770 is not set | ||
| 140 | # CONFIG_CPU_SUBTYPE_SH7780 is not set | ||
| 141 | # CONFIG_CPU_SUBTYPE_SH7785 is not set | ||
| 142 | # CONFIG_CPU_SUBTYPE_SHX3 is not set | ||
| 143 | # CONFIG_CPU_SUBTYPE_SH7343 is not set | ||
| 144 | CONFIG_CPU_SUBTYPE_SH7722=y | ||
| 145 | # CONFIG_CPU_SUBTYPE_SH5_101 is not set | ||
| 146 | # CONFIG_CPU_SUBTYPE_SH5_103 is not set | ||
| 147 | |||
| 148 | # | ||
| 149 | # Memory management options | ||
| 150 | # | ||
| 151 | CONFIG_QUICKLIST=y | ||
| 152 | CONFIG_MMU=y | ||
| 153 | CONFIG_PAGE_OFFSET=0x80000000 | ||
| 154 | CONFIG_MEMORY_START=0x0c000000 | ||
| 155 | CONFIG_MEMORY_SIZE=0x04000000 | ||
| 156 | CONFIG_29BIT=y | ||
| 157 | # CONFIG_X2TLB is not set | ||
| 158 | CONFIG_VSYSCALL=y | ||
| 159 | CONFIG_NUMA=y | ||
| 160 | CONFIG_NODES_SHIFT=1 | ||
| 161 | CONFIG_ARCH_SPARSEMEM_ENABLE=y | ||
| 162 | CONFIG_ARCH_SPARSEMEM_DEFAULT=y | ||
| 163 | CONFIG_MAX_ACTIVE_REGIONS=2 | ||
| 164 | CONFIG_ARCH_POPULATES_NODE_MAP=y | ||
| 165 | CONFIG_ARCH_SELECT_MEMORY_MODEL=y | ||
| 166 | CONFIG_ARCH_ENABLE_MEMORY_HOTPLUG=y | ||
| 167 | CONFIG_PAGE_SIZE_4KB=y | ||
| 168 | # CONFIG_PAGE_SIZE_8KB is not set | ||
| 169 | # CONFIG_PAGE_SIZE_64KB is not set | ||
| 170 | CONFIG_SELECT_MEMORY_MODEL=y | ||
| 171 | # CONFIG_FLATMEM_MANUAL is not set | ||
| 172 | # CONFIG_DISCONTIGMEM_MANUAL is not set | ||
| 173 | CONFIG_SPARSEMEM_MANUAL=y | ||
| 174 | CONFIG_SPARSEMEM=y | ||
| 175 | CONFIG_NEED_MULTIPLE_NODES=y | ||
| 176 | CONFIG_HAVE_MEMORY_PRESENT=y | ||
| 177 | CONFIG_SPARSEMEM_STATIC=y | ||
| 178 | # CONFIG_SPARSEMEM_VMEMMAP_ENABLE is not set | ||
| 179 | # CONFIG_MEMORY_HOTPLUG is not set | ||
| 180 | CONFIG_SPLIT_PTLOCK_CPUS=4 | ||
| 181 | # CONFIG_MIGRATION is not set | ||
| 182 | # CONFIG_RESOURCES_64BIT is not set | ||
| 183 | CONFIG_ZONE_DMA_FLAG=0 | ||
| 184 | CONFIG_NR_QUICK=2 | ||
| 185 | |||
| 186 | # | ||
| 187 | # Cache configuration | ||
| 188 | # | ||
| 189 | # CONFIG_SH_DIRECT_MAPPED is not set | ||
| 190 | CONFIG_CACHE_WRITEBACK=y | ||
| 191 | # CONFIG_CACHE_WRITETHROUGH is not set | ||
| 192 | # CONFIG_CACHE_OFF is not set | ||
| 193 | |||
| 194 | # | ||
| 195 | # Processor features | ||
| 196 | # | ||
| 197 | CONFIG_CPU_LITTLE_ENDIAN=y | ||
| 198 | # CONFIG_CPU_BIG_ENDIAN is not set | ||
| 199 | # CONFIG_SH_FPU_EMU is not set | ||
| 200 | CONFIG_SH_DSP=y | ||
| 201 | # CONFIG_SH_STORE_QUEUES is not set | ||
| 202 | CONFIG_CPU_HAS_INTEVT=y | ||
| 203 | CONFIG_CPU_HAS_SR_RB=y | ||
| 204 | CONFIG_CPU_HAS_PTEA=y | ||
| 205 | CONFIG_CPU_HAS_DSP=y | ||
| 206 | |||
| 207 | # | ||
| 208 | # Board support | ||
| 209 | # | ||
| 210 | # CONFIG_SH_7722_SOLUTION_ENGINE is not set | ||
| 211 | CONFIG_SH_MIGOR=y | ||
| 212 | |||
| 213 | # | ||
| 214 | # Timer and clock configuration | ||
| 215 | # | ||
| 216 | CONFIG_SH_TMU=y | ||
| 217 | CONFIG_SH_TIMER_IRQ=16 | ||
| 218 | CONFIG_SH_PCLK_FREQ=33333333 | ||
| 219 | # CONFIG_TICK_ONESHOT is not set | ||
| 220 | # CONFIG_NO_HZ is not set | ||
| 221 | # CONFIG_HIGH_RES_TIMERS is not set | ||
| 222 | CONFIG_GENERIC_CLOCKEVENTS_BUILD=y | ||
| 223 | |||
| 224 | # | ||
| 225 | # CPU Frequency scaling | ||
| 226 | # | ||
| 227 | # CONFIG_CPU_FREQ is not set | ||
| 228 | |||
| 229 | # | ||
| 230 | # DMA support | ||
| 231 | # | ||
| 232 | # CONFIG_SH_DMA is not set | ||
| 233 | |||
| 234 | # | ||
| 235 | # Companion Chips | ||
| 236 | # | ||
| 237 | |||
| 238 | # | ||
| 239 | # Additional SuperH Device Drivers | ||
| 240 | # | ||
| 241 | # CONFIG_HEARTBEAT is not set | ||
| 242 | # CONFIG_PUSH_SWITCH is not set | ||
| 243 | |||
| 244 | # | ||
| 245 | # Kernel features | ||
| 246 | # | ||
| 247 | # CONFIG_HZ_100 is not set | ||
| 248 | CONFIG_HZ_250=y | ||
| 249 | # CONFIG_HZ_300 is not set | ||
| 250 | # CONFIG_HZ_1000 is not set | ||
| 251 | CONFIG_HZ=250 | ||
| 252 | # CONFIG_SCHED_HRTICK is not set | ||
| 253 | # CONFIG_KEXEC is not set | ||
| 254 | # CONFIG_CRASH_DUMP is not set | ||
| 255 | CONFIG_PREEMPT_NONE=y | ||
| 256 | # CONFIG_PREEMPT_VOLUNTARY is not set | ||
| 257 | # CONFIG_PREEMPT is not set | ||
| 258 | CONFIG_RCU_TRACE=y | ||
| 259 | CONFIG_GUSA=y | ||
| 260 | |||
| 261 | # | ||
| 262 | # Boot options | ||
| 263 | # | ||
| 264 | CONFIG_ZERO_PAGE_OFFSET=0x00001000 | ||
| 265 | CONFIG_BOOT_LINK_OFFSET=0x00800000 | ||
| 266 | CONFIG_CMDLINE_BOOL=y | ||
| 267 | CONFIG_CMDLINE="console=ttySC0,115200 earlyprintk=serial ip=on" | ||
| 268 | |||
| 269 | # | ||
| 270 | # Bus options | ||
| 271 | # | ||
| 272 | # CONFIG_ARCH_SUPPORTS_MSI is not set | ||
| 273 | # CONFIG_PCCARD is not set | ||
| 274 | |||
| 275 | # | ||
| 276 | # Executable file formats | ||
| 277 | # | ||
| 278 | CONFIG_BINFMT_ELF=y | ||
| 279 | # CONFIG_BINFMT_MISC is not set | ||
| 280 | |||
| 281 | # | ||
| 282 | # Networking | ||
| 283 | # | ||
| 284 | CONFIG_NET=y | ||
| 285 | |||
| 286 | # | ||
| 287 | # Networking options | ||
| 288 | # | ||
| 289 | CONFIG_PACKET=y | ||
| 290 | # CONFIG_PACKET_MMAP is not set | ||
| 291 | CONFIG_UNIX=y | ||
| 292 | CONFIG_XFRM=y | ||
| 293 | # CONFIG_XFRM_USER is not set | ||
| 294 | # CONFIG_XFRM_SUB_POLICY is not set | ||
| 295 | # CONFIG_XFRM_MIGRATE is not set | ||
| 296 | # CONFIG_XFRM_STATISTICS is not set | ||
| 297 | # CONFIG_NET_KEY is not set | ||
| 298 | CONFIG_INET=y | ||
| 299 | # CONFIG_IP_MULTICAST is not set | ||
| 300 | # CONFIG_IP_ADVANCED_ROUTER is not set | ||
| 301 | CONFIG_IP_FIB_HASH=y | ||
| 302 | CONFIG_IP_PNP=y | ||
| 303 | CONFIG_IP_PNP_DHCP=y | ||
| 304 | # CONFIG_IP_PNP_BOOTP is not set | ||
| 305 | # CONFIG_IP_PNP_RARP is not set | ||
| 306 | # CONFIG_NET_IPIP is not set | ||
| 307 | # CONFIG_NET_IPGRE is not set | ||
| 308 | # CONFIG_ARPD is not set | ||
| 309 | # CONFIG_SYN_COOKIES is not set | ||
| 310 | # CONFIG_INET_AH is not set | ||
| 311 | # CONFIG_INET_ESP is not set | ||
| 312 | # CONFIG_INET_IPCOMP is not set | ||
| 313 | # CONFIG_INET_XFRM_TUNNEL is not set | ||
| 314 | # CONFIG_INET_TUNNEL is not set | ||
| 315 | CONFIG_INET_XFRM_MODE_TRANSPORT=y | ||
| 316 | CONFIG_INET_XFRM_MODE_TUNNEL=y | ||
| 317 | CONFIG_INET_XFRM_MODE_BEET=y | ||
| 318 | # CONFIG_INET_LRO is not set | ||
| 319 | CONFIG_INET_DIAG=y | ||
| 320 | CONFIG_INET_TCP_DIAG=y | ||
| 321 | # CONFIG_TCP_CONG_ADVANCED is not set | ||
| 322 | CONFIG_TCP_CONG_CUBIC=y | ||
| 323 | CONFIG_DEFAULT_TCP_CONG="cubic" | ||
| 324 | # CONFIG_TCP_MD5SIG is not set | ||
| 325 | # CONFIG_IPV6 is not set | ||
| 326 | # CONFIG_INET6_XFRM_TUNNEL is not set | ||
| 327 | # CONFIG_INET6_TUNNEL is not set | ||
| 328 | # CONFIG_NETWORK_SECMARK is not set | ||
| 329 | # CONFIG_NETFILTER is not set | ||
| 330 | # CONFIG_IP_DCCP is not set | ||
| 331 | # CONFIG_IP_SCTP is not set | ||
| 332 | # CONFIG_TIPC is not set | ||
| 333 | # CONFIG_ATM is not set | ||
| 334 | # CONFIG_BRIDGE is not set | ||
| 335 | # CONFIG_VLAN_8021Q is not set | ||
| 336 | # CONFIG_DECNET is not set | ||
| 337 | # CONFIG_LLC2 is not set | ||
| 338 | # CONFIG_IPX is not set | ||
| 339 | # CONFIG_ATALK is not set | ||
| 340 | # CONFIG_X25 is not set | ||
| 341 | # CONFIG_LAPB is not set | ||
| 342 | # CONFIG_ECONET is not set | ||
| 343 | # CONFIG_WAN_ROUTER is not set | ||
| 344 | # CONFIG_NET_SCHED is not set | ||
| 345 | |||
| 346 | # | ||
| 347 | # Network testing | ||
| 348 | # | ||
| 349 | # CONFIG_NET_PKTGEN is not set | ||
| 350 | # CONFIG_HAMRADIO is not set | ||
| 351 | # CONFIG_CAN is not set | ||
| 352 | # CONFIG_IRDA is not set | ||
| 353 | # CONFIG_BT is not set | ||
| 354 | # CONFIG_AF_RXRPC is not set | ||
| 355 | |||
| 356 | # | ||
| 357 | # Wireless | ||
| 358 | # | ||
| 359 | # CONFIG_CFG80211 is not set | ||
| 360 | CONFIG_WIRELESS_EXT=y | ||
| 361 | # CONFIG_MAC80211 is not set | ||
| 362 | # CONFIG_IEEE80211 is not set | ||
| 363 | # CONFIG_RFKILL is not set | ||
| 364 | # CONFIG_NET_9P is not set | ||
| 365 | |||
| 366 | # | ||
| 367 | # Device Drivers | ||
| 368 | # | ||
| 369 | |||
| 370 | # | ||
| 371 | # Generic Driver Options | ||
| 372 | # | ||
| 373 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" | ||
| 374 | CONFIG_STANDALONE=y | ||
| 375 | CONFIG_PREVENT_FIRMWARE_BUILD=y | ||
| 376 | CONFIG_FW_LOADER=m | ||
| 377 | # CONFIG_SYS_HYPERVISOR is not set | ||
| 378 | # CONFIG_CONNECTOR is not set | ||
| 379 | # CONFIG_MTD is not set | ||
| 380 | # CONFIG_PARPORT is not set | ||
| 381 | CONFIG_BLK_DEV=y | ||
| 382 | # CONFIG_BLK_DEV_COW_COMMON is not set | ||
| 383 | # CONFIG_BLK_DEV_LOOP is not set | ||
| 384 | # CONFIG_BLK_DEV_NBD is not set | ||
| 385 | CONFIG_BLK_DEV_RAM=y | ||
| 386 | CONFIG_BLK_DEV_RAM_COUNT=16 | ||
| 387 | CONFIG_BLK_DEV_RAM_SIZE=4096 | ||
| 388 | CONFIG_BLK_DEV_RAM_BLOCKSIZE=1024 | ||
| 389 | # CONFIG_CDROM_PKTCDVD is not set | ||
| 390 | # CONFIG_ATA_OVER_ETH is not set | ||
| 391 | CONFIG_MISC_DEVICES=y | ||
| 392 | # CONFIG_EEPROM_93CX6 is not set | ||
| 393 | # CONFIG_IDE is not set | ||
| 394 | |||
| 395 | # | ||
| 396 | # SCSI device support | ||
| 397 | # | ||
| 398 | # CONFIG_RAID_ATTRS is not set | ||
| 399 | CONFIG_SCSI=y | ||
| 400 | CONFIG_SCSI_DMA=y | ||
| 401 | # CONFIG_SCSI_TGT is not set | ||
| 402 | # CONFIG_SCSI_NETLINK is not set | ||
| 403 | CONFIG_SCSI_PROC_FS=y | ||
| 404 | |||
| 405 | # | ||
| 406 | # SCSI support type (disk, tape, CD-ROM) | ||
| 407 | # | ||
| 408 | CONFIG_BLK_DEV_SD=y | ||
| 409 | # CONFIG_CHR_DEV_ST is not set | ||
| 410 | # CONFIG_CHR_DEV_OSST is not set | ||
| 411 | # CONFIG_BLK_DEV_SR is not set | ||
| 412 | # CONFIG_CHR_DEV_SG is not set | ||
| 413 | # CONFIG_CHR_DEV_SCH is not set | ||
| 414 | |||
| 415 | # | ||
| 416 | # Some SCSI devices (e.g. CD jukebox) support multiple LUNs | ||
| 417 | # | ||
| 418 | # CONFIG_SCSI_MULTI_LUN is not set | ||
| 419 | # CONFIG_SCSI_CONSTANTS is not set | ||
| 420 | # CONFIG_SCSI_LOGGING is not set | ||
| 421 | # CONFIG_SCSI_SCAN_ASYNC is not set | ||
| 422 | CONFIG_SCSI_WAIT_SCAN=m | ||
| 423 | |||
| 424 | # | ||
| 425 | # SCSI Transports | ||
| 426 | # | ||
| 427 | # CONFIG_SCSI_SPI_ATTRS is not set | ||
| 428 | # CONFIG_SCSI_FC_ATTRS is not set | ||
| 429 | # CONFIG_SCSI_ISCSI_ATTRS is not set | ||
| 430 | # CONFIG_SCSI_SAS_LIBSAS is not set | ||
| 431 | # CONFIG_SCSI_SRP_ATTRS is not set | ||
| 432 | CONFIG_SCSI_LOWLEVEL=y | ||
| 433 | # CONFIG_ISCSI_TCP is not set | ||
| 434 | # CONFIG_SCSI_DEBUG is not set | ||
| 435 | # CONFIG_ATA is not set | ||
| 436 | # CONFIG_MD is not set | ||
| 437 | CONFIG_NETDEVICES=y | ||
| 438 | # CONFIG_NETDEVICES_MULTIQUEUE is not set | ||
| 439 | # CONFIG_DUMMY is not set | ||
| 440 | # CONFIG_BONDING is not set | ||
| 441 | # CONFIG_MACVLAN is not set | ||
| 442 | # CONFIG_EQUALIZER is not set | ||
| 443 | # CONFIG_TUN is not set | ||
| 444 | # CONFIG_VETH is not set | ||
| 445 | # CONFIG_PHYLIB is not set | ||
| 446 | CONFIG_NET_ETHERNET=y | ||
| 447 | CONFIG_MII=y | ||
| 448 | # CONFIG_AX88796 is not set | ||
| 449 | # CONFIG_STNIC is not set | ||
| 450 | CONFIG_SMC91X=y | ||
| 451 | # CONFIG_IBM_NEW_EMAC_ZMII is not set | ||
| 452 | # CONFIG_IBM_NEW_EMAC_RGMII is not set | ||
| 453 | # CONFIG_IBM_NEW_EMAC_TAH is not set | ||
| 454 | # CONFIG_IBM_NEW_EMAC_EMAC4 is not set | ||
| 455 | # CONFIG_B44 is not set | ||
| 456 | # CONFIG_NETDEV_1000 is not set | ||
| 457 | # CONFIG_NETDEV_10000 is not set | ||
| 458 | |||
| 459 | # | ||
| 460 | # Wireless LAN | ||
| 461 | # | ||
| 462 | # CONFIG_WLAN_PRE80211 is not set | ||
| 463 | # CONFIG_WLAN_80211 is not set | ||
| 464 | # CONFIG_WAN is not set | ||
| 465 | # CONFIG_PPP is not set | ||
| 466 | # CONFIG_SLIP is not set | ||
| 467 | # CONFIG_NETCONSOLE is not set | ||
| 468 | # CONFIG_NETPOLL is not set | ||
| 469 | # CONFIG_NET_POLL_CONTROLLER is not set | ||
| 470 | # CONFIG_ISDN is not set | ||
| 471 | # CONFIG_PHONE is not set | ||
| 472 | |||
| 473 | # | ||
| 474 | # Input device support | ||
| 475 | # | ||
| 476 | CONFIG_INPUT=y | ||
| 477 | # CONFIG_INPUT_FF_MEMLESS is not set | ||
| 478 | # CONFIG_INPUT_POLLDEV is not set | ||
| 479 | |||
| 480 | # | ||
| 481 | # Userland interfaces | ||
| 482 | # | ||
| 483 | # CONFIG_INPUT_MOUSEDEV is not set | ||
| 484 | # CONFIG_INPUT_JOYDEV is not set | ||
| 485 | # CONFIG_INPUT_EVDEV is not set | ||
| 486 | # CONFIG_INPUT_EVBUG is not set | ||
| 487 | |||
| 488 | # | ||
| 489 | # Input Device Drivers | ||
| 490 | # | ||
| 491 | # CONFIG_INPUT_KEYBOARD is not set | ||
| 492 | # CONFIG_INPUT_MOUSE is not set | ||
| 493 | # CONFIG_INPUT_JOYSTICK is not set | ||
| 494 | # CONFIG_INPUT_TABLET is not set | ||
| 495 | # CONFIG_INPUT_TOUCHSCREEN is not set | ||
| 496 | # CONFIG_INPUT_MISC is not set | ||
| 497 | |||
| 498 | # | ||
| 499 | # Hardware I/O ports | ||
| 500 | # | ||
| 501 | # CONFIG_SERIO is not set | ||
| 502 | # CONFIG_GAMEPORT is not set | ||
| 503 | |||
| 504 | # | ||
| 505 | # Character devices | ||
| 506 | # | ||
| 507 | CONFIG_VT=y | ||
| 508 | CONFIG_VT_CONSOLE=y | ||
| 509 | CONFIG_HW_CONSOLE=y | ||
| 510 | CONFIG_VT_HW_CONSOLE_BINDING=y | ||
| 511 | # CONFIG_SERIAL_NONSTANDARD is not set | ||
| 512 | |||
| 513 | # | ||
| 514 | # Serial drivers | ||
| 515 | # | ||
| 516 | # CONFIG_SERIAL_8250 is not set | ||
| 517 | |||
| 518 | # | ||
| 519 | # Non-8250 serial port support | ||
| 520 | # | ||
| 521 | CONFIG_SERIAL_SH_SCI=y | ||
| 522 | CONFIG_SERIAL_SH_SCI_NR_UARTS=3 | ||
| 523 | CONFIG_SERIAL_SH_SCI_CONSOLE=y | ||
| 524 | CONFIG_SERIAL_CORE=y | ||
| 525 | CONFIG_SERIAL_CORE_CONSOLE=y | ||
| 526 | CONFIG_UNIX98_PTYS=y | ||
| 527 | CONFIG_LEGACY_PTYS=y | ||
| 528 | CONFIG_LEGACY_PTY_COUNT=256 | ||
| 529 | # CONFIG_IPMI_HANDLER is not set | ||
| 530 | CONFIG_HW_RANDOM=y | ||
| 531 | # CONFIG_R3964 is not set | ||
| 532 | # CONFIG_RAW_DRIVER is not set | ||
| 533 | # CONFIG_TCG_TPM is not set | ||
| 534 | # CONFIG_I2C is not set | ||
| 535 | |||
| 536 | # | ||
| 537 | # SPI support | ||
| 538 | # | ||
| 539 | # CONFIG_SPI is not set | ||
| 540 | # CONFIG_SPI_MASTER is not set | ||
| 541 | # CONFIG_W1 is not set | ||
| 542 | # CONFIG_POWER_SUPPLY is not set | ||
| 543 | # CONFIG_HWMON is not set | ||
| 544 | # CONFIG_WATCHDOG is not set | ||
| 545 | |||
| 546 | # | ||
| 547 | # Sonics Silicon Backplane | ||
| 548 | # | ||
| 549 | CONFIG_SSB_POSSIBLE=y | ||
| 550 | # CONFIG_SSB is not set | ||
| 551 | |||
| 552 | # | ||
| 553 | # Multifunction device drivers | ||
| 554 | # | ||
| 555 | # CONFIG_MFD_SM501 is not set | ||
| 556 | |||
| 557 | # | ||
| 558 | # Multimedia devices | ||
| 559 | # | ||
| 560 | # CONFIG_VIDEO_DEV is not set | ||
| 561 | # CONFIG_DVB_CORE is not set | ||
| 562 | # CONFIG_DAB is not set | ||
| 563 | |||
| 564 | # | ||
| 565 | # Graphics support | ||
| 566 | # | ||
| 567 | # CONFIG_VGASTATE is not set | ||
| 568 | # CONFIG_VIDEO_OUTPUT_CONTROL is not set | ||
| 569 | # CONFIG_FB is not set | ||
| 570 | # CONFIG_BACKLIGHT_LCD_SUPPORT is not set | ||
| 571 | |||
| 572 | # | ||
| 573 | # Display device support | ||
| 574 | # | ||
| 575 | # CONFIG_DISPLAY_SUPPORT is not set | ||
| 576 | |||
| 577 | # | ||
| 578 | # Console display driver support | ||
| 579 | # | ||
| 580 | CONFIG_DUMMY_CONSOLE=y | ||
| 581 | |||
| 582 | # | ||
| 583 | # Sound | ||
| 584 | # | ||
| 585 | # CONFIG_SOUND is not set | ||
| 586 | CONFIG_HID_SUPPORT=y | ||
| 587 | CONFIG_HID=y | ||
| 588 | # CONFIG_HID_DEBUG is not set | ||
| 589 | # CONFIG_HIDRAW is not set | ||
| 590 | CONFIG_USB_SUPPORT=y | ||
| 591 | CONFIG_USB_ARCH_HAS_HCD=y | ||
| 592 | # CONFIG_USB_ARCH_HAS_OHCI is not set | ||
| 593 | # CONFIG_USB_ARCH_HAS_EHCI is not set | ||
| 594 | # CONFIG_USB is not set | ||
| 595 | |||
| 596 | # | ||
| 597 | # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' | ||
| 598 | # | ||
| 599 | CONFIG_USB_GADGET=y | ||
| 600 | # CONFIG_USB_GADGET_DEBUG_FILES is not set | ||
| 601 | # CONFIG_USB_GADGET_DEBUG_FS is not set | ||
| 602 | CONFIG_USB_GADGET_SELECTED=y | ||
| 603 | # CONFIG_USB_GADGET_AMD5536UDC is not set | ||
| 604 | # CONFIG_USB_GADGET_ATMEL_USBA is not set | ||
| 605 | # CONFIG_USB_GADGET_FSL_USB2 is not set | ||
| 606 | # CONFIG_USB_GADGET_NET2280 is not set | ||
| 607 | # CONFIG_USB_GADGET_PXA2XX is not set | ||
| 608 | CONFIG_USB_GADGET_M66592=y | ||
| 609 | CONFIG_USB_M66592=y | ||
| 610 | CONFIG_SUPERH_BUILT_IN_M66592=y | ||
| 611 | # CONFIG_USB_GADGET_GOKU is not set | ||
| 612 | # CONFIG_USB_GADGET_LH7A40X is not set | ||
| 613 | # CONFIG_USB_GADGET_OMAP is not set | ||
| 614 | # CONFIG_USB_GADGET_S3C2410 is not set | ||
| 615 | # CONFIG_USB_GADGET_AT91 is not set | ||
| 616 | # CONFIG_USB_GADGET_DUMMY_HCD is not set | ||
| 617 | CONFIG_USB_GADGET_DUALSPEED=y | ||
| 618 | # CONFIG_USB_ZERO is not set | ||
| 619 | # CONFIG_USB_ETH is not set | ||
| 620 | # CONFIG_USB_GADGETFS is not set | ||
| 621 | # CONFIG_USB_FILE_STORAGE is not set | ||
| 622 | CONFIG_USB_G_SERIAL=y | ||
| 623 | # CONFIG_USB_MIDI_GADGET is not set | ||
| 624 | # CONFIG_USB_G_PRINTER is not set | ||
| 625 | # CONFIG_MMC is not set | ||
| 626 | # CONFIG_NEW_LEDS is not set | ||
| 627 | CONFIG_RTC_LIB=y | ||
| 628 | CONFIG_RTC_CLASS=y | ||
| 629 | CONFIG_RTC_HCTOSYS=y | ||
| 630 | CONFIG_RTC_HCTOSYS_DEVICE="rtc0" | ||
| 631 | # CONFIG_RTC_DEBUG is not set | ||
| 632 | |||
| 633 | # | ||
| 634 | # RTC interfaces | ||
| 635 | # | ||
| 636 | CONFIG_RTC_INTF_SYSFS=y | ||
| 637 | CONFIG_RTC_INTF_PROC=y | ||
| 638 | CONFIG_RTC_INTF_DEV=y | ||
| 639 | # CONFIG_RTC_INTF_DEV_UIE_EMUL is not set | ||
| 640 | # CONFIG_RTC_DRV_TEST is not set | ||
| 641 | |||
| 642 | # | ||
| 643 | # SPI RTC drivers | ||
| 644 | # | ||
| 645 | |||
| 646 | # | ||
| 647 | # Platform RTC drivers | ||
| 648 | # | ||
| 649 | # CONFIG_RTC_DRV_DS1553 is not set | ||
| 650 | # CONFIG_RTC_DRV_STK17TA8 is not set | ||
| 651 | # CONFIG_RTC_DRV_DS1742 is not set | ||
| 652 | # CONFIG_RTC_DRV_M48T86 is not set | ||
| 653 | # CONFIG_RTC_DRV_M48T59 is not set | ||
| 654 | # CONFIG_RTC_DRV_V3020 is not set | ||
| 655 | |||
| 656 | # | ||
| 657 | # on-CPU RTC drivers | ||
| 658 | # | ||
| 659 | CONFIG_RTC_DRV_SH=y | ||
| 660 | |||
| 661 | # | ||
| 662 | # Userspace I/O | ||
| 663 | # | ||
| 664 | # CONFIG_UIO is not set | ||
| 665 | |||
| 666 | # | ||
| 667 | # File systems | ||
| 668 | # | ||
| 669 | # CONFIG_EXT2_FS is not set | ||
| 670 | # CONFIG_EXT3_FS is not set | ||
| 671 | # CONFIG_EXT4DEV_FS is not set | ||
| 672 | # CONFIG_REISERFS_FS is not set | ||
| 673 | # CONFIG_JFS_FS is not set | ||
| 674 | # CONFIG_FS_POSIX_ACL is not set | ||
| 675 | # CONFIG_XFS_FS is not set | ||
| 676 | # CONFIG_GFS2_FS is not set | ||
| 677 | # CONFIG_OCFS2_FS is not set | ||
| 678 | # CONFIG_MINIX_FS is not set | ||
| 679 | # CONFIG_ROMFS_FS is not set | ||
| 680 | # CONFIG_INOTIFY is not set | ||
| 681 | # CONFIG_QUOTA is not set | ||
| 682 | # CONFIG_DNOTIFY is not set | ||
| 683 | # CONFIG_AUTOFS_FS is not set | ||
| 684 | # CONFIG_AUTOFS4_FS is not set | ||
| 685 | # CONFIG_FUSE_FS is not set | ||
| 686 | |||
| 687 | # | ||
| 688 | # CD-ROM/DVD Filesystems | ||
| 689 | # | ||
| 690 | # CONFIG_ISO9660_FS is not set | ||
| 691 | # CONFIG_UDF_FS is not set | ||
| 692 | |||
| 693 | # | ||
| 694 | # DOS/FAT/NT Filesystems | ||
| 695 | # | ||
| 696 | # CONFIG_MSDOS_FS is not set | ||
| 697 | # CONFIG_VFAT_FS is not set | ||
| 698 | # CONFIG_NTFS_FS is not set | ||
| 699 | |||
| 700 | # | ||
| 701 | # Pseudo filesystems | ||
| 702 | # | ||
| 703 | CONFIG_PROC_FS=y | ||
| 704 | CONFIG_PROC_KCORE=y | ||
| 705 | CONFIG_PROC_SYSCTL=y | ||
| 706 | CONFIG_SYSFS=y | ||
| 707 | CONFIG_TMPFS=y | ||
| 708 | # CONFIG_TMPFS_POSIX_ACL is not set | ||
| 709 | # CONFIG_HUGETLBFS is not set | ||
| 710 | # CONFIG_HUGETLB_PAGE is not set | ||
| 711 | # CONFIG_CONFIGFS_FS is not set | ||
| 712 | |||
| 713 | # | ||
| 714 | # Miscellaneous filesystems | ||
| 715 | # | ||
| 716 | # CONFIG_ADFS_FS is not set | ||
| 717 | # CONFIG_AFFS_FS is not set | ||
| 718 | # CONFIG_HFS_FS is not set | ||
| 719 | # CONFIG_HFSPLUS_FS is not set | ||
| 720 | # CONFIG_BEFS_FS is not set | ||
| 721 | # CONFIG_BFS_FS is not set | ||
| 722 | # CONFIG_EFS_FS is not set | ||
| 723 | # CONFIG_CRAMFS is not set | ||
| 724 | # CONFIG_VXFS_FS is not set | ||
| 725 | # CONFIG_HPFS_FS is not set | ||
| 726 | # CONFIG_QNX4FS_FS is not set | ||
| 727 | # CONFIG_SYSV_FS is not set | ||
| 728 | # CONFIG_UFS_FS is not set | ||
| 729 | # CONFIG_NETWORK_FILESYSTEMS is not set | ||
| 730 | |||
| 731 | # | ||
| 732 | # Partition Types | ||
| 733 | # | ||
| 734 | # CONFIG_PARTITION_ADVANCED is not set | ||
| 735 | CONFIG_MSDOS_PARTITION=y | ||
| 736 | # CONFIG_NLS is not set | ||
| 737 | # CONFIG_DLM is not set | ||
| 738 | |||
| 739 | # | ||
| 740 | # Kernel hacking | ||
| 741 | # | ||
| 742 | CONFIG_TRACE_IRQFLAGS_SUPPORT=y | ||
| 743 | # CONFIG_PRINTK_TIME is not set | ||
| 744 | CONFIG_ENABLE_WARN_DEPRECATED=y | ||
| 745 | CONFIG_ENABLE_MUST_CHECK=y | ||
| 746 | # CONFIG_MAGIC_SYSRQ is not set | ||
| 747 | # CONFIG_UNUSED_SYMBOLS is not set | ||
| 748 | CONFIG_DEBUG_FS=y | ||
| 749 | # CONFIG_HEADERS_CHECK is not set | ||
| 750 | # CONFIG_DEBUG_KERNEL is not set | ||
| 751 | # CONFIG_DEBUG_BUGVERBOSE is not set | ||
| 752 | # CONFIG_SAMPLES is not set | ||
| 753 | # CONFIG_SH_STANDARD_BIOS is not set | ||
| 754 | CONFIG_EARLY_SCIF_CONSOLE=y | ||
| 755 | CONFIG_EARLY_SCIF_CONSOLE_PORT=0xffe00000 | ||
| 756 | CONFIG_EARLY_PRINTK=y | ||
| 757 | # CONFIG_SH_KGDB is not set | ||
| 758 | |||
| 759 | # | ||
| 760 | # Security options | ||
| 761 | # | ||
| 762 | # CONFIG_KEYS is not set | ||
| 763 | # CONFIG_SECURITY is not set | ||
| 764 | # CONFIG_SECURITY_FILE_CAPABILITIES is not set | ||
| 765 | CONFIG_CRYPTO=y | ||
| 766 | # CONFIG_CRYPTO_SEQIV is not set | ||
| 767 | # CONFIG_CRYPTO_MANAGER is not set | ||
| 768 | # CONFIG_CRYPTO_HMAC is not set | ||
| 769 | # CONFIG_CRYPTO_XCBC is not set | ||
| 770 | # CONFIG_CRYPTO_NULL is not set | ||
| 771 | # CONFIG_CRYPTO_MD4 is not set | ||
| 772 | # CONFIG_CRYPTO_MD5 is not set | ||
| 773 | # CONFIG_CRYPTO_SHA1 is not set | ||
| 774 | # CONFIG_CRYPTO_SHA256 is not set | ||
| 775 | # CONFIG_CRYPTO_SHA512 is not set | ||
| 776 | # CONFIG_CRYPTO_WP512 is not set | ||
| 777 | # CONFIG_CRYPTO_TGR192 is not set | ||
| 778 | # CONFIG_CRYPTO_GF128MUL is not set | ||
| 779 | # CONFIG_CRYPTO_ECB is not set | ||
| 780 | # CONFIG_CRYPTO_CBC is not set | ||
| 781 | # CONFIG_CRYPTO_PCBC is not set | ||
| 782 | # CONFIG_CRYPTO_LRW is not set | ||
| 783 | # CONFIG_CRYPTO_XTS is not set | ||
| 784 | # CONFIG_CRYPTO_CTR is not set | ||
| 785 | # CONFIG_CRYPTO_GCM is not set | ||
| 786 | # CONFIG_CRYPTO_CCM is not set | ||
| 787 | # CONFIG_CRYPTO_CRYPTD is not set | ||
| 788 | # CONFIG_CRYPTO_DES is not set | ||
| 789 | # CONFIG_CRYPTO_FCRYPT is not set | ||
| 790 | # CONFIG_CRYPTO_BLOWFISH is not set | ||
| 791 | # CONFIG_CRYPTO_TWOFISH is not set | ||
| 792 | # CONFIG_CRYPTO_SERPENT is not set | ||
| 793 | # CONFIG_CRYPTO_AES is not set | ||
| 794 | # CONFIG_CRYPTO_CAST5 is not set | ||
| 795 | # CONFIG_CRYPTO_CAST6 is not set | ||
| 796 | # CONFIG_CRYPTO_TEA is not set | ||
| 797 | # CONFIG_CRYPTO_ARC4 is not set | ||
| 798 | # CONFIG_CRYPTO_KHAZAD is not set | ||
| 799 | # CONFIG_CRYPTO_ANUBIS is not set | ||
| 800 | # CONFIG_CRYPTO_SEED is not set | ||
| 801 | # CONFIG_CRYPTO_SALSA20 is not set | ||
| 802 | # CONFIG_CRYPTO_DEFLATE is not set | ||
| 803 | # CONFIG_CRYPTO_MICHAEL_MIC is not set | ||
| 804 | # CONFIG_CRYPTO_CRC32C is not set | ||
| 805 | # CONFIG_CRYPTO_CAMELLIA is not set | ||
| 806 | # CONFIG_CRYPTO_TEST is not set | ||
| 807 | # CONFIG_CRYPTO_AUTHENC is not set | ||
| 808 | # CONFIG_CRYPTO_LZO is not set | ||
| 809 | CONFIG_CRYPTO_HW=y | ||
| 810 | |||
| 811 | # | ||
| 812 | # Library routines | ||
| 813 | # | ||
| 814 | CONFIG_BITREVERSE=y | ||
| 815 | # CONFIG_CRC_CCITT is not set | ||
| 816 | # CONFIG_CRC16 is not set | ||
| 817 | # CONFIG_CRC_ITU_T is not set | ||
| 818 | CONFIG_CRC32=y | ||
| 819 | # CONFIG_CRC7 is not set | ||
| 820 | # CONFIG_LIBCRC32C is not set | ||
| 821 | CONFIG_PLIST=y | ||
| 822 | CONFIG_HAS_IOMEM=y | ||
| 823 | CONFIG_HAS_IOPORT=y | ||
| 824 | CONFIG_HAS_DMA=y | ||
diff --git a/arch/sh/configs/rts7751r2d1_defconfig b/arch/sh/configs/rts7751r2d1_defconfig index 2dc754e5b733..3a915fd436d9 100644 --- a/arch/sh/configs/rts7751r2d1_defconfig +++ b/arch/sh/configs/rts7751r2d1_defconfig | |||
| @@ -1,9 +1,10 @@ | |||
| 1 | # | 1 | # |
| 2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
| 3 | # Linux kernel version: 2.6.23-rc2 | 3 | # Linux kernel version: 2.6.24 |
| 4 | # Tue Aug 14 18:04:44 2007 | 4 | # Thu Feb 7 16:25:55 2008 |
| 5 | # | 5 | # |
| 6 | CONFIG_SUPERH=y | 6 | CONFIG_SUPERH=y |
| 7 | CONFIG_SUPERH32=y | ||
| 7 | CONFIG_RWSEM_GENERIC_SPINLOCK=y | 8 | CONFIG_RWSEM_GENERIC_SPINLOCK=y |
| 8 | CONFIG_GENERIC_BUG=y | 9 | CONFIG_GENERIC_BUG=y |
| 9 | CONFIG_GENERIC_FIND_NEXT_BIT=y | 10 | CONFIG_GENERIC_FIND_NEXT_BIT=y |
| @@ -36,9 +37,14 @@ CONFIG_SYSVIPC_SYSCTL=y | |||
| 36 | # CONFIG_BSD_PROCESS_ACCT is not set | 37 | # CONFIG_BSD_PROCESS_ACCT is not set |
| 37 | # CONFIG_TASKSTATS is not set | 38 | # CONFIG_TASKSTATS is not set |
| 38 | # CONFIG_USER_NS is not set | 39 | # CONFIG_USER_NS is not set |
| 40 | # CONFIG_PID_NS is not set | ||
| 39 | # CONFIG_AUDIT is not set | 41 | # CONFIG_AUDIT is not set |
| 40 | # CONFIG_IKCONFIG is not set | 42 | # CONFIG_IKCONFIG is not set |
| 41 | CONFIG_LOG_BUF_SHIFT=14 | 43 | CONFIG_LOG_BUF_SHIFT=14 |
| 44 | # CONFIG_CGROUPS is not set | ||
| 45 | CONFIG_FAIR_GROUP_SCHED=y | ||
| 46 | CONFIG_FAIR_USER_SCHED=y | ||
| 47 | # CONFIG_FAIR_CGROUP_SCHED is not set | ||
| 42 | CONFIG_SYSFS_DEPRECATED=y | 48 | CONFIG_SYSFS_DEPRECATED=y |
| 43 | # CONFIG_RELAY is not set | 49 | # CONFIG_RELAY is not set |
| 44 | # CONFIG_BLK_DEV_INITRD is not set | 50 | # CONFIG_BLK_DEV_INITRD is not set |
| @@ -53,6 +59,7 @@ CONFIG_HOTPLUG=y | |||
| 53 | CONFIG_PRINTK=y | 59 | CONFIG_PRINTK=y |
| 54 | CONFIG_BUG=y | 60 | CONFIG_BUG=y |
| 55 | CONFIG_ELF_CORE=y | 61 | CONFIG_ELF_CORE=y |
| 62 | CONFIG_COMPAT_BRK=y | ||
| 56 | CONFIG_BASE_FULL=y | 63 | CONFIG_BASE_FULL=y |
| 57 | CONFIG_FUTEX=y | 64 | CONFIG_FUTEX=y |
| 58 | CONFIG_ANON_INODES=y | 65 | CONFIG_ANON_INODES=y |
| @@ -65,6 +72,13 @@ CONFIG_VM_EVENT_COUNTERS=y | |||
| 65 | CONFIG_SLAB=y | 72 | CONFIG_SLAB=y |
| 66 | # CONFIG_SLUB is not set | 73 | # CONFIG_SLUB is not set |
| 67 | # CONFIG_SLOB is not set | 74 | # CONFIG_SLOB is not set |
| 75 | CONFIG_PROFILING=y | ||
| 76 | # CONFIG_MARKERS is not set | ||
| 77 | CONFIG_OPROFILE=y | ||
| 78 | CONFIG_HAVE_OPROFILE=y | ||
| 79 | # CONFIG_HAVE_KPROBES is not set | ||
| 80 | CONFIG_PROC_PAGE_MONITOR=y | ||
| 81 | CONFIG_SLABINFO=y | ||
| 68 | CONFIG_RT_MUTEXES=y | 82 | CONFIG_RT_MUTEXES=y |
| 69 | # CONFIG_TINY_SHMEM is not set | 83 | # CONFIG_TINY_SHMEM is not set |
| 70 | CONFIG_BASE_SMALL=0 | 84 | CONFIG_BASE_SMALL=0 |
| @@ -91,13 +105,17 @@ CONFIG_DEFAULT_AS=y | |||
| 91 | # CONFIG_DEFAULT_CFQ is not set | 105 | # CONFIG_DEFAULT_CFQ is not set |
| 92 | # CONFIG_DEFAULT_NOOP is not set | 106 | # CONFIG_DEFAULT_NOOP is not set |
| 93 | CONFIG_DEFAULT_IOSCHED="anticipatory" | 107 | CONFIG_DEFAULT_IOSCHED="anticipatory" |
| 108 | CONFIG_CLASSIC_RCU=y | ||
| 109 | # CONFIG_PREEMPT_RCU is not set | ||
| 94 | 110 | ||
| 95 | # | 111 | # |
| 96 | # System type | 112 | # System type |
| 97 | # | 113 | # |
| 98 | CONFIG_CPU_SH4=y | 114 | CONFIG_CPU_SH4=y |
| 99 | # CONFIG_CPU_SUBTYPE_SH7619 is not set | 115 | # CONFIG_CPU_SUBTYPE_SH7619 is not set |
| 116 | # CONFIG_CPU_SUBTYPE_SH7203 is not set | ||
| 100 | # CONFIG_CPU_SUBTYPE_SH7206 is not set | 117 | # CONFIG_CPU_SUBTYPE_SH7206 is not set |
| 118 | # CONFIG_CPU_SUBTYPE_SH7263 is not set | ||
| 101 | # CONFIG_CPU_SUBTYPE_SH7705 is not set | 119 | # CONFIG_CPU_SUBTYPE_SH7705 is not set |
| 102 | # CONFIG_CPU_SUBTYPE_SH7706 is not set | 120 | # CONFIG_CPU_SUBTYPE_SH7706 is not set |
| 103 | # CONFIG_CPU_SUBTYPE_SH7707 is not set | 121 | # CONFIG_CPU_SUBTYPE_SH7707 is not set |
| @@ -105,6 +123,8 @@ CONFIG_CPU_SH4=y | |||
| 105 | # CONFIG_CPU_SUBTYPE_SH7709 is not set | 123 | # CONFIG_CPU_SUBTYPE_SH7709 is not set |
| 106 | # CONFIG_CPU_SUBTYPE_SH7710 is not set | 124 | # CONFIG_CPU_SUBTYPE_SH7710 is not set |
| 107 | # CONFIG_CPU_SUBTYPE_SH7712 is not set | 125 | # CONFIG_CPU_SUBTYPE_SH7712 is not set |
| 126 | # CONFIG_CPU_SUBTYPE_SH7720 is not set | ||
| 127 | # CONFIG_CPU_SUBTYPE_SH7721 is not set | ||
| 108 | # CONFIG_CPU_SUBTYPE_SH7750 is not set | 128 | # CONFIG_CPU_SUBTYPE_SH7750 is not set |
| 109 | # CONFIG_CPU_SUBTYPE_SH7091 is not set | 129 | # CONFIG_CPU_SUBTYPE_SH7091 is not set |
| 110 | # CONFIG_CPU_SUBTYPE_SH7750R is not set | 130 | # CONFIG_CPU_SUBTYPE_SH7750R is not set |
| @@ -113,14 +133,15 @@ CONFIG_CPU_SH4=y | |||
| 113 | CONFIG_CPU_SUBTYPE_SH7751R=y | 133 | CONFIG_CPU_SUBTYPE_SH7751R=y |
| 114 | # CONFIG_CPU_SUBTYPE_SH7760 is not set | 134 | # CONFIG_CPU_SUBTYPE_SH7760 is not set |
| 115 | # CONFIG_CPU_SUBTYPE_SH4_202 is not set | 135 | # CONFIG_CPU_SUBTYPE_SH4_202 is not set |
| 116 | # CONFIG_CPU_SUBTYPE_ST40STB1 is not set | 136 | # CONFIG_CPU_SUBTYPE_SH7763 is not set |
| 117 | # CONFIG_CPU_SUBTYPE_ST40GX1 is not set | ||
| 118 | # CONFIG_CPU_SUBTYPE_SH7770 is not set | 137 | # CONFIG_CPU_SUBTYPE_SH7770 is not set |
| 119 | # CONFIG_CPU_SUBTYPE_SH7780 is not set | 138 | # CONFIG_CPU_SUBTYPE_SH7780 is not set |
| 120 | # CONFIG_CPU_SUBTYPE_SH7785 is not set | 139 | # CONFIG_CPU_SUBTYPE_SH7785 is not set |
| 121 | # CONFIG_CPU_SUBTYPE_SHX3 is not set | 140 | # CONFIG_CPU_SUBTYPE_SHX3 is not set |
| 122 | # CONFIG_CPU_SUBTYPE_SH7343 is not set | 141 | # CONFIG_CPU_SUBTYPE_SH7343 is not set |
| 123 | # CONFIG_CPU_SUBTYPE_SH7722 is not set | 142 | # CONFIG_CPU_SUBTYPE_SH7722 is not set |
| 143 | # CONFIG_CPU_SUBTYPE_SH5_101 is not set | ||
| 144 | # CONFIG_CPU_SUBTYPE_SH5_103 is not set | ||
| 124 | 145 | ||
| 125 | # | 146 | # |
| 126 | # Memory management options | 147 | # Memory management options |
| @@ -130,6 +151,7 @@ CONFIG_MMU=y | |||
| 130 | CONFIG_PAGE_OFFSET=0x80000000 | 151 | CONFIG_PAGE_OFFSET=0x80000000 |
| 131 | CONFIG_MEMORY_START=0x0c000000 | 152 | CONFIG_MEMORY_START=0x0c000000 |
| 132 | CONFIG_MEMORY_SIZE=0x04000000 | 153 | CONFIG_MEMORY_SIZE=0x04000000 |
| 154 | CONFIG_29BIT=y | ||
| 133 | CONFIG_VSYSCALL=y | 155 | CONFIG_VSYSCALL=y |
| 134 | CONFIG_ARCH_FLATMEM_ENABLE=y | 156 | CONFIG_ARCH_FLATMEM_ENABLE=y |
| 135 | CONFIG_ARCH_SPARSEMEM_ENABLE=y | 157 | CONFIG_ARCH_SPARSEMEM_ENABLE=y |
| @@ -147,6 +169,7 @@ CONFIG_FLATMEM_MANUAL=y | |||
| 147 | CONFIG_FLATMEM=y | 169 | CONFIG_FLATMEM=y |
| 148 | CONFIG_FLAT_NODE_MEM_MAP=y | 170 | CONFIG_FLAT_NODE_MEM_MAP=y |
| 149 | CONFIG_SPARSEMEM_STATIC=y | 171 | CONFIG_SPARSEMEM_STATIC=y |
| 172 | # CONFIG_SPARSEMEM_VMEMMAP_ENABLE is not set | ||
| 150 | CONFIG_SPLIT_PTLOCK_CPUS=4 | 173 | CONFIG_SPLIT_PTLOCK_CPUS=4 |
| 151 | # CONFIG_RESOURCES_64BIT is not set | 174 | # CONFIG_RESOURCES_64BIT is not set |
| 152 | CONFIG_ZONE_DMA_FLAG=0 | 175 | CONFIG_ZONE_DMA_FLAG=0 |
| @@ -168,23 +191,22 @@ CONFIG_CPU_LITTLE_ENDIAN=y | |||
| 168 | CONFIG_SH_FPU=y | 191 | CONFIG_SH_FPU=y |
| 169 | # CONFIG_SH_STORE_QUEUES is not set | 192 | # CONFIG_SH_STORE_QUEUES is not set |
| 170 | CONFIG_CPU_HAS_INTEVT=y | 193 | CONFIG_CPU_HAS_INTEVT=y |
| 171 | CONFIG_CPU_HAS_INTC_IRQ=y | ||
| 172 | CONFIG_CPU_HAS_SR_RB=y | 194 | CONFIG_CPU_HAS_SR_RB=y |
| 173 | CONFIG_CPU_HAS_PTEA=y | 195 | CONFIG_CPU_HAS_PTEA=y |
| 196 | CONFIG_CPU_HAS_FPU=y | ||
| 174 | 197 | ||
| 175 | # | 198 | # |
| 176 | # Board support | 199 | # Board support |
| 177 | # | 200 | # |
| 178 | # CONFIG_SH_7751_SYSTEMH is not set | 201 | # CONFIG_SH_7751_SYSTEMH is not set |
| 179 | # CONFIG_SH_SECUREEDGE5410 is not set | 202 | # CONFIG_SH_SECUREEDGE5410 is not set |
| 180 | # CONFIG_SH_HS7751RVOIP is not set | ||
| 181 | CONFIG_SH_RTS7751R2D=y | 203 | CONFIG_SH_RTS7751R2D=y |
| 182 | # CONFIG_SH_LANDISK is not set | 204 | # CONFIG_SH_LANDISK is not set |
| 183 | # CONFIG_SH_TITAN is not set | 205 | # CONFIG_SH_TITAN is not set |
| 184 | # CONFIG_SH_LBOX_RE2 is not set | 206 | # CONFIG_SH_LBOX_RE2 is not set |
| 185 | 207 | ||
| 186 | # | 208 | # |
| 187 | # RTS7751R2D options | 209 | # RTS7751R2D Board Revision |
| 188 | # | 210 | # |
| 189 | # CONFIG_RTS7751R2D_PLUS is not set | 211 | # CONFIG_RTS7751R2D_PLUS is not set |
| 190 | CONFIG_RTS7751R2D_1=y | 212 | CONFIG_RTS7751R2D_1=y |
| @@ -198,6 +220,7 @@ CONFIG_SH_PCLK_FREQ=60000000 | |||
| 198 | # CONFIG_TICK_ONESHOT is not set | 220 | # CONFIG_TICK_ONESHOT is not set |
| 199 | # CONFIG_NO_HZ is not set | 221 | # CONFIG_NO_HZ is not set |
| 200 | # CONFIG_HIGH_RES_TIMERS is not set | 222 | # CONFIG_HIGH_RES_TIMERS is not set |
| 223 | CONFIG_GENERIC_CLOCKEVENTS_BUILD=y | ||
| 201 | 224 | ||
| 202 | # | 225 | # |
| 203 | # CPU Frequency scaling | 226 | # CPU Frequency scaling |
| @@ -227,11 +250,15 @@ CONFIG_HZ_250=y | |||
| 227 | # CONFIG_HZ_300 is not set | 250 | # CONFIG_HZ_300 is not set |
| 228 | # CONFIG_HZ_1000 is not set | 251 | # CONFIG_HZ_1000 is not set |
| 229 | CONFIG_HZ=250 | 252 | CONFIG_HZ=250 |
| 253 | # CONFIG_SCHED_HRTICK is not set | ||
| 230 | # CONFIG_KEXEC is not set | 254 | # CONFIG_KEXEC is not set |
| 231 | # CONFIG_CRASH_DUMP is not set | 255 | # CONFIG_CRASH_DUMP is not set |
| 232 | CONFIG_PREEMPT_NONE=y | 256 | CONFIG_PREEMPT_NONE=y |
| 233 | # CONFIG_PREEMPT_VOLUNTARY is not set | 257 | # CONFIG_PREEMPT_VOLUNTARY is not set |
| 234 | # CONFIG_PREEMPT is not set | 258 | # CONFIG_PREEMPT is not set |
| 259 | CONFIG_RCU_TRACE=y | ||
| 260 | CONFIG_GUSA=y | ||
| 261 | # CONFIG_GUSA_RB is not set | ||
| 235 | 262 | ||
| 236 | # | 263 | # |
| 237 | # Boot options | 264 | # Boot options |
| @@ -250,10 +277,7 @@ CONFIG_SH_PCIDMA_NONCOHERENT=y | |||
| 250 | CONFIG_PCI_AUTO=y | 277 | CONFIG_PCI_AUTO=y |
| 251 | CONFIG_PCI_AUTO_UPDATE_RESOURCES=y | 278 | CONFIG_PCI_AUTO_UPDATE_RESOURCES=y |
| 252 | # CONFIG_ARCH_SUPPORTS_MSI is not set | 279 | # CONFIG_ARCH_SUPPORTS_MSI is not set |
| 253 | 280 | CONFIG_PCI_LEGACY=y | |
| 254 | # | ||
| 255 | # PCCARD (PCMCIA/CardBus) support | ||
| 256 | # | ||
| 257 | # CONFIG_PCCARD is not set | 281 | # CONFIG_PCCARD is not set |
| 258 | CONFIG_HOTPLUG_PCI=y | 282 | CONFIG_HOTPLUG_PCI=y |
| 259 | # CONFIG_HOTPLUG_PCI_FAKE is not set | 283 | # CONFIG_HOTPLUG_PCI_FAKE is not set |
| @@ -281,6 +305,7 @@ CONFIG_XFRM=y | |||
| 281 | # CONFIG_XFRM_USER is not set | 305 | # CONFIG_XFRM_USER is not set |
| 282 | # CONFIG_XFRM_SUB_POLICY is not set | 306 | # CONFIG_XFRM_SUB_POLICY is not set |
| 283 | # CONFIG_XFRM_MIGRATE is not set | 307 | # CONFIG_XFRM_MIGRATE is not set |
| 308 | # CONFIG_XFRM_STATISTICS is not set | ||
| 284 | # CONFIG_NET_KEY is not set | 309 | # CONFIG_NET_KEY is not set |
| 285 | CONFIG_INET=y | 310 | CONFIG_INET=y |
| 286 | # CONFIG_IP_MULTICAST is not set | 311 | # CONFIG_IP_MULTICAST is not set |
| @@ -299,6 +324,7 @@ CONFIG_IP_FIB_HASH=y | |||
| 299 | CONFIG_INET_XFRM_MODE_TRANSPORT=y | 324 | CONFIG_INET_XFRM_MODE_TRANSPORT=y |
| 300 | CONFIG_INET_XFRM_MODE_TUNNEL=y | 325 | CONFIG_INET_XFRM_MODE_TUNNEL=y |
| 301 | CONFIG_INET_XFRM_MODE_BEET=y | 326 | CONFIG_INET_XFRM_MODE_BEET=y |
| 327 | # CONFIG_INET_LRO is not set | ||
| 302 | CONFIG_INET_DIAG=y | 328 | CONFIG_INET_DIAG=y |
| 303 | CONFIG_INET_TCP_DIAG=y | 329 | CONFIG_INET_TCP_DIAG=y |
| 304 | # CONFIG_TCP_CONG_ADVANCED is not set | 330 | # CONFIG_TCP_CONG_ADVANCED is not set |
| @@ -324,10 +350,6 @@ CONFIG_DEFAULT_TCP_CONG="cubic" | |||
| 324 | # CONFIG_LAPB is not set | 350 | # CONFIG_LAPB is not set |
| 325 | # CONFIG_ECONET is not set | 351 | # CONFIG_ECONET is not set |
| 326 | # CONFIG_WAN_ROUTER is not set | 352 | # CONFIG_WAN_ROUTER is not set |
| 327 | |||
| 328 | # | ||
| 329 | # QoS and/or fair queueing | ||
| 330 | # | ||
| 331 | # CONFIG_NET_SCHED is not set | 353 | # CONFIG_NET_SCHED is not set |
| 332 | 354 | ||
| 333 | # | 355 | # |
| @@ -335,6 +357,7 @@ CONFIG_DEFAULT_TCP_CONG="cubic" | |||
| 335 | # | 357 | # |
| 336 | # CONFIG_NET_PKTGEN is not set | 358 | # CONFIG_NET_PKTGEN is not set |
| 337 | # CONFIG_HAMRADIO is not set | 359 | # CONFIG_HAMRADIO is not set |
| 360 | # CONFIG_CAN is not set | ||
| 338 | # CONFIG_IRDA is not set | 361 | # CONFIG_IRDA is not set |
| 339 | # CONFIG_BT is not set | 362 | # CONFIG_BT is not set |
| 340 | # CONFIG_AF_RXRPC is not set | 363 | # CONFIG_AF_RXRPC is not set |
| @@ -356,6 +379,7 @@ CONFIG_WIRELESS_EXT=y | |||
| 356 | # | 379 | # |
| 357 | # Generic Driver Options | 380 | # Generic Driver Options |
| 358 | # | 381 | # |
| 382 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" | ||
| 359 | CONFIG_STANDALONE=y | 383 | CONFIG_STANDALONE=y |
| 360 | CONFIG_PREVENT_FIRMWARE_BUILD=y | 384 | CONFIG_PREVENT_FIRMWARE_BUILD=y |
| 361 | CONFIG_FW_LOADER=m | 385 | CONFIG_FW_LOADER=m |
| @@ -371,6 +395,7 @@ CONFIG_BLK_DEV=y | |||
| 371 | # CONFIG_BLK_DEV_LOOP is not set | 395 | # CONFIG_BLK_DEV_LOOP is not set |
| 372 | # CONFIG_BLK_DEV_NBD is not set | 396 | # CONFIG_BLK_DEV_NBD is not set |
| 373 | # CONFIG_BLK_DEV_SX8 is not set | 397 | # CONFIG_BLK_DEV_SX8 is not set |
| 398 | # CONFIG_BLK_DEV_UB is not set | ||
| 374 | CONFIG_BLK_DEV_RAM=y | 399 | CONFIG_BLK_DEV_RAM=y |
| 375 | CONFIG_BLK_DEV_RAM_COUNT=16 | 400 | CONFIG_BLK_DEV_RAM_COUNT=16 |
| 376 | CONFIG_BLK_DEV_RAM_SIZE=4096 | 401 | CONFIG_BLK_DEV_RAM_SIZE=4096 |
| @@ -420,6 +445,7 @@ CONFIG_SCSI_WAIT_SCAN=m | |||
| 420 | # CONFIG_SCSI_FC_ATTRS is not set | 445 | # CONFIG_SCSI_FC_ATTRS is not set |
| 421 | # CONFIG_SCSI_ISCSI_ATTRS is not set | 446 | # CONFIG_SCSI_ISCSI_ATTRS is not set |
| 422 | # CONFIG_SCSI_SAS_LIBSAS is not set | 447 | # CONFIG_SCSI_SAS_LIBSAS is not set |
| 448 | # CONFIG_SCSI_SRP_ATTRS is not set | ||
| 423 | CONFIG_SCSI_LOWLEVEL=y | 449 | CONFIG_SCSI_LOWLEVEL=y |
| 424 | # CONFIG_ISCSI_TCP is not set | 450 | # CONFIG_ISCSI_TCP is not set |
| 425 | # CONFIG_BLK_DEV_3W_XXXX_RAID is not set | 451 | # CONFIG_BLK_DEV_3W_XXXX_RAID is not set |
| @@ -493,7 +519,9 @@ CONFIG_ATA=y | |||
| 493 | # CONFIG_PATA_MPIIX is not set | 519 | # CONFIG_PATA_MPIIX is not set |
| 494 | # CONFIG_PATA_OLDPIIX is not set | 520 | # CONFIG_PATA_OLDPIIX is not set |
| 495 | # CONFIG_PATA_NETCELL is not set | 521 | # CONFIG_PATA_NETCELL is not set |
| 522 | # CONFIG_PATA_NINJA32 is not set | ||
| 496 | # CONFIG_PATA_NS87410 is not set | 523 | # CONFIG_PATA_NS87410 is not set |
| 524 | # CONFIG_PATA_NS87415 is not set | ||
| 497 | # CONFIG_PATA_OPTI is not set | 525 | # CONFIG_PATA_OPTI is not set |
| 498 | # CONFIG_PATA_OPTIDMA is not set | 526 | # CONFIG_PATA_OPTIDMA is not set |
| 499 | # CONFIG_PATA_PDC_OLD is not set | 527 | # CONFIG_PATA_PDC_OLD is not set |
| @@ -508,14 +536,7 @@ CONFIG_ATA=y | |||
| 508 | # CONFIG_PATA_WINBOND is not set | 536 | # CONFIG_PATA_WINBOND is not set |
| 509 | CONFIG_PATA_PLATFORM=y | 537 | CONFIG_PATA_PLATFORM=y |
| 510 | # CONFIG_MD is not set | 538 | # CONFIG_MD is not set |
| 511 | |||
| 512 | # | ||
| 513 | # Fusion MPT device support | ||
| 514 | # | ||
| 515 | # CONFIG_FUSION is not set | 539 | # CONFIG_FUSION is not set |
| 516 | # CONFIG_FUSION_SPI is not set | ||
| 517 | # CONFIG_FUSION_FC is not set | ||
| 518 | # CONFIG_FUSION_SAS is not set | ||
| 519 | 540 | ||
| 520 | # | 541 | # |
| 521 | # IEEE 1394 (FireWire) support | 542 | # IEEE 1394 (FireWire) support |
| @@ -530,25 +551,31 @@ CONFIG_NETDEVICES=y | |||
| 530 | # CONFIG_MACVLAN is not set | 551 | # CONFIG_MACVLAN is not set |
| 531 | # CONFIG_EQUALIZER is not set | 552 | # CONFIG_EQUALIZER is not set |
| 532 | # CONFIG_TUN is not set | 553 | # CONFIG_TUN is not set |
| 554 | # CONFIG_VETH is not set | ||
| 533 | # CONFIG_ARCNET is not set | 555 | # CONFIG_ARCNET is not set |
| 534 | # CONFIG_PHYLIB is not set | 556 | # CONFIG_PHYLIB is not set |
| 535 | CONFIG_NET_ETHERNET=y | 557 | CONFIG_NET_ETHERNET=y |
| 536 | CONFIG_MII=y | 558 | CONFIG_MII=y |
| 559 | # CONFIG_AX88796 is not set | ||
| 537 | # CONFIG_STNIC is not set | 560 | # CONFIG_STNIC is not set |
| 538 | # CONFIG_HAPPYMEAL is not set | 561 | # CONFIG_HAPPYMEAL is not set |
| 539 | # CONFIG_SUNGEM is not set | 562 | # CONFIG_SUNGEM is not set |
| 540 | # CONFIG_CASSINI is not set | 563 | # CONFIG_CASSINI is not set |
| 541 | # CONFIG_NET_VENDOR_3COM is not set | 564 | # CONFIG_NET_VENDOR_3COM is not set |
| 542 | # CONFIG_SMC91X is not set | 565 | # CONFIG_SMC91X is not set |
| 566 | # CONFIG_ENC28J60 is not set | ||
| 543 | # CONFIG_NET_TULIP is not set | 567 | # CONFIG_NET_TULIP is not set |
| 544 | # CONFIG_HP100 is not set | 568 | # CONFIG_HP100 is not set |
| 569 | # CONFIG_IBM_NEW_EMAC_ZMII is not set | ||
| 570 | # CONFIG_IBM_NEW_EMAC_RGMII is not set | ||
| 571 | # CONFIG_IBM_NEW_EMAC_TAH is not set | ||
| 572 | # CONFIG_IBM_NEW_EMAC_EMAC4 is not set | ||
| 545 | CONFIG_NET_PCI=y | 573 | CONFIG_NET_PCI=y |
| 546 | # CONFIG_PCNET32 is not set | 574 | # CONFIG_PCNET32 is not set |
| 547 | # CONFIG_AMD8111_ETH is not set | 575 | # CONFIG_AMD8111_ETH is not set |
| 548 | # CONFIG_ADAPTEC_STARFIRE is not set | 576 | # CONFIG_ADAPTEC_STARFIRE is not set |
| 549 | # CONFIG_B44 is not set | 577 | # CONFIG_B44 is not set |
| 550 | # CONFIG_FORCEDETH is not set | 578 | # CONFIG_FORCEDETH is not set |
| 551 | # CONFIG_DGRS is not set | ||
| 552 | # CONFIG_EEPRO100 is not set | 579 | # CONFIG_EEPRO100 is not set |
| 553 | # CONFIG_E100 is not set | 580 | # CONFIG_E100 is not set |
| 554 | # CONFIG_FEALNX is not set | 581 | # CONFIG_FEALNX is not set |
| @@ -560,6 +587,7 @@ CONFIG_8139TOO=y | |||
| 560 | # CONFIG_8139TOO_TUNE_TWISTER is not set | 587 | # CONFIG_8139TOO_TUNE_TWISTER is not set |
| 561 | # CONFIG_8139TOO_8129 is not set | 588 | # CONFIG_8139TOO_8129 is not set |
| 562 | # CONFIG_8139_OLD_RX_RESET is not set | 589 | # CONFIG_8139_OLD_RX_RESET is not set |
| 590 | # CONFIG_R6040 is not set | ||
| 563 | # CONFIG_SIS900 is not set | 591 | # CONFIG_SIS900 is not set |
| 564 | # CONFIG_EPIC100 is not set | 592 | # CONFIG_EPIC100 is not set |
| 565 | # CONFIG_SUNDANCE is not set | 593 | # CONFIG_SUNDANCE is not set |
| @@ -570,6 +598,10 @@ CONFIG_NETDEV_1000=y | |||
| 570 | # CONFIG_ACENIC is not set | 598 | # CONFIG_ACENIC is not set |
| 571 | # CONFIG_DL2K is not set | 599 | # CONFIG_DL2K is not set |
| 572 | # CONFIG_E1000 is not set | 600 | # CONFIG_E1000 is not set |
| 601 | # CONFIG_E1000E is not set | ||
| 602 | # CONFIG_E1000E_ENABLED is not set | ||
| 603 | # CONFIG_IP1000 is not set | ||
| 604 | # CONFIG_IGB is not set | ||
| 573 | # CONFIG_NS83820 is not set | 605 | # CONFIG_NS83820 is not set |
| 574 | # CONFIG_HAMACHI is not set | 606 | # CONFIG_HAMACHI is not set |
| 575 | # CONFIG_YELLOWFIN is not set | 607 | # CONFIG_YELLOWFIN is not set |
| @@ -577,6 +609,7 @@ CONFIG_NETDEV_1000=y | |||
| 577 | # CONFIG_SIS190 is not set | 609 | # CONFIG_SIS190 is not set |
| 578 | # CONFIG_SKGE is not set | 610 | # CONFIG_SKGE is not set |
| 579 | # CONFIG_SKY2 is not set | 611 | # CONFIG_SKY2 is not set |
| 612 | # CONFIG_SK98LIN is not set | ||
| 580 | # CONFIG_VIA_VELOCITY is not set | 613 | # CONFIG_VIA_VELOCITY is not set |
| 581 | # CONFIG_TIGON3 is not set | 614 | # CONFIG_TIGON3 is not set |
| 582 | # CONFIG_BNX2 is not set | 615 | # CONFIG_BNX2 is not set |
| @@ -585,11 +618,15 @@ CONFIG_NETDEV_1000=y | |||
| 585 | CONFIG_NETDEV_10000=y | 618 | CONFIG_NETDEV_10000=y |
| 586 | # CONFIG_CHELSIO_T1 is not set | 619 | # CONFIG_CHELSIO_T1 is not set |
| 587 | # CONFIG_CHELSIO_T3 is not set | 620 | # CONFIG_CHELSIO_T3 is not set |
| 621 | # CONFIG_IXGBE is not set | ||
| 588 | # CONFIG_IXGB is not set | 622 | # CONFIG_IXGB is not set |
| 589 | # CONFIG_S2IO is not set | 623 | # CONFIG_S2IO is not set |
| 590 | # CONFIG_MYRI10GE is not set | 624 | # CONFIG_MYRI10GE is not set |
| 591 | # CONFIG_NETXEN_NIC is not set | 625 | # CONFIG_NETXEN_NIC is not set |
| 626 | # CONFIG_NIU is not set | ||
| 592 | # CONFIG_MLX4_CORE is not set | 627 | # CONFIG_MLX4_CORE is not set |
| 628 | # CONFIG_TEHUTI is not set | ||
| 629 | # CONFIG_BNX2X is not set | ||
| 593 | # CONFIG_TR is not set | 630 | # CONFIG_TR is not set |
| 594 | 631 | ||
| 595 | # | 632 | # |
| @@ -597,13 +634,21 @@ CONFIG_NETDEV_10000=y | |||
| 597 | # | 634 | # |
| 598 | # CONFIG_WLAN_PRE80211 is not set | 635 | # CONFIG_WLAN_PRE80211 is not set |
| 599 | # CONFIG_WLAN_80211 is not set | 636 | # CONFIG_WLAN_80211 is not set |
| 637 | |||
| 638 | # | ||
| 639 | # USB Network Adapters | ||
| 640 | # | ||
| 641 | # CONFIG_USB_CATC is not set | ||
| 642 | # CONFIG_USB_KAWETH is not set | ||
| 643 | # CONFIG_USB_PEGASUS is not set | ||
| 644 | # CONFIG_USB_RTL8150 is not set | ||
| 645 | # CONFIG_USB_USBNET is not set | ||
| 600 | # CONFIG_WAN is not set | 646 | # CONFIG_WAN is not set |
| 601 | # CONFIG_FDDI is not set | 647 | # CONFIG_FDDI is not set |
| 602 | # CONFIG_HIPPI is not set | 648 | # CONFIG_HIPPI is not set |
| 603 | # CONFIG_PPP is not set | 649 | # CONFIG_PPP is not set |
| 604 | # CONFIG_SLIP is not set | 650 | # CONFIG_SLIP is not set |
| 605 | # CONFIG_NET_FC is not set | 651 | # CONFIG_NET_FC is not set |
| 606 | # CONFIG_SHAPER is not set | ||
| 607 | # CONFIG_NETCONSOLE is not set | 652 | # CONFIG_NETCONSOLE is not set |
| 608 | # CONFIG_NETPOLL is not set | 653 | # CONFIG_NETPOLL is not set |
| 609 | # CONFIG_NET_POLL_CONTROLLER is not set | 654 | # CONFIG_NET_POLL_CONTROLLER is not set |
| @@ -622,7 +667,6 @@ CONFIG_INPUT=y | |||
| 622 | # | 667 | # |
| 623 | # CONFIG_INPUT_MOUSEDEV is not set | 668 | # CONFIG_INPUT_MOUSEDEV is not set |
| 624 | # CONFIG_INPUT_JOYDEV is not set | 669 | # CONFIG_INPUT_JOYDEV is not set |
| 625 | # CONFIG_INPUT_TSDEV is not set | ||
| 626 | # CONFIG_INPUT_EVDEV is not set | 670 | # CONFIG_INPUT_EVDEV is not set |
| 627 | # CONFIG_INPUT_EVBUG is not set | 671 | # CONFIG_INPUT_EVBUG is not set |
| 628 | 672 | ||
| @@ -650,6 +694,7 @@ CONFIG_VT_CONSOLE=y | |||
| 650 | CONFIG_HW_CONSOLE=y | 694 | CONFIG_HW_CONSOLE=y |
| 651 | CONFIG_VT_HW_CONSOLE_BINDING=y | 695 | CONFIG_VT_HW_CONSOLE_BINDING=y |
| 652 | # CONFIG_SERIAL_NONSTANDARD is not set | 696 | # CONFIG_SERIAL_NONSTANDARD is not set |
| 697 | # CONFIG_NOZOMI is not set | ||
| 653 | 698 | ||
| 654 | # | 699 | # |
| 655 | # Serial drivers | 700 | # Serial drivers |
| @@ -674,11 +719,9 @@ CONFIG_UNIX98_PTYS=y | |||
| 674 | CONFIG_LEGACY_PTYS=y | 719 | CONFIG_LEGACY_PTYS=y |
| 675 | CONFIG_LEGACY_PTY_COUNT=256 | 720 | CONFIG_LEGACY_PTY_COUNT=256 |
| 676 | # CONFIG_IPMI_HANDLER is not set | 721 | # CONFIG_IPMI_HANDLER is not set |
| 677 | # CONFIG_WATCHDOG is not set | ||
| 678 | CONFIG_HW_RANDOM=y | 722 | CONFIG_HW_RANDOM=y |
| 679 | # CONFIG_R3964 is not set | 723 | # CONFIG_R3964 is not set |
| 680 | # CONFIG_APPLICOM is not set | 724 | # CONFIG_APPLICOM is not set |
| 681 | # CONFIG_DRM is not set | ||
| 682 | # CONFIG_RAW_DRIVER is not set | 725 | # CONFIG_RAW_DRIVER is not set |
| 683 | # CONFIG_TCG_TPM is not set | 726 | # CONFIG_TCG_TPM is not set |
| 684 | CONFIG_DEVPORT=y | 727 | CONFIG_DEVPORT=y |
| @@ -687,16 +730,30 @@ CONFIG_DEVPORT=y | |||
| 687 | # | 730 | # |
| 688 | # SPI support | 731 | # SPI support |
| 689 | # | 732 | # |
| 690 | # CONFIG_SPI is not set | 733 | CONFIG_SPI=y |
| 691 | # CONFIG_SPI_MASTER is not set | 734 | CONFIG_SPI_MASTER=y |
| 735 | |||
| 736 | # | ||
| 737 | # SPI Master Controller Drivers | ||
| 738 | # | ||
| 739 | CONFIG_SPI_BITBANG=y | ||
| 740 | CONFIG_SPI_SH_SCI=y | ||
| 741 | |||
| 742 | # | ||
| 743 | # SPI Protocol Masters | ||
| 744 | # | ||
| 745 | # CONFIG_SPI_AT25 is not set | ||
| 746 | # CONFIG_SPI_SPIDEV is not set | ||
| 747 | # CONFIG_SPI_TLE62X0 is not set | ||
| 692 | # CONFIG_W1 is not set | 748 | # CONFIG_W1 is not set |
| 693 | # CONFIG_POWER_SUPPLY is not set | 749 | # CONFIG_POWER_SUPPLY is not set |
| 694 | CONFIG_HWMON=y | 750 | CONFIG_HWMON=y |
| 695 | # CONFIG_HWMON_VID is not set | 751 | # CONFIG_HWMON_VID is not set |
| 696 | # CONFIG_SENSORS_ABITUGURU is not set | 752 | # CONFIG_SENSORS_I5K_AMB is not set |
| 697 | # CONFIG_SENSORS_ABITUGURU3 is not set | ||
| 698 | # CONFIG_SENSORS_F71805F is not set | 753 | # CONFIG_SENSORS_F71805F is not set |
| 754 | # CONFIG_SENSORS_F71882FG is not set | ||
| 699 | # CONFIG_SENSORS_IT87 is not set | 755 | # CONFIG_SENSORS_IT87 is not set |
| 756 | # CONFIG_SENSORS_LM70 is not set | ||
| 700 | # CONFIG_SENSORS_PC87360 is not set | 757 | # CONFIG_SENSORS_PC87360 is not set |
| 701 | # CONFIG_SENSORS_PC87427 is not set | 758 | # CONFIG_SENSORS_PC87427 is not set |
| 702 | # CONFIG_SENSORS_SIS5595 is not set | 759 | # CONFIG_SENSORS_SIS5595 is not set |
| @@ -708,6 +765,13 @@ CONFIG_HWMON=y | |||
| 708 | # CONFIG_SENSORS_W83627HF is not set | 765 | # CONFIG_SENSORS_W83627HF is not set |
| 709 | # CONFIG_SENSORS_W83627EHF is not set | 766 | # CONFIG_SENSORS_W83627EHF is not set |
| 710 | # CONFIG_HWMON_DEBUG_CHIP is not set | 767 | # CONFIG_HWMON_DEBUG_CHIP is not set |
| 768 | # CONFIG_WATCHDOG is not set | ||
| 769 | |||
| 770 | # | ||
| 771 | # Sonics Silicon Backplane | ||
| 772 | # | ||
| 773 | CONFIG_SSB_POSSIBLE=y | ||
| 774 | # CONFIG_SSB is not set | ||
| 711 | 775 | ||
| 712 | # | 776 | # |
| 713 | # Multifunction device drivers | 777 | # Multifunction device drivers |
| @@ -720,16 +784,12 @@ CONFIG_MFD_SM501=y | |||
| 720 | # CONFIG_VIDEO_DEV is not set | 784 | # CONFIG_VIDEO_DEV is not set |
| 721 | # CONFIG_DVB_CORE is not set | 785 | # CONFIG_DVB_CORE is not set |
| 722 | CONFIG_DAB=y | 786 | CONFIG_DAB=y |
| 787 | # CONFIG_USB_DABUSB is not set | ||
| 723 | 788 | ||
| 724 | # | 789 | # |
| 725 | # Graphics support | 790 | # Graphics support |
| 726 | # | 791 | # |
| 727 | # CONFIG_BACKLIGHT_LCD_SUPPORT is not set | 792 | # CONFIG_DRM is not set |
| 728 | |||
| 729 | # | ||
| 730 | # Display device support | ||
| 731 | # | ||
| 732 | # CONFIG_DISPLAY_SUPPORT is not set | ||
| 733 | # CONFIG_VGASTATE is not set | 793 | # CONFIG_VGASTATE is not set |
| 734 | CONFIG_VIDEO_OUTPUT_CONTROL=m | 794 | CONFIG_VIDEO_OUTPUT_CONTROL=m |
| 735 | CONFIG_FB=y | 795 | CONFIG_FB=y |
| @@ -738,6 +798,7 @@ CONFIG_FB=y | |||
| 738 | CONFIG_FB_CFB_FILLRECT=y | 798 | CONFIG_FB_CFB_FILLRECT=y |
| 739 | CONFIG_FB_CFB_COPYAREA=y | 799 | CONFIG_FB_CFB_COPYAREA=y |
| 740 | CONFIG_FB_CFB_IMAGEBLIT=y | 800 | CONFIG_FB_CFB_IMAGEBLIT=y |
| 801 | # CONFIG_FB_CFB_REV_PIXELS_IN_BYTE is not set | ||
| 741 | # CONFIG_FB_SYS_FILLRECT is not set | 802 | # CONFIG_FB_SYS_FILLRECT is not set |
| 742 | # CONFIG_FB_SYS_COPYAREA is not set | 803 | # CONFIG_FB_SYS_COPYAREA is not set |
| 743 | # CONFIG_FB_SYS_IMAGEBLIT is not set | 804 | # CONFIG_FB_SYS_IMAGEBLIT is not set |
| @@ -777,6 +838,12 @@ CONFIG_FB_DEFERRED_IO=y | |||
| 777 | # CONFIG_FB_PM3 is not set | 838 | # CONFIG_FB_PM3 is not set |
| 778 | CONFIG_FB_SM501=y | 839 | CONFIG_FB_SM501=y |
| 779 | # CONFIG_FB_VIRTUAL is not set | 840 | # CONFIG_FB_VIRTUAL is not set |
| 841 | # CONFIG_BACKLIGHT_LCD_SUPPORT is not set | ||
| 842 | |||
| 843 | # | ||
| 844 | # Display device support | ||
| 845 | # | ||
| 846 | # CONFIG_DISPLAY_SUPPORT is not set | ||
| 780 | 847 | ||
| 781 | # | 848 | # |
| 782 | # Console display driver support | 849 | # Console display driver support |
| @@ -844,6 +911,7 @@ CONFIG_SND_AC97_CODEC=m | |||
| 844 | # CONFIG_SND_BT87X is not set | 911 | # CONFIG_SND_BT87X is not set |
| 845 | # CONFIG_SND_CA0106 is not set | 912 | # CONFIG_SND_CA0106 is not set |
| 846 | # CONFIG_SND_CMIPCI is not set | 913 | # CONFIG_SND_CMIPCI is not set |
| 914 | # CONFIG_SND_OXYGEN is not set | ||
| 847 | # CONFIG_SND_CS4281 is not set | 915 | # CONFIG_SND_CS4281 is not set |
| 848 | # CONFIG_SND_CS46XX is not set | 916 | # CONFIG_SND_CS46XX is not set |
| 849 | # CONFIG_SND_DARLA20 is not set | 917 | # CONFIG_SND_DARLA20 is not set |
| @@ -868,6 +936,7 @@ CONFIG_SND_AC97_CODEC=m | |||
| 868 | # CONFIG_SND_HDA_INTEL is not set | 936 | # CONFIG_SND_HDA_INTEL is not set |
| 869 | # CONFIG_SND_HDSP is not set | 937 | # CONFIG_SND_HDSP is not set |
| 870 | # CONFIG_SND_HDSPM is not set | 938 | # CONFIG_SND_HDSPM is not set |
| 939 | # CONFIG_SND_HIFIER is not set | ||
| 871 | # CONFIG_SND_ICE1712 is not set | 940 | # CONFIG_SND_ICE1712 is not set |
| 872 | # CONFIG_SND_ICE1724 is not set | 941 | # CONFIG_SND_ICE1724 is not set |
| 873 | # CONFIG_SND_INTEL8X0 is not set | 942 | # CONFIG_SND_INTEL8X0 is not set |
| @@ -885,16 +954,27 @@ CONFIG_SND_AC97_CODEC=m | |||
| 885 | # CONFIG_SND_TRIDENT is not set | 954 | # CONFIG_SND_TRIDENT is not set |
| 886 | # CONFIG_SND_VIA82XX is not set | 955 | # CONFIG_SND_VIA82XX is not set |
| 887 | # CONFIG_SND_VIA82XX_MODEM is not set | 956 | # CONFIG_SND_VIA82XX_MODEM is not set |
| 957 | # CONFIG_SND_VIRTUOSO is not set | ||
| 888 | # CONFIG_SND_VX222 is not set | 958 | # CONFIG_SND_VX222 is not set |
| 889 | CONFIG_SND_YMFPCI=m | 959 | CONFIG_SND_YMFPCI=m |
| 890 | CONFIG_SND_YMFPCI_FIRMWARE_IN_KERNEL=y | 960 | CONFIG_SND_YMFPCI_FIRMWARE_IN_KERNEL=y |
| 891 | # CONFIG_SND_AC97_POWER_SAVE is not set | 961 | # CONFIG_SND_AC97_POWER_SAVE is not set |
| 892 | 962 | ||
| 893 | # | 963 | # |
| 964 | # SPI devices | ||
| 965 | # | ||
| 966 | |||
| 967 | # | ||
| 894 | # SUPERH devices | 968 | # SUPERH devices |
| 895 | # | 969 | # |
| 896 | 970 | ||
| 897 | # | 971 | # |
| 972 | # USB devices | ||
| 973 | # | ||
| 974 | # CONFIG_SND_USB_AUDIO is not set | ||
| 975 | # CONFIG_SND_USB_CAIAQ is not set | ||
| 976 | |||
| 977 | # | ||
| 898 | # System on Chip audio support | 978 | # System on Chip audio support |
| 899 | # | 979 | # |
| 900 | # CONFIG_SND_SOC is not set | 980 | # CONFIG_SND_SOC is not set |
| @@ -904,6 +984,10 @@ CONFIG_SND_YMFPCI_FIRMWARE_IN_KERNEL=y | |||
| 904 | # | 984 | # |
| 905 | 985 | ||
| 906 | # | 986 | # |
| 987 | # ALSA SoC audio for Freescale SOCs | ||
| 988 | # | ||
| 989 | |||
| 990 | # | ||
| 907 | # Open Sound System | 991 | # Open Sound System |
| 908 | # | 992 | # |
| 909 | CONFIG_SOUND_PRIME=m | 993 | CONFIG_SOUND_PRIME=m |
| @@ -914,19 +998,104 @@ CONFIG_AC97_BUS=m | |||
| 914 | CONFIG_HID_SUPPORT=y | 998 | CONFIG_HID_SUPPORT=y |
| 915 | CONFIG_HID=y | 999 | CONFIG_HID=y |
| 916 | # CONFIG_HID_DEBUG is not set | 1000 | # CONFIG_HID_DEBUG is not set |
| 1001 | # CONFIG_HIDRAW is not set | ||
| 1002 | |||
| 1003 | # | ||
| 1004 | # USB Input Devices | ||
| 1005 | # | ||
| 1006 | CONFIG_USB_HID=y | ||
| 1007 | # CONFIG_USB_HIDINPUT_POWERBOOK is not set | ||
| 1008 | # CONFIG_HID_FF is not set | ||
| 1009 | # CONFIG_USB_HIDDEV is not set | ||
| 917 | CONFIG_USB_SUPPORT=y | 1010 | CONFIG_USB_SUPPORT=y |
| 918 | CONFIG_USB_ARCH_HAS_HCD=y | 1011 | CONFIG_USB_ARCH_HAS_HCD=y |
| 919 | CONFIG_USB_ARCH_HAS_OHCI=y | 1012 | CONFIG_USB_ARCH_HAS_OHCI=y |
| 920 | CONFIG_USB_ARCH_HAS_EHCI=y | 1013 | CONFIG_USB_ARCH_HAS_EHCI=y |
| 921 | # CONFIG_USB is not set | 1014 | CONFIG_USB=y |
| 1015 | # CONFIG_USB_DEBUG is not set | ||
| 1016 | CONFIG_USB_ANNOUNCE_NEW_DEVICES=y | ||
| 1017 | |||
| 1018 | # | ||
| 1019 | # Miscellaneous USB options | ||
| 1020 | # | ||
| 1021 | # CONFIG_USB_DEVICEFS is not set | ||
| 1022 | CONFIG_USB_DEVICE_CLASS=y | ||
| 1023 | # CONFIG_USB_DYNAMIC_MINORS is not set | ||
| 1024 | # CONFIG_USB_OTG is not set | ||
| 1025 | |||
| 1026 | # | ||
| 1027 | # USB Host Controller Drivers | ||
| 1028 | # | ||
| 1029 | # CONFIG_USB_EHCI_HCD is not set | ||
| 1030 | # CONFIG_USB_ISP116X_HCD is not set | ||
| 1031 | CONFIG_USB_OHCI_HCD=y | ||
| 1032 | # CONFIG_USB_OHCI_BIG_ENDIAN_DESC is not set | ||
| 1033 | # CONFIG_USB_OHCI_BIG_ENDIAN_MMIO is not set | ||
| 1034 | CONFIG_USB_OHCI_LITTLE_ENDIAN=y | ||
| 1035 | # CONFIG_USB_UHCI_HCD is not set | ||
| 1036 | # CONFIG_USB_SL811_HCD is not set | ||
| 1037 | # CONFIG_USB_R8A66597_HCD is not set | ||
| 1038 | |||
| 1039 | # | ||
| 1040 | # USB Device Class drivers | ||
| 1041 | # | ||
| 1042 | # CONFIG_USB_ACM is not set | ||
| 1043 | # CONFIG_USB_PRINTER is not set | ||
| 922 | 1044 | ||
| 923 | # | 1045 | # |
| 924 | # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' | 1046 | # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' |
| 925 | # | 1047 | # |
| 926 | 1048 | ||
| 927 | # | 1049 | # |
| 928 | # USB Gadget Support | 1050 | # may also be needed; see USB_STORAGE Help for more information |
| 1051 | # | ||
| 1052 | CONFIG_USB_STORAGE=y | ||
| 1053 | # CONFIG_USB_STORAGE_DEBUG is not set | ||
| 1054 | # CONFIG_USB_STORAGE_DATAFAB is not set | ||
| 1055 | # CONFIG_USB_STORAGE_FREECOM is not set | ||
| 1056 | # CONFIG_USB_STORAGE_ISD200 is not set | ||
| 1057 | # CONFIG_USB_STORAGE_DPCM is not set | ||
| 1058 | # CONFIG_USB_STORAGE_USBAT is not set | ||
| 1059 | # CONFIG_USB_STORAGE_SDDR09 is not set | ||
| 1060 | # CONFIG_USB_STORAGE_SDDR55 is not set | ||
| 1061 | # CONFIG_USB_STORAGE_JUMPSHOT is not set | ||
| 1062 | # CONFIG_USB_STORAGE_ALAUDA is not set | ||
| 1063 | # CONFIG_USB_STORAGE_KARMA is not set | ||
| 1064 | CONFIG_USB_LIBUSUAL=y | ||
| 1065 | |||
| 1066 | # | ||
| 1067 | # USB Imaging devices | ||
| 1068 | # | ||
| 1069 | # CONFIG_USB_MDC800 is not set | ||
| 1070 | # CONFIG_USB_MICROTEK is not set | ||
| 1071 | # CONFIG_USB_MON is not set | ||
| 1072 | |||
| 1073 | # | ||
| 1074 | # USB port drivers | ||
| 1075 | # | ||
| 1076 | # CONFIG_USB_SERIAL is not set | ||
| 1077 | |||
| 1078 | # | ||
| 1079 | # USB Miscellaneous drivers | ||
| 929 | # | 1080 | # |
| 1081 | # CONFIG_USB_EMI62 is not set | ||
| 1082 | # CONFIG_USB_EMI26 is not set | ||
| 1083 | # CONFIG_USB_ADUTUX is not set | ||
| 1084 | # CONFIG_USB_AUERSWALD is not set | ||
| 1085 | # CONFIG_USB_RIO500 is not set | ||
| 1086 | # CONFIG_USB_LEGOTOWER is not set | ||
| 1087 | # CONFIG_USB_LCD is not set | ||
| 1088 | # CONFIG_USB_BERRY_CHARGE is not set | ||
| 1089 | # CONFIG_USB_LED is not set | ||
| 1090 | # CONFIG_USB_CYPRESS_CY7C63 is not set | ||
| 1091 | # CONFIG_USB_CYTHERM is not set | ||
| 1092 | # CONFIG_USB_PHIDGET is not set | ||
| 1093 | # CONFIG_USB_IDMOUSE is not set | ||
| 1094 | # CONFIG_USB_FTDI_ELAN is not set | ||
| 1095 | # CONFIG_USB_APPLEDISPLAY is not set | ||
| 1096 | # CONFIG_USB_LD is not set | ||
| 1097 | # CONFIG_USB_TRANCEVIBRATOR is not set | ||
| 1098 | # CONFIG_USB_IOWARRIOR is not set | ||
| 930 | # CONFIG_USB_GADGET is not set | 1099 | # CONFIG_USB_GADGET is not set |
| 931 | # CONFIG_MMC is not set | 1100 | # CONFIG_MMC is not set |
| 932 | # CONFIG_NEW_LEDS is not set | 1101 | # CONFIG_NEW_LEDS is not set |
| @@ -949,13 +1118,17 @@ CONFIG_RTC_INTF_DEV=y | |||
| 949 | # | 1118 | # |
| 950 | # SPI RTC drivers | 1119 | # SPI RTC drivers |
| 951 | # | 1120 | # |
| 1121 | # CONFIG_RTC_DRV_MAX6902 is not set | ||
| 1122 | CONFIG_RTC_DRV_R9701=y | ||
| 1123 | # CONFIG_RTC_DRV_RS5C348 is not set | ||
| 952 | 1124 | ||
| 953 | # | 1125 | # |
| 954 | # Platform RTC drivers | 1126 | # Platform RTC drivers |
| 955 | # | 1127 | # |
| 1128 | # CONFIG_RTC_DRV_DS1511 is not set | ||
| 956 | # CONFIG_RTC_DRV_DS1553 is not set | 1129 | # CONFIG_RTC_DRV_DS1553 is not set |
| 957 | # CONFIG_RTC_DRV_STK17TA8 is not set | ||
| 958 | # CONFIG_RTC_DRV_DS1742 is not set | 1130 | # CONFIG_RTC_DRV_DS1742 is not set |
| 1131 | # CONFIG_RTC_DRV_STK17TA8 is not set | ||
| 959 | # CONFIG_RTC_DRV_M48T86 is not set | 1132 | # CONFIG_RTC_DRV_M48T86 is not set |
| 960 | # CONFIG_RTC_DRV_M48T59 is not set | 1133 | # CONFIG_RTC_DRV_M48T59 is not set |
| 961 | # CONFIG_RTC_DRV_V3020 is not set | 1134 | # CONFIG_RTC_DRV_V3020 is not set |
| @@ -963,20 +1136,7 @@ CONFIG_RTC_INTF_DEV=y | |||
| 963 | # | 1136 | # |
| 964 | # on-CPU RTC drivers | 1137 | # on-CPU RTC drivers |
| 965 | # | 1138 | # |
| 966 | CONFIG_RTC_DRV_SH=y | 1139 | # CONFIG_RTC_DRV_SH is not set |
| 967 | |||
| 968 | # | ||
| 969 | # DMA Engine support | ||
| 970 | # | ||
| 971 | # CONFIG_DMA_ENGINE is not set | ||
| 972 | |||
| 973 | # | ||
| 974 | # DMA Clients | ||
| 975 | # | ||
| 976 | |||
| 977 | # | ||
| 978 | # DMA Devices | ||
| 979 | # | ||
| 980 | 1140 | ||
| 981 | # | 1141 | # |
| 982 | # Userspace I/O | 1142 | # Userspace I/O |
| @@ -1034,7 +1194,6 @@ CONFIG_TMPFS=y | |||
| 1034 | # CONFIG_TMPFS_POSIX_ACL is not set | 1194 | # CONFIG_TMPFS_POSIX_ACL is not set |
| 1035 | # CONFIG_HUGETLBFS is not set | 1195 | # CONFIG_HUGETLBFS is not set |
| 1036 | # CONFIG_HUGETLB_PAGE is not set | 1196 | # CONFIG_HUGETLB_PAGE is not set |
| 1037 | CONFIG_RAMFS=y | ||
| 1038 | # CONFIG_CONFIGFS_FS is not set | 1197 | # CONFIG_CONFIGFS_FS is not set |
| 1039 | 1198 | ||
| 1040 | # | 1199 | # |
| @@ -1053,10 +1212,7 @@ CONFIG_RAMFS=y | |||
| 1053 | # CONFIG_QNX4FS_FS is not set | 1212 | # CONFIG_QNX4FS_FS is not set |
| 1054 | # CONFIG_SYSV_FS is not set | 1213 | # CONFIG_SYSV_FS is not set |
| 1055 | # CONFIG_UFS_FS is not set | 1214 | # CONFIG_UFS_FS is not set |
| 1056 | 1215 | CONFIG_NETWORK_FILESYSTEMS=y | |
| 1057 | # | ||
| 1058 | # Network File Systems | ||
| 1059 | # | ||
| 1060 | # CONFIG_NFS_FS is not set | 1216 | # CONFIG_NFS_FS is not set |
| 1061 | # CONFIG_NFSD is not set | 1217 | # CONFIG_NFSD is not set |
| 1062 | # CONFIG_SMB_FS is not set | 1218 | # CONFIG_SMB_FS is not set |
| @@ -1070,10 +1226,6 @@ CONFIG_RAMFS=y | |||
| 1070 | # | 1226 | # |
| 1071 | # CONFIG_PARTITION_ADVANCED is not set | 1227 | # CONFIG_PARTITION_ADVANCED is not set |
| 1072 | CONFIG_MSDOS_PARTITION=y | 1228 | CONFIG_MSDOS_PARTITION=y |
| 1073 | |||
| 1074 | # | ||
| 1075 | # Native Language Support | ||
| 1076 | # | ||
| 1077 | CONFIG_NLS=y | 1229 | CONFIG_NLS=y |
| 1078 | CONFIG_NLS_DEFAULT="iso8859-1" | 1230 | CONFIG_NLS_DEFAULT="iso8859-1" |
| 1079 | # CONFIG_NLS_CODEPAGE_437 is not set | 1231 | # CONFIG_NLS_CODEPAGE_437 is not set |
| @@ -1114,30 +1266,22 @@ CONFIG_NLS_CODEPAGE_932=y | |||
| 1114 | # CONFIG_NLS_KOI8_R is not set | 1266 | # CONFIG_NLS_KOI8_R is not set |
| 1115 | # CONFIG_NLS_KOI8_U is not set | 1267 | # CONFIG_NLS_KOI8_U is not set |
| 1116 | # CONFIG_NLS_UTF8 is not set | 1268 | # CONFIG_NLS_UTF8 is not set |
| 1117 | |||
| 1118 | # | ||
| 1119 | # Distributed Lock Manager | ||
| 1120 | # | ||
| 1121 | # CONFIG_DLM is not set | 1269 | # CONFIG_DLM is not set |
| 1122 | 1270 | ||
| 1123 | # | 1271 | # |
| 1124 | # Profiling support | ||
| 1125 | # | ||
| 1126 | CONFIG_PROFILING=y | ||
| 1127 | CONFIG_OPROFILE=y | ||
| 1128 | |||
| 1129 | # | ||
| 1130 | # Kernel hacking | 1272 | # Kernel hacking |
| 1131 | # | 1273 | # |
| 1132 | CONFIG_TRACE_IRQFLAGS_SUPPORT=y | 1274 | CONFIG_TRACE_IRQFLAGS_SUPPORT=y |
| 1133 | # CONFIG_PRINTK_TIME is not set | 1275 | # CONFIG_PRINTK_TIME is not set |
| 1276 | CONFIG_ENABLE_WARN_DEPRECATED=y | ||
| 1134 | CONFIG_ENABLE_MUST_CHECK=y | 1277 | CONFIG_ENABLE_MUST_CHECK=y |
| 1135 | # CONFIG_MAGIC_SYSRQ is not set | 1278 | # CONFIG_MAGIC_SYSRQ is not set |
| 1136 | # CONFIG_UNUSED_SYMBOLS is not set | 1279 | # CONFIG_UNUSED_SYMBOLS is not set |
| 1137 | # CONFIG_DEBUG_FS is not set | 1280 | CONFIG_DEBUG_FS=y |
| 1138 | # CONFIG_HEADERS_CHECK is not set | 1281 | # CONFIG_HEADERS_CHECK is not set |
| 1139 | # CONFIG_DEBUG_KERNEL is not set | 1282 | # CONFIG_DEBUG_KERNEL is not set |
| 1140 | # CONFIG_DEBUG_BUGVERBOSE is not set | 1283 | # CONFIG_DEBUG_BUGVERBOSE is not set |
| 1284 | # CONFIG_SAMPLES is not set | ||
| 1141 | # CONFIG_SH_STANDARD_BIOS is not set | 1285 | # CONFIG_SH_STANDARD_BIOS is not set |
| 1142 | CONFIG_EARLY_SCIF_CONSOLE=y | 1286 | CONFIG_EARLY_SCIF_CONSOLE=y |
| 1143 | CONFIG_EARLY_SCIF_CONSOLE_PORT=0xffe80000 | 1287 | CONFIG_EARLY_SCIF_CONSOLE_PORT=0xffe80000 |
| @@ -1149,7 +1293,53 @@ CONFIG_EARLY_PRINTK=y | |||
| 1149 | # | 1293 | # |
| 1150 | # CONFIG_KEYS is not set | 1294 | # CONFIG_KEYS is not set |
| 1151 | # CONFIG_SECURITY is not set | 1295 | # CONFIG_SECURITY is not set |
| 1152 | # CONFIG_CRYPTO is not set | 1296 | # CONFIG_SECURITY_FILE_CAPABILITIES is not set |
| 1297 | CONFIG_CRYPTO=y | ||
| 1298 | # CONFIG_CRYPTO_SEQIV is not set | ||
| 1299 | # CONFIG_CRYPTO_MANAGER is not set | ||
| 1300 | # CONFIG_CRYPTO_HMAC is not set | ||
| 1301 | # CONFIG_CRYPTO_XCBC is not set | ||
| 1302 | # CONFIG_CRYPTO_NULL is not set | ||
| 1303 | # CONFIG_CRYPTO_MD4 is not set | ||
| 1304 | # CONFIG_CRYPTO_MD5 is not set | ||
| 1305 | # CONFIG_CRYPTO_SHA1 is not set | ||
| 1306 | # CONFIG_CRYPTO_SHA256 is not set | ||
| 1307 | # CONFIG_CRYPTO_SHA512 is not set | ||
| 1308 | # CONFIG_CRYPTO_WP512 is not set | ||
| 1309 | # CONFIG_CRYPTO_TGR192 is not set | ||
| 1310 | # CONFIG_CRYPTO_GF128MUL is not set | ||
| 1311 | # CONFIG_CRYPTO_ECB is not set | ||
| 1312 | # CONFIG_CRYPTO_CBC is not set | ||
| 1313 | # CONFIG_CRYPTO_PCBC is not set | ||
| 1314 | # CONFIG_CRYPTO_LRW is not set | ||
| 1315 | # CONFIG_CRYPTO_XTS is not set | ||
| 1316 | # CONFIG_CRYPTO_CTR is not set | ||
| 1317 | # CONFIG_CRYPTO_GCM is not set | ||
| 1318 | # CONFIG_CRYPTO_CCM is not set | ||
| 1319 | # CONFIG_CRYPTO_CRYPTD is not set | ||
| 1320 | # CONFIG_CRYPTO_DES is not set | ||
| 1321 | # CONFIG_CRYPTO_FCRYPT is not set | ||
| 1322 | # CONFIG_CRYPTO_BLOWFISH is not set | ||
| 1323 | # CONFIG_CRYPTO_TWOFISH is not set | ||
| 1324 | # CONFIG_CRYPTO_SERPENT is not set | ||
| 1325 | # CONFIG_CRYPTO_AES is not set | ||
| 1326 | # CONFIG_CRYPTO_CAST5 is not set | ||
| 1327 | # CONFIG_CRYPTO_CAST6 is not set | ||
| 1328 | # CONFIG_CRYPTO_TEA is not set | ||
| 1329 | # CONFIG_CRYPTO_ARC4 is not set | ||
| 1330 | # CONFIG_CRYPTO_KHAZAD is not set | ||
| 1331 | # CONFIG_CRYPTO_ANUBIS is not set | ||
| 1332 | # CONFIG_CRYPTO_SEED is not set | ||
| 1333 | # CONFIG_CRYPTO_SALSA20 is not set | ||
| 1334 | # CONFIG_CRYPTO_DEFLATE is not set | ||
| 1335 | # CONFIG_CRYPTO_MICHAEL_MIC is not set | ||
| 1336 | # CONFIG_CRYPTO_CRC32C is not set | ||
| 1337 | # CONFIG_CRYPTO_CAMELLIA is not set | ||
| 1338 | # CONFIG_CRYPTO_TEST is not set | ||
| 1339 | # CONFIG_CRYPTO_AUTHENC is not set | ||
| 1340 | # CONFIG_CRYPTO_LZO is not set | ||
| 1341 | CONFIG_CRYPTO_HW=y | ||
| 1342 | # CONFIG_CRYPTO_DEV_HIFN_795X is not set | ||
| 1153 | 1343 | ||
| 1154 | # | 1344 | # |
| 1155 | # Library routines | 1345 | # Library routines |
diff --git a/arch/sh/configs/rts7751r2dplus_defconfig b/arch/sh/configs/rts7751r2dplus_defconfig index 4ff5a752dcd9..0a6d3b9e648b 100644 --- a/arch/sh/configs/rts7751r2dplus_defconfig +++ b/arch/sh/configs/rts7751r2dplus_defconfig | |||
| @@ -1,9 +1,10 @@ | |||
| 1 | # | 1 | # |
| 2 | # Automatically generated make config: don't edit | 2 | # Automatically generated make config: don't edit |
| 3 | # Linux kernel version: 2.6.23-rc2 | 3 | # Linux kernel version: 2.6.24 |
| 4 | # Tue Aug 14 16:33:08 2007 | 4 | # Thu Feb 7 16:17:47 2008 |
| 5 | # | 5 | # |
| 6 | CONFIG_SUPERH=y | 6 | CONFIG_SUPERH=y |
| 7 | CONFIG_SUPERH32=y | ||
| 7 | CONFIG_RWSEM_GENERIC_SPINLOCK=y | 8 | CONFIG_RWSEM_GENERIC_SPINLOCK=y |
| 8 | CONFIG_GENERIC_BUG=y | 9 | CONFIG_GENERIC_BUG=y |
| 9 | CONFIG_GENERIC_FIND_NEXT_BIT=y | 10 | CONFIG_GENERIC_FIND_NEXT_BIT=y |
| @@ -36,9 +37,14 @@ CONFIG_SYSVIPC_SYSCTL=y | |||
| 36 | # CONFIG_BSD_PROCESS_ACCT is not set | 37 | # CONFIG_BSD_PROCESS_ACCT is not set |
| 37 | # CONFIG_TASKSTATS is not set | 38 | # CONFIG_TASKSTATS is not set |
| 38 | # CONFIG_USER_NS is not set | 39 | # CONFIG_USER_NS is not set |
| 40 | # CONFIG_PID_NS is not set | ||
| 39 | # CONFIG_AUDIT is not set | 41 | # CONFIG_AUDIT is not set |
| 40 | # CONFIG_IKCONFIG is not set | 42 | # CONFIG_IKCONFIG is not set |
| 41 | CONFIG_LOG_BUF_SHIFT=14 | 43 | CONFIG_LOG_BUF_SHIFT=14 |
| 44 | # CONFIG_CGROUPS is not set | ||
| 45 | CONFIG_FAIR_GROUP_SCHED=y | ||
| 46 | CONFIG_FAIR_USER_SCHED=y | ||
| 47 | # CONFIG_FAIR_CGROUP_SCHED is not set | ||
| 42 | CONFIG_SYSFS_DEPRECATED=y | 48 | CONFIG_SYSFS_DEPRECATED=y |
| 43 | # CONFIG_RELAY is not set | 49 | # CONFIG_RELAY is not set |
| 44 | # CONFIG_BLK_DEV_INITRD is not set | 50 | # CONFIG_BLK_DEV_INITRD is not set |
| @@ -53,6 +59,7 @@ CONFIG_HOTPLUG=y | |||
| 53 | CONFIG_PRINTK=y | 59 | CONFIG_PRINTK=y |
| 54 | CONFIG_BUG=y | 60 | CONFIG_BUG=y |
| 55 | CONFIG_ELF_CORE=y | 61 | CONFIG_ELF_CORE=y |
| 62 | CONFIG_COMPAT_BRK=y | ||
| 56 | CONFIG_BASE_FULL=y | 63 | CONFIG_BASE_FULL=y |
| 57 | CONFIG_FUTEX=y | 64 | CONFIG_FUTEX=y |
| 58 | CONFIG_ANON_INODES=y | 65 | CONFIG_ANON_INODES=y |
| @@ -65,6 +72,13 @@ CONFIG_VM_EVENT_COUNTERS=y | |||
| 65 | CONFIG_SLAB=y | 72 | CONFIG_SLAB=y |
| 66 | # CONFIG_SLUB is not set | 73 | # CONFIG_SLUB is not set |
| 67 | # CONFIG_SLOB is not set | 74 | # CONFIG_SLOB is not set |
| 75 | CONFIG_PROFILING=y | ||
| 76 | # CONFIG_MARKERS is not set | ||
| 77 | CONFIG_OPROFILE=y | ||
| 78 | CONFIG_HAVE_OPROFILE=y | ||
| 79 | # CONFIG_HAVE_KPROBES is not set | ||
| 80 | CONFIG_PROC_PAGE_MONITOR=y | ||
| 81 | CONFIG_SLABINFO=y | ||
| 68 | CONFIG_RT_MUTEXES=y | 82 | CONFIG_RT_MUTEXES=y |
| 69 | # CONFIG_TINY_SHMEM is not set | 83 | # CONFIG_TINY_SHMEM is not set |
| 70 | CONFIG_BASE_SMALL=0 | 84 | CONFIG_BASE_SMALL=0 |
| @@ -91,13 +105,17 @@ CONFIG_DEFAULT_AS=y | |||
| 91 | # CONFIG_DEFAULT_CFQ is not set | 105 | # CONFIG_DEFAULT_CFQ is not set |
| 92 | # CONFIG_DEFAULT_NOOP is not set | 106 | # CONFIG_DEFAULT_NOOP is not set |
| 93 | CONFIG_DEFAULT_IOSCHED="anticipatory" | 107 | CONFIG_DEFAULT_IOSCHED="anticipatory" |
| 108 | CONFIG_CLASSIC_RCU=y | ||
| 109 | # CONFIG_PREEMPT_RCU is not set | ||
| 94 | 110 | ||
| 95 | # | 111 | # |
| 96 | # System type | 112 | # System type |
| 97 | # | 113 | # |
| 98 | CONFIG_CPU_SH4=y | 114 | CONFIG_CPU_SH4=y |
| 99 | # CONFIG_CPU_SUBTYPE_SH7619 is not set | 115 | # CONFIG_CPU_SUBTYPE_SH7619 is not set |
| 116 | # CONFIG_CPU_SUBTYPE_SH7203 is not set | ||
| 100 | # CONFIG_CPU_SUBTYPE_SH7206 is not set | 117 | # CONFIG_CPU_SUBTYPE_SH7206 is not set |
| 118 | # CONFIG_CPU_SUBTYPE_SH7263 is not set | ||
| 101 | # CONFIG_CPU_SUBTYPE_SH7705 is not set | 119 | # CONFIG_CPU_SUBTYPE_SH7705 is not set |
| 102 | # CONFIG_CPU_SUBTYPE_SH7706 is not set | 120 | # CONFIG_CPU_SUBTYPE_SH7706 is not set |
| 103 | # CONFIG_CPU_SUBTYPE_SH7707 is not set | 121 | # CONFIG_CPU_SUBTYPE_SH7707 is not set |
| @@ -105,6 +123,8 @@ CONFIG_CPU_SH4=y | |||
| 105 | # CONFIG_CPU_SUBTYPE_SH7709 is not set | 123 | # CONFIG_CPU_SUBTYPE_SH7709 is not set |
| 106 | # CONFIG_CPU_SUBTYPE_SH7710 is not set | 124 | # CONFIG_CPU_SUBTYPE_SH7710 is not set |
| 107 | # CONFIG_CPU_SUBTYPE_SH7712 is not set | 125 | # CONFIG_CPU_SUBTYPE_SH7712 is not set |
| 126 | # CONFIG_CPU_SUBTYPE_SH7720 is not set | ||
| 127 | # CONFIG_CPU_SUBTYPE_SH7721 is not set | ||
| 108 | # CONFIG_CPU_SUBTYPE_SH7750 is not set | 128 | # CONFIG_CPU_SUBTYPE_SH7750 is not set |
| 109 | # CONFIG_CPU_SUBTYPE_SH7091 is not set | 129 | # CONFIG_CPU_SUBTYPE_SH7091 is not set |
| 110 | # CONFIG_CPU_SUBTYPE_SH7750R is not set | 130 | # CONFIG_CPU_SUBTYPE_SH7750R is not set |
| @@ -113,14 +133,15 @@ CONFIG_CPU_SH4=y | |||
| 113 | CONFIG_CPU_SUBTYPE_SH7751R=y | 133 | CONFIG_CPU_SUBTYPE_SH7751R=y |
| 114 | # CONFIG_CPU_SUBTYPE_SH7760 is not set | 134 | # CONFIG_CPU_SUBTYPE_SH7760 is not set |
| 115 | # CONFIG_CPU_SUBTYPE_SH4_202 is not set | 135 | # CONFIG_CPU_SUBTYPE_SH4_202 is not set |
| 116 | # CONFIG_CPU_SUBTYPE_ST40STB1 is not set | 136 | # CONFIG_CPU_SUBTYPE_SH7763 is not set |
| 117 | # CONFIG_CPU_SUBTYPE_ST40GX1 is not set | ||
| 118 | # CONFIG_CPU_SUBTYPE_SH7770 is not set | 137 | # CONFIG_CPU_SUBTYPE_SH7770 is not set |
| 119 | # CONFIG_CPU_SUBTYPE_SH7780 is not set | 138 | # CONFIG_CPU_SUBTYPE_SH7780 is not set |
| 120 | # CONFIG_CPU_SUBTYPE_SH7785 is not set | 139 | # CONFIG_CPU_SUBTYPE_SH7785 is not set |
| 121 | # CONFIG_CPU_SUBTYPE_SHX3 is not set | 140 | # CONFIG_CPU_SUBTYPE_SHX3 is not set |
| 122 | # CONFIG_CPU_SUBTYPE_SH7343 is not set | 141 | # CONFIG_CPU_SUBTYPE_SH7343 is not set |
| 123 | # CONFIG_CPU_SUBTYPE_SH7722 is not set | 142 | # CONFIG_CPU_SUBTYPE_SH7722 is not set |
| 143 | # CONFIG_CPU_SUBTYPE_SH5_101 is not set | ||
| 144 | # CONFIG_CPU_SUBTYPE_SH5_103 is not set | ||
| 124 | 145 | ||
| 125 | # | 146 | # |
| 126 | # Memory management options | 147 | # Memory management options |
| @@ -130,6 +151,7 @@ CONFIG_MMU=y | |||
| 130 | CONFIG_PAGE_OFFSET=0x80000000 | 151 | CONFIG_PAGE_OFFSET=0x80000000 |
| 131 | CONFIG_MEMORY_START=0x0c000000 | 152 | CONFIG_MEMORY_START=0x0c000000 |
| 132 | CONFIG_MEMORY_SIZE=0x04000000 | 153 | CONFIG_MEMORY_SIZE=0x04000000 |
| 154 | CONFIG_29BIT=y | ||
| 133 | CONFIG_VSYSCALL=y | 155 | CONFIG_VSYSCALL=y |
| 134 | CONFIG_ARCH_FLATMEM_ENABLE=y | 156 | CONFIG_ARCH_FLATMEM_ENABLE=y |
| 135 | CONFIG_ARCH_SPARSEMEM_ENABLE=y | 157 | CONFIG_ARCH_SPARSEMEM_ENABLE=y |
| @@ -147,6 +169,7 @@ CONFIG_FLATMEM_MANUAL=y | |||
| 147 | CONFIG_FLATMEM=y | 169 | CONFIG_FLATMEM=y |
| 148 | CONFIG_FLAT_NODE_MEM_MAP=y | 170 | CONFIG_FLAT_NODE_MEM_MAP=y |
| 149 | CONFIG_SPARSEMEM_STATIC=y | 171 | CONFIG_SPARSEMEM_STATIC=y |
| 172 | # CONFIG_SPARSEMEM_VMEMMAP_ENABLE is not set | ||
| 150 | CONFIG_SPLIT_PTLOCK_CPUS=4 | 173 | CONFIG_SPLIT_PTLOCK_CPUS=4 |
| 151 | # CONFIG_RESOURCES_64BIT is not set | 174 | # CONFIG_RESOURCES_64BIT is not set |
| 152 | CONFIG_ZONE_DMA_FLAG=0 | 175 | CONFIG_ZONE_DMA_FLAG=0 |
| @@ -168,23 +191,22 @@ CONFIG_CPU_LITTLE_ENDIAN=y | |||
| 168 | CONFIG_SH_FPU=y | 191 | CONFIG_SH_FPU=y |
| 169 | # CONFIG_SH_STORE_QUEUES is not set | 192 | # CONFIG_SH_STORE_QUEUES is not set |
| 170 | CONFIG_CPU_HAS_INTEVT=y | 193 | CONFIG_CPU_HAS_INTEVT=y |
| 171 | CONFIG_CPU_HAS_INTC_IRQ=y | ||
| 172 | CONFIG_CPU_HAS_SR_RB=y | 194 | CONFIG_CPU_HAS_SR_RB=y |
| 173 | CONFIG_CPU_HAS_PTEA=y | 195 | CONFIG_CPU_HAS_PTEA=y |
| 196 | CONFIG_CPU_HAS_FPU=y | ||
| 174 | 197 | ||
| 175 | # | 198 | # |
| 176 | # Board support | 199 | # Board support |
| 177 | # | 200 | # |
| 178 | # CONFIG_SH_7751_SYSTEMH is not set | 201 | # CONFIG_SH_7751_SYSTEMH is not set |
| 179 | # CONFIG_SH_SECUREEDGE5410 is not set | 202 | # CONFIG_SH_SECUREEDGE5410 is not set |
| 180 | # CONFIG_SH_HS7751RVOIP is not set | ||
| 181 | CONFIG_SH_RTS7751R2D=y | 203 | CONFIG_SH_RTS7751R2D=y |
| 182 | # CONFIG_SH_LANDISK is not set | 204 | # CONFIG_SH_LANDISK is not set |
| 183 | # CONFIG_SH_TITAN is not set | 205 | # CONFIG_SH_TITAN is not set |
| 184 | # CONFIG_SH_LBOX_RE2 is not set | 206 | # CONFIG_SH_LBOX_RE2 is not set |
| 185 | 207 | ||
| 186 | # | 208 | # |
| 187 | # RTS7751R2D options | 209 | # RTS7751R2D Board Revision |
| 188 | # | 210 | # |
| 189 | CONFIG_RTS7751R2D_PLUS=y | 211 | CONFIG_RTS7751R2D_PLUS=y |
| 190 | # CONFIG_RTS7751R2D_1 is not set | 212 | # CONFIG_RTS7751R2D_1 is not set |
| @@ -198,6 +220,7 @@ CONFIG_SH_PCLK_FREQ=60000000 | |||
| 198 | # CONFIG_TICK_ONESHOT is not set | 220 | # CONFIG_TICK_ONESHOT is not set |
| 199 | # CONFIG_NO_HZ is not set | 221 | # CONFIG_NO_HZ is not set |
| 200 | # CONFIG_HIGH_RES_TIMERS is not set | 222 | # CONFIG_HIGH_RES_TIMERS is not set |
| 223 | CONFIG_GENERIC_CLOCKEVENTS_BUILD=y | ||
| 201 | 224 | ||
| 202 | # | 225 | # |
| 203 | # CPU Frequency scaling | 226 | # CPU Frequency scaling |
| @@ -227,11 +250,15 @@ CONFIG_HZ_250=y | |||
| 227 | # CONFIG_HZ_300 is not set | 250 | # CONFIG_HZ_300 is not set |
| 228 | # CONFIG_HZ_1000 is not set | 251 | # CONFIG_HZ_1000 is not set |
| 229 | CONFIG_HZ=250 | 252 | CONFIG_HZ=250 |
| 253 | # CONFIG_SCHED_HRTICK is not set | ||
| 230 | # CONFIG_KEXEC is not set | 254 | # CONFIG_KEXEC is not set |
| 231 | # CONFIG_CRASH_DUMP is not set | 255 | # CONFIG_CRASH_DUMP is not set |
| 232 | CONFIG_PREEMPT_NONE=y | 256 | CONFIG_PREEMPT_NONE=y |
| 233 | # CONFIG_PREEMPT_VOLUNTARY is not set | 257 | # CONFIG_PREEMPT_VOLUNTARY is not set |
| 234 | # CONFIG_PREEMPT is not set | 258 | # CONFIG_PREEMPT is not set |
| 259 | CONFIG_RCU_TRACE=y | ||
| 260 | CONFIG_GUSA=y | ||
| 261 | # CONFIG_GUSA_RB is not set | ||
| 235 | 262 | ||
| 236 | # | 263 | # |
| 237 | # Boot options | 264 | # Boot options |
| @@ -250,10 +277,7 @@ CONFIG_SH_PCIDMA_NONCOHERENT=y | |||
| 250 | CONFIG_PCI_AUTO=y | 277 | CONFIG_PCI_AUTO=y |
| 251 | CONFIG_PCI_AUTO_UPDATE_RESOURCES=y | 278 | CONFIG_PCI_AUTO_UPDATE_RESOURCES=y |
| 252 | # CONFIG_ARCH_SUPPORTS_MSI is not set | 279 | # CONFIG_ARCH_SUPPORTS_MSI is not set |
| 253 | 280 | CONFIG_PCI_LEGACY=y | |
| 254 | # | ||
| 255 | # PCCARD (PCMCIA/CardBus) support | ||
| 256 | # | ||
| 257 | # CONFIG_PCCARD is not set | 281 | # CONFIG_PCCARD is not set |
| 258 | CONFIG_HOTPLUG_PCI=y | 282 | CONFIG_HOTPLUG_PCI=y |
| 259 | # CONFIG_HOTPLUG_PCI_FAKE is not set | 283 | # CONFIG_HOTPLUG_PCI_FAKE is not set |
| @@ -281,6 +305,7 @@ CONFIG_XFRM=y | |||
| 281 | # CONFIG_XFRM_USER is not set | 305 | # CONFIG_XFRM_USER is not set |
| 282 | # CONFIG_XFRM_SUB_POLICY is not set | 306 | # CONFIG_XFRM_SUB_POLICY is not set |
| 283 | # CONFIG_XFRM_MIGRATE is not set | 307 | # CONFIG_XFRM_MIGRATE is not set |
| 308 | # CONFIG_XFRM_STATISTICS is not set | ||
| 284 | # CONFIG_NET_KEY is not set | 309 | # CONFIG_NET_KEY is not set |
| 285 | CONFIG_INET=y | 310 | CONFIG_INET=y |
| 286 | # CONFIG_IP_MULTICAST is not set | 311 | # CONFIG_IP_MULTICAST is not set |
| @@ -299,6 +324,7 @@ CONFIG_IP_FIB_HASH=y | |||
| 299 | CONFIG_INET_XFRM_MODE_TRANSPORT=y | 324 | CONFIG_INET_XFRM_MODE_TRANSPORT=y |
| 300 | CONFIG_INET_XFRM_MODE_TUNNEL=y | 325 | CONFIG_INET_XFRM_MODE_TUNNEL=y |
| 301 | CONFIG_INET_XFRM_MODE_BEET=y | 326 | CONFIG_INET_XFRM_MODE_BEET=y |
| 327 | # CONFIG_INET_LRO is not set | ||
| 302 | CONFIG_INET_DIAG=y | 328 | CONFIG_INET_DIAG=y |
| 303 | CONFIG_INET_TCP_DIAG=y | 329 | CONFIG_INET_TCP_DIAG=y |
| 304 | # CONFIG_TCP_CONG_ADVANCED is not set | 330 | # CONFIG_TCP_CONG_ADVANCED is not set |
| @@ -324,10 +350,6 @@ CONFIG_DEFAULT_TCP_CONG="cubic" | |||
| 324 | # CONFIG_LAPB is not set | 350 | # CONFIG_LAPB is not set |
| 325 | # CONFIG_ECONET is not set | 351 | # CONFIG_ECONET is not set |
| 326 | # CONFIG_WAN_ROUTER is not set | 352 | # CONFIG_WAN_ROUTER is not set |
| 327 | |||
| 328 | # | ||
| 329 | # QoS and/or fair queueing | ||
| 330 | # | ||
| 331 | # CONFIG_NET_SCHED is not set | 353 | # CONFIG_NET_SCHED is not set |
| 332 | 354 | ||
| 333 | # | 355 | # |
| @@ -335,6 +357,7 @@ CONFIG_DEFAULT_TCP_CONG="cubic" | |||
| 335 | # | 357 | # |
| 336 | # CONFIG_NET_PKTGEN is not set | 358 | # CONFIG_NET_PKTGEN is not set |
| 337 | # CONFIG_HAMRADIO is not set | 359 | # CONFIG_HAMRADIO is not set |
| 360 | # CONFIG_CAN is not set | ||
| 338 | # CONFIG_IRDA is not set | 361 | # CONFIG_IRDA is not set |
| 339 | # CONFIG_BT is not set | 362 | # CONFIG_BT is not set |
| 340 | # CONFIG_AF_RXRPC is not set | 363 | # CONFIG_AF_RXRPC is not set |
| @@ -356,6 +379,7 @@ CONFIG_WIRELESS_EXT=y | |||
| 356 | # | 379 | # |
| 357 | # Generic Driver Options | 380 | # Generic Driver Options |
| 358 | # | 381 | # |
| 382 | CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" | ||
| 359 | CONFIG_STANDALONE=y | 383 | CONFIG_STANDALONE=y |
| 360 | CONFIG_PREVENT_FIRMWARE_BUILD=y | 384 | CONFIG_PREVENT_FIRMWARE_BUILD=y |
| 361 | CONFIG_FW_LOADER=m | 385 | CONFIG_FW_LOADER=m |
| @@ -371,6 +395,7 @@ CONFIG_BLK_DEV=y | |||
| 371 | # CONFIG_BLK_DEV_LOOP is not set | 395 | # CONFIG_BLK_DEV_LOOP is not set |
| 372 | # CONFIG_BLK_DEV_NBD is not set | 396 | # CONFIG_BLK_DEV_NBD is not set |
| 373 | # CONFIG_BLK_DEV_SX8 is not set | 397 | # CONFIG_BLK_DEV_SX8 is not set |
| 398 | # CONFIG_BLK_DEV_UB is not set | ||
| 374 | CONFIG_BLK_DEV_RAM=y | 399 | CONFIG_BLK_DEV_RAM=y |
| 375 | CONFIG_BLK_DEV_RAM_COUNT=16 | 400 | CONFIG_BLK_DEV_RAM_COUNT=16 |
| 376 | CONFIG_BLK_DEV_RAM_SIZE=4096 | 401 | CONFIG_BLK_DEV_RAM_SIZE=4096 |
| @@ -420,6 +445,7 @@ CONFIG_SCSI_WAIT_SCAN=m | |||
| 420 | # CONFIG_SCSI_FC_ATTRS is not set | 445 | # CONFIG_SCSI_FC_ATTRS is not set |
| 421 | # CONFIG_SCSI_ISCSI_ATTRS is not set | 446 | # CONFIG_SCSI_ISCSI_ATTRS is not set |
| 422 | # CONFIG_SCSI_SAS_LIBSAS is not set | 447 | # CONFIG_SCSI_SAS_LIBSAS is not set |
| 448 | # CONFIG_SCSI_SRP_ATTRS is not set | ||
| 423 | CONFIG_SCSI_LOWLEVEL=y | 449 | CONFIG_SCSI_LOWLEVEL=y |
| 424 | # CONFIG_ISCSI_TCP is not set | 450 | # CONFIG_ISCSI_TCP is not set |
| 425 | # CONFIG_BLK_DEV_3W_XXXX_RAID is not set | 451 | # CONFIG_BLK_DEV_3W_XXXX_RAID is not set |
| @@ -493,7 +519,9 @@ CONFIG_ATA=y | |||
| 493 | # CONFIG_PATA_MPIIX is not set | 519 | # CONFIG_PATA_MPIIX is not set |
| 494 | # CONFIG_PATA_OLDPIIX is not set | 520 | # CONFIG_PATA_OLDPIIX is not set |
| 495 | # CONFIG_PATA_NETCELL is not set | 521 | # CONFIG_PATA_NETCELL is not set |
| 522 | # CONFIG_PATA_NINJA32 is not set | ||
| 496 | # CONFIG_PATA_NS87410 is not set | 523 | # CONFIG_PATA_NS87410 is not set |
| 524 | # CONFIG_PATA_NS87415 is not set | ||
| 497 | # CONFIG_PATA_OPTI is not set | 525 | # CONFIG_PATA_OPTI is not set |
| 498 | # CONFIG_PATA_OPTIDMA is not set | 526 | # CONFIG_PATA_OPTIDMA is not set |
| 499 | # CONFIG_PATA_PDC_OLD is not set | 527 | # CONFIG_PATA_PDC_OLD is not set |
| @@ -508,14 +536,7 @@ CONFIG_ATA=y | |||
| 508 | # CONFIG_PATA_WINBOND is not set | 536 | # CONFIG_PATA_WINBOND is not set |
| 509 | CONFIG_PATA_PLATFORM=y | 537 | CONFIG_PATA_PLATFORM=y |
| 510 | # CONFIG_MD is not set | 538 | # CONFIG_MD is not set |
| 511 | |||
| 512 | # | ||
| 513 | # Fusion MPT device support | ||
| 514 | # | ||
| 515 | # CONFIG_FUSION is not set | 539 | # CONFIG_FUSION is not set |
| 516 | # CONFIG_FUSION_SPI is not set | ||
| 517 | # CONFIG_FUSION_FC is not set | ||
| 518 | # CONFIG_FUSION_SAS is not set | ||
| 519 | 540 | ||
| 520 | # | 541 | # |
| 521 | # IEEE 1394 (FireWire) support | 542 | # IEEE 1394 (FireWire) support |
| @@ -530,25 +551,31 @@ CONFIG_NETDEVICES=y | |||
| 530 | # CONFIG_MACVLAN is not set | 551 | # CONFIG_MACVLAN is not set |
| 531 | # CONFIG_EQUALIZER is not set | 552 | # CONFIG_EQUALIZER is not set |
| 532 | # CONFIG_TUN is not set | 553 | # CONFIG_TUN is not set |
| 554 | # CONFIG_VETH is not set | ||
| 533 | # CONFIG_ARCNET is not set | 555 | # CONFIG_ARCNET is not set |
| 534 | # CONFIG_PHYLIB is not set | 556 | # CONFIG_PHYLIB is not set |
| 535 | CONFIG_NET_ETHERNET=y | 557 | CONFIG_NET_ETHERNET=y |
| 536 | CONFIG_MII=y | 558 | CONFIG_MII=y |
| 559 | # CONFIG_AX88796 is not set | ||
| 537 | # CONFIG_STNIC is not set | 560 | # CONFIG_STNIC is not set |
| 538 | # CONFIG_HAPPYMEAL is not set | 561 | # CONFIG_HAPPYMEAL is not set |
| 539 | # CONFIG_SUNGEM is not set | 562 | # CONFIG_SUNGEM is not set |
| 540 | # CONFIG_CASSINI is not set | 563 | # CONFIG_CASSINI is not set |
| 541 | # CONFIG_NET_VENDOR_3COM is not set | 564 | # CONFIG_NET_VENDOR_3COM is not set |
| 542 | # CONFIG_SMC91X is not set | 565 | # CONFIG_SMC91X is not set |
| 566 | # CONFIG_ENC28J60 is not set | ||
| 543 | # CONFIG_NET_TULIP is not set | 567 | # CONFIG_NET_TULIP is not set |
| 544 | # CONFIG_HP100 is not set | 568 | # CONFIG_HP100 is not set |
| 569 | # CONFIG_IBM_NEW_EMAC_ZMII is not set | ||
| 570 | # CONFIG_IBM_NEW_EMAC_RGMII is not set | ||
| 571 | # CONFIG_IBM_NEW_EMAC_TAH is not set | ||
| 572 | # CONFIG_IBM_NEW_EMAC_EMAC4 is not set | ||
| 545 | CONFIG_NET_PCI=y | 573 | CONFIG_NET_PCI=y |
| 546 | # CONFIG_PCNET32 is not set | 574 | # CONFIG_PCNET32 is not set |
| 547 | # CONFIG_AMD8111_ETH is not set | 575 | # CONFIG_AMD8111_ETH is not set |
| 548 | # CONFIG_ADAPTEC_STARFIRE is not set | 576 | # CONFIG_ADAPTEC_STARFIRE is not set |
| 549 | # CONFIG_B44 is not set | 577 | # CONFIG_B44 is not set |
| 550 | # CONFIG_FORCEDETH is not set | 578 | # CONFIG_FORCEDETH is not set |
| 551 | # CONFIG_DGRS is not set | ||
| 552 | # CONFIG_EEPRO100 is not set | 579 | # CONFIG_EEPRO100 is not set |
| 553 | # CONFIG_E100 is not set | 580 | # CONFIG_E100 is not set |
| 554 | # CONFIG_FEALNX is not set | 581 | # CONFIG_FEALNX is not set |
| @@ -560,6 +587,7 @@ CONFIG_8139TOO=y | |||
| 560 | # CONFIG_8139TOO_TUNE_TWISTER is not set | 587 | # CONFIG_8139TOO_TUNE_TWISTER is not set |
| 561 | # CONFIG_8139TOO_8129 is not set | 588 | # CONFIG_8139TOO_8129 is not set |
| 562 | # CONFIG_8139_OLD_RX_RESET is not set | 589 | # CONFIG_8139_OLD_RX_RESET is not set |
| 590 | # CONFIG_R6040 is not set | ||
| 563 | # CONFIG_SIS900 is not set | 591 | # CONFIG_SIS900 is not set |
| 564 | # CONFIG_EPIC100 is not set | 592 | # CONFIG_EPIC100 is not set |
| 565 | # CONFIG_SUNDANCE is not set | 593 | # CONFIG_SUNDANCE is not set |
| @@ -570,6 +598,10 @@ CONFIG_NETDEV_1000=y | |||
| 570 | # CONFIG_ACENIC is not set | 598 | # CONFIG_ACENIC is not set |
| 571 | # CONFIG_DL2K is not set | 599 | # CONFIG_DL2K is not set |
| 572 | # CONFIG_E1000 is not set | 600 | # CONFIG_E1000 is not set |
| 601 | # CONFIG_E1000E is not set | ||
| 602 | # CONFIG_E1000E_ENABLED is not set | ||
| 603 | # CONFIG_IP1000 is not set | ||
| 604 | # CONFIG_IGB is not set | ||
| 573 | # CONFIG_NS83820 is not set | 605 | # CONFIG_NS83820 is not set |
| 574 | # CONFIG_HAMACHI is not set | 606 | # CONFIG_HAMACHI is not set |
| 575 | # CONFIG_YELLOWFIN is not set | 607 | # CONFIG_YELLOWFIN is not set |
| @@ -577,6 +609,7 @@ CONFIG_NETDEV_1000=y | |||
| 577 | # CONFIG_SIS190 is not set | 609 | # CONFIG_SIS190 is not set |
| 578 | # CONFIG_SKGE is not set | 610 | # CONFIG_SKGE is not set |
| 579 | # CONFIG_SKY2 is not set | 611 | # CONFIG_SKY2 is not set |
| 612 | # CONFIG_SK98LIN is not set | ||
| 580 | # CONFIG_VIA_VELOCITY is not set | 613 | # CONFIG_VIA_VELOCITY is not set |
| 581 | # CONFIG_TIGON3 is not set | 614 | # CONFIG_TIGON3 is not set |
| 582 | # CONFIG_BNX2 is not set | 615 | # CONFIG_BNX2 is not set |
| @@ -585,11 +618,15 @@ CONFIG_NETDEV_1000=y | |||
| 585 | CONFIG_NETDEV_10000=y | 618 | CONFIG_NETDEV_10000=y |
| 586 | # CONFIG_CHELSIO_T1 is not set | 619 | # CONFIG_CHELSIO_T1 is not set |
| 587 | # CONFIG_CHELSIO_T3 is not set | 620 | # CONFIG_CHELSIO_T3 is not set |
| 621 | # CONFIG_IXGBE is not set | ||
| 588 | # CONFIG_IXGB is not set | 622 | # CONFIG_IXGB is not set |
| 589 | # CONFIG_S2IO is not set | 623 | # CONFIG_S2IO is not set |
| 590 | # CONFIG_MYRI10GE is not set | 624 | # CONFIG_MYRI10GE is not set |
| 591 | # CONFIG_NETXEN_NIC is not set | 625 | # CONFIG_NETXEN_NIC is not set |
| 626 | # CONFIG_NIU is not set | ||
| 592 | # CONFIG_MLX4_CORE is not set | 627 | # CONFIG_MLX4_CORE is not set |
| 628 | # CONFIG_TEHUTI is not set | ||
| 629 | # CONFIG_BNX2X is not set | ||
| 593 | # CONFIG_TR is not set | 630 | # CONFIG_TR is not set |
| 594 | 631 | ||
| 595 | # | 632 | # |
| @@ -597,13 +634,21 @@ CONFIG_NETDEV_10000=y | |||
| 597 | # | 634 | # |
| 598 | # CONFIG_WLAN_PRE80211 is not set | 635 | # CONFIG_WLAN_PRE80211 is not set |
| 599 | # CONFIG_WLAN_80211 is not set | 636 | # CONFIG_WLAN_80211 is not set |
| 637 | |||
| 638 | # | ||
| 639 | # USB Network Adapters | ||
| 640 | # | ||
| 641 | # CONFIG_USB_CATC is not set | ||
| 642 | # CONFIG_USB_KAWETH is not set | ||
| 643 | # CONFIG_USB_PEGASUS is not set | ||
| 644 | # CONFIG_USB_RTL8150 is not set | ||
| 645 | # CONFIG_USB_USBNET is not set | ||
| 600 | # CONFIG_WAN is not set | 646 | # CONFIG_WAN is not set |
| 601 | # CONFIG_FDDI is not set | 647 | # CONFIG_FDDI is not set |
| 602 | # CONFIG_HIPPI is not set | 648 | # CONFIG_HIPPI is not set |
| 603 | # CONFIG_PPP is not set | 649 | # CONFIG_PPP is not set |
| 604 | # CONFIG_SLIP is not set | 650 | # CONFIG_SLIP is not set |
| 605 | # CONFIG_NET_FC is not set | 651 | # CONFIG_NET_FC is not set |
| 606 | # CONFIG_SHAPER is not set | ||
| 607 | # CONFIG_NETCONSOLE is not set | 652 | # CONFIG_NETCONSOLE is not set |
| 608 | # CONFIG_NETPOLL is not set | 653 | # CONFIG_NETPOLL is not set |
| 609 | # CONFIG_NET_POLL_CONTROLLER is not set | 654 | # CONFIG_NET_POLL_CONTROLLER is not set |
| @@ -622,7 +667,6 @@ CONFIG_INPUT=y | |||
| 622 | # | 667 | # |
| 623 | # CONFIG_INPUT_MOUSEDEV is not set | 668 | # CONFIG_INPUT_MOUSEDEV is not set |
| 624 | # CONFIG_INPUT_JOYDEV is not set | 669 | # CONFIG_INPUT_JOYDEV is not set |
| 625 | # CONFIG_INPUT_TSDEV is not set | ||
| 626 | # CONFIG_INPUT_EVDEV is not set | 670 | # CONFIG_INPUT_EVDEV is not set |
| 627 | # CONFIG_INPUT_EVBUG is not set | 671 | # CONFIG_INPUT_EVBUG is not set |
| 628 | 672 | ||
| @@ -650,6 +694,7 @@ CONFIG_VT_CONSOLE=y | |||
| 650 | CONFIG_HW_CONSOLE=y | 694 | CONFIG_HW_CONSOLE=y |
| 651 | CONFIG_VT_HW_CONSOLE_BINDING=y | 695 | CONFIG_VT_HW_CONSOLE_BINDING=y |
| 652 | # CONFIG_SERIAL_NONSTANDARD is not set | 696 | # CONFIG_SERIAL_NONSTANDARD is not set |
| 697 | # CONFIG_NOZOMI is not set | ||
| 653 | 698 | ||
| 654 | # | 699 | # |
| 655 | # Serial drivers | 700 | # Serial drivers |
| @@ -674,11 +719,9 @@ CONFIG_UNIX98_PTYS=y | |||
| 674 | CONFIG_LEGACY_PTYS=y | 719 | CONFIG_LEGACY_PTYS=y |
| 675 | CONFIG_LEGACY_PTY_COUNT=256 | 720 | CONFIG_LEGACY_PTY_COUNT=256 |
| 676 | # CONFIG_IPMI_HANDLER is not set | 721 | # CONFIG_IPMI_HANDLER is not set |
| 677 | # CONFIG_WATCHDOG is not set | ||
| 678 | CONFIG_HW_RANDOM=y | 722 | CONFIG_HW_RANDOM=y |
| 679 | # CONFIG_R3964 is not set | 723 | # CONFIG_R3964 is not set |
| 680 | # CONFIG_APPLICOM is not set | 724 | # CONFIG_APPLICOM is not set |
| 681 | # CONFIG_DRM is not set | ||
| 682 | # CONFIG_RAW_DRIVER is not set | 725 | # CONFIG_RAW_DRIVER is not set |
| 683 | # CONFIG_TCG_TPM is not set | 726 | # CONFIG_TCG_TPM is not set |
| 684 | CONFIG_DEVPORT=y | 727 | CONFIG_DEVPORT=y |
| @@ -687,16 +730,30 @@ CONFIG_DEVPORT=y | |||
| 687 | # | 730 | # |
| 688 | # SPI support | 731 | # SPI support |
| 689 | # | 732 | # |
| 690 | # CONFIG_SPI is not set | 733 | CONFIG_SPI=y |
| 691 | # CONFIG_SPI_MASTER is not set | 734 | CONFIG_SPI_MASTER=y |
| 735 | |||
| 736 | # | ||
| 737 | # SPI Master Controller Drivers | ||
| 738 | # | ||
| 739 | CONFIG_SPI_BITBANG=y | ||
| 740 | CONFIG_SPI_SH_SCI=y | ||
| 741 | |||
| 742 | # | ||
| 743 | # SPI Protocol Masters | ||
| 744 | # | ||
| 745 | # CONFIG_SPI_AT25 is not set | ||
| 746 | # CONFIG_SPI_SPIDEV is not set | ||
| 747 | # CONFIG_SPI_TLE62X0 is not set | ||
| 692 | # CONFIG_W1 is not set | 748 | # CONFIG_W1 is not set |
| 693 | # CONFIG_POWER_SUPPLY is not set | 749 | # CONFIG_POWER_SUPPLY is not set |
| 694 | CONFIG_HWMON=y | 750 | CONFIG_HWMON=y |
| 695 | # CONFIG_HWMON_VID is not set | 751 | # CONFIG_HWMON_VID is not set |
| 696 | # CONFIG_SENSORS_ABITUGURU is not set | 752 | # CONFIG_SENSORS_I5K_AMB is not set |
| 697 | # CONFIG_SENSORS_ABITUGURU3 is not set | ||
| 698 | # CONFIG_SENSORS_F71805F is not set | 753 | # CONFIG_SENSORS_F71805F is not set |
| 754 | # CONFIG_SENSORS_F71882FG is not set | ||
| 699 | # CONFIG_SENSORS_IT87 is not set | 755 | # CONFIG_SENSORS_IT87 is not set |
| 756 | # CONFIG_SENSORS_LM70 is not set | ||
| 700 | # CONFIG_SENSORS_PC87360 is not set | 757 | # CONFIG_SENSORS_PC87360 is not set |
| 701 | # CONFIG_SENSORS_PC87427 is not set | 758 | # CONFIG_SENSORS_PC87427 is not set |
| 702 | # CONFIG_SENSORS_SIS5595 is not set | 759 | # CONFIG_SENSORS_SIS5595 is not set |
| @@ -708,6 +765,13 @@ CONFIG_HWMON=y | |||
| 708 | # CONFIG_SENSORS_W83627HF is not set | 765 | # CONFIG_SENSORS_W83627HF is not set |
| 709 | # CONFIG_SENSORS_W83627EHF is not set | 766 | # CONFIG_SENSORS_W83627EHF is not set |
| 710 | # CONFIG_HWMON_DEBUG_CHIP is not set | 767 | # CONFIG_HWMON_DEBUG_CHIP is not set |
| 768 | # CONFIG_WATCHDOG is not set | ||
| 769 | |||
| 770 | # | ||
| 771 | # Sonics Silicon Backplane | ||
| 772 | # | ||
| 773 | CONFIG_SSB_POSSIBLE=y | ||
| 774 | # CONFIG_SSB is not set | ||
| 711 | 775 | ||
| 712 | # | 776 | # |
| 713 | # Multifunction device drivers | 777 | # Multifunction device drivers |
| @@ -720,16 +784,12 @@ CONFIG_MFD_SM501=y | |||
| 720 | # CONFIG_VIDEO_DEV is not set | 784 | # CONFIG_VIDEO_DEV is not set |
| 721 | # CONFIG_DVB_CORE is not set | 785 | # CONFIG_DVB_CORE is not set |
| 722 | CONFIG_DAB=y | 786 | CONFIG_DAB=y |
| 787 | # CONFIG_USB_DABUSB is not set | ||
| 723 | 788 | ||
| 724 | # | 789 | # |
| 725 | # Graphics support | 790 | # Graphics support |
| 726 | # | 791 | # |
| 727 | # CONFIG_BACKLIGHT_LCD_SUPPORT is not set | 792 | # CONFIG_DRM is not set |
| 728 | |||
| 729 | # | ||
| 730 | # Display device support | ||
| 731 | # | ||
| 732 | # CONFIG_DISPLAY_SUPPORT is not set | ||
| 733 | # CONFIG_VGASTATE is not set | 793 | # CONFIG_VGASTATE is not set |
| 734 | CONFIG_VIDEO_OUTPUT_CONTROL=m | 794 | CONFIG_VIDEO_OUTPUT_CONTROL=m |
| 735 | CONFIG_FB=y | 795 | CONFIG_FB=y |
| @@ -738,6 +798,7 @@ CONFIG_FB=y | |||
| 738 | CONFIG_FB_CFB_FILLRECT=y | 798 | CONFIG_FB_CFB_FILLRECT=y |
| 739 | CONFIG_FB_CFB_COPYAREA=y | 799 | CONFIG_FB_CFB_COPYAREA=y |
| 740 | CONFIG_FB_CFB_IMAGEBLIT=y | 800 | CONFIG_FB_CFB_IMAGEBLIT=y |
| 801 | # CONFIG_FB_CFB_REV_PIXELS_IN_BYTE is not set | ||
| 741 | # CONFIG_FB_SYS_FILLRECT is not set | 802 | # CONFIG_FB_SYS_FILLRECT is not set |
| 742 | # CONFIG_FB_SYS_COPYAREA is not set | 803 | # CONFIG_FB_SYS_COPYAREA is not set |
| 743 | # CONFIG_FB_SYS_IMAGEBLIT is not set | 804 | # CONFIG_FB_SYS_IMAGEBLIT is not set |
| @@ -777,6 +838,12 @@ CONFIG_FB_DEFERRED_IO=y | |||
| 777 | # CONFIG_FB_PM3 is not set | 838 | # CONFIG_FB_PM3 is not set |
| 778 | CONFIG_FB_SM501=y | 839 | CONFIG_FB_SM501=y |
| 779 | # CONFIG_FB_VIRTUAL is not set | 840 | # CONFIG_FB_VIRTUAL is not set |
| 841 | # CONFIG_BACKLIGHT_LCD_SUPPORT is not set | ||
| 842 | |||
| 843 | # | ||
| 844 | # Display device support | ||
| 845 | # | ||
| 846 | # CONFIG_DISPLAY_SUPPORT is not set | ||
| 780 | 847 | ||
| 781 | # | 848 | # |
| 782 | # Console display driver support | 849 | # Console display driver support |
| @@ -844,6 +911,7 @@ CONFIG_SND_AC97_CODEC=m | |||
| 844 | # CONFIG_SND_BT87X is not set | 911 | # CONFIG_SND_BT87X is not set |
| 845 | # CONFIG_SND_CA0106 is not set | 912 | # CONFIG_SND_CA0106 is not set |
| 846 | # CONFIG_SND_CMIPCI is not set | 913 | # CONFIG_SND_CMIPCI is not set |
| 914 | # CONFIG_SND_OXYGEN is not set | ||
| 847 | # CONFIG_SND_CS4281 is not set | 915 | # CONFIG_SND_CS4281 is not set |
| 848 | # CONFIG_SND_CS46XX is not set | 916 | # CONFIG_SND_CS46XX is not set |
| 849 | # CONFIG_SND_DARLA20 is not set | 917 | # CONFIG_SND_DARLA20 is not set |
| @@ -868,6 +936,7 @@ CONFIG_SND_AC97_CODEC=m | |||
| 868 | # CONFIG_SND_HDA_INTEL is not set | 936 | # CONFIG_SND_HDA_INTEL is not set |
| 869 | # CONFIG_SND_HDSP is not set | 937 | # CONFIG_SND_HDSP is not set |
| 870 | # CONFIG_SND_HDSPM is not set | 938 | # CONFIG_SND_HDSPM is not set |
| 939 | # CONFIG_SND_HIFIER is not set | ||
| 871 | # CONFIG_SND_ICE1712 is not set | 940 | # CONFIG_SND_ICE1712 is not set |
| 872 | # CONFIG_SND_ICE1724 is not set | 941 | # CONFIG_SND_ICE1724 is not set |
| 873 | # CONFIG_SND_INTEL8X0 is not set | 942 | # CONFIG_SND_INTEL8X0 is not set |
| @@ -885,16 +954,27 @@ CONFIG_SND_AC97_CODEC=m | |||
| 885 | # CONFIG_SND_TRIDENT is not set | 954 | # CONFIG_SND_TRIDENT is not set |
| 886 | # CONFIG_SND_VIA82XX is not set | 955 | # CONFIG_SND_VIA82XX is not set |
| 887 | # CONFIG_SND_VIA82XX_MODEM is not set | 956 | # CONFIG_SND_VIA82XX_MODEM is not set |
| 957 | # CONFIG_SND_VIRTUOSO is not set | ||
| 888 | # CONFIG_SND_VX222 is not set | 958 | # CONFIG_SND_VX222 is not set |
| 889 | CONFIG_SND_YMFPCI=m | 959 | CONFIG_SND_YMFPCI=m |
| 890 | CONFIG_SND_YMFPCI_FIRMWARE_IN_KERNEL=y | 960 | CONFIG_SND_YMFPCI_FIRMWARE_IN_KERNEL=y |
| 891 | # CONFIG_SND_AC97_POWER_SAVE is not set | 961 | # CONFIG_SND_AC97_POWER_SAVE is not set |
| 892 | 962 | ||
| 893 | # | 963 | # |
| 964 | # SPI devices | ||
| 965 | # | ||
| 966 | |||
| 967 | # | ||
| 894 | # SUPERH devices | 968 | # SUPERH devices |
| 895 | # | 969 | # |
| 896 | 970 | ||
| 897 | # | 971 | # |
| 972 | # USB devices | ||
| 973 | # | ||
| 974 | # CONFIG_SND_USB_AUDIO is not set | ||
| 975 | # CONFIG_SND_USB_CAIAQ is not set | ||
| 976 | |||
| 977 | # | ||
| 898 | # System on Chip audio support | 978 | # System on Chip audio support |
| 899 | # | 979 | # |
| 900 | # CONFIG_SND_SOC is not set | 980 | # CONFIG_SND_SOC is not set |
| @@ -904,6 +984,10 @@ CONFIG_SND_YMFPCI_FIRMWARE_IN_KERNEL=y | |||
| 904 | # | 984 | # |
| 905 | 985 | ||
| 906 | # | 986 | # |
| 987 | # ALSA SoC audio for Freescale SOCs | ||
| 988 | # | ||
| 989 | |||
| 990 | # | ||
| 907 | # Open Sound System | 991 | # Open Sound System |
| 908 | # | 992 | # |
| 909 | CONFIG_SOUND_PRIME=m | 993 | CONFIG_SOUND_PRIME=m |
| @@ -914,19 +998,104 @@ CONFIG_AC97_BUS=m | |||
| 914 | CONFIG_HID_SUPPORT=y | 998 | CONFIG_HID_SUPPORT=y |
| 915 | CONFIG_HID=y | 999 | CONFIG_HID=y |
| 916 | # CONFIG_HID_DEBUG is not set | 1000 | # CONFIG_HID_DEBUG is not set |
| 1001 | # CONFIG_HIDRAW is not set | ||
| 1002 | |||
| 1003 | # | ||
| 1004 | # USB Input Devices | ||
| 1005 | # | ||
| 1006 | CONFIG_USB_HID=y | ||
| 1007 | # CONFIG_USB_HIDINPUT_POWERBOOK is not set | ||
| 1008 | # CONFIG_HID_FF is not set | ||
| 1009 | # CONFIG_USB_HIDDEV is not set | ||
| 917 | CONFIG_USB_SUPPORT=y | 1010 | CONFIG_USB_SUPPORT=y |
| 918 | CONFIG_USB_ARCH_HAS_HCD=y | 1011 | CONFIG_USB_ARCH_HAS_HCD=y |
| 919 | CONFIG_USB_ARCH_HAS_OHCI=y | 1012 | CONFIG_USB_ARCH_HAS_OHCI=y |
| 920 | CONFIG_USB_ARCH_HAS_EHCI=y | 1013 | CONFIG_USB_ARCH_HAS_EHCI=y |
| 921 | # CONFIG_USB is not set | 1014 | CONFIG_USB=y |
| 1015 | # CONFIG_USB_DEBUG is not set | ||
| 1016 | CONFIG_USB_ANNOUNCE_NEW_DEVICES=y | ||
| 1017 | |||
| 1018 | # | ||
| 1019 | # Miscellaneous USB options | ||
| 1020 | # | ||
| 1021 | # CONFIG_USB_DEVICEFS is not set | ||
| 1022 | CONFIG_USB_DEVICE_CLASS=y | ||
| 1023 | # CONFIG_USB_DYNAMIC_MINORS is not set | ||
| 1024 | # CONFIG_USB_OTG is not set | ||
| 1025 | |||
| 1026 | # | ||
| 1027 | # USB Host Controller Drivers | ||
| 1028 | # | ||
| 1029 | # CONFIG_USB_EHCI_HCD is not set | ||
| 1030 | # CONFIG_USB_ISP116X_HCD is not set | ||
| 1031 | CONFIG_USB_OHCI_HCD=y | ||
| 1032 | # CONFIG_USB_OHCI_BIG_ENDIAN_DESC is not set | ||
| 1033 | # CONFIG_USB_OHCI_BIG_ENDIAN_MMIO is not set | ||
| 1034 | CONFIG_USB_OHCI_LITTLE_ENDIAN=y | ||
| 1035 | # CONFIG_USB_UHCI_HCD is not set | ||
| 1036 | # CONFIG_USB_SL811_HCD is not set | ||
| 1037 | # CONFIG_USB_R8A66597_HCD is not set | ||
| 1038 | |||
| 1039 | # | ||
| 1040 | # USB Device Class drivers | ||
| 1041 | # | ||
| 1042 | # CONFIG_USB_ACM is not set | ||
| 1043 | # CONFIG_USB_PRINTER is not set | ||
| 922 | 1044 | ||
| 923 | # | 1045 | # |
| 924 | # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' | 1046 | # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' |
| 925 | # | 1047 | # |
| 926 | 1048 | ||
| 927 | # | 1049 | # |
| 928 | # USB Gadget Support | 1050 | # may also be needed; see USB_STORAGE Help for more information |
| 1051 | # | ||
| 1052 | CONFIG_USB_STORAGE=y | ||
| 1053 | # CONFIG_USB_STORAGE_DEBUG is not set | ||
| 1054 | # CONFIG_USB_STORAGE_DATAFAB is not set | ||
| 1055 | # CONFIG_USB_STORAGE_FREECOM is not set | ||
| 1056 | # CONFIG_USB_STORAGE_ISD200 is not set | ||
| 1057 | # CONFIG_USB_STORAGE_DPCM is not set | ||
| 1058 | # CONFIG_USB_STORAGE_USBAT is not set | ||
| 1059 | # CONFIG_USB_STORAGE_SDDR09 is not set | ||
| 1060 | # CONFIG_USB_STORAGE_SDDR55 is not set | ||
| 1061 | # CONFIG_USB_STORAGE_JUMPSHOT is not set | ||
| 1062 | # CONFIG_USB_STORAGE_ALAUDA is not set | ||
| 1063 | # CONFIG_USB_STORAGE_KARMA is not set | ||
| 1064 | CONFIG_USB_LIBUSUAL=y | ||
| 1065 | |||
| 1066 | # | ||
| 1067 | # USB Imaging devices | ||
| 1068 | # | ||
| 1069 | # CONFIG_USB_MDC800 is not set | ||
| 1070 | # CONFIG_USB_MICROTEK is not set | ||
| 1071 | # CONFIG_USB_MON is not set | ||
| 1072 | |||
| 1073 | # | ||
| 1074 | # USB port drivers | ||
| 1075 | # | ||
| 1076 | # CONFIG_USB_SERIAL is not set | ||
| 1077 | |||
| 1078 | # | ||
| 1079 | # USB Miscellaneous drivers | ||
| 929 | # | 1080 | # |
| 1081 | # CONFIG_USB_EMI62 is not set | ||
| 1082 | # CONFIG_USB_EMI26 is not set | ||
| 1083 | # CONFIG_USB_ADUTUX is not set | ||
| 1084 | # CONFIG_USB_AUERSWALD is not set | ||
| 1085 | # CONFIG_USB_RIO500 is not set | ||
| 1086 | # CONFIG_USB_LEGOTOWER is not set | ||
| 1087 | # CONFIG_USB_LCD is not set | ||
| 1088 | # CONFIG_USB_BERRY_CHARGE is not set | ||
| 1089 | # CONFIG_USB_LED is not set | ||
| 1090 | # CONFIG_USB_CYPRESS_CY7C63 is not set | ||
| 1091 | # CONFIG_USB_CYTHERM is not set | ||
| 1092 | # CONFIG_USB_PHIDGET is not set | ||
| 1093 | # CONFIG_USB_IDMOUSE is not set | ||
| 1094 | # CONFIG_USB_FTDI_ELAN is not set | ||
| 1095 | # CONFIG_USB_APPLEDISPLAY is not set | ||
| 1096 | # CONFIG_USB_LD is not set | ||
| 1097 | # CONFIG_USB_TRANCEVIBRATOR is not set | ||
| 1098 | # CONFIG_USB_IOWARRIOR is not set | ||
| 930 | # CONFIG_USB_GADGET is not set | 1099 | # CONFIG_USB_GADGET is not set |
| 931 | # CONFIG_MMC is not set | 1100 | # CONFIG_MMC is not set |
| 932 | # CONFIG_NEW_LEDS is not set | 1101 | # CONFIG_NEW_LEDS is not set |
| @@ -949,13 +1118,17 @@ CONFIG_RTC_INTF_DEV=y | |||
| 949 | # | 1118 | # |
| 950 | # SPI RTC drivers | 1119 | # SPI RTC drivers |
| 951 | # | 1120 | # |
| 1121 | # CONFIG_RTC_DRV_MAX6902 is not set | ||
| 1122 | CONFIG_RTC_DRV_R9701=y | ||
| 1123 | # CONFIG_RTC_DRV_RS5C348 is not set | ||
| 952 | 1124 | ||
| 953 | # | 1125 | # |
| 954 | # Platform RTC drivers | 1126 | # Platform RTC drivers |
| 955 | # | 1127 | # |
| 1128 | # CONFIG_RTC_DRV_DS1511 is not set | ||
| 956 | # CONFIG_RTC_DRV_DS1553 is not set | 1129 | # CONFIG_RTC_DRV_DS1553 is not set |
| 957 | # CONFIG_RTC_DRV_STK17TA8 is not set | ||
| 958 | # CONFIG_RTC_DRV_DS1742 is not set | 1130 | # CONFIG_RTC_DRV_DS1742 is not set |
| 1131 | # CONFIG_RTC_DRV_STK17TA8 is not set | ||
| 959 | # CONFIG_RTC_DRV_M48T86 is not set | 1132 | # CONFIG_RTC_DRV_M48T86 is not set |
| 960 | # CONFIG_RTC_DRV_M48T59 is not set | 1133 | # CONFIG_RTC_DRV_M48T59 is not set |
| 961 | # CONFIG_RTC_DRV_V3020 is not set | 1134 | # CONFIG_RTC_DRV_V3020 is not set |
| @@ -963,20 +1136,7 @@ CONFIG_RTC_INTF_DEV=y | |||
| 963 | # | 1136 | # |
| 964 | # on-CPU RTC drivers | 1137 | # on-CPU RTC drivers |
| 965 | # | 1138 | # |
| 966 | CONFIG_RTC_DRV_SH=y | 1139 | # CONFIG_RTC_DRV_SH is not set |
| 967 | |||
| 968 | # | ||
| 969 | # DMA Engine support | ||
| 970 | # | ||
| 971 | # CONFIG_DMA_ENGINE is not set | ||
| 972 | |||
| 973 | # | ||
| 974 | # DMA Clients | ||
| 975 | # | ||
| 976 | |||
| 977 | # | ||
| 978 | # DMA Devices | ||
| 979 | # | ||
| 980 | 1140 | ||
| 981 | # | 1141 | # |
| 982 | # Userspace I/O | 1142 | # Userspace I/O |
| @@ -1034,7 +1194,6 @@ CONFIG_TMPFS=y | |||
| 1034 | # CONFIG_TMPFS_POSIX_ACL is not set | 1194 | # CONFIG_TMPFS_POSIX_ACL is not set |
| 1035 | # CONFIG_HUGETLBFS is not set | 1195 | # CONFIG_HUGETLBFS is not set |
| 1036 | # CONFIG_HUGETLB_PAGE is not set | 1196 | # CONFIG_HUGETLB_PAGE is not set |
| 1037 | CONFIG_RAMFS=y | ||
| 1038 | # CONFIG_CONFIGFS_FS is not set | 1197 | # CONFIG_CONFIGFS_FS is not set |
| 1039 | 1198 | ||
| 1040 | # | 1199 | # |
| @@ -1053,10 +1212,7 @@ CONFIG_RAMFS=y | |||
| 1053 | # CONFIG_QNX4FS_FS is not set | 1212 | # CONFIG_QNX4FS_FS is not set |
| 1054 | # CONFIG_SYSV_FS is not set | 1213 | # CONFIG_SYSV_FS is not set |
| 1055 | # CONFIG_UFS_FS is not set | 1214 | # CONFIG_UFS_FS is not set |
| 1056 | 1215 | CONFIG_NETWORK_FILESYSTEMS=y | |
| 1057 | # | ||
| 1058 | # Network File Systems | ||
| 1059 | # | ||
| 1060 | # CONFIG_NFS_FS is not set | 1216 | # CONFIG_NFS_FS is not set |
| 1061 | # CONFIG_NFSD is not set | 1217 | # CONFIG_NFSD is not set |
| 1062 | # CONFIG_SMB_FS is not set | 1218 | # CONFIG_SMB_FS is not set |
| @@ -1070,10 +1226,6 @@ CONFIG_RAMFS=y | |||
| 1070 | # | 1226 | # |
| 1071 | # CONFIG_PARTITION_ADVANCED is not set | 1227 | # CONFIG_PARTITION_ADVANCED is not set |
| 1072 | CONFIG_MSDOS_PARTITION=y | 1228 | CONFIG_MSDOS_PARTITION=y |
| 1073 | |||
| 1074 | # | ||
| 1075 | # Native Language Support | ||
| 1076 | # | ||
| 1077 | CONFIG_NLS=y | 1229 | CONFIG_NLS=y |
| 1078 | CONFIG_NLS_DEFAULT="iso8859-1" | 1230 | CONFIG_NLS_DEFAULT="iso8859-1" |
| 1079 | # CONFIG_NLS_CODEPAGE_437 is not set | 1231 | # CONFIG_NLS_CODEPAGE_437 is not set |
| @@ -1114,30 +1266,22 @@ CONFIG_NLS_CODEPAGE_932=y | |||
| 1114 | # CONFIG_NLS_KOI8_R is not set | 1266 | # CONFIG_NLS_KOI8_R is not set |
| 1115 | # CONFIG_NLS_KOI8_U is not set | 1267 | # CONFIG_NLS_KOI8_U is not set |
| 1116 | # CONFIG_NLS_UTF8 is not set | 1268 | # CONFIG_NLS_UTF8 is not set |
| 1117 | |||
| 1118 | # | ||
| 1119 | # Distributed Lock Manager | ||
| 1120 | # | ||
| 1121 | # CONFIG_DLM is not set | 1269 | # CONFIG_DLM is not set |
| 1122 | 1270 | ||
| 1123 | # | 1271 | # |
| 1124 | # Profiling support | ||
| 1125 | # | ||
| 1126 | CONFIG_PROFILING=y | ||
| 1127 | CONFIG_OPROFILE=y | ||
| 1128 | |||
| 1129 | # | ||
| 1130 | # Kernel hacking | 1272 | # Kernel hacking |
| 1131 | # | 1273 | # |
| 1132 | CONFIG_TRACE_IRQFLAGS_SUPPORT=y | 1274 | CONFIG_TRACE_IRQFLAGS_SUPPORT=y |
| 1133 | # CONFIG_PRINTK_TIME is not set | 1275 | # CONFIG_PRINTK_TIME is not set |
| 1276 | CONFIG_ENABLE_WARN_DEPRECATED=y | ||
| 1134 | CONFIG_ENABLE_MUST_CHECK=y | 1277 | CONFIG_ENABLE_MUST_CHECK=y |
| 1135 | # CONFIG_MAGIC_SYSRQ is not set | 1278 | # CONFIG_MAGIC_SYSRQ is not set |
| 1136 | # CONFIG_UNUSED_SYMBOLS is not set | 1279 | # CONFIG_UNUSED_SYMBOLS is not set |
| 1137 | # CONFIG_DEBUG_FS is not set | 1280 | CONFIG_DEBUG_FS=y |
| 1138 | # CONFIG_HEADERS_CHECK is not set | 1281 | # CONFIG_HEADERS_CHECK is not set |
| 1139 | # CONFIG_DEBUG_KERNEL is not set | 1282 | # CONFIG_DEBUG_KERNEL is not set |
| 1140 | # CONFIG_DEBUG_BUGVERBOSE is not set | 1283 | # CONFIG_DEBUG_BUGVERBOSE is not set |
| 1284 | # CONFIG_SAMPLES is not set | ||
| 1141 | # CONFIG_SH_STANDARD_BIOS is not set | 1285 | # CONFIG_SH_STANDARD_BIOS is not set |
| 1142 | CONFIG_EARLY_SCIF_CONSOLE=y | 1286 | CONFIG_EARLY_SCIF_CONSOLE=y |
| 1143 | CONFIG_EARLY_SCIF_CONSOLE_PORT=0xffe80000 | 1287 | CONFIG_EARLY_SCIF_CONSOLE_PORT=0xffe80000 |
| @@ -1149,7 +1293,53 @@ CONFIG_EARLY_PRINTK=y | |||
| 1149 | # | 1293 | # |
| 1150 | # CONFIG_KEYS is not set | 1294 | # CONFIG_KEYS is not set |
| 1151 | # CONFIG_SECURITY is not set | 1295 | # CONFIG_SECURITY is not set |
| 1152 | # CONFIG_CRYPTO is not set | 1296 | # CONFIG_SECURITY_FILE_CAPABILITIES is not set |
| 1297 | CONFIG_CRYPTO=y | ||
| 1298 | # CONFIG_CRYPTO_SEQIV is not set | ||
| 1299 | # CONFIG_CRYPTO_MANAGER is not set | ||
| 1300 | # CONFIG_CRYPTO_HMAC is not set | ||
| 1301 | # CONFIG_CRYPTO_XCBC is not set | ||
| 1302 | # CONFIG_CRYPTO_NULL is not set | ||
| 1303 | # CONFIG_CRYPTO_MD4 is not set | ||
| 1304 | # CONFIG_CRYPTO_MD5 is not set | ||
| 1305 | # CONFIG_CRYPTO_SHA1 is not set | ||
| 1306 | # CONFIG_CRYPTO_SHA256 is not set | ||
| 1307 | # CONFIG_CRYPTO_SHA512 is not set | ||
| 1308 | # CONFIG_CRYPTO_WP512 is not set | ||
| 1309 | # CONFIG_CRYPTO_TGR192 is not set | ||
| 1310 | # CONFIG_CRYPTO_GF128MUL is not set | ||
| 1311 | # CONFIG_CRYPTO_ECB is not set | ||
| 1312 | # CONFIG_CRYPTO_CBC is not set | ||
| 1313 | # CONFIG_CRYPTO_PCBC is not set | ||
| 1314 | # CONFIG_CRYPTO_LRW is not set | ||
| 1315 | # CONFIG_CRYPTO_XTS is not set | ||
| 1316 | # CONFIG_CRYPTO_CTR is not set | ||
| 1317 | # CONFIG_CRYPTO_GCM is not set | ||
| 1318 | # CONFIG_CRYPTO_CCM is not set | ||
| 1319 | # CONFIG_CRYPTO_CRYPTD is not set | ||
| 1320 | # CONFIG_CRYPTO_DES is not set | ||
| 1321 | # CONFIG_CRYPTO_FCRYPT is not set | ||
| 1322 | # CONFIG_CRYPTO_BLOWFISH is not set | ||
| 1323 | # CONFIG_CRYPTO_TWOFISH is not set | ||
| 1324 | # CONFIG_CRYPTO_SERPENT is not set | ||
| 1325 | # CONFIG_CRYPTO_AES is not set | ||
| 1326 | # CONFIG_CRYPTO_CAST5 is not set | ||
| 1327 | # CONFIG_CRYPTO_CAST6 is not set | ||
| 1328 | # CONFIG_CRYPTO_TEA is not set | ||
| 1329 | # CONFIG_CRYPTO_ARC4 is not set | ||
| 1330 | # CONFIG_CRYPTO_KHAZAD is not set | ||
| 1331 | # CONFIG_CRYPTO_ANUBIS is not set | ||
| 1332 | # CONFIG_CRYPTO_SEED is not set | ||
| 1333 | # CONFIG_CRYPTO_SALSA20 is not set | ||
| 1334 | # CONFIG_CRYPTO_DEFLATE is not set | ||
| 1335 | # CONFIG_CRYPTO_MICHAEL_MIC is not set | ||
| 1336 | # CONFIG_CRYPTO_CRC32C is not set | ||
| 1337 | # CONFIG_CRYPTO_CAMELLIA is not set | ||
| 1338 | # CONFIG_CRYPTO_TEST is not set | ||
| 1339 | # CONFIG_CRYPTO_AUTHENC is not set | ||
| 1340 | # CONFIG_CRYPTO_LZO is not set | ||
| 1341 | CONFIG_CRYPTO_HW=y | ||
| 1342 | # CONFIG_CRYPTO_DEV_HIFN_795X is not set | ||
| 1153 | 1343 | ||
| 1154 | # | 1344 | # |
| 1155 | # Library routines | 1345 | # Library routines |
diff --git a/arch/sh/configs/se7705_defconfig b/arch/sh/configs/se7705_defconfig index 87ae5c1f8629..84717d854867 100644 --- a/arch/sh/configs/se7705_defconfig +++ b/arch/sh/configs/se7705_defconfig | |||
| @@ -231,7 +231,6 @@ CONFIG_CPU_LITTLE_ENDIAN=y | |||
| 231 | # CONFIG_SH_DSP is not set | 231 | # CONFIG_SH_DSP is not set |
| 232 | # CONFIG_SH_ADC is not set | 232 | # CONFIG_SH_ADC is not set |
| 233 | CONFIG_CPU_HAS_INTEVT=y | 233 | CONFIG_CPU_HAS_INTEVT=y |
| 234 | CONFIG_CPU_HAS_PINT_IRQ=y | ||
| 235 | CONFIG_CPU_HAS_IPR_IRQ=y | 234 | CONFIG_CPU_HAS_IPR_IRQ=y |
| 236 | CONFIG_CPU_HAS_SR_RB=y | 235 | CONFIG_CPU_HAS_SR_RB=y |
| 237 | 236 | ||
diff --git a/arch/sh/drivers/dma/dma-api.c b/arch/sh/drivers/dma/dma-api.c index 76ed816d9a24..727126e907e3 100644 --- a/arch/sh/drivers/dma/dma-api.c +++ b/arch/sh/drivers/dma/dma-api.c | |||
| @@ -350,7 +350,7 @@ int register_dmac(struct dma_info *info) | |||
| 350 | 350 | ||
| 351 | BUG_ON((info->flags & DMAC_CHANNELS_CONFIGURED) && !info->channels); | 351 | BUG_ON((info->flags & DMAC_CHANNELS_CONFIGURED) && !info->channels); |
| 352 | 352 | ||
| 353 | info->pdev = platform_device_register_simple((char *)info->name, -1, | 353 | info->pdev = platform_device_register_simple(info->name, -1, |
| 354 | NULL, 0); | 354 | NULL, 0); |
| 355 | if (IS_ERR(info->pdev)) | 355 | if (IS_ERR(info->pdev)) |
| 356 | return PTR_ERR(info->pdev); | 356 | return PTR_ERR(info->pdev); |
diff --git a/arch/sh/drivers/pci/fixups-lboxre2.c b/arch/sh/drivers/pci/fixups-lboxre2.c index 40b19bdfb891..1c1d41255ec0 100644 --- a/arch/sh/drivers/pci/fixups-lboxre2.c +++ b/arch/sh/drivers/pci/fixups-lboxre2.c | |||
| @@ -18,7 +18,7 @@ int pci_fixup_pcic(void) | |||
| 18 | { | 18 | { |
| 19 | unsigned long bcr1, mcr; | 19 | unsigned long bcr1, mcr; |
| 20 | 20 | ||
| 21 | bcr1 = inl(SH7751_BCR1); | 21 | bcr1 = ctrl_inl(SH7751_BCR1); |
| 22 | bcr1 |= 0x40080000; /* Enable Bit 19 BREQEN, set PCIC to slave */ | 22 | bcr1 |= 0x40080000; /* Enable Bit 19 BREQEN, set PCIC to slave */ |
| 23 | pci_write_reg(bcr1, SH4_PCIBCR1); | 23 | pci_write_reg(bcr1, SH4_PCIBCR1); |
| 24 | 24 | ||
| @@ -28,7 +28,7 @@ int pci_fixup_pcic(void) | |||
| 28 | pci_write_reg(0xfb900047, SH7751_PCICONF1); | 28 | pci_write_reg(0xfb900047, SH7751_PCICONF1); |
| 29 | pci_write_reg(0xab000001, SH7751_PCICONF4); | 29 | pci_write_reg(0xab000001, SH7751_PCICONF4); |
| 30 | 30 | ||
| 31 | mcr = inl(SH7751_MCR); | 31 | mcr = ctrl_inl(SH7751_MCR); |
| 32 | mcr = (mcr & PCIMCR_MRSET_OFF) & PCIMCR_RFSH_OFF; | 32 | mcr = (mcr & PCIMCR_MRSET_OFF) & PCIMCR_RFSH_OFF; |
| 33 | pci_write_reg(mcr, SH4_PCIMCR); | 33 | pci_write_reg(mcr, SH4_PCIMCR); |
| 34 | 34 | ||
diff --git a/arch/sh/drivers/pci/fixups-rts7751r2d.c b/arch/sh/drivers/pci/fixups-rts7751r2d.c index e72ceb560d5b..904bce8768d3 100644 --- a/arch/sh/drivers/pci/fixups-rts7751r2d.c +++ b/arch/sh/drivers/pci/fixups-rts7751r2d.c | |||
| @@ -19,7 +19,7 @@ int pci_fixup_pcic(void) | |||
| 19 | { | 19 | { |
| 20 | unsigned long bcr1, mcr; | 20 | unsigned long bcr1, mcr; |
| 21 | 21 | ||
| 22 | bcr1 = inl(SH7751_BCR1); | 22 | bcr1 = ctrl_inl(SH7751_BCR1); |
| 23 | bcr1 |= 0x40080000; /* Enable Bit 19 BREQEN, set PCIC to slave */ | 23 | bcr1 |= 0x40080000; /* Enable Bit 19 BREQEN, set PCIC to slave */ |
| 24 | pci_write_reg(bcr1, SH4_PCIBCR1); | 24 | pci_write_reg(bcr1, SH4_PCIBCR1); |
| 25 | 25 | ||
| @@ -30,7 +30,7 @@ int pci_fixup_pcic(void) | |||
| 30 | pci_write_reg(0xfb900047, SH7751_PCICONF1); | 30 | pci_write_reg(0xfb900047, SH7751_PCICONF1); |
| 31 | pci_write_reg(0xab000001, SH7751_PCICONF4); | 31 | pci_write_reg(0xab000001, SH7751_PCICONF4); |
| 32 | 32 | ||
| 33 | mcr = inl(SH7751_MCR); | 33 | mcr = ctrl_inl(SH7751_MCR); |
| 34 | mcr = (mcr & PCIMCR_MRSET_OFF) & PCIMCR_RFSH_OFF; | 34 | mcr = (mcr & PCIMCR_MRSET_OFF) & PCIMCR_RFSH_OFF; |
| 35 | pci_write_reg(mcr, SH4_PCIMCR); | 35 | pci_write_reg(mcr, SH4_PCIMCR); |
| 36 | 36 | ||
diff --git a/arch/sh/drivers/pci/ops-dreamcast.c b/arch/sh/drivers/pci/ops-dreamcast.c index e1284fc69361..0dac87b19624 100644 --- a/arch/sh/drivers/pci/ops-dreamcast.c +++ b/arch/sh/drivers/pci/ops-dreamcast.c | |||
| @@ -83,9 +83,9 @@ static int gapspci_read(struct pci_bus *bus, unsigned int devfn, int where, int | |||
| 83 | return PCIBIOS_DEVICE_NOT_FOUND; | 83 | return PCIBIOS_DEVICE_NOT_FOUND; |
| 84 | 84 | ||
| 85 | switch (size) { | 85 | switch (size) { |
| 86 | case 1: *val = inb(GAPSPCI_BBA_CONFIG+where); break; | 86 | case 1: *val = ctrl_inb(GAPSPCI_BBA_CONFIG+where); break; |
| 87 | case 2: *val = inw(GAPSPCI_BBA_CONFIG+where); break; | 87 | case 2: *val = ctrl_inw(GAPSPCI_BBA_CONFIG+where); break; |
| 88 | case 4: *val = inl(GAPSPCI_BBA_CONFIG+where); break; | 88 | case 4: *val = ctrl_inl(GAPSPCI_BBA_CONFIG+where); break; |
| 89 | } | 89 | } |
| 90 | 90 | ||
| 91 | return PCIBIOS_SUCCESSFUL; | 91 | return PCIBIOS_SUCCESSFUL; |
| @@ -97,9 +97,9 @@ static int gapspci_write(struct pci_bus *bus, unsigned int devfn, int where, int | |||
| 97 | return PCIBIOS_DEVICE_NOT_FOUND; | 97 | return PCIBIOS_DEVICE_NOT_FOUND; |
| 98 | 98 | ||
| 99 | switch (size) { | 99 | switch (size) { |
| 100 | case 1: outb(( u8)val, GAPSPCI_BBA_CONFIG+where); break; | 100 | case 1: ctrl_outb(( u8)val, GAPSPCI_BBA_CONFIG+where); break; |
| 101 | case 2: outw((u16)val, GAPSPCI_BBA_CONFIG+where); break; | 101 | case 2: ctrl_outw((u16)val, GAPSPCI_BBA_CONFIG+where); break; |
| 102 | case 4: outl((u32)val, GAPSPCI_BBA_CONFIG+where); break; | 102 | case 4: ctrl_outl((u32)val, GAPSPCI_BBA_CONFIG+where); break; |
| 103 | } | 103 | } |
| 104 | 104 | ||
| 105 | return PCIBIOS_SUCCESSFUL; | 105 | return PCIBIOS_SUCCESSFUL; |
| @@ -127,36 +127,36 @@ int __init gapspci_init(void) | |||
| 127 | */ | 127 | */ |
| 128 | 128 | ||
| 129 | for (i=0; i<16; i++) | 129 | for (i=0; i<16; i++) |
| 130 | idbuf[i] = inb(GAPSPCI_REGS+i); | 130 | idbuf[i] = ctrl_inb(GAPSPCI_REGS+i); |
| 131 | 131 | ||
| 132 | if (strncmp(idbuf, "GAPSPCI_BRIDGE_2", 16)) | 132 | if (strncmp(idbuf, "GAPSPCI_BRIDGE_2", 16)) |
| 133 | return -ENODEV; | 133 | return -ENODEV; |
| 134 | 134 | ||
| 135 | outl(0x5a14a501, GAPSPCI_REGS+0x18); | 135 | ctrl_outl(0x5a14a501, GAPSPCI_REGS+0x18); |
| 136 | 136 | ||
| 137 | for (i=0; i<1000000; i++) | 137 | for (i=0; i<1000000; i++) |
| 138 | ; | 138 | ; |
| 139 | 139 | ||
| 140 | if (inl(GAPSPCI_REGS+0x18) != 1) | 140 | if (ctrl_inl(GAPSPCI_REGS+0x18) != 1) |
| 141 | return -EINVAL; | 141 | return -EINVAL; |
| 142 | 142 | ||
| 143 | outl(0x01000000, GAPSPCI_REGS+0x20); | 143 | ctrl_outl(0x01000000, GAPSPCI_REGS+0x20); |
| 144 | outl(0x01000000, GAPSPCI_REGS+0x24); | 144 | ctrl_outl(0x01000000, GAPSPCI_REGS+0x24); |
| 145 | 145 | ||
| 146 | outl(GAPSPCI_DMA_BASE, GAPSPCI_REGS+0x28); | 146 | ctrl_outl(GAPSPCI_DMA_BASE, GAPSPCI_REGS+0x28); |
| 147 | outl(GAPSPCI_DMA_BASE+GAPSPCI_DMA_SIZE, GAPSPCI_REGS+0x2c); | 147 | ctrl_outl(GAPSPCI_DMA_BASE+GAPSPCI_DMA_SIZE, GAPSPCI_REGS+0x2c); |
| 148 | 148 | ||
| 149 | outl(1, GAPSPCI_REGS+0x14); | 149 | ctrl_outl(1, GAPSPCI_REGS+0x14); |
| 150 | outl(1, GAPSPCI_REGS+0x34); | 150 | ctrl_outl(1, GAPSPCI_REGS+0x34); |
| 151 | 151 | ||
| 152 | /* Setting Broadband Adapter */ | 152 | /* Setting Broadband Adapter */ |
| 153 | outw(0xf900, GAPSPCI_BBA_CONFIG+0x06); | 153 | ctrl_outw(0xf900, GAPSPCI_BBA_CONFIG+0x06); |
| 154 | outl(0x00000000, GAPSPCI_BBA_CONFIG+0x30); | 154 | ctrl_outl(0x00000000, GAPSPCI_BBA_CONFIG+0x30); |
| 155 | outb(0x00, GAPSPCI_BBA_CONFIG+0x3c); | 155 | ctrl_outb(0x00, GAPSPCI_BBA_CONFIG+0x3c); |
| 156 | outb(0xf0, GAPSPCI_BBA_CONFIG+0x0d); | 156 | ctrl_outb(0xf0, GAPSPCI_BBA_CONFIG+0x0d); |
| 157 | outw(0x0006, GAPSPCI_BBA_CONFIG+0x04); | 157 | ctrl_outw(0x0006, GAPSPCI_BBA_CONFIG+0x04); |
| 158 | outl(0x00002001, GAPSPCI_BBA_CONFIG+0x10); | 158 | ctrl_outl(0x00002001, GAPSPCI_BBA_CONFIG+0x10); |
| 159 | outl(0x01000000, GAPSPCI_BBA_CONFIG+0x14); | 159 | ctrl_outl(0x01000000, GAPSPCI_BBA_CONFIG+0x14); |
| 160 | 160 | ||
| 161 | return 0; | 161 | return 0; |
| 162 | } | 162 | } |
diff --git a/arch/sh/drivers/pci/ops-rts7751r2d.c b/arch/sh/drivers/pci/ops-rts7751r2d.c index ec8430c8d2d1..b3fa3e2ef184 100644 --- a/arch/sh/drivers/pci/ops-rts7751r2d.c +++ b/arch/sh/drivers/pci/ops-rts7751r2d.c | |||
| @@ -33,7 +33,7 @@ int __init pcibios_map_platform_irq(struct pci_dev *pdev, u8 slot, u8 pin) | |||
| 33 | static struct resource sh7751_io_resource = { | 33 | static struct resource sh7751_io_resource = { |
| 34 | .name = "SH7751_IO", | 34 | .name = "SH7751_IO", |
| 35 | .start = 0x4000, | 35 | .start = 0x4000, |
| 36 | .end = 0x4000 + SH7751_PCI_IO_SIZE - 1, | 36 | .end = SH7751_PCI_IO_SIZE - 1, |
| 37 | .flags = IORESOURCE_IO | 37 | .flags = IORESOURCE_IO |
| 38 | }; | 38 | }; |
| 39 | 39 | ||
| @@ -68,6 +68,7 @@ static struct sh4_pci_address_map sh7751_pci_map = { | |||
| 68 | 68 | ||
| 69 | int __init pcibios_init_platform(void) | 69 | int __init pcibios_init_platform(void) |
| 70 | { | 70 | { |
| 71 | __set_io_port_base(SH7751_PCI_IO_BASE); | ||
| 71 | return sh7751_pcic_init(&sh7751_pci_map); | 72 | return sh7751_pcic_init(&sh7751_pci_map); |
| 72 | } | 73 | } |
| 73 | 74 | ||
diff --git a/arch/sh/drivers/pci/pci-sh4.h b/arch/sh/drivers/pci/pci-sh4.h index 4925c79ea959..07e29506080f 100644 --- a/arch/sh/drivers/pci/pci-sh4.h +++ b/arch/sh/drivers/pci/pci-sh4.h | |||
| @@ -172,11 +172,11 @@ struct sh4_pci_address_map { | |||
| 172 | 172 | ||
| 173 | static inline void pci_write_reg(unsigned long val, unsigned long reg) | 173 | static inline void pci_write_reg(unsigned long val, unsigned long reg) |
| 174 | { | 174 | { |
| 175 | outl(val, PCI_REG(reg)); | 175 | ctrl_outl(val, PCI_REG(reg)); |
| 176 | } | 176 | } |
| 177 | 177 | ||
| 178 | static inline unsigned long pci_read_reg(unsigned long reg) | 178 | static inline unsigned long pci_read_reg(unsigned long reg) |
| 179 | { | 179 | { |
| 180 | return inl(PCI_REG(reg)); | 180 | return ctrl_inl(PCI_REG(reg)); |
| 181 | } | 181 | } |
| 182 | #endif /* __PCI_SH4_H */ | 182 | #endif /* __PCI_SH4_H */ |
diff --git a/arch/sh/drivers/pci/pci-sh7751.c b/arch/sh/drivers/pci/pci-sh7751.c index 1aca7fe5783b..3065eb184f01 100644 --- a/arch/sh/drivers/pci/pci-sh7751.c +++ b/arch/sh/drivers/pci/pci-sh7751.c | |||
| @@ -58,7 +58,7 @@ static int __init __area_sdram_check(unsigned int area) | |||
| 58 | { | 58 | { |
| 59 | u32 word; | 59 | u32 word; |
| 60 | 60 | ||
| 61 | word = inl(SH7751_BCR1); | 61 | word = ctrl_inl(SH7751_BCR1); |
| 62 | /* check BCR for SDRAM in area */ | 62 | /* check BCR for SDRAM in area */ |
| 63 | if (((word >> area) & 1) == 0) { | 63 | if (((word >> area) & 1) == 0) { |
| 64 | printk("PCI: Area %d is not configured for SDRAM. BCR1=0x%x\n", | 64 | printk("PCI: Area %d is not configured for SDRAM. BCR1=0x%x\n", |
| @@ -67,7 +67,7 @@ static int __init __area_sdram_check(unsigned int area) | |||
| 67 | } | 67 | } |
| 68 | pci_write_reg(word, SH4_PCIBCR1); | 68 | pci_write_reg(word, SH4_PCIBCR1); |
| 69 | 69 | ||
| 70 | word = (u16)inw(SH7751_BCR2); | 70 | word = (u16)ctrl_inw(SH7751_BCR2); |
| 71 | /* check BCR2 for 32bit SDRAM interface*/ | 71 | /* check BCR2 for 32bit SDRAM interface*/ |
| 72 | if (((word >> (area << 1)) & 0x3) != 0x3) { | 72 | if (((word >> (area << 1)) & 0x3) != 0x3) { |
| 73 | printk("PCI: Area %d is not 32 bit SDRAM. BCR2=0x%x\n", | 73 | printk("PCI: Area %d is not 32 bit SDRAM. BCR2=0x%x\n", |
| @@ -85,9 +85,9 @@ int __init sh7751_pcic_init(struct sh4_pci_address_map *map) | |||
| 85 | u32 word; | 85 | u32 word; |
| 86 | 86 | ||
| 87 | /* Set the BCR's to enable PCI access */ | 87 | /* Set the BCR's to enable PCI access */ |
| 88 | reg = inl(SH7751_BCR1); | 88 | reg = ctrl_inl(SH7751_BCR1); |
| 89 | reg |= 0x80000; | 89 | reg |= 0x80000; |
| 90 | outl(reg, SH7751_BCR1); | 90 | ctrl_outl(reg, SH7751_BCR1); |
| 91 | 91 | ||
| 92 | /* Turn the clocks back on (not done in reset)*/ | 92 | /* Turn the clocks back on (not done in reset)*/ |
| 93 | pci_write_reg(0, SH4_PCICLKR); | 93 | pci_write_reg(0, SH4_PCICLKR); |
| @@ -179,13 +179,13 @@ int __init sh7751_pcic_init(struct sh4_pci_address_map *map) | |||
| 179 | return 0; | 179 | return 0; |
| 180 | 180 | ||
| 181 | /* configure the wait control registers */ | 181 | /* configure the wait control registers */ |
| 182 | word = inl(SH7751_WCR1); | 182 | word = ctrl_inl(SH7751_WCR1); |
| 183 | pci_write_reg(word, SH4_PCIWCR1); | 183 | pci_write_reg(word, SH4_PCIWCR1); |
| 184 | word = inl(SH7751_WCR2); | 184 | word = ctrl_inl(SH7751_WCR2); |
| 185 | pci_write_reg(word, SH4_PCIWCR2); | 185 | pci_write_reg(word, SH4_PCIWCR2); |
| 186 | word = inl(SH7751_WCR3); | 186 | word = ctrl_inl(SH7751_WCR3); |
| 187 | pci_write_reg(word, SH4_PCIWCR3); | 187 | pci_write_reg(word, SH4_PCIWCR3); |
| 188 | word = inl(SH7751_MCR); | 188 | word = ctrl_inl(SH7751_MCR); |
| 189 | pci_write_reg(word, SH4_PCIMCR); | 189 | pci_write_reg(word, SH4_PCIMCR); |
| 190 | 190 | ||
| 191 | /* NOTE: I'm ignoring the PCI error IRQs for now.. | 191 | /* NOTE: I'm ignoring the PCI error IRQs for now.. |
diff --git a/arch/sh/drivers/pci/pci-sh7780.c b/arch/sh/drivers/pci/pci-sh7780.c index 7d797f4de5e7..b2a2bfa3c1bd 100644 --- a/arch/sh/drivers/pci/pci-sh7780.c +++ b/arch/sh/drivers/pci/pci-sh7780.c | |||
| @@ -52,7 +52,7 @@ static int __init sh7780_pci_init(void) | |||
| 52 | 52 | ||
| 53 | pr_debug("PCI: Starting intialization.\n"); | 53 | pr_debug("PCI: Starting intialization.\n"); |
| 54 | 54 | ||
| 55 | outl(0x00000001, SH7780_PCI_VCR2); /* Enable PCIC */ | 55 | ctrl_outl(0x00000001, SH7780_PCI_VCR2); /* Enable PCIC */ |
| 56 | 56 | ||
| 57 | /* check for SH7780/SH7780R hardware */ | 57 | /* check for SH7780/SH7780R hardware */ |
| 58 | id = pci_read_reg(SH7780_PCIVID); | 58 | id = pci_read_reg(SH7780_PCIVID); |
diff --git a/arch/sh/kernel/Makefile_32 b/arch/sh/kernel/Makefile_32 index c89289831053..62bf373266f7 100644 --- a/arch/sh/kernel/Makefile_32 +++ b/arch/sh/kernel/Makefile_32 | |||
| @@ -22,5 +22,6 @@ obj-$(CONFIG_CRASH_DUMP) += crash_dump.o | |||
| 22 | obj-$(CONFIG_PM) += pm.o | 22 | obj-$(CONFIG_PM) += pm.o |
| 23 | obj-$(CONFIG_STACKTRACE) += stacktrace.o | 23 | obj-$(CONFIG_STACKTRACE) += stacktrace.o |
| 24 | obj-$(CONFIG_BINFMT_ELF) += dump_task.o | 24 | obj-$(CONFIG_BINFMT_ELF) += dump_task.o |
| 25 | obj-$(CONFIG_IO_TRAPPED) += io_trapped.o | ||
| 25 | 26 | ||
| 26 | EXTRA_CFLAGS += -Werror | 27 | EXTRA_CFLAGS += -Werror |
diff --git a/arch/sh/kernel/Makefile_64 b/arch/sh/kernel/Makefile_64 index 1ef21cc087f3..e01283d49cbf 100644 --- a/arch/sh/kernel/Makefile_64 +++ b/arch/sh/kernel/Makefile_64 | |||
| @@ -18,5 +18,6 @@ obj-$(CONFIG_CRASH_DUMP) += crash_dump.o | |||
| 18 | obj-$(CONFIG_PM) += pm.o | 18 | obj-$(CONFIG_PM) += pm.o |
| 19 | obj-$(CONFIG_STACKTRACE) += stacktrace.o | 19 | obj-$(CONFIG_STACKTRACE) += stacktrace.o |
| 20 | obj-$(CONFIG_BINFMT_ELF) += dump_task.o | 20 | obj-$(CONFIG_BINFMT_ELF) += dump_task.o |
| 21 | obj-$(CONFIG_IO_TRAPPED) += io_trapped.o | ||
| 21 | 22 | ||
| 22 | EXTRA_CFLAGS += -Werror | 23 | EXTRA_CFLAGS += -Werror |
diff --git a/arch/sh/kernel/cpu/irq/Makefile b/arch/sh/kernel/cpu/irq/Makefile index cc1836e47a5d..462a8f6dfee2 100644 --- a/arch/sh/kernel/cpu/irq/Makefile +++ b/arch/sh/kernel/cpu/irq/Makefile | |||
| @@ -6,4 +6,3 @@ obj-y += intc.o | |||
| 6 | obj-$(CONFIG_SUPERH32) += imask.o | 6 | obj-$(CONFIG_SUPERH32) += imask.o |
| 7 | obj-$(CONFIG_CPU_SH5) += intc-sh5.o | 7 | obj-$(CONFIG_CPU_SH5) += intc-sh5.o |
| 8 | obj-$(CONFIG_CPU_HAS_IPR_IRQ) += ipr.o | 8 | obj-$(CONFIG_CPU_HAS_IPR_IRQ) += ipr.o |
| 9 | obj-$(CONFIG_CPU_HAS_MASKREG_IRQ) += maskreg.o | ||
diff --git a/arch/sh/kernel/cpu/irq/intc-sh5.c b/arch/sh/kernel/cpu/irq/intc-sh5.c index 43ee7a9a4f0b..d6e0e2bdaad5 100644 --- a/arch/sh/kernel/cpu/irq/intc-sh5.c +++ b/arch/sh/kernel/cpu/irq/intc-sh5.c | |||
| @@ -75,21 +75,6 @@ int intc_evt_to_irq[(0xE20/0x20)+1] = { | |||
| 75 | -1, -1 /* 0xE00 - 0xE20 */ | 75 | -1, -1 /* 0xE00 - 0xE20 */ |
| 76 | }; | 76 | }; |
| 77 | 77 | ||
| 78 | /* | ||
| 79 | * Opposite mapper. | ||
| 80 | */ | ||
| 81 | static int IRQ_to_vectorN[NR_INTC_IRQS] = { | ||
| 82 | 0x12, 0x15, 0x18, 0x1B, 0x40, 0x41, 0x42, 0x43, /* 0- 7 */ | ||
| 83 | -1, -1, -1, -1, 0x50, 0x51, 0x52, 0x53, /* 8-15 */ | ||
| 84 | 0x54, 0x55, 0x32, 0x33, 0x34, 0x35, 0x36, -1, /* 16-23 */ | ||
| 85 | -1, -1, -1, -1, -1, -1, -1, -1, /* 24-31 */ | ||
| 86 | 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x38, /* 32-39 */ | ||
| 87 | 0x39, 0x3A, 0x3B, -1, -1, -1, -1, -1, /* 40-47 */ | ||
| 88 | -1, -1, -1, -1, -1, -1, -1, -1, /* 48-55 */ | ||
| 89 | -1, -1, -1, -1, -1, -1, -1, 0x2B, /* 56-63 */ | ||
| 90 | |||
| 91 | }; | ||
| 92 | |||
| 93 | static unsigned long intc_virt; | 78 | static unsigned long intc_virt; |
| 94 | 79 | ||
| 95 | static unsigned int startup_intc_irq(unsigned int irq); | 80 | static unsigned int startup_intc_irq(unsigned int irq); |
| @@ -176,6 +161,18 @@ void make_intc_irq(unsigned int irq) | |||
| 176 | } | 161 | } |
| 177 | 162 | ||
| 178 | #if defined(CONFIG_PROC_FS) && defined(CONFIG_SYSCTL) | 163 | #if defined(CONFIG_PROC_FS) && defined(CONFIG_SYSCTL) |
| 164 | static int IRQ_to_vectorN[NR_INTC_IRQS] = { | ||
| 165 | 0x12, 0x15, 0x18, 0x1B, 0x40, 0x41, 0x42, 0x43, /* 0- 7 */ | ||
| 166 | -1, -1, -1, -1, 0x50, 0x51, 0x52, 0x53, /* 8-15 */ | ||
| 167 | 0x54, 0x55, 0x32, 0x33, 0x34, 0x35, 0x36, -1, /* 16-23 */ | ||
| 168 | -1, -1, -1, -1, -1, -1, -1, -1, /* 24-31 */ | ||
| 169 | 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x38, /* 32-39 */ | ||
| 170 | 0x39, 0x3A, 0x3B, -1, -1, -1, -1, -1, /* 40-47 */ | ||
| 171 | -1, -1, -1, -1, -1, -1, -1, -1, /* 48-55 */ | ||
| 172 | -1, -1, -1, -1, -1, -1, -1, 0x2B, /* 56-63 */ | ||
| 173 | |||
| 174 | }; | ||
| 175 | |||
| 179 | int intc_irq_describe(char* p, int irq) | 176 | int intc_irq_describe(char* p, int irq) |
| 180 | { | 177 | { |
| 181 | if (irq < NR_INTC_IRQS) | 178 | if (irq < NR_INTC_IRQS) |
diff --git a/arch/sh/kernel/cpu/irq/maskreg.c b/arch/sh/kernel/cpu/irq/maskreg.c deleted file mode 100644 index 978992e367a5..000000000000 --- a/arch/sh/kernel/cpu/irq/maskreg.c +++ /dev/null | |||
| @@ -1,93 +0,0 @@ | |||
| 1 | /* | ||
| 2 | * Interrupt handling for Simple external interrupt mask register | ||
| 3 | * | ||
| 4 | * Copyright (C) 2001 A&D Co., Ltd. <http://www.aandd.co.jp> | ||
| 5 | * | ||
| 6 | * This is for the machine which have single 16 bit register | ||
| 7 | * for masking external IRQ individually. | ||
| 8 | * Each bit of the register is for masking each interrupt. | ||
| 9 | * | ||
| 10 | * This file may be copied or modified under the terms of the GNU | ||
| 11 | * General Public License. See linux/COPYING for more information. | ||
| 12 | */ | ||
| 13 | #include <linux/kernel.h> | ||
| 14 | #include <linux/init.h> | ||
| 15 | #include <linux/irq.h> | ||
| 16 | #include <asm/system.h> | ||
| 17 | #include <asm/io.h> | ||
| 18 | |||
| 19 | /* address of external interrupt mask register */ | ||
| 20 | unsigned long irq_mask_register; | ||
| 21 | |||
| 22 | /* forward declaration */ | ||
| 23 | static unsigned int startup_maskreg_irq(unsigned int irq); | ||
| 24 | static void shutdown_maskreg_irq(unsigned int irq); | ||
| 25 | static void enable_maskreg_irq(unsigned int irq); | ||
| 26 | static void disable_maskreg_irq(unsigned int irq); | ||
| 27 | static void mask_and_ack_maskreg(unsigned int); | ||
| 28 | static void end_maskreg_irq(unsigned int irq); | ||
| 29 | |||
| 30 | /* hw_interrupt_type */ | ||
| 31 | static struct hw_interrupt_type maskreg_irq_type = { | ||
| 32 | .typename = "Mask Register", | ||
| 33 | .startup = startup_maskreg_irq, | ||
| 34 | .shutdown = shutdown_maskreg_irq, | ||
| 35 | .enable = enable_maskreg_irq, | ||
| 36 | .disable = disable_maskreg_irq, | ||
| 37 | .ack = mask_and_ack_maskreg, | ||
| 38 | .end = end_maskreg_irq | ||
| 39 | }; | ||
| 40 | |||
| 41 | /* actual implementation */ | ||
| 42 | static unsigned int startup_maskreg_irq(unsigned int irq) | ||
| 43 | { | ||
| 44 | enable_maskreg_irq(irq); | ||
| 45 | return 0; /* never anything pending */ | ||
| 46 | } | ||
| 47 | |||
| 48 | static void shutdown_maskreg_irq(unsigned int irq) | ||
| 49 | { | ||
| 50 | disable_maskreg_irq(irq); | ||
| 51 | } | ||
| 52 | |||
| 53 | static void disable_maskreg_irq(unsigned int irq) | ||
| 54 | { | ||
| 55 | unsigned short val, mask = 0x01 << irq; | ||
| 56 | |||
| 57 | BUG_ON(!irq_mask_register); | ||
| 58 | |||
| 59 | /* Set "irq"th bit */ | ||
| 60 | val = ctrl_inw(irq_mask_register); | ||
| 61 | val |= mask; | ||
| 62 | ctrl_outw(val, irq_mask_register); | ||
| 63 | } | ||
| 64 | |||
| 65 | static void enable_maskreg_irq(unsigned int irq) | ||
| 66 | { | ||
| 67 | unsigned short val, mask = ~(0x01 << irq); | ||
| 68 | |||
| 69 | BUG_ON(!irq_mask_register); | ||
| 70 | |||
| 71 | /* Clear "irq"th bit */ | ||
| 72 | val = ctrl_inw(irq_mask_register); | ||
| 73 | val &= mask; | ||
| 74 | ctrl_outw(val, irq_mask_register); | ||
| 75 | } | ||
| 76 | |||
| 77 | static void mask_and_ack_maskreg(unsigned int irq) | ||
| 78 | { | ||
| 79 | disable_maskreg_irq(irq); | ||
| 80 | } | ||
| 81 | |||
| 82 | static void end_maskreg_irq(unsigned int irq) | ||
| 83 | { | ||
| 84 | if (!(irq_desc[irq].status & (IRQ_DISABLED|IRQ_INPROGRESS))) | ||
| 85 | enable_maskreg_irq(irq); | ||
| 86 | } | ||
| 87 | |||
| 88 | void make_maskreg_irq(unsigned int irq) | ||
| 89 | { | ||
| 90 | disable_irq_nosync(irq); | ||
| 91 | irq_desc[irq].handler = &maskreg_irq_type; | ||
| 92 | disable_maskreg_irq(irq); | ||
| 93 | } | ||
diff --git a/arch/sh/kernel/cpu/sh4/probe.c b/arch/sh/kernel/cpu/sh4/probe.c index f2b9238cda04..9e89984c4f1d 100644 --- a/arch/sh/kernel/cpu/sh4/probe.c +++ b/arch/sh/kernel/cpu/sh4/probe.c | |||
| @@ -126,12 +126,18 @@ int __init detect_cpu_and_cache_system(void) | |||
| 126 | CPU_HAS_LLSC; | 126 | CPU_HAS_LLSC; |
| 127 | break; | 127 | break; |
| 128 | case 0x3008: | 128 | case 0x3008: |
| 129 | if (prr == 0xa0) { | 129 | if (prr == 0xa0 || prr == 0xa1) { |
| 130 | boot_cpu_data.type = CPU_SH7722; | 130 | boot_cpu_data.type = CPU_SH7722; |
| 131 | boot_cpu_data.icache.ways = 4; | 131 | boot_cpu_data.icache.ways = 4; |
| 132 | boot_cpu_data.dcache.ways = 4; | 132 | boot_cpu_data.dcache.ways = 4; |
| 133 | boot_cpu_data.flags |= CPU_HAS_LLSC; | 133 | boot_cpu_data.flags |= CPU_HAS_LLSC; |
| 134 | } | 134 | } |
| 135 | else if (prr == 0x70) { | ||
| 136 | boot_cpu_data.type = CPU_SH7366; | ||
| 137 | boot_cpu_data.icache.ways = 4; | ||
| 138 | boot_cpu_data.dcache.ways = 4; | ||
| 139 | boot_cpu_data.flags |= CPU_HAS_LLSC; | ||
| 140 | } | ||
| 135 | break; | 141 | break; |
| 136 | case 0x4000: /* 1st cut */ | 142 | case 0x4000: /* 1st cut */ |
| 137 | case 0x4001: /* 2nd cut */ | 143 | case 0x4001: /* 2nd cut */ |
diff --git a/arch/sh/kernel/cpu/sh4a/Makefile b/arch/sh/kernel/cpu/sh4a/Makefile index 08ac6387bf17..5d890ac8e793 100644 --- a/arch/sh/kernel/cpu/sh4a/Makefile +++ b/arch/sh/kernel/cpu/sh4a/Makefile | |||
| @@ -9,6 +9,7 @@ obj-$(CONFIG_CPU_SUBTYPE_SH7780) += setup-sh7780.o | |||
| 9 | obj-$(CONFIG_CPU_SUBTYPE_SH7785) += setup-sh7785.o | 9 | obj-$(CONFIG_CPU_SUBTYPE_SH7785) += setup-sh7785.o |
| 10 | obj-$(CONFIG_CPU_SUBTYPE_SH7343) += setup-sh7343.o | 10 | obj-$(CONFIG_CPU_SUBTYPE_SH7343) += setup-sh7343.o |
| 11 | obj-$(CONFIG_CPU_SUBTYPE_SH7722) += setup-sh7722.o | 11 | obj-$(CONFIG_CPU_SUBTYPE_SH7722) += setup-sh7722.o |
| 12 | obj-$(CONFIG_CPU_SUBTYPE_SH7366) += setup-sh7366.o | ||
| 12 | obj-$(CONFIG_CPU_SUBTYPE_SHX3) += setup-shx3.o | 13 | obj-$(CONFIG_CPU_SUBTYPE_SHX3) += setup-shx3.o |
| 13 | 14 | ||
| 14 | # SMP setup | 15 | # SMP setup |
| @@ -21,6 +22,7 @@ clock-$(CONFIG_CPU_SUBTYPE_SH7780) := clock-sh7780.o | |||
| 21 | clock-$(CONFIG_CPU_SUBTYPE_SH7785) := clock-sh7785.o | 22 | clock-$(CONFIG_CPU_SUBTYPE_SH7785) := clock-sh7785.o |
| 22 | clock-$(CONFIG_CPU_SUBTYPE_SH7343) := clock-sh7343.o | 23 | clock-$(CONFIG_CPU_SUBTYPE_SH7343) := clock-sh7343.o |
| 23 | clock-$(CONFIG_CPU_SUBTYPE_SH7722) := clock-sh7722.o | 24 | clock-$(CONFIG_CPU_SUBTYPE_SH7722) := clock-sh7722.o |
| 25 | clock-$(CONFIG_CPU_SUBTYPE_SH7366) := clock-sh7722.o | ||
| 24 | clock-$(CONFIG_CPU_SUBTYPE_SHX3) := clock-shx3.o | 26 | clock-$(CONFIG_CPU_SUBTYPE_SHX3) := clock-shx3.o |
| 25 | 27 | ||
| 26 | obj-y += $(clock-y) | 28 | obj-y += $(clock-y) |
diff --git a/arch/sh/kernel/cpu/sh4a/clock-sh7722.c b/arch/sh/kernel/cpu/sh4a/clock-sh7722.c index a0fd8bb21f7c..299138ebe160 100644 --- a/arch/sh/kernel/cpu/sh4a/clock-sh7722.c +++ b/arch/sh/kernel/cpu/sh4a/clock-sh7722.c | |||
| @@ -1,7 +1,7 @@ | |||
| 1 | /* | 1 | /* |
| 2 | * arch/sh/kernel/cpu/sh4a/clock-sh7722.c | 2 | * arch/sh/kernel/cpu/sh4a/clock-sh7722.c |
| 3 | * | 3 | * |
| 4 | * SH7722 support for the clock framework | 4 | * SH7722 & SH7366 support for the clock framework |
| 5 | * | 5 | * |
| 6 | * Copyright (c) 2006-2007 Nomad Global Solutions Inc | 6 | * Copyright (c) 2006-2007 Nomad Global Solutions Inc |
| 7 | * Based on code for sh7343 by Paul Mundt | 7 | * Based on code for sh7343 by Paul Mundt |
| @@ -417,15 +417,19 @@ static int sh7722_siu_which(struct clk *clk) | |||
| 417 | return 0; | 417 | return 0; |
| 418 | if (!strcmp(clk->name, "siu_b_clk")) | 418 | if (!strcmp(clk->name, "siu_b_clk")) |
| 419 | return 1; | 419 | return 1; |
| 420 | #if defined(CONFIG_CPU_SUBTYPE_SH7722) | ||
| 420 | if (!strcmp(clk->name, "irda_clk")) | 421 | if (!strcmp(clk->name, "irda_clk")) |
| 421 | return 2; | 422 | return 2; |
| 423 | #endif | ||
| 422 | return -EINVAL; | 424 | return -EINVAL; |
| 423 | } | 425 | } |
| 424 | 426 | ||
| 425 | static unsigned long sh7722_siu_regs[] = { | 427 | static unsigned long sh7722_siu_regs[] = { |
| 426 | [0] = SCLKACR, | 428 | [0] = SCLKACR, |
| 427 | [1] = SCLKBCR, | 429 | [1] = SCLKBCR, |
| 430 | #if defined(CONFIG_CPU_SUBTYPE_SH7722) | ||
| 428 | [2] = IrDACLKCR, | 431 | [2] = IrDACLKCR, |
| 432 | #endif | ||
| 429 | }; | 433 | }; |
| 430 | 434 | ||
| 431 | static int sh7722_siu_start_stop(struct clk *clk, int enable) | 435 | static int sh7722_siu_start_stop(struct clk *clk, int enable) |
| @@ -571,10 +575,12 @@ static struct clk sh7722_siu_b_clock = { | |||
| 571 | .ops = &sh7722_siu_clk_ops, | 575 | .ops = &sh7722_siu_clk_ops, |
| 572 | }; | 576 | }; |
| 573 | 577 | ||
| 578 | #if defined(CONFIG_CPU_SUBTYPE_SH7722) | ||
| 574 | static struct clk sh7722_irda_clock = { | 579 | static struct clk sh7722_irda_clock = { |
| 575 | .name = "irda_clk", | 580 | .name = "irda_clk", |
| 576 | .ops = &sh7722_siu_clk_ops, | 581 | .ops = &sh7722_siu_clk_ops, |
| 577 | }; | 582 | }; |
| 583 | #endif | ||
| 578 | 584 | ||
| 579 | static struct clk sh7722_video_clock = { | 585 | static struct clk sh7722_video_clock = { |
| 580 | .name = "video_clk", | 586 | .name = "video_clk", |
| @@ -588,7 +594,9 @@ static struct clk *sh7722_clocks[] = { | |||
| 588 | &sh7722_sdram_clock, | 594 | &sh7722_sdram_clock, |
| 589 | &sh7722_siu_a_clock, | 595 | &sh7722_siu_a_clock, |
| 590 | &sh7722_siu_b_clock, | 596 | &sh7722_siu_b_clock, |
| 597 | #if defined(CONFIG_CPU_SUBTYPE_SH7722) | ||
| 591 | &sh7722_irda_clock, | 598 | &sh7722_irda_clock, |
| 599 | #endif | ||
| 592 | &sh7722_video_clock, | 600 | &sh7722_video_clock, |
| 593 | }; | 601 | }; |
| 594 | 602 | ||
diff --git a/arch/sh/kernel/cpu/sh4a/setup-sh7366.c b/arch/sh/kernel/cpu/sh4a/setup-sh7366.c new file mode 100644 index 000000000000..967e8b69a2f8 --- /dev/null +++ b/arch/sh/kernel/cpu/sh4a/setup-sh7366.c | |||
| @@ -0,0 +1,177 @@ | |||
| 1 | /* | ||
| 2 | * SH7366 Setup | ||
| 3 | * | ||
| 4 | * Copyright (C) 2008 Renesas Solutions | ||
| 5 | * | ||
| 6 | * Based on linux/arch/sh/kernel/cpu/sh4a/setup-sh7722.c | ||
| 7 | * | ||
| 8 | * This file is subject to the terms and conditions of the GNU General Public | ||
| 9 | * License. See the file "COPYING" in the main directory of this archive | ||
| 10 | * for more details. | ||
| 11 | */ | ||
| 12 | #include <linux/platform_device.h> | ||
| 13 | #include <linux/init.h> | ||
| 14 | #include <linux/serial.h> | ||
| 15 | #include <asm/sci.h> | ||
| 16 | |||
| 17 | static struct plat_sci_port sci_platform_data[] = { | ||
| 18 | { | ||
| 19 | .mapbase = 0xffe00000, | ||
| 20 | .flags = UPF_BOOT_AUTOCONF, | ||
| 21 | .type = PORT_SCIF, | ||
| 22 | .irqs = { 80, 80, 80, 80 }, | ||
| 23 | }, { | ||
| 24 | .flags = 0, | ||
| 25 | } | ||
| 26 | }; | ||
| 27 | |||
| 28 | static struct platform_device sci_device = { | ||
| 29 | .name = "sh-sci", | ||
| 30 | .id = -1, | ||
| 31 | .dev = { | ||
| 32 | .platform_data = sci_platform_data, | ||
| 33 | }, | ||
| 34 | }; | ||
| 35 | |||
| 36 | static struct platform_device *sh7366_devices[] __initdata = { | ||
| 37 | &sci_device, | ||
| 38 | }; | ||
| 39 | |||
| 40 | static int __init sh7366_devices_setup(void) | ||
| 41 | { | ||
| 42 | return platform_add_devices(sh7366_devices, | ||
| 43 | ARRAY_SIZE(sh7366_devices)); | ||
| 44 | } | ||
| 45 | __initcall(sh7366_devices_setup); | ||
| 46 | |||
| 47 | enum { | ||
| 48 | UNUSED=0, | ||
| 49 | |||
| 50 | /* interrupt sources */ | ||
| 51 | IRQ0, IRQ1, IRQ2, IRQ3, IRQ4, IRQ5, IRQ6, IRQ7, | ||
| 52 | ICB, | ||
| 53 | DMAC0, DMAC1, DMAC2, DMAC3, | ||
| 54 | VIO_CEUI, VIO_BEUI, VIO_VEUI, VOU, | ||
| 55 | MFI, VPU, USB, | ||
| 56 | MMC_MMC1I, MMC_MMC2I, MMC_MMC3I, | ||
| 57 | DMAC4, DMAC5, DMAC_DADERR, | ||
| 58 | SCIF, SCIFA1, SCIFA2, | ||
| 59 | DENC, MSIOF, | ||
| 60 | FLCTL_FLSTEI, FLCTL_FLENDI, FLCTL_FLTREQ0I, FLCTL_FLTREQ1I, | ||
| 61 | I2C_ALI, I2C_TACKI, I2C_WAITI, I2C_DTEI, | ||
| 62 | SDHI0, SDHI1, SDHI2, SDHI3, | ||
| 63 | CMT, TSIF, SIU, | ||
| 64 | TMU0, TMU1, TMU2, | ||
| 65 | VEU2, LCDC, | ||
| 66 | |||
| 67 | /* interrupt groups */ | ||
| 68 | |||
| 69 | DMAC0123, VIOVOU, MMC, DMAC45, FLCTL, I2C, SDHI, | ||
| 70 | }; | ||
| 71 | |||
| 72 | static struct intc_vect vectors[] __initdata = { | ||
| 73 | INTC_VECT(IRQ0, 0x600), INTC_VECT(IRQ1, 0x620), | ||
| 74 | INTC_VECT(IRQ2, 0x640), INTC_VECT(IRQ3, 0x660), | ||
| 75 | INTC_VECT(IRQ4, 0x680), INTC_VECT(IRQ5, 0x6a0), | ||
| 76 | INTC_VECT(IRQ6, 0x6c0), INTC_VECT(IRQ7, 0x6e0), | ||
| 77 | INTC_VECT(ICB, 0x700), | ||
| 78 | INTC_VECT(DMAC0, 0x800), INTC_VECT(DMAC1, 0x820), | ||
| 79 | INTC_VECT(DMAC2, 0x840), INTC_VECT(DMAC3, 0x860), | ||
| 80 | INTC_VECT(VIO_CEUI, 0x880), INTC_VECT(VIO_BEUI, 0x8a0), | ||
| 81 | INTC_VECT(VIO_VEUI, 0x8c0), INTC_VECT(VOU, 0x8e0), | ||
| 82 | INTC_VECT(MFI, 0x900), INTC_VECT(VPU, 0x980), INTC_VECT(USB, 0xa20), | ||
| 83 | INTC_VECT(MMC_MMC1I, 0xb00), INTC_VECT(MMC_MMC2I, 0xb20), | ||
| 84 | INTC_VECT(MMC_MMC3I, 0xb40), | ||
| 85 | INTC_VECT(DMAC4, 0xb80), INTC_VECT(DMAC5, 0xba0), | ||
| 86 | INTC_VECT(DMAC_DADERR, 0xbc0), | ||
| 87 | INTC_VECT(SCIF, 0xc00), INTC_VECT(SCIFA1, 0xc20), | ||
| 88 | INTC_VECT(SCIFA2, 0xc40), | ||
| 89 | INTC_VECT(DENC, 0xc60), INTC_VECT(MSIOF, 0xc80), | ||
| 90 | INTC_VECT(FLCTL_FLSTEI, 0xd80), INTC_VECT(FLCTL_FLENDI, 0xda0), | ||
| 91 | INTC_VECT(FLCTL_FLTREQ0I, 0xdc0), INTC_VECT(FLCTL_FLTREQ1I, 0xde0), | ||
| 92 | INTC_VECT(I2C_ALI, 0xe00), INTC_VECT(I2C_TACKI, 0xe20), | ||
| 93 | INTC_VECT(I2C_WAITI, 0xe40), INTC_VECT(I2C_DTEI, 0xe60), | ||
| 94 | INTC_VECT(SDHI0, 0xe80), INTC_VECT(SDHI1, 0xea0), | ||
| 95 | INTC_VECT(SDHI2, 0xec0), INTC_VECT(SDHI3, 0xee0), | ||
| 96 | INTC_VECT(CMT, 0xf00), INTC_VECT(TSIF, 0xf20), | ||
| 97 | INTC_VECT(SIU, 0xf80), | ||
| 98 | INTC_VECT(TMU0, 0x400), INTC_VECT(TMU1, 0x420), | ||
| 99 | INTC_VECT(TMU2, 0x440), | ||
| 100 | INTC_VECT(VEU2, 0x580), INTC_VECT(LCDC, 0x580), | ||
| 101 | }; | ||
| 102 | |||
| 103 | static struct intc_group groups[] __initdata = { | ||
| 104 | INTC_GROUP(DMAC0123, DMAC0, DMAC1, DMAC2, DMAC3), | ||
| 105 | INTC_GROUP(VIOVOU, VIO_CEUI, VIO_BEUI, VIO_VEUI, VOU), | ||
| 106 | INTC_GROUP(MMC, MMC_MMC1I, MMC_MMC2I, MMC_MMC3I), | ||
| 107 | INTC_GROUP(DMAC45, DMAC4, DMAC5, DMAC_DADERR), | ||
| 108 | INTC_GROUP(FLCTL, FLCTL_FLSTEI, FLCTL_FLENDI, | ||
| 109 | FLCTL_FLTREQ0I, FLCTL_FLTREQ1I), | ||
| 110 | INTC_GROUP(I2C, I2C_ALI, I2C_TACKI, I2C_WAITI, I2C_DTEI), | ||
| 111 | INTC_GROUP(SDHI, SDHI0, SDHI1, SDHI2, SDHI3), | ||
| 112 | }; | ||
| 113 | |||
| 114 | static struct intc_mask_reg mask_registers[] __initdata = { | ||
| 115 | { 0xa4080080, 0xa40800c0, 8, /* IMR0 / IMCR0 */ | ||
| 116 | { } }, | ||
| 117 | { 0xa4080084, 0xa40800c4, 8, /* IMR1 / IMCR1 */ | ||
| 118 | { VOU, VIO_VEUI, VIO_BEUI, VIO_CEUI, DMAC3, DMAC2, DMAC1, DMAC0 } }, | ||
| 119 | { 0xa4080088, 0xa40800c8, 8, /* IMR2 / IMCR2 */ | ||
| 120 | { 0, 0, 0, VPU, 0, 0, 0, MFI } }, | ||
| 121 | { 0xa408008c, 0xa40800cc, 8, /* IMR3 / IMCR3 */ | ||
| 122 | { 0, 0, 0, ICB } }, | ||
| 123 | { 0xa4080090, 0xa40800d0, 8, /* IMR4 / IMCR4 */ | ||
| 124 | { 0, TMU2, TMU1, TMU0, VEU2, 0, 0, LCDC } }, | ||
| 125 | { 0xa4080094, 0xa40800d4, 8, /* IMR5 / IMCR5 */ | ||
| 126 | { 0, DMAC_DADERR, DMAC5, DMAC4, DENC, SCIFA2, SCIFA1, SCIF } }, | ||
| 127 | { 0xa4080098, 0xa40800d8, 8, /* IMR6 / IMCR6 */ | ||
| 128 | { 0, 0, 0, 0, 0, 0, 0, MSIOF } }, | ||
| 129 | { 0xa408009c, 0xa40800dc, 8, /* IMR7 / IMCR7 */ | ||
| 130 | { I2C_DTEI, I2C_WAITI, I2C_TACKI, I2C_ALI, | ||
| 131 | FLCTL_FLTREQ1I, FLCTL_FLTREQ0I, FLCTL_FLENDI, FLCTL_FLSTEI } }, | ||
| 132 | { 0xa40800a0, 0xa40800e0, 8, /* IMR8 / IMCR8 */ | ||
| 133 | { SDHI3, SDHI2, SDHI1, SDHI0, 0, 0, 0, SIU } }, | ||
| 134 | { 0xa40800a4, 0xa40800e4, 8, /* IMR9 / IMCR9 */ | ||
| 135 | { 0, 0, 0, CMT, 0, USB, } }, | ||
| 136 | { 0xa40800a8, 0xa40800e8, 8, /* IMR10 / IMCR10 */ | ||
| 137 | { 0, MMC_MMC3I, MMC_MMC2I, MMC_MMC1I } }, | ||
| 138 | { 0xa40800ac, 0xa40800ec, 8, /* IMR11 / IMCR11 */ | ||
| 139 | { 0, 0, 0, 0, 0, 0, 0, TSIF } }, | ||
| 140 | { 0xa4140044, 0xa4140064, 8, /* INTMSK00 / INTMSKCLR00 */ | ||
| 141 | { IRQ0, IRQ1, IRQ2, IRQ3, IRQ4, IRQ5, IRQ6, IRQ7 } }, | ||
| 142 | }; | ||
| 143 | |||
| 144 | static struct intc_prio_reg prio_registers[] __initdata = { | ||
| 145 | { 0xa4080000, 0, 16, 4, /* IPRA */ { TMU0, TMU1, TMU2 } }, | ||
| 146 | { 0xa4080004, 0, 16, 4, /* IPRB */ { VEU2, LCDC, ICB } }, | ||
| 147 | { 0xa4080008, 0, 16, 4, /* IPRC */ { } }, | ||
| 148 | { 0xa408000c, 0, 16, 4, /* IPRD */ { } }, | ||
| 149 | { 0xa4080010, 0, 16, 4, /* IPRE */ { DMAC0123, VIOVOU, MFI, VPU } }, | ||
| 150 | { 0xa4080014, 0, 16, 4, /* IPRF */ { 0, DMAC45, USB, CMT } }, | ||
| 151 | { 0xa4080018, 0, 16, 4, /* IPRG */ { SCIF, SCIFA1, SCIFA2, DENC } }, | ||
| 152 | { 0xa408001c, 0, 16, 4, /* IPRH */ { MSIOF, 0, FLCTL, I2C } }, | ||
| 153 | { 0xa4080020, 0, 16, 4, /* IPRI */ { 0, 0, TSIF, } }, | ||
| 154 | { 0xa4080024, 0, 16, 4, /* IPRJ */ { 0, 0, SIU } }, | ||
| 155 | { 0xa4080028, 0, 16, 4, /* IPRK */ { 0, MMC, 0, SDHI } }, | ||
| 156 | { 0xa408002c, 0, 16, 4, /* IPRL */ { } }, | ||
| 157 | { 0xa4140010, 0, 32, 4, /* INTPRI00 */ | ||
| 158 | { IRQ0, IRQ1, IRQ2, IRQ3, IRQ4, IRQ5, IRQ6, IRQ7 } }, | ||
| 159 | }; | ||
| 160 | |||
| 161 | static struct intc_sense_reg sense_registers[] __initdata = { | ||
| 162 | { 0xa414001c, 16, 2, /* ICR1 */ | ||
| 163 | { IRQ0, IRQ1, IRQ2, IRQ3, IRQ4, IRQ5, IRQ6, IRQ7 } }, | ||
| 164 | }; | ||
| 165 | |||
| 166 | static DECLARE_INTC_DESC(intc_desc, "sh7366", vectors, groups, | ||
| 167 | mask_registers, prio_registers, sense_registers); | ||
| 168 | |||
| 169 | void __init plat_irq_setup(void) | ||
| 170 | { | ||
| 171 | register_intc_controller(&intc_desc); | ||
| 172 | } | ||
| 173 | |||
| 174 | void __init plat_mem_setup(void) | ||
| 175 | { | ||
| 176 | /* TODO: Register Node 1 */ | ||
| 177 | } | ||
diff --git a/arch/sh/kernel/cpu/sh5/probe.c b/arch/sh/kernel/cpu/sh5/probe.c index 15d167fd0ae7..31f8cb0f6374 100644 --- a/arch/sh/kernel/cpu/sh5/probe.c +++ b/arch/sh/kernel/cpu/sh5/probe.c | |||
| @@ -20,19 +20,18 @@ int __init detect_cpu_and_cache_system(void) | |||
| 20 | { | 20 | { |
| 21 | unsigned long long cir; | 21 | unsigned long long cir; |
| 22 | 22 | ||
| 23 | /* Do peeks in real mode to avoid having to set up a mapping for the | 23 | /* |
| 24 | WPC registers. On SH5-101 cut2, such a mapping would be exposed to | 24 | * Do peeks in real mode to avoid having to set up a mapping for |
| 25 | an address translation erratum which would make it hard to set up | 25 | * the WPC registers. On SH5-101 cut2, such a mapping would be |
| 26 | correctly. */ | 26 | * exposed to an address translation erratum which would make it |
| 27 | * hard to set up correctly. | ||
| 28 | */ | ||
| 27 | cir = peek_real_address_q(0x0d000008); | 29 | cir = peek_real_address_q(0x0d000008); |
| 28 | if ((cir & 0xffff) == 0x5103) { | 30 | if ((cir & 0xffff) == 0x5103) |
| 29 | boot_cpu_data.type = CPU_SH5_103; | 31 | boot_cpu_data.type = CPU_SH5_103; |
| 30 | } else if (((cir >> 32) & 0xffff) == 0x51e2) { | 32 | else if (((cir >> 32) & 0xffff) == 0x51e2) |
| 31 | /* CPU.VCR aliased at CIR address on SH5-101 */ | 33 | /* CPU.VCR aliased at CIR address on SH5-101 */ |
| 32 | boot_cpu_data.type = CPU_SH5_101; | 34 | boot_cpu_data.type = CPU_SH5_101; |
| 33 | } else { | ||
| 34 | boot_cpu_data.type = CPU_SH_NONE; | ||
| 35 | } | ||
| 36 | 35 | ||
| 37 | /* | 36 | /* |
| 38 | * First, setup some sane values for the I-cache. | 37 | * First, setup some sane values for the I-cache. |
| @@ -40,37 +39,33 @@ int __init detect_cpu_and_cache_system(void) | |||
| 40 | boot_cpu_data.icache.ways = 4; | 39 | boot_cpu_data.icache.ways = 4; |
| 41 | boot_cpu_data.icache.sets = 256; | 40 | boot_cpu_data.icache.sets = 256; |
| 42 | boot_cpu_data.icache.linesz = L1_CACHE_BYTES; | 41 | boot_cpu_data.icache.linesz = L1_CACHE_BYTES; |
| 42 | boot_cpu_data.icache.way_incr = (1 << 13); | ||
| 43 | boot_cpu_data.icache.entry_shift = 5; | ||
| 44 | boot_cpu_data.icache.way_size = boot_cpu_data.icache.sets * | ||
| 45 | boot_cpu_data.icache.linesz; | ||
| 46 | boot_cpu_data.icache.entry_mask = 0x1fe0; | ||
| 47 | boot_cpu_data.icache.flags = 0; | ||
| 43 | 48 | ||
| 44 | #if 0 | ||
| 45 | /* | 49 | /* |
| 46 | * FIXME: This can probably be cleaned up a bit as well.. for example, | 50 | * Next, setup some sane values for the D-cache. |
| 47 | * do we really need the way shift _and_ the way_step_shift ?? Judging | 51 | * |
| 48 | * by the existing code, I would guess no.. is there any valid reason | 52 | * On the SH5, these are pretty consistent with the I-cache settings, |
| 49 | * why we need to be tracking this around? | 53 | * so we just copy over the existing definitions.. these can be fixed |
| 54 | * up later, especially if we add runtime CPU probing. | ||
| 55 | * | ||
| 56 | * Though in the meantime it saves us from having to duplicate all of | ||
| 57 | * the above definitions.. | ||
| 50 | */ | 58 | */ |
| 51 | boot_cpu_data.icache.way_shift = 13; | 59 | boot_cpu_data.dcache = boot_cpu_data.icache; |
| 52 | boot_cpu_data.icache.entry_shift = 5; | ||
| 53 | boot_cpu_data.icache.set_shift = 4; | ||
| 54 | boot_cpu_data.icache.way_step_shift = 16; | ||
| 55 | boot_cpu_data.icache.asid_shift = 2; | ||
| 56 | 60 | ||
| 57 | /* | 61 | /* |
| 58 | * way offset = cache size / associativity, so just don't factor in | 62 | * Setup any cache-related flags here |
| 59 | * associativity in the first place.. | ||
| 60 | */ | 63 | */ |
| 61 | boot_cpu_data.icache.way_ofs = boot_cpu_data.icache.sets * | 64 | #if defined(CONFIG_CACHE_WRITETHROUGH) |
| 62 | boot_cpu_data.icache.linesz; | 65 | set_bit(SH_CACHE_MODE_WT, &(boot_cpu_data.dcache.flags)); |
| 63 | 66 | #elif defined(CONFIG_CACHE_WRITEBACK) | |
| 64 | boot_cpu_data.icache.asid_mask = 0x3fc; | 67 | set_bit(SH_CACHE_MODE_WB, &(boot_cpu_data.dcache.flags)); |
| 65 | boot_cpu_data.icache.idx_mask = 0x1fe0; | ||
| 66 | boot_cpu_data.icache.epn_mask = 0xffffe000; | ||
| 67 | #endif | 68 | #endif |
| 68 | 69 | ||
| 69 | boot_cpu_data.icache.flags = 0; | ||
| 70 | |||
| 71 | /* A trivial starting point.. */ | ||
| 72 | memcpy(&boot_cpu_data.dcache, | ||
| 73 | &boot_cpu_data.icache, sizeof(struct cache_info)); | ||
| 74 | |||
| 75 | return 0; | 70 | return 0; |
| 76 | } | 71 | } |
diff --git a/arch/sh/kernel/io.c b/arch/sh/kernel/io.c index 71c9fde2fd90..2b8991229900 100644 --- a/arch/sh/kernel/io.c +++ b/arch/sh/kernel/io.c | |||
| @@ -63,7 +63,13 @@ EXPORT_SYMBOL(memset_io); | |||
| 63 | 63 | ||
| 64 | void __iomem *ioport_map(unsigned long port, unsigned int nr) | 64 | void __iomem *ioport_map(unsigned long port, unsigned int nr) |
| 65 | { | 65 | { |
| 66 | return sh_mv.mv_ioport_map(port, nr); | 66 | void __iomem *ret; |
| 67 | |||
| 68 | ret = __ioport_map_trapped(port, nr); | ||
| 69 | if (ret) | ||
| 70 | return ret; | ||
| 71 | |||
| 72 | return __ioport_map(port, nr); | ||
| 67 | } | 73 | } |
| 68 | EXPORT_SYMBOL(ioport_map); | 74 | EXPORT_SYMBOL(ioport_map); |
| 69 | 75 | ||
diff --git a/arch/sh/kernel/io_generic.c b/arch/sh/kernel/io_generic.c index 771ea4230441..db769449f5a7 100644 --- a/arch/sh/kernel/io_generic.c +++ b/arch/sh/kernel/io_generic.c | |||
| @@ -33,17 +33,17 @@ static inline void delay(void) | |||
| 33 | 33 | ||
| 34 | u8 generic_inb(unsigned long port) | 34 | u8 generic_inb(unsigned long port) |
| 35 | { | 35 | { |
| 36 | return ctrl_inb((unsigned long __force)ioport_map(port, 1)); | 36 | return ctrl_inb((unsigned long __force)__ioport_map(port, 1)); |
| 37 | } | 37 | } |
| 38 | 38 | ||
| 39 | u16 generic_inw(unsigned long port) | 39 | u16 generic_inw(unsigned long port) |
| 40 | { | 40 | { |
| 41 | return ctrl_inw((unsigned long __force)ioport_map(port, 2)); | 41 | return ctrl_inw((unsigned long __force)__ioport_map(port, 2)); |
| 42 | } | 42 | } |
| 43 | 43 | ||
| 44 | u32 generic_inl(unsigned long port) | 44 | u32 generic_inl(unsigned long port) |
| 45 | { | 45 | { |
| 46 | return ctrl_inl((unsigned long __force)ioport_map(port, 4)); | 46 | return ctrl_inl((unsigned long __force)__ioport_map(port, 4)); |
| 47 | } | 47 | } |
| 48 | 48 | ||
| 49 | u8 generic_inb_p(unsigned long port) | 49 | u8 generic_inb_p(unsigned long port) |
| @@ -81,7 +81,7 @@ void generic_insb(unsigned long port, void *dst, unsigned long count) | |||
| 81 | volatile u8 *port_addr; | 81 | volatile u8 *port_addr; |
| 82 | u8 *buf = dst; | 82 | u8 *buf = dst; |
| 83 | 83 | ||
| 84 | port_addr = (volatile u8 *)ioport_map(port, 1); | 84 | port_addr = (volatile u8 *)__ioport_map(port, 1); |
| 85 | while (count--) | 85 | while (count--) |
| 86 | *buf++ = *port_addr; | 86 | *buf++ = *port_addr; |
| 87 | } | 87 | } |
| @@ -91,7 +91,7 @@ void generic_insw(unsigned long port, void *dst, unsigned long count) | |||
| 91 | volatile u16 *port_addr; | 91 | volatile u16 *port_addr; |
| 92 | u16 *buf = dst; | 92 | u16 *buf = dst; |
| 93 | 93 | ||
| 94 | port_addr = (volatile u16 *)ioport_map(port, 2); | 94 | port_addr = (volatile u16 *)__ioport_map(port, 2); |
| 95 | while (count--) | 95 | while (count--) |
| 96 | *buf++ = *port_addr; | 96 | *buf++ = *port_addr; |
| 97 | 97 | ||
| @@ -103,7 +103,7 @@ void generic_insl(unsigned long port, void *dst, unsigned long count) | |||
| 103 | volatile u32 *port_addr; | 103 | volatile u32 *port_addr; |
| 104 | u32 *buf = dst; | 104 | u32 *buf = dst; |
| 105 | 105 | ||
| 106 | port_addr = (volatile u32 *)ioport_map(port, 4); | 106 | port_addr = (volatile u32 *)__ioport_map(port, 4); |
| 107 | while (count--) | 107 | while (count--) |
| 108 | *buf++ = *port_addr; | 108 | *buf++ = *port_addr; |
| 109 | 109 | ||
| @@ -112,17 +112,17 @@ void generic_insl(unsigned long port, void *dst, unsigned long count) | |||
| 112 | 112 | ||
| 113 | void generic_outb(u8 b, unsigned long port) | 113 | void generic_outb(u8 b, unsigned long port) |
| 114 | { | 114 | { |
| 115 | ctrl_outb(b, (unsigned long __force)ioport_map(port, 1)); | 115 | ctrl_outb(b, (unsigned long __force)__ioport_map(port, 1)); |
| 116 | } | 116 | } |
| 117 | 117 | ||
| 118 | void generic_outw(u16 b, unsigned long port) | 118 | void generic_outw(u16 b, unsigned long port) |
| 119 | { | 119 | { |
| 120 | ctrl_outw(b, (unsigned long __force)ioport_map(port, 2)); | 120 | ctrl_outw(b, (unsigned long __force)__ioport_map(port, 2)); |
| 121 | } | 121 | } |
| 122 | 122 | ||
| 123 | void generic_outl(u32 b, unsigned long port) | 123 | void generic_outl(u32 b, unsigned long port) |
| 124 | { | 124 | { |
| 125 | ctrl_outl(b, (unsigned long __force)ioport_map(port, 4)); | 125 | ctrl_outl(b, (unsigned long __force)__ioport_map(port, 4)); |
| 126 | } | 126 | } |
| 127 | 127 | ||
| 128 | void generic_outb_p(u8 b, unsigned long port) | 128 | void generic_outb_p(u8 b, unsigned long port) |
| @@ -153,7 +153,7 @@ void generic_outsb(unsigned long port, const void *src, unsigned long count) | |||
| 153 | volatile u8 *port_addr; | 153 | volatile u8 *port_addr; |
| 154 | const u8 *buf = src; | 154 | const u8 *buf = src; |
| 155 | 155 | ||
| 156 | port_addr = (volatile u8 __force *)ioport_map(port, 1); | 156 | port_addr = (volatile u8 __force *)__ioport_map(port, 1); |
| 157 | 157 | ||
| 158 | while (count--) | 158 | while (count--) |
| 159 | *port_addr = *buf++; | 159 | *port_addr = *buf++; |
| @@ -164,7 +164,7 @@ void generic_outsw(unsigned long port, const void *src, unsigned long count) | |||
| 164 | volatile u16 *port_addr; | 164 | volatile u16 *port_addr; |
| 165 | const u16 *buf = src; | 165 | const u16 *buf = src; |
| 166 | 166 | ||
| 167 | port_addr = (volatile u16 __force *)ioport_map(port, 2); | 167 | port_addr = (volatile u16 __force *)__ioport_map(port, 2); |
| 168 | 168 | ||
| 169 | while (count--) | 169 | while (count--) |
| 170 | *port_addr = *buf++; | 170 | *port_addr = *buf++; |
| @@ -177,7 +177,7 @@ void generic_outsl(unsigned long port, const void *src, unsigned long count) | |||
| 177 | volatile u32 *port_addr; | 177 | volatile u32 *port_addr; |
| 178 | const u32 *buf = src; | 178 | const u32 *buf = src; |
| 179 | 179 | ||
| 180 | port_addr = (volatile u32 __force *)ioport_map(port, 4); | 180 | port_addr = (volatile u32 __force *)__ioport_map(port, 4); |
| 181 | while (count--) | 181 | while (count--) |
| 182 | *port_addr = *buf++; | 182 | *port_addr = *buf++; |
| 183 | 183 | ||
diff --git a/arch/sh/kernel/io_trapped.c b/arch/sh/kernel/io_trapped.c new file mode 100644 index 000000000000..86a665d92201 --- /dev/null +++ b/arch/sh/kernel/io_trapped.c | |||
| @@ -0,0 +1,276 @@ | |||
| 1 | /* | ||
| 2 | * Trapped io support | ||
| 3 | * | ||
| 4 | * Copyright (C) 2008 Magnus Damm | ||
| 5 | * | ||
| 6 | * Intercept io operations by trapping. | ||
| 7 | * | ||
| 8 | * This file is subject to the terms and conditions of the GNU General Public | ||
| 9 | * License. See the file "COPYING" in the main directory of this archive | ||
| 10 | * for more details. | ||
| 11 | */ | ||
| 12 | #include <linux/kernel.h> | ||
| 13 | #include <linux/mm.h> | ||
| 14 | #include <linux/bitops.h> | ||
| 15 | #include <linux/vmalloc.h> | ||
| 16 | #include <linux/module.h> | ||
| 17 | #include <asm/system.h> | ||
| 18 | #include <asm/mmu_context.h> | ||
| 19 | #include <asm/uaccess.h> | ||
| 20 | #include <asm/io.h> | ||
| 21 | #include <asm/io_trapped.h> | ||
| 22 | |||
| 23 | #define TRAPPED_PAGES_MAX 16 | ||
| 24 | |||
| 25 | #ifdef CONFIG_HAS_IOPORT | ||
| 26 | LIST_HEAD(trapped_io); | ||
| 27 | EXPORT_SYMBOL_GPL(trapped_io); | ||
| 28 | #endif | ||
| 29 | #ifdef CONFIG_HAS_IOMEM | ||
| 30 | LIST_HEAD(trapped_mem); | ||
| 31 | EXPORT_SYMBOL_GPL(trapped_mem); | ||
| 32 | #endif | ||
| 33 | static DEFINE_SPINLOCK(trapped_lock); | ||
| 34 | |||
| 35 | int __init register_trapped_io(struct trapped_io *tiop) | ||
| 36 | { | ||
| 37 | struct resource *res; | ||
| 38 | unsigned long len = 0, flags = 0; | ||
| 39 | struct page *pages[TRAPPED_PAGES_MAX]; | ||
| 40 | int k, n; | ||
| 41 | |||
| 42 | /* structure must be page aligned */ | ||
| 43 | if ((unsigned long)tiop & (PAGE_SIZE - 1)) | ||
| 44 | goto bad; | ||
| 45 | |||
| 46 | for (k = 0; k < tiop->num_resources; k++) { | ||
| 47 | res = tiop->resource + k; | ||
| 48 | len += roundup((res->end - res->start) + 1, PAGE_SIZE); | ||
| 49 | flags |= res->flags; | ||
| 50 | } | ||
| 51 | |||
| 52 | /* support IORESOURCE_IO _or_ MEM, not both */ | ||
| 53 | if (hweight_long(flags) != 1) | ||
| 54 | goto bad; | ||
| 55 | |||
| 56 | n = len >> PAGE_SHIFT; | ||
| 57 | |||
| 58 | if (n >= TRAPPED_PAGES_MAX) | ||
| 59 | goto bad; | ||
| 60 | |||
| 61 | for (k = 0; k < n; k++) | ||
| 62 | pages[k] = virt_to_page(tiop); | ||
| 63 | |||
| 64 | tiop->virt_base = vmap(pages, n, VM_MAP, PAGE_NONE); | ||
| 65 | if (!tiop->virt_base) | ||
| 66 | goto bad; | ||
| 67 | |||
| 68 | len = 0; | ||
| 69 | for (k = 0; k < tiop->num_resources; k++) { | ||
| 70 | res = tiop->resource + k; | ||
| 71 | pr_info("trapped io 0x%08lx overrides %s 0x%08lx\n", | ||
| 72 | (unsigned long)(tiop->virt_base + len), | ||
| 73 | res->flags & IORESOURCE_IO ? "io" : "mmio", | ||
| 74 | (unsigned long)res->start); | ||
| 75 | len += roundup((res->end - res->start) + 1, PAGE_SIZE); | ||
| 76 | } | ||
| 77 | |||
| 78 | tiop->magic = IO_TRAPPED_MAGIC; | ||
| 79 | INIT_LIST_HEAD(&tiop->list); | ||
| 80 | spin_lock_irq(&trapped_lock); | ||
| 81 | if (flags & IORESOURCE_IO) | ||
| 82 | list_add(&tiop->list, &trapped_io); | ||
| 83 | if (flags & IORESOURCE_MEM) | ||
| 84 | list_add(&tiop->list, &trapped_mem); | ||
| 85 | spin_unlock_irq(&trapped_lock); | ||
| 86 | |||
| 87 | return 0; | ||
| 88 | bad: | ||
| 89 | pr_warning("unable to install trapped io filter\n"); | ||
| 90 | return -1; | ||
| 91 | } | ||
| 92 | EXPORT_SYMBOL_GPL(register_trapped_io); | ||
| 93 | |||
| 94 | void __iomem *match_trapped_io_handler(struct list_head *list, | ||
| 95 | unsigned long offset, | ||
| 96 | unsigned long size) | ||
| 97 | { | ||
| 98 | unsigned long voffs; | ||
| 99 | struct trapped_io *tiop; | ||
| 100 | struct resource *res; | ||
| 101 | int k, len; | ||
| 102 | |||
| 103 | spin_lock_irq(&trapped_lock); | ||
| 104 | list_for_each_entry(tiop, list, list) { | ||
| 105 | voffs = 0; | ||
| 106 | for (k = 0; k < tiop->num_resources; k++) { | ||
| 107 | res = tiop->resource + k; | ||
| 108 | if (res->start == offset) { | ||
| 109 | spin_unlock_irq(&trapped_lock); | ||
| 110 | return tiop->virt_base + voffs; | ||
| 111 | } | ||
| 112 | |||
| 113 | len = (res->end - res->start) + 1; | ||
| 114 | voffs += roundup(len, PAGE_SIZE); | ||
| 115 | } | ||
| 116 | } | ||
| 117 | spin_unlock_irq(&trapped_lock); | ||
| 118 | return NULL; | ||
| 119 | } | ||
| 120 | EXPORT_SYMBOL_GPL(match_trapped_io_handler); | ||
| 121 | |||
| 122 | static struct trapped_io *lookup_tiop(unsigned long address) | ||
| 123 | { | ||
| 124 | pgd_t *pgd_k; | ||
| 125 | pud_t *pud_k; | ||
| 126 | pmd_t *pmd_k; | ||
| 127 | pte_t *pte_k; | ||
| 128 | pte_t entry; | ||
| 129 | |||
| 130 | pgd_k = swapper_pg_dir + pgd_index(address); | ||
| 131 | if (!pgd_present(*pgd_k)) | ||
| 132 | return NULL; | ||
| 133 | |||
| 134 | pud_k = pud_offset(pgd_k, address); | ||
| 135 | if (!pud_present(*pud_k)) | ||
| 136 | return NULL; | ||
| 137 | |||
| 138 | pmd_k = pmd_offset(pud_k, address); | ||
| 139 | if (!pmd_present(*pmd_k)) | ||
| 140 | return NULL; | ||
| 141 | |||
| 142 | pte_k = pte_offset_kernel(pmd_k, address); | ||
| 143 | entry = *pte_k; | ||
| 144 | |||
| 145 | return pfn_to_kaddr(pte_pfn(entry)); | ||
| 146 | } | ||
| 147 | |||
| 148 | static unsigned long lookup_address(struct trapped_io *tiop, | ||
| 149 | unsigned long address) | ||
| 150 | { | ||
| 151 | struct resource *res; | ||
| 152 | unsigned long vaddr = (unsigned long)tiop->virt_base; | ||
| 153 | unsigned long len; | ||
| 154 | int k; | ||
| 155 | |||
| 156 | for (k = 0; k < tiop->num_resources; k++) { | ||
| 157 | res = tiop->resource + k; | ||
| 158 | len = roundup((res->end - res->start) + 1, PAGE_SIZE); | ||
| 159 | if (address < (vaddr + len)) | ||
| 160 | return res->start + (address - vaddr); | ||
| 161 | vaddr += len; | ||
| 162 | } | ||
| 163 | return 0; | ||
| 164 | } | ||
| 165 | |||
| 166 | static unsigned long long copy_word(unsigned long src_addr, int src_len, | ||
| 167 | unsigned long dst_addr, int dst_len) | ||
| 168 | { | ||
| 169 | unsigned long long tmp = 0; | ||
| 170 | |||
| 171 | switch (src_len) { | ||
| 172 | case 1: | ||
| 173 | tmp = ctrl_inb(src_addr); | ||
| 174 | break; | ||
| 175 | case 2: | ||
| 176 | tmp = ctrl_inw(src_addr); | ||
| 177 | break; | ||
| 178 | case 4: | ||
| 179 | tmp = ctrl_inl(src_addr); | ||
| 180 | break; | ||
| 181 | case 8: | ||
| 182 | tmp = ctrl_inq(src_addr); | ||
| 183 | break; | ||
| 184 | } | ||
| 185 | |||
| 186 | switch (dst_len) { | ||
| 187 | case 1: | ||
| 188 | ctrl_outb(tmp, dst_addr); | ||
| 189 | break; | ||
| 190 | case 2: | ||
| 191 | ctrl_outw(tmp, dst_addr); | ||
| 192 | break; | ||
| 193 | case 4: | ||
| 194 | ctrl_outl(tmp, dst_addr); | ||
| 195 | break; | ||
| 196 | case 8: | ||
| 197 | ctrl_outq(tmp, dst_addr); | ||
| 198 | break; | ||
| 199 | } | ||
| 200 | |||
| 201 | return tmp; | ||
| 202 | } | ||
| 203 | |||
| 204 | static unsigned long from_device(void *dst, const void *src, unsigned long cnt) | ||
| 205 | { | ||
| 206 | struct trapped_io *tiop; | ||
| 207 | unsigned long src_addr = (unsigned long)src; | ||
| 208 | unsigned long long tmp; | ||
| 209 | |||
| 210 | pr_debug("trapped io read 0x%08lx (%ld)\n", src_addr, cnt); | ||
| 211 | tiop = lookup_tiop(src_addr); | ||
| 212 | WARN_ON(!tiop || (tiop->magic != IO_TRAPPED_MAGIC)); | ||
| 213 | |||
| 214 | src_addr = lookup_address(tiop, src_addr); | ||
| 215 | if (!src_addr) | ||
| 216 | return cnt; | ||
| 217 | |||
| 218 | tmp = copy_word(src_addr, | ||
| 219 | max_t(unsigned long, cnt, | ||
| 220 | (tiop->minimum_bus_width / 8)), | ||
| 221 | (unsigned long)dst, cnt); | ||
| 222 | |||
| 223 | pr_debug("trapped io read 0x%08lx -> 0x%08llx\n", src_addr, tmp); | ||
| 224 | return 0; | ||
| 225 | } | ||
| 226 | |||
| 227 | static unsigned long to_device(void *dst, const void *src, unsigned long cnt) | ||
| 228 | { | ||
| 229 | struct trapped_io *tiop; | ||
| 230 | unsigned long dst_addr = (unsigned long)dst; | ||
| 231 | unsigned long long tmp; | ||
| 232 | |||
| 233 | pr_debug("trapped io write 0x%08lx (%ld)\n", dst_addr, cnt); | ||
| 234 | tiop = lookup_tiop(dst_addr); | ||
| 235 | WARN_ON(!tiop || (tiop->magic != IO_TRAPPED_MAGIC)); | ||
| 236 | |||
| 237 | dst_addr = lookup_address(tiop, dst_addr); | ||
| 238 | if (!dst_addr) | ||
| 239 | return cnt; | ||
| 240 | |||
| 241 | tmp = copy_word((unsigned long)src, cnt, | ||
| 242 | dst_addr, max_t(unsigned long, cnt, | ||
| 243 | (tiop->minimum_bus_width / 8))); | ||
| 244 | |||
| 245 | pr_debug("trapped io write 0x%08lx -> 0x%08llx\n", dst_addr, tmp); | ||
| 246 | return 0; | ||
| 247 | } | ||
| 248 | |||
| 249 | static struct mem_access trapped_io_access = { | ||
| 250 | from_device, | ||
| 251 | to_device, | ||
| 252 | }; | ||
| 253 | |||
| 254 | int handle_trapped_io(struct pt_regs *regs, unsigned long address) | ||
| 255 | { | ||
| 256 | mm_segment_t oldfs; | ||
| 257 | opcode_t instruction; | ||
| 258 | int tmp; | ||
| 259 | |||
| 260 | if (!lookup_tiop(address)) | ||
| 261 | return 0; | ||
| 262 | |||
| 263 | WARN_ON(user_mode(regs)); | ||
| 264 | |||
| 265 | oldfs = get_fs(); | ||
| 266 | set_fs(KERNEL_DS); | ||
| 267 | if (copy_from_user(&instruction, (void *)(regs->pc), | ||
| 268 | sizeof(instruction))) { | ||
| 269 | set_fs(oldfs); | ||
| 270 | return 0; | ||
| 271 | } | ||
| 272 | |||
| 273 | tmp = handle_unaligned_access(instruction, regs, &trapped_io_access); | ||
| 274 | set_fs(oldfs); | ||
| 275 | return tmp == 0; | ||
| 276 | } | ||
diff --git a/arch/sh/kernel/irq.c b/arch/sh/kernel/irq.c index 0586bc62ad96..9bf19b00696a 100644 --- a/arch/sh/kernel/irq.c +++ b/arch/sh/kernel/irq.c | |||
| @@ -248,9 +248,6 @@ asmlinkage void do_softirq(void) | |||
| 248 | 248 | ||
| 249 | void __init init_IRQ(void) | 249 | void __init init_IRQ(void) |
| 250 | { | 250 | { |
| 251 | #ifdef CONFIG_CPU_HAS_PINT_IRQ | ||
| 252 | init_IRQ_pint(); | ||
| 253 | #endif | ||
| 254 | plat_irq_setup(); | 251 | plat_irq_setup(); |
| 255 | 252 | ||
| 256 | /* Perform the machine specific initialisation */ | 253 | /* Perform the machine specific initialisation */ |
diff --git a/arch/sh/kernel/process_64.c b/arch/sh/kernel/process_64.c index cff3b7dc9c56..046999b1d1af 100644 --- a/arch/sh/kernel/process_64.c +++ b/arch/sh/kernel/process_64.c | |||
| @@ -623,6 +623,7 @@ extern void interruptible_sleep_on(wait_queue_head_t *q); | |||
| 623 | 623 | ||
| 624 | #define mid_sched ((unsigned long) interruptible_sleep_on) | 624 | #define mid_sched ((unsigned long) interruptible_sleep_on) |
| 625 | 625 | ||
| 626 | #ifdef CONFIG_FRAME_POINTER | ||
| 626 | static int in_sh64_switch_to(unsigned long pc) | 627 | static int in_sh64_switch_to(unsigned long pc) |
| 627 | { | 628 | { |
| 628 | extern char __sh64_switch_to_end; | 629 | extern char __sh64_switch_to_end; |
| @@ -631,12 +632,10 @@ static int in_sh64_switch_to(unsigned long pc) | |||
| 631 | return (pc >= (unsigned long) sh64_switch_to) && | 632 | return (pc >= (unsigned long) sh64_switch_to) && |
| 632 | (pc < (unsigned long) &__sh64_switch_to_end); | 633 | (pc < (unsigned long) &__sh64_switch_to_end); |
| 633 | } | 634 | } |
| 635 | #endif | ||
| 634 | 636 | ||
| 635 | unsigned long get_wchan(struct task_struct *p) | 637 | unsigned long get_wchan(struct task_struct *p) |
| 636 | { | 638 | { |
| 637 | unsigned long schedule_fp; | ||
| 638 | unsigned long sh64_switch_to_fp; | ||
| 639 | unsigned long schedule_caller_pc; | ||
| 640 | unsigned long pc; | 639 | unsigned long pc; |
| 641 | 640 | ||
| 642 | if (!p || p == current || p->state == TASK_RUNNING) | 641 | if (!p || p == current || p->state == TASK_RUNNING) |
| @@ -649,6 +648,10 @@ unsigned long get_wchan(struct task_struct *p) | |||
| 649 | 648 | ||
| 650 | #ifdef CONFIG_FRAME_POINTER | 649 | #ifdef CONFIG_FRAME_POINTER |
| 651 | if (in_sh64_switch_to(pc)) { | 650 | if (in_sh64_switch_to(pc)) { |
| 651 | unsigned long schedule_fp; | ||
| 652 | unsigned long sh64_switch_to_fp; | ||
| 653 | unsigned long schedule_caller_pc; | ||
| 654 | |||
| 652 | sh64_switch_to_fp = (long) p->thread.sp; | 655 | sh64_switch_to_fp = (long) p->thread.sp; |
| 653 | /* r14 is saved at offset 4 in the sh64_switch_to frame */ | 656 | /* r14 is saved at offset 4 in the sh64_switch_to frame */ |
| 654 | schedule_fp = *(unsigned long *) (long)(sh64_switch_to_fp + 4); | 657 | schedule_fp = *(unsigned long *) (long)(sh64_switch_to_fp + 4); |
diff --git a/arch/sh/kernel/ptrace_32.c b/arch/sh/kernel/ptrace_32.c index ce0664a58b49..fddb547f3c2b 100644 --- a/arch/sh/kernel/ptrace_32.c +++ b/arch/sh/kernel/ptrace_32.c | |||
| @@ -220,7 +220,7 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) | |||
| 220 | dp = ((unsigned long) child) + THREAD_SIZE - | 220 | dp = ((unsigned long) child) + THREAD_SIZE - |
| 221 | sizeof(struct pt_dspregs); | 221 | sizeof(struct pt_dspregs); |
| 222 | if (*((int *) (dp - 4)) == SR_FD) { | 222 | if (*((int *) (dp - 4)) == SR_FD) { |
| 223 | copy_to_user(addr, (void *) dp, | 223 | copy_to_user((void *)addr, (void *) dp, |
| 224 | sizeof(struct pt_dspregs)); | 224 | sizeof(struct pt_dspregs)); |
| 225 | ret = 0; | 225 | ret = 0; |
| 226 | } | 226 | } |
| @@ -234,7 +234,7 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) | |||
| 234 | dp = ((unsigned long) child) + THREAD_SIZE - | 234 | dp = ((unsigned long) child) + THREAD_SIZE - |
| 235 | sizeof(struct pt_dspregs); | 235 | sizeof(struct pt_dspregs); |
| 236 | if (*((int *) (dp - 4)) == SR_FD) { | 236 | if (*((int *) (dp - 4)) == SR_FD) { |
| 237 | copy_from_user((void *) dp, addr, | 237 | copy_from_user((void *) dp, (void *)addr, |
| 238 | sizeof(struct pt_dspregs)); | 238 | sizeof(struct pt_dspregs)); |
| 239 | ret = 0; | 239 | ret = 0; |
| 240 | } | 240 | } |
diff --git a/arch/sh/kernel/setup.c b/arch/sh/kernel/setup.c index 18a5baf2cbad..ff4f54a47c07 100644 --- a/arch/sh/kernel/setup.c +++ b/arch/sh/kernel/setup.c | |||
| @@ -333,7 +333,7 @@ static const char *cpu_name[] = { | |||
| 333 | [CPU_SH7343] = "SH7343", [CPU_SH7785] = "SH7785", | 333 | [CPU_SH7343] = "SH7343", [CPU_SH7785] = "SH7785", |
| 334 | [CPU_SH7722] = "SH7722", [CPU_SHX3] = "SH-X3", | 334 | [CPU_SH7722] = "SH7722", [CPU_SHX3] = "SH-X3", |
| 335 | [CPU_SH5_101] = "SH5-101", [CPU_SH5_103] = "SH5-103", | 335 | [CPU_SH5_101] = "SH5-101", [CPU_SH5_103] = "SH5-103", |
| 336 | [CPU_SH_NONE] = "Unknown" | 336 | [CPU_SH7366] = "SH7366", [CPU_SH_NONE] = "Unknown" |
| 337 | }; | 337 | }; |
| 338 | 338 | ||
| 339 | const char *get_cpu_subtype(struct sh_cpuinfo *c) | 339 | const char *get_cpu_subtype(struct sh_cpuinfo *c) |
diff --git a/arch/sh/kernel/syscalls_32.S b/arch/sh/kernel/syscalls_32.S index 719e127a7c05..a46cc3a41148 100644 --- a/arch/sh/kernel/syscalls_32.S +++ b/arch/sh/kernel/syscalls_32.S | |||
| @@ -338,6 +338,8 @@ ENTRY(sys_call_table) | |||
| 338 | .long sys_epoll_pwait | 338 | .long sys_epoll_pwait |
| 339 | .long sys_utimensat /* 320 */ | 339 | .long sys_utimensat /* 320 */ |
| 340 | .long sys_signalfd | 340 | .long sys_signalfd |
| 341 | .long sys_ni_syscall | 341 | .long sys_timerfd_create |
| 342 | .long sys_eventfd | 342 | .long sys_eventfd |
| 343 | .long sys_fallocate | 343 | .long sys_fallocate |
| 344 | .long sys_timerfd_settime /* 325 */ | ||
| 345 | .long sys_timerfd_gettime | ||
diff --git a/arch/sh/kernel/syscalls_64.S b/arch/sh/kernel/syscalls_64.S index 12c7340356ae..d5d7843aad94 100644 --- a/arch/sh/kernel/syscalls_64.S +++ b/arch/sh/kernel/syscalls_64.S | |||
| @@ -376,6 +376,8 @@ sys_call_table: | |||
| 376 | .long sys_epoll_pwait | 376 | .long sys_epoll_pwait |
| 377 | .long sys_utimensat | 377 | .long sys_utimensat |
| 378 | .long sys_signalfd | 378 | .long sys_signalfd |
| 379 | .long sys_ni_syscall /* 350 */ | 379 | .long sys_timerfd_create /* 350 */ |
| 380 | .long sys_eventfd | 380 | .long sys_eventfd |
| 381 | .long sys_fallocate | 381 | .long sys_fallocate |
| 382 | .long sys_timerfd_settime | ||
| 383 | .long sys_timerfd_gettime | ||
diff --git a/arch/sh/kernel/time_32.c b/arch/sh/kernel/time_32.c index 2bc04bfee738..7281342c044d 100644 --- a/arch/sh/kernel/time_32.c +++ b/arch/sh/kernel/time_32.c | |||
| @@ -120,10 +120,6 @@ static long last_rtc_update; | |||
| 120 | */ | 120 | */ |
| 121 | void handle_timer_tick(void) | 121 | void handle_timer_tick(void) |
| 122 | { | 122 | { |
| 123 | do_timer(1); | ||
| 124 | #ifndef CONFIG_SMP | ||
| 125 | update_process_times(user_mode(get_irq_regs())); | ||
| 126 | #endif | ||
| 127 | if (current->pid) | 123 | if (current->pid) |
| 128 | profile_tick(CPU_PROFILING); | 124 | profile_tick(CPU_PROFILING); |
| 129 | 125 | ||
| @@ -133,6 +129,16 @@ void handle_timer_tick(void) | |||
| 133 | #endif | 129 | #endif |
| 134 | 130 | ||
| 135 | /* | 131 | /* |
| 132 | * Here we are in the timer irq handler. We just have irqs locally | ||
| 133 | * disabled but we don't know if the timer_bh is running on the other | ||
| 134 | * CPU. We need to avoid to SMP race with it. NOTE: we don' t need | ||
| 135 | * the irq version of write_lock because as just said we have irq | ||
| 136 | * locally disabled. -arca | ||
| 137 | */ | ||
| 138 | write_seqlock(&xtime_lock); | ||
| 139 | do_timer(1); | ||
| 140 | |||
| 141 | /* | ||
| 136 | * If we have an externally synchronized Linux clock, then update | 142 | * If we have an externally synchronized Linux clock, then update |
| 137 | * RTC clock accordingly every ~11 minutes. Set_rtc_mmss() has to be | 143 | * RTC clock accordingly every ~11 minutes. Set_rtc_mmss() has to be |
| 138 | * called as close as possible to 500 ms before the new second starts. | 144 | * called as close as possible to 500 ms before the new second starts. |
| @@ -147,6 +153,11 @@ void handle_timer_tick(void) | |||
| 147 | /* do it again in 60s */ | 153 | /* do it again in 60s */ |
| 148 | last_rtc_update = xtime.tv_sec - 600; | 154 | last_rtc_update = xtime.tv_sec - 600; |
| 149 | } | 155 | } |
| 156 | write_sequnlock(&xtime_lock); | ||
| 157 | |||
| 158 | #ifndef CONFIG_SMP | ||
| 159 | update_process_times(user_mode(get_irq_regs())); | ||
| 160 | #endif | ||
| 150 | } | 161 | } |
| 151 | #endif /* !CONFIG_GENERIC_CLOCKEVENTS */ | 162 | #endif /* !CONFIG_GENERIC_CLOCKEVENTS */ |
| 152 | 163 | ||
diff --git a/arch/sh/kernel/time_64.c b/arch/sh/kernel/time_64.c index f819ba38a6ce..898977ee2030 100644 --- a/arch/sh/kernel/time_64.c +++ b/arch/sh/kernel/time_64.c | |||
| @@ -229,15 +229,22 @@ static long last_rtc_update; | |||
| 229 | static inline void do_timer_interrupt(void) | 229 | static inline void do_timer_interrupt(void) |
| 230 | { | 230 | { |
| 231 | unsigned long long current_ctc; | 231 | unsigned long long current_ctc; |
| 232 | |||
| 233 | if (current->pid) | ||
| 234 | profile_tick(CPU_PROFILING); | ||
| 235 | |||
| 236 | /* | ||
| 237 | * Here we are in the timer irq handler. We just have irqs locally | ||
| 238 | * disabled but we don't know if the timer_bh is running on the other | ||
| 239 | * CPU. We need to avoid to SMP race with it. NOTE: we don' t need | ||
| 240 | * the irq version of write_lock because as just said we have irq | ||
| 241 | * locally disabled. -arca | ||
| 242 | */ | ||
| 243 | write_lock(&xtime_lock); | ||
| 232 | asm ("getcon cr62, %0" : "=r" (current_ctc)); | 244 | asm ("getcon cr62, %0" : "=r" (current_ctc)); |
| 233 | ctc_last_interrupt = (unsigned long) current_ctc; | 245 | ctc_last_interrupt = (unsigned long) current_ctc; |
| 234 | 246 | ||
| 235 | do_timer(1); | 247 | do_timer(1); |
| 236 | #ifndef CONFIG_SMP | ||
| 237 | update_process_times(user_mode(get_irq_regs())); | ||
| 238 | #endif | ||
| 239 | if (current->pid) | ||
| 240 | profile_tick(CPU_PROFILING); | ||
| 241 | 248 | ||
| 242 | #ifdef CONFIG_HEARTBEAT | 249 | #ifdef CONFIG_HEARTBEAT |
| 243 | if (sh_mv.mv_heartbeat != NULL) | 250 | if (sh_mv.mv_heartbeat != NULL) |
| @@ -259,6 +266,11 @@ static inline void do_timer_interrupt(void) | |||
| 259 | /* do it again in 60 s */ | 266 | /* do it again in 60 s */ |
| 260 | last_rtc_update = xtime.tv_sec - 600; | 267 | last_rtc_update = xtime.tv_sec - 600; |
| 261 | } | 268 | } |
| 269 | write_unlock(&xtime_lock); | ||
| 270 | |||
| 271 | #ifndef CONFIG_SMP | ||
| 272 | update_process_times(user_mode(get_irq_regs())); | ||
| 273 | #endif | ||
| 262 | } | 274 | } |
| 263 | 275 | ||
| 264 | /* | 276 | /* |
| @@ -275,16 +287,7 @@ static irqreturn_t timer_interrupt(int irq, void *dev_id) | |||
| 275 | timer_status &= ~0x100; | 287 | timer_status &= ~0x100; |
| 276 | ctrl_outw(timer_status, TMU0_TCR); | 288 | ctrl_outw(timer_status, TMU0_TCR); |
| 277 | 289 | ||
| 278 | /* | ||
| 279 | * Here we are in the timer irq handler. We just have irqs locally | ||
| 280 | * disabled but we don't know if the timer_bh is running on the other | ||
| 281 | * CPU. We need to avoid to SMP race with it. NOTE: we don' t need | ||
| 282 | * the irq version of write_lock because as just said we have irq | ||
| 283 | * locally disabled. -arca | ||
| 284 | */ | ||
| 285 | write_lock(&xtime_lock); | ||
| 286 | do_timer_interrupt(); | 290 | do_timer_interrupt(); |
| 287 | write_unlock(&xtime_lock); | ||
| 288 | 291 | ||
| 289 | return IRQ_HANDLED; | 292 | return IRQ_HANDLED; |
| 290 | } | 293 | } |
diff --git a/arch/sh/kernel/timers/timer-mtu2.c b/arch/sh/kernel/timers/timer-mtu2.c index 463cd08f9517..ade9d6eb29f9 100644 --- a/arch/sh/kernel/timers/timer-mtu2.c +++ b/arch/sh/kernel/timers/timer-mtu2.c | |||
| @@ -154,7 +154,6 @@ static int mtu2_timer_stop(void) | |||
| 154 | 154 | ||
| 155 | static int mtu2_timer_init(void) | 155 | static int mtu2_timer_init(void) |
| 156 | { | 156 | { |
| 157 | u8 tmp; | ||
| 158 | unsigned long interval; | 157 | unsigned long interval; |
| 159 | 158 | ||
| 160 | setup_irq(CONFIG_SH_TIMER_IRQ, &mtu2_irq); | 159 | setup_irq(CONFIG_SH_TIMER_IRQ, &mtu2_irq); |
diff --git a/arch/sh/kernel/traps_32.c b/arch/sh/kernel/traps_32.c index 2e58f7a6b746..baa4fa368dce 100644 --- a/arch/sh/kernel/traps_32.c +++ b/arch/sh/kernel/traps_32.c | |||
| @@ -147,6 +147,36 @@ static int die_if_no_fixup(const char * str, struct pt_regs * regs, long err) | |||
| 147 | return -EFAULT; | 147 | return -EFAULT; |
| 148 | } | 148 | } |
| 149 | 149 | ||
| 150 | static inline void sign_extend(unsigned int count, unsigned char *dst) | ||
| 151 | { | ||
| 152 | #ifdef __LITTLE_ENDIAN__ | ||
| 153 | if ((count == 1) && dst[0] & 0x80) { | ||
| 154 | dst[1] = 0xff; | ||
| 155 | dst[2] = 0xff; | ||
| 156 | dst[3] = 0xff; | ||
| 157 | } | ||
| 158 | if ((count == 2) && dst[1] & 0x80) { | ||
| 159 | dst[2] = 0xff; | ||
| 160 | dst[3] = 0xff; | ||
| 161 | } | ||
| 162 | #else | ||
| 163 | if ((count == 1) && dst[3] & 0x80) { | ||
| 164 | dst[2] = 0xff; | ||
| 165 | dst[1] = 0xff; | ||
| 166 | dst[0] = 0xff; | ||
| 167 | } | ||
| 168 | if ((count == 2) && dst[2] & 0x80) { | ||
| 169 | dst[1] = 0xff; | ||
| 170 | dst[0] = 0xff; | ||
| 171 | } | ||
| 172 | #endif | ||
| 173 | } | ||
| 174 | |||
| 175 | static struct mem_access user_mem_access = { | ||
| 176 | copy_from_user, | ||
| 177 | copy_to_user, | ||
| 178 | }; | ||
| 179 | |||
| 150 | /* | 180 | /* |
| 151 | * handle an instruction that does an unaligned memory access by emulating the | 181 | * handle an instruction that does an unaligned memory access by emulating the |
| 152 | * desired behaviour | 182 | * desired behaviour |
| @@ -154,7 +184,8 @@ static int die_if_no_fixup(const char * str, struct pt_regs * regs, long err) | |||
| 154 | * (if that instruction is in a branch delay slot) | 184 | * (if that instruction is in a branch delay slot) |
| 155 | * - return 0 if emulation okay, -EFAULT on existential error | 185 | * - return 0 if emulation okay, -EFAULT on existential error |
| 156 | */ | 186 | */ |
| 157 | static int handle_unaligned_ins(u16 instruction, struct pt_regs *regs) | 187 | static int handle_unaligned_ins(opcode_t instruction, struct pt_regs *regs, |
| 188 | struct mem_access *ma) | ||
| 158 | { | 189 | { |
| 159 | int ret, index, count; | 190 | int ret, index, count; |
| 160 | unsigned long *rm, *rn; | 191 | unsigned long *rm, *rn; |
| @@ -178,25 +209,13 @@ static int handle_unaligned_ins(u16 instruction, struct pt_regs *regs) | |||
| 178 | dst = (unsigned char*) rn; | 209 | dst = (unsigned char*) rn; |
| 179 | *(unsigned long*)dst = 0; | 210 | *(unsigned long*)dst = 0; |
| 180 | 211 | ||
| 181 | #ifdef __LITTLE_ENDIAN__ | 212 | #if !defined(__LITTLE_ENDIAN__) |
| 182 | if (copy_from_user(dst, src, count)) | ||
| 183 | goto fetch_fault; | ||
| 184 | |||
| 185 | if ((count == 2) && dst[1] & 0x80) { | ||
| 186 | dst[2] = 0xff; | ||
| 187 | dst[3] = 0xff; | ||
| 188 | } | ||
| 189 | #else | ||
| 190 | dst += 4-count; | 213 | dst += 4-count; |
| 191 | 214 | #endif | |
| 192 | if (__copy_user(dst, src, count)) | 215 | if (ma->from(dst, src, count)) |
| 193 | goto fetch_fault; | 216 | goto fetch_fault; |
| 194 | 217 | ||
| 195 | if ((count == 2) && dst[2] & 0x80) { | 218 | sign_extend(count, dst); |
| 196 | dst[0] = 0xff; | ||
| 197 | dst[1] = 0xff; | ||
| 198 | } | ||
| 199 | #endif | ||
| 200 | } else { | 219 | } else { |
| 201 | /* to memory */ | 220 | /* to memory */ |
| 202 | src = (unsigned char*) rm; | 221 | src = (unsigned char*) rm; |
| @@ -206,7 +225,7 @@ static int handle_unaligned_ins(u16 instruction, struct pt_regs *regs) | |||
| 206 | dst = (unsigned char*) *rn; | 225 | dst = (unsigned char*) *rn; |
| 207 | dst += regs->regs[0]; | 226 | dst += regs->regs[0]; |
| 208 | 227 | ||
| 209 | if (copy_to_user(dst, src, count)) | 228 | if (ma->to(dst, src, count)) |
| 210 | goto fetch_fault; | 229 | goto fetch_fault; |
| 211 | } | 230 | } |
| 212 | ret = 0; | 231 | ret = 0; |
| @@ -217,7 +236,7 @@ static int handle_unaligned_ins(u16 instruction, struct pt_regs *regs) | |||
| 217 | dst = (unsigned char*) *rn; | 236 | dst = (unsigned char*) *rn; |
| 218 | dst += (instruction&0x000F)<<2; | 237 | dst += (instruction&0x000F)<<2; |
| 219 | 238 | ||
| 220 | if (copy_to_user(dst,src,4)) | 239 | if (ma->to(dst, src, 4)) |
| 221 | goto fetch_fault; | 240 | goto fetch_fault; |
| 222 | ret = 0; | 241 | ret = 0; |
| 223 | break; | 242 | break; |
| @@ -230,7 +249,7 @@ static int handle_unaligned_ins(u16 instruction, struct pt_regs *regs) | |||
| 230 | #if !defined(__LITTLE_ENDIAN__) | 249 | #if !defined(__LITTLE_ENDIAN__) |
| 231 | src += 4-count; | 250 | src += 4-count; |
| 232 | #endif | 251 | #endif |
| 233 | if (copy_to_user(dst, src, count)) | 252 | if (ma->to(dst, src, count)) |
| 234 | goto fetch_fault; | 253 | goto fetch_fault; |
| 235 | ret = 0; | 254 | ret = 0; |
| 236 | break; | 255 | break; |
| @@ -241,7 +260,7 @@ static int handle_unaligned_ins(u16 instruction, struct pt_regs *regs) | |||
| 241 | dst = (unsigned char*) rn; | 260 | dst = (unsigned char*) rn; |
| 242 | *(unsigned long*)dst = 0; | 261 | *(unsigned long*)dst = 0; |
| 243 | 262 | ||
| 244 | if (copy_from_user(dst,src,4)) | 263 | if (ma->from(dst, src, 4)) |
| 245 | goto fetch_fault; | 264 | goto fetch_fault; |
| 246 | ret = 0; | 265 | ret = 0; |
| 247 | break; | 266 | break; |
| @@ -253,25 +272,12 @@ static int handle_unaligned_ins(u16 instruction, struct pt_regs *regs) | |||
| 253 | dst = (unsigned char*) rn; | 272 | dst = (unsigned char*) rn; |
| 254 | *(unsigned long*)dst = 0; | 273 | *(unsigned long*)dst = 0; |
| 255 | 274 | ||
| 256 | #ifdef __LITTLE_ENDIAN__ | 275 | #if !defined(__LITTLE_ENDIAN__) |
| 257 | if (copy_from_user(dst, src, count)) | ||
| 258 | goto fetch_fault; | ||
| 259 | |||
| 260 | if ((count == 2) && dst[1] & 0x80) { | ||
| 261 | dst[2] = 0xff; | ||
| 262 | dst[3] = 0xff; | ||
| 263 | } | ||
| 264 | #else | ||
| 265 | dst += 4-count; | 276 | dst += 4-count; |
| 266 | |||
| 267 | if (copy_from_user(dst, src, count)) | ||
| 268 | goto fetch_fault; | ||
| 269 | |||
| 270 | if ((count == 2) && dst[2] & 0x80) { | ||
| 271 | dst[0] = 0xff; | ||
| 272 | dst[1] = 0xff; | ||
| 273 | } | ||
| 274 | #endif | 277 | #endif |
| 278 | if (ma->from(dst, src, count)) | ||
| 279 | goto fetch_fault; | ||
| 280 | sign_extend(count, dst); | ||
| 275 | ret = 0; | 281 | ret = 0; |
| 276 | break; | 282 | break; |
| 277 | 283 | ||
| @@ -285,7 +291,7 @@ static int handle_unaligned_ins(u16 instruction, struct pt_regs *regs) | |||
| 285 | dst = (unsigned char*) *rm; /* called Rn in the spec */ | 291 | dst = (unsigned char*) *rm; /* called Rn in the spec */ |
| 286 | dst += (instruction&0x000F)<<1; | 292 | dst += (instruction&0x000F)<<1; |
| 287 | 293 | ||
| 288 | if (copy_to_user(dst, src, 2)) | 294 | if (ma->to(dst, src, 2)) |
| 289 | goto fetch_fault; | 295 | goto fetch_fault; |
| 290 | ret = 0; | 296 | ret = 0; |
| 291 | break; | 297 | break; |
| @@ -299,21 +305,9 @@ static int handle_unaligned_ins(u16 instruction, struct pt_regs *regs) | |||
| 299 | #if !defined(__LITTLE_ENDIAN__) | 305 | #if !defined(__LITTLE_ENDIAN__) |
| 300 | dst += 2; | 306 | dst += 2; |
| 301 | #endif | 307 | #endif |
| 302 | 308 | if (ma->from(dst, src, 2)) | |
| 303 | if (copy_from_user(dst, src, 2)) | ||
| 304 | goto fetch_fault; | 309 | goto fetch_fault; |
| 305 | 310 | sign_extend(2, dst); | |
| 306 | #ifdef __LITTLE_ENDIAN__ | ||
| 307 | if (dst[1] & 0x80) { | ||
| 308 | dst[2] = 0xff; | ||
| 309 | dst[3] = 0xff; | ||
| 310 | } | ||
| 311 | #else | ||
| 312 | if (dst[2] & 0x80) { | ||
| 313 | dst[0] = 0xff; | ||
| 314 | dst[1] = 0xff; | ||
| 315 | } | ||
| 316 | #endif | ||
| 317 | ret = 0; | 311 | ret = 0; |
| 318 | break; | 312 | break; |
| 319 | } | 313 | } |
| @@ -332,11 +326,14 @@ static int handle_unaligned_ins(u16 instruction, struct pt_regs *regs) | |||
| 332 | * emulate the instruction in the delay slot | 326 | * emulate the instruction in the delay slot |
| 333 | * - fetches the instruction from PC+2 | 327 | * - fetches the instruction from PC+2 |
| 334 | */ | 328 | */ |
| 335 | static inline int handle_unaligned_delayslot(struct pt_regs *regs) | 329 | static inline int handle_delayslot(struct pt_regs *regs, |
| 330 | opcode_t old_instruction, | ||
| 331 | struct mem_access *ma) | ||
| 336 | { | 332 | { |
| 337 | u16 instruction; | 333 | opcode_t instruction; |
| 334 | void *addr = (void *)(regs->pc + instruction_size(old_instruction)); | ||
| 338 | 335 | ||
| 339 | if (copy_from_user(&instruction, (u16 *)(regs->pc+2), 2)) { | 336 | if (copy_from_user(&instruction, addr, sizeof(instruction))) { |
| 340 | /* the instruction-fetch faulted */ | 337 | /* the instruction-fetch faulted */ |
| 341 | if (user_mode(regs)) | 338 | if (user_mode(regs)) |
| 342 | return -EFAULT; | 339 | return -EFAULT; |
| @@ -346,7 +343,7 @@ static inline int handle_unaligned_delayslot(struct pt_regs *regs) | |||
| 346 | regs, 0); | 343 | regs, 0); |
| 347 | } | 344 | } |
| 348 | 345 | ||
| 349 | return handle_unaligned_ins(instruction,regs); | 346 | return handle_unaligned_ins(instruction, regs, ma); |
| 350 | } | 347 | } |
| 351 | 348 | ||
| 352 | /* | 349 | /* |
| @@ -369,10 +366,11 @@ static inline int handle_unaligned_delayslot(struct pt_regs *regs) | |||
| 369 | * XXX: SH-2A needs this too, but it needs an overhaul thanks to mixed 32-bit | 366 | * XXX: SH-2A needs this too, but it needs an overhaul thanks to mixed 32-bit |
| 370 | * opcodes.. | 367 | * opcodes.. |
| 371 | */ | 368 | */ |
| 372 | #ifndef CONFIG_CPU_SH2A | 369 | |
| 373 | static int handle_unaligned_notify_count = 10; | 370 | static int handle_unaligned_notify_count = 10; |
| 374 | 371 | ||
| 375 | static int handle_unaligned_access(u16 instruction, struct pt_regs *regs) | 372 | int handle_unaligned_access(opcode_t instruction, struct pt_regs *regs, |
| 373 | struct mem_access *ma) | ||
| 376 | { | 374 | { |
| 377 | u_int rm; | 375 | u_int rm; |
| 378 | int ret, index; | 376 | int ret, index; |
| @@ -387,7 +385,7 @@ static int handle_unaligned_access(u16 instruction, struct pt_regs *regs) | |||
| 387 | printk(KERN_NOTICE "Fixing up unaligned userspace access " | 385 | printk(KERN_NOTICE "Fixing up unaligned userspace access " |
| 388 | "in \"%s\" pid=%d pc=0x%p ins=0x%04hx\n", | 386 | "in \"%s\" pid=%d pc=0x%p ins=0x%04hx\n", |
| 389 | current->comm, task_pid_nr(current), | 387 | current->comm, task_pid_nr(current), |
| 390 | (u16 *)regs->pc, instruction); | 388 | (void *)regs->pc, instruction); |
| 391 | } | 389 | } |
| 392 | 390 | ||
| 393 | ret = -EFAULT; | 391 | ret = -EFAULT; |
| @@ -395,19 +393,19 @@ static int handle_unaligned_access(u16 instruction, struct pt_regs *regs) | |||
| 395 | case 0x0000: | 393 | case 0x0000: |
| 396 | if (instruction==0x000B) { | 394 | if (instruction==0x000B) { |
| 397 | /* rts */ | 395 | /* rts */ |
| 398 | ret = handle_unaligned_delayslot(regs); | 396 | ret = handle_delayslot(regs, instruction, ma); |
| 399 | if (ret==0) | 397 | if (ret==0) |
| 400 | regs->pc = regs->pr; | 398 | regs->pc = regs->pr; |
| 401 | } | 399 | } |
| 402 | else if ((instruction&0x00FF)==0x0023) { | 400 | else if ((instruction&0x00FF)==0x0023) { |
| 403 | /* braf @Rm */ | 401 | /* braf @Rm */ |
| 404 | ret = handle_unaligned_delayslot(regs); | 402 | ret = handle_delayslot(regs, instruction, ma); |
| 405 | if (ret==0) | 403 | if (ret==0) |
| 406 | regs->pc += rm + 4; | 404 | regs->pc += rm + 4; |
| 407 | } | 405 | } |
| 408 | else if ((instruction&0x00FF)==0x0003) { | 406 | else if ((instruction&0x00FF)==0x0003) { |
| 409 | /* bsrf @Rm */ | 407 | /* bsrf @Rm */ |
| 410 | ret = handle_unaligned_delayslot(regs); | 408 | ret = handle_delayslot(regs, instruction, ma); |
| 411 | if (ret==0) { | 409 | if (ret==0) { |
| 412 | regs->pr = regs->pc + 4; | 410 | regs->pr = regs->pc + 4; |
| 413 | regs->pc += rm + 4; | 411 | regs->pc += rm + 4; |
| @@ -428,13 +426,13 @@ static int handle_unaligned_access(u16 instruction, struct pt_regs *regs) | |||
| 428 | case 0x4000: | 426 | case 0x4000: |
| 429 | if ((instruction&0x00FF)==0x002B) { | 427 | if ((instruction&0x00FF)==0x002B) { |
| 430 | /* jmp @Rm */ | 428 | /* jmp @Rm */ |
| 431 | ret = handle_unaligned_delayslot(regs); | 429 | ret = handle_delayslot(regs, instruction, ma); |
| 432 | if (ret==0) | 430 | if (ret==0) |
| 433 | regs->pc = rm; | 431 | regs->pc = rm; |
| 434 | } | 432 | } |
| 435 | else if ((instruction&0x00FF)==0x000B) { | 433 | else if ((instruction&0x00FF)==0x000B) { |
| 436 | /* jsr @Rm */ | 434 | /* jsr @Rm */ |
| 437 | ret = handle_unaligned_delayslot(regs); | 435 | ret = handle_delayslot(regs, instruction, ma); |
| 438 | if (ret==0) { | 436 | if (ret==0) { |
| 439 | regs->pr = regs->pc + 4; | 437 | regs->pr = regs->pc + 4; |
| 440 | regs->pc = rm; | 438 | regs->pc = rm; |
| @@ -461,7 +459,7 @@ static int handle_unaligned_access(u16 instruction, struct pt_regs *regs) | |||
| 461 | case 0x0B00: /* bf lab - no delayslot*/ | 459 | case 0x0B00: /* bf lab - no delayslot*/ |
| 462 | break; | 460 | break; |
| 463 | case 0x0F00: /* bf/s lab */ | 461 | case 0x0F00: /* bf/s lab */ |
| 464 | ret = handle_unaligned_delayslot(regs); | 462 | ret = handle_delayslot(regs, instruction, ma); |
| 465 | if (ret==0) { | 463 | if (ret==0) { |
| 466 | #if defined(CONFIG_CPU_SH4) || defined(CONFIG_SH7705_CACHE_32KB) | 464 | #if defined(CONFIG_CPU_SH4) || defined(CONFIG_SH7705_CACHE_32KB) |
| 467 | if ((regs->sr & 0x00000001) != 0) | 465 | if ((regs->sr & 0x00000001) != 0) |
| @@ -474,7 +472,7 @@ static int handle_unaligned_access(u16 instruction, struct pt_regs *regs) | |||
| 474 | case 0x0900: /* bt lab - no delayslot */ | 472 | case 0x0900: /* bt lab - no delayslot */ |
| 475 | break; | 473 | break; |
| 476 | case 0x0D00: /* bt/s lab */ | 474 | case 0x0D00: /* bt/s lab */ |
| 477 | ret = handle_unaligned_delayslot(regs); | 475 | ret = handle_delayslot(regs, instruction, ma); |
| 478 | if (ret==0) { | 476 | if (ret==0) { |
| 479 | #if defined(CONFIG_CPU_SH4) || defined(CONFIG_SH7705_CACHE_32KB) | 477 | #if defined(CONFIG_CPU_SH4) || defined(CONFIG_SH7705_CACHE_32KB) |
| 480 | if ((regs->sr & 0x00000001) == 0) | 478 | if ((regs->sr & 0x00000001) == 0) |
| @@ -488,13 +486,13 @@ static int handle_unaligned_access(u16 instruction, struct pt_regs *regs) | |||
| 488 | break; | 486 | break; |
| 489 | 487 | ||
| 490 | case 0xA000: /* bra label */ | 488 | case 0xA000: /* bra label */ |
| 491 | ret = handle_unaligned_delayslot(regs); | 489 | ret = handle_delayslot(regs, instruction, ma); |
| 492 | if (ret==0) | 490 | if (ret==0) |
| 493 | regs->pc += SH_PC_12BIT_OFFSET(instruction); | 491 | regs->pc += SH_PC_12BIT_OFFSET(instruction); |
| 494 | break; | 492 | break; |
| 495 | 493 | ||
| 496 | case 0xB000: /* bsr label */ | 494 | case 0xB000: /* bsr label */ |
| 497 | ret = handle_unaligned_delayslot(regs); | 495 | ret = handle_delayslot(regs, instruction, ma); |
| 498 | if (ret==0) { | 496 | if (ret==0) { |
| 499 | regs->pr = regs->pc + 4; | 497 | regs->pr = regs->pc + 4; |
| 500 | regs->pc += SH_PC_12BIT_OFFSET(instruction); | 498 | regs->pc += SH_PC_12BIT_OFFSET(instruction); |
| @@ -505,12 +503,11 @@ static int handle_unaligned_access(u16 instruction, struct pt_regs *regs) | |||
| 505 | 503 | ||
| 506 | /* handle non-delay-slot instruction */ | 504 | /* handle non-delay-slot instruction */ |
| 507 | simple: | 505 | simple: |
| 508 | ret = handle_unaligned_ins(instruction,regs); | 506 | ret = handle_unaligned_ins(instruction, regs, ma); |
| 509 | if (ret==0) | 507 | if (ret==0) |
| 510 | regs->pc += instruction_size(instruction); | 508 | regs->pc += instruction_size(instruction); |
| 511 | return ret; | 509 | return ret; |
| 512 | } | 510 | } |
| 513 | #endif /* CONFIG_CPU_SH2A */ | ||
| 514 | 511 | ||
| 515 | #ifdef CONFIG_CPU_HAS_SR_RB | 512 | #ifdef CONFIG_CPU_HAS_SR_RB |
| 516 | #define lookup_exception_vector(x) \ | 513 | #define lookup_exception_vector(x) \ |
| @@ -538,10 +535,8 @@ asmlinkage void do_address_error(struct pt_regs *regs, | |||
| 538 | unsigned long error_code = 0; | 535 | unsigned long error_code = 0; |
| 539 | mm_segment_t oldfs; | 536 | mm_segment_t oldfs; |
| 540 | siginfo_t info; | 537 | siginfo_t info; |
| 541 | #ifndef CONFIG_CPU_SH2A | 538 | opcode_t instruction; |
| 542 | u16 instruction; | ||
| 543 | int tmp; | 539 | int tmp; |
| 544 | #endif | ||
| 545 | 540 | ||
| 546 | /* Intentional ifdef */ | 541 | /* Intentional ifdef */ |
| 547 | #ifdef CONFIG_CPU_HAS_SR_RB | 542 | #ifdef CONFIG_CPU_HAS_SR_RB |
| @@ -561,9 +556,9 @@ asmlinkage void do_address_error(struct pt_regs *regs, | |||
| 561 | goto uspace_segv; | 556 | goto uspace_segv; |
| 562 | } | 557 | } |
| 563 | 558 | ||
| 564 | #ifndef CONFIG_CPU_SH2A | ||
| 565 | set_fs(USER_DS); | 559 | set_fs(USER_DS); |
| 566 | if (copy_from_user(&instruction, (u16 *)(regs->pc), 2)) { | 560 | if (copy_from_user(&instruction, (void *)(regs->pc), |
| 561 | sizeof(instruction))) { | ||
| 567 | /* Argh. Fault on the instruction itself. | 562 | /* Argh. Fault on the instruction itself. |
| 568 | This should never happen non-SMP | 563 | This should never happen non-SMP |
| 569 | */ | 564 | */ |
| @@ -571,13 +566,12 @@ asmlinkage void do_address_error(struct pt_regs *regs, | |||
| 571 | goto uspace_segv; | 566 | goto uspace_segv; |
| 572 | } | 567 | } |
| 573 | 568 | ||
| 574 | tmp = handle_unaligned_access(instruction, regs); | 569 | tmp = handle_unaligned_access(instruction, regs, |
| 570 | &user_mem_access); | ||
| 575 | set_fs(oldfs); | 571 | set_fs(oldfs); |
| 576 | 572 | ||
| 577 | if (tmp==0) | 573 | if (tmp==0) |
| 578 | return; /* sorted */ | 574 | return; /* sorted */ |
| 579 | #endif | ||
| 580 | |||
| 581 | uspace_segv: | 575 | uspace_segv: |
| 582 | printk(KERN_NOTICE "Sending SIGBUS to \"%s\" due to unaligned " | 576 | printk(KERN_NOTICE "Sending SIGBUS to \"%s\" due to unaligned " |
| 583 | "access (PC %lx PR %lx)\n", current->comm, regs->pc, | 577 | "access (PC %lx PR %lx)\n", current->comm, regs->pc, |
| @@ -592,9 +586,9 @@ uspace_segv: | |||
| 592 | if (regs->pc & 1) | 586 | if (regs->pc & 1) |
| 593 | die("unaligned program counter", regs, error_code); | 587 | die("unaligned program counter", regs, error_code); |
| 594 | 588 | ||
| 595 | #ifndef CONFIG_CPU_SH2A | ||
| 596 | set_fs(KERNEL_DS); | 589 | set_fs(KERNEL_DS); |
| 597 | if (copy_from_user(&instruction, (u16 *)(regs->pc), 2)) { | 590 | if (copy_from_user(&instruction, (void *)(regs->pc), |
| 591 | sizeof(instruction))) { | ||
| 598 | /* Argh. Fault on the instruction itself. | 592 | /* Argh. Fault on the instruction itself. |
| 599 | This should never happen non-SMP | 593 | This should never happen non-SMP |
| 600 | */ | 594 | */ |
| @@ -602,14 +596,8 @@ uspace_segv: | |||
| 602 | die("insn faulting in do_address_error", regs, 0); | 596 | die("insn faulting in do_address_error", regs, 0); |
| 603 | } | 597 | } |
| 604 | 598 | ||
| 605 | handle_unaligned_access(instruction, regs); | 599 | handle_unaligned_access(instruction, regs, &user_mem_access); |
| 606 | set_fs(oldfs); | 600 | set_fs(oldfs); |
| 607 | #else | ||
| 608 | printk(KERN_NOTICE "Killing process \"%s\" due to unaligned " | ||
| 609 | "access\n", current->comm); | ||
| 610 | |||
| 611 | force_sig(SIGSEGV, current); | ||
| 612 | #endif | ||
| 613 | } | 601 | } |
| 614 | } | 602 | } |
| 615 | 603 | ||
diff --git a/arch/sh/kernel/traps_64.c b/arch/sh/kernel/traps_64.c index c0b3c6f6edb5..a55ac81d795b 100644 --- a/arch/sh/kernel/traps_64.c +++ b/arch/sh/kernel/traps_64.c | |||
| @@ -630,7 +630,7 @@ static int misaligned_fpu_load(struct pt_regs *regs, | |||
| 630 | current->thread.fpu.hard.fp_regs[destreg] = buflo; | 630 | current->thread.fpu.hard.fp_regs[destreg] = buflo; |
| 631 | current->thread.fpu.hard.fp_regs[destreg+1] = bufhi; | 631 | current->thread.fpu.hard.fp_regs[destreg+1] = bufhi; |
| 632 | } else { | 632 | } else { |
| 633 | #if defined(CONFIG_LITTLE_ENDIAN) | 633 | #if defined(CONFIG_CPU_LITTLE_ENDIAN) |
| 634 | current->thread.fpu.hard.fp_regs[destreg] = bufhi; | 634 | current->thread.fpu.hard.fp_regs[destreg] = bufhi; |
| 635 | current->thread.fpu.hard.fp_regs[destreg+1] = buflo; | 635 | current->thread.fpu.hard.fp_regs[destreg+1] = buflo; |
| 636 | #else | 636 | #else |
| @@ -700,7 +700,7 @@ static int misaligned_fpu_store(struct pt_regs *regs, | |||
| 700 | buflo = current->thread.fpu.hard.fp_regs[srcreg]; | 700 | buflo = current->thread.fpu.hard.fp_regs[srcreg]; |
| 701 | bufhi = current->thread.fpu.hard.fp_regs[srcreg+1]; | 701 | bufhi = current->thread.fpu.hard.fp_regs[srcreg+1]; |
| 702 | } else { | 702 | } else { |
| 703 | #if defined(CONFIG_LITTLE_ENDIAN) | 703 | #if defined(CONFIG_CPU_LITTLE_ENDIAN) |
| 704 | bufhi = current->thread.fpu.hard.fp_regs[srcreg]; | 704 | bufhi = current->thread.fpu.hard.fp_regs[srcreg]; |
| 705 | buflo = current->thread.fpu.hard.fp_regs[srcreg+1]; | 705 | buflo = current->thread.fpu.hard.fp_regs[srcreg+1]; |
| 706 | #else | 706 | #else |
diff --git a/arch/sh/kernel/vmlinux_64.lds.S b/arch/sh/kernel/vmlinux_64.lds.S index 3f1bd6392bb3..d1e177009a41 100644 --- a/arch/sh/kernel/vmlinux_64.lds.S +++ b/arch/sh/kernel/vmlinux_64.lds.S | |||
| @@ -51,7 +51,7 @@ SECTIONS | |||
| 51 | KPROBES_TEXT | 51 | KPROBES_TEXT |
| 52 | *(.fixup) | 52 | *(.fixup) |
| 53 | *(.gnu.warning) | 53 | *(.gnu.warning) |
| 54 | #ifdef CONFIG_LITTLE_ENDIAN | 54 | #ifdef CONFIG_CPU_LITTLE_ENDIAN |
| 55 | } = 0x6ff0fff0 | 55 | } = 0x6ff0fff0 |
| 56 | #else | 56 | #else |
| 57 | } = 0xf0fff06f | 57 | } = 0xf0fff06f |
diff --git a/arch/sh/mm/cache-sh5.c b/arch/sh/mm/cache-sh5.c index 4617e3aeee73..3877321fcede 100644 --- a/arch/sh/mm/cache-sh5.c +++ b/arch/sh/mm/cache-sh5.c | |||
| @@ -1,10 +1,10 @@ | |||
| 1 | /* | 1 | /* |
| 2 | * arch/sh/mm/cache-sh5.c | 2 | * arch/sh/mm/cache-sh5.c |
| 3 | * | 3 | * |
| 4 | * Original version Copyright (C) 2000, 2001 Paolo Alberelli | 4 | * Copyright (C) 2000, 2001 Paolo Alberelli |
| 5 | * Second version Copyright (C) benedict.gaster@superh.com 2002 | 5 | * Copyright (C) 2002 Benedict Gaster |
| 6 | * Third version Copyright Richard.Curnow@superh.com 2003 | 6 | * Copyright (C) 2003 Richard Curnow |
| 7 | * Hacks to third version Copyright (C) 2003 Paul Mundt | 7 | * Copyright (C) 2003 - 2008 Paul Mundt |
| 8 | * | 8 | * |
| 9 | * This file is subject to the terms and conditions of the GNU General Public | 9 | * This file is subject to the terms and conditions of the GNU General Public |
| 10 | * License. See the file "COPYING" in the main directory of this archive | 10 | * License. See the file "COPYING" in the main directory of this archive |
| @@ -13,101 +13,20 @@ | |||
| 13 | #include <linux/init.h> | 13 | #include <linux/init.h> |
| 14 | #include <linux/mman.h> | 14 | #include <linux/mman.h> |
| 15 | #include <linux/mm.h> | 15 | #include <linux/mm.h> |
| 16 | #include <linux/threads.h> | 16 | #include <asm/tlb.h> |
| 17 | #include <asm/page.h> | ||
| 18 | #include <asm/pgtable.h> | ||
| 19 | #include <asm/processor.h> | 17 | #include <asm/processor.h> |
| 20 | #include <asm/cache.h> | 18 | #include <asm/cache.h> |
| 21 | #include <asm/tlb.h> | 19 | #include <asm/pgalloc.h> |
| 22 | #include <asm/io.h> | ||
| 23 | #include <asm/uaccess.h> | 20 | #include <asm/uaccess.h> |
| 24 | #include <asm/mmu_context.h> | 21 | #include <asm/mmu_context.h> |
| 25 | #include <asm/pgalloc.h> /* for flush_itlb_range */ | ||
| 26 | |||
| 27 | #include <linux/proc_fs.h> | ||
| 28 | |||
| 29 | /* This function is in entry.S */ | ||
| 30 | extern unsigned long switch_and_save_asid(unsigned long new_asid); | ||
| 31 | 22 | ||
| 32 | /* Wired TLB entry for the D-cache */ | 23 | /* Wired TLB entry for the D-cache */ |
| 33 | static unsigned long long dtlb_cache_slot; | 24 | static unsigned long long dtlb_cache_slot; |
| 34 | 25 | ||
| 35 | /** | 26 | void __init p3_cache_init(void) |
| 36 | * sh64_cache_init() | ||
| 37 | * | ||
| 38 | * This is pretty much just a straightforward clone of the SH | ||
| 39 | * detect_cpu_and_cache_system(). | ||
| 40 | * | ||
| 41 | * This function is responsible for setting up all of the cache | ||
| 42 | * info dynamically as well as taking care of CPU probing and | ||
| 43 | * setting up the relevant subtype data. | ||
| 44 | * | ||
| 45 | * FIXME: For the time being, we only really support the SH5-101 | ||
| 46 | * out of the box, and don't support dynamic probing for things | ||
| 47 | * like the SH5-103 or even cut2 of the SH5-101. Implement this | ||
| 48 | * later! | ||
| 49 | */ | ||
| 50 | int __init sh64_cache_init(void) | ||
| 51 | { | 27 | { |
| 52 | /* | 28 | /* Reserve a slot for dcache colouring in the DTLB */ |
| 53 | * First, setup some sane values for the I-cache. | 29 | dtlb_cache_slot = sh64_get_wired_dtlb_entry(); |
| 54 | */ | ||
| 55 | cpu_data->icache.ways = 4; | ||
| 56 | cpu_data->icache.sets = 256; | ||
| 57 | cpu_data->icache.linesz = L1_CACHE_BYTES; | ||
| 58 | |||
| 59 | /* | ||
| 60 | * FIXME: This can probably be cleaned up a bit as well.. for example, | ||
| 61 | * do we really need the way shift _and_ the way_step_shift ?? Judging | ||
| 62 | * by the existing code, I would guess no.. is there any valid reason | ||
| 63 | * why we need to be tracking this around? | ||
| 64 | */ | ||
| 65 | cpu_data->icache.way_shift = 13; | ||
| 66 | cpu_data->icache.entry_shift = 5; | ||
| 67 | cpu_data->icache.set_shift = 4; | ||
| 68 | cpu_data->icache.way_step_shift = 16; | ||
| 69 | cpu_data->icache.asid_shift = 2; | ||
| 70 | |||
| 71 | /* | ||
| 72 | * way offset = cache size / associativity, so just don't factor in | ||
| 73 | * associativity in the first place.. | ||
| 74 | */ | ||
| 75 | cpu_data->icache.way_ofs = cpu_data->icache.sets * | ||
| 76 | cpu_data->icache.linesz; | ||
| 77 | |||
| 78 | cpu_data->icache.asid_mask = 0x3fc; | ||
| 79 | cpu_data->icache.idx_mask = 0x1fe0; | ||
| 80 | cpu_data->icache.epn_mask = 0xffffe000; | ||
| 81 | cpu_data->icache.flags = 0; | ||
| 82 | |||
| 83 | /* | ||
| 84 | * Next, setup some sane values for the D-cache. | ||
| 85 | * | ||
| 86 | * On the SH5, these are pretty consistent with the I-cache settings, | ||
| 87 | * so we just copy over the existing definitions.. these can be fixed | ||
| 88 | * up later, especially if we add runtime CPU probing. | ||
| 89 | * | ||
| 90 | * Though in the meantime it saves us from having to duplicate all of | ||
| 91 | * the above definitions.. | ||
| 92 | */ | ||
| 93 | cpu_data->dcache = cpu_data->icache; | ||
| 94 | |||
| 95 | /* | ||
| 96 | * Setup any cache-related flags here | ||
| 97 | */ | ||
| 98 | #if defined(CONFIG_DCACHE_WRITE_THROUGH) | ||
| 99 | set_bit(SH_CACHE_MODE_WT, &(cpu_data->dcache.flags)); | ||
| 100 | #elif defined(CONFIG_DCACHE_WRITE_BACK) | ||
| 101 | set_bit(SH_CACHE_MODE_WB, &(cpu_data->dcache.flags)); | ||
| 102 | #endif | ||
| 103 | |||
| 104 | /* | ||
| 105 | * We also need to reserve a slot for the D-cache in the DTLB, so we | ||
| 106 | * do this now .. | ||
| 107 | */ | ||
| 108 | dtlb_cache_slot = sh64_get_wired_dtlb_entry(); | ||
| 109 | |||
| 110 | return 0; | ||
| 111 | } | 30 | } |
| 112 | 31 | ||
| 113 | #ifdef CONFIG_DCACHE_DISABLED | 32 | #ifdef CONFIG_DCACHE_DISABLED |
| @@ -116,73 +35,48 @@ int __init sh64_cache_init(void) | |||
| 116 | #define sh64_dcache_purge_user_range(mm, start, end) do { } while (0) | 35 | #define sh64_dcache_purge_user_range(mm, start, end) do { } while (0) |
| 117 | #define sh64_dcache_purge_phy_page(paddr) do { } while (0) | 36 | #define sh64_dcache_purge_phy_page(paddr) do { } while (0) |
| 118 | #define sh64_dcache_purge_virt_page(mm, eaddr) do { } while (0) | 37 | #define sh64_dcache_purge_virt_page(mm, eaddr) do { } while (0) |
| 119 | #define sh64_dcache_purge_kernel_range(start, end) do { } while (0) | ||
| 120 | #define sh64_dcache_wback_current_user_range(start, end) do { } while (0) | ||
| 121 | #endif | 38 | #endif |
| 122 | 39 | ||
| 123 | /*##########################################################################*/ | 40 | /* |
| 124 | 41 | * The following group of functions deal with mapping and unmapping a | |
| 125 | /* From here onwards, a rewrite of the implementation, | 42 | * temporary page into a DTLB slot that has been set aside for exclusive |
| 126 | by Richard.Curnow@superh.com. | 43 | * use. |
| 127 | 44 | */ | |
| 128 | The major changes in this compared to the old version are; | 45 | static inline void |
| 129 | 1. use more selective purging through OCBP instead of using ALLOCO to purge | 46 | sh64_setup_dtlb_cache_slot(unsigned long eaddr, unsigned long asid, |
| 130 | by natural replacement. This avoids purging out unrelated cache lines | 47 | unsigned long paddr) |
| 131 | that happen to be in the same set. | ||
| 132 | 2. exploit the APIs copy_user_page and clear_user_page better | ||
| 133 | 3. be more selective about I-cache purging, in particular use invalidate_all | ||
| 134 | more sparingly. | ||
| 135 | |||
| 136 | */ | ||
| 137 | |||
| 138 | /*########################################################################## | ||
| 139 | SUPPORT FUNCTIONS | ||
| 140 | ##########################################################################*/ | ||
| 141 | |||
| 142 | /****************************************************************************/ | ||
| 143 | /* The following group of functions deal with mapping and unmapping a temporary | ||
| 144 | page into the DTLB slot that have been set aside for our exclusive use. */ | ||
| 145 | /* In order to accomplish this, we use the generic interface for adding and | ||
| 146 | removing a wired slot entry as defined in arch/sh/mm/tlb-sh5.c */ | ||
| 147 | /****************************************************************************/ | ||
| 148 | |||
| 149 | static unsigned long slot_own_flags; | ||
| 150 | |||
| 151 | static inline void sh64_setup_dtlb_cache_slot(unsigned long eaddr, unsigned long asid, unsigned long paddr) | ||
| 152 | { | 48 | { |
| 153 | local_irq_save(slot_own_flags); | 49 | local_irq_disable(); |
| 154 | sh64_setup_tlb_slot(dtlb_cache_slot, eaddr, asid, paddr); | 50 | sh64_setup_tlb_slot(dtlb_cache_slot, eaddr, asid, paddr); |
| 155 | } | 51 | } |
| 156 | 52 | ||
| 157 | static inline void sh64_teardown_dtlb_cache_slot(void) | 53 | static inline void sh64_teardown_dtlb_cache_slot(void) |
| 158 | { | 54 | { |
| 159 | sh64_teardown_tlb_slot(dtlb_cache_slot); | 55 | sh64_teardown_tlb_slot(dtlb_cache_slot); |
| 160 | local_irq_restore(slot_own_flags); | 56 | local_irq_enable(); |
| 161 | } | 57 | } |
| 162 | 58 | ||
| 163 | /****************************************************************************/ | ||
| 164 | |||
| 165 | #ifndef CONFIG_ICACHE_DISABLED | 59 | #ifndef CONFIG_ICACHE_DISABLED |
| 166 | 60 | static inline void sh64_icache_inv_all(void) | |
| 167 | static void __inline__ sh64_icache_inv_all(void) | ||
| 168 | { | 61 | { |
| 169 | unsigned long long addr, flag, data; | 62 | unsigned long long addr, flag, data; |
| 170 | unsigned int flags; | 63 | unsigned int flags; |
| 171 | 64 | ||
| 172 | addr=ICCR0; | 65 | addr = ICCR0; |
| 173 | flag=ICCR0_ICI; | 66 | flag = ICCR0_ICI; |
| 174 | data=0; | 67 | data = 0; |
| 175 | 68 | ||
| 176 | /* Make this a critical section for safety (probably not strictly necessary.) */ | 69 | /* Make this a critical section for safety (probably not strictly necessary.) */ |
| 177 | local_irq_save(flags); | 70 | local_irq_save(flags); |
| 178 | 71 | ||
| 179 | /* Without %1 it gets unexplicably wrong */ | 72 | /* Without %1 it gets unexplicably wrong */ |
| 180 | asm volatile("getcfg %3, 0, %0\n\t" | 73 | __asm__ __volatile__ ( |
| 181 | "or %0, %2, %0\n\t" | 74 | "getcfg %3, 0, %0\n\t" |
| 182 | "putcfg %3, 0, %0\n\t" | 75 | "or %0, %2, %0\n\t" |
| 183 | "synci" | 76 | "putcfg %3, 0, %0\n\t" |
| 184 | : "=&r" (data) | 77 | "synci" |
| 185 | : "0" (data), "r" (flag), "r" (addr)); | 78 | : "=&r" (data) |
| 79 | : "0" (data), "r" (flag), "r" (addr)); | ||
| 186 | 80 | ||
| 187 | local_irq_restore(flags); | 81 | local_irq_restore(flags); |
| 188 | } | 82 | } |
| @@ -193,20 +87,12 @@ static void sh64_icache_inv_kernel_range(unsigned long start, unsigned long end) | |||
| 193 | * the addresses lie in the kernel superpage. */ | 87 | * the addresses lie in the kernel superpage. */ |
| 194 | 88 | ||
| 195 | unsigned long long ullend, addr, aligned_start; | 89 | unsigned long long ullend, addr, aligned_start; |
| 196 | #if (NEFF == 32) | ||
| 197 | aligned_start = (unsigned long long)(signed long long)(signed long) start; | 90 | aligned_start = (unsigned long long)(signed long long)(signed long) start; |
| 198 | #else | 91 | addr = L1_CACHE_ALIGN(aligned_start); |
| 199 | #error "NEFF != 32" | ||
| 200 | #endif | ||
| 201 | aligned_start &= L1_CACHE_ALIGN_MASK; | ||
| 202 | addr = aligned_start; | ||
| 203 | #if (NEFF == 32) | ||
| 204 | ullend = (unsigned long long) (signed long long) (signed long) end; | 92 | ullend = (unsigned long long) (signed long long) (signed long) end; |
| 205 | #else | 93 | |
| 206 | #error "NEFF != 32" | ||
| 207 | #endif | ||
| 208 | while (addr <= ullend) { | 94 | while (addr <= ullend) { |
| 209 | asm __volatile__ ("icbi %0, 0" : : "r" (addr)); | 95 | __asm__ __volatile__ ("icbi %0, 0" : : "r" (addr)); |
| 210 | addr += L1_CACHE_BYTES; | 96 | addr += L1_CACHE_BYTES; |
| 211 | } | 97 | } |
| 212 | } | 98 | } |
| @@ -215,7 +101,7 @@ static void sh64_icache_inv_user_page(struct vm_area_struct *vma, unsigned long | |||
| 215 | { | 101 | { |
| 216 | /* If we get called, we know that vma->vm_flags contains VM_EXEC. | 102 | /* If we get called, we know that vma->vm_flags contains VM_EXEC. |
| 217 | Also, eaddr is page-aligned. */ | 103 | Also, eaddr is page-aligned. */ |
| 218 | 104 | unsigned int cpu = smp_processor_id(); | |
| 219 | unsigned long long addr, end_addr; | 105 | unsigned long long addr, end_addr; |
| 220 | unsigned long flags = 0; | 106 | unsigned long flags = 0; |
| 221 | unsigned long running_asid, vma_asid; | 107 | unsigned long running_asid, vma_asid; |
| @@ -237,17 +123,17 @@ static void sh64_icache_inv_user_page(struct vm_area_struct *vma, unsigned long | |||
| 237 | */ | 123 | */ |
| 238 | 124 | ||
| 239 | running_asid = get_asid(); | 125 | running_asid = get_asid(); |
| 240 | vma_asid = (vma->vm_mm->context & MMU_CONTEXT_ASID_MASK); | 126 | vma_asid = cpu_asid(cpu, vma->vm_mm); |
| 241 | if (running_asid != vma_asid) { | 127 | if (running_asid != vma_asid) { |
| 242 | local_irq_save(flags); | 128 | local_irq_save(flags); |
| 243 | switch_and_save_asid(vma_asid); | 129 | switch_and_save_asid(vma_asid); |
| 244 | } | 130 | } |
| 245 | while (addr < end_addr) { | 131 | while (addr < end_addr) { |
| 246 | /* Worth unrolling a little */ | 132 | /* Worth unrolling a little */ |
| 247 | asm __volatile__("icbi %0, 0" : : "r" (addr)); | 133 | __asm__ __volatile__("icbi %0, 0" : : "r" (addr)); |
| 248 | asm __volatile__("icbi %0, 32" : : "r" (addr)); | 134 | __asm__ __volatile__("icbi %0, 32" : : "r" (addr)); |
| 249 | asm __volatile__("icbi %0, 64" : : "r" (addr)); | 135 | __asm__ __volatile__("icbi %0, 64" : : "r" (addr)); |
| 250 | asm __volatile__("icbi %0, 96" : : "r" (addr)); | 136 | __asm__ __volatile__("icbi %0, 96" : : "r" (addr)); |
| 251 | addr += 128; | 137 | addr += 128; |
| 252 | } | 138 | } |
| 253 | if (running_asid != vma_asid) { | 139 | if (running_asid != vma_asid) { |
| @@ -256,8 +142,6 @@ static void sh64_icache_inv_user_page(struct vm_area_struct *vma, unsigned long | |||
| 256 | } | 142 | } |
| 257 | } | 143 | } |
| 258 | 144 | ||
| 259 | /****************************************************************************/ | ||
| 260 | |||
| 261 | static void sh64_icache_inv_user_page_range(struct mm_struct *mm, | 145 | static void sh64_icache_inv_user_page_range(struct mm_struct *mm, |
| 262 | unsigned long start, unsigned long end) | 146 | unsigned long start, unsigned long end) |
| 263 | { | 147 | { |
| @@ -275,10 +159,10 @@ static void sh64_icache_inv_user_page_range(struct mm_struct *mm, | |||
| 275 | possible with the D-cache. Just assume 64 for now as a working | 159 | possible with the D-cache. Just assume 64 for now as a working |
| 276 | figure. | 160 | figure. |
| 277 | */ | 161 | */ |
| 278 | |||
| 279 | int n_pages; | 162 | int n_pages; |
| 280 | 163 | ||
| 281 | if (!mm) return; | 164 | if (!mm) |
| 165 | return; | ||
| 282 | 166 | ||
| 283 | n_pages = ((end - start) >> PAGE_SHIFT); | 167 | n_pages = ((end - start) >> PAGE_SHIFT); |
| 284 | if (n_pages >= 64) { | 168 | if (n_pages >= 64) { |
| @@ -290,7 +174,7 @@ static void sh64_icache_inv_user_page_range(struct mm_struct *mm, | |||
| 290 | unsigned long mm_asid, current_asid; | 174 | unsigned long mm_asid, current_asid; |
| 291 | unsigned long long flags = 0ULL; | 175 | unsigned long long flags = 0ULL; |
| 292 | 176 | ||
| 293 | mm_asid = mm->context & MMU_CONTEXT_ASID_MASK; | 177 | mm_asid = cpu_asid(smp_processor_id(), mm); |
| 294 | current_asid = get_asid(); | 178 | current_asid = get_asid(); |
| 295 | 179 | ||
| 296 | if (mm_asid != current_asid) { | 180 | if (mm_asid != current_asid) { |
| @@ -322,6 +206,7 @@ static void sh64_icache_inv_user_page_range(struct mm_struct *mm, | |||
| 322 | } | 206 | } |
| 323 | aligned_start = vma->vm_end; /* Skip to start of next region */ | 207 | aligned_start = vma->vm_end; /* Skip to start of next region */ |
| 324 | } | 208 | } |
| 209 | |||
| 325 | if (mm_asid != current_asid) { | 210 | if (mm_asid != current_asid) { |
| 326 | switch_and_save_asid(current_asid); | 211 | switch_and_save_asid(current_asid); |
| 327 | local_irq_restore(flags); | 212 | local_irq_restore(flags); |
| @@ -329,47 +214,46 @@ static void sh64_icache_inv_user_page_range(struct mm_struct *mm, | |||
| 329 | } | 214 | } |
| 330 | } | 215 | } |
| 331 | 216 | ||
| 217 | /* | ||
| 218 | * Invalidate a small range of user context I-cache, not necessarily page | ||
| 219 | * (or even cache-line) aligned. | ||
| 220 | * | ||
| 221 | * Since this is used inside ptrace, the ASID in the mm context typically | ||
| 222 | * won't match current_asid. We'll have to switch ASID to do this. For | ||
| 223 | * safety, and given that the range will be small, do all this under cli. | ||
| 224 | * | ||
| 225 | * Note, there is a hazard that the ASID in mm->context is no longer | ||
| 226 | * actually associated with mm, i.e. if the mm->context has started a new | ||
| 227 | * cycle since mm was last active. However, this is just a performance | ||
| 228 | * issue: all that happens is that we invalidate lines belonging to | ||
| 229 | * another mm, so the owning process has to refill them when that mm goes | ||
| 230 | * live again. mm itself can't have any cache entries because there will | ||
| 231 | * have been a flush_cache_all when the new mm->context cycle started. | ||
| 232 | */ | ||
| 332 | static void sh64_icache_inv_user_small_range(struct mm_struct *mm, | 233 | static void sh64_icache_inv_user_small_range(struct mm_struct *mm, |
| 333 | unsigned long start, int len) | 234 | unsigned long start, int len) |
| 334 | { | 235 | { |
| 335 | |||
| 336 | /* Invalidate a small range of user context I-cache, not necessarily | ||
| 337 | page (or even cache-line) aligned. */ | ||
| 338 | |||
| 339 | unsigned long long eaddr = start; | 236 | unsigned long long eaddr = start; |
| 340 | unsigned long long eaddr_end = start + len; | 237 | unsigned long long eaddr_end = start + len; |
| 341 | unsigned long current_asid, mm_asid; | 238 | unsigned long current_asid, mm_asid; |
| 342 | unsigned long long flags; | 239 | unsigned long long flags; |
| 343 | unsigned long long epage_start; | 240 | unsigned long long epage_start; |
| 344 | 241 | ||
| 345 | /* Since this is used inside ptrace, the ASID in the mm context | 242 | /* |
| 346 | typically won't match current_asid. We'll have to switch ASID to do | 243 | * Align to start of cache line. Otherwise, suppose len==8 and |
| 347 | this. For safety, and given that the range will be small, do all | 244 | * start was at 32N+28 : the last 4 bytes wouldn't get invalidated. |
| 348 | this under cli. | 245 | */ |
| 349 | 246 | eaddr = L1_CACHE_ALIGN(start); | |
| 350 | Note, there is a hazard that the ASID in mm->context is no longer | ||
| 351 | actually associated with mm, i.e. if the mm->context has started a | ||
| 352 | new cycle since mm was last active. However, this is just a | ||
| 353 | performance issue: all that happens is that we invalidate lines | ||
| 354 | belonging to another mm, so the owning process has to refill them | ||
| 355 | when that mm goes live again. mm itself can't have any cache | ||
| 356 | entries because there will have been a flush_cache_all when the new | ||
| 357 | mm->context cycle started. */ | ||
| 358 | |||
| 359 | /* Align to start of cache line. Otherwise, suppose len==8 and start | ||
| 360 | was at 32N+28 : the last 4 bytes wouldn't get invalidated. */ | ||
| 361 | eaddr = start & L1_CACHE_ALIGN_MASK; | ||
| 362 | eaddr_end = start + len; | 247 | eaddr_end = start + len; |
| 363 | 248 | ||
| 249 | mm_asid = cpu_asid(smp_processor_id(), mm); | ||
| 364 | local_irq_save(flags); | 250 | local_irq_save(flags); |
| 365 | mm_asid = mm->context & MMU_CONTEXT_ASID_MASK; | ||
| 366 | current_asid = switch_and_save_asid(mm_asid); | 251 | current_asid = switch_and_save_asid(mm_asid); |
| 367 | 252 | ||
| 368 | epage_start = eaddr & PAGE_MASK; | 253 | epage_start = eaddr & PAGE_MASK; |
| 369 | 254 | ||
| 370 | while (eaddr < eaddr_end) | 255 | while (eaddr < eaddr_end) { |
| 371 | { | 256 | __asm__ __volatile__("icbi %0, 0" : : "r" (eaddr)); |
| 372 | asm __volatile__("icbi %0, 0" : : "r" (eaddr)); | ||
| 373 | eaddr += L1_CACHE_BYTES; | 257 | eaddr += L1_CACHE_BYTES; |
| 374 | } | 258 | } |
| 375 | switch_and_save_asid(current_asid); | 259 | switch_and_save_asid(current_asid); |
| @@ -394,30 +278,24 @@ static void sh64_icache_inv_current_user_range(unsigned long start, unsigned lon | |||
| 394 | been recycled since we were last active in which case we might just | 278 | been recycled since we were last active in which case we might just |
| 395 | invalidate another processes I-cache entries : no worries, just a | 279 | invalidate another processes I-cache entries : no worries, just a |
| 396 | performance drop for him. */ | 280 | performance drop for him. */ |
| 397 | aligned_start = start & L1_CACHE_ALIGN_MASK; | 281 | aligned_start = L1_CACHE_ALIGN(start); |
| 398 | addr = aligned_start; | 282 | addr = aligned_start; |
| 399 | while (addr < ull_end) { | 283 | while (addr < ull_end) { |
| 400 | asm __volatile__ ("icbi %0, 0" : : "r" (addr)); | 284 | __asm__ __volatile__ ("icbi %0, 0" : : "r" (addr)); |
| 401 | asm __volatile__ ("nop"); | 285 | __asm__ __volatile__ ("nop"); |
| 402 | asm __volatile__ ("nop"); | 286 | __asm__ __volatile__ ("nop"); |
| 403 | addr += L1_CACHE_BYTES; | 287 | addr += L1_CACHE_BYTES; |
| 404 | } | 288 | } |
| 405 | } | 289 | } |
| 406 | |||
| 407 | #endif /* !CONFIG_ICACHE_DISABLED */ | 290 | #endif /* !CONFIG_ICACHE_DISABLED */ |
| 408 | 291 | ||
| 409 | /****************************************************************************/ | ||
| 410 | |||
| 411 | #ifndef CONFIG_DCACHE_DISABLED | 292 | #ifndef CONFIG_DCACHE_DISABLED |
| 412 | |||
| 413 | /* Buffer used as the target of alloco instructions to purge data from cache | 293 | /* Buffer used as the target of alloco instructions to purge data from cache |
| 414 | sets by natural eviction. -- RPC */ | 294 | sets by natural eviction. -- RPC */ |
| 415 | #define DUMMY_ALLOCO_AREA_SIZE L1_CACHE_SIZE_BYTES + (1024 * 4) | 295 | #define DUMMY_ALLOCO_AREA_SIZE ((L1_CACHE_BYTES << 10) + (1024 * 4)) |
| 416 | static unsigned char dummy_alloco_area[DUMMY_ALLOCO_AREA_SIZE] __cacheline_aligned = { 0, }; | 296 | static unsigned char dummy_alloco_area[DUMMY_ALLOCO_AREA_SIZE] __cacheline_aligned = { 0, }; |
| 417 | 297 | ||
| 418 | /****************************************************************************/ | 298 | static void inline sh64_dcache_purge_sets(int sets_to_purge_base, int n_sets) |
| 419 | |||
| 420 | static void __inline__ sh64_dcache_purge_sets(int sets_to_purge_base, int n_sets) | ||
| 421 | { | 299 | { |
| 422 | /* Purge all ways in a particular block of sets, specified by the base | 300 | /* Purge all ways in a particular block of sets, specified by the base |
| 423 | set number and number of sets. Can handle wrap-around, if that's | 301 | set number and number of sets. Can handle wrap-around, if that's |
| @@ -428,102 +306,86 @@ static void __inline__ sh64_dcache_purge_sets(int sets_to_purge_base, int n_sets | |||
| 428 | int j; | 306 | int j; |
| 429 | int set_offset; | 307 | int set_offset; |
| 430 | 308 | ||
| 431 | dummy_buffer_base_set = ((int)&dummy_alloco_area & cpu_data->dcache.idx_mask) >> cpu_data->dcache.entry_shift; | 309 | dummy_buffer_base_set = ((int)&dummy_alloco_area & |
| 310 | cpu_data->dcache.entry_mask) >> | ||
| 311 | cpu_data->dcache.entry_shift; | ||
| 432 | set_offset = sets_to_purge_base - dummy_buffer_base_set; | 312 | set_offset = sets_to_purge_base - dummy_buffer_base_set; |
| 433 | 313 | ||
| 434 | for (j=0; j<n_sets; j++, set_offset++) { | 314 | for (j = 0; j < n_sets; j++, set_offset++) { |
| 435 | set_offset &= (cpu_data->dcache.sets - 1); | 315 | set_offset &= (cpu_data->dcache.sets - 1); |
| 436 | eaddr0 = (unsigned long long)dummy_alloco_area + (set_offset << cpu_data->dcache.entry_shift); | 316 | eaddr0 = (unsigned long long)dummy_alloco_area + |
| 437 | 317 | (set_offset << cpu_data->dcache.entry_shift); | |
| 438 | /* Do one alloco which hits the required set per cache way. For | 318 | |
| 439 | write-back mode, this will purge the #ways resident lines. There's | 319 | /* |
| 440 | little point unrolling this loop because the allocos stall more if | 320 | * Do one alloco which hits the required set per cache |
| 441 | they're too close together. */ | 321 | * way. For write-back mode, this will purge the #ways |
| 442 | eaddr1 = eaddr0 + cpu_data->dcache.way_ofs * cpu_data->dcache.ways; | 322 | * resident lines. There's little point unrolling this |
| 443 | for (eaddr=eaddr0; eaddr<eaddr1; eaddr+=cpu_data->dcache.way_ofs) { | 323 | * loop because the allocos stall more if they're too |
| 444 | asm __volatile__ ("alloco %0, 0" : : "r" (eaddr)); | 324 | * close together. |
| 445 | asm __volatile__ ("synco"); /* TAKum03020 */ | 325 | */ |
| 326 | eaddr1 = eaddr0 + cpu_data->dcache.way_size * | ||
| 327 | cpu_data->dcache.ways; | ||
| 328 | |||
| 329 | for (eaddr = eaddr0; eaddr < eaddr1; | ||
| 330 | eaddr += cpu_data->dcache.way_size) { | ||
| 331 | __asm__ __volatile__ ("alloco %0, 0" : : "r" (eaddr)); | ||
| 332 | __asm__ __volatile__ ("synco"); /* TAKum03020 */ | ||
| 446 | } | 333 | } |
| 447 | 334 | ||
| 448 | eaddr1 = eaddr0 + cpu_data->dcache.way_ofs * cpu_data->dcache.ways; | 335 | eaddr1 = eaddr0 + cpu_data->dcache.way_size * |
| 449 | for (eaddr=eaddr0; eaddr<eaddr1; eaddr+=cpu_data->dcache.way_ofs) { | 336 | cpu_data->dcache.ways; |
| 450 | /* Load from each address. Required because alloco is a NOP if | 337 | |
| 451 | the cache is write-through. Write-through is a config option. */ | 338 | for (eaddr = eaddr0; eaddr < eaddr1; |
| 339 | eaddr += cpu_data->dcache.way_size) { | ||
| 340 | /* | ||
| 341 | * Load from each address. Required because | ||
| 342 | * alloco is a NOP if the cache is write-through. | ||
| 343 | */ | ||
| 452 | if (test_bit(SH_CACHE_MODE_WT, &(cpu_data->dcache.flags))) | 344 | if (test_bit(SH_CACHE_MODE_WT, &(cpu_data->dcache.flags))) |
| 453 | *(volatile unsigned char *)(int)eaddr; | 345 | ctrl_inb(eaddr); |
| 454 | } | 346 | } |
| 455 | } | 347 | } |
| 456 | 348 | ||
| 457 | /* Don't use OCBI to invalidate the lines. That costs cycles directly. | 349 | /* |
| 458 | If the dummy block is just left resident, it will naturally get | 350 | * Don't use OCBI to invalidate the lines. That costs cycles |
| 459 | evicted as required. */ | 351 | * directly. If the dummy block is just left resident, it will |
| 460 | 352 | * naturally get evicted as required. | |
| 461 | return; | 353 | */ |
| 462 | } | 354 | } |
| 463 | 355 | ||
| 464 | /****************************************************************************/ | 356 | /* |
| 465 | 357 | * Purge the entire contents of the dcache. The most efficient way to | |
| 358 | * achieve this is to use alloco instructions on a region of unused | ||
| 359 | * memory equal in size to the cache, thereby causing the current | ||
| 360 | * contents to be discarded by natural eviction. The alternative, namely | ||
| 361 | * reading every tag, setting up a mapping for the corresponding page and | ||
| 362 | * doing an OCBP for the line, would be much more expensive. | ||
| 363 | */ | ||
| 466 | static void sh64_dcache_purge_all(void) | 364 | static void sh64_dcache_purge_all(void) |
| 467 | { | 365 | { |
| 468 | /* Purge the entire contents of the dcache. The most efficient way to | ||
| 469 | achieve this is to use alloco instructions on a region of unused | ||
| 470 | memory equal in size to the cache, thereby causing the current | ||
| 471 | contents to be discarded by natural eviction. The alternative, | ||
| 472 | namely reading every tag, setting up a mapping for the corresponding | ||
| 473 | page and doing an OCBP for the line, would be much more expensive. | ||
| 474 | */ | ||
| 475 | 366 | ||
| 476 | sh64_dcache_purge_sets(0, cpu_data->dcache.sets); | 367 | sh64_dcache_purge_sets(0, cpu_data->dcache.sets); |
| 477 | |||
| 478 | return; | ||
| 479 | |||
| 480 | } | 368 | } |
| 481 | 369 | ||
| 482 | /****************************************************************************/ | ||
| 483 | |||
| 484 | static void sh64_dcache_purge_kernel_range(unsigned long start, unsigned long end) | ||
| 485 | { | ||
| 486 | /* Purge the range of addresses [start,end] from the D-cache. The | ||
| 487 | addresses lie in the superpage mapping. There's no harm if we | ||
| 488 | overpurge at either end - just a small performance loss. */ | ||
| 489 | unsigned long long ullend, addr, aligned_start; | ||
| 490 | #if (NEFF == 32) | ||
| 491 | aligned_start = (unsigned long long)(signed long long)(signed long) start; | ||
| 492 | #else | ||
| 493 | #error "NEFF != 32" | ||
| 494 | #endif | ||
| 495 | aligned_start &= L1_CACHE_ALIGN_MASK; | ||
| 496 | addr = aligned_start; | ||
| 497 | #if (NEFF == 32) | ||
| 498 | ullend = (unsigned long long) (signed long long) (signed long) end; | ||
| 499 | #else | ||
| 500 | #error "NEFF != 32" | ||
| 501 | #endif | ||
| 502 | while (addr <= ullend) { | ||
| 503 | asm __volatile__ ("ocbp %0, 0" : : "r" (addr)); | ||
| 504 | addr += L1_CACHE_BYTES; | ||
| 505 | } | ||
| 506 | return; | ||
| 507 | } | ||
| 508 | 370 | ||
| 509 | /* Assumes this address (+ (2**n_synbits) pages up from it) aren't used for | 371 | /* Assumes this address (+ (2**n_synbits) pages up from it) aren't used for |
| 510 | anything else in the kernel */ | 372 | anything else in the kernel */ |
| 511 | #define MAGIC_PAGE0_START 0xffffffffec000000ULL | 373 | #define MAGIC_PAGE0_START 0xffffffffec000000ULL |
| 512 | 374 | ||
| 513 | static void sh64_dcache_purge_coloured_phy_page(unsigned long paddr, unsigned long eaddr) | 375 | /* Purge the physical page 'paddr' from the cache. It's known that any |
| 376 | * cache lines requiring attention have the same page colour as the the | ||
| 377 | * address 'eaddr'. | ||
| 378 | * | ||
| 379 | * This relies on the fact that the D-cache matches on physical tags when | ||
| 380 | * no virtual tag matches. So we create an alias for the original page | ||
| 381 | * and purge through that. (Alternatively, we could have done this by | ||
| 382 | * switching ASID to match the original mapping and purged through that, | ||
| 383 | * but that involves ASID switching cost + probably a TLBMISS + refill | ||
| 384 | * anyway.) | ||
| 385 | */ | ||
| 386 | static void sh64_dcache_purge_coloured_phy_page(unsigned long paddr, | ||
| 387 | unsigned long eaddr) | ||
| 514 | { | 388 | { |
| 515 | /* Purge the physical page 'paddr' from the cache. It's known that any | ||
| 516 | cache lines requiring attention have the same page colour as the the | ||
| 517 | address 'eaddr'. | ||
| 518 | |||
| 519 | This relies on the fact that the D-cache matches on physical tags | ||
| 520 | when no virtual tag matches. So we create an alias for the original | ||
| 521 | page and purge through that. (Alternatively, we could have done | ||
| 522 | this by switching ASID to match the original mapping and purged | ||
| 523 | through that, but that involves ASID switching cost + probably a | ||
| 524 | TLBMISS + refill anyway.) | ||
| 525 | */ | ||
| 526 | |||
| 527 | unsigned long long magic_page_start; | 389 | unsigned long long magic_page_start; |
| 528 | unsigned long long magic_eaddr, magic_eaddr_end; | 390 | unsigned long long magic_eaddr, magic_eaddr_end; |
| 529 | 391 | ||
| @@ -531,47 +393,45 @@ static void sh64_dcache_purge_coloured_phy_page(unsigned long paddr, unsigned lo | |||
| 531 | 393 | ||
| 532 | /* As long as the kernel is not pre-emptible, this doesn't need to be | 394 | /* As long as the kernel is not pre-emptible, this doesn't need to be |
| 533 | under cli/sti. */ | 395 | under cli/sti. */ |
| 534 | |||
| 535 | sh64_setup_dtlb_cache_slot(magic_page_start, get_asid(), paddr); | 396 | sh64_setup_dtlb_cache_slot(magic_page_start, get_asid(), paddr); |
| 536 | 397 | ||
| 537 | magic_eaddr = magic_page_start; | 398 | magic_eaddr = magic_page_start; |
| 538 | magic_eaddr_end = magic_eaddr + PAGE_SIZE; | 399 | magic_eaddr_end = magic_eaddr + PAGE_SIZE; |
| 400 | |||
| 539 | while (magic_eaddr < magic_eaddr_end) { | 401 | while (magic_eaddr < magic_eaddr_end) { |
| 540 | /* Little point in unrolling this loop - the OCBPs are blocking | 402 | /* Little point in unrolling this loop - the OCBPs are blocking |
| 541 | and won't go any quicker (i.e. the loop overhead is parallel | 403 | and won't go any quicker (i.e. the loop overhead is parallel |
| 542 | to part of the OCBP execution.) */ | 404 | to part of the OCBP execution.) */ |
| 543 | asm __volatile__ ("ocbp %0, 0" : : "r" (magic_eaddr)); | 405 | __asm__ __volatile__ ("ocbp %0, 0" : : "r" (magic_eaddr)); |
| 544 | magic_eaddr += L1_CACHE_BYTES; | 406 | magic_eaddr += L1_CACHE_BYTES; |
| 545 | } | 407 | } |
| 546 | 408 | ||
| 547 | sh64_teardown_dtlb_cache_slot(); | 409 | sh64_teardown_dtlb_cache_slot(); |
| 548 | } | 410 | } |
| 549 | 411 | ||
| 550 | /****************************************************************************/ | 412 | /* |
| 551 | 413 | * Purge a page given its physical start address, by creating a temporary | |
| 414 | * 1 page mapping and purging across that. Even if we know the virtual | ||
| 415 | * address (& vma or mm) of the page, the method here is more elegant | ||
| 416 | * because it avoids issues of coping with page faults on the purge | ||
| 417 | * instructions (i.e. no special-case code required in the critical path | ||
| 418 | * in the TLB miss handling). | ||
| 419 | */ | ||
| 552 | static void sh64_dcache_purge_phy_page(unsigned long paddr) | 420 | static void sh64_dcache_purge_phy_page(unsigned long paddr) |
| 553 | { | 421 | { |
| 554 | /* Pure a page given its physical start address, by creating a | ||
| 555 | temporary 1 page mapping and purging across that. Even if we know | ||
| 556 | the virtual address (& vma or mm) of the page, the method here is | ||
| 557 | more elegant because it avoids issues of coping with page faults on | ||
| 558 | the purge instructions (i.e. no special-case code required in the | ||
| 559 | critical path in the TLB miss handling). */ | ||
| 560 | |||
| 561 | unsigned long long eaddr_start, eaddr, eaddr_end; | 422 | unsigned long long eaddr_start, eaddr, eaddr_end; |
| 562 | int i; | 423 | int i; |
| 563 | 424 | ||
| 564 | /* As long as the kernel is not pre-emptible, this doesn't need to be | 425 | /* As long as the kernel is not pre-emptible, this doesn't need to be |
| 565 | under cli/sti. */ | 426 | under cli/sti. */ |
| 566 | |||
| 567 | eaddr_start = MAGIC_PAGE0_START; | 427 | eaddr_start = MAGIC_PAGE0_START; |
| 568 | for (i=0; i < (1 << CACHE_OC_N_SYNBITS); i++) { | 428 | for (i = 0; i < (1 << CACHE_OC_N_SYNBITS); i++) { |
| 569 | sh64_setup_dtlb_cache_slot(eaddr_start, get_asid(), paddr); | 429 | sh64_setup_dtlb_cache_slot(eaddr_start, get_asid(), paddr); |
| 570 | 430 | ||
| 571 | eaddr = eaddr_start; | 431 | eaddr = eaddr_start; |
| 572 | eaddr_end = eaddr + PAGE_SIZE; | 432 | eaddr_end = eaddr + PAGE_SIZE; |
| 573 | while (eaddr < eaddr_end) { | 433 | while (eaddr < eaddr_end) { |
| 574 | asm __volatile__ ("ocbp %0, 0" : : "r" (eaddr)); | 434 | __asm__ __volatile__ ("ocbp %0, 0" : : "r" (eaddr)); |
| 575 | eaddr += L1_CACHE_BYTES; | 435 | eaddr += L1_CACHE_BYTES; |
| 576 | } | 436 | } |
| 577 | 437 | ||
| @@ -584,6 +444,7 @@ static void sh64_dcache_purge_user_pages(struct mm_struct *mm, | |||
| 584 | unsigned long addr, unsigned long end) | 444 | unsigned long addr, unsigned long end) |
| 585 | { | 445 | { |
| 586 | pgd_t *pgd; | 446 | pgd_t *pgd; |
| 447 | pud_t *pud; | ||
| 587 | pmd_t *pmd; | 448 | pmd_t *pmd; |
| 588 | pte_t *pte; | 449 | pte_t *pte; |
| 589 | pte_t entry; | 450 | pte_t entry; |
| @@ -597,7 +458,11 @@ static void sh64_dcache_purge_user_pages(struct mm_struct *mm, | |||
| 597 | if (pgd_bad(*pgd)) | 458 | if (pgd_bad(*pgd)) |
| 598 | return; | 459 | return; |
| 599 | 460 | ||
| 600 | pmd = pmd_offset(pgd, addr); | 461 | pud = pud_offset(pgd, addr); |
| 462 | if (pud_none(*pud) || pud_bad(*pud)) | ||
| 463 | return; | ||
| 464 | |||
| 465 | pmd = pmd_offset(pud, addr); | ||
| 601 | if (pmd_none(*pmd) || pmd_bad(*pmd)) | 466 | if (pmd_none(*pmd) || pmd_bad(*pmd)) |
| 602 | return; | 467 | return; |
| 603 | 468 | ||
| @@ -611,419 +476,357 @@ static void sh64_dcache_purge_user_pages(struct mm_struct *mm, | |||
| 611 | } while (pte++, addr += PAGE_SIZE, addr != end); | 476 | } while (pte++, addr += PAGE_SIZE, addr != end); |
| 612 | pte_unmap_unlock(pte - 1, ptl); | 477 | pte_unmap_unlock(pte - 1, ptl); |
| 613 | } | 478 | } |
| 614 | /****************************************************************************/ | ||
| 615 | 479 | ||
| 480 | /* | ||
| 481 | * There are at least 5 choices for the implementation of this, with | ||
| 482 | * pros (+), cons(-), comments(*): | ||
| 483 | * | ||
| 484 | * 1. ocbp each line in the range through the original user's ASID | ||
| 485 | * + no lines spuriously evicted | ||
| 486 | * - tlbmiss handling (must either handle faults on demand => extra | ||
| 487 | * special-case code in tlbmiss critical path), or map the page in | ||
| 488 | * advance (=> flush_tlb_range in advance to avoid multiple hits) | ||
| 489 | * - ASID switching | ||
| 490 | * - expensive for large ranges | ||
| 491 | * | ||
| 492 | * 2. temporarily map each page in the range to a special effective | ||
| 493 | * address and ocbp through the temporary mapping; relies on the | ||
| 494 | * fact that SH-5 OCB* always do TLB lookup and match on ptags (they | ||
| 495 | * never look at the etags) | ||
| 496 | * + no spurious evictions | ||
| 497 | * - expensive for large ranges | ||
| 498 | * * surely cheaper than (1) | ||
| 499 | * | ||
| 500 | * 3. walk all the lines in the cache, check the tags, if a match | ||
| 501 | * occurs create a page mapping to ocbp the line through | ||
| 502 | * + no spurious evictions | ||
| 503 | * - tag inspection overhead | ||
| 504 | * - (especially for small ranges) | ||
| 505 | * - potential cost of setting up/tearing down page mapping for | ||
| 506 | * every line that matches the range | ||
| 507 | * * cost partly independent of range size | ||
| 508 | * | ||
| 509 | * 4. walk all the lines in the cache, check the tags, if a match | ||
| 510 | * occurs use 4 * alloco to purge the line (+3 other probably | ||
| 511 | * innocent victims) by natural eviction | ||
| 512 | * + no tlb mapping overheads | ||
| 513 | * - spurious evictions | ||
| 514 | * - tag inspection overhead | ||
| 515 | * | ||
| 516 | * 5. implement like flush_cache_all | ||
| 517 | * + no tag inspection overhead | ||
| 518 | * - spurious evictions | ||
| 519 | * - bad for small ranges | ||
| 520 | * | ||
| 521 | * (1) can be ruled out as more expensive than (2). (2) appears best | ||
| 522 | * for small ranges. The choice between (3), (4) and (5) for large | ||
| 523 | * ranges and the range size for the large/small boundary need | ||
| 524 | * benchmarking to determine. | ||
| 525 | * | ||
| 526 | * For now use approach (2) for small ranges and (5) for large ones. | ||
| 527 | */ | ||
| 616 | static void sh64_dcache_purge_user_range(struct mm_struct *mm, | 528 | static void sh64_dcache_purge_user_range(struct mm_struct *mm, |
| 617 | unsigned long start, unsigned long end) | 529 | unsigned long start, unsigned long end) |
| 618 | { | 530 | { |
| 619 | /* There are at least 5 choices for the implementation of this, with | 531 | int n_pages = ((end - start) >> PAGE_SHIFT); |
| 620 | pros (+), cons(-), comments(*): | ||
| 621 | |||
| 622 | 1. ocbp each line in the range through the original user's ASID | ||
| 623 | + no lines spuriously evicted | ||
| 624 | - tlbmiss handling (must either handle faults on demand => extra | ||
| 625 | special-case code in tlbmiss critical path), or map the page in | ||
| 626 | advance (=> flush_tlb_range in advance to avoid multiple hits) | ||
| 627 | - ASID switching | ||
| 628 | - expensive for large ranges | ||
| 629 | |||
| 630 | 2. temporarily map each page in the range to a special effective | ||
| 631 | address and ocbp through the temporary mapping; relies on the | ||
| 632 | fact that SH-5 OCB* always do TLB lookup and match on ptags (they | ||
| 633 | never look at the etags) | ||
| 634 | + no spurious evictions | ||
| 635 | - expensive for large ranges | ||
| 636 | * surely cheaper than (1) | ||
| 637 | |||
| 638 | 3. walk all the lines in the cache, check the tags, if a match | ||
| 639 | occurs create a page mapping to ocbp the line through | ||
| 640 | + no spurious evictions | ||
| 641 | - tag inspection overhead | ||
| 642 | - (especially for small ranges) | ||
| 643 | - potential cost of setting up/tearing down page mapping for | ||
| 644 | every line that matches the range | ||
| 645 | * cost partly independent of range size | ||
| 646 | |||
| 647 | 4. walk all the lines in the cache, check the tags, if a match | ||
| 648 | occurs use 4 * alloco to purge the line (+3 other probably | ||
| 649 | innocent victims) by natural eviction | ||
| 650 | + no tlb mapping overheads | ||
| 651 | - spurious evictions | ||
| 652 | - tag inspection overhead | ||
| 653 | |||
| 654 | 5. implement like flush_cache_all | ||
| 655 | + no tag inspection overhead | ||
| 656 | - spurious evictions | ||
| 657 | - bad for small ranges | ||
| 658 | |||
| 659 | (1) can be ruled out as more expensive than (2). (2) appears best | ||
| 660 | for small ranges. The choice between (3), (4) and (5) for large | ||
| 661 | ranges and the range size for the large/small boundary need | ||
| 662 | benchmarking to determine. | ||
| 663 | |||
| 664 | For now use approach (2) for small ranges and (5) for large ones. | ||
| 665 | |||
| 666 | */ | ||
| 667 | |||
| 668 | int n_pages; | ||
| 669 | 532 | ||
| 670 | n_pages = ((end - start) >> PAGE_SHIFT); | ||
| 671 | if (n_pages >= 64 || ((start ^ (end - 1)) & PMD_MASK)) { | 533 | if (n_pages >= 64 || ((start ^ (end - 1)) & PMD_MASK)) { |
| 672 | #if 1 | ||
| 673 | sh64_dcache_purge_all(); | 534 | sh64_dcache_purge_all(); |
| 674 | #else | ||
| 675 | unsigned long long set, way; | ||
| 676 | unsigned long mm_asid = mm->context & MMU_CONTEXT_ASID_MASK; | ||
| 677 | for (set = 0; set < cpu_data->dcache.sets; set++) { | ||
| 678 | unsigned long long set_base_config_addr = CACHE_OC_ADDRESS_ARRAY + (set << cpu_data->dcache.set_shift); | ||
| 679 | for (way = 0; way < cpu_data->dcache.ways; way++) { | ||
| 680 | unsigned long long config_addr = set_base_config_addr + (way << cpu_data->dcache.way_step_shift); | ||
| 681 | unsigned long long tag0; | ||
| 682 | unsigned long line_valid; | ||
| 683 | |||
| 684 | asm __volatile__("getcfg %1, 0, %0" : "=r" (tag0) : "r" (config_addr)); | ||
| 685 | line_valid = tag0 & SH_CACHE_VALID; | ||
| 686 | if (line_valid) { | ||
| 687 | unsigned long cache_asid; | ||
| 688 | unsigned long epn; | ||
| 689 | |||
| 690 | cache_asid = (tag0 & cpu_data->dcache.asid_mask) >> cpu_data->dcache.asid_shift; | ||
| 691 | /* The next line needs some | ||
| 692 | explanation. The virtual tags | ||
| 693 | encode bits [31:13] of the virtual | ||
| 694 | address, bit [12] of the 'tag' being | ||
| 695 | implied by the cache set index. */ | ||
| 696 | epn = (tag0 & cpu_data->dcache.epn_mask) | ((set & 0x80) << cpu_data->dcache.entry_shift); | ||
| 697 | |||
| 698 | if ((cache_asid == mm_asid) && (start <= epn) && (epn < end)) { | ||
| 699 | /* TODO : could optimise this | ||
| 700 | call by batching multiple | ||
| 701 | adjacent sets together. */ | ||
| 702 | sh64_dcache_purge_sets(set, 1); | ||
| 703 | break; /* Don't waste time inspecting other ways for this set */ | ||
| 704 | } | ||
| 705 | } | ||
| 706 | } | ||
| 707 | } | ||
| 708 | #endif | ||
| 709 | } else { | 535 | } else { |
| 710 | /* Small range, covered by a single page table page */ | 536 | /* Small range, covered by a single page table page */ |
| 711 | start &= PAGE_MASK; /* should already be so */ | 537 | start &= PAGE_MASK; /* should already be so */ |
| 712 | end = PAGE_ALIGN(end); /* should already be so */ | 538 | end = PAGE_ALIGN(end); /* should already be so */ |
| 713 | sh64_dcache_purge_user_pages(mm, start, end); | 539 | sh64_dcache_purge_user_pages(mm, start, end); |
| 714 | } | 540 | } |
| 715 | return; | ||
| 716 | } | 541 | } |
| 717 | 542 | ||
| 718 | static void sh64_dcache_wback_current_user_range(unsigned long start, unsigned long end) | 543 | /* |
| 544 | * Purge the range of addresses from the D-cache. | ||
| 545 | * | ||
| 546 | * The addresses lie in the superpage mapping. There's no harm if we | ||
| 547 | * overpurge at either end - just a small performance loss. | ||
| 548 | */ | ||
| 549 | void __flush_purge_region(void *start, int size) | ||
| 719 | { | 550 | { |
| 720 | unsigned long long aligned_start; | 551 | unsigned long long ullend, addr, aligned_start; |
| 721 | unsigned long long ull_end; | ||
| 722 | unsigned long long addr; | ||
| 723 | |||
| 724 | ull_end = end; | ||
| 725 | 552 | ||
| 726 | /* Just wback over the range using the natural addresses. TLB miss | 553 | aligned_start = (unsigned long long)(signed long long)(signed long) start; |
| 727 | handling will be OK (TBC) : the range has just been written to by | 554 | addr = L1_CACHE_ALIGN(aligned_start); |
| 728 | the signal frame setup code, so the PTEs must exist. | 555 | ullend = (unsigned long long) (signed long long) (signed long) start + size; |
| 729 | 556 | ||
| 730 | Note, if we have CONFIG_PREEMPT and get preempted inside this loop, | 557 | while (addr <= ullend) { |
| 731 | it doesn't matter, even if the pid->ASID mapping changes whilst | 558 | __asm__ __volatile__ ("ocbp %0, 0" : : "r" (addr)); |
| 732 | we're away. In that case the cache will have been flushed when the | ||
| 733 | mapping was renewed. So the writebacks below will be nugatory (and | ||
| 734 | we'll doubtless have to fault the TLB entry/ies in again with the | ||
| 735 | new ASID), but it's a rare case. | ||
| 736 | */ | ||
| 737 | aligned_start = start & L1_CACHE_ALIGN_MASK; | ||
| 738 | addr = aligned_start; | ||
| 739 | while (addr < ull_end) { | ||
| 740 | asm __volatile__ ("ocbwb %0, 0" : : "r" (addr)); | ||
| 741 | addr += L1_CACHE_BYTES; | 559 | addr += L1_CACHE_BYTES; |
| 742 | } | 560 | } |
| 743 | } | 561 | } |
| 744 | 562 | ||
| 745 | /****************************************************************************/ | 563 | void __flush_wback_region(void *start, int size) |
| 746 | |||
| 747 | /* These *MUST* lie in an area of virtual address space that's otherwise unused. */ | ||
| 748 | #define UNIQUE_EADDR_START 0xe0000000UL | ||
| 749 | #define UNIQUE_EADDR_END 0xe8000000UL | ||
| 750 | |||
| 751 | static unsigned long sh64_make_unique_eaddr(unsigned long user_eaddr, unsigned long paddr) | ||
| 752 | { | 564 | { |
| 753 | /* Given a physical address paddr, and a user virtual address | 565 | unsigned long long ullend, addr, aligned_start; |
| 754 | user_eaddr which will eventually be mapped to it, create a one-off | ||
| 755 | kernel-private eaddr mapped to the same paddr. This is used for | ||
| 756 | creating special destination pages for copy_user_page and | ||
| 757 | clear_user_page */ | ||
| 758 | 566 | ||
| 759 | static unsigned long current_pointer = UNIQUE_EADDR_START; | 567 | aligned_start = (unsigned long long)(signed long long)(signed long) start; |
| 760 | unsigned long coloured_pointer; | 568 | addr = L1_CACHE_ALIGN(aligned_start); |
| 569 | ullend = (unsigned long long) (signed long long) (signed long) start + size; | ||
| 761 | 570 | ||
| 762 | if (current_pointer == UNIQUE_EADDR_END) { | 571 | while (addr < ullend) { |
| 763 | sh64_dcache_purge_all(); | 572 | __asm__ __volatile__ ("ocbwb %0, 0" : : "r" (addr)); |
| 764 | current_pointer = UNIQUE_EADDR_START; | 573 | addr += L1_CACHE_BYTES; |
| 765 | } | 574 | } |
| 766 | |||
| 767 | coloured_pointer = (current_pointer & ~CACHE_OC_SYN_MASK) | (user_eaddr & CACHE_OC_SYN_MASK); | ||
| 768 | sh64_setup_dtlb_cache_slot(coloured_pointer, get_asid(), paddr); | ||
| 769 | |||
| 770 | current_pointer += (PAGE_SIZE << CACHE_OC_N_SYNBITS); | ||
| 771 | |||
| 772 | return coloured_pointer; | ||
| 773 | } | ||
| 774 | |||
| 775 | /****************************************************************************/ | ||
| 776 | |||
| 777 | static void sh64_copy_user_page_coloured(void *to, void *from, unsigned long address) | ||
| 778 | { | ||
| 779 | void *coloured_to; | ||
| 780 | |||
| 781 | /* Discard any existing cache entries of the wrong colour. These are | ||
| 782 | present quite often, if the kernel has recently used the page | ||
| 783 | internally, then given it up, then it's been allocated to the user. | ||
| 784 | */ | ||
| 785 | sh64_dcache_purge_coloured_phy_page(__pa(to), (unsigned long) to); | ||
| 786 | |||
| 787 | coloured_to = (void *) sh64_make_unique_eaddr(address, __pa(to)); | ||
| 788 | sh64_page_copy(from, coloured_to); | ||
| 789 | |||
| 790 | sh64_teardown_dtlb_cache_slot(); | ||
| 791 | } | 575 | } |
| 792 | 576 | ||
| 793 | static void sh64_clear_user_page_coloured(void *to, unsigned long address) | 577 | void __flush_invalidate_region(void *start, int size) |
| 794 | { | 578 | { |
| 795 | void *coloured_to; | 579 | unsigned long long ullend, addr, aligned_start; |
| 796 | |||
| 797 | /* Discard any existing kernel-originated lines of the wrong colour (as | ||
| 798 | above) */ | ||
| 799 | sh64_dcache_purge_coloured_phy_page(__pa(to), (unsigned long) to); | ||
| 800 | 580 | ||
| 801 | coloured_to = (void *) sh64_make_unique_eaddr(address, __pa(to)); | 581 | aligned_start = (unsigned long long)(signed long long)(signed long) start; |
| 802 | sh64_page_clear(coloured_to); | 582 | addr = L1_CACHE_ALIGN(aligned_start); |
| 583 | ullend = (unsigned long long) (signed long long) (signed long) start + size; | ||
| 803 | 584 | ||
| 804 | sh64_teardown_dtlb_cache_slot(); | 585 | while (addr < ullend) { |
| 586 | __asm__ __volatile__ ("ocbi %0, 0" : : "r" (addr)); | ||
| 587 | addr += L1_CACHE_BYTES; | ||
| 588 | } | ||
| 805 | } | 589 | } |
| 806 | |||
| 807 | #endif /* !CONFIG_DCACHE_DISABLED */ | 590 | #endif /* !CONFIG_DCACHE_DISABLED */ |
| 808 | 591 | ||
| 809 | /****************************************************************************/ | 592 | /* |
| 810 | 593 | * Invalidate the entire contents of both caches, after writing back to | |
| 811 | /*########################################################################## | 594 | * memory any dirty data from the D-cache. |
| 812 | EXTERNALLY CALLABLE API. | 595 | */ |
| 813 | ##########################################################################*/ | ||
| 814 | |||
| 815 | /* These functions are described in Documentation/cachetlb.txt. | ||
| 816 | Each one of these functions varies in behaviour depending on whether the | ||
| 817 | I-cache and/or D-cache are configured out. | ||
| 818 | |||
| 819 | Note that the Linux term 'flush' corresponds to what is termed 'purge' in | ||
| 820 | the sh/sh64 jargon for the D-cache, i.e. write back dirty data then | ||
| 821 | invalidate the cache lines, and 'invalidate' for the I-cache. | ||
| 822 | */ | ||
| 823 | |||
| 824 | #undef FLUSH_TRACE | ||
| 825 | |||
| 826 | void flush_cache_all(void) | 596 | void flush_cache_all(void) |
| 827 | { | 597 | { |
| 828 | /* Invalidate the entire contents of both caches, after writing back to | ||
| 829 | memory any dirty data from the D-cache. */ | ||
| 830 | sh64_dcache_purge_all(); | 598 | sh64_dcache_purge_all(); |
| 831 | sh64_icache_inv_all(); | 599 | sh64_icache_inv_all(); |
| 832 | } | 600 | } |
| 833 | 601 | ||
| 834 | /****************************************************************************/ | 602 | /* |
| 835 | 603 | * Invalidate an entire user-address space from both caches, after | |
| 604 | * writing back dirty data (e.g. for shared mmap etc). | ||
| 605 | * | ||
| 606 | * This could be coded selectively by inspecting all the tags then | ||
| 607 | * doing 4*alloco on any set containing a match (as for | ||
| 608 | * flush_cache_range), but fork/exit/execve (where this is called from) | ||
| 609 | * are expensive anyway. | ||
| 610 | * | ||
| 611 | * Have to do a purge here, despite the comments re I-cache below. | ||
| 612 | * There could be odd-coloured dirty data associated with the mm still | ||
| 613 | * in the cache - if this gets written out through natural eviction | ||
| 614 | * after the kernel has reused the page there will be chaos. | ||
| 615 | * | ||
| 616 | * The mm being torn down won't ever be active again, so any Icache | ||
| 617 | * lines tagged with its ASID won't be visible for the rest of the | ||
| 618 | * lifetime of this ASID cycle. Before the ASID gets reused, there | ||
| 619 | * will be a flush_cache_all. Hence we don't need to touch the | ||
| 620 | * I-cache. This is similar to the lack of action needed in | ||
| 621 | * flush_tlb_mm - see fault.c. | ||
| 622 | */ | ||
| 836 | void flush_cache_mm(struct mm_struct *mm) | 623 | void flush_cache_mm(struct mm_struct *mm) |
| 837 | { | 624 | { |
| 838 | /* Invalidate an entire user-address space from both caches, after | ||
| 839 | writing back dirty data (e.g. for shared mmap etc). */ | ||
| 840 | |||
| 841 | /* This could be coded selectively by inspecting all the tags then | ||
| 842 | doing 4*alloco on any set containing a match (as for | ||
| 843 | flush_cache_range), but fork/exit/execve (where this is called from) | ||
| 844 | are expensive anyway. */ | ||
| 845 | |||
| 846 | /* Have to do a purge here, despite the comments re I-cache below. | ||
| 847 | There could be odd-coloured dirty data associated with the mm still | ||
| 848 | in the cache - if this gets written out through natural eviction | ||
| 849 | after the kernel has reused the page there will be chaos. | ||
| 850 | */ | ||
| 851 | |||
| 852 | sh64_dcache_purge_all(); | 625 | sh64_dcache_purge_all(); |
| 853 | |||
| 854 | /* The mm being torn down won't ever be active again, so any Icache | ||
| 855 | lines tagged with its ASID won't be visible for the rest of the | ||
| 856 | lifetime of this ASID cycle. Before the ASID gets reused, there | ||
| 857 | will be a flush_cache_all. Hence we don't need to touch the | ||
| 858 | I-cache. This is similar to the lack of action needed in | ||
| 859 | flush_tlb_mm - see fault.c. */ | ||
| 860 | } | 626 | } |
| 861 | 627 | ||
| 862 | /****************************************************************************/ | 628 | /* |
| 863 | 629 | * Invalidate (from both caches) the range [start,end) of virtual | |
| 630 | * addresses from the user address space specified by mm, after writing | ||
| 631 | * back any dirty data. | ||
| 632 | * | ||
| 633 | * Note, 'end' is 1 byte beyond the end of the range to flush. | ||
| 634 | */ | ||
| 864 | void flush_cache_range(struct vm_area_struct *vma, unsigned long start, | 635 | void flush_cache_range(struct vm_area_struct *vma, unsigned long start, |
| 865 | unsigned long end) | 636 | unsigned long end) |
| 866 | { | 637 | { |
| 867 | struct mm_struct *mm = vma->vm_mm; | 638 | struct mm_struct *mm = vma->vm_mm; |
| 868 | 639 | ||
| 869 | /* Invalidate (from both caches) the range [start,end) of virtual | ||
| 870 | addresses from the user address space specified by mm, after writing | ||
| 871 | back any dirty data. | ||
| 872 | |||
| 873 | Note, 'end' is 1 byte beyond the end of the range to flush. */ | ||
| 874 | |||
| 875 | sh64_dcache_purge_user_range(mm, start, end); | 640 | sh64_dcache_purge_user_range(mm, start, end); |
| 876 | sh64_icache_inv_user_page_range(mm, start, end); | 641 | sh64_icache_inv_user_page_range(mm, start, end); |
| 877 | } | 642 | } |
| 878 | 643 | ||
| 879 | /****************************************************************************/ | 644 | /* |
| 880 | 645 | * Invalidate any entries in either cache for the vma within the user | |
| 881 | void flush_cache_page(struct vm_area_struct *vma, unsigned long eaddr, unsigned long pfn) | 646 | * address space vma->vm_mm for the page starting at virtual address |
| 647 | * 'eaddr'. This seems to be used primarily in breaking COW. Note, | ||
| 648 | * the I-cache must be searched too in case the page in question is | ||
| 649 | * both writable and being executed from (e.g. stack trampolines.) | ||
| 650 | * | ||
| 651 | * Note, this is called with pte lock held. | ||
| 652 | */ | ||
| 653 | void flush_cache_page(struct vm_area_struct *vma, unsigned long eaddr, | ||
| 654 | unsigned long pfn) | ||
| 882 | { | 655 | { |
| 883 | /* Invalidate any entries in either cache for the vma within the user | ||
| 884 | address space vma->vm_mm for the page starting at virtual address | ||
| 885 | 'eaddr'. This seems to be used primarily in breaking COW. Note, | ||
| 886 | the I-cache must be searched too in case the page in question is | ||
| 887 | both writable and being executed from (e.g. stack trampolines.) | ||
| 888 | |||
| 889 | Note, this is called with pte lock held. | ||
| 890 | */ | ||
| 891 | |||
| 892 | sh64_dcache_purge_phy_page(pfn << PAGE_SHIFT); | 656 | sh64_dcache_purge_phy_page(pfn << PAGE_SHIFT); |
| 893 | 657 | ||
| 894 | if (vma->vm_flags & VM_EXEC) { | 658 | if (vma->vm_flags & VM_EXEC) |
| 895 | sh64_icache_inv_user_page(vma, eaddr); | 659 | sh64_icache_inv_user_page(vma, eaddr); |
| 896 | } | ||
| 897 | } | 660 | } |
| 898 | 661 | ||
| 899 | /****************************************************************************/ | 662 | void flush_dcache_page(struct page *page) |
| 663 | { | ||
| 664 | sh64_dcache_purge_phy_page(page_to_phys(page)); | ||
| 665 | wmb(); | ||
| 666 | } | ||
| 900 | 667 | ||
| 901 | #ifndef CONFIG_DCACHE_DISABLED | 668 | /* |
| 669 | * Flush the range [start,end] of kernel virtual adddress space from | ||
| 670 | * the I-cache. The corresponding range must be purged from the | ||
| 671 | * D-cache also because the SH-5 doesn't have cache snooping between | ||
| 672 | * the caches. The addresses will be visible through the superpage | ||
| 673 | * mapping, therefore it's guaranteed that there no cache entries for | ||
| 674 | * the range in cache sets of the wrong colour. | ||
| 675 | */ | ||
| 676 | void flush_icache_range(unsigned long start, unsigned long end) | ||
| 677 | { | ||
| 678 | __flush_purge_region((void *)start, end); | ||
| 679 | wmb(); | ||
| 680 | sh64_icache_inv_kernel_range(start, end); | ||
| 681 | } | ||
| 902 | 682 | ||
| 903 | void copy_user_page(void *to, void *from, unsigned long address, struct page *page) | 683 | /* |
| 684 | * Flush the range of user (defined by vma->vm_mm) address space starting | ||
| 685 | * at 'addr' for 'len' bytes from the cache. The range does not straddle | ||
| 686 | * a page boundary, the unique physical page containing the range is | ||
| 687 | * 'page'. This seems to be used mainly for invalidating an address | ||
| 688 | * range following a poke into the program text through the ptrace() call | ||
| 689 | * from another process (e.g. for BRK instruction insertion). | ||
| 690 | */ | ||
| 691 | void flush_icache_user_range(struct vm_area_struct *vma, | ||
| 692 | struct page *page, unsigned long addr, int len) | ||
| 904 | { | 693 | { |
| 905 | /* 'from' and 'to' are kernel virtual addresses (within the superpage | ||
| 906 | mapping of the physical RAM). 'address' is the user virtual address | ||
| 907 | where the copy 'to' will be mapped after. This allows a custom | ||
| 908 | mapping to be used to ensure that the new copy is placed in the | ||
| 909 | right cache sets for the user to see it without having to bounce it | ||
| 910 | out via memory. Note however : the call to flush_page_to_ram in | ||
| 911 | (generic)/mm/memory.c:(break_cow) undoes all this good work in that one | ||
| 912 | very important case! | ||
| 913 | |||
| 914 | TBD : can we guarantee that on every call, any cache entries for | ||
| 915 | 'from' are in the same colour sets as 'address' also? i.e. is this | ||
| 916 | always used just to deal with COW? (I suspect not). */ | ||
| 917 | |||
| 918 | /* There are two possibilities here for when the page 'from' was last accessed: | ||
| 919 | * by the kernel : this is OK, no purge required. | ||
| 920 | * by the/a user (e.g. for break_COW) : need to purge. | ||
| 921 | |||
| 922 | If the potential user mapping at 'address' is the same colour as | ||
| 923 | 'from' there is no need to purge any cache lines from the 'from' | ||
| 924 | page mapped into cache sets of colour 'address'. (The copy will be | ||
| 925 | accessing the page through 'from'). | ||
| 926 | */ | ||
| 927 | 694 | ||
| 928 | if (((address ^ (unsigned long) from) & CACHE_OC_SYN_MASK) != 0) { | 695 | sh64_dcache_purge_coloured_phy_page(page_to_phys(page), addr); |
| 929 | sh64_dcache_purge_coloured_phy_page(__pa(from), address); | 696 | mb(); |
| 930 | } | ||
| 931 | 697 | ||
| 932 | if (((address ^ (unsigned long) to) & CACHE_OC_SYN_MASK) == 0) { | 698 | if (vma->vm_flags & VM_EXEC) |
| 933 | /* No synonym problem on destination */ | 699 | sh64_icache_inv_user_small_range(vma->vm_mm, addr, len); |
| 934 | sh64_page_copy(from, to); | 700 | } |
| 935 | } else { | 701 | |
| 936 | sh64_copy_user_page_coloured(to, from, address); | 702 | /* |
| 937 | } | 703 | * For the address range [start,end), write back the data from the |
| 704 | * D-cache and invalidate the corresponding region of the I-cache for the | ||
| 705 | * current process. Used to flush signal trampolines on the stack to | ||
| 706 | * make them executable. | ||
| 707 | */ | ||
| 708 | void flush_cache_sigtramp(unsigned long vaddr) | ||
| 709 | { | ||
| 710 | unsigned long end = vaddr + L1_CACHE_BYTES; | ||
| 938 | 711 | ||
| 939 | /* Note, don't need to flush 'from' page from the cache again - it's | 712 | __flush_wback_region((void *)vaddr, L1_CACHE_BYTES); |
| 940 | done anyway by the generic code */ | 713 | wmb(); |
| 714 | sh64_icache_inv_current_user_range(vaddr, end); | ||
| 941 | } | 715 | } |
| 942 | 716 | ||
| 943 | void clear_user_page(void *to, unsigned long address, struct page *page) | 717 | /* |
| 718 | * These *MUST* lie in an area of virtual address space that's otherwise | ||
| 719 | * unused. | ||
| 720 | */ | ||
| 721 | #define UNIQUE_EADDR_START 0xe0000000UL | ||
| 722 | #define UNIQUE_EADDR_END 0xe8000000UL | ||
| 723 | |||
| 724 | /* | ||
| 725 | * Given a physical address paddr, and a user virtual address user_eaddr | ||
| 726 | * which will eventually be mapped to it, create a one-off kernel-private | ||
| 727 | * eaddr mapped to the same paddr. This is used for creating special | ||
| 728 | * destination pages for copy_user_page and clear_user_page. | ||
| 729 | */ | ||
| 730 | static unsigned long sh64_make_unique_eaddr(unsigned long user_eaddr, | ||
| 731 | unsigned long paddr) | ||
| 944 | { | 732 | { |
| 945 | /* 'to' is a kernel virtual address (within the superpage | 733 | static unsigned long current_pointer = UNIQUE_EADDR_START; |
| 946 | mapping of the physical RAM). 'address' is the user virtual address | 734 | unsigned long coloured_pointer; |
| 947 | where the 'to' page will be mapped after. This allows a custom | ||
| 948 | mapping to be used to ensure that the new copy is placed in the | ||
| 949 | right cache sets for the user to see it without having to bounce it | ||
| 950 | out via memory. | ||
| 951 | */ | ||
| 952 | 735 | ||
| 953 | if (((address ^ (unsigned long) to) & CACHE_OC_SYN_MASK) == 0) { | 736 | if (current_pointer == UNIQUE_EADDR_END) { |
| 954 | /* No synonym problem on destination */ | 737 | sh64_dcache_purge_all(); |
| 955 | sh64_page_clear(to); | 738 | current_pointer = UNIQUE_EADDR_START; |
| 956 | } else { | ||
| 957 | sh64_clear_user_page_coloured(to, address); | ||
| 958 | } | 739 | } |
| 959 | } | ||
| 960 | 740 | ||
| 961 | #endif /* !CONFIG_DCACHE_DISABLED */ | 741 | coloured_pointer = (current_pointer & ~CACHE_OC_SYN_MASK) | |
| 742 | (user_eaddr & CACHE_OC_SYN_MASK); | ||
| 743 | sh64_setup_dtlb_cache_slot(coloured_pointer, get_asid(), paddr); | ||
| 962 | 744 | ||
| 963 | /****************************************************************************/ | 745 | current_pointer += (PAGE_SIZE << CACHE_OC_N_SYNBITS); |
| 964 | 746 | ||
| 965 | void flush_dcache_page(struct page *page) | 747 | return coloured_pointer; |
| 966 | { | ||
| 967 | sh64_dcache_purge_phy_page(page_to_phys(page)); | ||
| 968 | wmb(); | ||
| 969 | } | 748 | } |
| 970 | 749 | ||
| 971 | /****************************************************************************/ | 750 | static void sh64_copy_user_page_coloured(void *to, void *from, |
| 972 | 751 | unsigned long address) | |
| 973 | void flush_icache_range(unsigned long start, unsigned long end) | ||
| 974 | { | 752 | { |
| 975 | /* Flush the range [start,end] of kernel virtual adddress space from | 753 | void *coloured_to; |
| 976 | the I-cache. The corresponding range must be purged from the | ||
| 977 | D-cache also because the SH-5 doesn't have cache snooping between | ||
| 978 | the caches. The addresses will be visible through the superpage | ||
| 979 | mapping, therefore it's guaranteed that there no cache entries for | ||
| 980 | the range in cache sets of the wrong colour. | ||
| 981 | 754 | ||
| 982 | Primarily used for cohering the I-cache after a module has | 755 | /* |
| 983 | been loaded. */ | 756 | * Discard any existing cache entries of the wrong colour. These are |
| 757 | * present quite often, if the kernel has recently used the page | ||
| 758 | * internally, then given it up, then it's been allocated to the user. | ||
| 759 | */ | ||
| 760 | sh64_dcache_purge_coloured_phy_page(__pa(to), (unsigned long)to); | ||
| 984 | 761 | ||
| 985 | /* We also make sure to purge the same range from the D-cache since | 762 | coloured_to = (void *)sh64_make_unique_eaddr(address, __pa(to)); |
| 986 | flush_page_to_ram() won't be doing this for us! */ | 763 | copy_page(from, coloured_to); |
| 987 | 764 | ||
| 988 | sh64_dcache_purge_kernel_range(start, end); | 765 | sh64_teardown_dtlb_cache_slot(); |
| 989 | wmb(); | ||
| 990 | sh64_icache_inv_kernel_range(start, end); | ||
| 991 | } | 766 | } |
| 992 | 767 | ||
| 993 | /****************************************************************************/ | 768 | static void sh64_clear_user_page_coloured(void *to, unsigned long address) |
| 994 | |||
| 995 | void flush_icache_user_range(struct vm_area_struct *vma, | ||
| 996 | struct page *page, unsigned long addr, int len) | ||
| 997 | { | 769 | { |
| 998 | /* Flush the range of user (defined by vma->vm_mm) address space | 770 | void *coloured_to; |
| 999 | starting at 'addr' for 'len' bytes from the cache. The range does | ||
| 1000 | not straddle a page boundary, the unique physical page containing | ||
| 1001 | the range is 'page'. This seems to be used mainly for invalidating | ||
| 1002 | an address range following a poke into the program text through the | ||
| 1003 | ptrace() call from another process (e.g. for BRK instruction | ||
| 1004 | insertion). */ | ||
| 1005 | 771 | ||
| 1006 | sh64_dcache_purge_coloured_phy_page(page_to_phys(page), addr); | 772 | /* |
| 1007 | mb(); | 773 | * Discard any existing kernel-originated lines of the wrong |
| 774 | * colour (as above) | ||
| 775 | */ | ||
| 776 | sh64_dcache_purge_coloured_phy_page(__pa(to), (unsigned long)to); | ||
| 1008 | 777 | ||
| 1009 | if (vma->vm_flags & VM_EXEC) { | 778 | coloured_to = (void *)sh64_make_unique_eaddr(address, __pa(to)); |
| 1010 | sh64_icache_inv_user_small_range(vma->vm_mm, addr, len); | 779 | clear_page(coloured_to); |
| 1011 | } | ||
| 1012 | } | ||
| 1013 | 780 | ||
| 1014 | /*########################################################################## | 781 | sh64_teardown_dtlb_cache_slot(); |
| 1015 | ARCH/SH64 PRIVATE CALLABLE API. | 782 | } |
| 1016 | ##########################################################################*/ | ||
| 1017 | 783 | ||
| 1018 | void flush_cache_sigtramp(unsigned long start, unsigned long end) | 784 | /* |
| 785 | * 'from' and 'to' are kernel virtual addresses (within the superpage | ||
| 786 | * mapping of the physical RAM). 'address' is the user virtual address | ||
| 787 | * where the copy 'to' will be mapped after. This allows a custom | ||
| 788 | * mapping to be used to ensure that the new copy is placed in the | ||
| 789 | * right cache sets for the user to see it without having to bounce it | ||
| 790 | * out via memory. Note however : the call to flush_page_to_ram in | ||
| 791 | * (generic)/mm/memory.c:(break_cow) undoes all this good work in that one | ||
| 792 | * very important case! | ||
| 793 | * | ||
| 794 | * TBD : can we guarantee that on every call, any cache entries for | ||
| 795 | * 'from' are in the same colour sets as 'address' also? i.e. is this | ||
| 796 | * always used just to deal with COW? (I suspect not). | ||
| 797 | * | ||
| 798 | * There are two possibilities here for when the page 'from' was last accessed: | ||
| 799 | * - by the kernel : this is OK, no purge required. | ||
| 800 | * - by the/a user (e.g. for break_COW) : need to purge. | ||
| 801 | * | ||
| 802 | * If the potential user mapping at 'address' is the same colour as | ||
| 803 | * 'from' there is no need to purge any cache lines from the 'from' | ||
| 804 | * page mapped into cache sets of colour 'address'. (The copy will be | ||
| 805 | * accessing the page through 'from'). | ||
| 806 | */ | ||
| 807 | void copy_user_page(void *to, void *from, unsigned long address, | ||
| 808 | struct page *page) | ||
| 1019 | { | 809 | { |
| 1020 | /* For the address range [start,end), write back the data from the | 810 | if (((address ^ (unsigned long) from) & CACHE_OC_SYN_MASK) != 0) |
| 1021 | D-cache and invalidate the corresponding region of the I-cache for | 811 | sh64_dcache_purge_coloured_phy_page(__pa(from), address); |
| 1022 | the current process. Used to flush signal trampolines on the stack | ||
| 1023 | to make them executable. */ | ||
| 1024 | 812 | ||
| 1025 | sh64_dcache_wback_current_user_range(start, end); | 813 | if (((address ^ (unsigned long) to) & CACHE_OC_SYN_MASK) == 0) |
| 1026 | wmb(); | 814 | copy_page(to, from); |
| 1027 | sh64_icache_inv_current_user_range(start, end); | 815 | else |
| 816 | sh64_copy_user_page_coloured(to, from, address); | ||
| 1028 | } | 817 | } |
| 1029 | 818 | ||
| 819 | /* | ||
| 820 | * 'to' is a kernel virtual address (within the superpage mapping of the | ||
| 821 | * physical RAM). 'address' is the user virtual address where the 'to' | ||
| 822 | * page will be mapped after. This allows a custom mapping to be used to | ||
| 823 | * ensure that the new copy is placed in the right cache sets for the | ||
| 824 | * user to see it without having to bounce it out via memory. | ||
| 825 | */ | ||
| 826 | void clear_user_page(void *to, unsigned long address, struct page *page) | ||
| 827 | { | ||
| 828 | if (((address ^ (unsigned long) to) & CACHE_OC_SYN_MASK) == 0) | ||
| 829 | clear_page(to); | ||
| 830 | else | ||
| 831 | sh64_clear_user_page_coloured(to, address); | ||
| 832 | } | ||
diff --git a/arch/sh/mm/consistent.c b/arch/sh/mm/consistent.c index 7b2131c9eeda..d3c33fc5b1c2 100644 --- a/arch/sh/mm/consistent.c +++ b/arch/sh/mm/consistent.c | |||
| @@ -26,7 +26,7 @@ struct dma_coherent_mem { | |||
| 26 | void *dma_alloc_coherent(struct device *dev, size_t size, | 26 | void *dma_alloc_coherent(struct device *dev, size_t size, |
| 27 | dma_addr_t *dma_handle, gfp_t gfp) | 27 | dma_addr_t *dma_handle, gfp_t gfp) |
| 28 | { | 28 | { |
| 29 | void *ret; | 29 | void *ret, *ret_nocache; |
| 30 | struct dma_coherent_mem *mem = dev ? dev->dma_mem : NULL; | 30 | struct dma_coherent_mem *mem = dev ? dev->dma_mem : NULL; |
| 31 | int order = get_order(size); | 31 | int order = get_order(size); |
| 32 | 32 | ||
| @@ -44,17 +44,24 @@ void *dma_alloc_coherent(struct device *dev, size_t size, | |||
| 44 | } | 44 | } |
| 45 | 45 | ||
| 46 | ret = (void *)__get_free_pages(gfp, order); | 46 | ret = (void *)__get_free_pages(gfp, order); |
| 47 | 47 | if (!ret) | |
| 48 | if (ret != NULL) { | 48 | return NULL; |
| 49 | memset(ret, 0, size); | 49 | |
| 50 | /* | 50 | memset(ret, 0, size); |
| 51 | * Pages from the page allocator may have data present in | 51 | /* |
| 52 | * cache. So flush the cache before using uncached memory. | 52 | * Pages from the page allocator may have data present in |
| 53 | */ | 53 | * cache. So flush the cache before using uncached memory. |
| 54 | dma_cache_sync(NULL, ret, size, DMA_BIDIRECTIONAL); | 54 | */ |
| 55 | *dma_handle = virt_to_phys(ret); | 55 | dma_cache_sync(dev, ret, size, DMA_BIDIRECTIONAL); |
| 56 | |||
| 57 | ret_nocache = ioremap_nocache(virt_to_phys(ret), size); | ||
| 58 | if (!ret_nocache) { | ||
| 59 | free_pages((unsigned long)ret, order); | ||
| 60 | return NULL; | ||
| 56 | } | 61 | } |
| 57 | return ret; | 62 | |
| 63 | *dma_handle = virt_to_phys(ret); | ||
| 64 | return ret_nocache; | ||
| 58 | } | 65 | } |
| 59 | EXPORT_SYMBOL(dma_alloc_coherent); | 66 | EXPORT_SYMBOL(dma_alloc_coherent); |
| 60 | 67 | ||
| @@ -71,7 +78,8 @@ void dma_free_coherent(struct device *dev, size_t size, | |||
| 71 | } else { | 78 | } else { |
| 72 | WARN_ON(irqs_disabled()); /* for portability */ | 79 | WARN_ON(irqs_disabled()); /* for portability */ |
| 73 | BUG_ON(mem && mem->flags & DMA_MEMORY_EXCLUSIVE); | 80 | BUG_ON(mem && mem->flags & DMA_MEMORY_EXCLUSIVE); |
| 74 | free_pages((unsigned long)vaddr, order); | 81 | free_pages((unsigned long)phys_to_virt(dma_handle), order); |
| 82 | iounmap(vaddr); | ||
| 75 | } | 83 | } |
| 76 | } | 84 | } |
| 77 | EXPORT_SYMBOL(dma_free_coherent); | 85 | EXPORT_SYMBOL(dma_free_coherent); |
diff --git a/arch/sh/mm/fault_32.c b/arch/sh/mm/fault_32.c index 33b43d20e9f6..d1fa27594c6e 100644 --- a/arch/sh/mm/fault_32.c +++ b/arch/sh/mm/fault_32.c | |||
| @@ -15,6 +15,7 @@ | |||
| 15 | #include <linux/mm.h> | 15 | #include <linux/mm.h> |
| 16 | #include <linux/hardirq.h> | 16 | #include <linux/hardirq.h> |
| 17 | #include <linux/kprobes.h> | 17 | #include <linux/kprobes.h> |
| 18 | #include <asm/io_trapped.h> | ||
| 18 | #include <asm/system.h> | 19 | #include <asm/system.h> |
| 19 | #include <asm/mmu_context.h> | 20 | #include <asm/mmu_context.h> |
| 20 | #include <asm/tlbflush.h> | 21 | #include <asm/tlbflush.h> |
| @@ -163,6 +164,8 @@ no_context: | |||
| 163 | if (fixup_exception(regs)) | 164 | if (fixup_exception(regs)) |
| 164 | return; | 165 | return; |
| 165 | 166 | ||
| 167 | if (handle_trapped_io(regs, address)) | ||
| 168 | return; | ||
| 166 | /* | 169 | /* |
| 167 | * Oops. The kernel tried to access some bad page. We'll have to | 170 | * Oops. The kernel tried to access some bad page. We'll have to |
| 168 | * terminate things with extreme prejudice. | 171 | * terminate things with extreme prejudice. |
| @@ -296,6 +299,14 @@ asmlinkage int __kprobes __do_page_fault(struct pt_regs *regs, | |||
| 296 | entry = pte_mkdirty(entry); | 299 | entry = pte_mkdirty(entry); |
| 297 | entry = pte_mkyoung(entry); | 300 | entry = pte_mkyoung(entry); |
| 298 | 301 | ||
| 302 | #if defined(CONFIG_CPU_SH4) && !defined(CONFIG_SMP) | ||
| 303 | /* | ||
| 304 | * ITLB is not affected by "ldtlb" instruction. | ||
| 305 | * So, we need to flush the entry by ourselves. | ||
| 306 | */ | ||
| 307 | local_flush_tlb_one(get_asid(), address & PAGE_MASK); | ||
| 308 | #endif | ||
| 309 | |||
| 299 | set_pte(pte, entry); | 310 | set_pte(pte, entry); |
| 300 | update_mmu_cache(NULL, address, entry); | 311 | update_mmu_cache(NULL, address, entry); |
| 301 | 312 | ||
diff --git a/arch/sh/mm/init.c b/arch/sh/mm/init.c index 2918c6b14659..e2ed6dd252b9 100644 --- a/arch/sh/mm/init.c +++ b/arch/sh/mm/init.c | |||
| @@ -203,6 +203,7 @@ void __init paging_init(void) | |||
| 203 | 203 | ||
| 204 | free_area_init_nodes(max_zone_pfns); | 204 | free_area_init_nodes(max_zone_pfns); |
| 205 | 205 | ||
| 206 | #ifdef CONFIG_SUPERH32 | ||
| 206 | /* Set up the uncached fixmap */ | 207 | /* Set up the uncached fixmap */ |
| 207 | set_fixmap_nocache(FIX_UNCACHED, __pa(&__uncached_start)); | 208 | set_fixmap_nocache(FIX_UNCACHED, __pa(&__uncached_start)); |
| 208 | 209 | ||
| @@ -214,6 +215,7 @@ void __init paging_init(void) | |||
| 214 | */ | 215 | */ |
| 215 | cached_to_uncached = P2SEG - P1SEG; | 216 | cached_to_uncached = P2SEG - P1SEG; |
| 216 | #endif | 217 | #endif |
| 218 | #endif | ||
| 217 | } | 219 | } |
| 218 | 220 | ||
| 219 | static struct kcore_list kcore_mem, kcore_vmalloc; | 221 | static struct kcore_list kcore_mem, kcore_vmalloc; |
diff --git a/arch/sh/tools/mach-types b/arch/sh/tools/mach-types index 25810670a0fa..67997af25c0c 100644 --- a/arch/sh/tools/mach-types +++ b/arch/sh/tools/mach-types | |||
| @@ -45,3 +45,5 @@ MAGICPANELR2 SH_MAGIC_PANEL_R2 | |||
| 45 | R2D_PLUS RTS7751R2D_PLUS | 45 | R2D_PLUS RTS7751R2D_PLUS |
| 46 | R2D_1 RTS7751R2D_1 | 46 | R2D_1 RTS7751R2D_1 |
| 47 | CAYMAN SH_CAYMAN | 47 | CAYMAN SH_CAYMAN |
| 48 | SDK7780 SH_SDK7780 | ||
| 49 | MIGOR SH_MIGOR | ||
diff --git a/drivers/serial/sh-sci.c b/drivers/serial/sh-sci.c index ddf639144538..9ce12cb2cebc 100644 --- a/drivers/serial/sh-sci.c +++ b/drivers/serial/sh-sci.c | |||
| @@ -393,7 +393,7 @@ static void sci_init_pins_scif(struct uart_port *port, unsigned int cflag) | |||
| 393 | if (cflag & CRTSCTS) { | 393 | if (cflag & CRTSCTS) { |
| 394 | fcr_val |= SCFCR_MCE; | 394 | fcr_val |= SCFCR_MCE; |
| 395 | } else { | 395 | } else { |
| 396 | #ifdef CONFIG_CPU_SUBTYPE_SH7343 | 396 | #if defined(CONFIG_CPU_SUBTYPE_SH7343) || defined(CONFIG_CPU_SUBTYPE_SH7366) |
| 397 | /* Nothing */ | 397 | /* Nothing */ |
| 398 | #elif defined(CONFIG_CPU_SUBTYPE_SH7763) || \ | 398 | #elif defined(CONFIG_CPU_SUBTYPE_SH7763) || \ |
| 399 | defined(CONFIG_CPU_SUBTYPE_SH7780) || \ | 399 | defined(CONFIG_CPU_SUBTYPE_SH7780) || \ |
diff --git a/drivers/serial/sh-sci.h b/drivers/serial/sh-sci.h index f5764ebcfe07..01a9dd715f5d 100644 --- a/drivers/serial/sh-sci.h +++ b/drivers/serial/sh-sci.h | |||
| @@ -97,13 +97,18 @@ | |||
| 97 | # define SCSCR_INIT(port) 0x0038 /* TIE=0,RIE=0,TE=1,RE=1,REIE=1 */ | 97 | # define SCSCR_INIT(port) 0x0038 /* TIE=0,RIE=0,TE=1,RE=1,REIE=1 */ |
| 98 | # define SCIF_ONLY | 98 | # define SCIF_ONLY |
| 99 | # define PORT_PSCR 0xA405011E | 99 | # define PORT_PSCR 0xA405011E |
| 100 | #elif defined(CONFIG_CPU_SUBTYPE_SH7366) | ||
| 101 | # define SCPDR0 0xA405013E /* 16 bit SCIF0 PSDR */ | ||
| 102 | # define SCSPTR0 SCPDR0 | ||
| 103 | # define SCIF_ORER 0x0001 /* overrun error bit */ | ||
| 104 | # define SCSCR_INIT(port) 0x0038 /* TIE=0,RIE=0,TE=1,RE=1,REIE=1 */ | ||
| 105 | # define SCIF_ONLY | ||
| 100 | #elif defined(CONFIG_CPU_SUBTYPE_SH4_202) | 106 | #elif defined(CONFIG_CPU_SUBTYPE_SH4_202) |
| 101 | # define SCSPTR2 0xffe80020 /* 16 bit SCIF */ | 107 | # define SCSPTR2 0xffe80020 /* 16 bit SCIF */ |
| 102 | # define SCIF_ORER 0x0001 /* overrun error bit */ | 108 | # define SCIF_ORER 0x0001 /* overrun error bit */ |
| 103 | # define SCSCR_INIT(port) 0x38 /* TIE=0,RIE=0,TE=1,RE=1,REIE=1 */ | 109 | # define SCSCR_INIT(port) 0x38 /* TIE=0,RIE=0,TE=1,RE=1,REIE=1 */ |
| 104 | # define SCIF_ONLY | 110 | # define SCIF_ONLY |
| 105 | #elif defined(CONFIG_CPU_SUBTYPE_SH5_101) || defined(CONFIG_CPU_SUBTYPE_SH5_103) | 111 | #elif defined(CONFIG_CPU_SUBTYPE_SH5_101) || defined(CONFIG_CPU_SUBTYPE_SH5_103) |
| 106 | # include <asm/hardware.h> | ||
| 107 | # define SCIF_BASE_ADDR 0x01030000 | 112 | # define SCIF_BASE_ADDR 0x01030000 |
| 108 | # define SCIF_ADDR_SH5 PHYS_PERIPHERAL_BLOCK+SCIF_BASE_ADDR | 113 | # define SCIF_ADDR_SH5 PHYS_PERIPHERAL_BLOCK+SCIF_BASE_ADDR |
| 109 | # define SCIF_PTR2_OFFS 0x0000020 | 114 | # define SCIF_PTR2_OFFS 0x0000020 |
| @@ -577,7 +582,7 @@ static inline int sci_rxd_in(struct uart_port *port) | |||
| 577 | return ctrl_inw(SCSPTR3) & 0x0001 ? 1 : 0; /* SCIF */ | 582 | return ctrl_inw(SCSPTR3) & 0x0001 ? 1 : 0; /* SCIF */ |
| 578 | return 1; | 583 | return 1; |
| 579 | } | 584 | } |
| 580 | #elif defined(CONFIG_CPU_SUBTYPE_SH7722) | 585 | #elif defined(CONFIG_CPU_SUBTYPE_SH7722) || defined(CONFIG_CPU_SUBTYPE_SH7366) |
| 581 | static inline int sci_rxd_in(struct uart_port *port) | 586 | static inline int sci_rxd_in(struct uart_port *port) |
| 582 | { | 587 | { |
| 583 | if (port->mapbase == 0xffe00000) | 588 | if (port->mapbase == 0xffe00000) |
diff --git a/drivers/sh/maple/maple.c b/drivers/sh/maple/maple.c index e52a6296ca46..9cfcfd8dad5e 100644 --- a/drivers/sh/maple/maple.c +++ b/drivers/sh/maple/maple.c | |||
| @@ -31,6 +31,7 @@ | |||
| 31 | #include <asm/mach/dma.h> | 31 | #include <asm/mach/dma.h> |
| 32 | #include <asm/mach/sysasic.h> | 32 | #include <asm/mach/sysasic.h> |
| 33 | #include <asm/mach/maple.h> | 33 | #include <asm/mach/maple.h> |
| 34 | #include <linux/delay.h> | ||
| 34 | 35 | ||
| 35 | MODULE_AUTHOR("Yaegshi Takeshi, Paul Mundt, M.R. Brown, Adrian McMenamin"); | 36 | MODULE_AUTHOR("Yaegshi Takeshi, Paul Mundt, M.R. Brown, Adrian McMenamin"); |
| 36 | MODULE_DESCRIPTION("Maple bus driver for Dreamcast"); | 37 | MODULE_DESCRIPTION("Maple bus driver for Dreamcast"); |
| @@ -53,12 +54,12 @@ static struct device maple_bus; | |||
| 53 | static int subdevice_map[MAPLE_PORTS]; | 54 | static int subdevice_map[MAPLE_PORTS]; |
| 54 | static unsigned long *maple_sendbuf, *maple_sendptr, *maple_lastptr; | 55 | static unsigned long *maple_sendbuf, *maple_sendptr, *maple_lastptr; |
| 55 | static unsigned long maple_pnp_time; | 56 | static unsigned long maple_pnp_time; |
| 56 | static int started, scanning, liststatus; | 57 | static int started, scanning, liststatus, realscan; |
| 57 | static struct kmem_cache *maple_queue_cache; | 58 | static struct kmem_cache *maple_queue_cache; |
| 58 | 59 | ||
| 59 | struct maple_device_specify { | 60 | struct maple_device_specify { |
| 60 | int port; | 61 | int port; |
| 61 | int unit; | 62 | int unit; |
| 62 | }; | 63 | }; |
| 63 | 64 | ||
| 64 | /** | 65 | /** |
| @@ -68,22 +69,22 @@ struct maple_device_specify { | |||
| 68 | */ | 69 | */ |
| 69 | int maple_driver_register(struct device_driver *drv) | 70 | int maple_driver_register(struct device_driver *drv) |
| 70 | { | 71 | { |
| 71 | if (!drv) | 72 | if (!drv) |
| 72 | return -EINVAL; | 73 | return -EINVAL; |
| 73 | drv->bus = &maple_bus_type; | 74 | drv->bus = &maple_bus_type; |
| 74 | return driver_register(drv); | 75 | return driver_register(drv); |
| 75 | } | 76 | } |
| 76 | EXPORT_SYMBOL_GPL(maple_driver_register); | 77 | EXPORT_SYMBOL_GPL(maple_driver_register); |
| 77 | 78 | ||
| 78 | /* set hardware registers to enable next round of dma */ | 79 | /* set hardware registers to enable next round of dma */ |
| 79 | static void maplebus_dma_reset(void) | 80 | static void maplebus_dma_reset(void) |
| 80 | { | 81 | { |
| 81 | ctrl_outl(MAPLE_MAGIC, MAPLE_RESET); | 82 | ctrl_outl(MAPLE_MAGIC, MAPLE_RESET); |
| 82 | /* set trig type to 0 for software trigger, 1 for hardware (VBLANK) */ | 83 | /* set trig type to 0 for software trigger, 1 for hardware (VBLANK) */ |
| 83 | ctrl_outl(1, MAPLE_TRIGTYPE); | 84 | ctrl_outl(1, MAPLE_TRIGTYPE); |
| 84 | ctrl_outl(MAPLE_2MBPS | MAPLE_TIMEOUT(50000), MAPLE_SPEED); | 85 | ctrl_outl(MAPLE_2MBPS | MAPLE_TIMEOUT(50000), MAPLE_SPEED); |
| 85 | ctrl_outl(PHYSADDR(maple_sendbuf), MAPLE_DMAADDR); | 86 | ctrl_outl(PHYSADDR(maple_sendbuf), MAPLE_DMAADDR); |
| 86 | ctrl_outl(1, MAPLE_ENABLE); | 87 | ctrl_outl(1, MAPLE_ENABLE); |
| 87 | } | 88 | } |
| 88 | 89 | ||
| 89 | /** | 90 | /** |
| @@ -94,27 +95,36 @@ static void maplebus_dma_reset(void) | |||
| 94 | * @function: the function code for the device | 95 | * @function: the function code for the device |
| 95 | */ | 96 | */ |
| 96 | void maple_getcond_callback(struct maple_device *dev, | 97 | void maple_getcond_callback(struct maple_device *dev, |
| 97 | void (*callback) (struct mapleq * mq), | 98 | void (*callback) (struct mapleq *mq), |
| 98 | unsigned long interval, unsigned long function) | 99 | unsigned long interval, unsigned long function) |
| 99 | { | 100 | { |
| 100 | dev->callback = callback; | 101 | dev->callback = callback; |
| 101 | dev->interval = interval; | 102 | dev->interval = interval; |
| 102 | dev->function = cpu_to_be32(function); | 103 | dev->function = cpu_to_be32(function); |
| 103 | dev->when = jiffies; | 104 | dev->when = jiffies; |
| 104 | } | 105 | } |
| 105 | EXPORT_SYMBOL_GPL(maple_getcond_callback); | 106 | EXPORT_SYMBOL_GPL(maple_getcond_callback); |
| 106 | 107 | ||
| 107 | static int maple_dma_done(void) | 108 | static int maple_dma_done(void) |
| 108 | { | 109 | { |
| 109 | return (ctrl_inl(MAPLE_STATE) & 1) == 0; | 110 | return (ctrl_inl(MAPLE_STATE) & 1) == 0; |
| 110 | } | 111 | } |
| 111 | 112 | ||
| 112 | static void maple_release_device(struct device *dev) | 113 | static void maple_release_device(struct device *dev) |
| 113 | { | 114 | { |
| 114 | if (dev->type) { | 115 | struct maple_device *mdev; |
| 115 | kfree(dev->type->name); | 116 | struct mapleq *mq; |
| 116 | kfree(dev->type); | 117 | if (!dev) |
| 117 | } | 118 | return; |
| 119 | mdev = to_maple_dev(dev); | ||
| 120 | mq = mdev->mq; | ||
| 121 | if (mq) { | ||
| 122 | if (mq->recvbufdcsp) | ||
| 123 | kmem_cache_free(maple_queue_cache, mq->recvbufdcsp); | ||
| 124 | kfree(mq); | ||
| 125 | mq = NULL; | ||
| 126 | } | ||
| 127 | kfree(mdev); | ||
| 118 | } | 128 | } |
| 119 | 129 | ||
| 120 | /** | 130 | /** |
| @@ -123,60 +133,64 @@ static void maple_release_device(struct device *dev) | |||
| 123 | */ | 133 | */ |
| 124 | void maple_add_packet(struct mapleq *mq) | 134 | void maple_add_packet(struct mapleq *mq) |
| 125 | { | 135 | { |
| 126 | mutex_lock(&maple_list_lock); | 136 | mutex_lock(&maple_list_lock); |
| 127 | list_add(&mq->list, &maple_waitq); | 137 | list_add(&mq->list, &maple_waitq); |
| 128 | mutex_unlock(&maple_list_lock); | 138 | mutex_unlock(&maple_list_lock); |
| 129 | } | 139 | } |
| 130 | EXPORT_SYMBOL_GPL(maple_add_packet); | 140 | EXPORT_SYMBOL_GPL(maple_add_packet); |
| 131 | 141 | ||
| 132 | static struct mapleq *maple_allocq(struct maple_device *dev) | 142 | static struct mapleq *maple_allocq(struct maple_device *mdev) |
| 133 | { | 143 | { |
| 134 | struct mapleq *mq; | 144 | struct mapleq *mq; |
| 135 | 145 | ||
| 136 | mq = kmalloc(sizeof(*mq), GFP_KERNEL); | 146 | mq = kmalloc(sizeof(*mq), GFP_KERNEL); |
| 137 | if (!mq) | 147 | if (!mq) |
| 138 | return NULL; | 148 | return NULL; |
| 139 | 149 | ||
| 140 | mq->dev = dev; | 150 | mq->dev = mdev; |
| 141 | mq->recvbufdcsp = kmem_cache_zalloc(maple_queue_cache, GFP_KERNEL); | 151 | mq->recvbufdcsp = kmem_cache_zalloc(maple_queue_cache, GFP_KERNEL); |
| 142 | mq->recvbuf = (void *) P2SEGADDR(mq->recvbufdcsp); | 152 | mq->recvbuf = (void *) P2SEGADDR(mq->recvbufdcsp); |
| 143 | if (!mq->recvbuf) { | 153 | if (!mq->recvbuf) { |
| 144 | kfree(mq); | 154 | kfree(mq); |
| 145 | return NULL; | 155 | return NULL; |
| 146 | } | 156 | } |
| 147 | 157 | ||
| 148 | return mq; | 158 | return mq; |
| 149 | } | 159 | } |
| 150 | 160 | ||
| 151 | static struct maple_device *maple_alloc_dev(int port, int unit) | 161 | static struct maple_device *maple_alloc_dev(int port, int unit) |
| 152 | { | 162 | { |
| 153 | struct maple_device *dev; | 163 | struct maple_device *mdev; |
| 154 | 164 | ||
| 155 | dev = kzalloc(sizeof(*dev), GFP_KERNEL); | 165 | mdev = kzalloc(sizeof(*mdev), GFP_KERNEL); |
| 156 | if (!dev) | 166 | if (!mdev) |
| 157 | return NULL; | 167 | return NULL; |
| 158 | 168 | ||
| 159 | dev->port = port; | 169 | mdev->port = port; |
| 160 | dev->unit = unit; | 170 | mdev->unit = unit; |
| 161 | dev->mq = maple_allocq(dev); | 171 | mdev->mq = maple_allocq(mdev); |
| 162 | 172 | ||
| 163 | if (!dev->mq) { | 173 | if (!mdev->mq) { |
| 164 | kfree(dev); | 174 | kfree(mdev); |
| 165 | return NULL; | 175 | return NULL; |
| 166 | } | 176 | } |
| 167 | 177 | mdev->dev.bus = &maple_bus_type; | |
| 168 | return dev; | 178 | mdev->dev.parent = &maple_bus; |
| 179 | mdev->function = 0; | ||
| 180 | return mdev; | ||
| 169 | } | 181 | } |
| 170 | 182 | ||
| 171 | static void maple_free_dev(struct maple_device *mdev) | 183 | static void maple_free_dev(struct maple_device *mdev) |
| 172 | { | 184 | { |
| 173 | if (!mdev) | 185 | if (!mdev) |
| 174 | return; | 186 | return; |
| 175 | if (mdev->mq) { | 187 | if (mdev->mq) { |
| 176 | kmem_cache_free(maple_queue_cache, mdev->mq->recvbufdcsp); | 188 | if (mdev->mq->recvbufdcsp) |
| 177 | kfree(mdev->mq); | 189 | kmem_cache_free(maple_queue_cache, |
| 178 | } | 190 | mdev->mq->recvbufdcsp); |
| 179 | kfree(mdev); | 191 | kfree(mdev->mq); |
| 192 | } | ||
| 193 | kfree(mdev); | ||
| 180 | } | 194 | } |
| 181 | 195 | ||
| 182 | /* process the command queue into a maple command block | 196 | /* process the command queue into a maple command block |
| @@ -184,153 +198,162 @@ static void maple_free_dev(struct maple_device *mdev) | |||
| 184 | */ | 198 | */ |
| 185 | static void maple_build_block(struct mapleq *mq) | 199 | static void maple_build_block(struct mapleq *mq) |
| 186 | { | 200 | { |
| 187 | int port, unit, from, to, len; | 201 | int port, unit, from, to, len; |
| 188 | unsigned long *lsendbuf = mq->sendbuf; | 202 | unsigned long *lsendbuf = mq->sendbuf; |
| 189 | 203 | ||
| 190 | port = mq->dev->port & 3; | 204 | port = mq->dev->port & 3; |
| 191 | unit = mq->dev->unit; | 205 | unit = mq->dev->unit; |
| 192 | len = mq->length; | 206 | len = mq->length; |
| 193 | from = port << 6; | 207 | from = port << 6; |
| 194 | to = (port << 6) | (unit > 0 ? (1 << (unit - 1)) & 0x1f : 0x20); | 208 | to = (port << 6) | (unit > 0 ? (1 << (unit - 1)) & 0x1f : 0x20); |
| 195 | 209 | ||
| 196 | *maple_lastptr &= 0x7fffffff; | 210 | *maple_lastptr &= 0x7fffffff; |
| 197 | maple_lastptr = maple_sendptr; | 211 | maple_lastptr = maple_sendptr; |
| 198 | 212 | ||
| 199 | *maple_sendptr++ = (port << 16) | len | 0x80000000; | 213 | *maple_sendptr++ = (port << 16) | len | 0x80000000; |
| 200 | *maple_sendptr++ = PHYSADDR(mq->recvbuf); | 214 | *maple_sendptr++ = PHYSADDR(mq->recvbuf); |
| 201 | *maple_sendptr++ = | 215 | *maple_sendptr++ = |
| 202 | mq->command | (to << 8) | (from << 16) | (len << 24); | 216 | mq->command | (to << 8) | (from << 16) | (len << 24); |
| 203 | 217 | ||
| 204 | while (len-- > 0) | 218 | while (len-- > 0) |
| 205 | *maple_sendptr++ = *lsendbuf++; | 219 | *maple_sendptr++ = *lsendbuf++; |
| 206 | } | 220 | } |
| 207 | 221 | ||
| 208 | /* build up command queue */ | 222 | /* build up command queue */ |
| 209 | static void maple_send(void) | 223 | static void maple_send(void) |
| 210 | { | 224 | { |
| 211 | int i; | 225 | int i; |
| 212 | int maple_packets; | 226 | int maple_packets; |
| 213 | struct mapleq *mq, *nmq; | 227 | struct mapleq *mq, *nmq; |
| 214 | 228 | ||
| 215 | if (!list_empty(&maple_sentq)) | 229 | if (!list_empty(&maple_sentq)) |
| 216 | return; | 230 | return; |
| 217 | if (list_empty(&maple_waitq) || !maple_dma_done()) | 231 | if (list_empty(&maple_waitq) || !maple_dma_done()) |
| 218 | return; | 232 | return; |
| 219 | maple_packets = 0; | 233 | maple_packets = 0; |
| 220 | maple_sendptr = maple_lastptr = maple_sendbuf; | 234 | maple_sendptr = maple_lastptr = maple_sendbuf; |
| 221 | list_for_each_entry_safe(mq, nmq, &maple_waitq, list) { | 235 | list_for_each_entry_safe(mq, nmq, &maple_waitq, list) { |
| 222 | maple_build_block(mq); | 236 | maple_build_block(mq); |
| 223 | list_move(&mq->list, &maple_sentq); | 237 | list_move(&mq->list, &maple_sentq); |
| 224 | if (maple_packets++ > MAPLE_MAXPACKETS) | 238 | if (maple_packets++ > MAPLE_MAXPACKETS) |
| 225 | break; | 239 | break; |
| 226 | } | 240 | } |
| 227 | if (maple_packets > 0) { | 241 | if (maple_packets > 0) { |
| 228 | for (i = 0; i < (1 << MAPLE_DMA_PAGES); i++) | 242 | for (i = 0; i < (1 << MAPLE_DMA_PAGES); i++) |
| 229 | dma_cache_sync(0, maple_sendbuf + i * PAGE_SIZE, | 243 | dma_cache_sync(0, maple_sendbuf + i * PAGE_SIZE, |
| 230 | PAGE_SIZE, DMA_BIDIRECTIONAL); | 244 | PAGE_SIZE, DMA_BIDIRECTIONAL); |
| 231 | } | 245 | } |
| 232 | } | 246 | } |
| 233 | 247 | ||
| 234 | static int attach_matching_maple_driver(struct device_driver *driver, | 248 | static int attach_matching_maple_driver(struct device_driver *driver, |
| 235 | void *devptr) | 249 | void *devptr) |
| 236 | { | 250 | { |
| 237 | struct maple_driver *maple_drv; | 251 | struct maple_driver *maple_drv; |
| 238 | struct maple_device *mdev; | 252 | struct maple_device *mdev; |
| 239 | 253 | ||
| 240 | mdev = devptr; | 254 | mdev = devptr; |
| 241 | maple_drv = to_maple_driver(driver); | 255 | maple_drv = to_maple_driver(driver); |
| 242 | if (mdev->devinfo.function & be32_to_cpu(maple_drv->function)) { | 256 | if (mdev->devinfo.function & be32_to_cpu(maple_drv->function)) { |
| 243 | if (maple_drv->connect(mdev) == 0) { | 257 | if (maple_drv->connect(mdev) == 0) { |
| 244 | mdev->driver = maple_drv; | 258 | mdev->driver = maple_drv; |
| 245 | return 1; | 259 | return 1; |
| 246 | } | 260 | } |
| 247 | } | 261 | } |
| 248 | return 0; | 262 | return 0; |
| 249 | } | 263 | } |
| 250 | 264 | ||
| 251 | static void maple_detach_driver(struct maple_device *mdev) | 265 | static void maple_detach_driver(struct maple_device *mdev) |
| 252 | { | 266 | { |
| 253 | if (!mdev) | 267 | if (!mdev) |
| 254 | return; | 268 | return; |
| 255 | if (mdev->driver) { | 269 | if (mdev->driver) { |
| 256 | if (mdev->driver->disconnect) | 270 | if (mdev->driver->disconnect) |
| 257 | mdev->driver->disconnect(mdev); | 271 | mdev->driver->disconnect(mdev); |
| 258 | } | 272 | } |
| 259 | mdev->driver = NULL; | 273 | mdev->driver = NULL; |
| 260 | if (mdev->registered) { | 274 | device_unregister(&mdev->dev); |
| 261 | maple_release_device(&mdev->dev); | 275 | mdev = NULL; |
| 262 | device_unregister(&mdev->dev); | ||
| 263 | } | ||
| 264 | mdev->registered = 0; | ||
| 265 | maple_free_dev(mdev); | ||
| 266 | } | 276 | } |
| 267 | 277 | ||
| 268 | /* process initial MAPLE_COMMAND_DEVINFO for each device or port */ | 278 | /* process initial MAPLE_COMMAND_DEVINFO for each device or port */ |
| 269 | static void maple_attach_driver(struct maple_device *dev) | 279 | static void maple_attach_driver(struct maple_device *mdev) |
| 270 | { | 280 | { |
| 271 | char *p; | 281 | char *p, *recvbuf; |
| 272 | 282 | unsigned long function; | |
| 273 | char *recvbuf; | 283 | int matched, retval; |
| 274 | unsigned long function; | 284 | |
| 275 | int matched, retval; | 285 | recvbuf = mdev->mq->recvbuf; |
| 276 | 286 | /* copy the data as individual elements in | |
| 277 | recvbuf = dev->mq->recvbuf; | 287 | * case of memory optimisation */ |
| 278 | memcpy(&dev->devinfo, recvbuf + 4, sizeof(dev->devinfo)); | 288 | memcpy(&mdev->devinfo.function, recvbuf + 4, 4); |
| 279 | memcpy(dev->product_name, dev->devinfo.product_name, 30); | 289 | memcpy(&mdev->devinfo.function_data[0], recvbuf + 8, 12); |
| 280 | memcpy(dev->product_licence, dev->devinfo.product_licence, 60); | 290 | memcpy(&mdev->devinfo.area_code, recvbuf + 20, 1); |
| 281 | dev->product_name[30] = '\0'; | 291 | memcpy(&mdev->devinfo.connector_direction, recvbuf + 21, 1); |
| 282 | dev->product_licence[60] = '\0'; | 292 | memcpy(&mdev->devinfo.product_name[0], recvbuf + 22, 30); |
| 283 | 293 | memcpy(&mdev->devinfo.product_licence[0], recvbuf + 52, 60); | |
| 284 | for (p = dev->product_name + 29; dev->product_name <= p; p--) | 294 | memcpy(&mdev->devinfo.standby_power, recvbuf + 112, 2); |
| 285 | if (*p == ' ') | 295 | memcpy(&mdev->devinfo.max_power, recvbuf + 114, 2); |
| 286 | *p = '\0'; | 296 | memcpy(mdev->product_name, mdev->devinfo.product_name, 30); |
| 287 | else | 297 | mdev->product_name[30] = '\0'; |
| 288 | break; | 298 | memcpy(mdev->product_licence, mdev->devinfo.product_licence, 60); |
| 289 | 299 | mdev->product_licence[60] = '\0'; | |
| 290 | for (p = dev->product_licence + 59; dev->product_licence <= p; p--) | 300 | |
| 291 | if (*p == ' ') | 301 | for (p = mdev->product_name + 29; mdev->product_name <= p; p--) |
| 292 | *p = '\0'; | 302 | if (*p == ' ') |
| 293 | else | 303 | *p = '\0'; |
| 294 | break; | 304 | else |
| 295 | 305 | break; | |
| 296 | function = be32_to_cpu(dev->devinfo.function); | 306 | for (p = mdev->product_licence + 59; mdev->product_licence <= p; p--) |
| 297 | 307 | if (*p == ' ') | |
| 298 | if (function > 0x200) { | 308 | *p = '\0'; |
| 299 | /* Do this silently - as not a real device */ | 309 | else |
| 300 | function = 0; | 310 | break; |
| 301 | dev->driver = &maple_dummy_driver; | 311 | |
| 302 | sprintf(dev->dev.bus_id, "%d:0.port", dev->port); | 312 | if (realscan) { |
| 303 | } else { | 313 | printk(KERN_INFO "Maple device detected: %s\n", |
| 304 | printk(KERN_INFO | 314 | mdev->product_name); |
| 305 | "Maple bus at (%d, %d): Connected function 0x%lX\n", | 315 | printk(KERN_INFO "Maple device: %s\n", mdev->product_licence); |
| 306 | dev->port, dev->unit, function); | 316 | } |
| 307 | 317 | ||
| 308 | matched = | 318 | function = be32_to_cpu(mdev->devinfo.function); |
| 309 | bus_for_each_drv(&maple_bus_type, NULL, dev, | 319 | |
| 310 | attach_matching_maple_driver); | 320 | if (function > 0x200) { |
| 311 | 321 | /* Do this silently - as not a real device */ | |
| 312 | if (matched == 0) { | 322 | function = 0; |
| 313 | /* Driver does not exist yet */ | 323 | mdev->driver = &maple_dummy_driver; |
| 314 | printk(KERN_INFO | 324 | sprintf(mdev->dev.bus_id, "%d:0.port", mdev->port); |
| 315 | "No maple driver found for this device\n"); | 325 | } else { |
| 316 | dev->driver = &maple_dummy_driver; | 326 | if (realscan) |
| 317 | } | 327 | printk(KERN_INFO |
| 318 | 328 | "Maple bus at (%d, %d): Function 0x%lX\n", | |
| 319 | sprintf(dev->dev.bus_id, "%d:0%d.%lX", dev->port, | 329 | mdev->port, mdev->unit, function); |
| 320 | dev->unit, function); | 330 | |
| 321 | } | 331 | matched = |
| 322 | dev->function = function; | 332 | bus_for_each_drv(&maple_bus_type, NULL, mdev, |
| 323 | dev->dev.bus = &maple_bus_type; | 333 | attach_matching_maple_driver); |
| 324 | dev->dev.parent = &maple_bus; | 334 | |
| 325 | dev->dev.release = &maple_release_device; | 335 | if (matched == 0) { |
| 326 | retval = device_register(&dev->dev); | 336 | /* Driver does not exist yet */ |
| 327 | if (retval) { | 337 | if (realscan) |
| 328 | printk(KERN_INFO | 338 | printk(KERN_INFO |
| 329 | "Maple bus: Attempt to register device (%x, %x) failed.\n", | 339 | "No maple driver found.\n"); |
| 330 | dev->port, dev->unit); | 340 | mdev->driver = &maple_dummy_driver; |
| 331 | maple_free_dev(dev); | 341 | } |
| 332 | } | 342 | sprintf(mdev->dev.bus_id, "%d:0%d.%lX", mdev->port, |
| 333 | dev->registered = 1; | 343 | mdev->unit, function); |
| 344 | } | ||
| 345 | mdev->function = function; | ||
| 346 | mdev->dev.release = &maple_release_device; | ||
| 347 | retval = device_register(&mdev->dev); | ||
| 348 | if (retval) { | ||
| 349 | printk(KERN_INFO | ||
| 350 | "Maple bus: Attempt to register device" | ||
| 351 | " (%x, %x) failed.\n", | ||
| 352 | mdev->port, mdev->unit); | ||
| 353 | maple_free_dev(mdev); | ||
| 354 | mdev = NULL; | ||
| 355 | return; | ||
| 356 | } | ||
| 334 | } | 357 | } |
| 335 | 358 | ||
| 336 | /* | 359 | /* |
| @@ -340,270 +363,262 @@ static void maple_attach_driver(struct maple_device *dev) | |||
| 340 | */ | 363 | */ |
| 341 | static int detach_maple_device(struct device *device, void *portptr) | 364 | static int detach_maple_device(struct device *device, void *portptr) |
| 342 | { | 365 | { |
| 343 | struct maple_device_specify *ds; | 366 | struct maple_device_specify *ds; |
| 344 | struct maple_device *mdev; | 367 | struct maple_device *mdev; |
| 345 | 368 | ||
| 346 | ds = portptr; | 369 | ds = portptr; |
| 347 | mdev = to_maple_dev(device); | 370 | mdev = to_maple_dev(device); |
| 348 | if (mdev->port == ds->port && mdev->unit == ds->unit) | 371 | if (mdev->port == ds->port && mdev->unit == ds->unit) |
| 349 | return 1; | 372 | return 1; |
| 350 | return 0; | 373 | return 0; |
| 351 | } | 374 | } |
| 352 | 375 | ||
| 353 | static int setup_maple_commands(struct device *device, void *ignored) | 376 | static int setup_maple_commands(struct device *device, void *ignored) |
| 354 | { | 377 | { |
| 355 | struct maple_device *maple_dev = to_maple_dev(device); | 378 | struct maple_device *maple_dev = to_maple_dev(device); |
| 356 | 379 | ||
| 357 | if ((maple_dev->interval > 0) | 380 | if ((maple_dev->interval > 0) |
| 358 | && time_after(jiffies, maple_dev->when)) { | 381 | && time_after(jiffies, maple_dev->when)) { |
| 359 | maple_dev->when = jiffies + maple_dev->interval; | 382 | maple_dev->when = jiffies + maple_dev->interval; |
| 360 | maple_dev->mq->command = MAPLE_COMMAND_GETCOND; | 383 | maple_dev->mq->command = MAPLE_COMMAND_GETCOND; |
| 361 | maple_dev->mq->sendbuf = &maple_dev->function; | 384 | maple_dev->mq->sendbuf = &maple_dev->function; |
| 362 | maple_dev->mq->length = 1; | 385 | maple_dev->mq->length = 1; |
| 363 | maple_add_packet(maple_dev->mq); | 386 | maple_add_packet(maple_dev->mq); |
| 364 | liststatus++; | 387 | liststatus++; |
| 365 | } else { | 388 | } else { |
| 366 | if (time_after(jiffies, maple_pnp_time)) { | 389 | if (time_after(jiffies, maple_pnp_time)) { |
| 367 | maple_dev->mq->command = MAPLE_COMMAND_DEVINFO; | 390 | maple_dev->mq->command = MAPLE_COMMAND_DEVINFO; |
| 368 | maple_dev->mq->length = 0; | 391 | maple_dev->mq->length = 0; |
| 369 | maple_add_packet(maple_dev->mq); | 392 | maple_add_packet(maple_dev->mq); |
| 370 | liststatus++; | 393 | liststatus++; |
| 371 | } | 394 | } |
| 372 | } | 395 | } |
| 373 | 396 | ||
| 374 | return 0; | 397 | return 0; |
| 375 | } | 398 | } |
| 376 | 399 | ||
| 377 | /* VBLANK bottom half - implemented via workqueue */ | 400 | /* VBLANK bottom half - implemented via workqueue */ |
| 378 | static void maple_vblank_handler(struct work_struct *work) | 401 | static void maple_vblank_handler(struct work_struct *work) |
| 379 | { | 402 | { |
| 380 | if (!maple_dma_done()) | 403 | if (!maple_dma_done()) |
| 381 | return; | 404 | return; |
| 382 | if (!list_empty(&maple_sentq)) | 405 | if (!list_empty(&maple_sentq)) |
| 383 | return; | 406 | return; |
| 384 | ctrl_outl(0, MAPLE_ENABLE); | 407 | ctrl_outl(0, MAPLE_ENABLE); |
| 385 | liststatus = 0; | 408 | liststatus = 0; |
| 386 | bus_for_each_dev(&maple_bus_type, NULL, NULL, | 409 | bus_for_each_dev(&maple_bus_type, NULL, NULL, |
| 387 | setup_maple_commands); | 410 | setup_maple_commands); |
| 388 | if (time_after(jiffies, maple_pnp_time)) | 411 | if (time_after(jiffies, maple_pnp_time)) |
| 389 | maple_pnp_time = jiffies + MAPLE_PNP_INTERVAL; | 412 | maple_pnp_time = jiffies + MAPLE_PNP_INTERVAL; |
| 390 | if (liststatus && list_empty(&maple_sentq)) { | 413 | if (liststatus && list_empty(&maple_sentq)) { |
| 391 | INIT_LIST_HEAD(&maple_sentq); | 414 | INIT_LIST_HEAD(&maple_sentq); |
| 392 | maple_send(); | 415 | maple_send(); |
| 393 | } | 416 | } |
| 394 | maplebus_dma_reset(); | 417 | maplebus_dma_reset(); |
| 395 | } | 418 | } |
| 396 | 419 | ||
| 397 | /* handle devices added via hotplugs - placing them on queue for DEVINFO*/ | 420 | /* handle devices added via hotplugs - placing them on queue for DEVINFO*/ |
| 398 | static void maple_map_subunits(struct maple_device *mdev, int submask) | 421 | static void maple_map_subunits(struct maple_device *mdev, int submask) |
| 399 | { | 422 | { |
| 400 | int retval, k, devcheck; | 423 | int retval, k, devcheck; |
| 401 | struct maple_device *mdev_add; | 424 | struct maple_device *mdev_add; |
| 402 | struct maple_device_specify ds; | 425 | struct maple_device_specify ds; |
| 403 | 426 | ||
| 404 | for (k = 0; k < 5; k++) { | 427 | for (k = 0; k < 5; k++) { |
| 405 | ds.port = mdev->port; | 428 | ds.port = mdev->port; |
| 406 | ds.unit = k + 1; | 429 | ds.unit = k + 1; |
| 407 | retval = | 430 | retval = |
| 408 | bus_for_each_dev(&maple_bus_type, NULL, &ds, | 431 | bus_for_each_dev(&maple_bus_type, NULL, &ds, |
| 409 | detach_maple_device); | 432 | detach_maple_device); |
| 410 | if (retval) { | 433 | if (retval) { |
| 411 | submask = submask >> 1; | 434 | submask = submask >> 1; |
| 412 | continue; | 435 | continue; |
| 413 | } | 436 | } |
| 414 | devcheck = submask & 0x01; | 437 | devcheck = submask & 0x01; |
| 415 | if (devcheck) { | 438 | if (devcheck) { |
| 416 | mdev_add = maple_alloc_dev(mdev->port, k + 1); | 439 | mdev_add = maple_alloc_dev(mdev->port, k + 1); |
| 417 | if (!mdev_add) | 440 | if (!mdev_add) |
| 418 | return; | 441 | return; |
| 419 | mdev_add->mq->command = MAPLE_COMMAND_DEVINFO; | 442 | mdev_add->mq->command = MAPLE_COMMAND_DEVINFO; |
| 420 | mdev_add->mq->length = 0; | 443 | mdev_add->mq->length = 0; |
| 421 | maple_add_packet(mdev_add->mq); | 444 | maple_add_packet(mdev_add->mq); |
| 422 | scanning = 1; | 445 | scanning = 1; |
| 423 | } | 446 | } |
| 424 | submask = submask >> 1; | 447 | submask = submask >> 1; |
| 425 | } | 448 | } |
| 426 | } | 449 | } |
| 427 | 450 | ||
| 428 | /* mark a device as removed */ | 451 | /* mark a device as removed */ |
| 429 | static void maple_clean_submap(struct maple_device *mdev) | 452 | static void maple_clean_submap(struct maple_device *mdev) |
| 430 | { | 453 | { |
| 431 | int killbit; | 454 | int killbit; |
| 432 | 455 | ||
| 433 | killbit = (mdev->unit > 0 ? (1 << (mdev->unit - 1)) & 0x1f : 0x20); | 456 | killbit = (mdev->unit > 0 ? (1 << (mdev->unit - 1)) & 0x1f : 0x20); |
| 434 | killbit = ~killbit; | 457 | killbit = ~killbit; |
| 435 | killbit &= 0xFF; | 458 | killbit &= 0xFF; |
| 436 | subdevice_map[mdev->port] = subdevice_map[mdev->port] & killbit; | 459 | subdevice_map[mdev->port] = subdevice_map[mdev->port] & killbit; |
| 437 | } | 460 | } |
| 438 | 461 | ||
| 439 | /* handle empty port or hotplug removal */ | 462 | /* handle empty port or hotplug removal */ |
| 440 | static void maple_response_none(struct maple_device *mdev, | 463 | static void maple_response_none(struct maple_device *mdev, |
| 441 | struct mapleq *mq) | 464 | struct mapleq *mq) |
| 442 | { | 465 | { |
| 443 | if (mdev->unit != 0) { | 466 | if (mdev->unit != 0) { |
| 444 | list_del(&mq->list); | 467 | list_del(&mq->list); |
| 445 | maple_clean_submap(mdev); | 468 | maple_clean_submap(mdev); |
| 446 | printk(KERN_INFO | 469 | printk(KERN_INFO |
| 447 | "Maple bus device detaching at (%d, %d)\n", | 470 | "Maple bus device detaching at (%d, %d)\n", |
| 448 | mdev->port, mdev->unit); | 471 | mdev->port, mdev->unit); |
| 449 | maple_detach_driver(mdev); | 472 | maple_detach_driver(mdev); |
| 450 | return; | 473 | return; |
| 451 | } | 474 | } |
| 452 | if (!started) { | 475 | if (!started) { |
| 453 | printk(KERN_INFO "No maple devices attached to port %d\n", | 476 | printk(KERN_INFO "No maple devices attached to port %d\n", |
| 454 | mdev->port); | 477 | mdev->port); |
| 455 | return; | 478 | return; |
| 456 | } | 479 | } |
| 457 | maple_clean_submap(mdev); | 480 | maple_clean_submap(mdev); |
| 458 | } | 481 | } |
| 459 | 482 | ||
| 460 | /* preprocess hotplugs or scans */ | 483 | /* preprocess hotplugs or scans */ |
| 461 | static void maple_response_devinfo(struct maple_device *mdev, | 484 | static void maple_response_devinfo(struct maple_device *mdev, |
| 462 | char *recvbuf) | 485 | char *recvbuf) |
| 463 | { | 486 | { |
| 464 | char submask; | 487 | char submask; |
| 465 | if ((!started) || (scanning == 2)) { | 488 | if ((!started) || (scanning == 2)) { |
| 466 | maple_attach_driver(mdev); | 489 | maple_attach_driver(mdev); |
| 467 | return; | 490 | return; |
| 468 | } | 491 | } |
| 469 | if (mdev->unit == 0) { | 492 | if (mdev->unit == 0) { |
| 470 | submask = recvbuf[2] & 0x1F; | 493 | submask = recvbuf[2] & 0x1F; |
| 471 | if (submask ^ subdevice_map[mdev->port]) { | 494 | if (submask ^ subdevice_map[mdev->port]) { |
| 472 | maple_map_subunits(mdev, submask); | 495 | maple_map_subunits(mdev, submask); |
| 473 | subdevice_map[mdev->port] = submask; | 496 | subdevice_map[mdev->port] = submask; |
| 474 | } | 497 | } |
| 475 | } | 498 | } |
| 476 | } | 499 | } |
| 477 | 500 | ||
| 478 | /* maple dma end bottom half - implemented via workqueue */ | 501 | /* maple dma end bottom half - implemented via workqueue */ |
| 479 | static void maple_dma_handler(struct work_struct *work) | 502 | static void maple_dma_handler(struct work_struct *work) |
| 480 | { | 503 | { |
| 481 | struct mapleq *mq, *nmq; | 504 | struct mapleq *mq, *nmq; |
| 482 | struct maple_device *dev; | 505 | struct maple_device *dev; |
| 483 | char *recvbuf; | 506 | char *recvbuf; |
| 484 | enum maple_code code; | 507 | enum maple_code code; |
| 485 | 508 | ||
| 486 | if (!maple_dma_done()) | 509 | if (!maple_dma_done()) |
| 487 | return; | 510 | return; |
| 488 | ctrl_outl(0, MAPLE_ENABLE); | 511 | ctrl_outl(0, MAPLE_ENABLE); |
| 489 | if (!list_empty(&maple_sentq)) { | 512 | if (!list_empty(&maple_sentq)) { |
| 490 | list_for_each_entry_safe(mq, nmq, &maple_sentq, list) { | 513 | list_for_each_entry_safe(mq, nmq, &maple_sentq, list) { |
| 491 | recvbuf = mq->recvbuf; | 514 | recvbuf = mq->recvbuf; |
| 492 | code = recvbuf[0]; | 515 | code = recvbuf[0]; |
| 493 | dev = mq->dev; | 516 | dev = mq->dev; |
| 494 | switch (code) { | 517 | switch (code) { |
| 495 | case MAPLE_RESPONSE_NONE: | 518 | case MAPLE_RESPONSE_NONE: |
| 496 | maple_response_none(dev, mq); | 519 | maple_response_none(dev, mq); |
| 497 | break; | 520 | break; |
| 498 | 521 | ||
| 499 | case MAPLE_RESPONSE_DEVINFO: | 522 | case MAPLE_RESPONSE_DEVINFO: |
| 500 | maple_response_devinfo(dev, recvbuf); | 523 | maple_response_devinfo(dev, recvbuf); |
| 501 | break; | 524 | break; |
| 502 | 525 | ||
| 503 | case MAPLE_RESPONSE_DATATRF: | 526 | case MAPLE_RESPONSE_DATATRF: |
| 504 | if (dev->callback) | 527 | if (dev->callback) |
| 505 | dev->callback(mq); | 528 | dev->callback(mq); |
| 506 | break; | 529 | break; |
| 507 | 530 | ||
| 508 | case MAPLE_RESPONSE_FILEERR: | 531 | case MAPLE_RESPONSE_FILEERR: |
| 509 | case MAPLE_RESPONSE_AGAIN: | 532 | case MAPLE_RESPONSE_AGAIN: |
| 510 | case MAPLE_RESPONSE_BADCMD: | 533 | case MAPLE_RESPONSE_BADCMD: |
| 511 | case MAPLE_RESPONSE_BADFUNC: | 534 | case MAPLE_RESPONSE_BADFUNC: |
| 512 | printk(KERN_DEBUG | 535 | printk(KERN_DEBUG |
| 513 | "Maple non-fatal error 0x%X\n", | 536 | "Maple non-fatal error 0x%X\n", |
| 514 | code); | 537 | code); |
| 515 | break; | 538 | break; |
| 516 | 539 | ||
| 517 | case MAPLE_RESPONSE_ALLINFO: | 540 | case MAPLE_RESPONSE_ALLINFO: |
| 518 | printk(KERN_DEBUG | 541 | printk(KERN_DEBUG |
| 519 | "Maple - extended device information not supported\n"); | 542 | "Maple - extended device information" |
| 520 | break; | 543 | " not supported\n"); |
| 521 | 544 | break; | |
| 522 | case MAPLE_RESPONSE_OK: | 545 | |
| 523 | break; | 546 | case MAPLE_RESPONSE_OK: |
| 524 | 547 | break; | |
| 525 | default: | 548 | |
| 526 | break; | 549 | default: |
| 527 | } | 550 | break; |
| 528 | } | 551 | } |
| 529 | INIT_LIST_HEAD(&maple_sentq); | 552 | } |
| 530 | if (scanning == 1) { | 553 | INIT_LIST_HEAD(&maple_sentq); |
| 531 | maple_send(); | 554 | if (scanning == 1) { |
| 532 | scanning = 2; | 555 | maple_send(); |
| 533 | } else | 556 | scanning = 2; |
| 534 | scanning = 0; | 557 | } else |
| 535 | 558 | scanning = 0; | |
| 536 | if (started == 0) | 559 | |
| 537 | started = 1; | 560 | if (started == 0) |
| 538 | } | 561 | started = 1; |
| 539 | maplebus_dma_reset(); | 562 | } |
| 563 | maplebus_dma_reset(); | ||
| 540 | } | 564 | } |
| 541 | 565 | ||
| 542 | static irqreturn_t maplebus_dma_interrupt(int irq, void *dev_id) | 566 | static irqreturn_t maplebus_dma_interrupt(int irq, void *dev_id) |
| 543 | { | 567 | { |
| 544 | /* Load everything into the bottom half */ | 568 | /* Load everything into the bottom half */ |
| 545 | schedule_work(&maple_dma_process); | 569 | schedule_work(&maple_dma_process); |
| 546 | return IRQ_HANDLED; | 570 | return IRQ_HANDLED; |
| 547 | } | 571 | } |
| 548 | 572 | ||
| 549 | static irqreturn_t maplebus_vblank_interrupt(int irq, void *dev_id) | 573 | static irqreturn_t maplebus_vblank_interrupt(int irq, void *dev_id) |
| 550 | { | 574 | { |
| 551 | schedule_work(&maple_vblank_process); | 575 | schedule_work(&maple_vblank_process); |
| 552 | return IRQ_HANDLED; | 576 | return IRQ_HANDLED; |
| 553 | } | 577 | } |
| 554 | 578 | ||
| 555 | static struct irqaction maple_dma_irq = { | ||
| 556 | .name = "maple bus DMA handler", | ||
| 557 | .handler = maplebus_dma_interrupt, | ||
| 558 | .flags = IRQF_SHARED, | ||
| 559 | }; | ||
| 560 | |||
| 561 | static struct irqaction maple_vblank_irq = { | ||
| 562 | .name = "maple bus VBLANK handler", | ||
| 563 | .handler = maplebus_vblank_interrupt, | ||
| 564 | .flags = IRQF_SHARED, | ||
| 565 | }; | ||
| 566 | |||
| 567 | static int maple_set_dma_interrupt_handler(void) | 579 | static int maple_set_dma_interrupt_handler(void) |
| 568 | { | 580 | { |
| 569 | return setup_irq(HW_EVENT_MAPLE_DMA, &maple_dma_irq); | 581 | return request_irq(HW_EVENT_MAPLE_DMA, maplebus_dma_interrupt, |
| 582 | IRQF_SHARED, "maple bus DMA", &maple_dummy_driver); | ||
| 570 | } | 583 | } |
| 571 | 584 | ||
| 572 | static int maple_set_vblank_interrupt_handler(void) | 585 | static int maple_set_vblank_interrupt_handler(void) |
| 573 | { | 586 | { |
| 574 | return setup_irq(HW_EVENT_VSYNC, &maple_vblank_irq); | 587 | return request_irq(HW_EVENT_VSYNC, maplebus_vblank_interrupt, |
| 588 | IRQF_SHARED, "maple bus VBLANK", &maple_dummy_driver); | ||
| 575 | } | 589 | } |
| 576 | 590 | ||
| 577 | static int maple_get_dma_buffer(void) | 591 | static int maple_get_dma_buffer(void) |
| 578 | { | 592 | { |
| 579 | maple_sendbuf = | 593 | maple_sendbuf = |
| 580 | (void *) __get_free_pages(GFP_KERNEL | __GFP_ZERO, | 594 | (void *) __get_free_pages(GFP_KERNEL | __GFP_ZERO, |
| 581 | MAPLE_DMA_PAGES); | 595 | MAPLE_DMA_PAGES); |
| 582 | if (!maple_sendbuf) | 596 | if (!maple_sendbuf) |
| 583 | return -ENOMEM; | 597 | return -ENOMEM; |
| 584 | return 0; | 598 | return 0; |
| 585 | } | 599 | } |
| 586 | 600 | ||
| 587 | static int match_maple_bus_driver(struct device *devptr, | 601 | static int match_maple_bus_driver(struct device *devptr, |
| 588 | struct device_driver *drvptr) | 602 | struct device_driver *drvptr) |
| 589 | { | 603 | { |
| 590 | struct maple_driver *maple_drv; | 604 | struct maple_driver *maple_drv; |
| 591 | struct maple_device *maple_dev; | 605 | struct maple_device *maple_dev; |
| 592 | 606 | ||
| 593 | maple_drv = container_of(drvptr, struct maple_driver, drv); | 607 | maple_drv = container_of(drvptr, struct maple_driver, drv); |
| 594 | maple_dev = container_of(devptr, struct maple_device, dev); | 608 | maple_dev = container_of(devptr, struct maple_device, dev); |
| 595 | /* Trap empty port case */ | 609 | /* Trap empty port case */ |
| 596 | if (maple_dev->devinfo.function == 0xFFFFFFFF) | 610 | if (maple_dev->devinfo.function == 0xFFFFFFFF) |
| 597 | return 0; | 611 | return 0; |
| 598 | else if (maple_dev->devinfo.function & | 612 | else if (maple_dev->devinfo.function & |
| 599 | be32_to_cpu(maple_drv->function)) | 613 | be32_to_cpu(maple_drv->function)) |
| 600 | return 1; | 614 | return 1; |
| 601 | return 0; | 615 | return 0; |
| 602 | } | 616 | } |
| 603 | 617 | ||
| 604 | static int maple_bus_uevent(struct device *dev, struct kobj_uevent_env *env) | 618 | static int maple_bus_uevent(struct device *dev, |
| 619 | struct kobj_uevent_env *env) | ||
| 605 | { | 620 | { |
| 606 | return 0; | 621 | return 0; |
| 607 | } | 622 | } |
| 608 | 623 | ||
| 609 | static void maple_bus_release(struct device *dev) | 624 | static void maple_bus_release(struct device *dev) |
| @@ -611,124 +626,122 @@ static void maple_bus_release(struct device *dev) | |||
| 611 | } | 626 | } |
| 612 | 627 | ||
| 613 | static struct maple_driver maple_dummy_driver = { | 628 | static struct maple_driver maple_dummy_driver = { |
| 614 | .drv = { | 629 | .drv = { |
| 615 | .name = "maple_dummy_driver", | 630 | .name = "maple_dummy_driver", |
| 616 | .bus = &maple_bus_type, | 631 | .bus = &maple_bus_type, |
| 617 | }, | 632 | }, |
| 618 | }; | 633 | }; |
| 619 | 634 | ||
| 620 | struct bus_type maple_bus_type = { | 635 | struct bus_type maple_bus_type = { |
| 621 | .name = "maple", | 636 | .name = "maple", |
| 622 | .match = match_maple_bus_driver, | 637 | .match = match_maple_bus_driver, |
| 623 | .uevent = maple_bus_uevent, | 638 | .uevent = maple_bus_uevent, |
| 624 | }; | 639 | }; |
| 625 | EXPORT_SYMBOL_GPL(maple_bus_type); | 640 | EXPORT_SYMBOL_GPL(maple_bus_type); |
| 626 | 641 | ||
| 627 | static struct device maple_bus = { | 642 | static struct device maple_bus = { |
| 628 | .bus_id = "maple", | 643 | .bus_id = "maple", |
| 629 | .release = maple_bus_release, | 644 | .release = maple_bus_release, |
| 630 | }; | 645 | }; |
| 631 | 646 | ||
| 632 | static int __init maple_bus_init(void) | 647 | static int __init maple_bus_init(void) |
| 633 | { | 648 | { |
| 634 | int retval, i; | 649 | int retval, i; |
| 635 | struct maple_device *mdev[MAPLE_PORTS]; | 650 | struct maple_device *mdev[MAPLE_PORTS]; |
| 636 | ctrl_outl(0, MAPLE_STATE); | 651 | ctrl_outl(0, MAPLE_STATE); |
| 637 | 652 | ||
| 638 | retval = device_register(&maple_bus); | 653 | retval = device_register(&maple_bus); |
| 639 | if (retval) | 654 | if (retval) |
| 640 | goto cleanup; | 655 | goto cleanup; |
| 641 | 656 | ||
| 642 | retval = bus_register(&maple_bus_type); | 657 | retval = bus_register(&maple_bus_type); |
| 643 | if (retval) | 658 | if (retval) |
| 644 | goto cleanup_device; | 659 | goto cleanup_device; |
| 645 | 660 | ||
| 646 | retval = driver_register(&maple_dummy_driver.drv); | 661 | retval = driver_register(&maple_dummy_driver.drv); |
| 647 | 662 | if (retval) | |
| 648 | if (retval) | 663 | goto cleanup_bus; |
| 649 | goto cleanup_bus; | 664 | |
| 650 | 665 | /* allocate memory for maple bus dma */ | |
| 651 | /* allocate memory for maple bus dma */ | 666 | retval = maple_get_dma_buffer(); |
| 652 | retval = maple_get_dma_buffer(); | 667 | if (retval) { |
| 653 | if (retval) { | 668 | printk(KERN_INFO |
| 654 | printk(KERN_INFO | 669 | "Maple bus: Failed to allocate Maple DMA buffers\n"); |
| 655 | "Maple bus: Failed to allocate Maple DMA buffers\n"); | 670 | goto cleanup_basic; |
| 656 | goto cleanup_basic; | 671 | } |
| 657 | } | 672 | |
| 658 | 673 | /* set up DMA interrupt handler */ | |
| 659 | /* set up DMA interrupt handler */ | 674 | retval = maple_set_dma_interrupt_handler(); |
| 660 | retval = maple_set_dma_interrupt_handler(); | 675 | if (retval) { |
| 661 | if (retval) { | 676 | printk(KERN_INFO |
| 662 | printk(KERN_INFO | 677 | "Maple bus: Failed to grab maple DMA IRQ\n"); |
| 663 | "Maple bus: Failed to grab maple DMA IRQ\n"); | 678 | goto cleanup_dma; |
| 664 | goto cleanup_dma; | 679 | } |
| 665 | } | 680 | |
| 666 | 681 | /* set up VBLANK interrupt handler */ | |
| 667 | /* set up VBLANK interrupt handler */ | 682 | retval = maple_set_vblank_interrupt_handler(); |
| 668 | retval = maple_set_vblank_interrupt_handler(); | 683 | if (retval) { |
| 669 | if (retval) { | 684 | printk(KERN_INFO "Maple bus: Failed to grab VBLANK IRQ\n"); |
| 670 | printk(KERN_INFO "Maple bus: Failed to grab VBLANK IRQ\n"); | 685 | goto cleanup_irq; |
| 671 | goto cleanup_irq; | 686 | } |
| 672 | } | 687 | |
| 673 | 688 | maple_queue_cache = | |
| 674 | maple_queue_cache = | 689 | kmem_cache_create("maple_queue_cache", 0x400, 0, |
| 675 | kmem_cache_create("maple_queue_cache", 0x400, 0, | 690 | SLAB_POISON|SLAB_HWCACHE_ALIGN, NULL); |
| 676 | SLAB_HWCACHE_ALIGN, NULL); | 691 | |
| 677 | 692 | if (!maple_queue_cache) | |
| 678 | if (!maple_queue_cache) | 693 | goto cleanup_bothirqs; |
| 679 | goto cleanup_bothirqs; | 694 | |
| 680 | 695 | /* setup maple ports */ | |
| 681 | /* setup maple ports */ | 696 | for (i = 0; i < MAPLE_PORTS; i++) { |
| 682 | for (i = 0; i < MAPLE_PORTS; i++) { | 697 | mdev[i] = maple_alloc_dev(i, 0); |
| 683 | mdev[i] = maple_alloc_dev(i, 0); | 698 | if (!mdev[i]) { |
| 684 | if (!mdev[i]) { | 699 | while (i-- > 0) |
| 685 | while (i-- > 0) | 700 | maple_free_dev(mdev[i]); |
| 686 | maple_free_dev(mdev[i]); | 701 | goto cleanup_cache; |
| 687 | goto cleanup_cache; | 702 | } |
| 688 | } | 703 | mdev[i]->mq->command = MAPLE_COMMAND_DEVINFO; |
| 689 | mdev[i]->registered = 0; | 704 | mdev[i]->mq->length = 0; |
| 690 | mdev[i]->mq->command = MAPLE_COMMAND_DEVINFO; | 705 | maple_add_packet(mdev[i]->mq); |
| 691 | mdev[i]->mq->length = 0; | 706 | /* delay aids hardware detection */ |
| 692 | maple_attach_driver(mdev[i]); | 707 | mdelay(5); |
| 693 | maple_add_packet(mdev[i]->mq); | 708 | subdevice_map[i] = 0; |
| 694 | subdevice_map[i] = 0; | 709 | } |
| 695 | } | 710 | |
| 696 | 711 | realscan = 1; | |
| 697 | /* setup maplebus hardware */ | 712 | /* setup maplebus hardware */ |
| 698 | maplebus_dma_reset(); | 713 | maplebus_dma_reset(); |
| 699 | 714 | /* initial detection */ | |
| 700 | /* initial detection */ | 715 | maple_send(); |
| 701 | maple_send(); | 716 | maple_pnp_time = jiffies; |
| 702 | 717 | printk(KERN_INFO "Maple bus core now registered.\n"); | |
| 703 | maple_pnp_time = jiffies; | 718 | |
| 704 | 719 | return 0; | |
| 705 | printk(KERN_INFO "Maple bus core now registered.\n"); | ||
| 706 | |||
| 707 | return 0; | ||
| 708 | 720 | ||
| 709 | cleanup_cache: | 721 | cleanup_cache: |
| 710 | kmem_cache_destroy(maple_queue_cache); | 722 | kmem_cache_destroy(maple_queue_cache); |
| 711 | 723 | ||
| 712 | cleanup_bothirqs: | 724 | cleanup_bothirqs: |
| 713 | free_irq(HW_EVENT_VSYNC, 0); | 725 | free_irq(HW_EVENT_VSYNC, 0); |
| 714 | 726 | ||
| 715 | cleanup_irq: | 727 | cleanup_irq: |
| 716 | free_irq(HW_EVENT_MAPLE_DMA, 0); | 728 | free_irq(HW_EVENT_MAPLE_DMA, 0); |
| 717 | 729 | ||
| 718 | cleanup_dma: | 730 | cleanup_dma: |
| 719 | free_pages((unsigned long) maple_sendbuf, MAPLE_DMA_PAGES); | 731 | free_pages((unsigned long) maple_sendbuf, MAPLE_DMA_PAGES); |
| 720 | 732 | ||
| 721 | cleanup_basic: | 733 | cleanup_basic: |
| 722 | driver_unregister(&maple_dummy_driver.drv); | 734 | driver_unregister(&maple_dummy_driver.drv); |
| 723 | 735 | ||
| 724 | cleanup_bus: | 736 | cleanup_bus: |
| 725 | bus_unregister(&maple_bus_type); | 737 | bus_unregister(&maple_bus_type); |
| 726 | 738 | ||
| 727 | cleanup_device: | 739 | cleanup_device: |
| 728 | device_unregister(&maple_bus); | 740 | device_unregister(&maple_bus); |
| 729 | 741 | ||
| 730 | cleanup: | 742 | cleanup: |
| 731 | printk(KERN_INFO "Maple bus registration failed\n"); | 743 | printk(KERN_INFO "Maple bus registration failed\n"); |
| 732 | return retval; | 744 | return retval; |
| 733 | } | 745 | } |
| 734 | subsys_initcall(maple_bus_init); | 746 | /* Push init to later to ensure hardware gets detected */ |
| 747 | fs_initcall(maple_bus_init); | ||
diff --git a/include/asm-sh/bugs.h b/include/asm-sh/bugs.h index def8128b8b78..cfda7d5bf026 100644 --- a/include/asm-sh/bugs.h +++ b/include/asm-sh/bugs.h | |||
| @@ -39,7 +39,7 @@ static void __init check_bugs(void) | |||
| 39 | *p++ = '4'; | 39 | *p++ = '4'; |
| 40 | *p++ = 'a'; | 40 | *p++ = 'a'; |
| 41 | break; | 41 | break; |
| 42 | case CPU_SH7343 ... CPU_SH7722: | 42 | case CPU_SH7343 ... CPU_SH7366: |
| 43 | *p++ = '4'; | 43 | *p++ = '4'; |
| 44 | *p++ = 'a'; | 44 | *p++ = 'a'; |
| 45 | *p++ = 'l'; | 45 | *p++ = 'l'; |
diff --git a/include/asm-sh/cpu-sh4/freq.h b/include/asm-sh/cpu-sh4/freq.h index 1ac10b9a078f..ec028c649215 100644 --- a/include/asm-sh/cpu-sh4/freq.h +++ b/include/asm-sh/cpu-sh4/freq.h | |||
| @@ -10,12 +10,14 @@ | |||
| 10 | #ifndef __ASM_CPU_SH4_FREQ_H | 10 | #ifndef __ASM_CPU_SH4_FREQ_H |
| 11 | #define __ASM_CPU_SH4_FREQ_H | 11 | #define __ASM_CPU_SH4_FREQ_H |
| 12 | 12 | ||
| 13 | #if defined(CONFIG_CPU_SUBTYPE_SH7722) | 13 | #if defined(CONFIG_CPU_SUBTYPE_SH7722) || defined(CONFIG_CPU_SUBTYPE_SH7366) |
| 14 | #define FRQCR 0xa4150000 | 14 | #define FRQCR 0xa4150000 |
| 15 | #define VCLKCR 0xa4150004 | 15 | #define VCLKCR 0xa4150004 |
| 16 | #define SCLKACR 0xa4150008 | 16 | #define SCLKACR 0xa4150008 |
| 17 | #define SCLKBCR 0xa415000c | 17 | #define SCLKBCR 0xa415000c |
| 18 | #if defined(CONFIG_CPU_SUBTYPE_SH7722) | ||
| 18 | #define IrDACLKCR 0xa4150010 | 19 | #define IrDACLKCR 0xa4150010 |
| 20 | #endif | ||
| 19 | #elif defined(CONFIG_CPU_SUBTYPE_SH7763) || \ | 21 | #elif defined(CONFIG_CPU_SUBTYPE_SH7763) || \ |
| 20 | defined(CONFIG_CPU_SUBTYPE_SH7780) | 22 | defined(CONFIG_CPU_SUBTYPE_SH7780) |
| 21 | #define FRQCR 0xffc80000 | 23 | #define FRQCR 0xffc80000 |
diff --git a/include/asm-sh/cpu-sh5/cacheflush.h b/include/asm-sh/cpu-sh5/cacheflush.h index 98edb5b1da32..5a11f0b7e66a 100644 --- a/include/asm-sh/cpu-sh5/cacheflush.h +++ b/include/asm-sh/cpu-sh5/cacheflush.h | |||
| @@ -3,15 +3,13 @@ | |||
| 3 | 3 | ||
| 4 | #ifndef __ASSEMBLY__ | 4 | #ifndef __ASSEMBLY__ |
| 5 | 5 | ||
| 6 | #include <asm/page.h> | ||
| 7 | |||
| 8 | struct vm_area_struct; | 6 | struct vm_area_struct; |
| 9 | struct page; | 7 | struct page; |
| 10 | struct mm_struct; | 8 | struct mm_struct; |
| 11 | 9 | ||
| 12 | extern void flush_cache_all(void); | 10 | extern void flush_cache_all(void); |
| 13 | extern void flush_cache_mm(struct mm_struct *mm); | 11 | extern void flush_cache_mm(struct mm_struct *mm); |
| 14 | extern void flush_cache_sigtramp(unsigned long start, unsigned long end); | 12 | extern void flush_cache_sigtramp(unsigned long vaddr); |
| 15 | extern void flush_cache_range(struct vm_area_struct *vma, unsigned long start, | 13 | extern void flush_cache_range(struct vm_area_struct *vma, unsigned long start, |
| 16 | unsigned long end); | 14 | unsigned long end); |
| 17 | extern void flush_cache_page(struct vm_area_struct *vma, unsigned long addr, unsigned long pfn); | 15 | extern void flush_cache_page(struct vm_area_struct *vma, unsigned long addr, unsigned long pfn); |
| @@ -27,7 +25,7 @@ extern void flush_icache_user_range(struct vm_area_struct *vma, | |||
| 27 | #define flush_dcache_mmap_unlock(mapping) do { } while (0) | 25 | #define flush_dcache_mmap_unlock(mapping) do { } while (0) |
| 28 | 26 | ||
| 29 | #define flush_icache_page(vma, page) do { } while (0) | 27 | #define flush_icache_page(vma, page) do { } while (0) |
| 30 | #define p3_cache_init() do { } while (0) | 28 | void p3_cache_init(void); |
| 31 | 29 | ||
| 32 | #endif /* __ASSEMBLY__ */ | 30 | #endif /* __ASSEMBLY__ */ |
| 33 | 31 | ||
diff --git a/include/asm-sh/cpu-sh5/mmu_context.h b/include/asm-sh/cpu-sh5/mmu_context.h index df857fc09960..68a1d2cff457 100644 --- a/include/asm-sh/cpu-sh5/mmu_context.h +++ b/include/asm-sh/cpu-sh5/mmu_context.h | |||
| @@ -16,12 +16,6 @@ | |||
| 16 | /* This has to be a common function because the next location to fill | 16 | /* This has to be a common function because the next location to fill |
| 17 | * information is shared. */ | 17 | * information is shared. */ |
| 18 | extern void __do_tlb_refill(unsigned long address, unsigned long long is_text_not_data, pte_t *pte); | 18 | extern void __do_tlb_refill(unsigned long address, unsigned long long is_text_not_data, pte_t *pte); |
| 19 | |||
| 20 | /* Profiling counter. */ | ||
| 21 | #ifdef CONFIG_SH64_PROC_TLB | ||
| 22 | extern unsigned long long calls_to_do_fast_page_fault; | ||
| 23 | #endif | ||
| 24 | |||
| 25 | #endif /* __ASSEMBLY__ */ | 19 | #endif /* __ASSEMBLY__ */ |
| 26 | 20 | ||
| 27 | #endif /* __ASM_SH_CPU_SH5_MMU_CONTEXT_H */ | 21 | #endif /* __ASM_SH_CPU_SH5_MMU_CONTEXT_H */ |
diff --git a/include/asm-sh/hp6xx.h b/include/asm-sh/hp6xx.h index 53ca5643d9c7..0d4165a32dcd 100644 --- a/include/asm-sh/hp6xx.h +++ b/include/asm-sh/hp6xx.h | |||
| @@ -10,9 +10,9 @@ | |||
| 10 | * | 10 | * |
| 11 | */ | 11 | */ |
| 12 | 12 | ||
| 13 | #define HP680_BTN_IRQ 32 /* IRQ0_IRQ */ | 13 | #define HP680_BTN_IRQ 32 /* IRQ0_IRQ */ |
| 14 | #define HP680_TS_IRQ 35 /* IRQ3_IRQ */ | 14 | #define HP680_TS_IRQ 35 /* IRQ3_IRQ */ |
| 15 | #define HP680_HD64461_IRQ 36 /* IRQ4_IRQ */ | 15 | #define HP680_HD64461_IRQ 36 /* IRQ4_IRQ */ |
| 16 | 16 | ||
| 17 | #define DAC_LCD_BRIGHTNESS 0 | 17 | #define DAC_LCD_BRIGHTNESS 0 |
| 18 | #define DAC_SPEAKER_VOLUME 1 | 18 | #define DAC_SPEAKER_VOLUME 1 |
| @@ -55,26 +55,4 @@ | |||
| 55 | #define PJDR 0xa4000130 | 55 | #define PJDR 0xa4000130 |
| 56 | #define PKDR 0xa4000132 | 56 | #define PKDR 0xa4000132 |
| 57 | 57 | ||
| 58 | static inline void hp6xx_led_red(int on) | ||
| 59 | { | ||
| 60 | u16 v16; | ||
| 61 | v16 = ctrl_inw(CONFIG_HD64461_IOBASE + HD64461_GPBDR - 0x10000); | ||
| 62 | if (on) | ||
| 63 | ctrl_outw(v16 & (~HD64461_GPBDR_LED_RED), CONFIG_HD64461_IOBASE + HD64461_GPBDR - 0x10000); | ||
| 64 | else | ||
| 65 | ctrl_outw(v16 | HD64461_GPBDR_LED_RED, CONFIG_HD64461_IOBASE + HD64461_GPBDR - 0x10000); | ||
| 66 | } | ||
| 67 | |||
| 68 | static inline void hp6xx_led_green(int on) | ||
| 69 | { | ||
| 70 | u8 v8; | ||
| 71 | |||
| 72 | v8 = ctrl_inb(PKDR); | ||
| 73 | if (on) | ||
| 74 | ctrl_outb(v8 & (~PKDR_LED_GREEN), PKDR); | ||
| 75 | else | ||
| 76 | ctrl_outb(v8 | PKDR_LED_GREEN, PKDR); | ||
| 77 | } | ||
| 78 | |||
| 79 | |||
| 80 | #endif /* __ASM_SH_HP6XX_H */ | 58 | #endif /* __ASM_SH_HP6XX_H */ |
diff --git a/include/asm-sh/io.h b/include/asm-sh/io.h index 94900c089519..356e50d06745 100644 --- a/include/asm-sh/io.h +++ b/include/asm-sh/io.h | |||
| @@ -38,6 +38,7 @@ | |||
| 38 | */ | 38 | */ |
| 39 | #define __IO_PREFIX generic | 39 | #define __IO_PREFIX generic |
| 40 | #include <asm/io_generic.h> | 40 | #include <asm/io_generic.h> |
| 41 | #include <asm/io_trapped.h> | ||
| 41 | 42 | ||
| 42 | #define maybebadio(port) \ | 43 | #define maybebadio(port) \ |
| 43 | printk(KERN_ERR "bad PC-like io %s:%u for port 0x%lx at 0x%08x\n", \ | 44 | printk(KERN_ERR "bad PC-like io %s:%u for port 0x%lx at 0x%08x\n", \ |
| @@ -181,13 +182,13 @@ __BUILD_MEMORY_STRING(w, u16) | |||
| 181 | #define iowrite32(v,a) writel((v),(a)) | 182 | #define iowrite32(v,a) writel((v),(a)) |
| 182 | #define iowrite32be(v,a) __raw_writel(cpu_to_be32((v)),(a)) | 183 | #define iowrite32be(v,a) __raw_writel(cpu_to_be32((v)),(a)) |
| 183 | 184 | ||
| 184 | #define ioread8_rep(a,d,c) insb((a),(d),(c)) | 185 | #define ioread8_rep(a, d, c) readsb((a), (d), (c)) |
| 185 | #define ioread16_rep(a,d,c) insw((a),(d),(c)) | 186 | #define ioread16_rep(a, d, c) readsw((a), (d), (c)) |
| 186 | #define ioread32_rep(a,d,c) insl((a),(d),(c)) | 187 | #define ioread32_rep(a, d, c) readsl((a), (d), (c)) |
| 187 | 188 | ||
| 188 | #define iowrite8_rep(a,s,c) outsb((a),(s),(c)) | 189 | #define iowrite8_rep(a, s, c) writesb((a), (s), (c)) |
| 189 | #define iowrite16_rep(a,s,c) outsw((a),(s),(c)) | 190 | #define iowrite16_rep(a, s, c) writesw((a), (s), (c)) |
| 190 | #define iowrite32_rep(a,s,c) outsl((a),(s),(c)) | 191 | #define iowrite32_rep(a, s, c) writesl((a), (s), (c)) |
| 191 | 192 | ||
| 192 | #define mmiowb() wmb() /* synco on SH-4A, otherwise a nop */ | 193 | #define mmiowb() wmb() /* synco on SH-4A, otherwise a nop */ |
| 193 | 194 | ||
| @@ -207,6 +208,8 @@ static inline void __set_io_port_base(unsigned long pbase) | |||
| 207 | generic_io_base = pbase; | 208 | generic_io_base = pbase; |
| 208 | } | 209 | } |
| 209 | 210 | ||
| 211 | #define __ioport_map(p, n) sh_mv.mv_ioport_map((p), (n)) | ||
| 212 | |||
| 210 | /* We really want to try and get these to memcpy etc */ | 213 | /* We really want to try and get these to memcpy etc */ |
| 211 | extern void memcpy_fromio(void *, volatile void __iomem *, unsigned long); | 214 | extern void memcpy_fromio(void *, volatile void __iomem *, unsigned long); |
| 212 | extern void memcpy_toio(volatile void __iomem *, const void *, unsigned long); | 215 | extern void memcpy_toio(volatile void __iomem *, const void *, unsigned long); |
| @@ -309,7 +312,14 @@ __ioremap_mode(unsigned long offset, unsigned long size, unsigned long flags) | |||
| 309 | { | 312 | { |
| 310 | #ifdef CONFIG_SUPERH32 | 313 | #ifdef CONFIG_SUPERH32 |
| 311 | unsigned long last_addr = offset + size - 1; | 314 | unsigned long last_addr = offset + size - 1; |
| 315 | #endif | ||
| 316 | void __iomem *ret; | ||
| 312 | 317 | ||
| 318 | ret = __ioremap_trapped(offset, size); | ||
| 319 | if (ret) | ||
| 320 | return ret; | ||
| 321 | |||
| 322 | #ifdef CONFIG_SUPERH32 | ||
| 313 | /* | 323 | /* |
| 314 | * For P1 and P2 space this is trivial, as everything is already | 324 | * For P1 and P2 space this is trivial, as everything is already |
| 315 | * mapped. Uncached access for P1 addresses are done through P2. | 325 | * mapped. Uncached access for P1 addresses are done through P2. |
diff --git a/include/asm-sh/io_trapped.h b/include/asm-sh/io_trapped.h new file mode 100644 index 000000000000..f1251d4f0ba9 --- /dev/null +++ b/include/asm-sh/io_trapped.h | |||
| @@ -0,0 +1,58 @@ | |||
| 1 | #ifndef __ASM_SH_IO_TRAPPED_H | ||
| 2 | #define __ASM_SH_IO_TRAPPED_H | ||
| 3 | |||
| 4 | #include <linux/list.h> | ||
| 5 | #include <linux/ioport.h> | ||
| 6 | #include <asm/page.h> | ||
| 7 | |||
| 8 | #define IO_TRAPPED_MAGIC 0xfeedbeef | ||
| 9 | |||
| 10 | struct trapped_io { | ||
| 11 | unsigned int magic; | ||
| 12 | struct resource *resource; | ||
| 13 | unsigned int num_resources; | ||
| 14 | unsigned int minimum_bus_width; | ||
| 15 | struct list_head list; | ||
| 16 | void __iomem *virt_base; | ||
| 17 | } __aligned(PAGE_SIZE); | ||
| 18 | |||
| 19 | #ifdef CONFIG_IO_TRAPPED | ||
| 20 | int register_trapped_io(struct trapped_io *tiop); | ||
| 21 | int handle_trapped_io(struct pt_regs *regs, unsigned long address); | ||
| 22 | |||
| 23 | void __iomem *match_trapped_io_handler(struct list_head *list, | ||
| 24 | unsigned long offset, | ||
| 25 | unsigned long size); | ||
| 26 | |||
| 27 | #ifdef CONFIG_HAS_IOMEM | ||
| 28 | extern struct list_head trapped_mem; | ||
| 29 | |||
| 30 | static inline void __iomem * | ||
| 31 | __ioremap_trapped(unsigned long offset, unsigned long size) | ||
| 32 | { | ||
| 33 | return match_trapped_io_handler(&trapped_mem, offset, size); | ||
| 34 | } | ||
| 35 | #else | ||
| 36 | #define __ioremap_trapped(offset, size) NULL | ||
| 37 | #endif | ||
| 38 | |||
| 39 | #ifdef CONFIG_HAS_IOPORT | ||
| 40 | extern struct list_head trapped_io; | ||
| 41 | |||
| 42 | static inline void __iomem * | ||
| 43 | __ioport_map_trapped(unsigned long offset, unsigned long size) | ||
| 44 | { | ||
| 45 | return match_trapped_io_handler(&trapped_io, offset, size); | ||
| 46 | } | ||
| 47 | #else | ||
| 48 | #define __ioport_map_trapped(offset, size) NULL | ||
| 49 | #endif | ||
| 50 | |||
| 51 | #else | ||
| 52 | #define register_trapped_io(tiop) (-1) | ||
| 53 | #define handle_trapped_io(tiop, address) 0 | ||
| 54 | #define __ioremap_trapped(offset, size) NULL | ||
| 55 | #define __ioport_map_trapped(offset, size) NULL | ||
| 56 | #endif | ||
| 57 | |||
| 58 | #endif /* __ASM_SH_IO_TRAPPED_H */ | ||
diff --git a/include/asm-sh/ioctls.h b/include/asm-sh/ioctls.h index 35805df010a0..c212c371a4a5 100644 --- a/include/asm-sh/ioctls.h +++ b/include/asm-sh/ioctls.h | |||
| @@ -78,6 +78,10 @@ | |||
| 78 | #define TIOCSBRK _IO('T', 39) /* 0x5427 */ /* BSD compatibility */ | 78 | #define TIOCSBRK _IO('T', 39) /* 0x5427 */ /* BSD compatibility */ |
| 79 | #define TIOCCBRK _IO('T', 40) /* 0x5428 */ /* BSD compatibility */ | 79 | #define TIOCCBRK _IO('T', 40) /* 0x5428 */ /* BSD compatibility */ |
| 80 | #define TIOCGSID _IOR('T', 41, pid_t) /* 0x5429 */ /* Return the session ID of FD */ | 80 | #define TIOCGSID _IOR('T', 41, pid_t) /* 0x5429 */ /* Return the session ID of FD */ |
| 81 | #define TCGETS2 _IOR('T', 42, struct termios2) | ||
| 82 | #define TCSETS2 _IOW('T', 43, struct termios2) | ||
| 83 | #define TCSETSW2 _IOW('T', 44, struct termios2) | ||
| 84 | #define TCSETSF2 _IOW('T', 45, struct termios2) | ||
| 81 | #define TIOCGPTN _IOR('T',0x30, unsigned int) /* Get Pty Number (of pty-mux device) */ | 85 | #define TIOCGPTN _IOR('T',0x30, unsigned int) /* Get Pty Number (of pty-mux device) */ |
| 82 | #define TIOCSPTLCK _IOW('T',0x31, int) /* Lock/unlock Pty */ | 86 | #define TIOCSPTLCK _IOW('T',0x31, int) /* Lock/unlock Pty */ |
| 83 | 87 | ||
diff --git a/include/asm-sh/irq.h b/include/asm-sh/irq.h index 11850f65c922..ca66e5df69dc 100644 --- a/include/asm-sh/irq.h +++ b/include/asm-sh/irq.h | |||
| @@ -50,4 +50,8 @@ extern void irq_ctx_exit(int cpu); | |||
| 50 | # define irq_ctx_exit(cpu) do { } while (0) | 50 | # define irq_ctx_exit(cpu) do { } while (0) |
| 51 | #endif | 51 | #endif |
| 52 | 52 | ||
| 53 | #ifdef CONFIG_CPU_SH5 | ||
| 54 | #include <asm/cpu/irq.h> | ||
| 55 | #endif | ||
| 56 | |||
| 53 | #endif /* __ASM_SH_IRQ_H */ | 57 | #endif /* __ASM_SH_IRQ_H */ |
diff --git a/include/asm-sh/mmu_context_64.h b/include/asm-sh/mmu_context_64.h index 020be744b088..9649f1c07caf 100644 --- a/include/asm-sh/mmu_context_64.h +++ b/include/asm-sh/mmu_context_64.h | |||
| @@ -66,6 +66,9 @@ static inline void set_asid(unsigned long asid) | |||
| 66 | : "=r" (sr), "=r" (pc) : "0" (sr)); | 66 | : "=r" (sr), "=r" (pc) : "0" (sr)); |
| 67 | } | 67 | } |
| 68 | 68 | ||
| 69 | /* arch/sh/kernel/cpu/sh5/entry.S */ | ||
| 70 | extern unsigned long switch_and_save_asid(unsigned long new_asid); | ||
| 71 | |||
| 69 | /* No spare register to twiddle, so use a software cache */ | 72 | /* No spare register to twiddle, so use a software cache */ |
| 70 | extern pgd_t *mmu_pdtp_cache; | 73 | extern pgd_t *mmu_pdtp_cache; |
| 71 | 74 | ||
diff --git a/include/asm-sh/page.h b/include/asm-sh/page.h index 134562dc8c45..304c30b5d947 100644 --- a/include/asm-sh/page.h +++ b/include/asm-sh/page.h | |||
| @@ -55,11 +55,14 @@ extern void clear_page(void *to); | |||
| 55 | extern void copy_page(void *to, void *from); | 55 | extern void copy_page(void *to, void *from); |
| 56 | 56 | ||
| 57 | #if !defined(CONFIG_CACHE_OFF) && defined(CONFIG_MMU) && \ | 57 | #if !defined(CONFIG_CACHE_OFF) && defined(CONFIG_MMU) && \ |
| 58 | (defined(CONFIG_CPU_SH4) || defined(CONFIG_SH7705_CACHE_32KB)) | 58 | (defined(CONFIG_CPU_SH5) || defined(CONFIG_CPU_SH4) || \ |
| 59 | defined(CONFIG_SH7705_CACHE_32KB)) | ||
| 59 | struct page; | 60 | struct page; |
| 60 | struct vm_area_struct; | 61 | struct vm_area_struct; |
| 61 | extern void clear_user_page(void *to, unsigned long address, struct page *page); | 62 | extern void clear_user_page(void *to, unsigned long address, struct page *page); |
| 62 | #ifdef CONFIG_CPU_SH4 | 63 | extern void copy_user_page(void *to, void *from, unsigned long address, |
| 64 | struct page *page); | ||
| 65 | #if defined(CONFIG_CPU_SH4) | ||
| 63 | extern void copy_user_highpage(struct page *to, struct page *from, | 66 | extern void copy_user_highpage(struct page *to, struct page *from, |
| 64 | unsigned long vaddr, struct vm_area_struct *vma); | 67 | unsigned long vaddr, struct vm_area_struct *vma); |
| 65 | #define __HAVE_ARCH_COPY_USER_HIGHPAGE | 68 | #define __HAVE_ARCH_COPY_USER_HIGHPAGE |
diff --git a/include/asm-sh/pgtable_64.h b/include/asm-sh/pgtable_64.h index 972211671c9a..f9dd9d311441 100644 --- a/include/asm-sh/pgtable_64.h +++ b/include/asm-sh/pgtable_64.h | |||
| @@ -138,6 +138,14 @@ static __inline__ void pmd_set(pmd_t *pmdp,pte_t *ptep) | |||
| 138 | #endif | 138 | #endif |
| 139 | 139 | ||
| 140 | /* | 140 | /* |
| 141 | * Stub out _PAGE_SZHUGE if we don't have a good definition for it, | ||
| 142 | * to make pte_mkhuge() happy. | ||
| 143 | */ | ||
| 144 | #ifndef _PAGE_SZHUGE | ||
| 145 | # define _PAGE_SZHUGE (0) | ||
| 146 | #endif | ||
| 147 | |||
| 148 | /* | ||
| 141 | * Default flags for a Kernel page. | 149 | * Default flags for a Kernel page. |
| 142 | * This is fundametally also SHARED because the main use of this define | 150 | * This is fundametally also SHARED because the main use of this define |
| 143 | * (other than for PGD/PMD entries) is for the VMALLOC pool which is | 151 | * (other than for PGD/PMD entries) is for the VMALLOC pool which is |
| @@ -179,6 +187,11 @@ static __inline__ void pmd_set(pmd_t *pmdp,pte_t *ptep) | |||
| 179 | _PAGE_WRITE | _PAGE_EXECUTE) | 187 | _PAGE_WRITE | _PAGE_EXECUTE) |
| 180 | #define PAGE_KERNEL __pgprot(_KERNPG_TABLE) | 188 | #define PAGE_KERNEL __pgprot(_KERNPG_TABLE) |
| 181 | 189 | ||
| 190 | #define PAGE_KERNEL_NOCACHE \ | ||
| 191 | __pgprot(_PAGE_PRESENT | _PAGE_READ | _PAGE_WRITE | \ | ||
| 192 | _PAGE_EXECUTE | _PAGE_ACCESSED | \ | ||
| 193 | _PAGE_DIRTY | _PAGE_SHARED) | ||
| 194 | |||
| 182 | /* Make it a device mapping for maximum safety (e.g. for mapping device | 195 | /* Make it a device mapping for maximum safety (e.g. for mapping device |
| 183 | registers into user-space via /dev/map). */ | 196 | registers into user-space via /dev/map). */ |
| 184 | #define pgprot_noncached(x) __pgprot(((x).pgprot & ~(_PAGE_CACHABLE)) | _PAGE_DEVICE) | 197 | #define pgprot_noncached(x) __pgprot(((x).pgprot & ~(_PAGE_CACHABLE)) | _PAGE_DEVICE) |
diff --git a/include/asm-sh/processor.h b/include/asm-sh/processor.h index c9b14161f73d..19fe47c1ca17 100644 --- a/include/asm-sh/processor.h +++ b/include/asm-sh/processor.h | |||
| @@ -33,7 +33,7 @@ enum cpu_type { | |||
| 33 | CPU_SH7763, CPU_SH7770, CPU_SH7780, CPU_SH7781, CPU_SH7785, CPU_SHX3, | 33 | CPU_SH7763, CPU_SH7770, CPU_SH7780, CPU_SH7781, CPU_SH7785, CPU_SHX3, |
| 34 | 34 | ||
| 35 | /* SH4AL-DSP types */ | 35 | /* SH4AL-DSP types */ |
| 36 | CPU_SH7343, CPU_SH7722, | 36 | CPU_SH7343, CPU_SH7722, CPU_SH7366, |
| 37 | 37 | ||
| 38 | /* SH-5 types */ | 38 | /* SH-5 types */ |
| 39 | CPU_SH5_101, CPU_SH5_103, | 39 | CPU_SH5_101, CPU_SH5_103, |
diff --git a/include/asm-sh/r7780rp.h b/include/asm-sh/r7780rp.h index bdecea0840a0..1770460a4616 100644 --- a/include/asm-sh/r7780rp.h +++ b/include/asm-sh/r7780rp.h | |||
| @@ -195,7 +195,4 @@ unsigned char *highlander_init_irq_r7780mp(void); | |||
| 195 | unsigned char *highlander_init_irq_r7780rp(void); | 195 | unsigned char *highlander_init_irq_r7780rp(void); |
| 196 | unsigned char *highlander_init_irq_r7785rp(void); | 196 | unsigned char *highlander_init_irq_r7785rp(void); |
| 197 | 197 | ||
| 198 | #define __IO_PREFIX r7780rp | ||
| 199 | #include <asm/io_generic.h> | ||
| 200 | |||
| 201 | #endif /* __ASM_SH_RENESAS_R7780RP */ | 198 | #endif /* __ASM_SH_RENESAS_R7780RP */ |
diff --git a/include/asm-sh/rts7751r2d.h b/include/asm-sh/rts7751r2d.h index 83b9c111f171..0a800157b826 100644 --- a/include/asm-sh/rts7751r2d.h +++ b/include/asm-sh/rts7751r2d.h | |||
| @@ -67,7 +67,4 @@ | |||
| 67 | void init_rts7751r2d_IRQ(void); | 67 | void init_rts7751r2d_IRQ(void); |
| 68 | int rts7751r2d_irq_demux(int); | 68 | int rts7751r2d_irq_demux(int); |
| 69 | 69 | ||
| 70 | #define __IO_PREFIX rts7751r2d | ||
| 71 | #include <asm/io_generic.h> | ||
| 72 | |||
| 73 | #endif /* __ASM_SH_RENESAS_RTS7751R2D */ | 70 | #endif /* __ASM_SH_RENESAS_RTS7751R2D */ |
diff --git a/include/asm-sh/system.h b/include/asm-sh/system.h index 772cd1a0a674..5145aa2a0ce9 100644 --- a/include/asm-sh/system.h +++ b/include/asm-sh/system.h | |||
| @@ -182,6 +182,11 @@ BUILD_TRAP_HANDLER(fpu_state_restore); | |||
| 182 | 182 | ||
| 183 | #define arch_align_stack(x) (x) | 183 | #define arch_align_stack(x) (x) |
| 184 | 184 | ||
| 185 | struct mem_access { | ||
| 186 | unsigned long (*from)(void *dst, const void *src, unsigned long cnt); | ||
| 187 | unsigned long (*to)(void *dst, const void *src, unsigned long cnt); | ||
| 188 | }; | ||
| 189 | |||
| 185 | #ifdef CONFIG_SUPERH32 | 190 | #ifdef CONFIG_SUPERH32 |
| 186 | # include "system_32.h" | 191 | # include "system_32.h" |
| 187 | #else | 192 | #else |
diff --git a/include/asm-sh/system_32.h b/include/asm-sh/system_32.h index 7ff08d956ba8..f11bcf0855ed 100644 --- a/include/asm-sh/system_32.h +++ b/include/asm-sh/system_32.h | |||
| @@ -96,4 +96,7 @@ do { \ | |||
| 96 | : "=&r" (__dummy)); \ | 96 | : "=&r" (__dummy)); \ |
| 97 | } while (0) | 97 | } while (0) |
| 98 | 98 | ||
| 99 | int handle_unaligned_access(opcode_t instruction, struct pt_regs *regs, | ||
| 100 | struct mem_access *ma); | ||
| 101 | |||
| 99 | #endif /* __ASM_SH_SYSTEM_32_H */ | 102 | #endif /* __ASM_SH_SYSTEM_32_H */ |
diff --git a/include/asm-sh/termbits.h b/include/asm-sh/termbits.h index 7ee1b42eeab0..77db116948cf 100644 --- a/include/asm-sh/termbits.h +++ b/include/asm-sh/termbits.h | |||
| @@ -140,6 +140,7 @@ struct ktermios { | |||
| 140 | #define HUPCL 0002000 | 140 | #define HUPCL 0002000 |
| 141 | #define CLOCAL 0004000 | 141 | #define CLOCAL 0004000 |
| 142 | #define CBAUDEX 0010000 | 142 | #define CBAUDEX 0010000 |
| 143 | #define BOTHER 0010000 | ||
| 143 | #define B57600 0010001 | 144 | #define B57600 0010001 |
| 144 | #define B115200 0010002 | 145 | #define B115200 0010002 |
| 145 | #define B230400 0010003 | 146 | #define B230400 0010003 |
| @@ -155,10 +156,12 @@ struct ktermios { | |||
| 155 | #define B3000000 0010015 | 156 | #define B3000000 0010015 |
| 156 | #define B3500000 0010016 | 157 | #define B3500000 0010016 |
| 157 | #define B4000000 0010017 | 158 | #define B4000000 0010017 |
| 158 | #define CIBAUD 002003600000 /* input baud rate (not used) */ | 159 | #define CIBAUD 002003600000 /* input baud rate */ |
| 159 | #define CMSPAR 010000000000 /* mark or space (stick) parity */ | 160 | #define CMSPAR 010000000000 /* mark or space (stick) parity */ |
| 160 | #define CRTSCTS 020000000000 /* flow control */ | 161 | #define CRTSCTS 020000000000 /* flow control */ |
| 161 | 162 | ||
| 163 | #define IBSHIFT 16 /* Shift from CBAUD to CIBAUD */ | ||
| 164 | |||
| 162 | /* c_lflag bits */ | 165 | /* c_lflag bits */ |
| 163 | #define ISIG 0000001 | 166 | #define ISIG 0000001 |
| 164 | #define ICANON 0000002 | 167 | #define ICANON 0000002 |
diff --git a/include/asm-sh/termios.h b/include/asm-sh/termios.h index e7c8f86ef890..0a8c793c76f2 100644 --- a/include/asm-sh/termios.h +++ b/include/asm-sh/termios.h | |||
| @@ -80,8 +80,10 @@ struct termio { | |||
| 80 | copy_to_user((termio)->c_cc, (termios)->c_cc, NCC); \ | 80 | copy_to_user((termio)->c_cc, (termios)->c_cc, NCC); \ |
| 81 | }) | 81 | }) |
| 82 | 82 | ||
| 83 | #define user_termios_to_kernel_termios(k, u) copy_from_user(k, u, sizeof(struct termios)) | 83 | #define user_termios_to_kernel_termios(k, u) copy_from_user(k, u, sizeof(struct termios2)) |
| 84 | #define kernel_termios_to_user_termios(u, k) copy_to_user(u, k, sizeof(struct termios)) | 84 | #define kernel_termios_to_user_termios(u, k) copy_to_user(u, k, sizeof(struct termios2)) |
| 85 | #define user_termios_to_kernel_termios_1(k, u) copy_from_user(k, u, sizeof(struct termios)) | ||
| 86 | #define kernel_termios_to_user_termios_1(u, k) copy_to_user(u, k, sizeof(struct termios)) | ||
| 85 | 87 | ||
| 86 | #endif /* __KERNEL__ */ | 88 | #endif /* __KERNEL__ */ |
| 87 | 89 | ||
diff --git a/include/asm-sh/tlb.h b/include/asm-sh/tlb.h index 56ad1fb888a2..88ff1ae8a6b8 100644 --- a/include/asm-sh/tlb.h +++ b/include/asm-sh/tlb.h | |||
| @@ -20,6 +20,7 @@ | |||
| 20 | */ | 20 | */ |
| 21 | #define tlb_flush(tlb) flush_tlb_mm((tlb)->mm) | 21 | #define tlb_flush(tlb) flush_tlb_mm((tlb)->mm) |
| 22 | 22 | ||
| 23 | #include <linux/pagemap.h> | ||
| 23 | #include <asm-generic/tlb.h> | 24 | #include <asm-generic/tlb.h> |
| 24 | 25 | ||
| 25 | #endif /* __ASSEMBLY__ */ | 26 | #endif /* __ASSEMBLY__ */ |
diff --git a/include/asm-sh/uaccess.h b/include/asm-sh/uaccess.h index ff24ce95b238..b3440c305b5d 100644 --- a/include/asm-sh/uaccess.h +++ b/include/asm-sh/uaccess.h | |||
| @@ -1,5 +1,34 @@ | |||
| 1 | #ifndef __ASM_SH_UACCESS_H | ||
| 2 | #define __ASM_SH_UACCESS_H | ||
| 3 | |||
| 1 | #ifdef CONFIG_SUPERH32 | 4 | #ifdef CONFIG_SUPERH32 |
| 2 | # include "uaccess_32.h" | 5 | # include "uaccess_32.h" |
| 3 | #else | 6 | #else |
| 4 | # include "uaccess_64.h" | 7 | # include "uaccess_64.h" |
| 5 | #endif | 8 | #endif |
| 9 | |||
| 10 | static inline unsigned long | ||
| 11 | copy_from_user(void *to, const void __user *from, unsigned long n) | ||
| 12 | { | ||
| 13 | unsigned long __copy_from = (unsigned long) from; | ||
| 14 | __kernel_size_t __copy_size = (__kernel_size_t) n; | ||
| 15 | |||
| 16 | if (__copy_size && __access_ok(__copy_from, __copy_size)) | ||
| 17 | return __copy_user(to, from, __copy_size); | ||
| 18 | |||
| 19 | return __copy_size; | ||
| 20 | } | ||
| 21 | |||
| 22 | static inline unsigned long | ||
| 23 | copy_to_user(void __user *to, const void *from, unsigned long n) | ||
| 24 | { | ||
| 25 | unsigned long __copy_to = (unsigned long) to; | ||
| 26 | __kernel_size_t __copy_size = (__kernel_size_t) n; | ||
| 27 | |||
| 28 | if (__copy_size && __access_ok(__copy_to, __copy_size)) | ||
| 29 | return __copy_user(to, from, __copy_size); | ||
| 30 | |||
| 31 | return __copy_size; | ||
| 32 | } | ||
| 33 | |||
| 34 | #endif /* __ASM_SH_UACCESS_H */ | ||
diff --git a/include/asm-sh/uaccess_32.h b/include/asm-sh/uaccess_32.h index b6082f3c1dc4..c0318b608893 100644 --- a/include/asm-sh/uaccess_32.h +++ b/include/asm-sh/uaccess_32.h | |||
| @@ -10,8 +10,8 @@ | |||
| 10 | * Copyright (C) 1996, 1997, 1998 by Ralf Baechle | 10 | * Copyright (C) 1996, 1997, 1998 by Ralf Baechle |
| 11 | * and i386 version. | 11 | * and i386 version. |
| 12 | */ | 12 | */ |
| 13 | #ifndef __ASM_SH_UACCESS_H | 13 | #ifndef __ASM_SH_UACCESS_32_H |
| 14 | #define __ASM_SH_UACCESS_H | 14 | #define __ASM_SH_UACCESS_32_H |
| 15 | 15 | ||
| 16 | #include <linux/errno.h> | 16 | #include <linux/errno.h> |
| 17 | #include <linux/sched.h> | 17 | #include <linux/sched.h> |
| @@ -302,24 +302,6 @@ extern void __put_user_unknown(void); | |||
| 302 | /* Return the number of bytes NOT copied */ | 302 | /* Return the number of bytes NOT copied */ |
| 303 | __kernel_size_t __copy_user(void *to, const void *from, __kernel_size_t n); | 303 | __kernel_size_t __copy_user(void *to, const void *from, __kernel_size_t n); |
| 304 | 304 | ||
| 305 | #define copy_to_user(to,from,n) ({ \ | ||
| 306 | void *__copy_to = (void *) (to); \ | ||
| 307 | __kernel_size_t __copy_size = (__kernel_size_t) (n); \ | ||
| 308 | __kernel_size_t __copy_res; \ | ||
| 309 | if(__copy_size && __access_ok((unsigned long)__copy_to, __copy_size)) { \ | ||
| 310 | __copy_res = __copy_user(__copy_to, (void *) (from), __copy_size); \ | ||
| 311 | } else __copy_res = __copy_size; \ | ||
| 312 | __copy_res; }) | ||
| 313 | |||
| 314 | #define copy_from_user(to,from,n) ({ \ | ||
| 315 | void *__copy_to = (void *) (to); \ | ||
| 316 | void *__copy_from = (void *) (from); \ | ||
| 317 | __kernel_size_t __copy_size = (__kernel_size_t) (n); \ | ||
| 318 | __kernel_size_t __copy_res; \ | ||
| 319 | if(__copy_size && __access_ok((unsigned long)__copy_from, __copy_size)) { \ | ||
| 320 | __copy_res = __copy_user(__copy_to, __copy_from, __copy_size); \ | ||
| 321 | } else __copy_res = __copy_size; \ | ||
| 322 | __copy_res; }) | ||
| 323 | 305 | ||
| 324 | static __always_inline unsigned long | 306 | static __always_inline unsigned long |
| 325 | __copy_from_user(void *to, const void __user *from, unsigned long n) | 307 | __copy_from_user(void *to, const void __user *from, unsigned long n) |
| @@ -507,4 +489,4 @@ struct exception_table_entry | |||
| 507 | 489 | ||
| 508 | extern int fixup_exception(struct pt_regs *regs); | 490 | extern int fixup_exception(struct pt_regs *regs); |
| 509 | 491 | ||
| 510 | #endif /* __ASM_SH_UACCESS_H */ | 492 | #endif /* __ASM_SH_UACCESS_32_H */ |
diff --git a/include/asm-sh/uaccess_64.h b/include/asm-sh/uaccess_64.h index d54ec082d25a..f956b7b316c7 100644 --- a/include/asm-sh/uaccess_64.h +++ b/include/asm-sh/uaccess_64.h | |||
| @@ -202,15 +202,6 @@ extern void __put_user_unknown(void); | |||
| 202 | /* XXX: should be such that: 4byte and the rest. */ | 202 | /* XXX: should be such that: 4byte and the rest. */ |
| 203 | extern __kernel_size_t __copy_user(void *__to, const void *__from, __kernel_size_t __n); | 203 | extern __kernel_size_t __copy_user(void *__to, const void *__from, __kernel_size_t __n); |
| 204 | 204 | ||
| 205 | #define copy_to_user(to,from,n) ({ \ | ||
| 206 | void *__copy_to = (void *) (to); \ | ||
| 207 | __kernel_size_t __copy_size = (__kernel_size_t) (n); \ | ||
| 208 | __kernel_size_t __copy_res; \ | ||
| 209 | if(__copy_size && __access_ok((unsigned long)__copy_to, __copy_size)) { \ | ||
| 210 | __copy_res = __copy_user(__copy_to, (void *) (from), __copy_size); \ | ||
| 211 | } else __copy_res = __copy_size; \ | ||
| 212 | __copy_res; }) | ||
| 213 | |||
| 214 | #define copy_to_user_ret(to,from,n,retval) ({ \ | 205 | #define copy_to_user_ret(to,from,n,retval) ({ \ |
| 215 | if (copy_to_user(to,from,n)) \ | 206 | if (copy_to_user(to,from,n)) \ |
| 216 | return retval; \ | 207 | return retval; \ |
| @@ -225,16 +216,6 @@ if (__copy_to_user(to,from,n)) \ | |||
| 225 | return retval; \ | 216 | return retval; \ |
| 226 | }) | 217 | }) |
| 227 | 218 | ||
| 228 | #define copy_from_user(to,from,n) ({ \ | ||
| 229 | void *__copy_to = (void *) (to); \ | ||
| 230 | void *__copy_from = (void *) (from); \ | ||
| 231 | __kernel_size_t __copy_size = (__kernel_size_t) (n); \ | ||
| 232 | __kernel_size_t __copy_res; \ | ||
| 233 | if(__copy_size && __access_ok((unsigned long)__copy_from, __copy_size)) { \ | ||
| 234 | __copy_res = __copy_user(__copy_to, __copy_from, __copy_size); \ | ||
| 235 | } else __copy_res = __copy_size; \ | ||
| 236 | __copy_res; }) | ||
| 237 | |||
| 238 | #define copy_from_user_ret(to,from,n,retval) ({ \ | 219 | #define copy_from_user_ret(to,from,n,retval) ({ \ |
| 239 | if (copy_from_user(to,from,n)) \ | 220 | if (copy_from_user(to,from,n)) \ |
| 240 | return retval; \ | 221 | return retval; \ |
diff --git a/include/asm-sh/unistd_32.h b/include/asm-sh/unistd_32.h index 433fd1b48fa2..0b07212ec659 100644 --- a/include/asm-sh/unistd_32.h +++ b/include/asm-sh/unistd_32.h | |||
| @@ -330,11 +330,13 @@ | |||
| 330 | #define __NR_epoll_pwait 319 | 330 | #define __NR_epoll_pwait 319 |
| 331 | #define __NR_utimensat 320 | 331 | #define __NR_utimensat 320 |
| 332 | #define __NR_signalfd 321 | 332 | #define __NR_signalfd 321 |
| 333 | /* #define __NR_timerfd 322 removed */ | 333 | #define __NR_timerfd_create 322 |
| 334 | #define __NR_eventfd 323 | 334 | #define __NR_eventfd 323 |
| 335 | #define __NR_fallocate 324 | 335 | #define __NR_fallocate 324 |
| 336 | #define __NR_timerfd_settime 325 | ||
| 337 | #define __NR_timerfd_gettime 326 | ||
| 336 | 338 | ||
| 337 | #define NR_syscalls 325 | 339 | #define NR_syscalls 327 |
| 338 | 340 | ||
| 339 | #ifdef __KERNEL__ | 341 | #ifdef __KERNEL__ |
| 340 | 342 | ||
diff --git a/include/asm-sh/unistd_64.h b/include/asm-sh/unistd_64.h index 108d2ba897fe..9d21eab52427 100644 --- a/include/asm-sh/unistd_64.h +++ b/include/asm-sh/unistd_64.h | |||
| @@ -90,7 +90,7 @@ | |||
| 90 | #define __NR_sigpending 73 | 90 | #define __NR_sigpending 73 |
| 91 | #define __NR_sethostname 74 | 91 | #define __NR_sethostname 74 |
| 92 | #define __NR_setrlimit 75 | 92 | #define __NR_setrlimit 75 |
| 93 | #define __NR_getrlimit 76 /* Back compatible 2Gig limited rlimit */ | 93 | #define __NR_getrlimit 76 /* Back compatible 2Gig limited rlimit */ |
| 94 | #define __NR_getrusage 77 | 94 | #define __NR_getrusage 77 |
| 95 | #define __NR_gettimeofday 78 | 95 | #define __NR_gettimeofday 78 |
| 96 | #define __NR_settimeofday 79 | 96 | #define __NR_settimeofday 79 |
| @@ -370,9 +370,11 @@ | |||
| 370 | #define __NR_epoll_pwait 347 | 370 | #define __NR_epoll_pwait 347 |
| 371 | #define __NR_utimensat 348 | 371 | #define __NR_utimensat 348 |
| 372 | #define __NR_signalfd 349 | 372 | #define __NR_signalfd 349 |
| 373 | /* #define __NR_timerfd 350 removed */ | 373 | #define __NR_timerfd_create 350 |
| 374 | #define __NR_eventfd 351 | 374 | #define __NR_eventfd 351 |
| 375 | #define __NR_fallocate 352 | 375 | #define __NR_fallocate 352 |
| 376 | #define __NR_timerfd_settime 353 | ||
| 377 | #define __NR_timerfd_gettime 354 | ||
| 376 | 378 | ||
| 377 | #ifdef __KERNEL__ | 379 | #ifdef __KERNEL__ |
| 378 | 380 | ||
diff --git a/include/linux/maple.h b/include/linux/maple.h index bad9a7b319de..3f01e2bae1a1 100644 --- a/include/linux/maple.h +++ b/include/linux/maple.h | |||
| @@ -7,74 +7,74 @@ extern struct bus_type maple_bus_type; | |||
| 7 | 7 | ||
| 8 | /* Maple Bus command and response codes */ | 8 | /* Maple Bus command and response codes */ |
| 9 | enum maple_code { | 9 | enum maple_code { |
| 10 | MAPLE_RESPONSE_FILEERR = -5, | 10 | MAPLE_RESPONSE_FILEERR = -5, |
| 11 | MAPLE_RESPONSE_AGAIN = -4, /* request should be retransmitted */ | 11 | MAPLE_RESPONSE_AGAIN = -4, /* request should be retransmitted */ |
| 12 | MAPLE_RESPONSE_BADCMD = -3, | 12 | MAPLE_RESPONSE_BADCMD = -3, |
| 13 | MAPLE_RESPONSE_BADFUNC = -2, | 13 | MAPLE_RESPONSE_BADFUNC = -2, |
| 14 | MAPLE_RESPONSE_NONE = -1, /* unit didn't respond at all */ | 14 | MAPLE_RESPONSE_NONE = -1, /* unit didn't respond at all */ |
| 15 | MAPLE_COMMAND_DEVINFO = 1, | 15 | MAPLE_COMMAND_DEVINFO = 1, |
| 16 | MAPLE_COMMAND_ALLINFO = 2, | 16 | MAPLE_COMMAND_ALLINFO = 2, |
| 17 | MAPLE_COMMAND_RESET = 3, | 17 | MAPLE_COMMAND_RESET = 3, |
| 18 | MAPLE_COMMAND_KILL = 4, | 18 | MAPLE_COMMAND_KILL = 4, |
| 19 | MAPLE_RESPONSE_DEVINFO = 5, | 19 | MAPLE_RESPONSE_DEVINFO = 5, |
| 20 | MAPLE_RESPONSE_ALLINFO = 6, | 20 | MAPLE_RESPONSE_ALLINFO = 6, |
| 21 | MAPLE_RESPONSE_OK = 7, | 21 | MAPLE_RESPONSE_OK = 7, |
| 22 | MAPLE_RESPONSE_DATATRF = 8, | 22 | MAPLE_RESPONSE_DATATRF = 8, |
| 23 | MAPLE_COMMAND_GETCOND = 9, | 23 | MAPLE_COMMAND_GETCOND = 9, |
| 24 | MAPLE_COMMAND_GETMINFO = 10, | 24 | MAPLE_COMMAND_GETMINFO = 10, |
| 25 | MAPLE_COMMAND_BREAD = 11, | 25 | MAPLE_COMMAND_BREAD = 11, |
| 26 | MAPLE_COMMAND_BWRITE = 12, | 26 | MAPLE_COMMAND_BWRITE = 12, |
| 27 | MAPLE_COMMAND_SETCOND = 14 | 27 | MAPLE_COMMAND_SETCOND = 14 |
| 28 | }; | 28 | }; |
| 29 | 29 | ||
| 30 | struct mapleq { | 30 | struct mapleq { |
| 31 | struct list_head list; | 31 | struct list_head list; |
| 32 | struct maple_device *dev; | 32 | struct maple_device *dev; |
| 33 | void *sendbuf, *recvbuf, *recvbufdcsp; | 33 | void *sendbuf, *recvbuf, *recvbufdcsp; |
| 34 | unsigned char length; | 34 | unsigned char length; |
| 35 | enum maple_code command; | 35 | enum maple_code command; |
| 36 | }; | 36 | }; |
| 37 | 37 | ||
| 38 | struct maple_devinfo { | 38 | struct maple_devinfo { |
| 39 | unsigned long function; | 39 | unsigned long function; |
| 40 | unsigned long function_data[3]; | 40 | unsigned long function_data[3]; |
| 41 | unsigned char area_code; | 41 | unsigned char area_code; |
| 42 | unsigned char connector_directon; | 42 | unsigned char connector_direction; |
| 43 | char product_name[31]; | 43 | char product_name[31]; |
| 44 | char product_licence[61]; | 44 | char product_licence[61]; |
| 45 | unsigned short standby_power; | 45 | unsigned short standby_power; |
| 46 | unsigned short max_power; | 46 | unsigned short max_power; |
| 47 | }; | 47 | }; |
| 48 | 48 | ||
| 49 | struct maple_device { | 49 | struct maple_device { |
| 50 | struct maple_driver *driver; | 50 | struct maple_driver *driver; |
| 51 | struct mapleq *mq; | 51 | struct mapleq *mq; |
| 52 | void *private_data; | 52 | void *private_data; |
| 53 | void (*callback) (struct mapleq * mq); | 53 | void (*callback) (struct mapleq * mq); |
| 54 | unsigned long when, interval, function; | 54 | unsigned long when, interval, function; |
| 55 | struct maple_devinfo devinfo; | 55 | struct maple_devinfo devinfo; |
| 56 | unsigned char port, unit; | 56 | unsigned char port, unit; |
| 57 | char product_name[32]; | 57 | char product_name[32]; |
| 58 | char product_licence[64]; | 58 | char product_licence[64]; |
| 59 | int registered; | 59 | struct device dev; |
| 60 | struct device dev; | ||
| 61 | }; | 60 | }; |
| 62 | 61 | ||
| 63 | struct maple_driver { | 62 | struct maple_driver { |
| 64 | unsigned long function; | 63 | unsigned long function; |
| 65 | int (*connect) (struct maple_device * dev); | 64 | int (*connect) (struct maple_device * dev); |
| 66 | void (*disconnect) (struct maple_device * dev); | 65 | void (*disconnect) (struct maple_device * dev); |
| 67 | struct device_driver drv; | 66 | struct device_driver drv; |
| 67 | int registered; | ||
| 68 | }; | 68 | }; |
| 69 | 69 | ||
| 70 | void maple_getcond_callback(struct maple_device *dev, | 70 | void maple_getcond_callback(struct maple_device *dev, |
| 71 | void (*callback) (struct mapleq * mq), | 71 | void (*callback) (struct mapleq * mq), |
| 72 | unsigned long interval, | 72 | unsigned long interval, |
| 73 | unsigned long function); | 73 | unsigned long function); |
| 74 | int maple_driver_register(struct device_driver *drv); | 74 | int maple_driver_register(struct device_driver *drv); |
| 75 | void maple_add_packet(struct mapleq *mq); | 75 | void maple_add_packet(struct mapleq *mq); |
| 76 | 76 | ||
| 77 | #define to_maple_dev(n) container_of(n, struct maple_device, dev) | 77 | #define to_maple_dev(n) container_of(n, struct maple_device, dev) |
| 78 | #define to_maple_driver(n) container_of(n, struct maple_driver, drv) | 78 | #define to_maple_driver(n) container_of(n, struct maple_driver, drv) |
| 79 | 79 | ||
| 80 | #endif /* __LINUX_MAPLE_H */ | 80 | #endif /* __LINUX_MAPLE_H */ |
