Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6

* git://git.kernel.org/pub/scm/linux/kernel/git/lethal/sh-2.6: (46 commits)
sh: Fix multiple UTLB hit on UP SH-4.
sh: fix pci io access for r2d boards
sh: fix ioreadN_rep and iowriteN_rep
sh: use ctrl_in/out for on chip pci access
sh: Kill off more dead symbols.
sh: __uncached_start only on sh32.
sh: asm/irq.h needs asm/cpu/irq.h.
serial: sh-sci: Fix up SH-5 build.
sh: Get SH-5 caches working again post-unification.
maple: Fix up maple build failure.
sh: Kill off bogus SH_SDK7780_STANDALONE symbol.
sh: asm/tlb.h needs linux/pagemap.h for CONFIG_SWAP=n.
sh: Tidy include/asm-sh/hp6xx.h
maple: improve detection of attached peripherals
sh: Shut up some trivial build warnings.
sh: Update SH-5 flush_cache_sigtramp() for API changes.
sh: Fix up set_fixmap_nocache() for SH-5.
sh: Fix up pte_mkhuge() build breakage for SH-5.
sh: Disable big endian for SH-5.
sh: Handle SH7366 CPU in check_bugs().
...

+3340 -1818
+19
arch/sh/Kconfig
··· 93 93 config ARCH_SUPPORTS_AOUT 94 94 def_bool y 95 95 96 + config IO_TRAPPED 97 + bool 98 + 96 99 source "init/Kconfig" 97 100 98 101 menu "System type" ··· 315 312 select ARCH_SPARSEMEM_ENABLE 316 313 select SYS_SUPPORTS_NUMA 317 314 315 + config CPU_SUBTYPE_SH7366 316 + bool "Support SH7366 processor" 317 + select CPU_SH4AL_DSP 318 + select CPU_SHX2 319 + select ARCH_SPARSEMEM_ENABLE 320 + select SYS_SUPPORTS_NUMA 321 + 318 322 # SH-5 Processor Support 319 323 320 324 config CPU_SUBTYPE_SH5_101 ··· 466 456 bool "RTS7751R2D" 467 457 depends on CPU_SUBTYPE_SH7751R 468 458 select SYS_SUPPORTS_PCI 459 + select IO_TRAPPED 469 460 help 470 461 Select RTS7751R2D if configuring for a Renesas Technology 471 462 Sales SH-Graphics board. ··· 483 472 bool "Highlander" 484 473 depends on CPU_SUBTYPE_SH7780 || CPU_SUBTYPE_SH7785 485 474 select SYS_SUPPORTS_PCI 475 + select IO_TRAPPED 476 + 477 + config SH_MIGOR 478 + bool "Migo-R" 479 + depends on CPU_SUBTYPE_SH7722 480 + help 481 + Select Migo-R if configuring for the SH7722 Migo-R platform 482 + by Renesas System Solutions Asia Pte. Ltd. 486 483 487 484 config SH_EDOSK7705 488 485 bool "EDOSK7705"
+1 -3
arch/sh/Kconfig.cpu
··· 12 12 13 13 config CPU_BIG_ENDIAN 14 14 bool "Big Endian" 15 + depends on !CPU_SH5 15 16 16 17 endchoice 17 18 ··· 86 85 depends on CPU_SUBTYPE_SH5_101 87 86 88 87 config CPU_HAS_INTEVT 89 - bool 90 - 91 - config CPU_HAS_MASKREG_IRQ 92 88 bool 93 89 94 90 config CPU_HAS_IPR_IRQ
+2 -1
arch/sh/Kconfig.debug
··· 29 29 config EARLY_SCIF_CONSOLE_PORT 30 30 hex 31 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 34 default "0xffea0000" if CPU_SUBTYPE_SH7785 34 35 default "0xfffe8000" if CPU_SUBTYPE_SH7203 35 36 default "0xfffe9800" if CPU_SUBTYPE_SH7206 || CPU_SUBTYPE_SH7263
+1
arch/sh/Makefile
··· 116 116 machdir-$(CONFIG_SH_7751_SYSTEMH) += renesas/systemh 117 117 machdir-$(CONFIG_SH_EDOSK7705) += renesas/edosk7705 118 118 machdir-$(CONFIG_SH_HIGHLANDER) += renesas/r7780rp 119 + machdir-$(CONFIG_SH_MIGOR) += renesas/migor 119 120 machdir-$(CONFIG_SH_SDK7780) += renesas/sdk7780 120 121 machdir-$(CONFIG_SH_7710VOIPGW) += renesas/sh7710voipgw 121 122 machdir-$(CONFIG_SH_X3PROTO) += renesas/x3proto
+1
arch/sh/boards/renesas/migor/Makefile
··· 1 + obj-y := setup.o
+61
arch/sh/boards/renesas/migor/setup.c
··· 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 + };
+16 -31
arch/sh/boards/renesas/r7780rp/setup.c
··· 23 23 #include <asm/clock.h> 24 24 #include <asm/heartbeat.h> 25 25 #include <asm/io.h> 26 + #include <asm/io_trapped.h> 26 27 27 28 static struct resource r8a66597_usb_host_resources[] = { 28 29 [0] = { ··· 182 181 &m66592_usb_peripheral_device, 183 182 &heartbeat_device, 184 183 #ifndef CONFIG_SH_R7780RP 185 - &cf_ide_device, 186 184 &ax88796_device, 187 185 #endif 188 186 }; 189 187 188 + /* 189 + * The CF is connected using a 16-bit bus where 8-bit operations are 190 + * unsupported. The linux ata driver is however using 8-bit operations, so 191 + * insert a trapped io filter to convert 8-bit operations into 16-bit. 192 + */ 193 + static struct trapped_io cf_trapped_io = { 194 + .resource = cf_ide_resources, 195 + .num_resources = 2, 196 + .minimum_bus_width = 16, 197 + }; 198 + 190 199 static int __init r7780rp_devices_setup(void) 191 200 { 201 + #ifndef CONFIG_SH_R7780RP 202 + if (register_trapped_io(&cf_trapped_io) == 0) 203 + platform_device_register(&cf_ide_device); 204 + #endif 192 205 return platform_add_devices(r7780rp_devices, 193 206 ARRAY_SIZE(r7780rp_devices)); 194 207 } ··· 239 224 { 240 225 if (mach_is_r7780mp() || mach_is_r7785rp()) 241 226 ctrl_outw(0x0001, PA_POFF); 242 - } 243 - 244 - static inline unsigned char is_ide_ioaddr(unsigned long addr) 245 - { 246 - return ((cf_ide_resources[0].start <= addr && 247 - addr <= cf_ide_resources[0].end) || 248 - (cf_ide_resources[1].start <= addr && 249 - addr <= cf_ide_resources[1].end)); 250 - } 251 - 252 - void highlander_writeb(u8 b, void __iomem *addr) 253 - { 254 - unsigned long tmp = (unsigned long __force)addr; 255 - 256 - if (is_ide_ioaddr(tmp)) 257 - ctrl_outw((u16)b, tmp); 258 - else 259 - ctrl_outb(b, tmp); 260 - } 261 - 262 - u8 highlander_readb(void __iomem *addr) 263 - { 264 - unsigned long tmp = (unsigned long __force)addr; 265 - 266 - if (is_ide_ioaddr(tmp)) 267 - return ctrl_inw(tmp) & 0xff; 268 - else 269 - return ctrl_inb(tmp); 270 227 } 271 228 272 229 /* ··· 325 338 .mv_setup = highlander_setup, 326 339 .mv_init_irq = highlander_init_irq, 327 340 .mv_irq_demux = highlander_irq_demux, 328 - .mv_readb = highlander_readb, 329 - .mv_writeb = highlander_writeb, 330 341 };
+14 -31
arch/sh/boards/renesas/rts7751r2d/setup.c
··· 21 21 #include <asm/machvec.h> 22 22 #include <asm/rts7751r2d.h> 23 23 #include <asm/io.h> 24 + #include <asm/io_trapped.h> 24 25 #include <asm/spi.h> 25 26 26 27 static struct resource cf_ide_resources[] = { ··· 215 214 &uart_device, 216 215 &sm501_device, 217 216 #endif 218 - &cf_ide_device, 219 217 &heartbeat_device, 220 218 &spi_sh_sci_device, 221 219 }; 222 220 221 + /* 222 + * The CF is connected with a 16-bit bus where 8-bit operations are 223 + * unsupported. The linux ata driver is however using 8-bit operations, so 224 + * insert a trapped io filter to convert 8-bit operations into 16-bit. 225 + */ 226 + static struct trapped_io cf_trapped_io = { 227 + .resource = cf_ide_resources, 228 + .num_resources = 2, 229 + .minimum_bus_width = 16, 230 + }; 231 + 223 232 static int __init rts7751r2d_devices_setup(void) 224 233 { 234 + if (register_trapped_io(&cf_trapped_io) == 0) 235 + platform_device_register(&cf_ide_device); 225 236 spi_register_board_info(spi_bus, ARRAY_SIZE(spi_bus)); 226 237 return platform_add_devices(rts7751r2d_devices, 227 238 ARRAY_SIZE(rts7751r2d_devices)); ··· 243 230 static void rts7751r2d_power_off(void) 244 231 { 245 232 ctrl_outw(0x0001, PA_POWOFF); 246 - } 247 - 248 - static inline unsigned char is_ide_ioaddr(unsigned long addr) 249 - { 250 - return ((cf_ide_resources[0].start <= addr && 251 - addr <= cf_ide_resources[0].end) || 252 - (cf_ide_resources[1].start <= addr && 253 - addr <= cf_ide_resources[1].end)); 254 - } 255 - 256 - void rts7751r2d_writeb(u8 b, void __iomem *addr) 257 - { 258 - unsigned long tmp = (unsigned long __force)addr; 259 - 260 - if (is_ide_ioaddr(tmp)) 261 - ctrl_outw((u16)b, tmp); 262 - else 263 - ctrl_outb(b, tmp); 264 - } 265 - 266 - u8 rts7751r2d_readb(void __iomem *addr) 267 - { 268 - unsigned long tmp = (unsigned long __force)addr; 269 - 270 - if (is_ide_ioaddr(tmp)) 271 - return ctrl_inw(tmp) & 0xff; 272 - else 273 - return ctrl_inb(tmp); 274 233 } 275 234 276 235 /* ··· 295 310 .mv_setup = rts7751r2d_setup, 296 311 .mv_init_irq = init_rts7751r2d_IRQ, 297 312 .mv_irq_demux = rts7751r2d_irq_demux, 298 - .mv_writeb = rts7751r2d_writeb, 299 - .mv_readb = rts7751r2d_readb, 300 313 };
-7
arch/sh/boards/renesas/sdk7780/Kconfig
··· 4 4 prompt "SDK7780 options" 5 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 7 config SH_SDK7780_BASE 15 8 bool "SDK7780 with base-board support" 16 9 depends on CPU_SUBTYPE_SH7780
+14 -33
arch/sh/cchips/hd6446x/hd64465/setup.c
··· 17 17 #include <linux/interrupt.h> 18 18 #include <linux/init.h> 19 19 #include <linux/irq.h> 20 - 21 20 #include <asm/io.h> 22 21 #include <asm/irq.h> 23 - 24 22 #include <asm/hd64465/hd64465.h> 25 23 26 24 static void disable_hd64465_irq(unsigned int irq) ··· 26 28 unsigned short nimr; 27 29 unsigned short mask = 1 << (irq - HD64465_IRQ_BASE); 28 30 29 - pr_debug("disable_hd64465_irq(%d): mask=%x\n", irq, mask); 31 + pr_debug("disable_hd64465_irq(%d): mask=%x\n", irq, mask); 30 32 nimr = inw(HD64465_REG_NIMR); 31 33 nimr |= mask; 32 34 outw(nimr, HD64465_REG_NIMR); 33 35 } 34 - 35 36 36 37 static void enable_hd64465_irq(unsigned int irq) 37 38 { 38 39 unsigned short nimr; 39 40 unsigned short mask = 1 << (irq - HD64465_IRQ_BASE); 40 41 41 - pr_debug("enable_hd64465_irq(%d): mask=%x\n", irq, mask); 42 + pr_debug("enable_hd64465_irq(%d): mask=%x\n", irq, mask); 42 43 nimr = inw(HD64465_REG_NIMR); 43 44 nimr &= ~mask; 44 45 outw(nimr, HD64465_REG_NIMR); 45 46 } 46 47 47 - 48 48 static void mask_and_ack_hd64465(unsigned int irq) 49 49 { 50 50 disable_hd64465_irq(irq); 51 51 } 52 - 53 52 54 53 static void end_hd64465_irq(unsigned int irq) 55 54 { ··· 54 59 enable_hd64465_irq(irq); 55 60 } 56 61 57 - 58 62 static unsigned int startup_hd64465_irq(unsigned int irq) 59 - { 63 + { 60 64 enable_hd64465_irq(irq); 61 65 return 0; 62 66 } 63 - 64 67 65 68 static void shutdown_hd64465_irq(unsigned int irq) 66 69 { 67 70 disable_hd64465_irq(irq); 68 71 } 69 - 70 72 71 73 static struct hw_interrupt_type hd64465_irq_type = { 72 74 .typename = "HD64465-IRQ", ··· 75 83 .end = end_hd64465_irq, 76 84 }; 77 85 78 - 79 86 static irqreturn_t hd64465_interrupt(int irq, void *dev_id) 80 87 { 81 88 printk(KERN_INFO ··· 84 93 return IRQ_NONE; 85 94 } 86 95 87 - 88 - /*====================================================*/ 89 - 90 96 /* 91 97 * Support for a secondary IRQ demux step. This is necessary 92 98 * because the HD64465 presents a very thin interface to the ··· 91 103 * normally done in hardware by other PCMCIA host bridges is 92 104 * instead done in software. 93 105 */ 94 - static struct 95 - { 106 + static struct { 96 107 int (*func)(int, void *); 97 108 void *dev; 98 109 } hd64465_demux[HD64465_IRQ_NUM]; ··· 99 112 void hd64465_register_irq_demux(int irq, 100 113 int (*demux)(int irq, void *dev), void *dev) 101 114 { 102 - hd64465_demux[irq - HD64465_IRQ_BASE].func = demux; 103 - hd64465_demux[irq - HD64465_IRQ_BASE].dev = dev; 115 + hd64465_demux[irq - HD64465_IRQ_BASE].func = demux; 116 + hd64465_demux[irq - HD64465_IRQ_BASE].dev = dev; 104 117 } 105 118 EXPORT_SYMBOL(hd64465_register_irq_demux); 106 119 107 120 void hd64465_unregister_irq_demux(int irq) 108 121 { 109 - hd64465_demux[irq - HD64465_IRQ_BASE].func = 0; 122 + hd64465_demux[irq - HD64465_IRQ_BASE].func = 0; 110 123 } 111 124 EXPORT_SYMBOL(hd64465_unregister_irq_demux); 112 - 113 - 114 125 115 126 int hd64465_irq_demux(int irq) 116 127 { ··· 117 132 unsigned short nirr = inw(HD64465_REG_NIRR); 118 133 unsigned short nimr = inw(HD64465_REG_NIMR); 119 134 120 - pr_debug("hd64465_irq_demux, nirr=%04x, nimr=%04x\n", nirr, nimr); 135 + pr_debug("hd64465_irq_demux, nirr=%04x, nimr=%04x\n", nirr, nimr); 121 136 nirr &= ~nimr; 122 137 for (bit = 1, i = 0 ; i < HD64465_IRQ_NUM ; bit <<= 1, i++) 123 138 if (nirr & bit) 124 - break; 139 + break; 125 140 126 - if (i < HD64465_IRQ_NUM) { 141 + if (i < HD64465_IRQ_NUM) { 127 142 irq = HD64465_IRQ_BASE + i; 128 - if (hd64465_demux[i].func != 0) 129 - irq = hd64465_demux[i].func(irq, hd64465_demux[i].dev); 143 + if (hd64465_demux[i].func != 0) 144 + irq = hd64465_demux[i].func(irq, hd64465_demux[i].dev); 130 145 } 131 146 } 132 147 return irq; ··· 138 153 .mask = CPU_MASK_NONE, 139 154 .name = "HD64465", 140 155 }; 141 - 142 156 143 157 static int __init setup_hd64465(void) 144 158 { ··· 160 176 161 177 rev = inw(HD64465_REG_SRR); 162 178 printk(KERN_INFO "HD64465 hardware revision %d.%d\n", (rev >> 8) & 0xff, rev & 0xff); 163 - 164 - outw(0xffff, HD64465_REG_NIMR); /* mask all interrupts */ 179 + 180 + outw(0xffff, HD64465_REG_NIMR); /* mask all interrupts */ 165 181 166 182 for (i = 0; i < HD64465_IRQ_NUM ; i++) { 167 183 irq_desc[HD64465_IRQ_BASE + i].chip = &hd64465_irq_type; ··· 169 185 170 186 setup_irq(CONFIG_HD64465_IRQ, &irq0); 171 187 172 - #ifdef CONFIG_SERIAL 173 188 /* wake up the UART from STANDBY at this point */ 174 189 smscr = inw(HD64465_REG_SMSCR); 175 190 outw(smscr & (~HD64465_SMSCR_UARTST), HD64465_REG_SMSCR); 176 191 177 192 /* remap IO ports for first ISA serial port to HD64465 UART */ 178 193 hd64465_port_map(0x3f8, 8, CONFIG_HD64465_IOBASE + 0x8000, 1); 179 - #endif 180 194 181 195 return 0; 182 196 } 183 - 184 197 module_init(setup_hd64465);
+824
arch/sh/configs/migor_defconfig
··· 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
+265 -75
arch/sh/configs/rts7751r2d1_defconfig
··· 1 1 # 2 2 # Automatically generated make config: don't edit 3 - # Linux kernel version: 2.6.23-rc2 4 - # Tue Aug 14 18:04:44 2007 3 + # Linux kernel version: 2.6.24 4 + # Thu Feb 7 16:25:55 2008 5 5 # 6 6 CONFIG_SUPERH=y 7 + CONFIG_SUPERH32=y 7 8 CONFIG_RWSEM_GENERIC_SPINLOCK=y 8 9 CONFIG_GENERIC_BUG=y 9 10 CONFIG_GENERIC_FIND_NEXT_BIT=y ··· 37 36 # CONFIG_BSD_PROCESS_ACCT is not set 38 37 # CONFIG_TASKSTATS is not set 39 38 # CONFIG_USER_NS is not set 39 + # CONFIG_PID_NS is not set 40 40 # CONFIG_AUDIT is not set 41 41 # CONFIG_IKCONFIG is not set 42 42 CONFIG_LOG_BUF_SHIFT=14 43 + # CONFIG_CGROUPS is not set 44 + CONFIG_FAIR_GROUP_SCHED=y 45 + CONFIG_FAIR_USER_SCHED=y 46 + # CONFIG_FAIR_CGROUP_SCHED is not set 43 47 CONFIG_SYSFS_DEPRECATED=y 44 48 # CONFIG_RELAY is not set 45 49 # CONFIG_BLK_DEV_INITRD is not set ··· 59 53 CONFIG_PRINTK=y 60 54 CONFIG_BUG=y 61 55 CONFIG_ELF_CORE=y 56 + CONFIG_COMPAT_BRK=y 62 57 CONFIG_BASE_FULL=y 63 58 CONFIG_FUTEX=y 64 59 CONFIG_ANON_INODES=y ··· 72 65 CONFIG_SLAB=y 73 66 # CONFIG_SLUB is not set 74 67 # CONFIG_SLOB is not set 68 + CONFIG_PROFILING=y 69 + # CONFIG_MARKERS is not set 70 + CONFIG_OPROFILE=y 71 + CONFIG_HAVE_OPROFILE=y 72 + # CONFIG_HAVE_KPROBES is not set 73 + CONFIG_PROC_PAGE_MONITOR=y 74 + CONFIG_SLABINFO=y 75 75 CONFIG_RT_MUTEXES=y 76 76 # CONFIG_TINY_SHMEM is not set 77 77 CONFIG_BASE_SMALL=0 ··· 105 91 # CONFIG_DEFAULT_CFQ is not set 106 92 # CONFIG_DEFAULT_NOOP is not set 107 93 CONFIG_DEFAULT_IOSCHED="anticipatory" 94 + CONFIG_CLASSIC_RCU=y 95 + # CONFIG_PREEMPT_RCU is not set 108 96 109 97 # 110 98 # System type 111 99 # 112 100 CONFIG_CPU_SH4=y 113 101 # CONFIG_CPU_SUBTYPE_SH7619 is not set 102 + # CONFIG_CPU_SUBTYPE_SH7203 is not set 114 103 # CONFIG_CPU_SUBTYPE_SH7206 is not set 104 + # CONFIG_CPU_SUBTYPE_SH7263 is not set 115 105 # CONFIG_CPU_SUBTYPE_SH7705 is not set 116 106 # CONFIG_CPU_SUBTYPE_SH7706 is not set 117 107 # CONFIG_CPU_SUBTYPE_SH7707 is not set ··· 123 105 # CONFIG_CPU_SUBTYPE_SH7709 is not set 124 106 # CONFIG_CPU_SUBTYPE_SH7710 is not set 125 107 # CONFIG_CPU_SUBTYPE_SH7712 is not set 108 + # CONFIG_CPU_SUBTYPE_SH7720 is not set 109 + # CONFIG_CPU_SUBTYPE_SH7721 is not set 126 110 # CONFIG_CPU_SUBTYPE_SH7750 is not set 127 111 # CONFIG_CPU_SUBTYPE_SH7091 is not set 128 112 # CONFIG_CPU_SUBTYPE_SH7750R is not set ··· 133 113 CONFIG_CPU_SUBTYPE_SH7751R=y 134 114 # CONFIG_CPU_SUBTYPE_SH7760 is not set 135 115 # CONFIG_CPU_SUBTYPE_SH4_202 is not set 136 - # CONFIG_CPU_SUBTYPE_ST40STB1 is not set 137 - # CONFIG_CPU_SUBTYPE_ST40GX1 is not set 116 + # CONFIG_CPU_SUBTYPE_SH7763 is not set 138 117 # CONFIG_CPU_SUBTYPE_SH7770 is not set 139 118 # CONFIG_CPU_SUBTYPE_SH7780 is not set 140 119 # CONFIG_CPU_SUBTYPE_SH7785 is not set 141 120 # CONFIG_CPU_SUBTYPE_SHX3 is not set 142 121 # CONFIG_CPU_SUBTYPE_SH7343 is not set 143 122 # CONFIG_CPU_SUBTYPE_SH7722 is not set 123 + # CONFIG_CPU_SUBTYPE_SH5_101 is not set 124 + # CONFIG_CPU_SUBTYPE_SH5_103 is not set 144 125 145 126 # 146 127 # Memory management options ··· 151 130 CONFIG_PAGE_OFFSET=0x80000000 152 131 CONFIG_MEMORY_START=0x0c000000 153 132 CONFIG_MEMORY_SIZE=0x04000000 133 + CONFIG_29BIT=y 154 134 CONFIG_VSYSCALL=y 155 135 CONFIG_ARCH_FLATMEM_ENABLE=y 156 136 CONFIG_ARCH_SPARSEMEM_ENABLE=y ··· 169 147 CONFIG_FLATMEM=y 170 148 CONFIG_FLAT_NODE_MEM_MAP=y 171 149 CONFIG_SPARSEMEM_STATIC=y 150 + # CONFIG_SPARSEMEM_VMEMMAP_ENABLE is not set 172 151 CONFIG_SPLIT_PTLOCK_CPUS=4 173 152 # CONFIG_RESOURCES_64BIT is not set 174 153 CONFIG_ZONE_DMA_FLAG=0 ··· 191 168 CONFIG_SH_FPU=y 192 169 # CONFIG_SH_STORE_QUEUES is not set 193 170 CONFIG_CPU_HAS_INTEVT=y 194 - CONFIG_CPU_HAS_INTC_IRQ=y 195 171 CONFIG_CPU_HAS_SR_RB=y 196 172 CONFIG_CPU_HAS_PTEA=y 173 + CONFIG_CPU_HAS_FPU=y 197 174 198 175 # 199 176 # Board support 200 177 # 201 178 # CONFIG_SH_7751_SYSTEMH is not set 202 179 # CONFIG_SH_SECUREEDGE5410 is not set 203 - # CONFIG_SH_HS7751RVOIP is not set 204 180 CONFIG_SH_RTS7751R2D=y 205 181 # CONFIG_SH_LANDISK is not set 206 182 # CONFIG_SH_TITAN is not set 207 183 # CONFIG_SH_LBOX_RE2 is not set 208 184 209 185 # 210 - # RTS7751R2D options 186 + # RTS7751R2D Board Revision 211 187 # 212 188 # CONFIG_RTS7751R2D_PLUS is not set 213 189 CONFIG_RTS7751R2D_1=y ··· 220 198 # CONFIG_TICK_ONESHOT is not set 221 199 # CONFIG_NO_HZ is not set 222 200 # CONFIG_HIGH_RES_TIMERS is not set 201 + CONFIG_GENERIC_CLOCKEVENTS_BUILD=y 223 202 224 203 # 225 204 # CPU Frequency scaling ··· 250 227 # CONFIG_HZ_300 is not set 251 228 # CONFIG_HZ_1000 is not set 252 229 CONFIG_HZ=250 230 + # CONFIG_SCHED_HRTICK is not set 253 231 # CONFIG_KEXEC is not set 254 232 # CONFIG_CRASH_DUMP is not set 255 233 CONFIG_PREEMPT_NONE=y 256 234 # CONFIG_PREEMPT_VOLUNTARY is not set 257 235 # CONFIG_PREEMPT is not set 236 + CONFIG_RCU_TRACE=y 237 + CONFIG_GUSA=y 238 + # CONFIG_GUSA_RB is not set 258 239 259 240 # 260 241 # Boot options ··· 277 250 CONFIG_PCI_AUTO=y 278 251 CONFIG_PCI_AUTO_UPDATE_RESOURCES=y 279 252 # CONFIG_ARCH_SUPPORTS_MSI is not set 280 - 281 - # 282 - # PCCARD (PCMCIA/CardBus) support 283 - # 253 + CONFIG_PCI_LEGACY=y 284 254 # CONFIG_PCCARD is not set 285 255 CONFIG_HOTPLUG_PCI=y 286 256 # CONFIG_HOTPLUG_PCI_FAKE is not set ··· 305 281 # CONFIG_XFRM_USER is not set 306 282 # CONFIG_XFRM_SUB_POLICY is not set 307 283 # CONFIG_XFRM_MIGRATE is not set 284 + # CONFIG_XFRM_STATISTICS is not set 308 285 # CONFIG_NET_KEY is not set 309 286 CONFIG_INET=y 310 287 # CONFIG_IP_MULTICAST is not set ··· 324 299 CONFIG_INET_XFRM_MODE_TRANSPORT=y 325 300 CONFIG_INET_XFRM_MODE_TUNNEL=y 326 301 CONFIG_INET_XFRM_MODE_BEET=y 302 + # CONFIG_INET_LRO is not set 327 303 CONFIG_INET_DIAG=y 328 304 CONFIG_INET_TCP_DIAG=y 329 305 # CONFIG_TCP_CONG_ADVANCED is not set ··· 350 324 # CONFIG_LAPB is not set 351 325 # CONFIG_ECONET is not set 352 326 # CONFIG_WAN_ROUTER is not set 353 - 354 - # 355 - # QoS and/or fair queueing 356 - # 357 327 # CONFIG_NET_SCHED is not set 358 328 359 329 # ··· 357 335 # 358 336 # CONFIG_NET_PKTGEN is not set 359 337 # CONFIG_HAMRADIO is not set 338 + # CONFIG_CAN is not set 360 339 # CONFIG_IRDA is not set 361 340 # CONFIG_BT is not set 362 341 # CONFIG_AF_RXRPC is not set ··· 379 356 # 380 357 # Generic Driver Options 381 358 # 359 + CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" 382 360 CONFIG_STANDALONE=y 383 361 CONFIG_PREVENT_FIRMWARE_BUILD=y 384 362 CONFIG_FW_LOADER=m ··· 395 371 # CONFIG_BLK_DEV_LOOP is not set 396 372 # CONFIG_BLK_DEV_NBD is not set 397 373 # CONFIG_BLK_DEV_SX8 is not set 374 + # CONFIG_BLK_DEV_UB is not set 398 375 CONFIG_BLK_DEV_RAM=y 399 376 CONFIG_BLK_DEV_RAM_COUNT=16 400 377 CONFIG_BLK_DEV_RAM_SIZE=4096 ··· 445 420 # CONFIG_SCSI_FC_ATTRS is not set 446 421 # CONFIG_SCSI_ISCSI_ATTRS is not set 447 422 # CONFIG_SCSI_SAS_LIBSAS is not set 423 + # CONFIG_SCSI_SRP_ATTRS is not set 448 424 CONFIG_SCSI_LOWLEVEL=y 449 425 # CONFIG_ISCSI_TCP is not set 450 426 # CONFIG_BLK_DEV_3W_XXXX_RAID is not set ··· 519 493 # CONFIG_PATA_MPIIX is not set 520 494 # CONFIG_PATA_OLDPIIX is not set 521 495 # CONFIG_PATA_NETCELL is not set 496 + # CONFIG_PATA_NINJA32 is not set 522 497 # CONFIG_PATA_NS87410 is not set 498 + # CONFIG_PATA_NS87415 is not set 523 499 # CONFIG_PATA_OPTI is not set 524 500 # CONFIG_PATA_OPTIDMA is not set 525 501 # CONFIG_PATA_PDC_OLD is not set ··· 536 508 # CONFIG_PATA_WINBOND is not set 537 509 CONFIG_PATA_PLATFORM=y 538 510 # CONFIG_MD is not set 539 - 540 - # 541 - # Fusion MPT device support 542 - # 543 511 # CONFIG_FUSION is not set 544 - # CONFIG_FUSION_SPI is not set 545 - # CONFIG_FUSION_FC is not set 546 - # CONFIG_FUSION_SAS is not set 547 512 548 513 # 549 514 # IEEE 1394 (FireWire) support ··· 551 530 # CONFIG_MACVLAN is not set 552 531 # CONFIG_EQUALIZER is not set 553 532 # CONFIG_TUN is not set 533 + # CONFIG_VETH is not set 554 534 # CONFIG_ARCNET is not set 555 535 # CONFIG_PHYLIB is not set 556 536 CONFIG_NET_ETHERNET=y 557 537 CONFIG_MII=y 538 + # CONFIG_AX88796 is not set 558 539 # CONFIG_STNIC is not set 559 540 # CONFIG_HAPPYMEAL is not set 560 541 # CONFIG_SUNGEM is not set 561 542 # CONFIG_CASSINI is not set 562 543 # CONFIG_NET_VENDOR_3COM is not set 563 544 # CONFIG_SMC91X is not set 545 + # CONFIG_ENC28J60 is not set 564 546 # CONFIG_NET_TULIP is not set 565 547 # CONFIG_HP100 is not set 548 + # CONFIG_IBM_NEW_EMAC_ZMII is not set 549 + # CONFIG_IBM_NEW_EMAC_RGMII is not set 550 + # CONFIG_IBM_NEW_EMAC_TAH is not set 551 + # CONFIG_IBM_NEW_EMAC_EMAC4 is not set 566 552 CONFIG_NET_PCI=y 567 553 # CONFIG_PCNET32 is not set 568 554 # CONFIG_AMD8111_ETH is not set 569 555 # CONFIG_ADAPTEC_STARFIRE is not set 570 556 # CONFIG_B44 is not set 571 557 # CONFIG_FORCEDETH is not set 572 - # CONFIG_DGRS is not set 573 558 # CONFIG_EEPRO100 is not set 574 559 # CONFIG_E100 is not set 575 560 # CONFIG_FEALNX is not set ··· 587 560 # CONFIG_8139TOO_TUNE_TWISTER is not set 588 561 # CONFIG_8139TOO_8129 is not set 589 562 # CONFIG_8139_OLD_RX_RESET is not set 563 + # CONFIG_R6040 is not set 590 564 # CONFIG_SIS900 is not set 591 565 # CONFIG_EPIC100 is not set 592 566 # CONFIG_SUNDANCE is not set ··· 598 570 # CONFIG_ACENIC is not set 599 571 # CONFIG_DL2K is not set 600 572 # CONFIG_E1000 is not set 573 + # CONFIG_E1000E is not set 574 + # CONFIG_E1000E_ENABLED is not set 575 + # CONFIG_IP1000 is not set 576 + # CONFIG_IGB is not set 601 577 # CONFIG_NS83820 is not set 602 578 # CONFIG_HAMACHI is not set 603 579 # CONFIG_YELLOWFIN is not set ··· 609 577 # CONFIG_SIS190 is not set 610 578 # CONFIG_SKGE is not set 611 579 # CONFIG_SKY2 is not set 580 + # CONFIG_SK98LIN is not set 612 581 # CONFIG_VIA_VELOCITY is not set 613 582 # CONFIG_TIGON3 is not set 614 583 # CONFIG_BNX2 is not set ··· 618 585 CONFIG_NETDEV_10000=y 619 586 # CONFIG_CHELSIO_T1 is not set 620 587 # CONFIG_CHELSIO_T3 is not set 588 + # CONFIG_IXGBE is not set 621 589 # CONFIG_IXGB is not set 622 590 # CONFIG_S2IO is not set 623 591 # CONFIG_MYRI10GE is not set 624 592 # CONFIG_NETXEN_NIC is not set 593 + # CONFIG_NIU is not set 625 594 # CONFIG_MLX4_CORE is not set 595 + # CONFIG_TEHUTI is not set 596 + # CONFIG_BNX2X is not set 626 597 # CONFIG_TR is not set 627 598 628 599 # ··· 634 597 # 635 598 # CONFIG_WLAN_PRE80211 is not set 636 599 # CONFIG_WLAN_80211 is not set 600 + 601 + # 602 + # USB Network Adapters 603 + # 604 + # CONFIG_USB_CATC is not set 605 + # CONFIG_USB_KAWETH is not set 606 + # CONFIG_USB_PEGASUS is not set 607 + # CONFIG_USB_RTL8150 is not set 608 + # CONFIG_USB_USBNET is not set 637 609 # CONFIG_WAN is not set 638 610 # CONFIG_FDDI is not set 639 611 # CONFIG_HIPPI is not set 640 612 # CONFIG_PPP is not set 641 613 # CONFIG_SLIP is not set 642 614 # CONFIG_NET_FC is not set 643 - # CONFIG_SHAPER is not set 644 615 # CONFIG_NETCONSOLE is not set 645 616 # CONFIG_NETPOLL is not set 646 617 # CONFIG_NET_POLL_CONTROLLER is not set ··· 667 622 # 668 623 # CONFIG_INPUT_MOUSEDEV is not set 669 624 # CONFIG_INPUT_JOYDEV is not set 670 - # CONFIG_INPUT_TSDEV is not set 671 625 # CONFIG_INPUT_EVDEV is not set 672 626 # CONFIG_INPUT_EVBUG is not set 673 627 ··· 694 650 CONFIG_HW_CONSOLE=y 695 651 CONFIG_VT_HW_CONSOLE_BINDING=y 696 652 # CONFIG_SERIAL_NONSTANDARD is not set 653 + # CONFIG_NOZOMI is not set 697 654 698 655 # 699 656 # Serial drivers ··· 719 674 CONFIG_LEGACY_PTYS=y 720 675 CONFIG_LEGACY_PTY_COUNT=256 721 676 # CONFIG_IPMI_HANDLER is not set 722 - # CONFIG_WATCHDOG is not set 723 677 CONFIG_HW_RANDOM=y 724 678 # CONFIG_R3964 is not set 725 679 # CONFIG_APPLICOM is not set 726 - # CONFIG_DRM is not set 727 680 # CONFIG_RAW_DRIVER is not set 728 681 # CONFIG_TCG_TPM is not set 729 682 CONFIG_DEVPORT=y ··· 730 687 # 731 688 # SPI support 732 689 # 733 - # CONFIG_SPI is not set 734 - # CONFIG_SPI_MASTER is not set 690 + CONFIG_SPI=y 691 + CONFIG_SPI_MASTER=y 692 + 693 + # 694 + # SPI Master Controller Drivers 695 + # 696 + CONFIG_SPI_BITBANG=y 697 + CONFIG_SPI_SH_SCI=y 698 + 699 + # 700 + # SPI Protocol Masters 701 + # 702 + # CONFIG_SPI_AT25 is not set 703 + # CONFIG_SPI_SPIDEV is not set 704 + # CONFIG_SPI_TLE62X0 is not set 735 705 # CONFIG_W1 is not set 736 706 # CONFIG_POWER_SUPPLY is not set 737 707 CONFIG_HWMON=y 738 708 # CONFIG_HWMON_VID is not set 739 - # CONFIG_SENSORS_ABITUGURU is not set 740 - # CONFIG_SENSORS_ABITUGURU3 is not set 709 + # CONFIG_SENSORS_I5K_AMB is not set 741 710 # CONFIG_SENSORS_F71805F is not set 711 + # CONFIG_SENSORS_F71882FG is not set 742 712 # CONFIG_SENSORS_IT87 is not set 713 + # CONFIG_SENSORS_LM70 is not set 743 714 # CONFIG_SENSORS_PC87360 is not set 744 715 # CONFIG_SENSORS_PC87427 is not set 745 716 # CONFIG_SENSORS_SIS5595 is not set ··· 765 708 # CONFIG_SENSORS_W83627HF is not set 766 709 # CONFIG_SENSORS_W83627EHF is not set 767 710 # CONFIG_HWMON_DEBUG_CHIP is not set 711 + # CONFIG_WATCHDOG is not set 712 + 713 + # 714 + # Sonics Silicon Backplane 715 + # 716 + CONFIG_SSB_POSSIBLE=y 717 + # CONFIG_SSB is not set 768 718 769 719 # 770 720 # Multifunction device drivers ··· 784 720 # CONFIG_VIDEO_DEV is not set 785 721 # CONFIG_DVB_CORE is not set 786 722 CONFIG_DAB=y 723 + # CONFIG_USB_DABUSB is not set 787 724 788 725 # 789 726 # Graphics support 790 727 # 791 - # CONFIG_BACKLIGHT_LCD_SUPPORT is not set 792 - 793 - # 794 - # Display device support 795 - # 796 - # CONFIG_DISPLAY_SUPPORT is not set 728 + # CONFIG_DRM is not set 797 729 # CONFIG_VGASTATE is not set 798 730 CONFIG_VIDEO_OUTPUT_CONTROL=m 799 731 CONFIG_FB=y ··· 798 738 CONFIG_FB_CFB_FILLRECT=y 799 739 CONFIG_FB_CFB_COPYAREA=y 800 740 CONFIG_FB_CFB_IMAGEBLIT=y 741 + # CONFIG_FB_CFB_REV_PIXELS_IN_BYTE is not set 801 742 # CONFIG_FB_SYS_FILLRECT is not set 802 743 # CONFIG_FB_SYS_COPYAREA is not set 803 744 # CONFIG_FB_SYS_IMAGEBLIT is not set ··· 838 777 # CONFIG_FB_PM3 is not set 839 778 CONFIG_FB_SM501=y 840 779 # CONFIG_FB_VIRTUAL is not set 780 + # CONFIG_BACKLIGHT_LCD_SUPPORT is not set 781 + 782 + # 783 + # Display device support 784 + # 785 + # CONFIG_DISPLAY_SUPPORT is not set 841 786 842 787 # 843 788 # Console display driver support ··· 911 844 # CONFIG_SND_BT87X is not set 912 845 # CONFIG_SND_CA0106 is not set 913 846 # CONFIG_SND_CMIPCI is not set 847 + # CONFIG_SND_OXYGEN is not set 914 848 # CONFIG_SND_CS4281 is not set 915 849 # CONFIG_SND_CS46XX is not set 916 850 # CONFIG_SND_DARLA20 is not set ··· 936 868 # CONFIG_SND_HDA_INTEL is not set 937 869 # CONFIG_SND_HDSP is not set 938 870 # CONFIG_SND_HDSPM is not set 871 + # CONFIG_SND_HIFIER is not set 939 872 # CONFIG_SND_ICE1712 is not set 940 873 # CONFIG_SND_ICE1724 is not set 941 874 # CONFIG_SND_INTEL8X0 is not set ··· 954 885 # CONFIG_SND_TRIDENT is not set 955 886 # CONFIG_SND_VIA82XX is not set 956 887 # CONFIG_SND_VIA82XX_MODEM is not set 888 + # CONFIG_SND_VIRTUOSO is not set 957 889 # CONFIG_SND_VX222 is not set 958 890 CONFIG_SND_YMFPCI=m 959 891 CONFIG_SND_YMFPCI_FIRMWARE_IN_KERNEL=y 960 892 # CONFIG_SND_AC97_POWER_SAVE is not set 961 893 962 894 # 895 + # SPI devices 896 + # 897 + 898 + # 963 899 # SUPERH devices 964 900 # 901 + 902 + # 903 + # USB devices 904 + # 905 + # CONFIG_SND_USB_AUDIO is not set 906 + # CONFIG_SND_USB_CAIAQ is not set 965 907 966 908 # 967 909 # System on Chip audio support ··· 981 901 982 902 # 983 903 # SoC Audio support for SuperH 904 + # 905 + 906 + # 907 + # ALSA SoC audio for Freescale SOCs 984 908 # 985 909 986 910 # ··· 998 914 CONFIG_HID_SUPPORT=y 999 915 CONFIG_HID=y 1000 916 # CONFIG_HID_DEBUG is not set 917 + # CONFIG_HIDRAW is not set 918 + 919 + # 920 + # USB Input Devices 921 + # 922 + CONFIG_USB_HID=y 923 + # CONFIG_USB_HIDINPUT_POWERBOOK is not set 924 + # CONFIG_HID_FF is not set 925 + # CONFIG_USB_HIDDEV is not set 1001 926 CONFIG_USB_SUPPORT=y 1002 927 CONFIG_USB_ARCH_HAS_HCD=y 1003 928 CONFIG_USB_ARCH_HAS_OHCI=y 1004 929 CONFIG_USB_ARCH_HAS_EHCI=y 1005 - # CONFIG_USB is not set 930 + CONFIG_USB=y 931 + # CONFIG_USB_DEBUG is not set 932 + CONFIG_USB_ANNOUNCE_NEW_DEVICES=y 933 + 934 + # 935 + # Miscellaneous USB options 936 + # 937 + # CONFIG_USB_DEVICEFS is not set 938 + CONFIG_USB_DEVICE_CLASS=y 939 + # CONFIG_USB_DYNAMIC_MINORS is not set 940 + # CONFIG_USB_OTG is not set 941 + 942 + # 943 + # USB Host Controller Drivers 944 + # 945 + # CONFIG_USB_EHCI_HCD is not set 946 + # CONFIG_USB_ISP116X_HCD is not set 947 + CONFIG_USB_OHCI_HCD=y 948 + # CONFIG_USB_OHCI_BIG_ENDIAN_DESC is not set 949 + # CONFIG_USB_OHCI_BIG_ENDIAN_MMIO is not set 950 + CONFIG_USB_OHCI_LITTLE_ENDIAN=y 951 + # CONFIG_USB_UHCI_HCD is not set 952 + # CONFIG_USB_SL811_HCD is not set 953 + # CONFIG_USB_R8A66597_HCD is not set 954 + 955 + # 956 + # USB Device Class drivers 957 + # 958 + # CONFIG_USB_ACM is not set 959 + # CONFIG_USB_PRINTER is not set 1006 960 1007 961 # 1008 962 # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' 1009 963 # 1010 964 1011 965 # 1012 - # USB Gadget Support 966 + # may also be needed; see USB_STORAGE Help for more information 1013 967 # 968 + CONFIG_USB_STORAGE=y 969 + # CONFIG_USB_STORAGE_DEBUG is not set 970 + # CONFIG_USB_STORAGE_DATAFAB is not set 971 + # CONFIG_USB_STORAGE_FREECOM is not set 972 + # CONFIG_USB_STORAGE_ISD200 is not set 973 + # CONFIG_USB_STORAGE_DPCM is not set 974 + # CONFIG_USB_STORAGE_USBAT is not set 975 + # CONFIG_USB_STORAGE_SDDR09 is not set 976 + # CONFIG_USB_STORAGE_SDDR55 is not set 977 + # CONFIG_USB_STORAGE_JUMPSHOT is not set 978 + # CONFIG_USB_STORAGE_ALAUDA is not set 979 + # CONFIG_USB_STORAGE_KARMA is not set 980 + CONFIG_USB_LIBUSUAL=y 981 + 982 + # 983 + # USB Imaging devices 984 + # 985 + # CONFIG_USB_MDC800 is not set 986 + # CONFIG_USB_MICROTEK is not set 987 + # CONFIG_USB_MON is not set 988 + 989 + # 990 + # USB port drivers 991 + # 992 + # CONFIG_USB_SERIAL is not set 993 + 994 + # 995 + # USB Miscellaneous drivers 996 + # 997 + # CONFIG_USB_EMI62 is not set 998 + # CONFIG_USB_EMI26 is not set 999 + # CONFIG_USB_ADUTUX is not set 1000 + # CONFIG_USB_AUERSWALD is not set 1001 + # CONFIG_USB_RIO500 is not set 1002 + # CONFIG_USB_LEGOTOWER is not set 1003 + # CONFIG_USB_LCD is not set 1004 + # CONFIG_USB_BERRY_CHARGE is not set 1005 + # CONFIG_USB_LED is not set 1006 + # CONFIG_USB_CYPRESS_CY7C63 is not set 1007 + # CONFIG_USB_CYTHERM is not set 1008 + # CONFIG_USB_PHIDGET is not set 1009 + # CONFIG_USB_IDMOUSE is not set 1010 + # CONFIG_USB_FTDI_ELAN is not set 1011 + # CONFIG_USB_APPLEDISPLAY is not set 1012 + # CONFIG_USB_LD is not set 1013 + # CONFIG_USB_TRANCEVIBRATOR is not set 1014 + # CONFIG_USB_IOWARRIOR is not set 1014 1015 # CONFIG_USB_GADGET is not set 1015 1016 # CONFIG_MMC is not set 1016 1017 # CONFIG_NEW_LEDS is not set ··· 1118 949 # 1119 950 # SPI RTC drivers 1120 951 # 952 + # CONFIG_RTC_DRV_MAX6902 is not set 953 + CONFIG_RTC_DRV_R9701=y 954 + # CONFIG_RTC_DRV_RS5C348 is not set 1121 955 1122 956 # 1123 957 # Platform RTC drivers 1124 958 # 959 + # CONFIG_RTC_DRV_DS1511 is not set 1125 960 # CONFIG_RTC_DRV_DS1553 is not set 1126 - # CONFIG_RTC_DRV_STK17TA8 is not set 1127 961 # CONFIG_RTC_DRV_DS1742 is not set 962 + # CONFIG_RTC_DRV_STK17TA8 is not set 1128 963 # CONFIG_RTC_DRV_M48T86 is not set 1129 964 # CONFIG_RTC_DRV_M48T59 is not set 1130 965 # CONFIG_RTC_DRV_V3020 is not set ··· 1136 963 # 1137 964 # on-CPU RTC drivers 1138 965 # 1139 - CONFIG_RTC_DRV_SH=y 1140 - 1141 - # 1142 - # DMA Engine support 1143 - # 1144 - # CONFIG_DMA_ENGINE is not set 1145 - 1146 - # 1147 - # DMA Clients 1148 - # 1149 - 1150 - # 1151 - # DMA Devices 1152 - # 966 + # CONFIG_RTC_DRV_SH is not set 1153 967 1154 968 # 1155 969 # Userspace I/O ··· 1194 1034 # CONFIG_TMPFS_POSIX_ACL is not set 1195 1035 # CONFIG_HUGETLBFS is not set 1196 1036 # CONFIG_HUGETLB_PAGE is not set 1197 - CONFIG_RAMFS=y 1198 1037 # CONFIG_CONFIGFS_FS is not set 1199 1038 1200 1039 # ··· 1212 1053 # CONFIG_QNX4FS_FS is not set 1213 1054 # CONFIG_SYSV_FS is not set 1214 1055 # CONFIG_UFS_FS is not set 1215 - 1216 - # 1217 - # Network File Systems 1218 - # 1056 + CONFIG_NETWORK_FILESYSTEMS=y 1219 1057 # CONFIG_NFS_FS is not set 1220 1058 # CONFIG_NFSD is not set 1221 1059 # CONFIG_SMB_FS is not set ··· 1226 1070 # 1227 1071 # CONFIG_PARTITION_ADVANCED is not set 1228 1072 CONFIG_MSDOS_PARTITION=y 1229 - 1230 - # 1231 - # Native Language Support 1232 - # 1233 1073 CONFIG_NLS=y 1234 1074 CONFIG_NLS_DEFAULT="iso8859-1" 1235 1075 # CONFIG_NLS_CODEPAGE_437 is not set ··· 1266 1114 # CONFIG_NLS_KOI8_R is not set 1267 1115 # CONFIG_NLS_KOI8_U is not set 1268 1116 # CONFIG_NLS_UTF8 is not set 1269 - 1270 - # 1271 - # Distributed Lock Manager 1272 - # 1273 1117 # CONFIG_DLM is not set 1274 - 1275 - # 1276 - # Profiling support 1277 - # 1278 - CONFIG_PROFILING=y 1279 - CONFIG_OPROFILE=y 1280 1118 1281 1119 # 1282 1120 # Kernel hacking 1283 1121 # 1284 1122 CONFIG_TRACE_IRQFLAGS_SUPPORT=y 1285 1123 # CONFIG_PRINTK_TIME is not set 1124 + CONFIG_ENABLE_WARN_DEPRECATED=y 1286 1125 CONFIG_ENABLE_MUST_CHECK=y 1287 1126 # CONFIG_MAGIC_SYSRQ is not set 1288 1127 # CONFIG_UNUSED_SYMBOLS is not set 1289 - # CONFIG_DEBUG_FS is not set 1128 + CONFIG_DEBUG_FS=y 1290 1129 # CONFIG_HEADERS_CHECK is not set 1291 1130 # CONFIG_DEBUG_KERNEL is not set 1292 1131 # CONFIG_DEBUG_BUGVERBOSE is not set 1132 + # CONFIG_SAMPLES is not set 1293 1133 # CONFIG_SH_STANDARD_BIOS is not set 1294 1134 CONFIG_EARLY_SCIF_CONSOLE=y 1295 1135 CONFIG_EARLY_SCIF_CONSOLE_PORT=0xffe80000 ··· 1293 1149 # 1294 1150 # CONFIG_KEYS is not set 1295 1151 # CONFIG_SECURITY is not set 1296 - # CONFIG_CRYPTO is not set 1152 + # CONFIG_SECURITY_FILE_CAPABILITIES is not set 1153 + CONFIG_CRYPTO=y 1154 + # CONFIG_CRYPTO_SEQIV is not set 1155 + # CONFIG_CRYPTO_MANAGER is not set 1156 + # CONFIG_CRYPTO_HMAC is not set 1157 + # CONFIG_CRYPTO_XCBC is not set 1158 + # CONFIG_CRYPTO_NULL is not set 1159 + # CONFIG_CRYPTO_MD4 is not set 1160 + # CONFIG_CRYPTO_MD5 is not set 1161 + # CONFIG_CRYPTO_SHA1 is not set 1162 + # CONFIG_CRYPTO_SHA256 is not set 1163 + # CONFIG_CRYPTO_SHA512 is not set 1164 + # CONFIG_CRYPTO_WP512 is not set 1165 + # CONFIG_CRYPTO_TGR192 is not set 1166 + # CONFIG_CRYPTO_GF128MUL is not set 1167 + # CONFIG_CRYPTO_ECB is not set 1168 + # CONFIG_CRYPTO_CBC is not set 1169 + # CONFIG_CRYPTO_PCBC is not set 1170 + # CONFIG_CRYPTO_LRW is not set 1171 + # CONFIG_CRYPTO_XTS is not set 1172 + # CONFIG_CRYPTO_CTR is not set 1173 + # CONFIG_CRYPTO_GCM is not set 1174 + # CONFIG_CRYPTO_CCM is not set 1175 + # CONFIG_CRYPTO_CRYPTD is not set 1176 + # CONFIG_CRYPTO_DES is not set 1177 + # CONFIG_CRYPTO_FCRYPT is not set 1178 + # CONFIG_CRYPTO_BLOWFISH is not set 1179 + # CONFIG_CRYPTO_TWOFISH is not set 1180 + # CONFIG_CRYPTO_SERPENT is not set 1181 + # CONFIG_CRYPTO_AES is not set 1182 + # CONFIG_CRYPTO_CAST5 is not set 1183 + # CONFIG_CRYPTO_CAST6 is not set 1184 + # CONFIG_CRYPTO_TEA is not set 1185 + # CONFIG_CRYPTO_ARC4 is not set 1186 + # CONFIG_CRYPTO_KHAZAD is not set 1187 + # CONFIG_CRYPTO_ANUBIS is not set 1188 + # CONFIG_CRYPTO_SEED is not set 1189 + # CONFIG_CRYPTO_SALSA20 is not set 1190 + # CONFIG_CRYPTO_DEFLATE is not set 1191 + # CONFIG_CRYPTO_MICHAEL_MIC is not set 1192 + # CONFIG_CRYPTO_CRC32C is not set 1193 + # CONFIG_CRYPTO_CAMELLIA is not set 1194 + # CONFIG_CRYPTO_TEST is not set 1195 + # CONFIG_CRYPTO_AUTHENC is not set 1196 + # CONFIG_CRYPTO_LZO is not set 1197 + CONFIG_CRYPTO_HW=y 1198 + # CONFIG_CRYPTO_DEV_HIFN_795X is not set 1297 1199 1298 1200 # 1299 1201 # Library routines
+265 -75
arch/sh/configs/rts7751r2dplus_defconfig
··· 1 1 # 2 2 # Automatically generated make config: don't edit 3 - # Linux kernel version: 2.6.23-rc2 4 - # Tue Aug 14 16:33:08 2007 3 + # Linux kernel version: 2.6.24 4 + # Thu Feb 7 16:17:47 2008 5 5 # 6 6 CONFIG_SUPERH=y 7 + CONFIG_SUPERH32=y 7 8 CONFIG_RWSEM_GENERIC_SPINLOCK=y 8 9 CONFIG_GENERIC_BUG=y 9 10 CONFIG_GENERIC_FIND_NEXT_BIT=y ··· 37 36 # CONFIG_BSD_PROCESS_ACCT is not set 38 37 # CONFIG_TASKSTATS is not set 39 38 # CONFIG_USER_NS is not set 39 + # CONFIG_PID_NS is not set 40 40 # CONFIG_AUDIT is not set 41 41 # CONFIG_IKCONFIG is not set 42 42 CONFIG_LOG_BUF_SHIFT=14 43 + # CONFIG_CGROUPS is not set 44 + CONFIG_FAIR_GROUP_SCHED=y 45 + CONFIG_FAIR_USER_SCHED=y 46 + # CONFIG_FAIR_CGROUP_SCHED is not set 43 47 CONFIG_SYSFS_DEPRECATED=y 44 48 # CONFIG_RELAY is not set 45 49 # CONFIG_BLK_DEV_INITRD is not set ··· 59 53 CONFIG_PRINTK=y 60 54 CONFIG_BUG=y 61 55 CONFIG_ELF_CORE=y 56 + CONFIG_COMPAT_BRK=y 62 57 CONFIG_BASE_FULL=y 63 58 CONFIG_FUTEX=y 64 59 CONFIG_ANON_INODES=y ··· 72 65 CONFIG_SLAB=y 73 66 # CONFIG_SLUB is not set 74 67 # CONFIG_SLOB is not set 68 + CONFIG_PROFILING=y 69 + # CONFIG_MARKERS is not set 70 + CONFIG_OPROFILE=y 71 + CONFIG_HAVE_OPROFILE=y 72 + # CONFIG_HAVE_KPROBES is not set 73 + CONFIG_PROC_PAGE_MONITOR=y 74 + CONFIG_SLABINFO=y 75 75 CONFIG_RT_MUTEXES=y 76 76 # CONFIG_TINY_SHMEM is not set 77 77 CONFIG_BASE_SMALL=0 ··· 105 91 # CONFIG_DEFAULT_CFQ is not set 106 92 # CONFIG_DEFAULT_NOOP is not set 107 93 CONFIG_DEFAULT_IOSCHED="anticipatory" 94 + CONFIG_CLASSIC_RCU=y 95 + # CONFIG_PREEMPT_RCU is not set 108 96 109 97 # 110 98 # System type 111 99 # 112 100 CONFIG_CPU_SH4=y 113 101 # CONFIG_CPU_SUBTYPE_SH7619 is not set 102 + # CONFIG_CPU_SUBTYPE_SH7203 is not set 114 103 # CONFIG_CPU_SUBTYPE_SH7206 is not set 104 + # CONFIG_CPU_SUBTYPE_SH7263 is not set 115 105 # CONFIG_CPU_SUBTYPE_SH7705 is not set 116 106 # CONFIG_CPU_SUBTYPE_SH7706 is not set 117 107 # CONFIG_CPU_SUBTYPE_SH7707 is not set ··· 123 105 # CONFIG_CPU_SUBTYPE_SH7709 is not set 124 106 # CONFIG_CPU_SUBTYPE_SH7710 is not set 125 107 # CONFIG_CPU_SUBTYPE_SH7712 is not set 108 + # CONFIG_CPU_SUBTYPE_SH7720 is not set 109 + # CONFIG_CPU_SUBTYPE_SH7721 is not set 126 110 # CONFIG_CPU_SUBTYPE_SH7750 is not set 127 111 # CONFIG_CPU_SUBTYPE_SH7091 is not set 128 112 # CONFIG_CPU_SUBTYPE_SH7750R is not set ··· 133 113 CONFIG_CPU_SUBTYPE_SH7751R=y 134 114 # CONFIG_CPU_SUBTYPE_SH7760 is not set 135 115 # CONFIG_CPU_SUBTYPE_SH4_202 is not set 136 - # CONFIG_CPU_SUBTYPE_ST40STB1 is not set 137 - # CONFIG_CPU_SUBTYPE_ST40GX1 is not set 116 + # CONFIG_CPU_SUBTYPE_SH7763 is not set 138 117 # CONFIG_CPU_SUBTYPE_SH7770 is not set 139 118 # CONFIG_CPU_SUBTYPE_SH7780 is not set 140 119 # CONFIG_CPU_SUBTYPE_SH7785 is not set 141 120 # CONFIG_CPU_SUBTYPE_SHX3 is not set 142 121 # CONFIG_CPU_SUBTYPE_SH7343 is not set 143 122 # CONFIG_CPU_SUBTYPE_SH7722 is not set 123 + # CONFIG_CPU_SUBTYPE_SH5_101 is not set 124 + # CONFIG_CPU_SUBTYPE_SH5_103 is not set 144 125 145 126 # 146 127 # Memory management options ··· 151 130 CONFIG_PAGE_OFFSET=0x80000000 152 131 CONFIG_MEMORY_START=0x0c000000 153 132 CONFIG_MEMORY_SIZE=0x04000000 133 + CONFIG_29BIT=y 154 134 CONFIG_VSYSCALL=y 155 135 CONFIG_ARCH_FLATMEM_ENABLE=y 156 136 CONFIG_ARCH_SPARSEMEM_ENABLE=y ··· 169 147 CONFIG_FLATMEM=y 170 148 CONFIG_FLAT_NODE_MEM_MAP=y 171 149 CONFIG_SPARSEMEM_STATIC=y 150 + # CONFIG_SPARSEMEM_VMEMMAP_ENABLE is not set 172 151 CONFIG_SPLIT_PTLOCK_CPUS=4 173 152 # CONFIG_RESOURCES_64BIT is not set 174 153 CONFIG_ZONE_DMA_FLAG=0 ··· 191 168 CONFIG_SH_FPU=y 192 169 # CONFIG_SH_STORE_QUEUES is not set 193 170 CONFIG_CPU_HAS_INTEVT=y 194 - CONFIG_CPU_HAS_INTC_IRQ=y 195 171 CONFIG_CPU_HAS_SR_RB=y 196 172 CONFIG_CPU_HAS_PTEA=y 173 + CONFIG_CPU_HAS_FPU=y 197 174 198 175 # 199 176 # Board support 200 177 # 201 178 # CONFIG_SH_7751_SYSTEMH is not set 202 179 # CONFIG_SH_SECUREEDGE5410 is not set 203 - # CONFIG_SH_HS7751RVOIP is not set 204 180 CONFIG_SH_RTS7751R2D=y 205 181 # CONFIG_SH_LANDISK is not set 206 182 # CONFIG_SH_TITAN is not set 207 183 # CONFIG_SH_LBOX_RE2 is not set 208 184 209 185 # 210 - # RTS7751R2D options 186 + # RTS7751R2D Board Revision 211 187 # 212 188 CONFIG_RTS7751R2D_PLUS=y 213 189 # CONFIG_RTS7751R2D_1 is not set ··· 220 198 # CONFIG_TICK_ONESHOT is not set 221 199 # CONFIG_NO_HZ is not set 222 200 # CONFIG_HIGH_RES_TIMERS is not set 201 + CONFIG_GENERIC_CLOCKEVENTS_BUILD=y 223 202 224 203 # 225 204 # CPU Frequency scaling ··· 250 227 # CONFIG_HZ_300 is not set 251 228 # CONFIG_HZ_1000 is not set 252 229 CONFIG_HZ=250 230 + # CONFIG_SCHED_HRTICK is not set 253 231 # CONFIG_KEXEC is not set 254 232 # CONFIG_CRASH_DUMP is not set 255 233 CONFIG_PREEMPT_NONE=y 256 234 # CONFIG_PREEMPT_VOLUNTARY is not set 257 235 # CONFIG_PREEMPT is not set 236 + CONFIG_RCU_TRACE=y 237 + CONFIG_GUSA=y 238 + # CONFIG_GUSA_RB is not set 258 239 259 240 # 260 241 # Boot options ··· 277 250 CONFIG_PCI_AUTO=y 278 251 CONFIG_PCI_AUTO_UPDATE_RESOURCES=y 279 252 # CONFIG_ARCH_SUPPORTS_MSI is not set 280 - 281 - # 282 - # PCCARD (PCMCIA/CardBus) support 283 - # 253 + CONFIG_PCI_LEGACY=y 284 254 # CONFIG_PCCARD is not set 285 255 CONFIG_HOTPLUG_PCI=y 286 256 # CONFIG_HOTPLUG_PCI_FAKE is not set ··· 305 281 # CONFIG_XFRM_USER is not set 306 282 # CONFIG_XFRM_SUB_POLICY is not set 307 283 # CONFIG_XFRM_MIGRATE is not set 284 + # CONFIG_XFRM_STATISTICS is not set 308 285 # CONFIG_NET_KEY is not set 309 286 CONFIG_INET=y 310 287 # CONFIG_IP_MULTICAST is not set ··· 324 299 CONFIG_INET_XFRM_MODE_TRANSPORT=y 325 300 CONFIG_INET_XFRM_MODE_TUNNEL=y 326 301 CONFIG_INET_XFRM_MODE_BEET=y 302 + # CONFIG_INET_LRO is not set 327 303 CONFIG_INET_DIAG=y 328 304 CONFIG_INET_TCP_DIAG=y 329 305 # CONFIG_TCP_CONG_ADVANCED is not set ··· 350 324 # CONFIG_LAPB is not set 351 325 # CONFIG_ECONET is not set 352 326 # CONFIG_WAN_ROUTER is not set 353 - 354 - # 355 - # QoS and/or fair queueing 356 - # 357 327 # CONFIG_NET_SCHED is not set 358 328 359 329 # ··· 357 335 # 358 336 # CONFIG_NET_PKTGEN is not set 359 337 # CONFIG_HAMRADIO is not set 338 + # CONFIG_CAN is not set 360 339 # CONFIG_IRDA is not set 361 340 # CONFIG_BT is not set 362 341 # CONFIG_AF_RXRPC is not set ··· 379 356 # 380 357 # Generic Driver Options 381 358 # 359 + CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug" 382 360 CONFIG_STANDALONE=y 383 361 CONFIG_PREVENT_FIRMWARE_BUILD=y 384 362 CONFIG_FW_LOADER=m ··· 395 371 # CONFIG_BLK_DEV_LOOP is not set 396 372 # CONFIG_BLK_DEV_NBD is not set 397 373 # CONFIG_BLK_DEV_SX8 is not set 374 + # CONFIG_BLK_DEV_UB is not set 398 375 CONFIG_BLK_DEV_RAM=y 399 376 CONFIG_BLK_DEV_RAM_COUNT=16 400 377 CONFIG_BLK_DEV_RAM_SIZE=4096 ··· 445 420 # CONFIG_SCSI_FC_ATTRS is not set 446 421 # CONFIG_SCSI_ISCSI_ATTRS is not set 447 422 # CONFIG_SCSI_SAS_LIBSAS is not set 423 + # CONFIG_SCSI_SRP_ATTRS is not set 448 424 CONFIG_SCSI_LOWLEVEL=y 449 425 # CONFIG_ISCSI_TCP is not set 450 426 # CONFIG_BLK_DEV_3W_XXXX_RAID is not set ··· 519 493 # CONFIG_PATA_MPIIX is not set 520 494 # CONFIG_PATA_OLDPIIX is not set 521 495 # CONFIG_PATA_NETCELL is not set 496 + # CONFIG_PATA_NINJA32 is not set 522 497 # CONFIG_PATA_NS87410 is not set 498 + # CONFIG_PATA_NS87415 is not set 523 499 # CONFIG_PATA_OPTI is not set 524 500 # CONFIG_PATA_OPTIDMA is not set 525 501 # CONFIG_PATA_PDC_OLD is not set ··· 536 508 # CONFIG_PATA_WINBOND is not set 537 509 CONFIG_PATA_PLATFORM=y 538 510 # CONFIG_MD is not set 539 - 540 - # 541 - # Fusion MPT device support 542 - # 543 511 # CONFIG_FUSION is not set 544 - # CONFIG_FUSION_SPI is not set 545 - # CONFIG_FUSION_FC is not set 546 - # CONFIG_FUSION_SAS is not set 547 512 548 513 # 549 514 # IEEE 1394 (FireWire) support ··· 551 530 # CONFIG_MACVLAN is not set 552 531 # CONFIG_EQUALIZER is not set 553 532 # CONFIG_TUN is not set 533 + # CONFIG_VETH is not set 554 534 # CONFIG_ARCNET is not set 555 535 # CONFIG_PHYLIB is not set 556 536 CONFIG_NET_ETHERNET=y 557 537 CONFIG_MII=y 538 + # CONFIG_AX88796 is not set 558 539 # CONFIG_STNIC is not set 559 540 # CONFIG_HAPPYMEAL is not set 560 541 # CONFIG_SUNGEM is not set 561 542 # CONFIG_CASSINI is not set 562 543 # CONFIG_NET_VENDOR_3COM is not set 563 544 # CONFIG_SMC91X is not set 545 + # CONFIG_ENC28J60 is not set 564 546 # CONFIG_NET_TULIP is not set 565 547 # CONFIG_HP100 is not set 548 + # CONFIG_IBM_NEW_EMAC_ZMII is not set 549 + # CONFIG_IBM_NEW_EMAC_RGMII is not set 550 + # CONFIG_IBM_NEW_EMAC_TAH is not set 551 + # CONFIG_IBM_NEW_EMAC_EMAC4 is not set 566 552 CONFIG_NET_PCI=y 567 553 # CONFIG_PCNET32 is not set 568 554 # CONFIG_AMD8111_ETH is not set 569 555 # CONFIG_ADAPTEC_STARFIRE is not set 570 556 # CONFIG_B44 is not set 571 557 # CONFIG_FORCEDETH is not set 572 - # CONFIG_DGRS is not set 573 558 # CONFIG_EEPRO100 is not set 574 559 # CONFIG_E100 is not set 575 560 # CONFIG_FEALNX is not set ··· 587 560 # CONFIG_8139TOO_TUNE_TWISTER is not set 588 561 # CONFIG_8139TOO_8129 is not set 589 562 # CONFIG_8139_OLD_RX_RESET is not set 563 + # CONFIG_R6040 is not set 590 564 # CONFIG_SIS900 is not set 591 565 # CONFIG_EPIC100 is not set 592 566 # CONFIG_SUNDANCE is not set ··· 598 570 # CONFIG_ACENIC is not set 599 571 # CONFIG_DL2K is not set 600 572 # CONFIG_E1000 is not set 573 + # CONFIG_E1000E is not set 574 + # CONFIG_E1000E_ENABLED is not set 575 + # CONFIG_IP1000 is not set 576 + # CONFIG_IGB is not set 601 577 # CONFIG_NS83820 is not set 602 578 # CONFIG_HAMACHI is not set 603 579 # CONFIG_YELLOWFIN is not set ··· 609 577 # CONFIG_SIS190 is not set 610 578 # CONFIG_SKGE is not set 611 579 # CONFIG_SKY2 is not set 580 + # CONFIG_SK98LIN is not set 612 581 # CONFIG_VIA_VELOCITY is not set 613 582 # CONFIG_TIGON3 is not set 614 583 # CONFIG_BNX2 is not set ··· 618 585 CONFIG_NETDEV_10000=y 619 586 # CONFIG_CHELSIO_T1 is not set 620 587 # CONFIG_CHELSIO_T3 is not set 588 + # CONFIG_IXGBE is not set 621 589 # CONFIG_IXGB is not set 622 590 # CONFIG_S2IO is not set 623 591 # CONFIG_MYRI10GE is not set 624 592 # CONFIG_NETXEN_NIC is not set 593 + # CONFIG_NIU is not set 625 594 # CONFIG_MLX4_CORE is not set 595 + # CONFIG_TEHUTI is not set 596 + # CONFIG_BNX2X is not set 626 597 # CONFIG_TR is not set 627 598 628 599 # ··· 634 597 # 635 598 # CONFIG_WLAN_PRE80211 is not set 636 599 # CONFIG_WLAN_80211 is not set 600 + 601 + # 602 + # USB Network Adapters 603 + # 604 + # CONFIG_USB_CATC is not set 605 + # CONFIG_USB_KAWETH is not set 606 + # CONFIG_USB_PEGASUS is not set 607 + # CONFIG_USB_RTL8150 is not set 608 + # CONFIG_USB_USBNET is not set 637 609 # CONFIG_WAN is not set 638 610 # CONFIG_FDDI is not set 639 611 # CONFIG_HIPPI is not set 640 612 # CONFIG_PPP is not set 641 613 # CONFIG_SLIP is not set 642 614 # CONFIG_NET_FC is not set 643 - # CONFIG_SHAPER is not set 644 615 # CONFIG_NETCONSOLE is not set 645 616 # CONFIG_NETPOLL is not set 646 617 # CONFIG_NET_POLL_CONTROLLER is not set ··· 667 622 # 668 623 # CONFIG_INPUT_MOUSEDEV is not set 669 624 # CONFIG_INPUT_JOYDEV is not set 670 - # CONFIG_INPUT_TSDEV is not set 671 625 # CONFIG_INPUT_EVDEV is not set 672 626 # CONFIG_INPUT_EVBUG is not set 673 627 ··· 694 650 CONFIG_HW_CONSOLE=y 695 651 CONFIG_VT_HW_CONSOLE_BINDING=y 696 652 # CONFIG_SERIAL_NONSTANDARD is not set 653 + # CONFIG_NOZOMI is not set 697 654 698 655 # 699 656 # Serial drivers ··· 719 674 CONFIG_LEGACY_PTYS=y 720 675 CONFIG_LEGACY_PTY_COUNT=256 721 676 # CONFIG_IPMI_HANDLER is not set 722 - # CONFIG_WATCHDOG is not set 723 677 CONFIG_HW_RANDOM=y 724 678 # CONFIG_R3964 is not set 725 679 # CONFIG_APPLICOM is not set 726 - # CONFIG_DRM is not set 727 680 # CONFIG_RAW_DRIVER is not set 728 681 # CONFIG_TCG_TPM is not set 729 682 CONFIG_DEVPORT=y ··· 730 687 # 731 688 # SPI support 732 689 # 733 - # CONFIG_SPI is not set 734 - # CONFIG_SPI_MASTER is not set 690 + CONFIG_SPI=y 691 + CONFIG_SPI_MASTER=y 692 + 693 + # 694 + # SPI Master Controller Drivers 695 + # 696 + CONFIG_SPI_BITBANG=y 697 + CONFIG_SPI_SH_SCI=y 698 + 699 + # 700 + # SPI Protocol Masters 701 + # 702 + # CONFIG_SPI_AT25 is not set 703 + # CONFIG_SPI_SPIDEV is not set 704 + # CONFIG_SPI_TLE62X0 is not set 735 705 # CONFIG_W1 is not set 736 706 # CONFIG_POWER_SUPPLY is not set 737 707 CONFIG_HWMON=y 738 708 # CONFIG_HWMON_VID is not set 739 - # CONFIG_SENSORS_ABITUGURU is not set 740 - # CONFIG_SENSORS_ABITUGURU3 is not set 709 + # CONFIG_SENSORS_I5K_AMB is not set 741 710 # CONFIG_SENSORS_F71805F is not set 711 + # CONFIG_SENSORS_F71882FG is not set 742 712 # CONFIG_SENSORS_IT87 is not set 713 + # CONFIG_SENSORS_LM70 is not set 743 714 # CONFIG_SENSORS_PC87360 is not set 744 715 # CONFIG_SENSORS_PC87427 is not set 745 716 # CONFIG_SENSORS_SIS5595 is not set ··· 765 708 # CONFIG_SENSORS_W83627HF is not set 766 709 # CONFIG_SENSORS_W83627EHF is not set 767 710 # CONFIG_HWMON_DEBUG_CHIP is not set 711 + # CONFIG_WATCHDOG is not set 712 + 713 + # 714 + # Sonics Silicon Backplane 715 + # 716 + CONFIG_SSB_POSSIBLE=y 717 + # CONFIG_SSB is not set 768 718 769 719 # 770 720 # Multifunction device drivers ··· 784 720 # CONFIG_VIDEO_DEV is not set 785 721 # CONFIG_DVB_CORE is not set 786 722 CONFIG_DAB=y 723 + # CONFIG_USB_DABUSB is not set 787 724 788 725 # 789 726 # Graphics support 790 727 # 791 - # CONFIG_BACKLIGHT_LCD_SUPPORT is not set 792 - 793 - # 794 - # Display device support 795 - # 796 - # CONFIG_DISPLAY_SUPPORT is not set 728 + # CONFIG_DRM is not set 797 729 # CONFIG_VGASTATE is not set 798 730 CONFIG_VIDEO_OUTPUT_CONTROL=m 799 731 CONFIG_FB=y ··· 798 738 CONFIG_FB_CFB_FILLRECT=y 799 739 CONFIG_FB_CFB_COPYAREA=y 800 740 CONFIG_FB_CFB_IMAGEBLIT=y 741 + # CONFIG_FB_CFB_REV_PIXELS_IN_BYTE is not set 801 742 # CONFIG_FB_SYS_FILLRECT is not set 802 743 # CONFIG_FB_SYS_COPYAREA is not set 803 744 # CONFIG_FB_SYS_IMAGEBLIT is not set ··· 838 777 # CONFIG_FB_PM3 is not set 839 778 CONFIG_FB_SM501=y 840 779 # CONFIG_FB_VIRTUAL is not set 780 + # CONFIG_BACKLIGHT_LCD_SUPPORT is not set 781 + 782 + # 783 + # Display device support 784 + # 785 + # CONFIG_DISPLAY_SUPPORT is not set 841 786 842 787 # 843 788 # Console display driver support ··· 911 844 # CONFIG_SND_BT87X is not set 912 845 # CONFIG_SND_CA0106 is not set 913 846 # CONFIG_SND_CMIPCI is not set 847 + # CONFIG_SND_OXYGEN is not set 914 848 # CONFIG_SND_CS4281 is not set 915 849 # CONFIG_SND_CS46XX is not set 916 850 # CONFIG_SND_DARLA20 is not set ··· 936 868 # CONFIG_SND_HDA_INTEL is not set 937 869 # CONFIG_SND_HDSP is not set 938 870 # CONFIG_SND_HDSPM is not set 871 + # CONFIG_SND_HIFIER is not set 939 872 # CONFIG_SND_ICE1712 is not set 940 873 # CONFIG_SND_ICE1724 is not set 941 874 # CONFIG_SND_INTEL8X0 is not set ··· 954 885 # CONFIG_SND_TRIDENT is not set 955 886 # CONFIG_SND_VIA82XX is not set 956 887 # CONFIG_SND_VIA82XX_MODEM is not set 888 + # CONFIG_SND_VIRTUOSO is not set 957 889 # CONFIG_SND_VX222 is not set 958 890 CONFIG_SND_YMFPCI=m 959 891 CONFIG_SND_YMFPCI_FIRMWARE_IN_KERNEL=y 960 892 # CONFIG_SND_AC97_POWER_SAVE is not set 961 893 962 894 # 895 + # SPI devices 896 + # 897 + 898 + # 963 899 # SUPERH devices 964 900 # 901 + 902 + # 903 + # USB devices 904 + # 905 + # CONFIG_SND_USB_AUDIO is not set 906 + # CONFIG_SND_USB_CAIAQ is not set 965 907 966 908 # 967 909 # System on Chip audio support ··· 981 901 982 902 # 983 903 # SoC Audio support for SuperH 904 + # 905 + 906 + # 907 + # ALSA SoC audio for Freescale SOCs 984 908 # 985 909 986 910 # ··· 998 914 CONFIG_HID_SUPPORT=y 999 915 CONFIG_HID=y 1000 916 # CONFIG_HID_DEBUG is not set 917 + # CONFIG_HIDRAW is not set 918 + 919 + # 920 + # USB Input Devices 921 + # 922 + CONFIG_USB_HID=y 923 + # CONFIG_USB_HIDINPUT_POWERBOOK is not set 924 + # CONFIG_HID_FF is not set 925 + # CONFIG_USB_HIDDEV is not set 1001 926 CONFIG_USB_SUPPORT=y 1002 927 CONFIG_USB_ARCH_HAS_HCD=y 1003 928 CONFIG_USB_ARCH_HAS_OHCI=y 1004 929 CONFIG_USB_ARCH_HAS_EHCI=y 1005 - # CONFIG_USB is not set 930 + CONFIG_USB=y 931 + # CONFIG_USB_DEBUG is not set 932 + CONFIG_USB_ANNOUNCE_NEW_DEVICES=y 933 + 934 + # 935 + # Miscellaneous USB options 936 + # 937 + # CONFIG_USB_DEVICEFS is not set 938 + CONFIG_USB_DEVICE_CLASS=y 939 + # CONFIG_USB_DYNAMIC_MINORS is not set 940 + # CONFIG_USB_OTG is not set 941 + 942 + # 943 + # USB Host Controller Drivers 944 + # 945 + # CONFIG_USB_EHCI_HCD is not set 946 + # CONFIG_USB_ISP116X_HCD is not set 947 + CONFIG_USB_OHCI_HCD=y 948 + # CONFIG_USB_OHCI_BIG_ENDIAN_DESC is not set 949 + # CONFIG_USB_OHCI_BIG_ENDIAN_MMIO is not set 950 + CONFIG_USB_OHCI_LITTLE_ENDIAN=y 951 + # CONFIG_USB_UHCI_HCD is not set 952 + # CONFIG_USB_SL811_HCD is not set 953 + # CONFIG_USB_R8A66597_HCD is not set 954 + 955 + # 956 + # USB Device Class drivers 957 + # 958 + # CONFIG_USB_ACM is not set 959 + # CONFIG_USB_PRINTER is not set 1006 960 1007 961 # 1008 962 # NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' 1009 963 # 1010 964 1011 965 # 1012 - # USB Gadget Support 966 + # may also be needed; see USB_STORAGE Help for more information 1013 967 # 968 + CONFIG_USB_STORAGE=y 969 + # CONFIG_USB_STORAGE_DEBUG is not set 970 + # CONFIG_USB_STORAGE_DATAFAB is not set 971 + # CONFIG_USB_STORAGE_FREECOM is not set 972 + # CONFIG_USB_STORAGE_ISD200 is not set 973 + # CONFIG_USB_STORAGE_DPCM is not set 974 + # CONFIG_USB_STORAGE_USBAT is not set 975 + # CONFIG_USB_STORAGE_SDDR09 is not set 976 + # CONFIG_USB_STORAGE_SDDR55 is not set 977 + # CONFIG_USB_STORAGE_JUMPSHOT is not set 978 + # CONFIG_USB_STORAGE_ALAUDA is not set 979 + # CONFIG_USB_STORAGE_KARMA is not set 980 + CONFIG_USB_LIBUSUAL=y 981 + 982 + # 983 + # USB Imaging devices 984 + # 985 + # CONFIG_USB_MDC800 is not set 986 + # CONFIG_USB_MICROTEK is not set 987 + # CONFIG_USB_MON is not set 988 + 989 + # 990 + # USB port drivers 991 + # 992 + # CONFIG_USB_SERIAL is not set 993 + 994 + # 995 + # USB Miscellaneous drivers 996 + # 997 + # CONFIG_USB_EMI62 is not set 998 + # CONFIG_USB_EMI26 is not set 999 + # CONFIG_USB_ADUTUX is not set 1000 + # CONFIG_USB_AUERSWALD is not set 1001 + # CONFIG_USB_RIO500 is not set 1002 + # CONFIG_USB_LEGOTOWER is not set 1003 + # CONFIG_USB_LCD is not set 1004 + # CONFIG_USB_BERRY_CHARGE is not set 1005 + # CONFIG_USB_LED is not set 1006 + # CONFIG_USB_CYPRESS_CY7C63 is not set 1007 + # CONFIG_USB_CYTHERM is not set 1008 + # CONFIG_USB_PHIDGET is not set 1009 + # CONFIG_USB_IDMOUSE is not set 1010 + # CONFIG_USB_FTDI_ELAN is not set 1011 + # CONFIG_USB_APPLEDISPLAY is not set 1012 + # CONFIG_USB_LD is not set 1013 + # CONFIG_USB_TRANCEVIBRATOR is not set 1014 + # CONFIG_USB_IOWARRIOR is not set 1014 1015 # CONFIG_USB_GADGET is not set 1015 1016 # CONFIG_MMC is not set 1016 1017 # CONFIG_NEW_LEDS is not set ··· 1118 949 # 1119 950 # SPI RTC drivers 1120 951 # 952 + # CONFIG_RTC_DRV_MAX6902 is not set 953 + CONFIG_RTC_DRV_R9701=y 954 + # CONFIG_RTC_DRV_RS5C348 is not set 1121 955 1122 956 # 1123 957 # Platform RTC drivers 1124 958 # 959 + # CONFIG_RTC_DRV_DS1511 is not set 1125 960 # CONFIG_RTC_DRV_DS1553 is not set 1126 - # CONFIG_RTC_DRV_STK17TA8 is not set 1127 961 # CONFIG_RTC_DRV_DS1742 is not set 962 + # CONFIG_RTC_DRV_STK17TA8 is not set 1128 963 # CONFIG_RTC_DRV_M48T86 is not set 1129 964 # CONFIG_RTC_DRV_M48T59 is not set 1130 965 # CONFIG_RTC_DRV_V3020 is not set ··· 1136 963 # 1137 964 # on-CPU RTC drivers 1138 965 # 1139 - CONFIG_RTC_DRV_SH=y 1140 - 1141 - # 1142 - # DMA Engine support 1143 - # 1144 - # CONFIG_DMA_ENGINE is not set 1145 - 1146 - # 1147 - # DMA Clients 1148 - # 1149 - 1150 - # 1151 - # DMA Devices 1152 - # 966 + # CONFIG_RTC_DRV_SH is not set 1153 967 1154 968 # 1155 969 # Userspace I/O ··· 1194 1034 # CONFIG_TMPFS_POSIX_ACL is not set 1195 1035 # CONFIG_HUGETLBFS is not set 1196 1036 # CONFIG_HUGETLB_PAGE is not set 1197 - CONFIG_RAMFS=y 1198 1037 # CONFIG_CONFIGFS_FS is not set 1199 1038 1200 1039 # ··· 1212 1053 # CONFIG_QNX4FS_FS is not set 1213 1054 # CONFIG_SYSV_FS is not set 1214 1055 # CONFIG_UFS_FS is not set 1215 - 1216 - # 1217 - # Network File Systems 1218 - # 1056 + CONFIG_NETWORK_FILESYSTEMS=y 1219 1057 # CONFIG_NFS_FS is not set 1220 1058 # CONFIG_NFSD is not set 1221 1059 # CONFIG_SMB_FS is not set ··· 1226 1070 # 1227 1071 # CONFIG_PARTITION_ADVANCED is not set 1228 1072 CONFIG_MSDOS_PARTITION=y 1229 - 1230 - # 1231 - # Native Language Support 1232 - # 1233 1073 CONFIG_NLS=y 1234 1074 CONFIG_NLS_DEFAULT="iso8859-1" 1235 1075 # CONFIG_NLS_CODEPAGE_437 is not set ··· 1266 1114 # CONFIG_NLS_KOI8_R is not set 1267 1115 # CONFIG_NLS_KOI8_U is not set 1268 1116 # CONFIG_NLS_UTF8 is not set 1269 - 1270 - # 1271 - # Distributed Lock Manager 1272 - # 1273 1117 # CONFIG_DLM is not set 1274 - 1275 - # 1276 - # Profiling support 1277 - # 1278 - CONFIG_PROFILING=y 1279 - CONFIG_OPROFILE=y 1280 1118 1281 1119 # 1282 1120 # Kernel hacking 1283 1121 # 1284 1122 CONFIG_TRACE_IRQFLAGS_SUPPORT=y 1285 1123 # CONFIG_PRINTK_TIME is not set 1124 + CONFIG_ENABLE_WARN_DEPRECATED=y 1286 1125 CONFIG_ENABLE_MUST_CHECK=y 1287 1126 # CONFIG_MAGIC_SYSRQ is not set 1288 1127 # CONFIG_UNUSED_SYMBOLS is not set 1289 - # CONFIG_DEBUG_FS is not set 1128 + CONFIG_DEBUG_FS=y 1290 1129 # CONFIG_HEADERS_CHECK is not set 1291 1130 # CONFIG_DEBUG_KERNEL is not set 1292 1131 # CONFIG_DEBUG_BUGVERBOSE is not set 1132 + # CONFIG_SAMPLES is not set 1293 1133 # CONFIG_SH_STANDARD_BIOS is not set 1294 1134 CONFIG_EARLY_SCIF_CONSOLE=y 1295 1135 CONFIG_EARLY_SCIF_CONSOLE_PORT=0xffe80000 ··· 1293 1149 # 1294 1150 # CONFIG_KEYS is not set 1295 1151 # CONFIG_SECURITY is not set 1296 - # CONFIG_CRYPTO is not set 1152 + # CONFIG_SECURITY_FILE_CAPABILITIES is not set 1153 + CONFIG_CRYPTO=y 1154 + # CONFIG_CRYPTO_SEQIV is not set 1155 + # CONFIG_CRYPTO_MANAGER is not set 1156 + # CONFIG_CRYPTO_HMAC is not set 1157 + # CONFIG_CRYPTO_XCBC is not set 1158 + # CONFIG_CRYPTO_NULL is not set 1159 + # CONFIG_CRYPTO_MD4 is not set 1160 + # CONFIG_CRYPTO_MD5 is not set 1161 + # CONFIG_CRYPTO_SHA1 is not set 1162 + # CONFIG_CRYPTO_SHA256 is not set 1163 + # CONFIG_CRYPTO_SHA512 is not set 1164 + # CONFIG_CRYPTO_WP512 is not set 1165 + # CONFIG_CRYPTO_TGR192 is not set 1166 + # CONFIG_CRYPTO_GF128MUL is not set 1167 + # CONFIG_CRYPTO_ECB is not set 1168 + # CONFIG_CRYPTO_CBC is not set 1169 + # CONFIG_CRYPTO_PCBC is not set 1170 + # CONFIG_CRYPTO_LRW is not set 1171 + # CONFIG_CRYPTO_XTS is not set 1172 + # CONFIG_CRYPTO_CTR is not set 1173 + # CONFIG_CRYPTO_GCM is not set 1174 + # CONFIG_CRYPTO_CCM is not set 1175 + # CONFIG_CRYPTO_CRYPTD is not set 1176 + # CONFIG_CRYPTO_DES is not set 1177 + # CONFIG_CRYPTO_FCRYPT is not set 1178 + # CONFIG_CRYPTO_BLOWFISH is not set 1179 + # CONFIG_CRYPTO_TWOFISH is not set 1180 + # CONFIG_CRYPTO_SERPENT is not set 1181 + # CONFIG_CRYPTO_AES is not set 1182 + # CONFIG_CRYPTO_CAST5 is not set 1183 + # CONFIG_CRYPTO_CAST6 is not set 1184 + # CONFIG_CRYPTO_TEA is not set 1185 + # CONFIG_CRYPTO_ARC4 is not set 1186 + # CONFIG_CRYPTO_KHAZAD is not set 1187 + # CONFIG_CRYPTO_ANUBIS is not set 1188 + # CONFIG_CRYPTO_SEED is not set 1189 + # CONFIG_CRYPTO_SALSA20 is not set 1190 + # CONFIG_CRYPTO_DEFLATE is not set 1191 + # CONFIG_CRYPTO_MICHAEL_MIC is not set 1192 + # CONFIG_CRYPTO_CRC32C is not set 1193 + # CONFIG_CRYPTO_CAMELLIA is not set 1194 + # CONFIG_CRYPTO_TEST is not set 1195 + # CONFIG_CRYPTO_AUTHENC is not set 1196 + # CONFIG_CRYPTO_LZO is not set 1197 + CONFIG_CRYPTO_HW=y 1198 + # CONFIG_CRYPTO_DEV_HIFN_795X is not set 1297 1199 1298 1200 # 1299 1201 # Library routines
-1
arch/sh/configs/se7705_defconfig
··· 231 231 # CONFIG_SH_DSP is not set 232 232 # CONFIG_SH_ADC is not set 233 233 CONFIG_CPU_HAS_INTEVT=y 234 - CONFIG_CPU_HAS_PINT_IRQ=y 235 234 CONFIG_CPU_HAS_IPR_IRQ=y 236 235 CONFIG_CPU_HAS_SR_RB=y 237 236
+1 -1
arch/sh/drivers/dma/dma-api.c
··· 350 350 351 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 354 NULL, 0); 355 355 if (IS_ERR(info->pdev)) 356 356 return PTR_ERR(info->pdev);
+2 -2
arch/sh/drivers/pci/fixups-lboxre2.c
··· 18 18 { 19 19 unsigned long bcr1, mcr; 20 20 21 - bcr1 = inl(SH7751_BCR1); 21 + bcr1 = ctrl_inl(SH7751_BCR1); 22 22 bcr1 |= 0x40080000; /* Enable Bit 19 BREQEN, set PCIC to slave */ 23 23 pci_write_reg(bcr1, SH4_PCIBCR1); 24 24 ··· 28 28 pci_write_reg(0xfb900047, SH7751_PCICONF1); 29 29 pci_write_reg(0xab000001, SH7751_PCICONF4); 30 30 31 - mcr = inl(SH7751_MCR); 31 + mcr = ctrl_inl(SH7751_MCR); 32 32 mcr = (mcr & PCIMCR_MRSET_OFF) & PCIMCR_RFSH_OFF; 33 33 pci_write_reg(mcr, SH4_PCIMCR); 34 34
+2 -2
arch/sh/drivers/pci/fixups-rts7751r2d.c
··· 19 19 { 20 20 unsigned long bcr1, mcr; 21 21 22 - bcr1 = inl(SH7751_BCR1); 22 + bcr1 = ctrl_inl(SH7751_BCR1); 23 23 bcr1 |= 0x40080000; /* Enable Bit 19 BREQEN, set PCIC to slave */ 24 24 pci_write_reg(bcr1, SH4_PCIBCR1); 25 25 ··· 30 30 pci_write_reg(0xfb900047, SH7751_PCICONF1); 31 31 pci_write_reg(0xab000001, SH7751_PCICONF4); 32 32 33 - mcr = inl(SH7751_MCR); 33 + mcr = ctrl_inl(SH7751_MCR); 34 34 mcr = (mcr & PCIMCR_MRSET_OFF) & PCIMCR_RFSH_OFF; 35 35 pci_write_reg(mcr, SH4_PCIMCR); 36 36
+22 -22
arch/sh/drivers/pci/ops-dreamcast.c
··· 83 83 return PCIBIOS_DEVICE_NOT_FOUND; 84 84 85 85 switch (size) { 86 - case 1: *val = inb(GAPSPCI_BBA_CONFIG+where); break; 87 - case 2: *val = inw(GAPSPCI_BBA_CONFIG+where); break; 88 - case 4: *val = inl(GAPSPCI_BBA_CONFIG+where); break; 86 + case 1: *val = ctrl_inb(GAPSPCI_BBA_CONFIG+where); break; 87 + case 2: *val = ctrl_inw(GAPSPCI_BBA_CONFIG+where); break; 88 + case 4: *val = ctrl_inl(GAPSPCI_BBA_CONFIG+where); break; 89 89 } 90 90 91 91 return PCIBIOS_SUCCESSFUL; ··· 97 97 return PCIBIOS_DEVICE_NOT_FOUND; 98 98 99 99 switch (size) { 100 - case 1: outb(( u8)val, GAPSPCI_BBA_CONFIG+where); break; 101 - case 2: outw((u16)val, GAPSPCI_BBA_CONFIG+where); break; 102 - case 4: outl((u32)val, GAPSPCI_BBA_CONFIG+where); break; 100 + case 1: ctrl_outb(( u8)val, GAPSPCI_BBA_CONFIG+where); break; 101 + case 2: ctrl_outw((u16)val, GAPSPCI_BBA_CONFIG+where); break; 102 + case 4: ctrl_outl((u32)val, GAPSPCI_BBA_CONFIG+where); break; 103 103 } 104 104 105 105 return PCIBIOS_SUCCESSFUL; ··· 127 127 */ 128 128 129 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 132 if (strncmp(idbuf, "GAPSPCI_BRIDGE_2", 16)) 133 133 return -ENODEV; 134 134 135 - outl(0x5a14a501, GAPSPCI_REGS+0x18); 135 + ctrl_outl(0x5a14a501, GAPSPCI_REGS+0x18); 136 136 137 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 141 return -EINVAL; 142 142 143 - outl(0x01000000, GAPSPCI_REGS+0x20); 144 - outl(0x01000000, GAPSPCI_REGS+0x24); 143 + ctrl_outl(0x01000000, GAPSPCI_REGS+0x20); 144 + ctrl_outl(0x01000000, GAPSPCI_REGS+0x24); 145 145 146 - outl(GAPSPCI_DMA_BASE, GAPSPCI_REGS+0x28); 147 - outl(GAPSPCI_DMA_BASE+GAPSPCI_DMA_SIZE, GAPSPCI_REGS+0x2c); 146 + ctrl_outl(GAPSPCI_DMA_BASE, GAPSPCI_REGS+0x28); 147 + ctrl_outl(GAPSPCI_DMA_BASE+GAPSPCI_DMA_SIZE, GAPSPCI_REGS+0x2c); 148 148 149 - outl(1, GAPSPCI_REGS+0x14); 150 - outl(1, GAPSPCI_REGS+0x34); 149 + ctrl_outl(1, GAPSPCI_REGS+0x14); 150 + ctrl_outl(1, GAPSPCI_REGS+0x34); 151 151 152 152 /* Setting Broadband Adapter */ 153 - outw(0xf900, GAPSPCI_BBA_CONFIG+0x06); 154 - outl(0x00000000, GAPSPCI_BBA_CONFIG+0x30); 155 - outb(0x00, GAPSPCI_BBA_CONFIG+0x3c); 156 - outb(0xf0, GAPSPCI_BBA_CONFIG+0x0d); 157 - outw(0x0006, GAPSPCI_BBA_CONFIG+0x04); 158 - outl(0x00002001, GAPSPCI_BBA_CONFIG+0x10); 159 - outl(0x01000000, GAPSPCI_BBA_CONFIG+0x14); 153 + ctrl_outw(0xf900, GAPSPCI_BBA_CONFIG+0x06); 154 + ctrl_outl(0x00000000, GAPSPCI_BBA_CONFIG+0x30); 155 + ctrl_outb(0x00, GAPSPCI_BBA_CONFIG+0x3c); 156 + ctrl_outb(0xf0, GAPSPCI_BBA_CONFIG+0x0d); 157 + ctrl_outw(0x0006, GAPSPCI_BBA_CONFIG+0x04); 158 + ctrl_outl(0x00002001, GAPSPCI_BBA_CONFIG+0x10); 159 + ctrl_outl(0x01000000, GAPSPCI_BBA_CONFIG+0x14); 160 160 161 161 return 0; 162 162 }
+2 -1
arch/sh/drivers/pci/ops-rts7751r2d.c
··· 33 33 static struct resource sh7751_io_resource = { 34 34 .name = "SH7751_IO", 35 35 .start = 0x4000, 36 - .end = 0x4000 + SH7751_PCI_IO_SIZE - 1, 36 + .end = SH7751_PCI_IO_SIZE - 1, 37 37 .flags = IORESOURCE_IO 38 38 }; 39 39 ··· 68 68 69 69 int __init pcibios_init_platform(void) 70 70 { 71 + __set_io_port_base(SH7751_PCI_IO_BASE); 71 72 return sh7751_pcic_init(&sh7751_pci_map); 72 73 } 73 74
+2 -2
arch/sh/drivers/pci/pci-sh4.h
··· 172 172 173 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 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 182 #endif /* __PCI_SH4_H */
+8 -8
arch/sh/drivers/pci/pci-sh7751.c
··· 58 58 { 59 59 u32 word; 60 60 61 - word = inl(SH7751_BCR1); 61 + word = ctrl_inl(SH7751_BCR1); 62 62 /* check BCR for SDRAM in area */ 63 63 if (((word >> area) & 1) == 0) { 64 64 printk("PCI: Area %d is not configured for SDRAM. BCR1=0x%x\n", ··· 67 67 } 68 68 pci_write_reg(word, SH4_PCIBCR1); 69 69 70 - word = (u16)inw(SH7751_BCR2); 70 + word = (u16)ctrl_inw(SH7751_BCR2); 71 71 /* check BCR2 for 32bit SDRAM interface*/ 72 72 if (((word >> (area << 1)) & 0x3) != 0x3) { 73 73 printk("PCI: Area %d is not 32 bit SDRAM. BCR2=0x%x\n", ··· 85 85 u32 word; 86 86 87 87 /* Set the BCR's to enable PCI access */ 88 - reg = inl(SH7751_BCR1); 88 + reg = ctrl_inl(SH7751_BCR1); 89 89 reg |= 0x80000; 90 - outl(reg, SH7751_BCR1); 90 + ctrl_outl(reg, SH7751_BCR1); 91 91 92 92 /* Turn the clocks back on (not done in reset)*/ 93 93 pci_write_reg(0, SH4_PCICLKR); ··· 179 179 return 0; 180 180 181 181 /* configure the wait control registers */ 182 - word = inl(SH7751_WCR1); 182 + word = ctrl_inl(SH7751_WCR1); 183 183 pci_write_reg(word, SH4_PCIWCR1); 184 - word = inl(SH7751_WCR2); 184 + word = ctrl_inl(SH7751_WCR2); 185 185 pci_write_reg(word, SH4_PCIWCR2); 186 - word = inl(SH7751_WCR3); 186 + word = ctrl_inl(SH7751_WCR3); 187 187 pci_write_reg(word, SH4_PCIWCR3); 188 - word = inl(SH7751_MCR); 188 + word = ctrl_inl(SH7751_MCR); 189 189 pci_write_reg(word, SH4_PCIMCR); 190 190 191 191 /* NOTE: I'm ignoring the PCI error IRQs for now..
+1 -1
arch/sh/drivers/pci/pci-sh7780.c
··· 52 52 53 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 57 /* check for SH7780/SH7780R hardware */ 58 58 id = pci_read_reg(SH7780_PCIVID);
+1
arch/sh/kernel/Makefile_32
··· 22 22 obj-$(CONFIG_PM) += pm.o 23 23 obj-$(CONFIG_STACKTRACE) += stacktrace.o 24 24 obj-$(CONFIG_BINFMT_ELF) += dump_task.o 25 + obj-$(CONFIG_IO_TRAPPED) += io_trapped.o 25 26 26 27 EXTRA_CFLAGS += -Werror
+1
arch/sh/kernel/Makefile_64
··· 18 18 obj-$(CONFIG_PM) += pm.o 19 19 obj-$(CONFIG_STACKTRACE) += stacktrace.o 20 20 obj-$(CONFIG_BINFMT_ELF) += dump_task.o 21 + obj-$(CONFIG_IO_TRAPPED) += io_trapped.o 21 22 22 23 EXTRA_CFLAGS += -Werror
-1
arch/sh/kernel/cpu/irq/Makefile
··· 6 6 obj-$(CONFIG_SUPERH32) += imask.o 7 7 obj-$(CONFIG_CPU_SH5) += intc-sh5.o 8 8 obj-$(CONFIG_CPU_HAS_IPR_IRQ) += ipr.o 9 - obj-$(CONFIG_CPU_HAS_MASKREG_IRQ) += maskreg.o
+12 -15
arch/sh/kernel/cpu/irq/intc-sh5.c
··· 75 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 78 static unsigned long intc_virt; 94 79 95 80 static unsigned int startup_intc_irq(unsigned int irq); ··· 161 176 } 162 177 163 178 #if defined(CONFIG_PROC_FS) && defined(CONFIG_SYSCTL) 179 + static int IRQ_to_vectorN[NR_INTC_IRQS] = { 180 + 0x12, 0x15, 0x18, 0x1B, 0x40, 0x41, 0x42, 0x43, /* 0- 7 */ 181 + -1, -1, -1, -1, 0x50, 0x51, 0x52, 0x53, /* 8-15 */ 182 + 0x54, 0x55, 0x32, 0x33, 0x34, 0x35, 0x36, -1, /* 16-23 */ 183 + -1, -1, -1, -1, -1, -1, -1, -1, /* 24-31 */ 184 + 0x20, 0x21, 0x22, 0x23, 0x24, 0x25, 0x26, 0x38, /* 32-39 */ 185 + 0x39, 0x3A, 0x3B, -1, -1, -1, -1, -1, /* 40-47 */ 186 + -1, -1, -1, -1, -1, -1, -1, -1, /* 48-55 */ 187 + -1, -1, -1, -1, -1, -1, -1, 0x2B, /* 56-63 */ 188 + 189 + }; 190 + 164 191 int intc_irq_describe(char* p, int irq) 165 192 { 166 193 if (irq < NR_INTC_IRQS)
-93
arch/sh/kernel/cpu/irq/maskreg.c
··· 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 - }
+7 -1
arch/sh/kernel/cpu/sh4/probe.c
··· 126 126 CPU_HAS_LLSC; 127 127 break; 128 128 case 0x3008: 129 - if (prr == 0xa0) { 129 + if (prr == 0xa0 || prr == 0xa1) { 130 130 boot_cpu_data.type = CPU_SH7722; 131 + boot_cpu_data.icache.ways = 4; 132 + boot_cpu_data.dcache.ways = 4; 133 + boot_cpu_data.flags |= CPU_HAS_LLSC; 134 + } 135 + else if (prr == 0x70) { 136 + boot_cpu_data.type = CPU_SH7366; 131 137 boot_cpu_data.icache.ways = 4; 132 138 boot_cpu_data.dcache.ways = 4; 133 139 boot_cpu_data.flags |= CPU_HAS_LLSC;
+2
arch/sh/kernel/cpu/sh4a/Makefile
··· 9 9 obj-$(CONFIG_CPU_SUBTYPE_SH7785) += setup-sh7785.o 10 10 obj-$(CONFIG_CPU_SUBTYPE_SH7343) += setup-sh7343.o 11 11 obj-$(CONFIG_CPU_SUBTYPE_SH7722) += setup-sh7722.o 12 + obj-$(CONFIG_CPU_SUBTYPE_SH7366) += setup-sh7366.o 12 13 obj-$(CONFIG_CPU_SUBTYPE_SHX3) += setup-shx3.o 13 14 14 15 # SMP setup ··· 22 21 clock-$(CONFIG_CPU_SUBTYPE_SH7785) := clock-sh7785.o 23 22 clock-$(CONFIG_CPU_SUBTYPE_SH7343) := clock-sh7343.o 24 23 clock-$(CONFIG_CPU_SUBTYPE_SH7722) := clock-sh7722.o 24 + clock-$(CONFIG_CPU_SUBTYPE_SH7366) := clock-sh7722.o 25 25 clock-$(CONFIG_CPU_SUBTYPE_SHX3) := clock-shx3.o 26 26 27 27 obj-y += $(clock-y)
+9 -1
arch/sh/kernel/cpu/sh4a/clock-sh7722.c
··· 1 1 /* 2 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 6 * Copyright (c) 2006-2007 Nomad Global Solutions Inc 7 7 * Based on code for sh7343 by Paul Mundt ··· 417 417 return 0; 418 418 if (!strcmp(clk->name, "siu_b_clk")) 419 419 return 1; 420 + #if defined(CONFIG_CPU_SUBTYPE_SH7722) 420 421 if (!strcmp(clk->name, "irda_clk")) 421 422 return 2; 423 + #endif 422 424 return -EINVAL; 423 425 } 424 426 425 427 static unsigned long sh7722_siu_regs[] = { 426 428 [0] = SCLKACR, 427 429 [1] = SCLKBCR, 430 + #if defined(CONFIG_CPU_SUBTYPE_SH7722) 428 431 [2] = IrDACLKCR, 432 + #endif 429 433 }; 430 434 431 435 static int sh7722_siu_start_stop(struct clk *clk, int enable) ··· 575 571 .ops = &sh7722_siu_clk_ops, 576 572 }; 577 573 574 + #if defined(CONFIG_CPU_SUBTYPE_SH7722) 578 575 static struct clk sh7722_irda_clock = { 579 576 .name = "irda_clk", 580 577 .ops = &sh7722_siu_clk_ops, 581 578 }; 579 + #endif 582 580 583 581 static struct clk sh7722_video_clock = { 584 582 .name = "video_clk", ··· 594 588 &sh7722_sdram_clock, 595 589 &sh7722_siu_a_clock, 596 590 &sh7722_siu_b_clock, 591 + #if defined(CONFIG_CPU_SUBTYPE_SH7722) 597 592 &sh7722_irda_clock, 593 + #endif 598 594 &sh7722_video_clock, 599 595 }; 600 596
+177
arch/sh/kernel/cpu/sh4a/setup-sh7366.c
··· 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 + }
+32 -37
arch/sh/kernel/cpu/sh5/probe.c
··· 20 20 { 21 21 unsigned long long cir; 22 22 23 - /* Do peeks in real mode to avoid having to set up a mapping for the 24 - WPC registers. On SH5-101 cut2, such a mapping would be exposed to 25 - an address translation erratum which would make it hard to set up 26 - correctly. */ 23 + /* 24 + * Do peeks in real mode to avoid having to set up a mapping for 25 + * the WPC registers. On SH5-101 cut2, such a mapping would be 26 + * exposed to an address translation erratum which would make it 27 + * hard to set up correctly. 28 + */ 27 29 cir = peek_real_address_q(0x0d000008); 28 - if ((cir & 0xffff) == 0x5103) { 30 + if ((cir & 0xffff) == 0x5103) 29 31 boot_cpu_data.type = CPU_SH5_103; 30 - } else if (((cir >> 32) & 0xffff) == 0x51e2) { 32 + else if (((cir >> 32) & 0xffff) == 0x51e2) 31 33 /* CPU.VCR aliased at CIR address on SH5-101 */ 32 34 boot_cpu_data.type = CPU_SH5_101; 33 - } else { 34 - boot_cpu_data.type = CPU_SH_NONE; 35 - } 36 35 37 36 /* 38 37 * First, setup some sane values for the I-cache. ··· 39 40 boot_cpu_data.icache.ways = 4; 40 41 boot_cpu_data.icache.sets = 256; 41 42 boot_cpu_data.icache.linesz = L1_CACHE_BYTES; 42 - 43 - #if 0 44 - /* 45 - * FIXME: This can probably be cleaned up a bit as well.. for example, 46 - * do we really need the way shift _and_ the way_step_shift ?? Judging 47 - * by the existing code, I would guess no.. is there any valid reason 48 - * why we need to be tracking this around? 49 - */ 50 - boot_cpu_data.icache.way_shift = 13; 43 + boot_cpu_data.icache.way_incr = (1 << 13); 51 44 boot_cpu_data.icache.entry_shift = 5; 52 - boot_cpu_data.icache.set_shift = 4; 53 - boot_cpu_data.icache.way_step_shift = 16; 54 - boot_cpu_data.icache.asid_shift = 2; 55 - 56 - /* 57 - * way offset = cache size / associativity, so just don't factor in 58 - * associativity in the first place.. 59 - */ 60 - boot_cpu_data.icache.way_ofs = boot_cpu_data.icache.sets * 61 - boot_cpu_data.icache.linesz; 62 - 63 - boot_cpu_data.icache.asid_mask = 0x3fc; 64 - boot_cpu_data.icache.idx_mask = 0x1fe0; 65 - boot_cpu_data.icache.epn_mask = 0xffffe000; 66 - #endif 67 - 45 + boot_cpu_data.icache.way_size = boot_cpu_data.icache.sets * 46 + boot_cpu_data.icache.linesz; 47 + boot_cpu_data.icache.entry_mask = 0x1fe0; 68 48 boot_cpu_data.icache.flags = 0; 69 49 70 - /* A trivial starting point.. */ 71 - memcpy(&boot_cpu_data.dcache, 72 - &boot_cpu_data.icache, sizeof(struct cache_info)); 50 + /* 51 + * Next, setup some sane values for the D-cache. 52 + * 53 + * On the SH5, these are pretty consistent with the I-cache settings, 54 + * so we just copy over the existing definitions.. these can be fixed 55 + * up later, especially if we add runtime CPU probing. 56 + * 57 + * Though in the meantime it saves us from having to duplicate all of 58 + * the above definitions.. 59 + */ 60 + boot_cpu_data.dcache = boot_cpu_data.icache; 61 + 62 + /* 63 + * Setup any cache-related flags here 64 + */ 65 + #if defined(CONFIG_CACHE_WRITETHROUGH) 66 + set_bit(SH_CACHE_MODE_WT, &(boot_cpu_data.dcache.flags)); 67 + #elif defined(CONFIG_CACHE_WRITEBACK) 68 + set_bit(SH_CACHE_MODE_WB, &(boot_cpu_data.dcache.flags)); 69 + #endif 73 70 74 71 return 0; 75 72 }
+7 -1
arch/sh/kernel/io.c
··· 63 63 64 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 74 EXPORT_SYMBOL(ioport_map); 69 75
+12 -12
arch/sh/kernel/io_generic.c
··· 33 33 34 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 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 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 49 u8 generic_inb_p(unsigned long port) ··· 81 81 volatile u8 *port_addr; 82 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 85 while (count--) 86 86 *buf++ = *port_addr; 87 87 } ··· 91 91 volatile u16 *port_addr; 92 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 95 while (count--) 96 96 *buf++ = *port_addr; 97 97 ··· 103 103 volatile u32 *port_addr; 104 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 107 while (count--) 108 108 *buf++ = *port_addr; 109 109 ··· 112 112 113 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 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 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 128 void generic_outb_p(u8 b, unsigned long port) ··· 153 153 volatile u8 *port_addr; 154 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 158 while (count--) 159 159 *port_addr = *buf++; ··· 164 164 volatile u16 *port_addr; 165 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 169 while (count--) 170 170 *port_addr = *buf++; ··· 177 177 volatile u32 *port_addr; 178 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 181 while (count--) 182 182 *port_addr = *buf++; 183 183
+276
arch/sh/kernel/io_trapped.c
··· 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 + }
-3
arch/sh/kernel/irq.c
··· 248 248 249 249 void __init init_IRQ(void) 250 250 { 251 - #ifdef CONFIG_CPU_HAS_PINT_IRQ 252 - init_IRQ_pint(); 253 - #endif 254 251 plat_irq_setup(); 255 252 256 253 /* Perform the machine specific initialisation */
+6 -3
arch/sh/kernel/process_64.c
··· 623 623 624 624 #define mid_sched ((unsigned long) interruptible_sleep_on) 625 625 626 + #ifdef CONFIG_FRAME_POINTER 626 627 static int in_sh64_switch_to(unsigned long pc) 627 628 { 628 629 extern char __sh64_switch_to_end; ··· 632 631 return (pc >= (unsigned long) sh64_switch_to) && 633 632 (pc < (unsigned long) &__sh64_switch_to_end); 634 633 } 634 + #endif 635 635 636 636 unsigned long get_wchan(struct task_struct *p) 637 637 { 638 - unsigned long schedule_fp; 639 - unsigned long sh64_switch_to_fp; 640 - unsigned long schedule_caller_pc; 641 638 unsigned long pc; 642 639 643 640 if (!p || p == current || p->state == TASK_RUNNING) ··· 648 649 649 650 #ifdef CONFIG_FRAME_POINTER 650 651 if (in_sh64_switch_to(pc)) { 652 + unsigned long schedule_fp; 653 + unsigned long sh64_switch_to_fp; 654 + unsigned long schedule_caller_pc; 655 + 651 656 sh64_switch_to_fp = (long) p->thread.sp; 652 657 /* r14 is saved at offset 4 in the sh64_switch_to frame */ 653 658 schedule_fp = *(unsigned long *) (long)(sh64_switch_to_fp + 4);
+2 -2
arch/sh/kernel/ptrace_32.c
··· 220 220 dp = ((unsigned long) child) + THREAD_SIZE - 221 221 sizeof(struct pt_dspregs); 222 222 if (*((int *) (dp - 4)) == SR_FD) { 223 - copy_to_user(addr, (void *) dp, 223 + copy_to_user((void *)addr, (void *) dp, 224 224 sizeof(struct pt_dspregs)); 225 225 ret = 0; 226 226 } ··· 234 234 dp = ((unsigned long) child) + THREAD_SIZE - 235 235 sizeof(struct pt_dspregs); 236 236 if (*((int *) (dp - 4)) == SR_FD) { 237 - copy_from_user((void *) dp, addr, 237 + copy_from_user((void *) dp, (void *)addr, 238 238 sizeof(struct pt_dspregs)); 239 239 ret = 0; 240 240 }
+1 -1
arch/sh/kernel/setup.c
··· 333 333 [CPU_SH7343] = "SH7343", [CPU_SH7785] = "SH7785", 334 334 [CPU_SH7722] = "SH7722", [CPU_SHX3] = "SH-X3", 335 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 339 const char *get_cpu_subtype(struct sh_cpuinfo *c)
+3 -1
arch/sh/kernel/syscalls_32.S
··· 338 338 .long sys_epoll_pwait 339 339 .long sys_utimensat /* 320 */ 340 340 .long sys_signalfd 341 - .long sys_ni_syscall 341 + .long sys_timerfd_create 342 342 .long sys_eventfd 343 343 .long sys_fallocate 344 + .long sys_timerfd_settime /* 325 */ 345 + .long sys_timerfd_gettime
+3 -1
arch/sh/kernel/syscalls_64.S
··· 376 376 .long sys_epoll_pwait 377 377 .long sys_utimensat 378 378 .long sys_signalfd 379 - .long sys_ni_syscall /* 350 */ 379 + .long sys_timerfd_create /* 350 */ 380 380 .long sys_eventfd 381 381 .long sys_fallocate 382 + .long sys_timerfd_settime 383 + .long sys_timerfd_gettime
+15 -4
arch/sh/kernel/time_32.c
··· 120 120 */ 121 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 123 if (current->pid) 128 124 profile_tick(CPU_PROFILING); 129 125 ··· 127 131 if (sh_mv.mv_heartbeat != NULL) 128 132 sh_mv.mv_heartbeat(); 129 133 #endif 134 + 135 + /* 136 + * Here we are in the timer irq handler. We just have irqs locally 137 + * disabled but we don't know if the timer_bh is running on the other 138 + * CPU. We need to avoid to SMP race with it. NOTE: we don' t need 139 + * the irq version of write_lock because as just said we have irq 140 + * locally disabled. -arca 141 + */ 142 + write_seqlock(&xtime_lock); 143 + do_timer(1); 130 144 131 145 /* 132 146 * If we have an externally synchronized Linux clock, then update ··· 153 147 /* do it again in 60s */ 154 148 last_rtc_update = xtime.tv_sec - 600; 155 149 } 150 + write_sequnlock(&xtime_lock); 151 + 152 + #ifndef CONFIG_SMP 153 + update_process_times(user_mode(get_irq_regs())); 154 + #endif 156 155 } 157 156 #endif /* !CONFIG_GENERIC_CLOCKEVENTS */ 158 157
+17 -14
arch/sh/kernel/time_64.c
··· 229 229 static inline void do_timer_interrupt(void) 230 230 { 231 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 244 asm ("getcon cr62, %0" : "=r" (current_ctc)); 233 245 ctc_last_interrupt = (unsigned long) current_ctc; 234 246 235 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 249 #ifdef CONFIG_HEARTBEAT 243 250 if (sh_mv.mv_heartbeat != NULL) ··· 266 259 /* do it again in 60 s */ 267 260 last_rtc_update = xtime.tv_sec - 600; 268 261 } 262 + write_unlock(&xtime_lock); 263 + 264 + #ifndef CONFIG_SMP 265 + update_process_times(user_mode(get_irq_regs())); 266 + #endif 269 267 } 270 268 271 269 /* ··· 287 275 timer_status &= ~0x100; 288 276 ctrl_outw(timer_status, TMU0_TCR); 289 277 290 - /* 291 - * Here we are in the timer irq handler. We just have irqs locally 292 - * disabled but we don't know if the timer_bh is running on the other 293 - * CPU. We need to avoid to SMP race with it. NOTE: we don' t need 294 - * the irq version of write_lock because as just said we have irq 295 - * locally disabled. -arca 296 - */ 297 - write_lock(&xtime_lock); 298 278 do_timer_interrupt(); 299 - write_unlock(&xtime_lock); 300 279 301 280 return IRQ_HANDLED; 302 281 }
-1
arch/sh/kernel/timers/timer-mtu2.c
··· 154 154 155 155 static int mtu2_timer_init(void) 156 156 { 157 - u8 tmp; 158 157 unsigned long interval; 159 158 160 159 setup_irq(CONFIG_SH_TIMER_IRQ, &mtu2_irq);
+76 -88
arch/sh/kernel/traps_32.c
··· 147 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 181 * handle an instruction that does an unaligned memory access by emulating the 152 182 * desired behaviour ··· 184 154 * (if that instruction is in a branch delay slot) 185 155 * - return 0 if emulation okay, -EFAULT on existential error 186 156 */ 187 - static int handle_unaligned_ins(u16 instruction, struct pt_regs *regs) 157 + static int handle_unaligned_ins(opcode_t instruction, struct pt_regs *regs, 158 + struct mem_access *ma) 188 159 { 189 160 int ret, index, count; 190 161 unsigned long *rm, *rn; ··· 209 178 dst = (unsigned char*) rn; 210 179 *(unsigned long*)dst = 0; 211 180 212 - #ifdef __LITTLE_ENDIAN__ 213 - if (copy_from_user(dst, src, count)) 214 - goto fetch_fault; 215 - 216 - if ((count == 2) && dst[1] & 0x80) { 217 - dst[2] = 0xff; 218 - dst[3] = 0xff; 219 - } 220 - #else 181 + #if !defined(__LITTLE_ENDIAN__) 221 182 dst += 4-count; 222 - 223 - if (__copy_user(dst, src, count)) 183 + #endif 184 + if (ma->from(dst, src, count)) 224 185 goto fetch_fault; 225 186 226 - if ((count == 2) && dst[2] & 0x80) { 227 - dst[0] = 0xff; 228 - dst[1] = 0xff; 229 - } 230 - #endif 187 + sign_extend(count, dst); 231 188 } else { 232 189 /* to memory */ 233 190 src = (unsigned char*) rm; ··· 225 206 dst = (unsigned char*) *rn; 226 207 dst += regs->regs[0]; 227 208 228 - if (copy_to_user(dst, src, count)) 209 + if (ma->to(dst, src, count)) 229 210 goto fetch_fault; 230 211 } 231 212 ret = 0; ··· 236 217 dst = (unsigned char*) *rn; 237 218 dst += (instruction&0x000F)<<2; 238 219 239 - if (copy_to_user(dst,src,4)) 220 + if (ma->to(dst, src, 4)) 240 221 goto fetch_fault; 241 222 ret = 0; 242 223 break; ··· 249 230 #if !defined(__LITTLE_ENDIAN__) 250 231 src += 4-count; 251 232 #endif 252 - if (copy_to_user(dst, src, count)) 233 + if (ma->to(dst, src, count)) 253 234 goto fetch_fault; 254 235 ret = 0; 255 236 break; ··· 260 241 dst = (unsigned char*) rn; 261 242 *(unsigned long*)dst = 0; 262 243 263 - if (copy_from_user(dst,src,4)) 244 + if (ma->from(dst, src, 4)) 264 245 goto fetch_fault; 265 246 ret = 0; 266 247 break; ··· 272 253 dst = (unsigned char*) rn; 273 254 *(unsigned long*)dst = 0; 274 255 275 - #ifdef __LITTLE_ENDIAN__ 276 - if (copy_from_user(dst, src, count)) 277 - goto fetch_fault; 278 - 279 - if ((count == 2) && dst[1] & 0x80) { 280 - dst[2] = 0xff; 281 - dst[3] = 0xff; 282 - } 283 - #else 256 + #if !defined(__LITTLE_ENDIAN__) 284 257 dst += 4-count; 285 - 286 - if (copy_from_user(dst, src, count)) 287 - goto fetch_fault; 288 - 289 - if ((count == 2) && dst[2] & 0x80) { 290 - dst[0] = 0xff; 291 - dst[1] = 0xff; 292 - } 293 258 #endif 259 + if (ma->from(dst, src, count)) 260 + goto fetch_fault; 261 + sign_extend(count, dst); 294 262 ret = 0; 295 263 break; 296 264 ··· 291 285 dst = (unsigned char*) *rm; /* called Rn in the spec */ 292 286 dst += (instruction&0x000F)<<1; 293 287 294 - if (copy_to_user(dst, src, 2)) 288 + if (ma->to(dst, src, 2)) 295 289 goto fetch_fault; 296 290 ret = 0; 297 291 break; ··· 305 299 #if !defined(__LITTLE_ENDIAN__) 306 300 dst += 2; 307 301 #endif 308 - 309 - if (copy_from_user(dst, src, 2)) 302 + if (ma->from(dst, src, 2)) 310 303 goto fetch_fault; 311 - 312 - #ifdef __LITTLE_ENDIAN__ 313 - if (dst[1] & 0x80) { 314 - dst[2] = 0xff; 315 - dst[3] = 0xff; 316 - } 317 - #else 318 - if (dst[2] & 0x80) { 319 - dst[0] = 0xff; 320 - dst[1] = 0xff; 321 - } 322 - #endif 304 + sign_extend(2, dst); 323 305 ret = 0; 324 306 break; 325 307 } ··· 326 332 * emulate the instruction in the delay slot 327 333 * - fetches the instruction from PC+2 328 334 */ 329 - static inline int handle_unaligned_delayslot(struct pt_regs *regs) 335 + static inline int handle_delayslot(struct pt_regs *regs, 336 + opcode_t old_instruction, 337 + struct mem_access *ma) 330 338 { 331 - u16 instruction; 339 + opcode_t instruction; 340 + void *addr = (void *)(regs->pc + instruction_size(old_instruction)); 332 341 333 - if (copy_from_user(&instruction, (u16 *)(regs->pc+2), 2)) { 342 + if (copy_from_user(&instruction, addr, sizeof(instruction))) { 334 343 /* the instruction-fetch faulted */ 335 344 if (user_mode(regs)) 336 345 return -EFAULT; ··· 343 346 regs, 0); 344 347 } 345 348 346 - return handle_unaligned_ins(instruction,regs); 349 + return handle_unaligned_ins(instruction, regs, ma); 347 350 } 348 351 349 352 /* ··· 366 369 * XXX: SH-2A needs this too, but it needs an overhaul thanks to mixed 32-bit 367 370 * opcodes.. 368 371 */ 369 - #ifndef CONFIG_CPU_SH2A 372 + 370 373 static int handle_unaligned_notify_count = 10; 371 374 372 - static int handle_unaligned_access(u16 instruction, struct pt_regs *regs) 375 + int handle_unaligned_access(opcode_t instruction, struct pt_regs *regs, 376 + struct mem_access *ma) 373 377 { 374 378 u_int rm; 375 379 int ret, index; ··· 385 387 printk(KERN_NOTICE "Fixing up unaligned userspace access " 386 388 "in \"%s\" pid=%d pc=0x%p ins=0x%04hx\n", 387 389 current->comm, task_pid_nr(current), 388 - (u16 *)regs->pc, instruction); 390 + (void *)regs->pc, instruction); 389 391 } 390 392 391 393 ret = -EFAULT; ··· 393 395 case 0x0000: 394 396 if (instruction==0x000B) { 395 397 /* rts */ 396 - ret = handle_unaligned_delayslot(regs); 398 + ret = handle_delayslot(regs, instruction, ma); 397 399 if (ret==0) 398 400 regs->pc = regs->pr; 399 401 } 400 402 else if ((instruction&0x00FF)==0x0023) { 401 403 /* braf @Rm */ 402 - ret = handle_unaligned_delayslot(regs); 404 + ret = handle_delayslot(regs, instruction, ma); 403 405 if (ret==0) 404 406 regs->pc += rm + 4; 405 407 } 406 408 else if ((instruction&0x00FF)==0x0003) { 407 409 /* bsrf @Rm */ 408 - ret = handle_unaligned_delayslot(regs); 410 + ret = handle_delayslot(regs, instruction, ma); 409 411 if (ret==0) { 410 412 regs->pr = regs->pc + 4; 411 413 regs->pc += rm + 4; ··· 426 428 case 0x4000: 427 429 if ((instruction&0x00FF)==0x002B) { 428 430 /* jmp @Rm */ 429 - ret = handle_unaligned_delayslot(regs); 431 + ret = handle_delayslot(regs, instruction, ma); 430 432 if (ret==0) 431 433 regs->pc = rm; 432 434 } 433 435 else if ((instruction&0x00FF)==0x000B) { 434 436 /* jsr @Rm */ 435 - ret = handle_unaligned_delayslot(regs); 437 + ret = handle_delayslot(regs, instruction, ma); 436 438 if (ret==0) { 437 439 regs->pr = regs->pc + 4; 438 440 regs->pc = rm; ··· 459 461 case 0x0B00: /* bf lab - no delayslot*/ 460 462 break; 461 463 case 0x0F00: /* bf/s lab */ 462 - ret = handle_unaligned_delayslot(regs); 464 + ret = handle_delayslot(regs, instruction, ma); 463 465 if (ret==0) { 464 466 #if defined(CONFIG_CPU_SH4) || defined(CONFIG_SH7705_CACHE_32KB) 465 467 if ((regs->sr & 0x00000001) != 0) ··· 472 474 case 0x0900: /* bt lab - no delayslot */ 473 475 break; 474 476 case 0x0D00: /* bt/s lab */ 475 - ret = handle_unaligned_delayslot(regs); 477 + ret = handle_delayslot(regs, instruction, ma); 476 478 if (ret==0) { 477 479 #if defined(CONFIG_CPU_SH4) || defined(CONFIG_SH7705_CACHE_32KB) 478 480 if ((regs->sr & 0x00000001) == 0) ··· 486 488 break; 487 489 488 490 case 0xA000: /* bra label */ 489 - ret = handle_unaligned_delayslot(regs); 491 + ret = handle_delayslot(regs, instruction, ma); 490 492 if (ret==0) 491 493 regs->pc += SH_PC_12BIT_OFFSET(instruction); 492 494 break; 493 495 494 496 case 0xB000: /* bsr label */ 495 - ret = handle_unaligned_delayslot(regs); 497 + ret = handle_delayslot(regs, instruction, ma); 496 498 if (ret==0) { 497 499 regs->pr = regs->pc + 4; 498 500 regs->pc += SH_PC_12BIT_OFFSET(instruction); ··· 503 505 504 506 /* handle non-delay-slot instruction */ 505 507 simple: 506 - ret = handle_unaligned_ins(instruction,regs); 508 + ret = handle_unaligned_ins(instruction, regs, ma); 507 509 if (ret==0) 508 510 regs->pc += instruction_size(instruction); 509 511 return ret; 510 512 } 511 - #endif /* CONFIG_CPU_SH2A */ 512 513 513 514 #ifdef CONFIG_CPU_HAS_SR_RB 514 515 #define lookup_exception_vector(x) \ ··· 535 538 unsigned long error_code = 0; 536 539 mm_segment_t oldfs; 537 540 siginfo_t info; 538 - #ifndef CONFIG_CPU_SH2A 539 - u16 instruction; 541 + opcode_t instruction; 540 542 int tmp; 541 - #endif 542 543 543 544 /* Intentional ifdef */ 544 545 #ifdef CONFIG_CPU_HAS_SR_RB ··· 556 561 goto uspace_segv; 557 562 } 558 563 559 - #ifndef CONFIG_CPU_SH2A 560 564 set_fs(USER_DS); 561 - if (copy_from_user(&instruction, (u16 *)(regs->pc), 2)) { 565 + if (copy_from_user(&instruction, (void *)(regs->pc), 566 + sizeof(instruction))) { 562 567 /* Argh. Fault on the instruction itself. 563 568 This should never happen non-SMP 564 569 */ ··· 566 571 goto uspace_segv; 567 572 } 568 573 569 - tmp = handle_unaligned_access(instruction, regs); 574 + tmp = handle_unaligned_access(instruction, regs, 575 + &user_mem_access); 570 576 set_fs(oldfs); 571 577 572 578 if (tmp==0) 573 579 return; /* sorted */ 574 - #endif 575 - 576 580 uspace_segv: 577 581 printk(KERN_NOTICE "Sending SIGBUS to \"%s\" due to unaligned " 578 582 "access (PC %lx PR %lx)\n", current->comm, regs->pc, ··· 586 592 if (regs->pc & 1) 587 593 die("unaligned program counter", regs, error_code); 588 594 589 - #ifndef CONFIG_CPU_SH2A 590 595 set_fs(KERNEL_DS); 591 - if (copy_from_user(&instruction, (u16 *)(regs->pc), 2)) { 596 + if (copy_from_user(&instruction, (void *)(regs->pc), 597 + sizeof(instruction))) { 592 598 /* Argh. Fault on the instruction itself. 593 599 This should never happen non-SMP 594 600 */ ··· 596 602 die("insn faulting in do_address_error", regs, 0); 597 603 } 598 604 599 - handle_unaligned_access(instruction, regs); 605 + handle_unaligned_access(instruction, regs, &user_mem_access); 600 606 set_fs(oldfs); 601 - #else 602 - printk(KERN_NOTICE "Killing process \"%s\" due to unaligned " 603 - "access\n", current->comm); 604 - 605 - force_sig(SIGSEGV, current); 606 - #endif 607 607 } 608 608 } 609 609
+2 -2
arch/sh/kernel/traps_64.c
··· 630 630 current->thread.fpu.hard.fp_regs[destreg] = buflo; 631 631 current->thread.fpu.hard.fp_regs[destreg+1] = bufhi; 632 632 } else { 633 - #if defined(CONFIG_LITTLE_ENDIAN) 633 + #if defined(CONFIG_CPU_LITTLE_ENDIAN) 634 634 current->thread.fpu.hard.fp_regs[destreg] = bufhi; 635 635 current->thread.fpu.hard.fp_regs[destreg+1] = buflo; 636 636 #else ··· 700 700 buflo = current->thread.fpu.hard.fp_regs[srcreg]; 701 701 bufhi = current->thread.fpu.hard.fp_regs[srcreg+1]; 702 702 } else { 703 - #if defined(CONFIG_LITTLE_ENDIAN) 703 + #if defined(CONFIG_CPU_LITTLE_ENDIAN) 704 704 bufhi = current->thread.fpu.hard.fp_regs[srcreg]; 705 705 buflo = current->thread.fpu.hard.fp_regs[srcreg+1]; 706 706 #else
+1 -1
arch/sh/kernel/vmlinux_64.lds.S
··· 51 51 KPROBES_TEXT 52 52 *(.fixup) 53 53 *(.gnu.warning) 54 - #ifdef CONFIG_LITTLE_ENDIAN 54 + #ifdef CONFIG_CPU_LITTLE_ENDIAN 55 55 } = 0x6ff0fff0 56 56 #else 57 57 } = 0xf0fff06f
+432 -629
arch/sh/mm/cache-sh5.c
··· 1 1 /* 2 2 * arch/sh/mm/cache-sh5.c 3 3 * 4 - * Original version Copyright (C) 2000, 2001 Paolo Alberelli 5 - * Second version Copyright (C) benedict.gaster@superh.com 2002 6 - * Third version Copyright Richard.Curnow@superh.com 2003 7 - * Hacks to third version Copyright (C) 2003 Paul Mundt 4 + * Copyright (C) 2000, 2001 Paolo Alberelli 5 + * Copyright (C) 2002 Benedict Gaster 6 + * Copyright (C) 2003 Richard Curnow 7 + * Copyright (C) 2003 - 2008 Paul Mundt 8 8 * 9 9 * This file is subject to the terms and conditions of the GNU General Public 10 10 * License. See the file "COPYING" in the main directory of this archive ··· 13 13 #include <linux/init.h> 14 14 #include <linux/mman.h> 15 15 #include <linux/mm.h> 16 - #include <linux/threads.h> 17 - #include <asm/page.h> 18 - #include <asm/pgtable.h> 16 + #include <asm/tlb.h> 19 17 #include <asm/processor.h> 20 18 #include <asm/cache.h> 21 - #include <asm/tlb.h> 22 - #include <asm/io.h> 19 + #include <asm/pgalloc.h> 23 20 #include <asm/uaccess.h> 24 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 23 /* Wired TLB entry for the D-cache */ 33 24 static unsigned long long dtlb_cache_slot; 34 25 35 - /** 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) 26 + void __init p3_cache_init(void) 51 27 { 52 - /* 53 - * First, setup some sane values for the I-cache. 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; 28 + /* Reserve a slot for dcache colouring in the DTLB */ 29 + dtlb_cache_slot = sh64_get_wired_dtlb_entry(); 111 30 } 112 31 113 32 #ifdef CONFIG_DCACHE_DISABLED ··· 35 116 #define sh64_dcache_purge_user_range(mm, start, end) do { } while (0) 36 117 #define sh64_dcache_purge_phy_page(paddr) do { } while (0) 37 118 #define sh64_dcache_purge_virt_page(mm, eaddr) do { } while (0) 38 - #define sh64_dcache_purge_kernel_range(start, end) do { } while (0) 39 - #define sh64_dcache_wback_current_user_range(start, end) do { } while (0) 40 119 #endif 41 120 42 - /*##########################################################################*/ 43 - 44 - /* From here onwards, a rewrite of the implementation, 45 - by Richard.Curnow@superh.com. 46 - 47 - The major changes in this compared to the old version are; 48 - 1. use more selective purging through OCBP instead of using ALLOCO to purge 49 - by natural replacement. This avoids purging out unrelated cache lines 50 - that happen to be in the same set. 51 - 2. exploit the APIs copy_user_page and clear_user_page better 52 - 3. be more selective about I-cache purging, in particular use invalidate_all 53 - more sparingly. 54 - 55 - */ 56 - 57 - /*########################################################################## 58 - SUPPORT FUNCTIONS 59 - ##########################################################################*/ 60 - 61 - /****************************************************************************/ 62 - /* The following group of functions deal with mapping and unmapping a temporary 63 - page into the DTLB slot that have been set aside for our exclusive use. */ 64 - /* In order to accomplish this, we use the generic interface for adding and 65 - removing a wired slot entry as defined in arch/sh/mm/tlb-sh5.c */ 66 - /****************************************************************************/ 67 - 68 - static unsigned long slot_own_flags; 69 - 70 - static inline void sh64_setup_dtlb_cache_slot(unsigned long eaddr, unsigned long asid, unsigned long paddr) 121 + /* 122 + * The following group of functions deal with mapping and unmapping a 123 + * temporary page into a DTLB slot that has been set aside for exclusive 124 + * use. 125 + */ 126 + static inline void 127 + sh64_setup_dtlb_cache_slot(unsigned long eaddr, unsigned long asid, 128 + unsigned long paddr) 71 129 { 72 - local_irq_save(slot_own_flags); 130 + local_irq_disable(); 73 131 sh64_setup_tlb_slot(dtlb_cache_slot, eaddr, asid, paddr); 74 132 } 75 133 76 134 static inline void sh64_teardown_dtlb_cache_slot(void) 77 135 { 78 136 sh64_teardown_tlb_slot(dtlb_cache_slot); 79 - local_irq_restore(slot_own_flags); 137 + local_irq_enable(); 80 138 } 81 139 82 - /****************************************************************************/ 83 - 84 140 #ifndef CONFIG_ICACHE_DISABLED 85 - 86 - static void __inline__ sh64_icache_inv_all(void) 141 + static inline void sh64_icache_inv_all(void) 87 142 { 88 143 unsigned long long addr, flag, data; 89 144 unsigned int flags; 90 145 91 - addr=ICCR0; 92 - flag=ICCR0_ICI; 93 - data=0; 146 + addr = ICCR0; 147 + flag = ICCR0_ICI; 148 + data = 0; 94 149 95 150 /* Make this a critical section for safety (probably not strictly necessary.) */ 96 151 local_irq_save(flags); 97 152 98 153 /* Without %1 it gets unexplicably wrong */ 99 - asm volatile("getcfg %3, 0, %0\n\t" 100 - "or %0, %2, %0\n\t" 101 - "putcfg %3, 0, %0\n\t" 102 - "synci" 103 - : "=&r" (data) 104 - : "0" (data), "r" (flag), "r" (addr)); 154 + __asm__ __volatile__ ( 155 + "getcfg %3, 0, %0\n\t" 156 + "or %0, %2, %0\n\t" 157 + "putcfg %3, 0, %0\n\t" 158 + "synci" 159 + : "=&r" (data) 160 + : "0" (data), "r" (flag), "r" (addr)); 105 161 106 162 local_irq_restore(flags); 107 163 } ··· 87 193 * the addresses lie in the kernel superpage. */ 88 194 89 195 unsigned long long ullend, addr, aligned_start; 90 - #if (NEFF == 32) 91 196 aligned_start = (unsigned long long)(signed long long)(signed long) start; 92 - #else 93 - #error "NEFF != 32" 94 - #endif 95 - aligned_start &= L1_CACHE_ALIGN_MASK; 96 - addr = aligned_start; 97 - #if (NEFF == 32) 197 + addr = L1_CACHE_ALIGN(aligned_start); 98 198 ullend = (unsigned long long) (signed long long) (signed long) end; 99 - #else 100 - #error "NEFF != 32" 101 - #endif 199 + 102 200 while (addr <= ullend) { 103 - asm __volatile__ ("icbi %0, 0" : : "r" (addr)); 201 + __asm__ __volatile__ ("icbi %0, 0" : : "r" (addr)); 104 202 addr += L1_CACHE_BYTES; 105 203 } 106 204 } ··· 101 215 { 102 216 /* If we get called, we know that vma->vm_flags contains VM_EXEC. 103 217 Also, eaddr is page-aligned. */ 104 - 218 + unsigned int cpu = smp_processor_id(); 105 219 unsigned long long addr, end_addr; 106 220 unsigned long flags = 0; 107 221 unsigned long running_asid, vma_asid; ··· 123 237 */ 124 238 125 239 running_asid = get_asid(); 126 - vma_asid = (vma->vm_mm->context & MMU_CONTEXT_ASID_MASK); 240 + vma_asid = cpu_asid(cpu, vma->vm_mm); 127 241 if (running_asid != vma_asid) { 128 242 local_irq_save(flags); 129 243 switch_and_save_asid(vma_asid); 130 244 } 131 245 while (addr < end_addr) { 132 246 /* Worth unrolling a little */ 133 - asm __volatile__("icbi %0, 0" : : "r" (addr)); 134 - asm __volatile__("icbi %0, 32" : : "r" (addr)); 135 - asm __volatile__("icbi %0, 64" : : "r" (addr)); 136 - asm __volatile__("icbi %0, 96" : : "r" (addr)); 247 + __asm__ __volatile__("icbi %0, 0" : : "r" (addr)); 248 + __asm__ __volatile__("icbi %0, 32" : : "r" (addr)); 249 + __asm__ __volatile__("icbi %0, 64" : : "r" (addr)); 250 + __asm__ __volatile__("icbi %0, 96" : : "r" (addr)); 137 251 addr += 128; 138 252 } 139 253 if (running_asid != vma_asid) { ··· 141 255 local_irq_restore(flags); 142 256 } 143 257 } 144 - 145 - /****************************************************************************/ 146 258 147 259 static void sh64_icache_inv_user_page_range(struct mm_struct *mm, 148 260 unsigned long start, unsigned long end) ··· 159 275 possible with the D-cache. Just assume 64 for now as a working 160 276 figure. 161 277 */ 162 - 163 278 int n_pages; 164 279 165 - if (!mm) return; 280 + if (!mm) 281 + return; 166 282 167 283 n_pages = ((end - start) >> PAGE_SHIFT); 168 284 if (n_pages >= 64) { ··· 174 290 unsigned long mm_asid, current_asid; 175 291 unsigned long long flags = 0ULL; 176 292 177 - mm_asid = mm->context & MMU_CONTEXT_ASID_MASK; 293 + mm_asid = cpu_asid(smp_processor_id(), mm); 178 294 current_asid = get_asid(); 179 295 180 296 if (mm_asid != current_asid) { ··· 206 322 } 207 323 aligned_start = vma->vm_end; /* Skip to start of next region */ 208 324 } 325 + 209 326 if (mm_asid != current_asid) { 210 327 switch_and_save_asid(current_asid); 211 328 local_irq_restore(flags); ··· 214 329 } 215 330 } 216 331 332 + /* 333 + * Invalidate a small range of user context I-cache, not necessarily page 334 + * (or even cache-line) aligned. 335 + * 336 + * Since this is used inside ptrace, the ASID in the mm context typically 337 + * won't match current_asid. We'll have to switch ASID to do this. For 338 + * safety, and given that the range will be small, do all this under cli. 339 + * 340 + * Note, there is a hazard that the ASID in mm->context is no longer 341 + * actually associated with mm, i.e. if the mm->context has started a new 342 + * cycle since mm was last active. However, this is just a performance 343 + * issue: all that happens is that we invalidate lines belonging to 344 + * another mm, so the owning process has to refill them when that mm goes 345 + * live again. mm itself can't have any cache entries because there will 346 + * have been a flush_cache_all when the new mm->context cycle started. 347 + */ 217 348 static void sh64_icache_inv_user_small_range(struct mm_struct *mm, 218 349 unsigned long start, int len) 219 350 { 220 - 221 - /* Invalidate a small range of user context I-cache, not necessarily 222 - page (or even cache-line) aligned. */ 223 - 224 351 unsigned long long eaddr = start; 225 352 unsigned long long eaddr_end = start + len; 226 353 unsigned long current_asid, mm_asid; 227 354 unsigned long long flags; 228 355 unsigned long long epage_start; 229 356 230 - /* Since this is used inside ptrace, the ASID in the mm context 231 - typically won't match current_asid. We'll have to switch ASID to do 232 - this. For safety, and given that the range will be small, do all 233 - this under cli. 234 - 235 - Note, there is a hazard that the ASID in mm->context is no longer 236 - actually associated with mm, i.e. if the mm->context has started a 237 - new cycle since mm was last active. However, this is just a 238 - performance issue: all that happens is that we invalidate lines 239 - belonging to another mm, so the owning process has to refill them 240 - when that mm goes live again. mm itself can't have any cache 241 - entries because there will have been a flush_cache_all when the new 242 - mm->context cycle started. */ 243 - 244 - /* Align to start of cache line. Otherwise, suppose len==8 and start 245 - was at 32N+28 : the last 4 bytes wouldn't get invalidated. */ 246 - eaddr = start & L1_CACHE_ALIGN_MASK; 357 + /* 358 + * Align to start of cache line. Otherwise, suppose len==8 and 359 + * start was at 32N+28 : the last 4 bytes wouldn't get invalidated. 360 + */ 361 + eaddr = L1_CACHE_ALIGN(start); 247 362 eaddr_end = start + len; 248 363 364 + mm_asid = cpu_asid(smp_processor_id(), mm); 249 365 local_irq_save(flags); 250 - mm_asid = mm->context & MMU_CONTEXT_ASID_MASK; 251 366 current_asid = switch_and_save_asid(mm_asid); 252 367 253 368 epage_start = eaddr & PAGE_MASK; 254 369 255 - while (eaddr < eaddr_end) 256 - { 257 - asm __volatile__("icbi %0, 0" : : "r" (eaddr)); 370 + while (eaddr < eaddr_end) { 371 + __asm__ __volatile__("icbi %0, 0" : : "r" (eaddr)); 258 372 eaddr += L1_CACHE_BYTES; 259 373 } 260 374 switch_and_save_asid(current_asid); ··· 278 394 been recycled since we were last active in which case we might just 279 395 invalidate another processes I-cache entries : no worries, just a 280 396 performance drop for him. */ 281 - aligned_start = start & L1_CACHE_ALIGN_MASK; 397 + aligned_start = L1_CACHE_ALIGN(start); 282 398 addr = aligned_start; 283 399 while (addr < ull_end) { 284 - asm __volatile__ ("icbi %0, 0" : : "r" (addr)); 285 - asm __volatile__ ("nop"); 286 - asm __volatile__ ("nop"); 400 + __asm__ __volatile__ ("icbi %0, 0" : : "r" (addr)); 401 + __asm__ __volatile__ ("nop"); 402 + __asm__ __volatile__ ("nop"); 287 403 addr += L1_CACHE_BYTES; 288 404 } 289 405 } 290 - 291 406 #endif /* !CONFIG_ICACHE_DISABLED */ 292 407 293 - /****************************************************************************/ 294 - 295 408 #ifndef CONFIG_DCACHE_DISABLED 296 - 297 409 /* Buffer used as the target of alloco instructions to purge data from cache 298 410 sets by natural eviction. -- RPC */ 299 - #define DUMMY_ALLOCO_AREA_SIZE L1_CACHE_SIZE_BYTES + (1024 * 4) 411 + #define DUMMY_ALLOCO_AREA_SIZE ((L1_CACHE_BYTES << 10) + (1024 * 4)) 300 412 static unsigned char dummy_alloco_area[DUMMY_ALLOCO_AREA_SIZE] __cacheline_aligned = { 0, }; 301 413 302 - /****************************************************************************/ 303 - 304 - static void __inline__ sh64_dcache_purge_sets(int sets_to_purge_base, int n_sets) 414 + static void inline sh64_dcache_purge_sets(int sets_to_purge_base, int n_sets) 305 415 { 306 416 /* Purge all ways in a particular block of sets, specified by the base 307 417 set number and number of sets. Can handle wrap-around, if that's ··· 306 428 int j; 307 429 int set_offset; 308 430 309 - dummy_buffer_base_set = ((int)&dummy_alloco_area & cpu_data->dcache.idx_mask) >> cpu_data->dcache.entry_shift; 431 + dummy_buffer_base_set = ((int)&dummy_alloco_area & 432 + cpu_data->dcache.entry_mask) >> 433 + cpu_data->dcache.entry_shift; 310 434 set_offset = sets_to_purge_base - dummy_buffer_base_set; 311 435 312 - for (j=0; j<n_sets; j++, set_offset++) { 436 + for (j = 0; j < n_sets; j++, set_offset++) { 313 437 set_offset &= (cpu_data->dcache.sets - 1); 314 - eaddr0 = (unsigned long long)dummy_alloco_area + (set_offset << cpu_data->dcache.entry_shift); 438 + eaddr0 = (unsigned long long)dummy_alloco_area + 439 + (set_offset << cpu_data->dcache.entry_shift); 315 440 316 - /* Do one alloco which hits the required set per cache way. For 317 - write-back mode, this will purge the #ways resident lines. There's 318 - little point unrolling this loop because the allocos stall more if 319 - they're too close together. */ 320 - eaddr1 = eaddr0 + cpu_data->dcache.way_ofs * cpu_data->dcache.ways; 321 - for (eaddr=eaddr0; eaddr<eaddr1; eaddr+=cpu_data->dcache.way_ofs) { 322 - asm __volatile__ ("alloco %0, 0" : : "r" (eaddr)); 323 - asm __volatile__ ("synco"); /* TAKum03020 */ 441 + /* 442 + * Do one alloco which hits the required set per cache 443 + * way. For write-back mode, this will purge the #ways 444 + * resident lines. There's little point unrolling this 445 + * loop because the allocos stall more if they're too 446 + * close together. 447 + */ 448 + eaddr1 = eaddr0 + cpu_data->dcache.way_size * 449 + cpu_data->dcache.ways; 450 + 451 + for (eaddr = eaddr0; eaddr < eaddr1; 452 + eaddr += cpu_data->dcache.way_size) { 453 + __asm__ __volatile__ ("alloco %0, 0" : : "r" (eaddr)); 454 + __asm__ __volatile__ ("synco"); /* TAKum03020 */ 324 455 } 325 456 326 - eaddr1 = eaddr0 + cpu_data->dcache.way_ofs * cpu_data->dcache.ways; 327 - for (eaddr=eaddr0; eaddr<eaddr1; eaddr+=cpu_data->dcache.way_ofs) { 328 - /* Load from each address. Required because alloco is a NOP if 329 - the cache is write-through. Write-through is a config option. */ 457 + eaddr1 = eaddr0 + cpu_data->dcache.way_size * 458 + cpu_data->dcache.ways; 459 + 460 + for (eaddr = eaddr0; eaddr < eaddr1; 461 + eaddr += cpu_data->dcache.way_size) { 462 + /* 463 + * Load from each address. Required because 464 + * alloco is a NOP if the cache is write-through. 465 + */ 330 466 if (test_bit(SH_CACHE_MODE_WT, &(cpu_data->dcache.flags))) 331 - *(volatile unsigned char *)(int)eaddr; 467 + ctrl_inb(eaddr); 332 468 } 333 469 } 334 470 335 - /* Don't use OCBI to invalidate the lines. That costs cycles directly. 336 - If the dummy block is just left resident, it will naturally get 337 - evicted as required. */ 338 - 339 - return; 471 + /* 472 + * Don't use OCBI to invalidate the lines. That costs cycles 473 + * directly. If the dummy block is just left resident, it will 474 + * naturally get evicted as required. 475 + */ 340 476 } 341 477 342 - /****************************************************************************/ 343 - 478 + /* 479 + * Purge the entire contents of the dcache. The most efficient way to 480 + * achieve this is to use alloco instructions on a region of unused 481 + * memory equal in size to the cache, thereby causing the current 482 + * contents to be discarded by natural eviction. The alternative, namely 483 + * reading every tag, setting up a mapping for the corresponding page and 484 + * doing an OCBP for the line, would be much more expensive. 485 + */ 344 486 static void sh64_dcache_purge_all(void) 345 487 { 346 - /* Purge the entire contents of the dcache. The most efficient way to 347 - achieve this is to use alloco instructions on a region of unused 348 - memory equal in size to the cache, thereby causing the current 349 - contents to be discarded by natural eviction. The alternative, 350 - namely reading every tag, setting up a mapping for the corresponding 351 - page and doing an OCBP for the line, would be much more expensive. 352 - */ 353 488 354 489 sh64_dcache_purge_sets(0, cpu_data->dcache.sets); 355 - 356 - return; 357 - 358 490 } 359 491 360 - /****************************************************************************/ 361 - 362 - static void sh64_dcache_purge_kernel_range(unsigned long start, unsigned long end) 363 - { 364 - /* Purge the range of addresses [start,end] from the D-cache. The 365 - addresses lie in the superpage mapping. There's no harm if we 366 - overpurge at either end - just a small performance loss. */ 367 - unsigned long long ullend, addr, aligned_start; 368 - #if (NEFF == 32) 369 - aligned_start = (unsigned long long)(signed long long)(signed long) start; 370 - #else 371 - #error "NEFF != 32" 372 - #endif 373 - aligned_start &= L1_CACHE_ALIGN_MASK; 374 - addr = aligned_start; 375 - #if (NEFF == 32) 376 - ullend = (unsigned long long) (signed long long) (signed long) end; 377 - #else 378 - #error "NEFF != 32" 379 - #endif 380 - while (addr <= ullend) { 381 - asm __volatile__ ("ocbp %0, 0" : : "r" (addr)); 382 - addr += L1_CACHE_BYTES; 383 - } 384 - return; 385 - } 386 492 387 493 /* Assumes this address (+ (2**n_synbits) pages up from it) aren't used for 388 494 anything else in the kernel */ 389 495 #define MAGIC_PAGE0_START 0xffffffffec000000ULL 390 496 391 - static void sh64_dcache_purge_coloured_phy_page(unsigned long paddr, unsigned long eaddr) 497 + /* Purge the physical page 'paddr' from the cache. It's known that any 498 + * cache lines requiring attention have the same page colour as the the 499 + * address 'eaddr'. 500 + * 501 + * This relies on the fact that the D-cache matches on physical tags when 502 + * no virtual tag matches. So we create an alias for the original page 503 + * and purge through that. (Alternatively, we could have done this by 504 + * switching ASID to match the original mapping and purged through that, 505 + * but that involves ASID switching cost + probably a TLBMISS + refill 506 + * anyway.) 507 + */ 508 + static void sh64_dcache_purge_coloured_phy_page(unsigned long paddr, 509 + unsigned long eaddr) 392 510 { 393 - /* Purge the physical page 'paddr' from the cache. It's known that any 394 - cache lines requiring attention have the same page colour as the the 395 - address 'eaddr'. 396 - 397 - This relies on the fact that the D-cache matches on physical tags 398 - when no virtual tag matches. So we create an alias for the original 399 - page and purge through that. (Alternatively, we could have done 400 - this by switching ASID to match the original mapping and purged 401 - through that, but that involves ASID switching cost + probably a 402 - TLBMISS + refill anyway.) 403 - */ 404 - 405 511 unsigned long long magic_page_start; 406 512 unsigned long long magic_eaddr, magic_eaddr_end; 407 513 ··· 393 531 394 532 /* As long as the kernel is not pre-emptible, this doesn't need to be 395 533 under cli/sti. */ 396 - 397 534 sh64_setup_dtlb_cache_slot(magic_page_start, get_asid(), paddr); 398 535 399 536 magic_eaddr = magic_page_start; 400 537 magic_eaddr_end = magic_eaddr + PAGE_SIZE; 538 + 401 539 while (magic_eaddr < magic_eaddr_end) { 402 540 /* Little point in unrolling this loop - the OCBPs are blocking 403 541 and won't go any quicker (i.e. the loop overhead is parallel 404 542 to part of the OCBP execution.) */ 405 - asm __volatile__ ("ocbp %0, 0" : : "r" (magic_eaddr)); 543 + __asm__ __volatile__ ("ocbp %0, 0" : : "r" (magic_eaddr)); 406 544 magic_eaddr += L1_CACHE_BYTES; 407 545 } 408 546 409 547 sh64_teardown_dtlb_cache_slot(); 410 548 } 411 549 412 - /****************************************************************************/ 413 - 550 + /* 551 + * Purge a page given its physical start address, by creating a temporary 552 + * 1 page mapping and purging across that. Even if we know the virtual 553 + * address (& vma or mm) of the page, the method here is more elegant 554 + * because it avoids issues of coping with page faults on the purge 555 + * instructions (i.e. no special-case code required in the critical path 556 + * in the TLB miss handling). 557 + */ 414 558 static void sh64_dcache_purge_phy_page(unsigned long paddr) 415 559 { 416 - /* Pure a page given its physical start address, by creating a 417 - temporary 1 page mapping and purging across that. Even if we know 418 - the virtual address (& vma or mm) of the page, the method here is 419 - more elegant because it avoids issues of coping with page faults on 420 - the purge instructions (i.e. no special-case code required in the 421 - critical path in the TLB miss handling). */ 422 - 423 560 unsigned long long eaddr_start, eaddr, eaddr_end; 424 561 int i; 425 562 426 563 /* As long as the kernel is not pre-emptible, this doesn't need to be 427 564 under cli/sti. */ 428 - 429 565 eaddr_start = MAGIC_PAGE0_START; 430 - for (i=0; i < (1 << CACHE_OC_N_SYNBITS); i++) { 566 + for (i = 0; i < (1 << CACHE_OC_N_SYNBITS); i++) { 431 567 sh64_setup_dtlb_cache_slot(eaddr_start, get_asid(), paddr); 432 568 433 569 eaddr = eaddr_start; 434 570 eaddr_end = eaddr + PAGE_SIZE; 435 571 while (eaddr < eaddr_end) { 436 - asm __volatile__ ("ocbp %0, 0" : : "r" (eaddr)); 572 + __asm__ __volatile__ ("ocbp %0, 0" : : "r" (eaddr)); 437 573 eaddr += L1_CACHE_BYTES; 438 574 } 439 575 ··· 444 584 unsigned long addr, unsigned long end) 445 585 { 446 586 pgd_t *pgd; 587 + pud_t *pud; 447 588 pmd_t *pmd; 448 589 pte_t *pte; 449 590 pte_t entry; ··· 458 597 if (pgd_bad(*pgd)) 459 598 return; 460 599 461 - pmd = pmd_offset(pgd, addr); 600 + pud = pud_offset(pgd, addr); 601 + if (pud_none(*pud) || pud_bad(*pud)) 602 + return; 603 + 604 + pmd = pmd_offset(pud, addr); 462 605 if (pmd_none(*pmd) || pmd_bad(*pmd)) 463 606 return; 464 607 ··· 476 611 } while (pte++, addr += PAGE_SIZE, addr != end); 477 612 pte_unmap_unlock(pte - 1, ptl); 478 613 } 479 - /****************************************************************************/ 480 614 615 + /* 616 + * There are at least 5 choices for the implementation of this, with 617 + * pros (+), cons(-), comments(*): 618 + * 619 + * 1. ocbp each line in the range through the original user's ASID 620 + * + no lines spuriously evicted 621 + * - tlbmiss handling (must either handle faults on demand => extra 622 + * special-case code in tlbmiss critical path), or map the page in 623 + * advance (=> flush_tlb_range in advance to avoid multiple hits) 624 + * - ASID switching 625 + * - expensive for large ranges 626 + * 627 + * 2. temporarily map each page in the range to a special effective 628 + * address and ocbp through the temporary mapping; relies on the 629 + * fact that SH-5 OCB* always do TLB lookup and match on ptags (they 630 + * never look at the etags) 631 + * + no spurious evictions 632 + * - expensive for large ranges 633 + * * surely cheaper than (1) 634 + * 635 + * 3. walk all the lines in the cache, check the tags, if a match 636 + * occurs create a page mapping to ocbp the line through 637 + * + no spurious evictions 638 + * - tag inspection overhead 639 + * - (especially for small ranges) 640 + * - potential cost of setting up/tearing down page mapping for 641 + * every line that matches the range 642 + * * cost partly independent of range size 643 + * 644 + * 4. walk all the lines in the cache, check the tags, if a match 645 + * occurs use 4 * alloco to purge the line (+3 other probably 646 + * innocent victims) by natural eviction 647 + * + no tlb mapping overheads 648 + * - spurious evictions 649 + * - tag inspection overhead 650 + * 651 + * 5. implement like flush_cache_all 652 + * + no tag inspection overhead 653 + * - spurious evictions 654 + * - bad for small ranges 655 + * 656 + * (1) can be ruled out as more expensive than (2). (2) appears best 657 + * for small ranges. The choice between (3), (4) and (5) for large 658 + * ranges and the range size for the large/small boundary need 659 + * benchmarking to determine. 660 + * 661 + * For now use approach (2) for small ranges and (5) for large ones. 662 + */ 481 663 static void sh64_dcache_purge_user_range(struct mm_struct *mm, 482 664 unsigned long start, unsigned long end) 483 665 { 484 - /* There are at least 5 choices for the implementation of this, with 485 - pros (+), cons(-), comments(*): 666 + int n_pages = ((end - start) >> PAGE_SHIFT); 486 667 487 - 1. ocbp each line in the range through the original user's ASID 488 - + no lines spuriously evicted 489 - - tlbmiss handling (must either handle faults on demand => extra 490 - special-case code in tlbmiss critical path), or map the page in 491 - advance (=> flush_tlb_range in advance to avoid multiple hits) 492 - - ASID switching 493 - - expensive for large ranges 494 - 495 - 2. temporarily map each page in the range to a special effective 496 - address and ocbp through the temporary mapping; relies on the 497 - fact that SH-5 OCB* always do TLB lookup and match on ptags (they 498 - never look at the etags) 499 - + no spurious evictions 500 - - expensive for large ranges 501 - * surely cheaper than (1) 502 - 503 - 3. walk all the lines in the cache, check the tags, if a match 504 - occurs create a page mapping to ocbp the line through 505 - + no spurious evictions 506 - - tag inspection overhead 507 - - (especially for small ranges) 508 - - potential cost of setting up/tearing down page mapping for 509 - every line that matches the range 510 - * cost partly independent of range size 511 - 512 - 4. walk all the lines in the cache, check the tags, if a match 513 - occurs use 4 * alloco to purge the line (+3 other probably 514 - innocent victims) by natural eviction 515 - + no tlb mapping overheads 516 - - spurious evictions 517 - - tag inspection overhead 518 - 519 - 5. implement like flush_cache_all 520 - + no tag inspection overhead 521 - - spurious evictions 522 - - bad for small ranges 523 - 524 - (1) can be ruled out as more expensive than (2). (2) appears best 525 - for small ranges. The choice between (3), (4) and (5) for large 526 - ranges and the range size for the large/small boundary need 527 - benchmarking to determine. 528 - 529 - For now use approach (2) for small ranges and (5) for large ones. 530 - 531 - */ 532 - 533 - int n_pages; 534 - 535 - n_pages = ((end - start) >> PAGE_SHIFT); 536 668 if (n_pages >= 64 || ((start ^ (end - 1)) & PMD_MASK)) { 537 - #if 1 538 669 sh64_dcache_purge_all(); 539 - #else 540 - unsigned long long set, way; 541 - unsigned long mm_asid = mm->context & MMU_CONTEXT_ASID_MASK; 542 - for (set = 0; set < cpu_data->dcache.sets; set++) { 543 - unsigned long long set_base_config_addr = CACHE_OC_ADDRESS_ARRAY + (set << cpu_data->dcache.set_shift); 544 - for (way = 0; way < cpu_data->dcache.ways; way++) { 545 - unsigned long long config_addr = set_base_config_addr + (way << cpu_data->dcache.way_step_shift); 546 - unsigned long long tag0; 547 - unsigned long line_valid; 548 - 549 - asm __volatile__("getcfg %1, 0, %0" : "=r" (tag0) : "r" (config_addr)); 550 - line_valid = tag0 & SH_CACHE_VALID; 551 - if (line_valid) { 552 - unsigned long cache_asid; 553 - unsigned long epn; 554 - 555 - cache_asid = (tag0 & cpu_data->dcache.asid_mask) >> cpu_data->dcache.asid_shift; 556 - /* The next line needs some 557 - explanation. The virtual tags 558 - encode bits [31:13] of the virtual 559 - address, bit [12] of the 'tag' being 560 - implied by the cache set index. */ 561 - epn = (tag0 & cpu_data->dcache.epn_mask) | ((set & 0x80) << cpu_data->dcache.entry_shift); 562 - 563 - if ((cache_asid == mm_asid) && (start <= epn) && (epn < end)) { 564 - /* TODO : could optimise this 565 - call by batching multiple 566 - adjacent sets together. */ 567 - sh64_dcache_purge_sets(set, 1); 568 - break; /* Don't waste time inspecting other ways for this set */ 569 - } 570 - } 571 - } 572 - } 573 - #endif 574 670 } else { 575 671 /* Small range, covered by a single page table page */ 576 672 start &= PAGE_MASK; /* should already be so */ 577 673 end = PAGE_ALIGN(end); /* should already be so */ 578 674 sh64_dcache_purge_user_pages(mm, start, end); 579 675 } 580 - return; 581 676 } 582 677 583 - static void sh64_dcache_wback_current_user_range(unsigned long start, unsigned long end) 678 + /* 679 + * Purge the range of addresses from the D-cache. 680 + * 681 + * The addresses lie in the superpage mapping. There's no harm if we 682 + * overpurge at either end - just a small performance loss. 683 + */ 684 + void __flush_purge_region(void *start, int size) 584 685 { 585 - unsigned long long aligned_start; 586 - unsigned long long ull_end; 587 - unsigned long long addr; 686 + unsigned long long ullend, addr, aligned_start; 588 687 589 - ull_end = end; 688 + aligned_start = (unsigned long long)(signed long long)(signed long) start; 689 + addr = L1_CACHE_ALIGN(aligned_start); 690 + ullend = (unsigned long long) (signed long long) (signed long) start + size; 590 691 591 - /* Just wback over the range using the natural addresses. TLB miss 592 - handling will be OK (TBC) : the range has just been written to by 593 - the signal frame setup code, so the PTEs must exist. 594 - 595 - Note, if we have CONFIG_PREEMPT and get preempted inside this loop, 596 - it doesn't matter, even if the pid->ASID mapping changes whilst 597 - we're away. In that case the cache will have been flushed when the 598 - mapping was renewed. So the writebacks below will be nugatory (and 599 - we'll doubtless have to fault the TLB entry/ies in again with the 600 - new ASID), but it's a rare case. 601 - */ 602 - aligned_start = start & L1_CACHE_ALIGN_MASK; 603 - addr = aligned_start; 604 - while (addr < ull_end) { 605 - asm __volatile__ ("ocbwb %0, 0" : : "r" (addr)); 692 + while (addr <= ullend) { 693 + __asm__ __volatile__ ("ocbp %0, 0" : : "r" (addr)); 606 694 addr += L1_CACHE_BYTES; 607 695 } 608 696 } 609 697 610 - /****************************************************************************/ 698 + void __flush_wback_region(void *start, int size) 699 + { 700 + unsigned long long ullend, addr, aligned_start; 611 701 612 - /* These *MUST* lie in an area of virtual address space that's otherwise unused. */ 702 + aligned_start = (unsigned long long)(signed long long)(signed long) start; 703 + addr = L1_CACHE_ALIGN(aligned_start); 704 + ullend = (unsigned long long) (signed long long) (signed long) start + size; 705 + 706 + while (addr < ullend) { 707 + __asm__ __volatile__ ("ocbwb %0, 0" : : "r" (addr)); 708 + addr += L1_CACHE_BYTES; 709 + } 710 + } 711 + 712 + void __flush_invalidate_region(void *start, int size) 713 + { 714 + unsigned long long ullend, addr, aligned_start; 715 + 716 + aligned_start = (unsigned long long)(signed long long)(signed long) start; 717 + addr = L1_CACHE_ALIGN(aligned_start); 718 + ullend = (unsigned long long) (signed long long) (signed long) start + size; 719 + 720 + while (addr < ullend) { 721 + __asm__ __volatile__ ("ocbi %0, 0" : : "r" (addr)); 722 + addr += L1_CACHE_BYTES; 723 + } 724 + } 725 + #endif /* !CONFIG_DCACHE_DISABLED */ 726 + 727 + /* 728 + * Invalidate the entire contents of both caches, after writing back to 729 + * memory any dirty data from the D-cache. 730 + */ 731 + void flush_cache_all(void) 732 + { 733 + sh64_dcache_purge_all(); 734 + sh64_icache_inv_all(); 735 + } 736 + 737 + /* 738 + * Invalidate an entire user-address space from both caches, after 739 + * writing back dirty data (e.g. for shared mmap etc). 740 + * 741 + * This could be coded selectively by inspecting all the tags then 742 + * doing 4*alloco on any set containing a match (as for 743 + * flush_cache_range), but fork/exit/execve (where this is called from) 744 + * are expensive anyway. 745 + * 746 + * Have to do a purge here, despite the comments re I-cache below. 747 + * There could be odd-coloured dirty data associated with the mm still 748 + * in the cache - if this gets written out through natural eviction 749 + * after the kernel has reused the page there will be chaos. 750 + * 751 + * The mm being torn down won't ever be active again, so any Icache 752 + * lines tagged with its ASID won't be visible for the rest of the 753 + * lifetime of this ASID cycle. Before the ASID gets reused, there 754 + * will be a flush_cache_all. Hence we don't need to touch the 755 + * I-cache. This is similar to the lack of action needed in 756 + * flush_tlb_mm - see fault.c. 757 + */ 758 + void flush_cache_mm(struct mm_struct *mm) 759 + { 760 + sh64_dcache_purge_all(); 761 + } 762 + 763 + /* 764 + * Invalidate (from both caches) the range [start,end) of virtual 765 + * addresses from the user address space specified by mm, after writing 766 + * back any dirty data. 767 + * 768 + * Note, 'end' is 1 byte beyond the end of the range to flush. 769 + */ 770 + void flush_cache_range(struct vm_area_struct *vma, unsigned long start, 771 + unsigned long end) 772 + { 773 + struct mm_struct *mm = vma->vm_mm; 774 + 775 + sh64_dcache_purge_user_range(mm, start, end); 776 + sh64_icache_inv_user_page_range(mm, start, end); 777 + } 778 + 779 + /* 780 + * Invalidate any entries in either cache for the vma within the user 781 + * address space vma->vm_mm for the page starting at virtual address 782 + * 'eaddr'. This seems to be used primarily in breaking COW. Note, 783 + * the I-cache must be searched too in case the page in question is 784 + * both writable and being executed from (e.g. stack trampolines.) 785 + * 786 + * Note, this is called with pte lock held. 787 + */ 788 + void flush_cache_page(struct vm_area_struct *vma, unsigned long eaddr, 789 + unsigned long pfn) 790 + { 791 + sh64_dcache_purge_phy_page(pfn << PAGE_SHIFT); 792 + 793 + if (vma->vm_flags & VM_EXEC) 794 + sh64_icache_inv_user_page(vma, eaddr); 795 + } 796 + 797 + void flush_dcache_page(struct page *page) 798 + { 799 + sh64_dcache_purge_phy_page(page_to_phys(page)); 800 + wmb(); 801 + } 802 + 803 + /* 804 + * Flush the range [start,end] of kernel virtual adddress space from 805 + * the I-cache. The corresponding range must be purged from the 806 + * D-cache also because the SH-5 doesn't have cache snooping between 807 + * the caches. The addresses will be visible through the superpage 808 + * mapping, therefore it's guaranteed that there no cache entries for 809 + * the range in cache sets of the wrong colour. 810 + */ 811 + void flush_icache_range(unsigned long start, unsigned long end) 812 + { 813 + __flush_purge_region((void *)start, end); 814 + wmb(); 815 + sh64_icache_inv_kernel_range(start, end); 816 + } 817 + 818 + /* 819 + * Flush the range of user (defined by vma->vm_mm) address space starting 820 + * at 'addr' for 'len' bytes from the cache. The range does not straddle 821 + * a page boundary, the unique physical page containing the range is 822 + * 'page'. This seems to be used mainly for invalidating an address 823 + * range following a poke into the program text through the ptrace() call 824 + * from another process (e.g. for BRK instruction insertion). 825 + */ 826 + void flush_icache_user_range(struct vm_area_struct *vma, 827 + struct page *page, unsigned long addr, int len) 828 + { 829 + 830 + sh64_dcache_purge_coloured_phy_page(page_to_phys(page), addr); 831 + mb(); 832 + 833 + if (vma->vm_flags & VM_EXEC) 834 + sh64_icache_inv_user_small_range(vma->vm_mm, addr, len); 835 + } 836 + 837 + /* 838 + * For the address range [start,end), write back the data from the 839 + * D-cache and invalidate the corresponding region of the I-cache for the 840 + * current process. Used to flush signal trampolines on the stack to 841 + * make them executable. 842 + */ 843 + void flush_cache_sigtramp(unsigned long vaddr) 844 + { 845 + unsigned long end = vaddr + L1_CACHE_BYTES; 846 + 847 + __flush_wback_region((void *)vaddr, L1_CACHE_BYTES); 848 + wmb(); 849 + sh64_icache_inv_current_user_range(vaddr, end); 850 + } 851 + 852 + /* 853 + * These *MUST* lie in an area of virtual address space that's otherwise 854 + * unused. 855 + */ 613 856 #define UNIQUE_EADDR_START 0xe0000000UL 614 857 #define UNIQUE_EADDR_END 0xe8000000UL 615 858 616 - static unsigned long sh64_make_unique_eaddr(unsigned long user_eaddr, unsigned long paddr) 859 + /* 860 + * Given a physical address paddr, and a user virtual address user_eaddr 861 + * which will eventually be mapped to it, create a one-off kernel-private 862 + * eaddr mapped to the same paddr. This is used for creating special 863 + * destination pages for copy_user_page and clear_user_page. 864 + */ 865 + static unsigned long sh64_make_unique_eaddr(unsigned long user_eaddr, 866 + unsigned long paddr) 617 867 { 618 - /* Given a physical address paddr, and a user virtual address 619 - user_eaddr which will eventually be mapped to it, create a one-off 620 - kernel-private eaddr mapped to the same paddr. This is used for 621 - creating special destination pages for copy_user_page and 622 - clear_user_page */ 623 - 624 868 static unsigned long current_pointer = UNIQUE_EADDR_START; 625 869 unsigned long coloured_pointer; 626 870 ··· 738 764 current_pointer = UNIQUE_EADDR_START; 739 765 } 740 766 741 - coloured_pointer = (current_pointer & ~CACHE_OC_SYN_MASK) | (user_eaddr & CACHE_OC_SYN_MASK); 767 + coloured_pointer = (current_pointer & ~CACHE_OC_SYN_MASK) | 768 + (user_eaddr & CACHE_OC_SYN_MASK); 742 769 sh64_setup_dtlb_cache_slot(coloured_pointer, get_asid(), paddr); 743 770 744 771 current_pointer += (PAGE_SIZE << CACHE_OC_N_SYNBITS); ··· 747 772 return coloured_pointer; 748 773 } 749 774 750 - /****************************************************************************/ 751 - 752 - static void sh64_copy_user_page_coloured(void *to, void *from, unsigned long address) 775 + static void sh64_copy_user_page_coloured(void *to, void *from, 776 + unsigned long address) 753 777 { 754 778 void *coloured_to; 755 779 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); 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); 761 786 762 - coloured_to = (void *) sh64_make_unique_eaddr(address, __pa(to)); 763 - sh64_page_copy(from, coloured_to); 787 + coloured_to = (void *)sh64_make_unique_eaddr(address, __pa(to)); 788 + copy_page(from, coloured_to); 764 789 765 790 sh64_teardown_dtlb_cache_slot(); 766 791 } ··· 769 794 { 770 795 void *coloured_to; 771 796 772 - /* Discard any existing kernel-originated lines of the wrong colour (as 773 - above) */ 774 - sh64_dcache_purge_coloured_phy_page(__pa(to), (unsigned long) to); 797 + /* 798 + * Discard any existing kernel-originated lines of the wrong 799 + * colour (as above) 800 + */ 801 + sh64_dcache_purge_coloured_phy_page(__pa(to), (unsigned long)to); 775 802 776 - coloured_to = (void *) sh64_make_unique_eaddr(address, __pa(to)); 777 - sh64_page_clear(coloured_to); 803 + coloured_to = (void *)sh64_make_unique_eaddr(address, __pa(to)); 804 + clear_page(coloured_to); 778 805 779 806 sh64_teardown_dtlb_cache_slot(); 780 807 } 781 808 782 - #endif /* !CONFIG_DCACHE_DISABLED */ 783 - 784 - /****************************************************************************/ 785 - 786 - /*########################################################################## 787 - EXTERNALLY CALLABLE API. 788 - ##########################################################################*/ 789 - 790 - /* These functions are described in Documentation/cachetlb.txt. 791 - Each one of these functions varies in behaviour depending on whether the 792 - I-cache and/or D-cache are configured out. 793 - 794 - Note that the Linux term 'flush' corresponds to what is termed 'purge' in 795 - the sh/sh64 jargon for the D-cache, i.e. write back dirty data then 796 - invalidate the cache lines, and 'invalidate' for the I-cache. 797 - */ 798 - 799 - #undef FLUSH_TRACE 800 - 801 - void flush_cache_all(void) 809 + /* 810 + * 'from' and 'to' are kernel virtual addresses (within the superpage 811 + * mapping of the physical RAM). 'address' is the user virtual address 812 + * where the copy 'to' will be mapped after. This allows a custom 813 + * mapping to be used to ensure that the new copy is placed in the 814 + * right cache sets for the user to see it without having to bounce it 815 + * out via memory. Note however : the call to flush_page_to_ram in 816 + * (generic)/mm/memory.c:(break_cow) undoes all this good work in that one 817 + * very important case! 818 + * 819 + * TBD : can we guarantee that on every call, any cache entries for 820 + * 'from' are in the same colour sets as 'address' also? i.e. is this 821 + * always used just to deal with COW? (I suspect not). 822 + * 823 + * There are two possibilities here for when the page 'from' was last accessed: 824 + * - by the kernel : this is OK, no purge required. 825 + * - by the/a user (e.g. for break_COW) : need to purge. 826 + * 827 + * If the potential user mapping at 'address' is the same colour as 828 + * 'from' there is no need to purge any cache lines from the 'from' 829 + * page mapped into cache sets of colour 'address'. (The copy will be 830 + * accessing the page through 'from'). 831 + */ 832 + void copy_user_page(void *to, void *from, unsigned long address, 833 + struct page *page) 802 834 { 803 - /* Invalidate the entire contents of both caches, after writing back to 804 - memory any dirty data from the D-cache. */ 805 - sh64_dcache_purge_all(); 806 - sh64_icache_inv_all(); 807 - } 808 - 809 - /****************************************************************************/ 810 - 811 - void flush_cache_mm(struct mm_struct *mm) 812 - { 813 - /* Invalidate an entire user-address space from both caches, after 814 - writing back dirty data (e.g. for shared mmap etc). */ 815 - 816 - /* This could be coded selectively by inspecting all the tags then 817 - doing 4*alloco on any set containing a match (as for 818 - flush_cache_range), but fork/exit/execve (where this is called from) 819 - are expensive anyway. */ 820 - 821 - /* Have to do a purge here, despite the comments re I-cache below. 822 - There could be odd-coloured dirty data associated with the mm still 823 - in the cache - if this gets written out through natural eviction 824 - after the kernel has reused the page there will be chaos. 825 - */ 826 - 827 - sh64_dcache_purge_all(); 828 - 829 - /* The mm being torn down won't ever be active again, so any Icache 830 - lines tagged with its ASID won't be visible for the rest of the 831 - lifetime of this ASID cycle. Before the ASID gets reused, there 832 - will be a flush_cache_all. Hence we don't need to touch the 833 - I-cache. This is similar to the lack of action needed in 834 - flush_tlb_mm - see fault.c. */ 835 - } 836 - 837 - /****************************************************************************/ 838 - 839 - void flush_cache_range(struct vm_area_struct *vma, unsigned long start, 840 - unsigned long end) 841 - { 842 - struct mm_struct *mm = vma->vm_mm; 843 - 844 - /* Invalidate (from both caches) the range [start,end) of virtual 845 - addresses from the user address space specified by mm, after writing 846 - back any dirty data. 847 - 848 - Note, 'end' is 1 byte beyond the end of the range to flush. */ 849 - 850 - sh64_dcache_purge_user_range(mm, start, end); 851 - sh64_icache_inv_user_page_range(mm, start, end); 852 - } 853 - 854 - /****************************************************************************/ 855 - 856 - void flush_cache_page(struct vm_area_struct *vma, unsigned long eaddr, unsigned long pfn) 857 - { 858 - /* Invalidate any entries in either cache for the vma within the user 859 - address space vma->vm_mm for the page starting at virtual address 860 - 'eaddr'. This seems to be used primarily in breaking COW. Note, 861 - the I-cache must be searched too in case the page in question is 862 - both writable and being executed from (e.g. stack trampolines.) 863 - 864 - Note, this is called with pte lock held. 865 - */ 866 - 867 - sh64_dcache_purge_phy_page(pfn << PAGE_SHIFT); 868 - 869 - if (vma->vm_flags & VM_EXEC) { 870 - sh64_icache_inv_user_page(vma, eaddr); 871 - } 872 - } 873 - 874 - /****************************************************************************/ 875 - 876 - #ifndef CONFIG_DCACHE_DISABLED 877 - 878 - void copy_user_page(void *to, void *from, unsigned long address, struct page *page) 879 - { 880 - /* 'from' and 'to' are kernel virtual addresses (within the superpage 881 - mapping of the physical RAM). 'address' is the user virtual address 882 - where the copy 'to' will be mapped after. This allows a custom 883 - mapping to be used to ensure that the new copy is placed in the 884 - right cache sets for the user to see it without having to bounce it 885 - out via memory. Note however : the call to flush_page_to_ram in 886 - (generic)/mm/memory.c:(break_cow) undoes all this good work in that one 887 - very important case! 888 - 889 - TBD : can we guarantee that on every call, any cache entries for 890 - 'from' are in the same colour sets as 'address' also? i.e. is this 891 - always used just to deal with COW? (I suspect not). */ 892 - 893 - /* There are two possibilities here for when the page 'from' was last accessed: 894 - * by the kernel : this is OK, no purge required. 895 - * by the/a user (e.g. for break_COW) : need to purge. 896 - 897 - If the potential user mapping at 'address' is the same colour as 898 - 'from' there is no need to purge any cache lines from the 'from' 899 - page mapped into cache sets of colour 'address'. (The copy will be 900 - accessing the page through 'from'). 901 - */ 902 - 903 - if (((address ^ (unsigned long) from) & CACHE_OC_SYN_MASK) != 0) { 835 + if (((address ^ (unsigned long) from) & CACHE_OC_SYN_MASK) != 0) 904 836 sh64_dcache_purge_coloured_phy_page(__pa(from), address); 905 - } 906 837 907 - if (((address ^ (unsigned long) to) & CACHE_OC_SYN_MASK) == 0) { 908 - /* No synonym problem on destination */ 909 - sh64_page_copy(from, to); 910 - } else { 838 + if (((address ^ (unsigned long) to) & CACHE_OC_SYN_MASK) == 0) 839 + copy_page(to, from); 840 + else 911 841 sh64_copy_user_page_coloured(to, from, address); 912 - } 913 - 914 - /* Note, don't need to flush 'from' page from the cache again - it's 915 - done anyway by the generic code */ 916 842 } 917 843 844 + /* 845 + * 'to' is a kernel virtual address (within the superpage mapping of the 846 + * physical RAM). 'address' is the user virtual address where the 'to' 847 + * page will be mapped after. This allows a custom mapping to be used to 848 + * ensure that the new copy is placed in the right cache sets for the 849 + * user to see it without having to bounce it out via memory. 850 + */ 918 851 void clear_user_page(void *to, unsigned long address, struct page *page) 919 852 { 920 - /* 'to' is a kernel virtual address (within the superpage 921 - mapping of the physical RAM). 'address' is the user virtual address 922 - where the 'to' page will be mapped after. This allows a custom 923 - mapping to be used to ensure that the new copy is placed in the 924 - right cache sets for the user to see it without having to bounce it 925 - out via memory. 926 - */ 927 - 928 - if (((address ^ (unsigned long) to) & CACHE_OC_SYN_MASK) == 0) { 929 - /* No synonym problem on destination */ 930 - sh64_page_clear(to); 931 - } else { 853 + if (((address ^ (unsigned long) to) & CACHE_OC_SYN_MASK) == 0) 854 + clear_page(to); 855 + else 932 856 sh64_clear_user_page_coloured(to, address); 933 - } 934 857 } 935 - 936 - #endif /* !CONFIG_DCACHE_DISABLED */ 937 - 938 - /****************************************************************************/ 939 - 940 - void flush_dcache_page(struct page *page) 941 - { 942 - sh64_dcache_purge_phy_page(page_to_phys(page)); 943 - wmb(); 944 - } 945 - 946 - /****************************************************************************/ 947 - 948 - void flush_icache_range(unsigned long start, unsigned long end) 949 - { 950 - /* Flush the range [start,end] of kernel virtual adddress space from 951 - the I-cache. The corresponding range must be purged from the 952 - D-cache also because the SH-5 doesn't have cache snooping between 953 - the caches. The addresses will be visible through the superpage 954 - mapping, therefore it's guaranteed that there no cache entries for 955 - the range in cache sets of the wrong colour. 956 - 957 - Primarily used for cohering the I-cache after a module has 958 - been loaded. */ 959 - 960 - /* We also make sure to purge the same range from the D-cache since 961 - flush_page_to_ram() won't be doing this for us! */ 962 - 963 - sh64_dcache_purge_kernel_range(start, end); 964 - wmb(); 965 - sh64_icache_inv_kernel_range(start, end); 966 - } 967 - 968 - /****************************************************************************/ 969 - 970 - void flush_icache_user_range(struct vm_area_struct *vma, 971 - struct page *page, unsigned long addr, int len) 972 - { 973 - /* Flush the range of user (defined by vma->vm_mm) address space 974 - starting at 'addr' for 'len' bytes from the cache. The range does 975 - not straddle a page boundary, the unique physical page containing 976 - the range is 'page'. This seems to be used mainly for invalidating 977 - an address range following a poke into the program text through the 978 - ptrace() call from another process (e.g. for BRK instruction 979 - insertion). */ 980 - 981 - sh64_dcache_purge_coloured_phy_page(page_to_phys(page), addr); 982 - mb(); 983 - 984 - if (vma->vm_flags & VM_EXEC) { 985 - sh64_icache_inv_user_small_range(vma->vm_mm, addr, len); 986 - } 987 - } 988 - 989 - /*########################################################################## 990 - ARCH/SH64 PRIVATE CALLABLE API. 991 - ##########################################################################*/ 992 - 993 - void flush_cache_sigtramp(unsigned long start, unsigned long end) 994 - { 995 - /* For the address range [start,end), write back the data from the 996 - D-cache and invalidate the corresponding region of the I-cache for 997 - the current process. Used to flush signal trampolines on the stack 998 - to make them executable. */ 999 - 1000 - sh64_dcache_wback_current_user_range(start, end); 1001 - wmb(); 1002 - sh64_icache_inv_current_user_range(start, end); 1003 - } 1004 -
+19 -11
arch/sh/mm/consistent.c
··· 26 26 void *dma_alloc_coherent(struct device *dev, size_t size, 27 27 dma_addr_t *dma_handle, gfp_t gfp) 28 28 { 29 - void *ret; 29 + void *ret, *ret_nocache; 30 30 struct dma_coherent_mem *mem = dev ? dev->dma_mem : NULL; 31 31 int order = get_order(size); 32 32 ··· 44 44 } 45 45 46 46 ret = (void *)__get_free_pages(gfp, order); 47 + if (!ret) 48 + return NULL; 47 49 48 - if (ret != NULL) { 49 - memset(ret, 0, size); 50 - /* 51 - * Pages from the page allocator may have data present in 52 - * cache. So flush the cache before using uncached memory. 53 - */ 54 - dma_cache_sync(NULL, ret, size, DMA_BIDIRECTIONAL); 55 - *dma_handle = virt_to_phys(ret); 50 + memset(ret, 0, size); 51 + /* 52 + * Pages from the page allocator may have data present in 53 + * cache. So flush the cache before using uncached memory. 54 + */ 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 66 EXPORT_SYMBOL(dma_alloc_coherent); 60 67 ··· 78 71 } else { 79 72 WARN_ON(irqs_disabled()); /* for portability */ 80 73 BUG_ON(mem && mem->flags & DMA_MEMORY_EXCLUSIVE); 81 - free_pages((unsigned long)vaddr, order); 74 + free_pages((unsigned long)phys_to_virt(dma_handle), order); 75 + iounmap(vaddr); 82 76 } 83 77 } 84 78 EXPORT_SYMBOL(dma_free_coherent);
+11
arch/sh/mm/fault_32.c
··· 15 15 #include <linux/mm.h> 16 16 #include <linux/hardirq.h> 17 17 #include <linux/kprobes.h> 18 + #include <asm/io_trapped.h> 18 19 #include <asm/system.h> 19 20 #include <asm/mmu_context.h> 20 21 #include <asm/tlbflush.h> ··· 164 163 if (fixup_exception(regs)) 165 164 return; 166 165 166 + if (handle_trapped_io(regs, address)) 167 + return; 167 168 /* 168 169 * Oops. The kernel tried to access some bad page. We'll have to 169 170 * terminate things with extreme prejudice. ··· 298 295 if (writeaccess) 299 296 entry = pte_mkdirty(entry); 300 297 entry = pte_mkyoung(entry); 298 + 299 + #if defined(CONFIG_CPU_SH4) && !defined(CONFIG_SMP) 300 + /* 301 + * ITLB is not affected by "ldtlb" instruction. 302 + * So, we need to flush the entry by ourselves. 303 + */ 304 + local_flush_tlb_one(get_asid(), address & PAGE_MASK); 305 + #endif 301 306 302 307 set_pte(pte, entry); 303 308 update_mmu_cache(NULL, address, entry);
+2
arch/sh/mm/init.c
··· 203 203 204 204 free_area_init_nodes(max_zone_pfns); 205 205 206 + #ifdef CONFIG_SUPERH32 206 207 /* Set up the uncached fixmap */ 207 208 set_fixmap_nocache(FIX_UNCACHED, __pa(&__uncached_start)); 208 209 ··· 214 213 * 512MB lowmem. 215 214 */ 216 215 cached_to_uncached = P2SEG - P1SEG; 216 + #endif 217 217 #endif 218 218 } 219 219
+2
arch/sh/tools/mach-types
··· 45 45 R2D_PLUS RTS7751R2D_PLUS 46 46 R2D_1 RTS7751R2D_1 47 47 CAYMAN SH_CAYMAN 48 + SDK7780 SH_SDK7780 49 + MIGOR SH_MIGOR
+1 -1
drivers/serial/sh-sci.c
··· 393 393 if (cflag & CRTSCTS) { 394 394 fcr_val |= SCFCR_MCE; 395 395 } else { 396 - #ifdef CONFIG_CPU_SUBTYPE_SH7343 396 + #if defined(CONFIG_CPU_SUBTYPE_SH7343) || defined(CONFIG_CPU_SUBTYPE_SH7366) 397 397 /* Nothing */ 398 398 #elif defined(CONFIG_CPU_SUBTYPE_SH7763) || \ 399 399 defined(CONFIG_CPU_SUBTYPE_SH7780) || \
+7 -2
drivers/serial/sh-sci.h
··· 97 97 # define SCSCR_INIT(port) 0x0038 /* TIE=0,RIE=0,TE=1,RE=1,REIE=1 */ 98 98 # define SCIF_ONLY 99 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 106 #elif defined(CONFIG_CPU_SUBTYPE_SH4_202) 101 107 # define SCSPTR2 0xffe80020 /* 16 bit SCIF */ 102 108 # define SCIF_ORER 0x0001 /* overrun error bit */ 103 109 # define SCSCR_INIT(port) 0x38 /* TIE=0,RIE=0,TE=1,RE=1,REIE=1 */ 104 110 # define SCIF_ONLY 105 111 #elif defined(CONFIG_CPU_SUBTYPE_SH5_101) || defined(CONFIG_CPU_SUBTYPE_SH5_103) 106 - # include <asm/hardware.h> 107 112 # define SCIF_BASE_ADDR 0x01030000 108 113 # define SCIF_ADDR_SH5 PHYS_PERIPHERAL_BLOCK+SCIF_BASE_ADDR 109 114 # define SCIF_PTR2_OFFS 0x0000020 ··· 582 577 return ctrl_inw(SCSPTR3) & 0x0001 ? 1 : 0; /* SCIF */ 583 578 return 1; 584 579 } 585 - #elif defined(CONFIG_CPU_SUBTYPE_SH7722) 580 + #elif defined(CONFIG_CPU_SUBTYPE_SH7722) || defined(CONFIG_CPU_SUBTYPE_SH7366) 586 581 static inline int sci_rxd_in(struct uart_port *port) 587 582 { 588 583 if (port->mapbase == 0xffe00000)
+461 -448
drivers/sh/maple/maple.c
··· 31 31 #include <asm/mach/dma.h> 32 32 #include <asm/mach/sysasic.h> 33 33 #include <asm/mach/maple.h> 34 + #include <linux/delay.h> 34 35 35 36 MODULE_AUTHOR("Yaegshi Takeshi, Paul Mundt, M.R. Brown, Adrian McMenamin"); 36 37 MODULE_DESCRIPTION("Maple bus driver for Dreamcast"); ··· 54 53 static int subdevice_map[MAPLE_PORTS]; 55 54 static unsigned long *maple_sendbuf, *maple_sendptr, *maple_lastptr; 56 55 static unsigned long maple_pnp_time; 57 - static int started, scanning, liststatus; 56 + static int started, scanning, liststatus, realscan; 58 57 static struct kmem_cache *maple_queue_cache; 59 58 60 59 struct maple_device_specify { 61 - int port; 62 - int unit; 60 + int port; 61 + int unit; 63 62 }; 64 63 65 64 /** ··· 69 68 */ 70 69 int maple_driver_register(struct device_driver *drv) 71 70 { 72 - if (!drv) 73 - return -EINVAL; 74 - drv->bus = &maple_bus_type; 75 - return driver_register(drv); 71 + if (!drv) 72 + return -EINVAL; 73 + drv->bus = &maple_bus_type; 74 + return driver_register(drv); 76 75 } 77 76 EXPORT_SYMBOL_GPL(maple_driver_register); 78 77 79 78 /* set hardware registers to enable next round of dma */ 80 79 static void maplebus_dma_reset(void) 81 80 { 82 - ctrl_outl(MAPLE_MAGIC, MAPLE_RESET); 83 - /* set trig type to 0 for software trigger, 1 for hardware (VBLANK) */ 84 - ctrl_outl(1, MAPLE_TRIGTYPE); 85 - ctrl_outl(MAPLE_2MBPS | MAPLE_TIMEOUT(50000), MAPLE_SPEED); 86 - ctrl_outl(PHYSADDR(maple_sendbuf), MAPLE_DMAADDR); 87 - ctrl_outl(1, MAPLE_ENABLE); 81 + ctrl_outl(MAPLE_MAGIC, MAPLE_RESET); 82 + /* set trig type to 0 for software trigger, 1 for hardware (VBLANK) */ 83 + ctrl_outl(1, MAPLE_TRIGTYPE); 84 + ctrl_outl(MAPLE_2MBPS | MAPLE_TIMEOUT(50000), MAPLE_SPEED); 85 + ctrl_outl(PHYSADDR(maple_sendbuf), MAPLE_DMAADDR); 86 + ctrl_outl(1, MAPLE_ENABLE); 88 87 } 89 88 90 89 /** ··· 95 94 * @function: the function code for the device 96 95 */ 97 96 void maple_getcond_callback(struct maple_device *dev, 98 - void (*callback) (struct mapleq * mq), 99 - unsigned long interval, unsigned long function) 97 + void (*callback) (struct mapleq *mq), 98 + unsigned long interval, unsigned long function) 100 99 { 101 - dev->callback = callback; 102 - dev->interval = interval; 103 - dev->function = cpu_to_be32(function); 104 - dev->when = jiffies; 100 + dev->callback = callback; 101 + dev->interval = interval; 102 + dev->function = cpu_to_be32(function); 103 + dev->when = jiffies; 105 104 } 106 105 EXPORT_SYMBOL_GPL(maple_getcond_callback); 107 106 108 107 static int maple_dma_done(void) 109 108 { 110 - return (ctrl_inl(MAPLE_STATE) & 1) == 0; 109 + return (ctrl_inl(MAPLE_STATE) & 1) == 0; 111 110 } 112 111 113 112 static void maple_release_device(struct device *dev) 114 113 { 115 - if (dev->type) { 116 - kfree(dev->type->name); 117 - kfree(dev->type); 118 - } 114 + struct maple_device *mdev; 115 + struct mapleq *mq; 116 + if (!dev) 117 + return; 118 + mdev = to_maple_dev(dev); 119 + mq = mdev->mq; 120 + if (mq) { 121 + if (mq->recvbufdcsp) 122 + kmem_cache_free(maple_queue_cache, mq->recvbufdcsp); 123 + kfree(mq); 124 + mq = NULL; 125 + } 126 + kfree(mdev); 119 127 } 120 128 121 129 /** ··· 133 123 */ 134 124 void maple_add_packet(struct mapleq *mq) 135 125 { 136 - mutex_lock(&maple_list_lock); 137 - list_add(&mq->list, &maple_waitq); 138 - mutex_unlock(&maple_list_lock); 126 + mutex_lock(&maple_list_lock); 127 + list_add(&mq->list, &maple_waitq); 128 + mutex_unlock(&maple_list_lock); 139 129 } 140 130 EXPORT_SYMBOL_GPL(maple_add_packet); 141 131 142 - static struct mapleq *maple_allocq(struct maple_device *dev) 132 + static struct mapleq *maple_allocq(struct maple_device *mdev) 143 133 { 144 - struct mapleq *mq; 134 + struct mapleq *mq; 145 135 146 - mq = kmalloc(sizeof(*mq), GFP_KERNEL); 147 - if (!mq) 148 - return NULL; 136 + mq = kmalloc(sizeof(*mq), GFP_KERNEL); 137 + if (!mq) 138 + return NULL; 149 139 150 - mq->dev = dev; 151 - mq->recvbufdcsp = kmem_cache_zalloc(maple_queue_cache, GFP_KERNEL); 152 - mq->recvbuf = (void *) P2SEGADDR(mq->recvbufdcsp); 153 - if (!mq->recvbuf) { 154 - kfree(mq); 155 - return NULL; 156 - } 140 + mq->dev = mdev; 141 + mq->recvbufdcsp = kmem_cache_zalloc(maple_queue_cache, GFP_KERNEL); 142 + mq->recvbuf = (void *) P2SEGADDR(mq->recvbufdcsp); 143 + if (!mq->recvbuf) { 144 + kfree(mq); 145 + return NULL; 146 + } 157 147 158 - return mq; 148 + return mq; 159 149 } 160 150 161 151 static struct maple_device *maple_alloc_dev(int port, int unit) 162 152 { 163 - struct maple_device *dev; 153 + struct maple_device *mdev; 164 154 165 - dev = kzalloc(sizeof(*dev), GFP_KERNEL); 166 - if (!dev) 167 - return NULL; 155 + mdev = kzalloc(sizeof(*mdev), GFP_KERNEL); 156 + if (!mdev) 157 + return NULL; 168 158 169 - dev->port = port; 170 - dev->unit = unit; 171 - dev->mq = maple_allocq(dev); 159 + mdev->port = port; 160 + mdev->unit = unit; 161 + mdev->mq = maple_allocq(mdev); 172 162 173 - if (!dev->mq) { 174 - kfree(dev); 175 - return NULL; 176 - } 177 - 178 - return dev; 163 + if (!mdev->mq) { 164 + kfree(mdev); 165 + return NULL; 166 + } 167 + mdev->dev.bus = &maple_bus_type; 168 + mdev->dev.parent = &maple_bus; 169 + mdev->function = 0; 170 + return mdev; 179 171 } 180 172 181 173 static void maple_free_dev(struct maple_device *mdev) 182 174 { 183 - if (!mdev) 184 - return; 185 - if (mdev->mq) { 186 - kmem_cache_free(maple_queue_cache, mdev->mq->recvbufdcsp); 187 - kfree(mdev->mq); 188 - } 189 - kfree(mdev); 175 + if (!mdev) 176 + return; 177 + if (mdev->mq) { 178 + if (mdev->mq->recvbufdcsp) 179 + kmem_cache_free(maple_queue_cache, 180 + mdev->mq->recvbufdcsp); 181 + kfree(mdev->mq); 182 + } 183 + kfree(mdev); 190 184 } 191 185 192 186 /* process the command queue into a maple command block ··· 198 184 */ 199 185 static void maple_build_block(struct mapleq *mq) 200 186 { 201 - int port, unit, from, to, len; 202 - unsigned long *lsendbuf = mq->sendbuf; 187 + int port, unit, from, to, len; 188 + unsigned long *lsendbuf = mq->sendbuf; 203 189 204 - port = mq->dev->port & 3; 205 - unit = mq->dev->unit; 206 - len = mq->length; 207 - from = port << 6; 208 - to = (port << 6) | (unit > 0 ? (1 << (unit - 1)) & 0x1f : 0x20); 190 + port = mq->dev->port & 3; 191 + unit = mq->dev->unit; 192 + len = mq->length; 193 + from = port << 6; 194 + to = (port << 6) | (unit > 0 ? (1 << (unit - 1)) & 0x1f : 0x20); 209 195 210 - *maple_lastptr &= 0x7fffffff; 211 - maple_lastptr = maple_sendptr; 196 + *maple_lastptr &= 0x7fffffff; 197 + maple_lastptr = maple_sendptr; 212 198 213 - *maple_sendptr++ = (port << 16) | len | 0x80000000; 214 - *maple_sendptr++ = PHYSADDR(mq->recvbuf); 215 - *maple_sendptr++ = 216 - mq->command | (to << 8) | (from << 16) | (len << 24); 199 + *maple_sendptr++ = (port << 16) | len | 0x80000000; 200 + *maple_sendptr++ = PHYSADDR(mq->recvbuf); 201 + *maple_sendptr++ = 202 + mq->command | (to << 8) | (from << 16) | (len << 24); 217 203 218 - while (len-- > 0) 219 - *maple_sendptr++ = *lsendbuf++; 204 + while (len-- > 0) 205 + *maple_sendptr++ = *lsendbuf++; 220 206 } 221 207 222 208 /* build up command queue */ 223 209 static void maple_send(void) 224 210 { 225 - int i; 226 - int maple_packets; 227 - struct mapleq *mq, *nmq; 211 + int i; 212 + int maple_packets; 213 + struct mapleq *mq, *nmq; 228 214 229 - if (!list_empty(&maple_sentq)) 230 - return; 231 - if (list_empty(&maple_waitq) || !maple_dma_done()) 232 - return; 233 - maple_packets = 0; 234 - maple_sendptr = maple_lastptr = maple_sendbuf; 235 - list_for_each_entry_safe(mq, nmq, &maple_waitq, list) { 236 - maple_build_block(mq); 237 - list_move(&mq->list, &maple_sentq); 238 - if (maple_packets++ > MAPLE_MAXPACKETS) 239 - break; 240 - } 241 - if (maple_packets > 0) { 242 - for (i = 0; i < (1 << MAPLE_DMA_PAGES); i++) 243 - dma_cache_sync(0, maple_sendbuf + i * PAGE_SIZE, 244 - PAGE_SIZE, DMA_BIDIRECTIONAL); 245 - } 215 + if (!list_empty(&maple_sentq)) 216 + return; 217 + if (list_empty(&maple_waitq) || !maple_dma_done()) 218 + return; 219 + maple_packets = 0; 220 + maple_sendptr = maple_lastptr = maple_sendbuf; 221 + list_for_each_entry_safe(mq, nmq, &maple_waitq, list) { 222 + maple_build_block(mq); 223 + list_move(&mq->list, &maple_sentq); 224 + if (maple_packets++ > MAPLE_MAXPACKETS) 225 + break; 226 + } 227 + if (maple_packets > 0) { 228 + for (i = 0; i < (1 << MAPLE_DMA_PAGES); i++) 229 + dma_cache_sync(0, maple_sendbuf + i * PAGE_SIZE, 230 + PAGE_SIZE, DMA_BIDIRECTIONAL); 231 + } 246 232 } 247 233 248 234 static int attach_matching_maple_driver(struct device_driver *driver, 249 - void *devptr) 235 + void *devptr) 250 236 { 251 - struct maple_driver *maple_drv; 252 - struct maple_device *mdev; 237 + struct maple_driver *maple_drv; 238 + struct maple_device *mdev; 253 239 254 - mdev = devptr; 255 - maple_drv = to_maple_driver(driver); 256 - if (mdev->devinfo.function & be32_to_cpu(maple_drv->function)) { 257 - if (maple_drv->connect(mdev) == 0) { 258 - mdev->driver = maple_drv; 259 - return 1; 260 - } 261 - } 262 - return 0; 240 + mdev = devptr; 241 + maple_drv = to_maple_driver(driver); 242 + if (mdev->devinfo.function & be32_to_cpu(maple_drv->function)) { 243 + if (maple_drv->connect(mdev) == 0) { 244 + mdev->driver = maple_drv; 245 + return 1; 246 + } 247 + } 248 + return 0; 263 249 } 264 250 265 251 static void maple_detach_driver(struct maple_device *mdev) 266 252 { 267 - if (!mdev) 268 - return; 269 - if (mdev->driver) { 270 - if (mdev->driver->disconnect) 271 - mdev->driver->disconnect(mdev); 272 - } 273 - mdev->driver = NULL; 274 - if (mdev->registered) { 275 - maple_release_device(&mdev->dev); 276 - device_unregister(&mdev->dev); 277 - } 278 - mdev->registered = 0; 279 - maple_free_dev(mdev); 253 + if (!mdev) 254 + return; 255 + if (mdev->driver) { 256 + if (mdev->driver->disconnect) 257 + mdev->driver->disconnect(mdev); 258 + } 259 + mdev->driver = NULL; 260 + device_unregister(&mdev->dev); 261 + mdev = NULL; 280 262 } 281 263 282 264 /* process initial MAPLE_COMMAND_DEVINFO for each device or port */ 283 - static void maple_attach_driver(struct maple_device *dev) 265 + static void maple_attach_driver(struct maple_device *mdev) 284 266 { 285 - char *p; 267 + char *p, *recvbuf; 268 + unsigned long function; 269 + int matched, retval; 286 270 287 - char *recvbuf; 288 - unsigned long function; 289 - int matched, retval; 271 + recvbuf = mdev->mq->recvbuf; 272 + /* copy the data as individual elements in 273 + * case of memory optimisation */ 274 + memcpy(&mdev->devinfo.function, recvbuf + 4, 4); 275 + memcpy(&mdev->devinfo.function_data[0], recvbuf + 8, 12); 276 + memcpy(&mdev->devinfo.area_code, recvbuf + 20, 1); 277 + memcpy(&mdev->devinfo.connector_direction, recvbuf + 21, 1); 278 + memcpy(&mdev->devinfo.product_name[0], recvbuf + 22, 30); 279 + memcpy(&mdev->devinfo.product_licence[0], recvbuf + 52, 60); 280 + memcpy(&mdev->devinfo.standby_power, recvbuf + 112, 2); 281 + memcpy(&mdev->devinfo.max_power, recvbuf + 114, 2); 282 + memcpy(mdev->product_name, mdev->devinfo.product_name, 30); 283 + mdev->product_name[30] = '\0'; 284 + memcpy(mdev->product_licence, mdev->devinfo.product_licence, 60); 285 + mdev->product_licence[60] = '\0'; 290 286 291 - recvbuf = dev->mq->recvbuf; 292 - memcpy(&dev->devinfo, recvbuf + 4, sizeof(dev->devinfo)); 293 - memcpy(dev->product_name, dev->devinfo.product_name, 30); 294 - memcpy(dev->product_licence, dev->devinfo.product_licence, 60); 295 - dev->product_name[30] = '\0'; 296 - dev->product_licence[60] = '\0'; 287 + for (p = mdev->product_name + 29; mdev->product_name <= p; p--) 288 + if (*p == ' ') 289 + *p = '\0'; 290 + else 291 + break; 292 + for (p = mdev->product_licence + 59; mdev->product_licence <= p; p--) 293 + if (*p == ' ') 294 + *p = '\0'; 295 + else 296 + break; 297 297 298 - for (p = dev->product_name + 29; dev->product_name <= p; p--) 299 - if (*p == ' ') 300 - *p = '\0'; 301 - else 302 - break; 298 + if (realscan) { 299 + printk(KERN_INFO "Maple device detected: %s\n", 300 + mdev->product_name); 301 + printk(KERN_INFO "Maple device: %s\n", mdev->product_licence); 302 + } 303 303 304 - for (p = dev->product_licence + 59; dev->product_licence <= p; p--) 305 - if (*p == ' ') 306 - *p = '\0'; 307 - else 308 - break; 304 + function = be32_to_cpu(mdev->devinfo.function); 309 305 310 - function = be32_to_cpu(dev->devinfo.function); 306 + if (function > 0x200) { 307 + /* Do this silently - as not a real device */ 308 + function = 0; 309 + mdev->driver = &maple_dummy_driver; 310 + sprintf(mdev->dev.bus_id, "%d:0.port", mdev->port); 311 + } else { 312 + if (realscan) 313 + printk(KERN_INFO 314 + "Maple bus at (%d, %d): Function 0x%lX\n", 315 + mdev->port, mdev->unit, function); 311 316 312 - if (function > 0x200) { 313 - /* Do this silently - as not a real device */ 314 - function = 0; 315 - dev->driver = &maple_dummy_driver; 316 - sprintf(dev->dev.bus_id, "%d:0.port", dev->port); 317 - } else { 318 - printk(KERN_INFO 319 - "Maple bus at (%d, %d): Connected function 0x%lX\n", 320 - dev->port, dev->unit, function); 317 + matched = 318 + bus_for_each_drv(&maple_bus_type, NULL, mdev, 319 + attach_matching_maple_driver); 321 320 322 - matched = 323 - bus_for_each_drv(&maple_bus_type, NULL, dev, 324 - attach_matching_maple_driver); 325 - 326 - if (matched == 0) { 327 - /* Driver does not exist yet */ 328 - printk(KERN_INFO 329 - "No maple driver found for this device\n"); 330 - dev->driver = &maple_dummy_driver; 331 - } 332 - 333 - sprintf(dev->dev.bus_id, "%d:0%d.%lX", dev->port, 334 - dev->unit, function); 335 - } 336 - dev->function = function; 337 - dev->dev.bus = &maple_bus_type; 338 - dev->dev.parent = &maple_bus; 339 - dev->dev.release = &maple_release_device; 340 - retval = device_register(&dev->dev); 341 - if (retval) { 342 - printk(KERN_INFO 343 - "Maple bus: Attempt to register device (%x, %x) failed.\n", 344 - dev->port, dev->unit); 345 - maple_free_dev(dev); 346 - } 347 - dev->registered = 1; 321 + if (matched == 0) { 322 + /* Driver does not exist yet */ 323 + if (realscan) 324 + printk(KERN_INFO 325 + "No maple driver found.\n"); 326 + mdev->driver = &maple_dummy_driver; 327 + } 328 + sprintf(mdev->dev.bus_id, "%d:0%d.%lX", mdev->port, 329 + mdev->unit, function); 330 + } 331 + mdev->function = function; 332 + mdev->dev.release = &maple_release_device; 333 + retval = device_register(&mdev->dev); 334 + if (retval) { 335 + printk(KERN_INFO 336 + "Maple bus: Attempt to register device" 337 + " (%x, %x) failed.\n", 338 + mdev->port, mdev->unit); 339 + maple_free_dev(mdev); 340 + mdev = NULL; 341 + return; 342 + } 348 343 } 349 344 350 345 /* ··· 363 340 */ 364 341 static int detach_maple_device(struct device *device, void *portptr) 365 342 { 366 - struct maple_device_specify *ds; 367 - struct maple_device *mdev; 343 + struct maple_device_specify *ds; 344 + struct maple_device *mdev; 368 345 369 - ds = portptr; 370 - mdev = to_maple_dev(device); 371 - if (mdev->port == ds->port && mdev->unit == ds->unit) 372 - return 1; 373 - return 0; 346 + ds = portptr; 347 + mdev = to_maple_dev(device); 348 + if (mdev->port == ds->port && mdev->unit == ds->unit) 349 + return 1; 350 + return 0; 374 351 } 375 352 376 353 static int setup_maple_commands(struct device *device, void *ignored) 377 354 { 378 - struct maple_device *maple_dev = to_maple_dev(device); 355 + struct maple_device *maple_dev = to_maple_dev(device); 379 356 380 - if ((maple_dev->interval > 0) 381 - && time_after(jiffies, maple_dev->when)) { 382 - maple_dev->when = jiffies + maple_dev->interval; 383 - maple_dev->mq->command = MAPLE_COMMAND_GETCOND; 384 - maple_dev->mq->sendbuf = &maple_dev->function; 385 - maple_dev->mq->length = 1; 386 - maple_add_packet(maple_dev->mq); 387 - liststatus++; 388 - } else { 389 - if (time_after(jiffies, maple_pnp_time)) { 390 - maple_dev->mq->command = MAPLE_COMMAND_DEVINFO; 391 - maple_dev->mq->length = 0; 392 - maple_add_packet(maple_dev->mq); 393 - liststatus++; 394 - } 395 - } 357 + if ((maple_dev->interval > 0) 358 + && time_after(jiffies, maple_dev->when)) { 359 + maple_dev->when = jiffies + maple_dev->interval; 360 + maple_dev->mq->command = MAPLE_COMMAND_GETCOND; 361 + maple_dev->mq->sendbuf = &maple_dev->function; 362 + maple_dev->mq->length = 1; 363 + maple_add_packet(maple_dev->mq); 364 + liststatus++; 365 + } else { 366 + if (time_after(jiffies, maple_pnp_time)) { 367 + maple_dev->mq->command = MAPLE_COMMAND_DEVINFO; 368 + maple_dev->mq->length = 0; 369 + maple_add_packet(maple_dev->mq); 370 + liststatus++; 371 + } 372 + } 396 373 397 - return 0; 374 + return 0; 398 375 } 399 376 400 377 /* VBLANK bottom half - implemented via workqueue */ 401 378 static void maple_vblank_handler(struct work_struct *work) 402 379 { 403 - if (!maple_dma_done()) 404 - return; 405 - if (!list_empty(&maple_sentq)) 406 - return; 407 - ctrl_outl(0, MAPLE_ENABLE); 408 - liststatus = 0; 409 - bus_for_each_dev(&maple_bus_type, NULL, NULL, 410 - setup_maple_commands); 411 - if (time_after(jiffies, maple_pnp_time)) 412 - maple_pnp_time = jiffies + MAPLE_PNP_INTERVAL; 413 - if (liststatus && list_empty(&maple_sentq)) { 414 - INIT_LIST_HEAD(&maple_sentq); 415 - maple_send(); 416 - } 417 - maplebus_dma_reset(); 380 + if (!maple_dma_done()) 381 + return; 382 + if (!list_empty(&maple_sentq)) 383 + return; 384 + ctrl_outl(0, MAPLE_ENABLE); 385 + liststatus = 0; 386 + bus_for_each_dev(&maple_bus_type, NULL, NULL, 387 + setup_maple_commands); 388 + if (time_after(jiffies, maple_pnp_time)) 389 + maple_pnp_time = jiffies + MAPLE_PNP_INTERVAL; 390 + if (liststatus && list_empty(&maple_sentq)) { 391 + INIT_LIST_HEAD(&maple_sentq); 392 + maple_send(); 393 + } 394 + maplebus_dma_reset(); 418 395 } 419 396 420 397 /* handle devices added via hotplugs - placing them on queue for DEVINFO*/ 421 398 static void maple_map_subunits(struct maple_device *mdev, int submask) 422 399 { 423 - int retval, k, devcheck; 424 - struct maple_device *mdev_add; 425 - struct maple_device_specify ds; 400 + int retval, k, devcheck; 401 + struct maple_device *mdev_add; 402 + struct maple_device_specify ds; 426 403 427 - for (k = 0; k < 5; k++) { 428 - ds.port = mdev->port; 429 - ds.unit = k + 1; 430 - retval = 431 - bus_for_each_dev(&maple_bus_type, NULL, &ds, 432 - detach_maple_device); 433 - if (retval) { 434 - submask = submask >> 1; 435 - continue; 436 - } 437 - devcheck = submask & 0x01; 438 - if (devcheck) { 439 - mdev_add = maple_alloc_dev(mdev->port, k + 1); 440 - if (!mdev_add) 441 - return; 442 - mdev_add->mq->command = MAPLE_COMMAND_DEVINFO; 443 - mdev_add->mq->length = 0; 444 - maple_add_packet(mdev_add->mq); 445 - scanning = 1; 446 - } 447 - submask = submask >> 1; 448 - } 404 + for (k = 0; k < 5; k++) { 405 + ds.port = mdev->port; 406 + ds.unit = k + 1; 407 + retval = 408 + bus_for_each_dev(&maple_bus_type, NULL, &ds, 409 + detach_maple_device); 410 + if (retval) { 411 + submask = submask >> 1; 412 + continue; 413 + } 414 + devcheck = submask & 0x01; 415 + if (devcheck) { 416 + mdev_add = maple_alloc_dev(mdev->port, k + 1); 417 + if (!mdev_add) 418 + return; 419 + mdev_add->mq->command = MAPLE_COMMAND_DEVINFO; 420 + mdev_add->mq->length = 0; 421 + maple_add_packet(mdev_add->mq); 422 + scanning = 1; 423 + } 424 + submask = submask >> 1; 425 + } 449 426 } 450 427 451 428 /* mark a device as removed */ 452 429 static void maple_clean_submap(struct maple_device *mdev) 453 430 { 454 - int killbit; 431 + int killbit; 455 432 456 - killbit = (mdev->unit > 0 ? (1 << (mdev->unit - 1)) & 0x1f : 0x20); 457 - killbit = ~killbit; 458 - killbit &= 0xFF; 459 - subdevice_map[mdev->port] = subdevice_map[mdev->port] & killbit; 433 + killbit = (mdev->unit > 0 ? (1 << (mdev->unit - 1)) & 0x1f : 0x20); 434 + killbit = ~killbit; 435 + killbit &= 0xFF; 436 + subdevice_map[mdev->port] = subdevice_map[mdev->port] & killbit; 460 437 } 461 438 462 439 /* handle empty port or hotplug removal */ 463 440 static void maple_response_none(struct maple_device *mdev, 464 - struct mapleq *mq) 441 + struct mapleq *mq) 465 442 { 466 - if (mdev->unit != 0) { 467 - list_del(&mq->list); 468 - maple_clean_submap(mdev); 469 - printk(KERN_INFO 470 - "Maple bus device detaching at (%d, %d)\n", 471 - mdev->port, mdev->unit); 472 - maple_detach_driver(mdev); 473 - return; 474 - } 475 - if (!started) { 476 - printk(KERN_INFO "No maple devices attached to port %d\n", 477 - mdev->port); 478 - return; 479 - } 480 - maple_clean_submap(mdev); 443 + if (mdev->unit != 0) { 444 + list_del(&mq->list); 445 + maple_clean_submap(mdev); 446 + printk(KERN_INFO 447 + "Maple bus device detaching at (%d, %d)\n", 448 + mdev->port, mdev->unit); 449 + maple_detach_driver(mdev); 450 + return; 451 + } 452 + if (!started) { 453 + printk(KERN_INFO "No maple devices attached to port %d\n", 454 + mdev->port); 455 + return; 456 + } 457 + maple_clean_submap(mdev); 481 458 } 482 459 483 460 /* preprocess hotplugs or scans */ 484 461 static void maple_response_devinfo(struct maple_device *mdev, 485 - char *recvbuf) 462 + char *recvbuf) 486 463 { 487 - char submask; 488 - if ((!started) || (scanning == 2)) { 489 - maple_attach_driver(mdev); 490 - return; 491 - } 492 - if (mdev->unit == 0) { 493 - submask = recvbuf[2] & 0x1F; 494 - if (submask ^ subdevice_map[mdev->port]) { 495 - maple_map_subunits(mdev, submask); 496 - subdevice_map[mdev->port] = submask; 497 - } 498 - } 464 + char submask; 465 + if ((!started) || (scanning == 2)) { 466 + maple_attach_driver(mdev); 467 + return; 468 + } 469 + if (mdev->unit == 0) { 470 + submask = recvbuf[2] & 0x1F; 471 + if (submask ^ subdevice_map[mdev->port]) { 472 + maple_map_subunits(mdev, submask); 473 + subdevice_map[mdev->port] = submask; 474 + } 475 + } 499 476 } 500 477 501 478 /* maple dma end bottom half - implemented via workqueue */ 502 479 static void maple_dma_handler(struct work_struct *work) 503 480 { 504 - struct mapleq *mq, *nmq; 505 - struct maple_device *dev; 506 - char *recvbuf; 507 - enum maple_code code; 481 + struct mapleq *mq, *nmq; 482 + struct maple_device *dev; 483 + char *recvbuf; 484 + enum maple_code code; 508 485 509 - if (!maple_dma_done()) 510 - return; 511 - ctrl_outl(0, MAPLE_ENABLE); 512 - if (!list_empty(&maple_sentq)) { 513 - list_for_each_entry_safe(mq, nmq, &maple_sentq, list) { 514 - recvbuf = mq->recvbuf; 515 - code = recvbuf[0]; 516 - dev = mq->dev; 517 - switch (code) { 518 - case MAPLE_RESPONSE_NONE: 519 - maple_response_none(dev, mq); 520 - break; 486 + if (!maple_dma_done()) 487 + return; 488 + ctrl_outl(0, MAPLE_ENABLE); 489 + if (!list_empty(&maple_sentq)) { 490 + list_for_each_entry_safe(mq, nmq, &maple_sentq, list) { 491 + recvbuf = mq->recvbuf; 492 + code = recvbuf[0]; 493 + dev = mq->dev; 494 + switch (code) { 495 + case MAPLE_RESPONSE_NONE: 496 + maple_response_none(dev, mq); 497 + break; 521 498 522 - case MAPLE_RESPONSE_DEVINFO: 523 - maple_response_devinfo(dev, recvbuf); 524 - break; 499 + case MAPLE_RESPONSE_DEVINFO: 500 + maple_response_devinfo(dev, recvbuf); 501 + break; 525 502 526 - case MAPLE_RESPONSE_DATATRF: 527 - if (dev->callback) 528 - dev->callback(mq); 529 - break; 503 + case MAPLE_RESPONSE_DATATRF: 504 + if (dev->callback) 505 + dev->callback(mq); 506 + break; 530 507 531 - case MAPLE_RESPONSE_FILEERR: 532 - case MAPLE_RESPONSE_AGAIN: 533 - case MAPLE_RESPONSE_BADCMD: 534 - case MAPLE_RESPONSE_BADFUNC: 535 - printk(KERN_DEBUG 536 - "Maple non-fatal error 0x%X\n", 537 - code); 538 - break; 508 + case MAPLE_RESPONSE_FILEERR: 509 + case MAPLE_RESPONSE_AGAIN: 510 + case MAPLE_RESPONSE_BADCMD: 511 + case MAPLE_RESPONSE_BADFUNC: 512 + printk(KERN_DEBUG 513 + "Maple non-fatal error 0x%X\n", 514 + code); 515 + break; 539 516 540 - case MAPLE_RESPONSE_ALLINFO: 541 - printk(KERN_DEBUG 542 - "Maple - extended device information not supported\n"); 543 - break; 517 + case MAPLE_RESPONSE_ALLINFO: 518 + printk(KERN_DEBUG 519 + "Maple - extended device information" 520 + " not supported\n"); 521 + break; 544 522 545 - case MAPLE_RESPONSE_OK: 546 - break; 523 + case MAPLE_RESPONSE_OK: 524 + break; 547 525 548 - default: 549 - break; 550 - } 551 - } 552 - INIT_LIST_HEAD(&maple_sentq); 553 - if (scanning == 1) { 554 - maple_send(); 555 - scanning = 2; 556 - } else 557 - scanning = 0; 526 + default: 527 + break; 528 + } 529 + } 530 + INIT_LIST_HEAD(&maple_sentq); 531 + if (scanning == 1) { 532 + maple_send(); 533 + scanning = 2; 534 + } else 535 + scanning = 0; 558 536 559 - if (started == 0) 560 - started = 1; 561 - } 562 - maplebus_dma_reset(); 537 + if (started == 0) 538 + started = 1; 539 + } 540 + maplebus_dma_reset(); 563 541 } 564 542 565 543 static irqreturn_t maplebus_dma_interrupt(int irq, void *dev_id) 566 544 { 567 - /* Load everything into the bottom half */ 568 - schedule_work(&maple_dma_process); 569 - return IRQ_HANDLED; 545 + /* Load everything into the bottom half */ 546 + schedule_work(&maple_dma_process); 547 + return IRQ_HANDLED; 570 548 } 571 549 572 550 static irqreturn_t maplebus_vblank_interrupt(int irq, void *dev_id) 573 551 { 574 - schedule_work(&maple_vblank_process); 575 - return IRQ_HANDLED; 552 + schedule_work(&maple_vblank_process); 553 + return IRQ_HANDLED; 576 554 } 577 - 578 - static struct irqaction maple_dma_irq = { 579 - .name = "maple bus DMA handler", 580 - .handler = maplebus_dma_interrupt, 581 - .flags = IRQF_SHARED, 582 - }; 583 - 584 - static struct irqaction maple_vblank_irq = { 585 - .name = "maple bus VBLANK handler", 586 - .handler = maplebus_vblank_interrupt, 587 - .flags = IRQF_SHARED, 588 - }; 589 555 590 556 static int maple_set_dma_interrupt_handler(void) 591 557 { 592 - return setup_irq(HW_EVENT_MAPLE_DMA, &maple_dma_irq); 558 + return request_irq(HW_EVENT_MAPLE_DMA, maplebus_dma_interrupt, 559 + IRQF_SHARED, "maple bus DMA", &maple_dummy_driver); 593 560 } 594 561 595 562 static int maple_set_vblank_interrupt_handler(void) 596 563 { 597 - return setup_irq(HW_EVENT_VSYNC, &maple_vblank_irq); 564 + return request_irq(HW_EVENT_VSYNC, maplebus_vblank_interrupt, 565 + IRQF_SHARED, "maple bus VBLANK", &maple_dummy_driver); 598 566 } 599 567 600 568 static int maple_get_dma_buffer(void) 601 569 { 602 - maple_sendbuf = 603 - (void *) __get_free_pages(GFP_KERNEL | __GFP_ZERO, 604 - MAPLE_DMA_PAGES); 605 - if (!maple_sendbuf) 606 - return -ENOMEM; 607 - return 0; 570 + maple_sendbuf = 571 + (void *) __get_free_pages(GFP_KERNEL | __GFP_ZERO, 572 + MAPLE_DMA_PAGES); 573 + if (!maple_sendbuf) 574 + return -ENOMEM; 575 + return 0; 608 576 } 609 577 610 578 static int match_maple_bus_driver(struct device *devptr, 611 - struct device_driver *drvptr) 579 + struct device_driver *drvptr) 612 580 { 613 - struct maple_driver *maple_drv; 614 - struct maple_device *maple_dev; 581 + struct maple_driver *maple_drv; 582 + struct maple_device *maple_dev; 615 583 616 - maple_drv = container_of(drvptr, struct maple_driver, drv); 617 - maple_dev = container_of(devptr, struct maple_device, dev); 618 - /* Trap empty port case */ 619 - if (maple_dev->devinfo.function == 0xFFFFFFFF) 620 - return 0; 621 - else if (maple_dev->devinfo.function & 622 - be32_to_cpu(maple_drv->function)) 623 - return 1; 624 - return 0; 584 + maple_drv = container_of(drvptr, struct maple_driver, drv); 585 + maple_dev = container_of(devptr, struct maple_device, dev); 586 + /* Trap empty port case */ 587 + if (maple_dev->devinfo.function == 0xFFFFFFFF) 588 + return 0; 589 + else if (maple_dev->devinfo.function & 590 + be32_to_cpu(maple_drv->function)) 591 + return 1; 592 + return 0; 625 593 } 626 594 627 - static int maple_bus_uevent(struct device *dev, struct kobj_uevent_env *env) 595 + static int maple_bus_uevent(struct device *dev, 596 + struct kobj_uevent_env *env) 628 597 { 629 - return 0; 598 + return 0; 630 599 } 631 600 632 601 static void maple_bus_release(struct device *dev) ··· 626 611 } 627 612 628 613 static struct maple_driver maple_dummy_driver = { 629 - .drv = { 630 - .name = "maple_dummy_driver", 631 - .bus = &maple_bus_type, 632 - }, 614 + .drv = { 615 + .name = "maple_dummy_driver", 616 + .bus = &maple_bus_type, 617 + }, 633 618 }; 634 619 635 620 struct bus_type maple_bus_type = { 636 - .name = "maple", 637 - .match = match_maple_bus_driver, 638 - .uevent = maple_bus_uevent, 621 + .name = "maple", 622 + .match = match_maple_bus_driver, 623 + .uevent = maple_bus_uevent, 639 624 }; 640 625 EXPORT_SYMBOL_GPL(maple_bus_type); 641 626 642 627 static struct device maple_bus = { 643 - .bus_id = "maple", 644 - .release = maple_bus_release, 628 + .bus_id = "maple", 629 + .release = maple_bus_release, 645 630 }; 646 631 647 632 static int __init maple_bus_init(void) 648 633 { 649 - int retval, i; 650 - struct maple_device *mdev[MAPLE_PORTS]; 651 - ctrl_outl(0, MAPLE_STATE); 634 + int retval, i; 635 + struct maple_device *mdev[MAPLE_PORTS]; 636 + ctrl_outl(0, MAPLE_STATE); 652 637 653 - retval = device_register(&maple_bus); 654 - if (retval) 655 - goto cleanup; 638 + retval = device_register(&maple_bus); 639 + if (retval) 640 + goto cleanup; 656 641 657 - retval = bus_register(&maple_bus_type); 658 - if (retval) 659 - goto cleanup_device; 642 + retval = bus_register(&maple_bus_type); 643 + if (retval) 644 + goto cleanup_device; 660 645 661 - retval = driver_register(&maple_dummy_driver.drv); 646 + retval = driver_register(&maple_dummy_driver.drv); 647 + if (retval) 648 + goto cleanup_bus; 662 649 663 - if (retval) 664 - goto cleanup_bus; 650 + /* allocate memory for maple bus dma */ 651 + retval = maple_get_dma_buffer(); 652 + if (retval) { 653 + printk(KERN_INFO 654 + "Maple bus: Failed to allocate Maple DMA buffers\n"); 655 + goto cleanup_basic; 656 + } 665 657 666 - /* allocate memory for maple bus dma */ 667 - retval = maple_get_dma_buffer(); 668 - if (retval) { 669 - printk(KERN_INFO 670 - "Maple bus: Failed to allocate Maple DMA buffers\n"); 671 - goto cleanup_basic; 672 - } 658 + /* set up DMA interrupt handler */ 659 + retval = maple_set_dma_interrupt_handler(); 660 + if (retval) { 661 + printk(KERN_INFO 662 + "Maple bus: Failed to grab maple DMA IRQ\n"); 663 + goto cleanup_dma; 664 + } 673 665 674 - /* set up DMA interrupt handler */ 675 - retval = maple_set_dma_interrupt_handler(); 676 - if (retval) { 677 - printk(KERN_INFO 678 - "Maple bus: Failed to grab maple DMA IRQ\n"); 679 - goto cleanup_dma; 680 - } 666 + /* set up VBLANK interrupt handler */ 667 + retval = maple_set_vblank_interrupt_handler(); 668 + if (retval) { 669 + printk(KERN_INFO "Maple bus: Failed to grab VBLANK IRQ\n"); 670 + goto cleanup_irq; 671 + } 681 672 682 - /* set up VBLANK interrupt handler */ 683 - retval = maple_set_vblank_interrupt_handler(); 684 - if (retval) { 685 - printk(KERN_INFO "Maple bus: Failed to grab VBLANK IRQ\n"); 686 - goto cleanup_irq; 687 - } 673 + maple_queue_cache = 674 + kmem_cache_create("maple_queue_cache", 0x400, 0, 675 + SLAB_POISON|SLAB_HWCACHE_ALIGN, NULL); 688 676 689 - maple_queue_cache = 690 - kmem_cache_create("maple_queue_cache", 0x400, 0, 691 - SLAB_HWCACHE_ALIGN, NULL); 677 + if (!maple_queue_cache) 678 + goto cleanup_bothirqs; 692 679 693 - if (!maple_queue_cache) 694 - goto cleanup_bothirqs; 680 + /* setup maple ports */ 681 + for (i = 0; i < MAPLE_PORTS; i++) { 682 + mdev[i] = maple_alloc_dev(i, 0); 683 + if (!mdev[i]) { 684 + while (i-- > 0) 685 + maple_free_dev(mdev[i]); 686 + goto cleanup_cache; 687 + } 688 + mdev[i]->mq->command = MAPLE_COMMAND_DEVINFO; 689 + mdev[i]->mq->length = 0; 690 + maple_add_packet(mdev[i]->mq); 691 + /* delay aids hardware detection */ 692 + mdelay(5); 693 + subdevice_map[i] = 0; 694 + } 695 695 696 - /* setup maple ports */ 697 - for (i = 0; i < MAPLE_PORTS; i++) { 698 - mdev[i] = maple_alloc_dev(i, 0); 699 - if (!mdev[i]) { 700 - while (i-- > 0) 701 - maple_free_dev(mdev[i]); 702 - goto cleanup_cache; 703 - } 704 - mdev[i]->registered = 0; 705 - mdev[i]->mq->command = MAPLE_COMMAND_DEVINFO; 706 - mdev[i]->mq->length = 0; 707 - maple_attach_driver(mdev[i]); 708 - maple_add_packet(mdev[i]->mq); 709 - subdevice_map[i] = 0; 710 - } 696 + realscan = 1; 697 + /* setup maplebus hardware */ 698 + maplebus_dma_reset(); 699 + /* initial detection */ 700 + maple_send(); 701 + maple_pnp_time = jiffies; 702 + printk(KERN_INFO "Maple bus core now registered.\n"); 711 703 712 - /* setup maplebus hardware */ 713 - maplebus_dma_reset(); 714 - 715 - /* initial detection */ 716 - maple_send(); 717 - 718 - maple_pnp_time = jiffies; 719 - 720 - printk(KERN_INFO "Maple bus core now registered.\n"); 721 - 722 - return 0; 704 + return 0; 723 705 724 706 cleanup_cache: 725 - kmem_cache_destroy(maple_queue_cache); 707 + kmem_cache_destroy(maple_queue_cache); 726 708 727 709 cleanup_bothirqs: 728 - free_irq(HW_EVENT_VSYNC, 0); 710 + free_irq(HW_EVENT_VSYNC, 0); 729 711 730 712 cleanup_irq: 731 - free_irq(HW_EVENT_MAPLE_DMA, 0); 713 + free_irq(HW_EVENT_MAPLE_DMA, 0); 732 714 733 715 cleanup_dma: 734 - free_pages((unsigned long) maple_sendbuf, MAPLE_DMA_PAGES); 716 + free_pages((unsigned long) maple_sendbuf, MAPLE_DMA_PAGES); 735 717 736 718 cleanup_basic: 737 - driver_unregister(&maple_dummy_driver.drv); 719 + driver_unregister(&maple_dummy_driver.drv); 738 720 739 721 cleanup_bus: 740 - bus_unregister(&maple_bus_type); 722 + bus_unregister(&maple_bus_type); 741 723 742 724 cleanup_device: 743 - device_unregister(&maple_bus); 725 + device_unregister(&maple_bus); 744 726 745 727 cleanup: 746 - printk(KERN_INFO "Maple bus registration failed\n"); 747 - return retval; 728 + printk(KERN_INFO "Maple bus registration failed\n"); 729 + return retval; 748 730 } 749 - subsys_initcall(maple_bus_init); 731 + /* Push init to later to ensure hardware gets detected */ 732 + fs_initcall(maple_bus_init);
+1 -1
include/asm-sh/bugs.h
··· 39 39 *p++ = '4'; 40 40 *p++ = 'a'; 41 41 break; 42 - case CPU_SH7343 ... CPU_SH7722: 42 + case CPU_SH7343 ... CPU_SH7366: 43 43 *p++ = '4'; 44 44 *p++ = 'a'; 45 45 *p++ = 'l';
+3 -1
include/asm-sh/cpu-sh4/freq.h
··· 10 10 #ifndef __ASM_CPU_SH4_FREQ_H 11 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 14 #define FRQCR 0xa4150000 15 15 #define VCLKCR 0xa4150004 16 16 #define SCLKACR 0xa4150008 17 17 #define SCLKBCR 0xa415000c 18 + #if defined(CONFIG_CPU_SUBTYPE_SH7722) 18 19 #define IrDACLKCR 0xa4150010 20 + #endif 19 21 #elif defined(CONFIG_CPU_SUBTYPE_SH7763) || \ 20 22 defined(CONFIG_CPU_SUBTYPE_SH7780) 21 23 #define FRQCR 0xffc80000
+2 -4
include/asm-sh/cpu-sh5/cacheflush.h
··· 3 3 4 4 #ifndef __ASSEMBLY__ 5 5 6 - #include <asm/page.h> 7 - 8 6 struct vm_area_struct; 9 7 struct page; 10 8 struct mm_struct; 11 9 12 10 extern void flush_cache_all(void); 13 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 13 extern void flush_cache_range(struct vm_area_struct *vma, unsigned long start, 16 14 unsigned long end); 17 15 extern void flush_cache_page(struct vm_area_struct *vma, unsigned long addr, unsigned long pfn); ··· 25 27 #define flush_dcache_mmap_unlock(mapping) do { } while (0) 26 28 27 29 #define flush_icache_page(vma, page) do { } while (0) 28 - #define p3_cache_init() do { } while (0) 30 + void p3_cache_init(void); 29 31 30 32 #endif /* __ASSEMBLY__ */ 31 33
-6
include/asm-sh/cpu-sh5/mmu_context.h
··· 16 16 /* This has to be a common function because the next location to fill 17 17 * information is shared. */ 18 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 19 #endif /* __ASSEMBLY__ */ 26 20 27 21 #endif /* __ASM_SH_CPU_SH5_MMU_CONTEXT_H */
+3 -25
include/asm-sh/hp6xx.h
··· 10 10 * 11 11 */ 12 12 13 - #define HP680_BTN_IRQ 32 /* IRQ0_IRQ */ 14 - #define HP680_TS_IRQ 35 /* IRQ3_IRQ */ 15 - #define HP680_HD64461_IRQ 36 /* IRQ4_IRQ */ 13 + #define HP680_BTN_IRQ 32 /* IRQ0_IRQ */ 14 + #define HP680_TS_IRQ 35 /* IRQ3_IRQ */ 15 + #define HP680_HD64461_IRQ 36 /* IRQ4_IRQ */ 16 16 17 17 #define DAC_LCD_BRIGHTNESS 0 18 18 #define DAC_SPEAKER_VOLUME 1 ··· 54 54 55 55 #define PJDR 0xa4000130 56 56 #define PKDR 0xa4000132 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 57 80 58 #endif /* __ASM_SH_HP6XX_H */
+16 -6
include/asm-sh/io.h
··· 38 38 */ 39 39 #define __IO_PREFIX generic 40 40 #include <asm/io_generic.h> 41 + #include <asm/io_trapped.h> 41 42 42 43 #define maybebadio(port) \ 43 44 printk(KERN_ERR "bad PC-like io %s:%u for port 0x%lx at 0x%08x\n", \ ··· 182 181 #define iowrite32(v,a) writel((v),(a)) 183 182 #define iowrite32be(v,a) __raw_writel(cpu_to_be32((v)),(a)) 184 183 185 - #define ioread8_rep(a,d,c) insb((a),(d),(c)) 186 - #define ioread16_rep(a,d,c) insw((a),(d),(c)) 187 - #define ioread32_rep(a,d,c) insl((a),(d),(c)) 184 + #define ioread8_rep(a, d, c) readsb((a), (d), (c)) 185 + #define ioread16_rep(a, d, c) readsw((a), (d), (c)) 186 + #define ioread32_rep(a, d, c) readsl((a), (d), (c)) 188 187 189 - #define iowrite8_rep(a,s,c) outsb((a),(s),(c)) 190 - #define iowrite16_rep(a,s,c) outsw((a),(s),(c)) 191 - #define iowrite32_rep(a,s,c) outsl((a),(s),(c)) 188 + #define iowrite8_rep(a, s, c) writesb((a), (s), (c)) 189 + #define iowrite16_rep(a, s, c) writesw((a), (s), (c)) 190 + #define iowrite32_rep(a, s, c) writesl((a), (s), (c)) 192 191 193 192 #define mmiowb() wmb() /* synco on SH-4A, otherwise a nop */ 194 193 ··· 207 206 208 207 generic_io_base = pbase; 209 208 } 209 + 210 + #define __ioport_map(p, n) sh_mv.mv_ioport_map((p), (n)) 210 211 211 212 /* We really want to try and get these to memcpy etc */ 212 213 extern void memcpy_fromio(void *, volatile void __iomem *, unsigned long); ··· 312 309 { 313 310 #ifdef CONFIG_SUPERH32 314 311 unsigned long last_addr = offset + size - 1; 312 + #endif 313 + void __iomem *ret; 315 314 315 + ret = __ioremap_trapped(offset, size); 316 + if (ret) 317 + return ret; 318 + 319 + #ifdef CONFIG_SUPERH32 316 320 /* 317 321 * For P1 and P2 space this is trivial, as everything is already 318 322 * mapped. Uncached access for P1 addresses are done through P2.
+58
include/asm-sh/io_trapped.h
··· 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 */
+4
include/asm-sh/ioctls.h
··· 78 78 #define TIOCSBRK _IO('T', 39) /* 0x5427 */ /* BSD compatibility */ 79 79 #define TIOCCBRK _IO('T', 40) /* 0x5428 */ /* BSD compatibility */ 80 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 85 #define TIOCGPTN _IOR('T',0x30, unsigned int) /* Get Pty Number (of pty-mux device) */ 82 86 #define TIOCSPTLCK _IOW('T',0x31, int) /* Lock/unlock Pty */ 83 87
+4
include/asm-sh/irq.h
··· 50 50 # define irq_ctx_exit(cpu) do { } while (0) 51 51 #endif 52 52 53 + #ifdef CONFIG_CPU_SH5 54 + #include <asm/cpu/irq.h> 55 + #endif 56 + 53 57 #endif /* __ASM_SH_IRQ_H */
+3
include/asm-sh/mmu_context_64.h
··· 66 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 72 /* No spare register to twiddle, so use a software cache */ 70 73 extern pgd_t *mmu_pdtp_cache; 71 74
+5 -2
include/asm-sh/page.h
··· 55 55 extern void copy_page(void *to, void *from); 56 56 57 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 60 struct page; 60 61 struct vm_area_struct; 61 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 66 extern void copy_user_highpage(struct page *to, struct page *from, 64 67 unsigned long vaddr, struct vm_area_struct *vma); 65 68 #define __HAVE_ARCH_COPY_USER_HIGHPAGE
+13
include/asm-sh/pgtable_64.h
··· 138 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 149 * Default flags for a Kernel page. 142 150 * This is fundametally also SHARED because the main use of this define 143 151 * (other than for PGD/PMD entries) is for the VMALLOC pool which is ··· 186 178 #define PAGE_RWX __pgprot(_PAGE_COMMON | _PAGE_READ | \ 187 179 _PAGE_WRITE | _PAGE_EXECUTE) 188 180 #define PAGE_KERNEL __pgprot(_KERNPG_TABLE) 181 + 182 + #define PAGE_KERNEL_NOCACHE \ 183 + __pgprot(_PAGE_PRESENT | _PAGE_READ | _PAGE_WRITE | \ 184 + _PAGE_EXECUTE | _PAGE_ACCESSED | \ 185 + _PAGE_DIRTY | _PAGE_SHARED) 189 186 190 187 /* Make it a device mapping for maximum safety (e.g. for mapping device 191 188 registers into user-space via /dev/map). */
+1 -1
include/asm-sh/processor.h
··· 33 33 CPU_SH7763, CPU_SH7770, CPU_SH7780, CPU_SH7781, CPU_SH7785, CPU_SHX3, 34 34 35 35 /* SH4AL-DSP types */ 36 - CPU_SH7343, CPU_SH7722, 36 + CPU_SH7343, CPU_SH7722, CPU_SH7366, 37 37 38 38 /* SH-5 types */ 39 39 CPU_SH5_101, CPU_SH5_103,
-3
include/asm-sh/r7780rp.h
··· 195 195 unsigned char *highlander_init_irq_r7780rp(void); 196 196 unsigned char *highlander_init_irq_r7785rp(void); 197 197 198 - #define __IO_PREFIX r7780rp 199 - #include <asm/io_generic.h> 200 - 201 198 #endif /* __ASM_SH_RENESAS_R7780RP */
-3
include/asm-sh/rts7751r2d.h
··· 67 67 void init_rts7751r2d_IRQ(void); 68 68 int rts7751r2d_irq_demux(int); 69 69 70 - #define __IO_PREFIX rts7751r2d 71 - #include <asm/io_generic.h> 72 - 73 70 #endif /* __ASM_SH_RENESAS_RTS7751R2D */
+5
include/asm-sh/system.h
··· 182 182 183 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 190 #ifdef CONFIG_SUPERH32 186 191 # include "system_32.h" 187 192 #else
+3
include/asm-sh/system_32.h
··· 96 96 : "=&r" (__dummy)); \ 97 97 } while (0) 98 98 99 + int handle_unaligned_access(opcode_t instruction, struct pt_regs *regs, 100 + struct mem_access *ma); 101 + 99 102 #endif /* __ASM_SH_SYSTEM_32_H */
+4 -1
include/asm-sh/termbits.h
··· 140 140 #define HUPCL 0002000 141 141 #define CLOCAL 0004000 142 142 #define CBAUDEX 0010000 143 + #define BOTHER 0010000 143 144 #define B57600 0010001 144 145 #define B115200 0010002 145 146 #define B230400 0010003 ··· 156 155 #define B3000000 0010015 157 156 #define B3500000 0010016 158 157 #define B4000000 0010017 159 - #define CIBAUD 002003600000 /* input baud rate (not used) */ 158 + #define CIBAUD 002003600000 /* input baud rate */ 160 159 #define CMSPAR 010000000000 /* mark or space (stick) parity */ 161 160 #define CRTSCTS 020000000000 /* flow control */ 161 + 162 + #define IBSHIFT 16 /* Shift from CBAUD to CIBAUD */ 162 163 163 164 /* c_lflag bits */ 164 165 #define ISIG 0000001
+4 -2
include/asm-sh/termios.h
··· 80 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)) 84 - #define kernel_termios_to_user_termios(u, k) copy_to_user(u, k, 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 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 88 #endif /* __KERNEL__ */ 87 89
+1
include/asm-sh/tlb.h
··· 20 20 */ 21 21 #define tlb_flush(tlb) flush_tlb_mm((tlb)->mm) 22 22 23 + #include <linux/pagemap.h> 23 24 #include <asm-generic/tlb.h> 24 25 25 26 #endif /* __ASSEMBLY__ */
+29
include/asm-sh/uaccess.h
··· 1 + #ifndef __ASM_SH_UACCESS_H 2 + #define __ASM_SH_UACCESS_H 3 + 1 4 #ifdef CONFIG_SUPERH32 2 5 # include "uaccess_32.h" 3 6 #else 4 7 # include "uaccess_64.h" 5 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 */
+3 -21
include/asm-sh/uaccess_32.h
··· 10 10 * Copyright (C) 1996, 1997, 1998 by Ralf Baechle 11 11 * and i386 version. 12 12 */ 13 - #ifndef __ASM_SH_UACCESS_H 14 - #define __ASM_SH_UACCESS_H 13 + #ifndef __ASM_SH_UACCESS_32_H 14 + #define __ASM_SH_UACCESS_32_H 15 15 16 16 #include <linux/errno.h> 17 17 #include <linux/sched.h> ··· 302 302 /* Return the number of bytes NOT copied */ 303 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 306 static __always_inline unsigned long 325 307 __copy_from_user(void *to, const void __user *from, unsigned long n) ··· 489 507 490 508 extern int fixup_exception(struct pt_regs *regs); 491 509 492 - #endif /* __ASM_SH_UACCESS_H */ 510 + #endif /* __ASM_SH_UACCESS_32_H */
-19
include/asm-sh/uaccess_64.h
··· 202 202 /* XXX: should be such that: 4byte and the rest. */ 203 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 205 #define copy_to_user_ret(to,from,n,retval) ({ \ 215 206 if (copy_to_user(to,from,n)) \ 216 207 return retval; \ ··· 215 224 if (__copy_to_user(to,from,n)) \ 216 225 return retval; \ 217 226 }) 218 - 219 - #define copy_from_user(to,from,n) ({ \ 220 - void *__copy_to = (void *) (to); \ 221 - void *__copy_from = (void *) (from); \ 222 - __kernel_size_t __copy_size = (__kernel_size_t) (n); \ 223 - __kernel_size_t __copy_res; \ 224 - if(__copy_size && __access_ok((unsigned long)__copy_from, __copy_size)) { \ 225 - __copy_res = __copy_user(__copy_to, __copy_from, __copy_size); \ 226 - } else __copy_res = __copy_size; \ 227 - __copy_res; }) 228 227 229 228 #define copy_from_user_ret(to,from,n,retval) ({ \ 230 229 if (copy_from_user(to,from,n)) \
+4 -2
include/asm-sh/unistd_32.h
··· 330 330 #define __NR_epoll_pwait 319 331 331 #define __NR_utimensat 320 332 332 #define __NR_signalfd 321 333 - /* #define __NR_timerfd 322 removed */ 333 + #define __NR_timerfd_create 322 334 334 #define __NR_eventfd 323 335 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 341 #ifdef __KERNEL__ 340 342
+4 -2
include/asm-sh/unistd_64.h
··· 90 90 #define __NR_sigpending 73 91 91 #define __NR_sethostname 74 92 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 94 #define __NR_getrusage 77 95 95 #define __NR_gettimeofday 78 96 96 #define __NR_settimeofday 79 ··· 370 370 #define __NR_epoll_pwait 347 371 371 #define __NR_utimensat 348 372 372 #define __NR_signalfd 349 373 - /* #define __NR_timerfd 350 removed */ 373 + #define __NR_timerfd_create 350 374 374 #define __NR_eventfd 351 375 375 #define __NR_fallocate 352 376 + #define __NR_timerfd_settime 353 377 + #define __NR_timerfd_gettime 354 376 378 377 379 #ifdef __KERNEL__ 378 380
+50 -50
include/linux/maple.h
··· 7 7 8 8 /* Maple Bus command and response codes */ 9 9 enum maple_code { 10 - MAPLE_RESPONSE_FILEERR = -5, 11 - MAPLE_RESPONSE_AGAIN = -4, /* request should be retransmitted */ 12 - MAPLE_RESPONSE_BADCMD = -3, 13 - MAPLE_RESPONSE_BADFUNC = -2, 14 - MAPLE_RESPONSE_NONE = -1, /* unit didn't respond at all */ 15 - MAPLE_COMMAND_DEVINFO = 1, 16 - MAPLE_COMMAND_ALLINFO = 2, 17 - MAPLE_COMMAND_RESET = 3, 18 - MAPLE_COMMAND_KILL = 4, 19 - MAPLE_RESPONSE_DEVINFO = 5, 20 - MAPLE_RESPONSE_ALLINFO = 6, 21 - MAPLE_RESPONSE_OK = 7, 22 - MAPLE_RESPONSE_DATATRF = 8, 23 - MAPLE_COMMAND_GETCOND = 9, 24 - MAPLE_COMMAND_GETMINFO = 10, 25 - MAPLE_COMMAND_BREAD = 11, 26 - MAPLE_COMMAND_BWRITE = 12, 27 - MAPLE_COMMAND_SETCOND = 14 10 + MAPLE_RESPONSE_FILEERR = -5, 11 + MAPLE_RESPONSE_AGAIN = -4, /* request should be retransmitted */ 12 + MAPLE_RESPONSE_BADCMD = -3, 13 + MAPLE_RESPONSE_BADFUNC = -2, 14 + MAPLE_RESPONSE_NONE = -1, /* unit didn't respond at all */ 15 + MAPLE_COMMAND_DEVINFO = 1, 16 + MAPLE_COMMAND_ALLINFO = 2, 17 + MAPLE_COMMAND_RESET = 3, 18 + MAPLE_COMMAND_KILL = 4, 19 + MAPLE_RESPONSE_DEVINFO = 5, 20 + MAPLE_RESPONSE_ALLINFO = 6, 21 + MAPLE_RESPONSE_OK = 7, 22 + MAPLE_RESPONSE_DATATRF = 8, 23 + MAPLE_COMMAND_GETCOND = 9, 24 + MAPLE_COMMAND_GETMINFO = 10, 25 + MAPLE_COMMAND_BREAD = 11, 26 + MAPLE_COMMAND_BWRITE = 12, 27 + MAPLE_COMMAND_SETCOND = 14 28 28 }; 29 29 30 30 struct mapleq { 31 - struct list_head list; 32 - struct maple_device *dev; 33 - void *sendbuf, *recvbuf, *recvbufdcsp; 34 - unsigned char length; 35 - enum maple_code command; 31 + struct list_head list; 32 + struct maple_device *dev; 33 + void *sendbuf, *recvbuf, *recvbufdcsp; 34 + unsigned char length; 35 + enum maple_code command; 36 36 }; 37 37 38 38 struct maple_devinfo { 39 - unsigned long function; 40 - unsigned long function_data[3]; 41 - unsigned char area_code; 42 - unsigned char connector_directon; 43 - char product_name[31]; 44 - char product_licence[61]; 45 - unsigned short standby_power; 46 - unsigned short max_power; 39 + unsigned long function; 40 + unsigned long function_data[3]; 41 + unsigned char area_code; 42 + unsigned char connector_direction; 43 + char product_name[31]; 44 + char product_licence[61]; 45 + unsigned short standby_power; 46 + unsigned short max_power; 47 47 }; 48 48 49 49 struct maple_device { 50 - struct maple_driver *driver; 51 - struct mapleq *mq; 52 - void *private_data; 53 - void (*callback) (struct mapleq * mq); 54 - unsigned long when, interval, function; 55 - struct maple_devinfo devinfo; 56 - unsigned char port, unit; 57 - char product_name[32]; 58 - char product_licence[64]; 59 - int registered; 60 - struct device dev; 50 + struct maple_driver *driver; 51 + struct mapleq *mq; 52 + void *private_data; 53 + void (*callback) (struct mapleq * mq); 54 + unsigned long when, interval, function; 55 + struct maple_devinfo devinfo; 56 + unsigned char port, unit; 57 + char product_name[32]; 58 + char product_licence[64]; 59 + struct device dev; 61 60 }; 62 61 63 62 struct maple_driver { 64 - unsigned long function; 65 - int (*connect) (struct maple_device * dev); 66 - void (*disconnect) (struct maple_device * dev); 67 - struct device_driver drv; 63 + unsigned long function; 64 + int (*connect) (struct maple_device * dev); 65 + void (*disconnect) (struct maple_device * dev); 66 + struct device_driver drv; 67 + int registered; 68 68 }; 69 69 70 70 void maple_getcond_callback(struct maple_device *dev, 71 - void (*callback) (struct mapleq * mq), 72 - unsigned long interval, 73 - unsigned long function); 71 + void (*callback) (struct mapleq * mq), 72 + unsigned long interval, 73 + unsigned long function); 74 74 int maple_driver_register(struct device_driver *drv); 75 75 void maple_add_packet(struct mapleq *mq); 76 76 77 77 #define to_maple_dev(n) container_of(n, struct maple_device, dev) 78 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 */