From 1a836f002a0f42b88e44a41377ca4dda76d9713f Mon Sep 17 00:00:00 2001 From: Eric Anholt Date: Thu, 18 Nov 2010 09:32:58 +0800 Subject: [PATCH] --- yaml --- r: 223010 b: refs/heads/master c: 220cad3cbf553f893432919b458da36489373fc6 h: refs/heads/master v: v3 --- [refs] | 2 +- .../ABI/testing/sysfs-platform-asus-laptop | 16 +- .../ABI/testing/sysfs-platform-eeepc-wmi | 10 - trunk/Documentation/filesystems/vfs.txt | 9 +- trunk/Makefile | 2 +- trunk/arch/arm/Kconfig | 2 +- trunk/arch/arm/boot/Makefile | 5 + trunk/arch/arm/boot/bootp/init.S | 2 - trunk/arch/arm/boot/compressed/head.S | 13 +- trunk/arch/arm/common/gic.c | 40 +- trunk/arch/arm/kernel/entry-armv.S | 2 +- trunk/arch/arm/kernel/head.S | 7 - trunk/arch/arm/kernel/relocate_kernel.S | 2 - trunk/arch/arm/mach-cns3xxx/pcie.c | 2 +- trunk/arch/arm/mach-realview/headsmp.S | 1 - trunk/arch/arm/mach-s3c2412/Kconfig | 2 +- trunk/arch/arm/mach-s3c2416/Kconfig | 3 - trunk/arch/arm/mach-s3c2440/Kconfig | 4 - trunk/arch/arm/mach-s3c2440/s3c2440.c | 11 +- trunk/arch/arm/mach-s3c2440/s3c2442.c | 14 - trunk/arch/arm/mach-s3c2443/Kconfig | 1 - .../arm/mach-tegra/include/mach/debug-macro.S | 4 +- trunk/arch/arm/mach-vexpress/headsmp.S | 1 - trunk/arch/arm/mm/proc-v7.S | 4 +- trunk/arch/arm/plat-iop/time.c | 3 +- trunk/arch/arm/plat-s3c24xx/cpu.c | 8 +- trunk/arch/arm/plat-s3c24xx/gpiolib.c | 2 + .../arm/plat-s3c24xx/include/plat/s3c244x.h | 7 +- trunk/arch/arm/plat-samsung/gpio-config.c | 47 +- .../include/plat/gpio-cfg-helpers.h | 11 - trunk/arch/arm/vfp/vfphw.S | 1 - trunk/arch/mn10300/include/asm/syscall.h | 117 ---- trunk/arch/mn10300/kernel/gdb-io-serial.c | 3 +- trunk/arch/mn10300/kernel/gdb-io-ttysm.c | 3 +- trunk/arch/mn10300/kernel/gdb-stub.c | 3 +- trunk/arch/parisc/kernel/irq.c | 7 +- trunk/arch/parisc/kernel/signal.c | 9 +- trunk/arch/s390/kernel/vtime.c | 19 - trunk/arch/sh/boards/mach-ecovec24/setup.c | 34 +- trunk/arch/sh/boards/mach-se/7724/setup.c | 47 +- trunk/arch/sh/include/asm/cacheflush.h | 2 +- trunk/arch/sh/include/cpu-sh4/cpu/sh7724.h | 3 - trunk/arch/sh/kernel/cpu/sh4a/clock-sh7724.c | 44 +- trunk/arch/sh/mm/cache-sh4.c | 4 +- trunk/arch/sh/mm/cache-sh7705.c | 2 +- trunk/arch/sh/mm/cache.c | 14 +- trunk/arch/sh/mm/kmap.c | 2 +- trunk/arch/x86/pci/xen.c | 27 +- trunk/arch/x86/xen/enlighten.c | 4 + trunk/arch/x86/xen/mmu.c | 2 + trunk/arch/x86/xen/platform-pci-unplug.c | 2 +- trunk/arch/x86/xen/setup.c | 41 +- trunk/arch/x86/xen/suspend.c | 1 - trunk/arch/x86/xen/xen-ops.h | 2 +- trunk/drivers/dma/shdma.c | 1 - trunk/drivers/gpio/cs5535-gpio.c | 16 +- trunk/drivers/gpu/drm/i915/i915_reg.h | 1 + trunk/drivers/gpu/drm/i915/intel_display.c | 4 +- trunk/drivers/hid/hid-core.c | 1 - trunk/drivers/hid/hid-egalax.c | 2 +- trunk/drivers/hid/hid-input.c | 21 +- trunk/drivers/hid/hid-tmff.c | 2 - trunk/drivers/i2c/Kconfig | 3 +- trunk/drivers/i2c/algos/Kconfig | 14 +- trunk/drivers/input/joystick/turbografx.c | 1 - trunk/drivers/input/keyboard/Kconfig | 16 - trunk/drivers/input/keyboard/Makefile | 1 - .../drivers/input/keyboard/gpio_keys_polled.c | 261 -------- trunk/drivers/input/mouse/synaptics.h | 3 +- trunk/drivers/input/serio/gscps2.c | 2 +- trunk/drivers/input/tablet/wacom_wac.c | 9 - .../input/touchscreen/usbtouchscreen.c | 1 - trunk/drivers/leds/Kconfig | 50 +- trunk/drivers/macintosh/Kconfig | 1 - trunk/drivers/media/common/tuners/Kconfig | 8 +- trunk/drivers/media/dvb/frontends/Kconfig | 5 +- trunk/drivers/media/video/Kconfig | 2 +- trunk/drivers/mtd/ubi/io.c | 37 +- trunk/drivers/mtd/ubi/scan.c | 4 - trunk/drivers/parisc/dino.c | 1 + trunk/drivers/parisc/eisa.c | 3 +- trunk/drivers/parisc/gsc.c | 3 +- trunk/drivers/parisc/iosapic.c | 8 - trunk/drivers/parisc/led.c | 17 +- trunk/drivers/parisc/superio.c | 3 +- trunk/drivers/pcmcia/soc_common.c | 1 - trunk/drivers/platform/x86/asus-laptop.c | 97 +-- trunk/drivers/platform/x86/eeepc-wmi.c | 4 +- trunk/drivers/platform/x86/hp-wmi.c | 2 - trunk/drivers/platform/x86/ibm_rtl.c | 34 +- trunk/drivers/platform/x86/msi-wmi.c | 16 +- trunk/drivers/platform/x86/thinkpad_acpi.c | 1 + trunk/drivers/platform/x86/toshiba_acpi.c | 1 - trunk/drivers/platform/x86/wmi.c | 2 +- trunk/drivers/s390/cio/css.c | 2 +- trunk/drivers/video/da8xx-fb.c | 14 +- trunk/drivers/video/fbcmap.c | 1 - trunk/drivers/video/geode/lxfb.h | 4 +- trunk/drivers/video/geode/lxfb_ops.c | 20 +- trunk/drivers/xen/balloon.c | 12 +- trunk/drivers/xen/events.c | 109 +--- trunk/drivers/xen/manage.c | 1 - trunk/fs/autofs4/root.c | 12 +- trunk/fs/ocfs2/cluster/heartbeat.c | 14 +- trunk/fs/ocfs2/dcache.c | 1 + trunk/fs/ocfs2/dlm/dlmdomain.c | 2 +- trunk/fs/ocfs2/ocfs2.h | 6 +- trunk/fs/ocfs2/stack_user.c | 2 +- trunk/fs/proc/base.c | 2 +- trunk/fs/reiserfs/xattr_acl.c | 6 +- trunk/include/linux/gfp.h | 4 +- trunk/include/linux/gpio_keys.h | 2 - trunk/include/linux/input.h | 25 +- trunk/include/linux/memory_hotplug.h | 6 - trunk/include/linux/vmalloc.h | 2 + trunk/include/xen/events.h | 7 +- trunk/include/xen/interface/physdev.h | 10 - trunk/kernel/exit.c | 9 - trunk/kernel/irq/proc.c | 2 +- trunk/kernel/power/hibernate.c | 22 +- trunk/kernel/power/suspend.c | 5 +- trunk/kernel/power/swap.c | 53 +- trunk/kernel/power/user.c | 2 - trunk/mm/hugetlb.c | 3 +- trunk/mm/ksm.c | 7 +- trunk/mm/memory-failure.c | 8 +- trunk/mm/memory_hotplug.c | 31 +- trunk/mm/mempolicy.c | 3 - trunk/mm/page_alloc.c | 19 +- trunk/mm/slub.c | 4 +- trunk/mm/vmalloc.c | 28 +- trunk/mm/vmstat.c | 4 +- trunk/net/mac80211/Kconfig | 2 +- trunk/scripts/kconfig/expr.h | 1 - trunk/scripts/kconfig/lkc.h | 1 - trunk/scripts/kconfig/menu.c | 11 - trunk/scripts/kconfig/zconf.gperf | 1 - trunk/scripts/kconfig/zconf.hash.c_shipped | 122 ++-- trunk/scripts/kconfig/zconf.tab.c_shipped | 570 +++++++++--------- trunk/scripts/kconfig/zconf.y | 21 +- trunk/sound/core/oss/pcm_oss.c | 19 +- trunk/sound/pci/hda/patch_realtek.c | 1 + trunk/sound/pci/hda/patch_sigmatel.c | 2 - trunk/sound/soc/codecs/wm8731.c | 2 +- trunk/sound/soc/fsl/mpc8610_hpcd.c | 1 - trunk/sound/soc/fsl/p1022_ds.c | 1 - trunk/sound/soc/nuc900/nuc900-ac97.c | 15 +- trunk/sound/soc/nuc900/nuc900-audio.h | 2 - trunk/sound/soc/nuc900/nuc900-pcm.c | 11 +- trunk/sound/soc/omap/Kconfig | 2 +- trunk/sound/soc/s6000/s6000-i2s.c | 2 +- trunk/sound/soc/s6000/s6000-pcm.c | 2 +- trunk/sound/soc/s6000/s6105-ipcam.c | 2 +- trunk/usr/initramfs_data.S | 5 +- 154 files changed, 829 insertions(+), 1720 deletions(-) delete mode 100644 trunk/Documentation/ABI/testing/sysfs-platform-eeepc-wmi delete mode 100644 trunk/arch/mn10300/include/asm/syscall.h delete mode 100644 trunk/drivers/input/keyboard/gpio_keys_polled.c diff --git a/[refs] b/[refs] index 145139b13ec5..2659758aa829 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: f8f5d4f11dc7d321fb372b09fc8767069a18bf30 +refs/heads/master: 220cad3cbf553f893432919b458da36489373fc6 diff --git a/trunk/Documentation/ABI/testing/sysfs-platform-asus-laptop b/trunk/Documentation/ABI/testing/sysfs-platform-asus-laptop index 41ff8ae4dee0..1d775390e856 100644 --- a/trunk/Documentation/ABI/testing/sysfs-platform-asus-laptop +++ b/trunk/Documentation/ABI/testing/sysfs-platform-asus-laptop @@ -47,20 +47,6 @@ Date: January 2007 KernelVersion: 2.6.20 Contact: "Corentin Chary" Description: - Control the wlan device. 1 means on, 0 means off. + Control the bluetooth device. 1 means on, 0 means off. This may control the led, the device or both. Users: Lapsus - -What: /sys/devices/platform/asus_laptop/wimax -Date: October 2010 -KernelVersion: 2.6.37 -Contact: "Corentin Chary" -Description: - Control the wimax device. 1 means on, 0 means off. - -What: /sys/devices/platform/asus_laptop/wwan -Date: October 2010 -KernelVersion: 2.6.37 -Contact: "Corentin Chary" -Description: - Control the wwan (3G) device. 1 means on, 0 means off. diff --git a/trunk/Documentation/ABI/testing/sysfs-platform-eeepc-wmi b/trunk/Documentation/ABI/testing/sysfs-platform-eeepc-wmi deleted file mode 100644 index e4b5fef5fadd..000000000000 --- a/trunk/Documentation/ABI/testing/sysfs-platform-eeepc-wmi +++ /dev/null @@ -1,10 +0,0 @@ -What: /sys/devices/platform/eeepc-wmi/cpufv -Date: Oct 2010 -KernelVersion: 2.6.37 -Contact: "Corentin Chary" -Description: - Change CPU clock configuration (write-only). - There are three available clock configuration: - * 0 -> Super Performance Mode - * 1 -> High Performance Mode - * 2 -> Power Saving Mode diff --git a/trunk/Documentation/filesystems/vfs.txt b/trunk/Documentation/filesystems/vfs.txt index 55c28b79d8dc..ed7e5efc06d8 100644 --- a/trunk/Documentation/filesystems/vfs.txt +++ b/trunk/Documentation/filesystems/vfs.txt @@ -660,10 +660,11 @@ struct address_space_operations { releasepage: releasepage is called on PagePrivate pages to indicate that the page should be freed if possible. ->releasepage should remove any private data from the page and clear the - PagePrivate flag. If releasepage() fails for some reason, it must - indicate failure with a 0 return value. - releasepage() is used in two distinct though related cases. The - first is when the VM finds a clean page with no active users and + PagePrivate flag. It may also remove the page from the + address_space. If this fails for some reason, it may indicate + failure with a 0 return value. + This is used in two distinct though related cases. The first + is when the VM finds a clean page with no active users and wants to make it a free page. If ->releasepage succeeds, the page will be removed from the address_space and become free. diff --git a/trunk/Makefile b/trunk/Makefile index 3d94974542ea..9e3c89030f5c 100644 --- a/trunk/Makefile +++ b/trunk/Makefile @@ -1,7 +1,7 @@ VERSION = 2 PATCHLEVEL = 6 SUBLEVEL = 37 -EXTRAVERSION = -rc5 +EXTRAVERSION = -rc4 NAME = Flesh-Eating Bats with Fangs # *DOCUMENTATION* diff --git a/trunk/arch/arm/Kconfig b/trunk/arch/arm/Kconfig index f1d9297b1050..db524e75c4a2 100644 --- a/trunk/arch/arm/Kconfig +++ b/trunk/arch/arm/Kconfig @@ -9,7 +9,7 @@ config ARM select GENERIC_ATOMIC64 if (!CPU_32v6K || !AEABI) select HAVE_OPROFILE if (HAVE_PERF_EVENTS) select HAVE_ARCH_KGDB - select HAVE_KPROBES if (!XIP_KERNEL && !THUMB2_KERNEL) + select HAVE_KPROBES if (!XIP_KERNEL) select HAVE_KRETPROBES if (HAVE_KPROBES) select HAVE_FUNCTION_TRACER if (!XIP_KERNEL) select HAVE_FTRACE_MCOUNT_RECORD if (!XIP_KERNEL) diff --git a/trunk/arch/arm/boot/Makefile b/trunk/arch/arm/boot/Makefile index 4d26f2c52a75..4a590f4113e2 100644 --- a/trunk/arch/arm/boot/Makefile +++ b/trunk/arch/arm/boot/Makefile @@ -70,7 +70,12 @@ else $(obj)/uImage: LOADADDR=$(ZRELADDR) endif +ifeq ($(CONFIG_THUMB2_KERNEL),y) +# Set bit 0 to 1 so that "mov pc, rx" switches to Thumb-2 mode +$(obj)/uImage: STARTADDR=$(shell echo $(LOADADDR) | sed -e "s/.$$/1/") +else $(obj)/uImage: STARTADDR=$(LOADADDR) +endif $(obj)/uImage: $(obj)/zImage FORCE $(call if_changed,uimage) diff --git a/trunk/arch/arm/boot/bootp/init.S b/trunk/arch/arm/boot/bootp/init.S index 78b508075161..8b0de41c3dcb 100644 --- a/trunk/arch/arm/boot/bootp/init.S +++ b/trunk/arch/arm/boot/bootp/init.S @@ -73,8 +73,6 @@ move: ldmia r4!, {r7 - r10} @ move 32-bytes at a time .size _start, . - _start - .align - .type data,#object data: .word initrd_start @ source initrd address .word initrd_phys @ destination initrd address diff --git a/trunk/arch/arm/boot/compressed/head.S b/trunk/arch/arm/boot/compressed/head.S index 7193884ed8b0..9be21ba648cd 100644 --- a/trunk/arch/arm/boot/compressed/head.S +++ b/trunk/arch/arm/boot/compressed/head.S @@ -125,13 +125,9 @@ wait: mrc p14, 0, pc, c0, c1, 0 * sort out different calling conventions */ .align - .arm @ Always enter in ARM state start: .type start,#function - THUMB( adr r12, BSYM(1f) ) - THUMB( bx r12 ) - THUMB( .rept 6 ) - ARM( .rept 8 ) + .rept 8 mov r0, r0 .endr @@ -139,7 +135,6 @@ start: .word 0x016f2818 @ Magic numbers to help the loader .word start @ absolute load/run zImage address .word _edata @ zImage end address - THUMB( .thumb ) 1: mov r7, r1 @ save architecture ID mov r8, r2 @ save atags pointer @@ -179,8 +174,7 @@ not_angel: ldr sp, [r0, #28] #ifdef CONFIG_AUTO_ZRELADDR @ determine final kernel image address - mov r4, pc - and r4, r4, #0xf8000000 + and r4, pc, #0xf8000000 add r4, r4, #TEXT_OFFSET #else ldr r4, =zreladdr @@ -451,8 +445,7 @@ __setup_mmu: sub r3, r4, #16384 @ Page directory size */ mov r1, #0x1e orr r1, r1, #3 << 10 - mov r2, pc - mov r2, r2, lsr #20 + mov r2, pc, lsr #20 orr r1, r1, r2, lsl #20 add r0, r3, r2, lsl #2 str r1, [r0], #4 diff --git a/trunk/arch/arm/common/gic.c b/trunk/arch/arm/common/gic.c index e6388dcd8cfa..772f95f1aecd 100644 --- a/trunk/arch/arm/common/gic.c +++ b/trunk/arch/arm/common/gic.c @@ -146,15 +146,9 @@ static int gic_set_cpu(unsigned int irq, const struct cpumask *mask_val) unsigned int shift = (irq % 4) * 8; unsigned int cpu = cpumask_first(mask_val); u32 val; - struct irq_desc *desc; spin_lock(&irq_controller_lock); - desc = irq_to_desc(irq); - if (desc == NULL) { - spin_unlock(&irq_controller_lock); - return -EINVAL; - } - desc->node = cpu; + irq_desc[irq].node = cpu; val = readl(reg) & ~(0xff << shift); val |= 1 << (cpu + shift); writel(val, reg); @@ -216,7 +210,7 @@ void __init gic_cascade_irq(unsigned int gic_nr, unsigned int irq) void __init gic_dist_init(unsigned int gic_nr, void __iomem *base, unsigned int irq_start) { - unsigned int gic_irqs, irq_limit, i; + unsigned int max_irq, i; u32 cpumask = 1 << smp_processor_id(); if (gic_nr >= MAX_GIC_NR) @@ -232,49 +226,47 @@ void __init gic_dist_init(unsigned int gic_nr, void __iomem *base, /* * Find out how many interrupts are supported. + */ + max_irq = readl(base + GIC_DIST_CTR) & 0x1f; + max_irq = (max_irq + 1) * 32; + + /* * The GIC only supports up to 1020 interrupt sources. + * Limit this to either the architected maximum, or the + * platform maximum. */ - gic_irqs = readl(base + GIC_DIST_CTR) & 0x1f; - gic_irqs = (gic_irqs + 1) * 32; - if (gic_irqs > 1020) - gic_irqs = 1020; + if (max_irq > max(1020, NR_IRQS)) + max_irq = max(1020, NR_IRQS); /* * Set all global interrupts to be level triggered, active low. */ - for (i = 32; i < gic_irqs; i += 16) + for (i = 32; i < max_irq; i += 16) writel(0, base + GIC_DIST_CONFIG + i * 4 / 16); /* * Set all global interrupts to this CPU only. */ - for (i = 32; i < gic_irqs; i += 4) + for (i = 32; i < max_irq; i += 4) writel(cpumask, base + GIC_DIST_TARGET + i * 4 / 4); /* * Set priority on all global interrupts. */ - for (i = 32; i < gic_irqs; i += 4) + for (i = 32; i < max_irq; i += 4) writel(0xa0a0a0a0, base + GIC_DIST_PRI + i * 4 / 4); /* * Disable all interrupts. Leave the PPI and SGIs alone * as these enables are banked registers. */ - for (i = 32; i < gic_irqs; i += 32) + for (i = 32; i < max_irq; i += 32) writel(0xffffffff, base + GIC_DIST_ENABLE_CLEAR + i * 4 / 32); - /* - * Limit number of interrupts registered to the platform maximum - */ - irq_limit = gic_data[gic_nr].irq_offset + gic_irqs; - if (WARN_ON(irq_limit > NR_IRQS)) - irq_limit = NR_IRQS; - /* * Setup the Linux IRQ subsystem. */ - for (i = irq_start; i < irq_limit; i++) { + for (i = irq_start; i < gic_data[gic_nr].irq_offset + max_irq; i++) { set_irq_chip(i, &gic_chip); set_irq_chip_data(i, &gic_data[gic_nr]); set_irq_handler(i, handle_level_irq); diff --git a/trunk/arch/arm/kernel/entry-armv.S b/trunk/arch/arm/kernel/entry-armv.S index bb96a7d4bbf5..c09e3573c5de 100644 --- a/trunk/arch/arm/kernel/entry-armv.S +++ b/trunk/arch/arm/kernel/entry-armv.S @@ -911,7 +911,7 @@ __kuser_cmpxchg: @ 0xffff0fc0 * A special ghost syscall is used for that (see traps.c). */ stmfd sp!, {r7, lr} - ldr r7, 1f @ it's 20 bits + ldr r7, =1f @ it's 20 bits swi __ARM_NR_cmpxchg ldmfd sp!, {r7, pc} 1: .word __ARM_NR_cmpxchg diff --git a/trunk/arch/arm/kernel/head.S b/trunk/arch/arm/kernel/head.S index 6bd82d25683c..dd6b369ac69c 100644 --- a/trunk/arch/arm/kernel/head.S +++ b/trunk/arch/arm/kernel/head.S @@ -85,11 +85,9 @@ ENTRY(stext) mrc p15, 0, r9, c0, c0 @ get processor id bl __lookup_processor_type @ r5=procinfo r9=cpuid movs r10, r5 @ invalid processor (r5=0)? - THUMB( it eq ) @ force fixup-able long branch encoding beq __error_p @ yes, error 'p' bl __lookup_machine_type @ r5=machinfo movs r8, r5 @ invalid machine (r5=0)? - THUMB( it eq ) @ force fixup-able long branch encoding beq __error_a @ yes, error 'a' bl __vet_atags #ifdef CONFIG_SMP_ON_UP @@ -264,7 +262,6 @@ __create_page_tables: mov pc, lr ENDPROC(__create_page_tables) .ltorg - .align __enable_mmu_loc: .long . .long __enable_mmu @@ -285,7 +282,6 @@ ENTRY(secondary_startup) bl __lookup_processor_type movs r10, r5 @ invalid processor? moveq r0, #'p' @ yes, error 'p' - THUMB( it eq ) @ force fixup-able long branch encoding beq __error_p /* @@ -312,8 +308,6 @@ ENTRY(__secondary_switched) b secondary_start_kernel ENDPROC(__secondary_switched) - .align - .type __secondary_data, %object __secondary_data: .long . @@ -419,7 +413,6 @@ __fixup_smp_on_up: mov pc, lr ENDPROC(__fixup_smp) - .align 1: .word . .word __smpalt_begin .word __smpalt_end diff --git a/trunk/arch/arm/kernel/relocate_kernel.S b/trunk/arch/arm/kernel/relocate_kernel.S index 9cf4cbf8f95b..fd26f8d65151 100644 --- a/trunk/arch/arm/kernel/relocate_kernel.S +++ b/trunk/arch/arm/kernel/relocate_kernel.S @@ -59,8 +59,6 @@ relocate_new_kernel: ldr r2,kexec_boot_atags mov pc,lr - .align - .globl kexec_start_address kexec_start_address: .long 0x0 diff --git a/trunk/arch/arm/mach-cns3xxx/pcie.c b/trunk/arch/arm/mach-cns3xxx/pcie.c index 78defd71a829..38088c36936c 100644 --- a/trunk/arch/arm/mach-cns3xxx/pcie.c +++ b/trunk/arch/arm/mach-cns3xxx/pcie.c @@ -369,7 +369,7 @@ static int __init cns3xxx_pcie_init(void) { int i; - hook_fault_code(16 + 6, cns3xxx_pcie_abort_handler, SIGBUS, 0, + hook_fault_code(16 + 6, cns3xxx_pcie_abort_handler, SIGBUS, "imprecise external abort"); for (i = 0; i < ARRAY_SIZE(cns3xxx_pcie); i++) { diff --git a/trunk/arch/arm/mach-realview/headsmp.S b/trunk/arch/arm/mach-realview/headsmp.S index b34be4554d40..4075473cf68a 100644 --- a/trunk/arch/arm/mach-realview/headsmp.S +++ b/trunk/arch/arm/mach-realview/headsmp.S @@ -35,6 +35,5 @@ pen: ldr r7, [r6] */ b secondary_startup - .align 1: .long . .long pen_release diff --git a/trunk/arch/arm/mach-s3c2412/Kconfig b/trunk/arch/arm/mach-s3c2412/Kconfig index fa2e5bffbb8e..cef6a65637bd 100644 --- a/trunk/arch/arm/mach-s3c2412/Kconfig +++ b/trunk/arch/arm/mach-s3c2412/Kconfig @@ -16,7 +16,7 @@ config CPU_S3C2412 config CPU_S3C2412_ONLY bool depends on ARCH_S3C2410 && !CPU_S3C2400 && !CPU_S3C2410 && \ - !CPU_S3C2416 && !CPU_S3C2440 && !CPU_S3C2442 && \ + !CPU_2416 && !CPU_S3C2440 && !CPU_S3C2442 && \ !CPU_S3C2443 && CPU_S3C2412 default y if CPU_S3C2412 diff --git a/trunk/arch/arm/mach-s3c2416/Kconfig b/trunk/arch/arm/mach-s3c2416/Kconfig index 27b3e7c9d613..87b9c9f003bd 100644 --- a/trunk/arch/arm/mach-s3c2416/Kconfig +++ b/trunk/arch/arm/mach-s3c2416/Kconfig @@ -35,12 +35,9 @@ menu "S3C2416 Machines" config MACH_SMDK2416 bool "SMDK2416" select CPU_S3C2416 - select MACH_SMDK select S3C_DEV_FB select S3C_DEV_HSMMC select S3C_DEV_HSMMC1 - select S3C_DEV_NAND - select S3C_DEV_USB_HOST select S3C2416_PM if PM help Say Y here if you are using an SMDK2416 diff --git a/trunk/arch/arm/mach-s3c2440/Kconfig b/trunk/arch/arm/mach-s3c2440/Kconfig index a0cb2581894f..ff024a6c0f85 100644 --- a/trunk/arch/arm/mach-s3c2440/Kconfig +++ b/trunk/arch/arm/mach-s3c2440/Kconfig @@ -18,7 +18,6 @@ config CPU_S3C2440 config CPU_S3C2442 bool select CPU_ARM920T - select S3C_GPIO_PULL_DOWN select S3C2410_CLOCK select S3C2410_GPIO select S3C2410_PM if PM @@ -179,9 +178,6 @@ config MACH_MINI2440 bool "MINI2440 development board" select CPU_S3C2440 select EEPROM_AT24 - select NEW_LEDS - select LEDS_CLASS - select LEDS_TRIGGER select LEDS_TRIGGER_BACKLIGHT select S3C_DEV_NAND select S3C_DEV_USB_HOST diff --git a/trunk/arch/arm/mach-s3c2440/s3c2440.c b/trunk/arch/arm/mach-s3c2440/s3c2440.c index f7663f731ea0..d50f3ae6173d 100644 --- a/trunk/arch/arm/mach-s3c2440/s3c2440.c +++ b/trunk/arch/arm/mach-s3c2440/s3c2440.c @@ -46,6 +46,9 @@ int __init s3c2440_init(void) { printk("S3C2440: Initialising architecture\n"); + s3c24xx_gpiocfg_default.set_pull = s3c_gpio_setpull_1up; + s3c24xx_gpiocfg_default.get_pull = s3c_gpio_getpull_1up; + /* change irq for watchdog */ s3c_device_wdt.resource[1].start = IRQ_S3C2440_WDT; @@ -55,11 +58,3 @@ int __init s3c2440_init(void) return sysdev_register(&s3c2440_sysdev); } - -void __init s3c2440_map_io(void) -{ - s3c244x_map_io(); - - s3c24xx_gpiocfg_default.set_pull = s3c_gpio_setpull_1up; - s3c24xx_gpiocfg_default.get_pull = s3c_gpio_getpull_1up; -} diff --git a/trunk/arch/arm/mach-s3c2440/s3c2442.c b/trunk/arch/arm/mach-s3c2440/s3c2442.c index ecf813546554..188ad1e57dc0 100644 --- a/trunk/arch/arm/mach-s3c2440/s3c2442.c +++ b/trunk/arch/arm/mach-s3c2440/s3c2442.c @@ -32,7 +32,6 @@ #include #include #include -#include #include #include @@ -44,11 +43,6 @@ #include #include -#include - -#include -#include -#include /* S3C2442 extended clock support */ @@ -169,11 +163,3 @@ int __init s3c2442_init(void) return sysdev_register(&s3c2442_sysdev); } - -void __init s3c2442_map_io(void) -{ - s3c244x_map_io(); - - s3c24xx_gpiocfg_default.set_pull = s3c_gpio_setpull_1down; - s3c24xx_gpiocfg_default.get_pull = s3c_gpio_getpull_1down; -} diff --git a/trunk/arch/arm/mach-s3c2443/Kconfig b/trunk/arch/arm/mach-s3c2443/Kconfig index 31babec90cec..4fef723126fa 100644 --- a/trunk/arch/arm/mach-s3c2443/Kconfig +++ b/trunk/arch/arm/mach-s3c2443/Kconfig @@ -5,7 +5,6 @@ config CPU_S3C2443 bool depends on ARCH_S3C2410 - select CPU_ARM920T select S3C2443_DMA if S3C2410_DMA select CPU_LLSERIAL_S3C2440 select SAMSUNG_CLKSRC diff --git a/trunk/arch/arm/mach-tegra/include/mach/debug-macro.S b/trunk/arch/arm/mach-tegra/include/mach/debug-macro.S index a0e7c12868bd..8ea3bffb4e00 100644 --- a/trunk/arch/arm/mach-tegra/include/mach/debug-macro.S +++ b/trunk/arch/arm/mach-tegra/include/mach/debug-macro.S @@ -21,8 +21,8 @@ #include .macro addruart, rp, rv - ldr \rp, =IO_APB_PHYS @ physical - ldr \rv, =IO_APB_VIRT @ virtual + ldreq \rp, =IO_APB_PHYS @ physical + ldrne \rv, =IO_APB_VIRT @ virtual #if defined(CONFIG_TEGRA_DEBUG_UART_NONE) #error "A debug UART must be selected in the kernel config to use DEBUG_LL" #elif defined(CONFIG_TEGRA_DEBUG_UARTA) diff --git a/trunk/arch/arm/mach-vexpress/headsmp.S b/trunk/arch/arm/mach-vexpress/headsmp.S index 7a3f0632947c..8a78ff68e1ee 100644 --- a/trunk/arch/arm/mach-vexpress/headsmp.S +++ b/trunk/arch/arm/mach-vexpress/headsmp.S @@ -35,6 +35,5 @@ pen: ldr r7, [r6] */ b secondary_startup - .align 1: .long . .long pen_release diff --git a/trunk/arch/arm/mm/proc-v7.S b/trunk/arch/arm/mm/proc-v7.S index 9b9ff5d949fd..53cbe2225153 100644 --- a/trunk/arch/arm/mm/proc-v7.S +++ b/trunk/arch/arm/mm/proc-v7.S @@ -381,7 +381,7 @@ __v7_ca9mp_proc_info: PMD_SECT_XN | \ PMD_SECT_AP_WRITE | \ PMD_SECT_AP_READ - W(b) __v7_ca9mp_setup + b __v7_ca9mp_setup .long cpu_arch_name .long cpu_elf_name .long HWCAP_SWP|HWCAP_HALF|HWCAP_THUMB|HWCAP_FAST_MULT|HWCAP_EDSP|HWCAP_TLS @@ -413,7 +413,7 @@ __v7_proc_info: PMD_SECT_XN | \ PMD_SECT_AP_WRITE | \ PMD_SECT_AP_READ - W(b) __v7_setup + b __v7_setup .long cpu_arch_name .long cpu_elf_name .long HWCAP_SWP|HWCAP_HALF|HWCAP_THUMB|HWCAP_FAST_MULT|HWCAP_EDSP|HWCAP_TLS diff --git a/trunk/arch/arm/plat-iop/time.c b/trunk/arch/arm/plat-iop/time.c index 558cdfaf76b6..85d3e55ca4a9 100644 --- a/trunk/arch/arm/plat-iop/time.c +++ b/trunk/arch/arm/plat-iop/time.c @@ -18,7 +18,6 @@ #include #include #include -#include #include #include #include @@ -37,7 +36,7 @@ /* * IOP clocksource (free-running timer 1). */ -static cycle_t notrace iop_clocksource_read(struct clocksource *unused) +static cycle_t iop_clocksource_read(struct clocksource *unused) { return 0xffffffffu - read_tcr1(); } diff --git a/trunk/arch/arm/plat-s3c24xx/cpu.c b/trunk/arch/arm/plat-s3c24xx/cpu.c index 4a10c0f684b2..76d0858c3cbb 100644 --- a/trunk/arch/arm/plat-s3c24xx/cpu.c +++ b/trunk/arch/arm/plat-s3c24xx/cpu.c @@ -88,7 +88,7 @@ static struct cpu_table cpu_ids[] __initdata = { { .idcode = 0x32440000, .idmask = 0xffffffff, - .map_io = s3c2440_map_io, + .map_io = s3c244x_map_io, .init_clocks = s3c244x_init_clocks, .init_uarts = s3c244x_init_uarts, .init = s3c2440_init, @@ -97,7 +97,7 @@ static struct cpu_table cpu_ids[] __initdata = { { .idcode = 0x32440001, .idmask = 0xffffffff, - .map_io = s3c2440_map_io, + .map_io = s3c244x_map_io, .init_clocks = s3c244x_init_clocks, .init_uarts = s3c244x_init_uarts, .init = s3c2440_init, @@ -106,7 +106,7 @@ static struct cpu_table cpu_ids[] __initdata = { { .idcode = 0x32440aaa, .idmask = 0xffffffff, - .map_io = s3c2442_map_io, + .map_io = s3c244x_map_io, .init_clocks = s3c244x_init_clocks, .init_uarts = s3c244x_init_uarts, .init = s3c2442_init, @@ -115,7 +115,7 @@ static struct cpu_table cpu_ids[] __initdata = { { .idcode = 0x32440aab, .idmask = 0xffffffff, - .map_io = s3c2442_map_io, + .map_io = s3c244x_map_io, .init_clocks = s3c244x_init_clocks, .init_uarts = s3c244x_init_uarts, .init = s3c2442_init, diff --git a/trunk/arch/arm/plat-s3c24xx/gpiolib.c b/trunk/arch/arm/plat-s3c24xx/gpiolib.c index 243b6411050d..24c6f5a30596 100644 --- a/trunk/arch/arm/plat-s3c24xx/gpiolib.c +++ b/trunk/arch/arm/plat-s3c24xx/gpiolib.c @@ -82,6 +82,8 @@ static struct s3c_gpio_cfg s3c24xx_gpiocfg_banka = { struct s3c_gpio_cfg s3c24xx_gpiocfg_default = { .set_config = s3c_gpio_setcfg_s3c24xx, .get_config = s3c_gpio_getcfg_s3c24xx, + .set_pull = s3c_gpio_setpull_1up, + .get_pull = s3c_gpio_getpull_1up, }; struct s3c_gpio_chip s3c24xx_gpios[] = { diff --git a/trunk/arch/arm/plat-s3c24xx/include/plat/s3c244x.h b/trunk/arch/arm/plat-s3c24xx/include/plat/s3c244x.h index 89e8d0a25f87..307248d1ccbb 100644 --- a/trunk/arch/arm/plat-s3c24xx/include/plat/s3c244x.h +++ b/trunk/arch/arm/plat-s3c24xx/include/plat/s3c244x.h @@ -21,22 +21,17 @@ extern void s3c244x_init_clocks(int xtal); #else #define s3c244x_init_clocks NULL #define s3c244x_init_uarts NULL +#define s3c244x_map_io NULL #endif #ifdef CONFIG_CPU_S3C2440 extern int s3c2440_init(void); - -extern void s3c2440_map_io(void); #else #define s3c2440_init NULL -#define s3c2440_map_io NULL #endif #ifdef CONFIG_CPU_S3C2442 extern int s3c2442_init(void); - -extern void s3c2442_map_io(void); #else #define s3c2442_init NULL -#define s3c2442_map_io NULL #endif diff --git a/trunk/arch/arm/plat-samsung/gpio-config.c b/trunk/arch/arm/plat-samsung/gpio-config.c index 0aa32f242ee4..b732b773b9af 100644 --- a/trunk/arch/arm/plat-samsung/gpio-config.c +++ b/trunk/arch/arm/plat-samsung/gpio-config.c @@ -280,17 +280,18 @@ s3c_gpio_pull_t s3c_gpio_getpull_updown(struct s3c_gpio_chip *chip, } #endif -#if defined(CONFIG_S3C_GPIO_PULL_UP) || defined(CONFIG_S3C_GPIO_PULL_DOWN) -static int s3c_gpio_setpull_1(struct s3c_gpio_chip *chip, - unsigned int off, s3c_gpio_pull_t pull, - s3c_gpio_pull_t updown) +#ifdef CONFIG_S3C_GPIO_PULL_UP +int s3c_gpio_setpull_1up(struct s3c_gpio_chip *chip, + unsigned int off, s3c_gpio_pull_t pull) { void __iomem *reg = chip->base + 0x08; u32 pup = __raw_readl(reg); - if (pull == updown) + pup = __raw_readl(reg); + + if (pup == S3C_GPIO_PULL_UP) pup &= ~(1 << off); - else if (pull == S3C_GPIO_PULL_NONE) + else if (pup == S3C_GPIO_PULL_NONE) pup |= (1 << off); else return -EINVAL; @@ -299,45 +300,17 @@ static int s3c_gpio_setpull_1(struct s3c_gpio_chip *chip, return 0; } -static s3c_gpio_pull_t s3c_gpio_getpull_1(struct s3c_gpio_chip *chip, - unsigned int off, s3c_gpio_pull_t updown) +s3c_gpio_pull_t s3c_gpio_getpull_1up(struct s3c_gpio_chip *chip, + unsigned int off) { void __iomem *reg = chip->base + 0x08; u32 pup = __raw_readl(reg); pup &= (1 << off); - return pup ? S3C_GPIO_PULL_NONE : updown; -} -#endif /* CONFIG_S3C_GPIO_PULL_UP || CONFIG_S3C_GPIO_PULL_DOWN */ - -#ifdef CONFIG_S3C_GPIO_PULL_UP -s3c_gpio_pull_t s3c_gpio_getpull_1up(struct s3c_gpio_chip *chip, - unsigned int off) -{ - return s3c_gpio_getpull_1(chip, off, S3C_GPIO_PULL_UP); -} - -int s3c_gpio_setpull_1up(struct s3c_gpio_chip *chip, - unsigned int off, s3c_gpio_pull_t pull) -{ - return s3c_gpio_setpull_1(chip, off, pull, S3C_GPIO_PULL_UP); + return pup ? S3C_GPIO_PULL_NONE : S3C_GPIO_PULL_UP; } #endif /* CONFIG_S3C_GPIO_PULL_UP */ -#ifdef CONFIG_S3C_GPIO_PULL_DOWN -s3c_gpio_pull_t s3c_gpio_getpull_1down(struct s3c_gpio_chip *chip, - unsigned int off) -{ - return s3c_gpio_getpull_1(chip, off, S3C_GPIO_PULL_DOWN); -} - -int s3c_gpio_setpull_1down(struct s3c_gpio_chip *chip, - unsigned int off, s3c_gpio_pull_t pull) -{ - return s3c_gpio_setpull_1(chip, off, pull, S3C_GPIO_PULL_DOWN); -} -#endif /* CONFIG_S3C_GPIO_PULL_DOWN */ - #ifdef CONFIG_S5P_GPIO_DRVSTR s5p_gpio_drvstr_t s5p_gpio_get_drvstr(unsigned int pin) { diff --git a/trunk/arch/arm/plat-samsung/include/plat/gpio-cfg-helpers.h b/trunk/arch/arm/plat-samsung/include/plat/gpio-cfg-helpers.h index 0d2c5703f1ee..8fd65d8b5863 100644 --- a/trunk/arch/arm/plat-samsung/include/plat/gpio-cfg-helpers.h +++ b/trunk/arch/arm/plat-samsung/include/plat/gpio-cfg-helpers.h @@ -209,17 +209,6 @@ extern s3c_gpio_pull_t s3c_gpio_getpull_updown(struct s3c_gpio_chip *chip, extern s3c_gpio_pull_t s3c_gpio_getpull_1up(struct s3c_gpio_chip *chip, unsigned int off); -/** - * s3c_gpio_getpull_1down() - Get configuration for choice of down or none - * @chip: The gpio chip that the GPIO pin belongs to - * @off: The offset to the pin to get the configuration of. - * - * This helper function reads the state of the pull-down resistor for the - * given GPIO in the same case as s3c_gpio_setpull_1down. -*/ -extern s3c_gpio_pull_t s3c_gpio_getpull_1down(struct s3c_gpio_chip *chip, - unsigned int off); - /** * s3c_gpio_setpull_s3c2443() - Pull configuration for s3c2443. * @chip: The gpio chip that is being configured. diff --git a/trunk/arch/arm/vfp/vfphw.S b/trunk/arch/arm/vfp/vfphw.S index 9897dcfc16d6..d66cead97d28 100644 --- a/trunk/arch/arm/vfp/vfphw.S +++ b/trunk/arch/arm/vfp/vfphw.S @@ -206,7 +206,6 @@ ENTRY(vfp_save_state) mov pc, lr ENDPROC(vfp_save_state) - .align last_VFP_context_address: .word last_VFP_context diff --git a/trunk/arch/mn10300/include/asm/syscall.h b/trunk/arch/mn10300/include/asm/syscall.h deleted file mode 100644 index b44b0bb75a01..000000000000 --- a/trunk/arch/mn10300/include/asm/syscall.h +++ /dev/null @@ -1,117 +0,0 @@ -/* Access to user system call parameters and results - * - * See asm-generic/syscall.h for function descriptions. - * - * Copyright (C) 2010 Red Hat, Inc. All Rights Reserved. - * Written by David Howells (dhowells@redhat.com) - * - * This program is free software; you can redistribute it and/or - * modify it under the terms of the GNU General Public Licence - * as published by the Free Software Foundation; either version - * 2 of the Licence, or (at your option) any later version. - */ - -#ifndef _ASM_SYSCALL_H -#define _ASM_SYSCALL_H - -#include -#include - -extern const unsigned long sys_call_table[]; - -static inline int syscall_get_nr(struct task_struct *task, struct pt_regs *regs) -{ - return regs->orig_d0; -} - -static inline void syscall_rollback(struct task_struct *task, - struct pt_regs *regs) -{ - regs->d0 = regs->orig_d0; -} - -static inline long syscall_get_error(struct task_struct *task, - struct pt_regs *regs) -{ - unsigned long error = regs->d0; - return IS_ERR_VALUE(error) ? error : 0; -} - -static inline long syscall_get_return_value(struct task_struct *task, - struct pt_regs *regs) -{ - return regs->d0; -} - -static inline void syscall_set_return_value(struct task_struct *task, - struct pt_regs *regs, - int error, long val) -{ - regs->d0 = (long) error ?: val; -} - -static inline void syscall_get_arguments(struct task_struct *task, - struct pt_regs *regs, - unsigned int i, unsigned int n, - unsigned long *args) -{ - switch (i) { - case 0: - if (!n--) break; - *args++ = regs->a0; - case 1: - if (!n--) break; - *args++ = regs->d1; - case 2: - if (!n--) break; - *args++ = regs->a3; - case 3: - if (!n--) break; - *args++ = regs->a2; - case 4: - if (!n--) break; - *args++ = regs->d3; - case 5: - if (!n--) break; - *args++ = regs->d2; - case 6: - if (!n--) break; - default: - BUG(); - break; - } -} - -static inline void syscall_set_arguments(struct task_struct *task, - struct pt_regs *regs, - unsigned int i, unsigned int n, - const unsigned long *args) -{ - switch (i) { - case 0: - if (!n--) break; - regs->a0 = *args++; - case 1: - if (!n--) break; - regs->d1 = *args++; - case 2: - if (!n--) break; - regs->a3 = *args++; - case 3: - if (!n--) break; - regs->a2 = *args++; - case 4: - if (!n--) break; - regs->d3 = *args++; - case 5: - if (!n--) break; - regs->d2 = *args++; - case 6: - if (!n--) break; - default: - BUG(); - break; - } -} - -#endif /* _ASM_SYSCALL_H */ diff --git a/trunk/arch/mn10300/kernel/gdb-io-serial.c b/trunk/arch/mn10300/kernel/gdb-io-serial.c index f28dc99c6f72..0d5d63c91dc3 100644 --- a/trunk/arch/mn10300/kernel/gdb-io-serial.c +++ b/trunk/arch/mn10300/kernel/gdb-io-serial.c @@ -73,8 +73,7 @@ void gdbstub_io_init(void) GDBPORT_SERIAL_IER = UART_IER_RDI | UART_IER_RLSI; /* permit level 0 IRQs to take place */ - arch_local_change_intr_mask_level( - NUM2EPSW_IM(CONFIG_GDBSTUB_IRQ_LEVEL + 1)); + local_change_intr_mask_level(NUM2EPSW_IM(CONFIG_GDBSTUB_IRQ_LEVEL + 1)); } /* diff --git a/trunk/arch/mn10300/kernel/gdb-io-ttysm.c b/trunk/arch/mn10300/kernel/gdb-io-ttysm.c index abdeea153c89..97dfda23342c 100644 --- a/trunk/arch/mn10300/kernel/gdb-io-ttysm.c +++ b/trunk/arch/mn10300/kernel/gdb-io-ttysm.c @@ -87,8 +87,7 @@ void __init gdbstub_io_init(void) tmp = *gdbstub_port->_control; /* permit level 0 IRQs only */ - arch_local_change_intr_mask_level( - NUM2EPSW_IM(CONFIG_GDBSTUB_IRQ_LEVEL + 1)); + local_change_intr_mask_level(NUM2EPSW_IM(CONFIG_GDBSTUB_IRQ_LEVEL + 1)); } /* diff --git a/trunk/arch/mn10300/kernel/gdb-stub.c b/trunk/arch/mn10300/kernel/gdb-stub.c index b169d99d9f20..a5fc3f05309b 100644 --- a/trunk/arch/mn10300/kernel/gdb-stub.c +++ b/trunk/arch/mn10300/kernel/gdb-stub.c @@ -1194,8 +1194,7 @@ static int gdbstub(struct pt_regs *regs, enum exception_code excep) asm volatile("mov mdr,%0" : "=d"(mdr)); local_save_flags(epsw); - arch_local_change_intr_mask_level( - NUM2EPSW_IM(CONFIG_GDBSTUB_IRQ_LEVEL + 1)); + local_change_intr_mask_level(NUM2EPSW_IM(CONFIG_GDBSTUB_IRQ_LEVEL + 1)); gdbstub_store_fpu(); diff --git a/trunk/arch/parisc/kernel/irq.c b/trunk/arch/parisc/kernel/irq.c index d7d94b845dc2..5024f643b3b1 100644 --- a/trunk/arch/parisc/kernel/irq.c +++ b/trunk/arch/parisc/kernel/irq.c @@ -75,6 +75,9 @@ static void cpu_unmask_irq(unsigned int irq) smp_send_all_nop(); } +void no_ack_irq(unsigned int irq) { } +void no_end_irq(unsigned int irq) { } + void cpu_ack_irq(unsigned int irq) { unsigned long mask = EIEM_MASK(irq); @@ -238,7 +241,7 @@ int cpu_claim_irq(unsigned int irq, struct irq_chip *type, void *data) /* for iosapic interrupts */ if (type) { - set_irq_chip_and_handler(irq, type, handle_percpu_irq); + set_irq_chip_and_handler(irq, type, handle_level_irq); set_irq_chip_data(irq, data); cpu_unmask_irq(irq); } @@ -389,7 +392,7 @@ static void claim_cpu_irqs(void) int i; for (i = CPU_IRQ_BASE; i <= CPU_IRQ_MAX; i++) { set_irq_chip_and_handler(i, &cpu_interrupt_type, - handle_percpu_irq); + handle_level_irq); } set_irq_handler(TIMER_IRQ, handle_percpu_irq); diff --git a/trunk/arch/parisc/kernel/signal.c b/trunk/arch/parisc/kernel/signal.c index 609a331878e7..35c827e94e31 100644 --- a/trunk/arch/parisc/kernel/signal.c +++ b/trunk/arch/parisc/kernel/signal.c @@ -98,6 +98,7 @@ void sys_rt_sigreturn(struct pt_regs *regs, int in_syscall) { struct rt_sigframe __user *frame; + struct siginfo si; sigset_t set; unsigned long usp = (regs->gr[30] & ~(0x01UL)); unsigned long sigframe_size = PARISC_RT_SIGFRAME_SIZE; @@ -177,7 +178,13 @@ sys_rt_sigreturn(struct pt_regs *regs, int in_syscall) give_sigsegv: DBG(1,"sys_rt_sigreturn: Sending SIGSEGV\n"); - force_sig(SIGSEGV, current); + si.si_signo = SIGSEGV; + si.si_errno = 0; + si.si_code = SI_KERNEL; + si.si_pid = task_pid_vnr(current); + si.si_uid = current_uid(); + si.si_addr = &frame->uc; + force_sig_info(SIGSEGV, &si, current); return; } diff --git a/trunk/arch/s390/kernel/vtime.c b/trunk/arch/s390/kernel/vtime.c index 7eff9b7347c0..56c8687b29b3 100644 --- a/trunk/arch/s390/kernel/vtime.c +++ b/trunk/arch/s390/kernel/vtime.c @@ -19,7 +19,6 @@ #include #include #include -#include #include #include @@ -567,23 +566,6 @@ void init_cpu_vtimer(void) __ctl_set_bit(0,10); } -static int __cpuinit s390_nohz_notify(struct notifier_block *self, - unsigned long action, void *hcpu) -{ - struct s390_idle_data *idle; - long cpu = (long) hcpu; - - idle = &per_cpu(s390_idle, cpu); - switch (action) { - case CPU_DYING: - case CPU_DYING_FROZEN: - idle->nohz_delay = 0; - default: - break; - } - return NOTIFY_OK; -} - void __init vtime_init(void) { /* request the cpu timer external interrupt */ @@ -592,6 +574,5 @@ void __init vtime_init(void) /* Enable cpu timer interrupts on the boot cpu. */ init_cpu_vtimer(); - cpu_notifier(s390_nohz_notify, 0); } diff --git a/trunk/arch/sh/boards/mach-ecovec24/setup.c b/trunk/arch/sh/boards/mach-ecovec24/setup.c index f48c492a68d3..2eaeb9e59585 100644 --- a/trunk/arch/sh/boards/mach-ecovec24/setup.c +++ b/trunk/arch/sh/boards/mach-ecovec24/setup.c @@ -720,6 +720,32 @@ static struct platform_device camera_devices[] = { }; /* FSI */ +/* + * FSI-B use external clock which came from da7210. + * So, we should change parent of fsi + */ +#define FCLKBCR 0xa415000c +static void fsimck_init(struct clk *clk) +{ + u32 status = __raw_readl(clk->enable_reg); + + /* use external clock */ + status &= ~0x000000ff; + status |= 0x00000080; + + __raw_writel(status, clk->enable_reg); +} + +static struct clk_ops fsimck_clk_ops = { + .init = fsimck_init, +}; + +static struct clk fsimckb_clk = { + .ops = &fsimck_clk_ops, + .enable_reg = (void __iomem *)FCLKBCR, + .rate = 0, /* unknown */ +}; + static struct sh_fsi_platform_info fsi_info = { .portb_flags = SH_FSI_BRS_INV | SH_FSI_OUT_SLAVE_MODE | @@ -1238,10 +1264,10 @@ static int __init arch_setup(void) /* change parent of FSI B */ clk = clk_get(NULL, "fsib_clk"); if (!IS_ERR(clk)) { - /* 48kHz dummy clock was used to make sure 1/1 divide */ - clk_set_rate(&sh7724_fsimckb_clk, 48000); - clk_set_parent(clk, &sh7724_fsimckb_clk); - clk_set_rate(clk, 48000); + clk_register(&fsimckb_clk); + clk_set_parent(clk, &fsimckb_clk); + clk_set_rate(clk, 11000); + clk_set_rate(&fsimckb_clk, 11000); clk_put(clk); } diff --git a/trunk/arch/sh/boards/mach-se/7724/setup.c b/trunk/arch/sh/boards/mach-se/7724/setup.c index 527a0cd956b5..c31d228fdfc6 100644 --- a/trunk/arch/sh/boards/mach-se/7724/setup.c +++ b/trunk/arch/sh/boards/mach-se/7724/setup.c @@ -283,6 +283,31 @@ static struct platform_device ceu1_device = { }; /* FSI */ +/* + * FSI-A use external clock which came from ak464x. + * So, we should change parent of fsi + */ +#define FCLKACR 0xa4150008 +static void fsimck_init(struct clk *clk) +{ + u32 status = __raw_readl(clk->enable_reg); + + /* use external clock */ + status &= ~0x000000ff; + status |= 0x00000080; + __raw_writel(status, clk->enable_reg); +} + +static struct clk_ops fsimck_clk_ops = { + .init = fsimck_init, +}; + +static struct clk fsimcka_clk = { + .ops = &fsimck_clk_ops, + .enable_reg = (void __iomem *)FCLKACR, + .rate = 0, /* unknown */ +}; + /* change J20, J21, J22 pin to 1-2 connection to use slave mode */ static struct sh_fsi_platform_info fsi_info = { .porta_flags = SH_FSI_BRS_INV | @@ -827,29 +852,37 @@ static int __init devices_setup(void) gpio_request(GPIO_FN_KEYOUT0, NULL); /* enable FSI */ + gpio_request(GPIO_FN_FSIMCKB, NULL); gpio_request(GPIO_FN_FSIMCKA, NULL); - gpio_request(GPIO_FN_FSIIASD, NULL); gpio_request(GPIO_FN_FSIOASD, NULL); gpio_request(GPIO_FN_FSIIABCK, NULL); gpio_request(GPIO_FN_FSIIALRCK, NULL); gpio_request(GPIO_FN_FSIOABCK, NULL); gpio_request(GPIO_FN_FSIOALRCK, NULL); gpio_request(GPIO_FN_CLKAUDIOAO, NULL); + gpio_request(GPIO_FN_FSIIBSD, NULL); + gpio_request(GPIO_FN_FSIOBSD, NULL); + gpio_request(GPIO_FN_FSIIBBCK, NULL); + gpio_request(GPIO_FN_FSIIBLRCK, NULL); + gpio_request(GPIO_FN_FSIOBBCK, NULL); + gpio_request(GPIO_FN_FSIOBLRCK, NULL); + gpio_request(GPIO_FN_CLKAUDIOBO, NULL); + gpio_request(GPIO_FN_FSIIASD, NULL); /* set SPU2 clock to 83.4 MHz */ clk = clk_get(NULL, "spu_clk"); - if (!IS_ERR(clk)) { + if (clk) { clk_set_rate(clk, clk_round_rate(clk, 83333333)); clk_put(clk); } /* change parent of FSI A */ clk = clk_get(NULL, "fsia_clk"); - if (!IS_ERR(clk)) { - /* 48kHz dummy clock was used to make sure 1/1 divide */ - clk_set_rate(&sh7724_fsimcka_clk, 48000); - clk_set_parent(clk, &sh7724_fsimcka_clk); - clk_set_rate(clk, 48000); + if (clk) { + clk_register(&fsimcka_clk); + clk_set_parent(clk, &fsimcka_clk); + clk_set_rate(clk, 11000); + clk_set_rate(&fsimcka_clk, 11000); clk_put(clk); } diff --git a/trunk/arch/sh/include/asm/cacheflush.h b/trunk/arch/sh/include/asm/cacheflush.h index 82e1eabeac98..1f4e562c5e8c 100644 --- a/trunk/arch/sh/include/asm/cacheflush.h +++ b/trunk/arch/sh/include/asm/cacheflush.h @@ -96,7 +96,7 @@ void kmap_coherent_init(void); void *kmap_coherent(struct page *page, unsigned long addr); void kunmap_coherent(void *kvaddr); -#define PG_dcache_clean PG_arch_1 +#define PG_dcache_dirty PG_arch_1 void cpu_cache_init(void); diff --git a/trunk/arch/sh/include/cpu-sh4/cpu/sh7724.h b/trunk/arch/sh/include/cpu-sh4/cpu/sh7724.h index 7eb435999426..4c27b68789b3 100644 --- a/trunk/arch/sh/include/cpu-sh4/cpu/sh7724.h +++ b/trunk/arch/sh/include/cpu-sh4/cpu/sh7724.h @@ -303,7 +303,4 @@ enum { SHDMA_SLAVE_SDHI1_RX, }; -extern struct clk sh7724_fsimcka_clk; -extern struct clk sh7724_fsimckb_clk; - #endif /* __ASM_SH7724_H__ */ diff --git a/trunk/arch/sh/kernel/cpu/sh4a/clock-sh7724.c b/trunk/arch/sh/kernel/cpu/sh4a/clock-sh7724.c index 271c0b325a9a..0fe2e9329cb2 100644 --- a/trunk/arch/sh/kernel/cpu/sh4a/clock-sh7724.c +++ b/trunk/arch/sh/kernel/cpu/sh4a/clock-sh7724.c @@ -111,21 +111,12 @@ static struct clk div3_clk = { .parent = &pll_clk, }; -/* External input clock (pin name: FSIMCKA/FSIMCKB ) */ -struct clk sh7724_fsimcka_clk = { -}; - -struct clk sh7724_fsimckb_clk = { -}; - static struct clk *main_clks[] = { &r_clk, &extal_clk, &fll_clk, &pll_clk, &div3_clk, - &sh7724_fsimcka_clk, - &sh7724_fsimckb_clk, }; static void div4_kick(struct clk *clk) @@ -163,38 +154,16 @@ struct clk div4_clks[DIV4_NR] = { [DIV4_M1] = DIV4(FRQCRB, 4, 0x2f7c, CLK_ENABLE_ON_INIT), }; -enum { DIV6_V, DIV6_I, DIV6_S, DIV6_NR }; +enum { DIV6_V, DIV6_FA, DIV6_FB, DIV6_I, DIV6_S, DIV6_NR }; static struct clk div6_clks[DIV6_NR] = { [DIV6_V] = SH_CLK_DIV6(&div3_clk, VCLKCR, 0), + [DIV6_FA] = SH_CLK_DIV6(&div3_clk, FCLKACR, 0), + [DIV6_FB] = SH_CLK_DIV6(&div3_clk, FCLKBCR, 0), [DIV6_I] = SH_CLK_DIV6(&div3_clk, IRDACLKCR, 0), [DIV6_S] = SH_CLK_DIV6(&div3_clk, SPUCLKCR, CLK_ENABLE_ON_INIT), }; -enum { DIV6_FA, DIV6_FB, DIV6_REPARENT_NR }; - -/* Indices are important - they are the actual src selecting values */ -static struct clk *fclkacr_parent[] = { - [0] = &div3_clk, - [1] = NULL, - [2] = &sh7724_fsimcka_clk, - [3] = NULL, -}; - -static struct clk *fclkbcr_parent[] = { - [0] = &div3_clk, - [1] = NULL, - [2] = &sh7724_fsimckb_clk, - [3] = NULL, -}; - -static struct clk div6_reparent_clks[DIV6_REPARENT_NR] = { - [DIV6_FA] = SH_CLK_DIV6_EXT(&div3_clk, FCLKACR, 0, - fclkacr_parent, ARRAY_SIZE(fclkacr_parent), 6, 2), - [DIV6_FB] = SH_CLK_DIV6_EXT(&div3_clk, FCLKBCR, 0, - fclkbcr_parent, ARRAY_SIZE(fclkbcr_parent), 6, 2), -}; - static struct clk mstp_clks[HWBLK_NR] = { SH_HWBLK_CLK(HWBLK_TLB, &div4_clks[DIV4_I], CLK_ENABLE_ON_INIT), SH_HWBLK_CLK(HWBLK_IC, &div4_clks[DIV4_I], CLK_ENABLE_ON_INIT), @@ -271,8 +240,8 @@ static struct clk_lookup lookups[] = { /* DIV6 clocks */ CLKDEV_CON_ID("video_clk", &div6_clks[DIV6_V]), - CLKDEV_CON_ID("fsia_clk", &div6_reparent_clks[DIV6_FA]), - CLKDEV_CON_ID("fsib_clk", &div6_reparent_clks[DIV6_FB]), + CLKDEV_CON_ID("fsia_clk", &div6_clks[DIV6_FA]), + CLKDEV_CON_ID("fsib_clk", &div6_clks[DIV6_FB]), CLKDEV_CON_ID("irda_clk", &div6_clks[DIV6_I]), CLKDEV_CON_ID("spu_clk", &div6_clks[DIV6_S]), @@ -406,9 +375,6 @@ int __init arch_clk_init(void) if (!ret) ret = sh_clk_div6_register(div6_clks, DIV6_NR); - if (!ret) - ret = sh_clk_div6_reparent_register(div6_reparent_clks, DIV6_REPARENT_NR); - if (!ret) ret = sh_hwblk_clk_register(mstp_clks, HWBLK_NR); diff --git a/trunk/arch/sh/mm/cache-sh4.c b/trunk/arch/sh/mm/cache-sh4.c index 92eb98633ab0..2cfae81914aa 100644 --- a/trunk/arch/sh/mm/cache-sh4.c +++ b/trunk/arch/sh/mm/cache-sh4.c @@ -114,7 +114,7 @@ static void sh4_flush_dcache_page(void *arg) struct address_space *mapping = page_mapping(page); if (mapping && !mapping_mapped(mapping)) - clear_bit(PG_dcache_clean, &page->flags); + set_bit(PG_dcache_dirty, &page->flags); else #endif flush_cache_one(CACHE_OC_ADDRESS_ARRAY | @@ -239,7 +239,7 @@ static void sh4_flush_cache_page(void *args) * another ASID than the current one. */ map_coherent = (current_cpu_data.dcache.n_aliases && - test_bit(PG_dcache_clean, &page->flags) && + !test_bit(PG_dcache_dirty, &page->flags) && page_mapped(page)); if (map_coherent) vaddr = kmap_coherent(page, address); diff --git a/trunk/arch/sh/mm/cache-sh7705.c b/trunk/arch/sh/mm/cache-sh7705.c index 7729cca727eb..f498da1cce7a 100644 --- a/trunk/arch/sh/mm/cache-sh7705.c +++ b/trunk/arch/sh/mm/cache-sh7705.c @@ -139,7 +139,7 @@ static void sh7705_flush_dcache_page(void *arg) struct address_space *mapping = page_mapping(page); if (mapping && !mapping_mapped(mapping)) - clear_bit(PG_dcache_clean, &page->flags); + set_bit(PG_dcache_dirty, &page->flags); else __flush_dcache_page(__pa(page_address(page))); } diff --git a/trunk/arch/sh/mm/cache.c b/trunk/arch/sh/mm/cache.c index 88d3dc3d30d5..ba401d137bb9 100644 --- a/trunk/arch/sh/mm/cache.c +++ b/trunk/arch/sh/mm/cache.c @@ -60,14 +60,14 @@ void copy_to_user_page(struct vm_area_struct *vma, struct page *page, unsigned long len) { if (boot_cpu_data.dcache.n_aliases && page_mapped(page) && - test_bit(PG_dcache_clean, &page->flags)) { + !test_bit(PG_dcache_dirty, &page->flags)) { void *vto = kmap_coherent(page, vaddr) + (vaddr & ~PAGE_MASK); memcpy(vto, src, len); kunmap_coherent(vto); } else { memcpy(dst, src, len); if (boot_cpu_data.dcache.n_aliases) - clear_bit(PG_dcache_clean, &page->flags); + set_bit(PG_dcache_dirty, &page->flags); } if (vma->vm_flags & VM_EXEC) @@ -79,14 +79,14 @@ void copy_from_user_page(struct vm_area_struct *vma, struct page *page, unsigned long len) { if (boot_cpu_data.dcache.n_aliases && page_mapped(page) && - test_bit(PG_dcache_clean, &page->flags)) { + !test_bit(PG_dcache_dirty, &page->flags)) { void *vfrom = kmap_coherent(page, vaddr) + (vaddr & ~PAGE_MASK); memcpy(dst, vfrom, len); kunmap_coherent(vfrom); } else { memcpy(dst, src, len); if (boot_cpu_data.dcache.n_aliases) - clear_bit(PG_dcache_clean, &page->flags); + set_bit(PG_dcache_dirty, &page->flags); } } @@ -98,7 +98,7 @@ void copy_user_highpage(struct page *to, struct page *from, vto = kmap_atomic(to, KM_USER1); if (boot_cpu_data.dcache.n_aliases && page_mapped(from) && - test_bit(PG_dcache_clean, &from->flags)) { + !test_bit(PG_dcache_dirty, &from->flags)) { vfrom = kmap_coherent(from, vaddr); copy_page(vto, vfrom); kunmap_coherent(vfrom); @@ -141,7 +141,7 @@ void __update_cache(struct vm_area_struct *vma, page = pfn_to_page(pfn); if (pfn_valid(pfn)) { - int dirty = !test_and_set_bit(PG_dcache_clean, &page->flags); + int dirty = test_and_clear_bit(PG_dcache_dirty, &page->flags); if (dirty) __flush_purge_region(page_address(page), PAGE_SIZE); } @@ -153,7 +153,7 @@ void __flush_anon_page(struct page *page, unsigned long vmaddr) if (pages_do_alias(addr, vmaddr)) { if (boot_cpu_data.dcache.n_aliases && page_mapped(page) && - test_bit(PG_dcache_clean, &page->flags)) { + !test_bit(PG_dcache_dirty, &page->flags)) { void *kaddr; kaddr = kmap_coherent(page, vmaddr); diff --git a/trunk/arch/sh/mm/kmap.c b/trunk/arch/sh/mm/kmap.c index ec29e14ec5a8..15d74ea42094 100644 --- a/trunk/arch/sh/mm/kmap.c +++ b/trunk/arch/sh/mm/kmap.c @@ -34,7 +34,7 @@ void *kmap_coherent(struct page *page, unsigned long addr) enum fixed_addresses idx; unsigned long vaddr; - BUG_ON(!test_bit(PG_dcache_clean, &page->flags)); + BUG_ON(test_bit(PG_dcache_dirty, &page->flags)); pagefault_disable(); diff --git a/trunk/arch/x86/pci/xen.c b/trunk/arch/x86/pci/xen.c index 25cd4a07d09f..d7b5109f7a9c 100644 --- a/trunk/arch/x86/pci/xen.c +++ b/trunk/arch/x86/pci/xen.c @@ -70,9 +70,6 @@ static int acpi_register_gsi_xen_hvm(struct device *dev, u32 gsi, struct xen_pci_frontend_ops *xen_pci_frontend; EXPORT_SYMBOL_GPL(xen_pci_frontend); -#define XEN_PIRQ_MSI_DATA (MSI_DATA_TRIGGER_EDGE | \ - MSI_DATA_LEVEL_ASSERT | (3 << 8) | MSI_DATA_VECTOR(0)) - static void xen_msi_compose_msg(struct pci_dev *pdev, unsigned int pirq, struct msi_msg *msg) { @@ -86,7 +83,12 @@ static void xen_msi_compose_msg(struct pci_dev *pdev, unsigned int pirq, MSI_ADDR_REDIRECTION_CPU | MSI_ADDR_DEST_ID(pirq); - msg->data = XEN_PIRQ_MSI_DATA; + msg->data = + MSI_DATA_TRIGGER_EDGE | + MSI_DATA_LEVEL_ASSERT | + /* delivery mode reserved */ + (3 << 8) | + MSI_DATA_VECTOR(0); } static int xen_hvm_setup_msi_irqs(struct pci_dev *dev, int nvec, int type) @@ -96,23 +98,8 @@ static int xen_hvm_setup_msi_irqs(struct pci_dev *dev, int nvec, int type) struct msi_msg msg; list_for_each_entry(msidesc, &dev->msi_list, list) { - __read_msi_msg(msidesc, &msg); - pirq = MSI_ADDR_EXT_DEST_ID(msg.address_hi) | - ((msg.address_lo >> MSI_ADDR_DEST_ID_SHIFT) & 0xff); - if (xen_irq_from_pirq(pirq) >= 0 && msg.data == XEN_PIRQ_MSI_DATA) { - xen_allocate_pirq_msi((type == PCI_CAP_ID_MSIX) ? - "msi-x" : "msi", &irq, &pirq, XEN_ALLOC_IRQ); - if (irq < 0) - goto error; - ret = set_irq_msi(irq, msidesc); - if (ret < 0) - goto error_while; - printk(KERN_DEBUG "xen: msi already setup: msi --> irq=%d" - " pirq=%d\n", irq, pirq); - return 0; - } xen_allocate_pirq_msi((type == PCI_CAP_ID_MSIX) ? - "msi-x" : "msi", &irq, &pirq, (XEN_ALLOC_IRQ | XEN_ALLOC_PIRQ)); + "msi-x" : "msi", &irq, &pirq); if (irq < 0 || pirq < 0) goto error; printk(KERN_DEBUG "xen: msi --> irq=%d, pirq=%d\n", irq, pirq); diff --git a/trunk/arch/x86/xen/enlighten.c b/trunk/arch/x86/xen/enlighten.c index 44dcad43989d..02c710bebf7a 100644 --- a/trunk/arch/x86/xen/enlighten.c +++ b/trunk/arch/x86/xen/enlighten.c @@ -1021,6 +1021,10 @@ static void xen_reboot(int reason) { struct sched_shutdown r = { .reason = reason }; +#ifdef CONFIG_SMP + stop_other_cpus(); +#endif + if (HYPERVISOR_sched_op(SCHEDOP_shutdown, &r)) BUG(); } diff --git a/trunk/arch/x86/xen/mmu.c b/trunk/arch/x86/xen/mmu.c index 44924e551fde..a1feff9e59b6 100644 --- a/trunk/arch/x86/xen/mmu.c +++ b/trunk/arch/x86/xen/mmu.c @@ -2415,6 +2415,8 @@ void __init xen_init_mmu_ops(void) x86_init.paging.pagetable_setup_done = xen_pagetable_setup_done; pv_mmu_ops = xen_mmu_ops; + vmap_lazy_unmap = false; + memset(dummy_mapping, 0xff, PAGE_SIZE); } diff --git a/trunk/arch/x86/xen/platform-pci-unplug.c b/trunk/arch/x86/xen/platform-pci-unplug.c index 25c52f94a27c..0f456386cce5 100644 --- a/trunk/arch/x86/xen/platform-pci-unplug.c +++ b/trunk/arch/x86/xen/platform-pci-unplug.c @@ -68,7 +68,7 @@ static int __init check_platform_magic(void) return 0; } -void xen_unplug_emulated_devices(void) +void __init xen_unplug_emulated_devices(void) { int r; diff --git a/trunk/arch/x86/xen/setup.c b/trunk/arch/x86/xen/setup.c index b5a7f928234b..01afd8a94607 100644 --- a/trunk/arch/x86/xen/setup.c +++ b/trunk/arch/x86/xen/setup.c @@ -181,21 +181,24 @@ char * __init xen_memory_setup(void) for (i = 0; i < memmap.nr_entries; i++) { unsigned long long end = map[i].addr + map[i].size; - if (map[i].type == E820_RAM && end > mem_end) { - /* RAM off the end - may be partially included */ - u64 delta = min(map[i].size, end - mem_end); + if (map[i].type == E820_RAM) { + if (map[i].addr < mem_end && end > mem_end) { + /* Truncate region to max_mem. */ + u64 delta = end - mem_end; - map[i].size -= delta; - end -= delta; + map[i].size -= delta; + extra_pages += PFN_DOWN(delta); - extra_pages += PFN_DOWN(delta); + end = mem_end; + } } - if (map[i].size > 0 && end > xen_extra_mem_start) + if (end > xen_extra_mem_start) xen_extra_mem_start = end; - /* Add region if any remains */ - if (map[i].size > 0) + /* If region is non-RAM or below mem_end, add what remains */ + if ((map[i].type != E820_RAM || map[i].addr < mem_end) && + map[i].size > 0) e820_add_region(map[i].addr, map[i].size, map[i].type); } @@ -249,6 +252,20 @@ char * __init xen_memory_setup(void) return "Xen"; } +static void xen_idle(void) +{ + local_irq_disable(); + + if (need_resched()) + local_irq_enable(); + else { + current_thread_info()->status &= ~TS_POLLING; + smp_mb__after_clear_bit(); + safe_halt(); + current_thread_info()->status |= TS_POLLING; + } +} + /* * Set the bit indicating "nosegneg" library variants should be used. * We only need to bother in pure 32-bit mode; compat 32-bit processes @@ -345,11 +362,7 @@ void __init xen_arch_setup(void) MAX_GUEST_CMDLINE > COMMAND_LINE_SIZE ? COMMAND_LINE_SIZE : MAX_GUEST_CMDLINE); - /* Set up idle, making sure it calls safe_halt() pvop */ -#ifdef CONFIG_X86_32 - boot_cpu_data.hlt_works_ok = 1; -#endif - pm_idle = default_idle; + pm_idle = xen_idle; fiddle_vdso(); } diff --git a/trunk/arch/x86/xen/suspend.c b/trunk/arch/x86/xen/suspend.c index 9bbd63a129b5..1d789d56877c 100644 --- a/trunk/arch/x86/xen/suspend.c +++ b/trunk/arch/x86/xen/suspend.c @@ -31,7 +31,6 @@ void xen_hvm_post_suspend(int suspend_cancelled) int cpu; xen_hvm_init_shared_info(); xen_callback_vector(); - xen_unplug_emulated_devices(); if (xen_feature(XENFEAT_hvm_safe_pvclock)) { for_each_online_cpu(cpu) { xen_setup_runstate_info(cpu); diff --git a/trunk/arch/x86/xen/xen-ops.h b/trunk/arch/x86/xen/xen-ops.h index 9d41bf985757..64044747348e 100644 --- a/trunk/arch/x86/xen/xen-ops.h +++ b/trunk/arch/x86/xen/xen-ops.h @@ -43,7 +43,7 @@ void xen_vcpu_restore(void); void xen_callback_vector(void); void xen_hvm_init_shared_info(void); -void xen_unplug_emulated_devices(void); +void __init xen_unplug_emulated_devices(void); void __init xen_build_dynamic_phys_to_machine(void); diff --git a/trunk/drivers/dma/shdma.c b/trunk/drivers/dma/shdma.c index 85ffd5e38c50..eb6b54dbb806 100644 --- a/trunk/drivers/dma/shdma.c +++ b/trunk/drivers/dma/shdma.c @@ -1213,4 +1213,3 @@ module_exit(sh_dmae_exit); MODULE_AUTHOR("Nobuhiro Iwamatsu "); MODULE_DESCRIPTION("Renesas SH DMA Engine driver"); MODULE_LICENSE("GPL"); -MODULE_ALIAS("platform:sh-dma-engine"); diff --git a/trunk/drivers/gpio/cs5535-gpio.c b/trunk/drivers/gpio/cs5535-gpio.c index 599f6c9e0fbf..e23c06893d19 100644 --- a/trunk/drivers/gpio/cs5535-gpio.c +++ b/trunk/drivers/gpio/cs5535-gpio.c @@ -56,18 +56,6 @@ static struct cs5535_gpio_chip { * registers, see include/linux/cs5535.h. */ -static void errata_outl(u32 val, unsigned long addr) -{ - /* - * According to the CS5536 errata (#36), after suspend - * a write to the high bank GPIO register will clear all - * non-selected bits; the recommended workaround is a - * read-modify-write operation. - */ - val |= inl(addr); - outl(val, addr); -} - static void __cs5535_gpio_set(struct cs5535_gpio_chip *chip, unsigned offset, unsigned int reg) { @@ -76,7 +64,7 @@ static void __cs5535_gpio_set(struct cs5535_gpio_chip *chip, unsigned offset, outl(1 << offset, chip->base + reg); else /* high bank register */ - errata_outl(1 << (offset - 16), chip->base + 0x80 + reg); + outl(1 << (offset - 16), chip->base + 0x80 + reg); } void cs5535_gpio_set(unsigned offset, unsigned int reg) @@ -98,7 +86,7 @@ static void __cs5535_gpio_clear(struct cs5535_gpio_chip *chip, unsigned offset, outl(1 << (offset + 16), chip->base + reg); else /* high bank register */ - errata_outl(1 << offset, chip->base + 0x80 + reg); + outl(1 << offset, chip->base + 0x80 + reg); } void cs5535_gpio_clear(unsigned offset, unsigned int reg) diff --git a/trunk/drivers/gpu/drm/i915/i915_reg.h b/trunk/drivers/gpu/drm/i915/i915_reg.h index 25ed911a3112..878fc766a12c 100644 --- a/trunk/drivers/gpu/drm/i915/i915_reg.h +++ b/trunk/drivers/gpu/drm/i915/i915_reg.h @@ -3033,6 +3033,7 @@ #define TRANS_DP_10BPC (1<<9) #define TRANS_DP_6BPC (2<<9) #define TRANS_DP_12BPC (3<<9) +#define TRANS_DP_BPC_MASK (3<<9) #define TRANS_DP_VSYNC_ACTIVE_HIGH (1<<4) #define TRANS_DP_VSYNC_ACTIVE_LOW 0 #define TRANS_DP_HSYNC_ACTIVE_HIGH (1<<3) diff --git a/trunk/drivers/gpu/drm/i915/intel_display.c b/trunk/drivers/gpu/drm/i915/intel_display.c index 255b52ee0091..9d3af3cb5a0b 100644 --- a/trunk/drivers/gpu/drm/i915/intel_display.c +++ b/trunk/drivers/gpu/drm/i915/intel_display.c @@ -2120,9 +2120,11 @@ static void ironlake_crtc_enable(struct drm_crtc *crtc) reg = TRANS_DP_CTL(pipe); temp = I915_READ(reg); temp &= ~(TRANS_DP_PORT_SEL_MASK | - TRANS_DP_SYNC_MASK); + TRANS_DP_SYNC_MASK | + TRANS_DP_BPC_MASK); temp |= (TRANS_DP_OUTPUT_ENABLE | TRANS_DP_ENH_FRAMING); + temp |= TRANS_DP_8BPC; if (crtc->mode.flags & DRM_MODE_FLAG_PHSYNC) temp |= TRANS_DP_HSYNC_ACTIVE_HIGH; diff --git a/trunk/drivers/hid/hid-core.c b/trunk/drivers/hid/hid-core.c index 88cb04e7962b..515345b11ac9 100644 --- a/trunk/drivers/hid/hid-core.c +++ b/trunk/drivers/hid/hid-core.c @@ -1386,7 +1386,6 @@ static const struct hid_device_id hid_blacklist[] = { { HID_USB_DEVICE(USB_VENDOR_ID_THRUSTMASTER, 0xb651) }, { HID_USB_DEVICE(USB_VENDOR_ID_THRUSTMASTER, 0xb653) }, { HID_USB_DEVICE(USB_VENDOR_ID_THRUSTMASTER, 0xb654) }, - { HID_USB_DEVICE(USB_VENDOR_ID_THRUSTMASTER, 0xb65a) }, { HID_USB_DEVICE(USB_VENDOR_ID_TOPSEED, USB_DEVICE_ID_TOPSEED_CYBERLINK) }, { HID_USB_DEVICE(USB_VENDOR_ID_TOPSEED2, USB_DEVICE_ID_TOPSEED2_RF_COMBO) }, { HID_USB_DEVICE(USB_VENDOR_ID_TWINHAN, USB_DEVICE_ID_TWINHAN_IR_REMOTE) }, diff --git a/trunk/drivers/hid/hid-egalax.c b/trunk/drivers/hid/hid-egalax.c index 5a1b52e0eb85..54b017ad258d 100644 --- a/trunk/drivers/hid/hid-egalax.c +++ b/trunk/drivers/hid/hid-egalax.c @@ -221,7 +221,7 @@ static int egalax_probe(struct hid_device *hdev, const struct hid_device_id *id) struct egalax_data *td; struct hid_report *report; - td = kzalloc(sizeof(struct egalax_data), GFP_KERNEL); + td = kmalloc(sizeof(struct egalax_data), GFP_KERNEL); if (!td) { dev_err(&hdev->dev, "cannot allocate eGalax data\n"); return -ENOMEM; diff --git a/trunk/drivers/hid/hid-input.c b/trunk/drivers/hid/hid-input.c index d8d372bae3cc..bb0b3659437b 100644 --- a/trunk/drivers/hid/hid-input.c +++ b/trunk/drivers/hid/hid-input.c @@ -174,7 +174,7 @@ static int hidinput_setkeycode(struct input_dev *dev, clear_bit(*old_keycode, dev->keybit); set_bit(usage->code, dev->keybit); - dbg_hid("Assigned keycode %d to HID usage code %x\n", + dbg_hid(KERN_DEBUG "Assigned keycode %d to HID usage code %x\n", usage->code, usage->hid); /* @@ -203,8 +203,8 @@ static int hidinput_setkeycode(struct input_dev *dev, * * as seen in the HID specification v1.11 6.2.2.7 Global Items. * - * Only exponent 1 length units are processed. Centimeters and inches are - * converted to millimeters. Degrees are converted to radians. + * Only exponent 1 length units are processed. Centimeters are converted to + * inches. Degrees are converted to radians. */ static __s32 hidinput_calc_abs_res(const struct hid_field *field, __u16 code) { @@ -225,16 +225,13 @@ static __s32 hidinput_calc_abs_res(const struct hid_field *field, __u16 code) */ if (code == ABS_X || code == ABS_Y || code == ABS_Z) { if (field->unit == 0x11) { /* If centimeters */ - /* Convert to millimeters */ - unit_exponent += 1; - } else if (field->unit == 0x13) { /* If inches */ - /* Convert to millimeters */ - prev = physical_extents; - physical_extents *= 254; - if (physical_extents < prev) + /* Convert to inches */ + prev = logical_extents; + logical_extents *= 254; + if (logical_extents < prev) return 0; - unit_exponent -= 1; - } else { + unit_exponent += 2; + } else if (field->unit != 0x13) { /* If not inches */ return 0; } } else if (code == ABS_RX || code == ABS_RY || code == ABS_RZ) { diff --git a/trunk/drivers/hid/hid-tmff.c b/trunk/drivers/hid/hid-tmff.c index 25be4e1461bd..15434c814793 100644 --- a/trunk/drivers/hid/hid-tmff.c +++ b/trunk/drivers/hid/hid-tmff.c @@ -256,8 +256,6 @@ static const struct hid_device_id tm_devices[] = { .driver_data = (unsigned long)ff_joystick }, { HID_USB_DEVICE(USB_VENDOR_ID_THRUSTMASTER, 0xb654), /* FGT Force Feedback Wheel */ .driver_data = (unsigned long)ff_joystick }, - { HID_USB_DEVICE(USB_VENDOR_ID_THRUSTMASTER, 0xb65a), /* F430 Force Feedback Wheel */ - .driver_data = (unsigned long)ff_joystick }, { } }; MODULE_DEVICE_TABLE(hid, tm_devices); diff --git a/trunk/drivers/i2c/Kconfig b/trunk/drivers/i2c/Kconfig index 30f06e956bfb..b923074b2cbe 100644 --- a/trunk/drivers/i2c/Kconfig +++ b/trunk/drivers/i2c/Kconfig @@ -75,7 +75,8 @@ config I2C_HELPER_AUTO In doubt, say Y. config I2C_SMBUS - tristate "SMBus-specific protocols" if !I2C_HELPER_AUTO + tristate + prompt "SMBus-specific protocols" if !I2C_HELPER_AUTO help Say Y here if you want support for SMBus extensions to the I2C specification. At the moment, the only supported extension is diff --git a/trunk/drivers/i2c/algos/Kconfig b/trunk/drivers/i2c/algos/Kconfig index f1cfe7e5508b..3998dd620a03 100644 --- a/trunk/drivers/i2c/algos/Kconfig +++ b/trunk/drivers/i2c/algos/Kconfig @@ -3,7 +3,7 @@ # menu "I2C Algorithms" - visible if !I2C_HELPER_AUTO + depends on !I2C_HELPER_AUTO config I2C_ALGOBIT tristate "I2C bit-banging interfaces" @@ -15,3 +15,15 @@ config I2C_ALGOPCA tristate "I2C PCA 9564 interfaces" endmenu + +# In automatic configuration mode, we still have to define the +# symbols to avoid unmet dependencies. + +if I2C_HELPER_AUTO +config I2C_ALGOBIT + tristate +config I2C_ALGOPCF + tristate +config I2C_ALGOPCA + tristate +endif diff --git a/trunk/drivers/input/joystick/turbografx.c b/trunk/drivers/input/joystick/turbografx.c index 27b6a3ce18ca..d53b9e900234 100644 --- a/trunk/drivers/input/joystick/turbografx.c +++ b/trunk/drivers/input/joystick/turbografx.c @@ -245,7 +245,6 @@ static struct tgfx __init *tgfx_probe(int parport, int *n_buttons, int n_devs) goto err_free_tgfx; } - parport_put_port(pp); return tgfx; err_free_dev: diff --git a/trunk/drivers/input/keyboard/Kconfig b/trunk/drivers/input/keyboard/Kconfig index 3a87f3ba5f75..b8c51b9781db 100644 --- a/trunk/drivers/input/keyboard/Kconfig +++ b/trunk/drivers/input/keyboard/Kconfig @@ -179,22 +179,6 @@ config KEYBOARD_GPIO To compile this driver as a module, choose M here: the module will be called gpio_keys. -config KEYBOARD_GPIO_POLLED - tristate "Polled GPIO buttons" - depends on GENERIC_GPIO - select INPUT_POLLDEV - help - This driver implements support for buttons connected - to GPIO pins that are not capable of generating interrupts. - - Say Y here if your device has buttons connected - directly to such GPIO pins. Your board-specific - setup logic must also provide a platform device, - with configuration data saying which GPIOs are used. - - To compile this driver as a module, choose M here: the - module will be called gpio_keys_polled. - config KEYBOARD_TCA6416 tristate "TCA6416 Keypad Support" depends on I2C diff --git a/trunk/drivers/input/keyboard/Makefile b/trunk/drivers/input/keyboard/Makefile index 622de73a445d..a34452e8ebe2 100644 --- a/trunk/drivers/input/keyboard/Makefile +++ b/trunk/drivers/input/keyboard/Makefile @@ -14,7 +14,6 @@ obj-$(CONFIG_KEYBOARD_BFIN) += bf54x-keys.o obj-$(CONFIG_KEYBOARD_DAVINCI) += davinci_keyscan.o obj-$(CONFIG_KEYBOARD_EP93XX) += ep93xx_keypad.o obj-$(CONFIG_KEYBOARD_GPIO) += gpio_keys.o -obj-$(CONFIG_KEYBOARD_GPIO_POLLED) += gpio_keys_polled.o obj-$(CONFIG_KEYBOARD_TCA6416) += tca6416-keypad.o obj-$(CONFIG_KEYBOARD_HIL) += hil_kbd.o obj-$(CONFIG_KEYBOARD_HIL_OLD) += hilkbd.o diff --git a/trunk/drivers/input/keyboard/gpio_keys_polled.c b/trunk/drivers/input/keyboard/gpio_keys_polled.c deleted file mode 100644 index 4c17aff20657..000000000000 --- a/trunk/drivers/input/keyboard/gpio_keys_polled.c +++ /dev/null @@ -1,261 +0,0 @@ -/* - * Driver for buttons on GPIO lines not capable of generating interrupts - * - * Copyright (C) 2007-2010 Gabor Juhos - * Copyright (C) 2010 Nuno Goncalves - * - * This file was based on: /drivers/input/misc/cobalt_btns.c - * Copyright (C) 2007 Yoichi Yuasa - * - * also was based on: /drivers/input/keyboard/gpio_keys.c - * Copyright 2005 Phil Blundell - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. - */ - -#include -#include -#include -#include -#include -#include -#include -#include -#include -#include - -#define DRV_NAME "gpio-keys-polled" - -struct gpio_keys_button_data { - int last_state; - int count; - int threshold; - int can_sleep; -}; - -struct gpio_keys_polled_dev { - struct input_polled_dev *poll_dev; - struct device *dev; - struct gpio_keys_platform_data *pdata; - struct gpio_keys_button_data data[0]; -}; - -static void gpio_keys_polled_check_state(struct input_dev *input, - struct gpio_keys_button *button, - struct gpio_keys_button_data *bdata) -{ - int state; - - if (bdata->can_sleep) - state = !!gpio_get_value_cansleep(button->gpio); - else - state = !!gpio_get_value(button->gpio); - - if (state != bdata->last_state) { - unsigned int type = button->type ?: EV_KEY; - - input_event(input, type, button->code, - !!(state ^ button->active_low)); - input_sync(input); - bdata->count = 0; - bdata->last_state = state; - } -} - -static void gpio_keys_polled_poll(struct input_polled_dev *dev) -{ - struct gpio_keys_polled_dev *bdev = dev->private; - struct gpio_keys_platform_data *pdata = bdev->pdata; - struct input_dev *input = dev->input; - int i; - - for (i = 0; i < bdev->pdata->nbuttons; i++) { - struct gpio_keys_button_data *bdata = &bdev->data[i]; - - if (bdata->count < bdata->threshold) - bdata->count++; - else - gpio_keys_polled_check_state(input, &pdata->buttons[i], - bdata); - } -} - -static void gpio_keys_polled_open(struct input_polled_dev *dev) -{ - struct gpio_keys_polled_dev *bdev = dev->private; - struct gpio_keys_platform_data *pdata = bdev->pdata; - - if (pdata->enable) - pdata->enable(bdev->dev); -} - -static void gpio_keys_polled_close(struct input_polled_dev *dev) -{ - struct gpio_keys_polled_dev *bdev = dev->private; - struct gpio_keys_platform_data *pdata = bdev->pdata; - - if (pdata->disable) - pdata->disable(bdev->dev); -} - -static int __devinit gpio_keys_polled_probe(struct platform_device *pdev) -{ - struct gpio_keys_platform_data *pdata = pdev->dev.platform_data; - struct device *dev = &pdev->dev; - struct gpio_keys_polled_dev *bdev; - struct input_polled_dev *poll_dev; - struct input_dev *input; - int error; - int i; - - if (!pdata || !pdata->poll_interval) - return -EINVAL; - - bdev = kzalloc(sizeof(struct gpio_keys_polled_dev) + - pdata->nbuttons * sizeof(struct gpio_keys_button_data), - GFP_KERNEL); - if (!bdev) { - dev_err(dev, "no memory for private data\n"); - return -ENOMEM; - } - - poll_dev = input_allocate_polled_device(); - if (!poll_dev) { - dev_err(dev, "no memory for polled device\n"); - error = -ENOMEM; - goto err_free_bdev; - } - - poll_dev->private = bdev; - poll_dev->poll = gpio_keys_polled_poll; - poll_dev->poll_interval = pdata->poll_interval; - poll_dev->open = gpio_keys_polled_open; - poll_dev->close = gpio_keys_polled_close; - - input = poll_dev->input; - - input->evbit[0] = BIT(EV_KEY); - input->name = pdev->name; - input->phys = DRV_NAME"/input0"; - input->dev.parent = &pdev->dev; - - input->id.bustype = BUS_HOST; - input->id.vendor = 0x0001; - input->id.product = 0x0001; - input->id.version = 0x0100; - - for (i = 0; i < pdata->nbuttons; i++) { - struct gpio_keys_button *button = &pdata->buttons[i]; - struct gpio_keys_button_data *bdata = &bdev->data[i]; - unsigned int gpio = button->gpio; - unsigned int type = button->type ?: EV_KEY; - - if (button->wakeup) { - dev_err(dev, DRV_NAME " does not support wakeup\n"); - error = -EINVAL; - goto err_free_gpio; - } - - error = gpio_request(gpio, - button->desc ? button->desc : DRV_NAME); - if (error) { - dev_err(dev, "unable to claim gpio %u, err=%d\n", - gpio, error); - goto err_free_gpio; - } - - error = gpio_direction_input(gpio); - if (error) { - dev_err(dev, - "unable to set direction on gpio %u, err=%d\n", - gpio, error); - goto err_free_gpio; - } - - bdata->can_sleep = gpio_cansleep(gpio); - bdata->last_state = -1; - bdata->threshold = DIV_ROUND_UP(button->debounce_interval, - pdata->poll_interval); - - input_set_capability(input, type, button->code); - } - - bdev->poll_dev = poll_dev; - bdev->dev = dev; - bdev->pdata = pdata; - platform_set_drvdata(pdev, bdev); - - error = input_register_polled_device(poll_dev); - if (error) { - dev_err(dev, "unable to register polled device, err=%d\n", - error); - goto err_free_gpio; - } - - /* report initial state of the buttons */ - for (i = 0; i < pdata->nbuttons; i++) - gpio_keys_polled_check_state(input, &pdata->buttons[i], - &bdev->data[i]); - - return 0; - -err_free_gpio: - while (--i >= 0) - gpio_free(pdata->buttons[i].gpio); - - input_free_polled_device(poll_dev); - -err_free_bdev: - kfree(bdev); - - platform_set_drvdata(pdev, NULL); - return error; -} - -static int __devexit gpio_keys_polled_remove(struct platform_device *pdev) -{ - struct gpio_keys_polled_dev *bdev = platform_get_drvdata(pdev); - struct gpio_keys_platform_data *pdata = bdev->pdata; - int i; - - input_unregister_polled_device(bdev->poll_dev); - - for (i = 0; i < pdata->nbuttons; i++) - gpio_free(pdata->buttons[i].gpio); - - input_free_polled_device(bdev->poll_dev); - - kfree(bdev); - platform_set_drvdata(pdev, NULL); - - return 0; -} - -static struct platform_driver gpio_keys_polled_driver = { - .probe = gpio_keys_polled_probe, - .remove = __devexit_p(gpio_keys_polled_remove), - .driver = { - .name = DRV_NAME, - .owner = THIS_MODULE, - }, -}; - -static int __init gpio_keys_polled_init(void) -{ - return platform_driver_register(&gpio_keys_polled_driver); -} - -static void __exit gpio_keys_polled_exit(void) -{ - platform_driver_unregister(&gpio_keys_polled_driver); -} - -module_init(gpio_keys_polled_init); -module_exit(gpio_keys_polled_exit); - -MODULE_LICENSE("GPL v2"); -MODULE_AUTHOR("Gabor Juhos "); -MODULE_DESCRIPTION("Polled GPIO Buttons driver"); -MODULE_ALIAS("platform:" DRV_NAME); diff --git a/trunk/drivers/input/mouse/synaptics.h b/trunk/drivers/input/mouse/synaptics.h index 0aefaa885871..613a3652f98f 100644 --- a/trunk/drivers/input/mouse/synaptics.h +++ b/trunk/drivers/input/mouse/synaptics.h @@ -51,8 +51,7 @@ #define SYN_EXT_CAP_REQUESTS(c) (((c) & 0x700000) >> 20) #define SYN_CAP_MULTI_BUTTON_NO(ec) (((ec) & 0x00f000) >> 12) #define SYN_CAP_PRODUCT_ID(ec) (((ec) & 0xff0000) >> 16) -#define SYN_CAP_CLICKPAD(ex0c) ((ex0c) & 0x100000) /* 1-button ClickPad */ -#define SYN_CAP_CLICKPAD2BTN(ex0c) ((ex0c) & 0x000100) /* 2-button ClickPad */ +#define SYN_CAP_CLICKPAD(ex0c) ((ex0c) & 0x100100) #define SYN_CAP_MAX_DIMENSIONS(ex0c) ((ex0c) & 0x020000) /* synaptics modes query bits */ diff --git a/trunk/drivers/input/serio/gscps2.c b/trunk/drivers/input/serio/gscps2.c index 4225f5d6b15f..3c287dd879d3 100644 --- a/trunk/drivers/input/serio/gscps2.c +++ b/trunk/drivers/input/serio/gscps2.c @@ -358,7 +358,7 @@ static int __devinit gscps2_probe(struct parisc_device *dev) gscps2_reset(ps2port); ps2port->id = readb(ps2port->addr + GSC_ID) & 0x0f; - snprintf(serio->name, sizeof(serio->name), "gsc-ps2-%s", + snprintf(serio->name, sizeof(serio->name), "GSC PS/2 %s", (ps2port->id == GSC_ID_KEYBOARD) ? "keyboard" : "mouse"); strlcpy(serio->phys, dev_name(&dev->dev), sizeof(serio->phys)); serio->id.type = SERIO_8042; diff --git a/trunk/drivers/input/tablet/wacom_wac.c b/trunk/drivers/input/tablet/wacom_wac.c index 4852b440960a..b3252ef1e279 100644 --- a/trunk/drivers/input/tablet/wacom_wac.c +++ b/trunk/drivers/input/tablet/wacom_wac.c @@ -1436,12 +1436,6 @@ static struct wacom_features wacom_features_0xD2 = { "Wacom Bamboo Craft", WACOM_PKGLEN_BBFUN, 14720, 9200, 1023, 63, BAMBOO_PT }; static struct wacom_features wacom_features_0xD3 = { "Wacom Bamboo 2FG 6x8", WACOM_PKGLEN_BBFUN, 21648, 13530, 1023, 63, BAMBOO_PT }; -static struct wacom_features wacom_features_0xD8 = - { "Wacom Bamboo Comic 2FG", WACOM_PKGLEN_BBFUN, 21648, 13530, 1023, 63, BAMBOO_PT }; -static struct wacom_features wacom_features_0xDA = - { "Wacom Bamboo 2FG 4x5 SE", WACOM_PKGLEN_BBFUN, 14720, 9200, 1023, 63, BAMBOO_PT }; -static struct wacom_features wacom_features_0xDB = - { "Wacom Bamboo 2FG 6x8 SE", WACOM_PKGLEN_BBFUN, 21648, 13530, 1023, 63, BAMBOO_PT }; #define USB_DEVICE_WACOM(prod) \ USB_DEVICE(USB_VENDOR_ID_WACOM, prod), \ @@ -1510,9 +1504,6 @@ const struct usb_device_id wacom_ids[] = { { USB_DEVICE_WACOM(0xD1) }, { USB_DEVICE_WACOM(0xD2) }, { USB_DEVICE_WACOM(0xD3) }, - { USB_DEVICE_WACOM(0xD8) }, - { USB_DEVICE_WACOM(0xDA) }, - { USB_DEVICE_WACOM(0xDB) }, { USB_DEVICE_WACOM(0xF0) }, { USB_DEVICE_WACOM(0xCC) }, { USB_DEVICE_WACOM(0x90) }, diff --git a/trunk/drivers/input/touchscreen/usbtouchscreen.c b/trunk/drivers/input/touchscreen/usbtouchscreen.c index 73fd6642b681..f45f80f6d336 100644 --- a/trunk/drivers/input/touchscreen/usbtouchscreen.c +++ b/trunk/drivers/input/touchscreen/usbtouchscreen.c @@ -178,7 +178,6 @@ static const struct usb_device_id usbtouch_devices[] = { #ifdef CONFIG_TOUCHSCREEN_USB_ITM {USB_DEVICE(0x0403, 0xf9e9), .driver_info = DEVTYPE_ITM}, - {USB_DEVICE(0x16e3, 0xf9e9), .driver_info = DEVTYPE_ITM}, #endif #ifdef CONFIG_TOUCHSCREEN_USB_ETURBO diff --git a/trunk/drivers/leds/Kconfig b/trunk/drivers/leds/Kconfig index 6f190f4cdbc0..77b8fd20cd90 100644 --- a/trunk/drivers/leds/Kconfig +++ b/trunk/drivers/leds/Kconfig @@ -7,20 +7,20 @@ menuconfig NEW_LEDS This is not related to standard keyboard LEDs which are controlled via the input system. +if NEW_LEDS + config LEDS_CLASS bool "LED Class Support" - depends on NEW_LEDS help This option enables the led sysfs class in /sys/class/leds. You'll need this to do anything useful with LEDs. If unsure, say N. -if NEW_LEDS +if LEDS_CLASS comment "LED drivers" config LEDS_88PM860X tristate "LED Support for Marvell 88PM860x PMIC" - depends on LEDS_CLASS depends on MFD_88PM860X help This option enables support for on-chip LED drivers found on Marvell @@ -28,7 +28,6 @@ config LEDS_88PM860X config LEDS_ATMEL_PWM tristate "LED Support using Atmel PWM outputs" - depends on LEDS_CLASS depends on ATMEL_PWM help This option enables support for LEDs driven using outputs @@ -36,7 +35,6 @@ config LEDS_ATMEL_PWM config LEDS_LOCOMO tristate "LED Support for Locomo device" - depends on LEDS_CLASS depends on SHARP_LOCOMO help This option enables support for the LEDs on Sharp Locomo. @@ -44,7 +42,6 @@ config LEDS_LOCOMO config LEDS_MIKROTIK_RB532 tristate "LED Support for Mikrotik Routerboard 532" - depends on LEDS_CLASS depends on MIKROTIK_RB532 help This option enables support for the so called "User LED" of @@ -52,7 +49,6 @@ config LEDS_MIKROTIK_RB532 config LEDS_S3C24XX tristate "LED Support for Samsung S3C24XX GPIO LEDs" - depends on LEDS_CLASS depends on ARCH_S3C2410 help This option enables support for LEDs connected to GPIO lines @@ -60,14 +56,12 @@ config LEDS_S3C24XX config LEDS_AMS_DELTA tristate "LED Support for the Amstrad Delta (E3)" - depends on LEDS_CLASS depends on MACH_AMS_DELTA help This option enables support for the LEDs on Amstrad Delta (E3). config LEDS_NET48XX tristate "LED Support for Soekris net48xx series Error LED" - depends on LEDS_CLASS depends on SCx200_GPIO help This option enables support for the Soekris net4801 and net4826 error @@ -85,21 +79,18 @@ config LEDS_NET5501 config LEDS_FSG tristate "LED Support for the Freecom FSG-3" - depends on LEDS_CLASS depends on MACH_FSG help This option enables support for the LEDs on the Freecom FSG-3. config LEDS_WRAP tristate "LED Support for the WRAP series LEDs" - depends on LEDS_CLASS depends on SCx200_GPIO help This option enables support for the PCEngines WRAP programmable LEDs. config LEDS_ALIX2 tristate "LED Support for ALIX.2 and ALIX.3 series" - depends on LEDS_CLASS depends on X86 && !GPIO_CS5535 && !CS5535_GPIO help This option enables support for the PCEngines ALIX.2 and ALIX.3 LEDs. @@ -107,14 +98,12 @@ config LEDS_ALIX2 config LEDS_H1940 tristate "LED Support for iPAQ H1940 device" - depends on LEDS_CLASS depends on ARCH_H1940 help This option enables support for the LEDs on the h1940. config LEDS_COBALT_QUBE tristate "LED Support for the Cobalt Qube series front LED" - depends on LEDS_CLASS depends on MIPS_COBALT help This option enables support for the front LED on Cobalt Qube series @@ -128,7 +117,6 @@ config LEDS_COBALT_RAQ config LEDS_SUNFIRE tristate "LED support for SunFire servers." - depends on LEDS_CLASS depends on SPARC64 select LEDS_TRIGGERS help @@ -137,7 +125,6 @@ config LEDS_SUNFIRE config LEDS_HP6XX tristate "LED Support for the HP Jornada 6xx" - depends on LEDS_CLASS depends on SH_HP6XX help This option enables LED support for the handheld @@ -145,7 +132,6 @@ config LEDS_HP6XX config LEDS_PCA9532 tristate "LED driver for PCA9532 dimmer" - depends on LEDS_CLASS depends on I2C && INPUT && EXPERIMENTAL help This option enables support for NXP pca9532 @@ -154,7 +140,6 @@ config LEDS_PCA9532 config LEDS_GPIO tristate "LED Support for GPIO connected LEDs" - depends on LEDS_CLASS depends on GENERIC_GPIO help This option enables support for the LEDs connected to GPIO @@ -182,7 +167,6 @@ config LEDS_GPIO_OF config LEDS_LP3944 tristate "LED Support for N.S. LP3944 (Fun Light) I2C chip" - depends on LEDS_CLASS depends on I2C help This option enables support for LEDs connected to the National @@ -212,7 +196,6 @@ config LEDS_LP5523 config LEDS_CLEVO_MAIL tristate "Mail LED on Clevo notebook" - depends on LEDS_CLASS depends on X86 && SERIO_I8042 && DMI help This driver makes the mail LED accessible from userspace @@ -243,7 +226,6 @@ config LEDS_CLEVO_MAIL config LEDS_PCA955X tristate "LED Support for PCA955x I2C chips" - depends on LEDS_CLASS depends on I2C help This option enables support for LEDs connected to PCA955x @@ -252,7 +234,6 @@ config LEDS_PCA955X config LEDS_WM831X_STATUS tristate "LED support for status LEDs on WM831x PMICs" - depends on LEDS_CLASS depends on MFD_WM831X help This option enables support for the status LEDs of the WM831x @@ -260,7 +241,6 @@ config LEDS_WM831X_STATUS config LEDS_WM8350 tristate "LED Support for WM8350 AudioPlus PMIC" - depends on LEDS_CLASS depends on MFD_WM8350 help This option enables support for LEDs driven by the Wolfson @@ -268,7 +248,6 @@ config LEDS_WM8350 config LEDS_DA903X tristate "LED Support for DA9030/DA9034 PMIC" - depends on LEDS_CLASS depends on PMIC_DA903X help This option enables support for on-chip LED drivers found @@ -276,7 +255,6 @@ config LEDS_DA903X config LEDS_DAC124S085 tristate "LED Support for DAC124S085 SPI DAC" - depends on LEDS_CLASS depends on SPI help This option enables support for DAC124S085 SPI DAC from NatSemi, @@ -284,21 +262,18 @@ config LEDS_DAC124S085 config LEDS_PWM tristate "PWM driven LED Support" - depends on LEDS_CLASS depends on HAVE_PWM help This option enables support for pwm driven LEDs config LEDS_REGULATOR tristate "REGULATOR driven LED support" - depends on LEDS_CLASS depends on REGULATOR help This option enables support for regulator driven LEDs. config LEDS_BD2802 tristate "LED driver for BD2802 RGB LED" - depends on LEDS_CLASS depends on I2C help This option enables support for BD2802GU RGB LED driver chips @@ -306,7 +281,6 @@ config LEDS_BD2802 config LEDS_INTEL_SS4200 tristate "LED driver for Intel NAS SS4200 series" - depends on LEDS_CLASS depends on PCI && DMI help This option enables support for the Intel SS4200 series of @@ -316,7 +290,6 @@ config LEDS_INTEL_SS4200 config LEDS_LT3593 tristate "LED driver for LT3593 controllers" - depends on LEDS_CLASS depends on GENERIC_GPIO help This option enables support for LEDs driven by a Linear Technology @@ -325,7 +298,6 @@ config LEDS_LT3593 config LEDS_ADP5520 tristate "LED Support for ADP5520/ADP5501 PMIC" - depends on LEDS_CLASS depends on PMIC_ADP5520 help This option enables support for on-chip LED drivers found @@ -336,7 +308,6 @@ config LEDS_ADP5520 config LEDS_DELL_NETBOOKS tristate "External LED on Dell Business Netbooks" - depends on LEDS_CLASS depends on X86 && ACPI_WMI help This adds support for the Latitude 2100 and similar @@ -344,7 +315,6 @@ config LEDS_DELL_NETBOOKS config LEDS_MC13783 tristate "LED Support for MC13783 PMIC" - depends on LEDS_CLASS depends on MFD_MC13783 help This option enable support for on-chip LED drivers found @@ -352,7 +322,6 @@ config LEDS_MC13783 config LEDS_NS2 tristate "LED support for Network Space v2 GPIO LEDs" - depends on LEDS_CLASS depends on MACH_NETSPACE_V2 || MACH_INETSPACE_V2 || MACH_NETSPACE_MAX_V2 || D2NET_V2 default y help @@ -371,17 +340,17 @@ config LEDS_NETXBIG config LEDS_TRIGGERS bool "LED Trigger support" - depends on LEDS_CLASS help This option enables trigger support for the leds class. These triggers allow kernel events to drive the LEDs and can be configured via sysfs. If unsure, say Y. +if LEDS_TRIGGERS + comment "LED Triggers" config LEDS_TRIGGER_TIMER tristate "LED Timer Trigger" - depends on LEDS_TRIGGERS help This allows LEDs to be controlled by a programmable timer via sysfs. Some LED hardware can be programmed to start @@ -393,14 +362,12 @@ config LEDS_TRIGGER_TIMER config LEDS_TRIGGER_IDE_DISK bool "LED IDE Disk Trigger" depends on IDE_GD_ATA - depends on LEDS_TRIGGERS help This allows LEDs to be controlled by IDE disk activity. If unsure, say Y. config LEDS_TRIGGER_HEARTBEAT tristate "LED Heartbeat Trigger" - depends on LEDS_TRIGGERS help This allows LEDs to be controlled by a CPU load average. The flash frequency is a hyperbolic function of the 1-minute @@ -409,7 +376,6 @@ config LEDS_TRIGGER_HEARTBEAT config LEDS_TRIGGER_BACKLIGHT tristate "LED backlight Trigger" - depends on LEDS_TRIGGERS help This allows LEDs to be controlled as a backlight device: they turn off and on when the display is blanked and unblanked. @@ -418,7 +384,6 @@ config LEDS_TRIGGER_BACKLIGHT config LEDS_TRIGGER_GPIO tristate "LED GPIO Trigger" - depends on LEDS_TRIGGERS depends on GPIOLIB help This allows LEDs to be controlled by gpio events. It's good @@ -431,7 +396,6 @@ config LEDS_TRIGGER_GPIO config LEDS_TRIGGER_DEFAULT_ON tristate "LED Default ON Trigger" - depends on LEDS_TRIGGERS help This allows LEDs to be initialised in the ON state. If unsure, say Y. @@ -439,4 +403,8 @@ config LEDS_TRIGGER_DEFAULT_ON comment "iptables trigger is under Netfilter config (LED target)" depends on LEDS_TRIGGERS +endif # LEDS_TRIGGERS + +endif # LEDS_CLASS + endif # NEW_LEDS diff --git a/trunk/drivers/macintosh/Kconfig b/trunk/drivers/macintosh/Kconfig index fa51af11c6f1..3d7355ff7308 100644 --- a/trunk/drivers/macintosh/Kconfig +++ b/trunk/drivers/macintosh/Kconfig @@ -102,7 +102,6 @@ config ADB_PMU_LED config ADB_PMU_LED_IDE bool "Use front LED as IDE LED by default" depends on ADB_PMU_LED - depends on LEDS_CLASS select LEDS_TRIGGERS select LEDS_TRIGGER_IDE_DISK help diff --git a/trunk/drivers/media/common/tuners/Kconfig b/trunk/drivers/media/common/tuners/Kconfig index 78b089526e02..2385e6cca635 100644 --- a/trunk/drivers/media/common/tuners/Kconfig +++ b/trunk/drivers/media/common/tuners/Kconfig @@ -31,7 +31,7 @@ config MEDIA_TUNER select MEDIA_TUNER_TDA9887 if !MEDIA_TUNER_CUSTOMISE select MEDIA_TUNER_MC44S803 if !MEDIA_TUNER_CUSTOMISE -config MEDIA_TUNER_CUSTOMISE +menuconfig MEDIA_TUNER_CUSTOMISE bool "Customize analog and hybrid tuner modules to build" depends on MEDIA_TUNER default y if EMBEDDED @@ -44,8 +44,7 @@ config MEDIA_TUNER_CUSTOMISE If unsure say N. -menu "Customize TV tuners" - visible if MEDIA_TUNER_CUSTOMISE +if MEDIA_TUNER_CUSTOMISE config MEDIA_TUNER_SIMPLE tristate "Simple tuner support" @@ -186,4 +185,5 @@ config MEDIA_TUNER_TDA18218 default m if MEDIA_TUNER_CUSTOMISE help NXP TDA18218 silicon tuner driver. -endmenu + +endif # MEDIA_TUNER_CUSTOMISE diff --git a/trunk/drivers/media/dvb/frontends/Kconfig b/trunk/drivers/media/dvb/frontends/Kconfig index 96b27016670e..e9062b08a485 100644 --- a/trunk/drivers/media/dvb/frontends/Kconfig +++ b/trunk/drivers/media/dvb/frontends/Kconfig @@ -12,8 +12,9 @@ config DVB_FE_CUSTOMISE If unsure say N. +if DVB_FE_CUSTOMISE + menu "Customise DVB Frontends" - visible if DVB_FE_CUSTOMISE comment "Multistandard (satellite) frontends" depends on DVB_CORE @@ -618,3 +619,5 @@ config DVB_DUMMY_FE tristate "Dummy frontend driver" default n endmenu + +endif diff --git a/trunk/drivers/media/video/Kconfig b/trunk/drivers/media/video/Kconfig index 6830d2848bd7..ac16e815e275 100644 --- a/trunk/drivers/media/video/Kconfig +++ b/trunk/drivers/media/video/Kconfig @@ -112,7 +112,7 @@ config VIDEO_IR_I2C # menu "Encoders/decoders and other helper chips" - visible if !VIDEO_HELPER_CHIPS_AUTO + depends on !VIDEO_HELPER_CHIPS_AUTO comment "Audio decoders" diff --git a/trunk/drivers/mtd/ubi/io.c b/trunk/drivers/mtd/ubi/io.c index 811775aa8ee8..c2960ac9f39c 100644 --- a/trunk/drivers/mtd/ubi/io.c +++ b/trunk/drivers/mtd/ubi/io.c @@ -482,17 +482,10 @@ static int nor_erase_prepare(struct ubi_device *ubi, int pnum) uint32_t data = 0; struct ubi_vid_hdr vid_hdr; - /* - * It is important to first invalidate the EC header, and then the VID - * header. Otherwise a power cut may lead to valid EC header and - * invalid VID header, in which case UBI will treat this PEB as - * corrupted and will try to preserve it, and print scary warnings (see - * the header comment in scan.c for more information). - */ - addr = (loff_t)pnum * ubi->peb_size; + addr = (loff_t)pnum * ubi->peb_size + ubi->vid_hdr_aloffset; err = ubi->mtd->write(ubi->mtd, addr, 4, &written, (void *)&data); if (!err) { - addr += ubi->vid_hdr_aloffset; + addr -= ubi->vid_hdr_aloffset; err = ubi->mtd->write(ubi->mtd, addr, 4, &written, (void *)&data); if (!err) @@ -501,24 +494,18 @@ static int nor_erase_prepare(struct ubi_device *ubi, int pnum) /* * We failed to write to the media. This was observed with Spansion - * S29GL512N NOR flash. Most probably the previously eraseblock erasure - * was interrupted at a very inappropriate moment, so it became - * unwritable. In this case we probably anyway have garbage in this - * PEB. + * S29GL512N NOR flash. Most probably the eraseblock erasure was + * interrupted at a very inappropriate moment, so it became unwritable. + * In this case we probably anyway have garbage in this PEB. */ err1 = ubi_io_read_vid_hdr(ubi, pnum, &vid_hdr, 0); - if (err1 == UBI_IO_BAD_HDR_EBADMSG || err1 == UBI_IO_BAD_HDR) { - struct ubi_ec_hdr ec_hdr; - - err1 = ubi_io_read_ec_hdr(ubi, pnum, &ec_hdr, 0); - if (err1 == UBI_IO_BAD_HDR_EBADMSG || err1 == UBI_IO_BAD_HDR) - /* - * Both VID and EC headers are corrupted, so we can - * safely erase this PEB and not afraid that it will be - * treated as a valid PEB in case of an unclean reboot. - */ - return 0; - } + if (err1 == UBI_IO_BAD_HDR_EBADMSG || err1 == UBI_IO_BAD_HDR) + /* + * The VID header is corrupted, so we can safely erase this + * PEB and not afraid that it will be treated as a valid PEB in + * case of an unclean reboot. + */ + return 0; /* * The PEB contains a valid VID header, but we cannot invalidate it. diff --git a/trunk/drivers/mtd/ubi/scan.c b/trunk/drivers/mtd/ubi/scan.c index 79ca304fc4db..204345be8e62 100644 --- a/trunk/drivers/mtd/ubi/scan.c +++ b/trunk/drivers/mtd/ubi/scan.c @@ -953,10 +953,6 @@ static int process_eb(struct ubi_device *ubi, struct ubi_scan_info *si, * impossible to distinguish it from a PEB which just * contains garbage because of a power cut during erase * operation. So we just schedule this PEB for erasure. - * - * Besides, in case of NOR flash, we deliberatly - * corrupt both headers because NOR flash erasure is - * slow and can start from the end. */ err = 0; else diff --git a/trunk/drivers/parisc/dino.c b/trunk/drivers/parisc/dino.c index 9383063d2b16..d9f51485beee 100644 --- a/trunk/drivers/parisc/dino.c +++ b/trunk/drivers/parisc/dino.c @@ -349,6 +349,7 @@ static struct irq_chip dino_interrupt_type = { .name = "GSC-PCI", .unmask = dino_unmask_irq, .mask = dino_mask_irq, + .ack = no_ack_irq, }; diff --git a/trunk/drivers/parisc/eisa.c b/trunk/drivers/parisc/eisa.c index e860038b0b84..1211974f55aa 100644 --- a/trunk/drivers/parisc/eisa.c +++ b/trunk/drivers/parisc/eisa.c @@ -186,6 +186,7 @@ static struct irq_chip eisa_interrupt_type = { .name = "EISA", .unmask = eisa_unmask_irq, .mask = eisa_mask_irq, + .ack = no_ack_irq, }; static irqreturn_t eisa_irq(int wax_irq, void *intr_dev) @@ -339,7 +340,7 @@ static int __init eisa_probe(struct parisc_device *dev) setup_irq(2, &irq2_action); for (i = 0; i < 16; i++) { set_irq_chip_and_handler(i, &eisa_interrupt_type, - handle_simple_irq); + handle_level_irq); } EISA_bus = 1; diff --git a/trunk/drivers/parisc/gsc.c b/trunk/drivers/parisc/gsc.c index 772b1939ac21..e605298e3aee 100644 --- a/trunk/drivers/parisc/gsc.c +++ b/trunk/drivers/parisc/gsc.c @@ -143,6 +143,7 @@ static struct irq_chip gsc_asic_interrupt_type = { .name = "GSC-ASIC", .unmask = gsc_asic_unmask_irq, .mask = gsc_asic_mask_irq, + .ack = no_ack_irq, }; int gsc_assign_irq(struct irq_chip *type, void *data) @@ -152,7 +153,7 @@ int gsc_assign_irq(struct irq_chip *type, void *data) if (irq > GSC_IRQ_MAX) return NO_IRQ; - set_irq_chip_and_handler(irq, type, handle_simple_irq); + set_irq_chip_and_handler(irq, type, handle_level_irq); set_irq_chip_data(irq, data); return irq++; diff --git a/trunk/drivers/parisc/iosapic.c b/trunk/drivers/parisc/iosapic.c index 0327894bf235..a3120a09c43d 100644 --- a/trunk/drivers/parisc/iosapic.c +++ b/trunk/drivers/parisc/iosapic.c @@ -669,13 +669,6 @@ printk("\n"); DBG(KERN_DEBUG "enable_irq(%d): eoi(%p, 0x%x)\n", irq, vi->eoi_addr, vi->eoi_data); iosapic_eoi(vi->eoi_addr, vi->eoi_data); -} - -static void iosapic_eoi_irq(unsigned int irq) -{ - struct vector_info *vi = get_irq_chip_data(irq); - - iosapic_eoi(vi->eoi_addr, vi->eoi_data); cpu_eoi_irq(irq); } @@ -712,7 +705,6 @@ static struct irq_chip iosapic_interrupt_type = { .unmask = iosapic_unmask_irq, .mask = iosapic_mask_irq, .ack = cpu_ack_irq, - .eoi = iosapic_eoi_irq, #ifdef CONFIG_SMP .set_affinity = iosapic_set_affinity_irq, #endif diff --git a/trunk/drivers/parisc/led.c b/trunk/drivers/parisc/led.c index f2f501e5b6a0..2350e8a86eef 100644 --- a/trunk/drivers/parisc/led.c +++ b/trunk/drivers/parisc/led.c @@ -64,7 +64,6 @@ static unsigned int led_diskio __read_mostly = 1; static unsigned int led_lanrxtx __read_mostly = 1; static char lcd_text[32] __read_mostly; static char lcd_text_default[32] __read_mostly; -static int lcd_no_led_support __read_mostly = 0; /* KittyHawk doesn't support LED on its LCD */ static struct workqueue_struct *led_wq; @@ -116,7 +115,7 @@ lcd_info __attribute__((aligned(8))) __read_mostly = .lcd_width = 16, .lcd_cmd_reg_addr = KITTYHAWK_LCD_CMD, .lcd_data_reg_addr = KITTYHAWK_LCD_DATA, - .min_cmd_delay = 80, + .min_cmd_delay = 40, .reset_cmd1 = 0x80, .reset_cmd2 = 0xc0, }; @@ -136,9 +135,6 @@ static int start_task(void) /* Display the default text now */ if (led_type == LED_HASLCD) lcd_print( lcd_text_default ); - /* KittyHawk has no LED support on its LCD */ - if (lcd_no_led_support) return 0; - /* Create the work queue and queue the LED task */ led_wq = create_singlethread_workqueue("led_wq"); queue_delayed_work(led_wq, &led_task, 0); @@ -252,13 +248,9 @@ static int __init led_create_procfs(void) proc_pdc_root = proc_mkdir("pdc", 0); if (!proc_pdc_root) return -1; - - if (!lcd_no_led_support) - { - ent = proc_create_data("led", S_IRUGO|S_IWUSR, proc_pdc_root, - &led_proc_fops, (void *)LED_NOLCD); /* LED */ - if (!ent) return -1; - } + ent = proc_create_data("led", S_IRUGO|S_IWUSR, proc_pdc_root, + &led_proc_fops, (void *)LED_NOLCD); /* LED */ + if (!ent) return -1; if (led_type == LED_HASLCD) { @@ -700,7 +692,6 @@ int __init led_init(void) case 0x58B: /* KittyHawk DC2 100 (K200) */ printk(KERN_INFO "%s: KittyHawk-Machine (hversion 0x%x) found, " "LED detection skipped.\n", __FILE__, CPU_HVERSION); - lcd_no_led_support = 1; goto found; /* use the preinitialized values of lcd_info */ } diff --git a/trunk/drivers/parisc/superio.c b/trunk/drivers/parisc/superio.c index 28241532c0fd..0846dafdfff1 100644 --- a/trunk/drivers/parisc/superio.c +++ b/trunk/drivers/parisc/superio.c @@ -323,6 +323,7 @@ static struct irq_chip superio_interrupt_type = { .name = SUPERIO, .unmask = superio_unmask_irq, .mask = superio_mask_irq, + .ack = no_ack_irq, }; #ifdef DEBUG_SUPERIO_INIT @@ -353,7 +354,7 @@ int superio_fixup_irq(struct pci_dev *pcidev) #endif for (i = 0; i < 16; i++) { - set_irq_chip_and_handler(i, &superio_interrupt_type, handle_simple_irq); + set_irq_chip_and_handler(i, &superio_interrupt_type, handle_level_irq); } /* diff --git a/trunk/drivers/pcmcia/soc_common.c b/trunk/drivers/pcmcia/soc_common.c index 2fe8cb8e95cd..3753fd0722e7 100644 --- a/trunk/drivers/pcmcia/soc_common.c +++ b/trunk/drivers/pcmcia/soc_common.c @@ -70,7 +70,6 @@ void soc_pcmcia_debug(struct soc_pcmcia_socket *skt, const char *func, va_end(args); } } -EXPORT_SYMBOL(soc_pcmcia_debug); #endif diff --git a/trunk/drivers/platform/x86/asus-laptop.c b/trunk/drivers/platform/x86/asus-laptop.c index d235f44fd7a3..60a5a5c6b50a 100644 --- a/trunk/drivers/platform/x86/asus-laptop.c +++ b/trunk/drivers/platform/x86/asus-laptop.c @@ -81,8 +81,6 @@ MODULE_PARM_DESC(wapf, "WAPF value"); static int wlan_status = 1; static int bluetooth_status = 1; -static int wimax_status = -1; -static int wwan_status = -1; module_param(wlan_status, int, 0444); MODULE_PARM_DESC(wlan_status, "Set the wireless status on boot " @@ -94,16 +92,6 @@ MODULE_PARM_DESC(bluetooth_status, "Set the wireless status on boot " "(0 = disabled, 1 = enabled, -1 = don't do anything). " "default is 1"); -module_param(wimax_status, int, 0444); -MODULE_PARM_DESC(wimax_status, "Set the wireless status on boot " - "(0 = disabled, 1 = enabled, -1 = don't do anything). " - "default is 1"); - -module_param(wwan_status, int, 0444); -MODULE_PARM_DESC(wwan_status, "Set the wireless status on boot " - "(0 = disabled, 1 = enabled, -1 = don't do anything). " - "default is 1"); - /* * Some events we use, same for all Asus */ @@ -126,8 +114,6 @@ MODULE_PARM_DESC(wwan_status, "Set the wireless status on boot " */ #define WL_RSTS 0x01 /* internal Wifi */ #define BT_RSTS 0x02 /* internal Bluetooth */ -#define WM_RSTS 0x08 /* internal wimax */ -#define WW_RSTS 0x20 /* internal wwan */ /* LED */ #define METHOD_MLED "MLED" @@ -146,11 +132,6 @@ MODULE_PARM_DESC(wwan_status, "Set the wireless status on boot " */ #define METHOD_WLAN "WLED" #define METHOD_BLUETOOTH "BLED" - -/* WWAN and WIMAX */ -#define METHOD_WWAN "GSMC" -#define METHOD_WIMAX "WMXC" - #define METHOD_WL_STATUS "RSTS" /* Brightness */ @@ -901,64 +882,6 @@ static ssize_t store_bluetooth(struct device *dev, return sysfs_acpi_set(asus, buf, count, METHOD_BLUETOOTH); } -/* - * Wimax - */ -static int asus_wimax_set(struct asus_laptop *asus, int status) -{ - if (write_acpi_int(asus->handle, METHOD_WIMAX, !!status)) { - pr_warning("Error setting wimax status to %d", status); - return -EIO; - } - return 0; -} - -static ssize_t show_wimax(struct device *dev, - struct device_attribute *attr, char *buf) -{ - struct asus_laptop *asus = dev_get_drvdata(dev); - - return sprintf(buf, "%d\n", asus_wireless_status(asus, WM_RSTS)); -} - -static ssize_t store_wimax(struct device *dev, - struct device_attribute *attr, const char *buf, - size_t count) -{ - struct asus_laptop *asus = dev_get_drvdata(dev); - - return sysfs_acpi_set(asus, buf, count, METHOD_WIMAX); -} - -/* - * Wwan - */ -static int asus_wwan_set(struct asus_laptop *asus, int status) -{ - if (write_acpi_int(asus->handle, METHOD_WWAN, !!status)) { - pr_warning("Error setting wwan status to %d", status); - return -EIO; - } - return 0; -} - -static ssize_t show_wwan(struct device *dev, - struct device_attribute *attr, char *buf) -{ - struct asus_laptop *asus = dev_get_drvdata(dev); - - return sprintf(buf, "%d\n", asus_wireless_status(asus, WW_RSTS)); -} - -static ssize_t store_wwan(struct device *dev, - struct device_attribute *attr, const char *buf, - size_t count) -{ - struct asus_laptop *asus = dev_get_drvdata(dev); - - return sysfs_acpi_set(asus, buf, count, METHOD_WWAN); -} - /* * Display */ @@ -1279,8 +1202,6 @@ static DEVICE_ATTR(infos, S_IRUGO, show_infos, NULL); static DEVICE_ATTR(wlan, S_IRUGO | S_IWUSR, show_wlan, store_wlan); static DEVICE_ATTR(bluetooth, S_IRUGO | S_IWUSR, show_bluetooth, store_bluetooth); -static DEVICE_ATTR(wimax, S_IRUGO | S_IWUSR, show_wimax, store_wimax); -static DEVICE_ATTR(wwan, S_IRUGO | S_IWUSR, show_wwan, store_wwan); static DEVICE_ATTR(display, S_IRUGO | S_IWUSR, show_disp, store_disp); static DEVICE_ATTR(ledd, S_IRUGO | S_IWUSR, show_ledd, store_ledd); static DEVICE_ATTR(ls_level, S_IRUGO | S_IWUSR, show_lslvl, store_lslvl); @@ -1291,8 +1212,6 @@ static struct attribute *asus_attributes[] = { &dev_attr_infos.attr, &dev_attr_wlan.attr, &dev_attr_bluetooth.attr, - &dev_attr_wimax.attr, - &dev_attr_wwan.attr, &dev_attr_display.attr, &dev_attr_ledd.attr, &dev_attr_ls_level.attr, @@ -1320,13 +1239,6 @@ static mode_t asus_sysfs_is_visible(struct kobject *kobj, } else if (attr == &dev_attr_display.attr) { supported = !acpi_check_handle(handle, METHOD_SWITCH_DISPLAY, NULL); - } else if (attr == &dev_attr_wimax.attr) { - supported = - !acpi_check_handle(asus->handle, METHOD_WIMAX, NULL); - - } else if (attr == &dev_attr_wwan.attr) { - supported = !acpi_check_handle(asus->handle, METHOD_WWAN, NULL); - } else if (attr == &dev_attr_ledd.attr) { supported = !acpi_check_handle(handle, METHOD_LEDD, NULL); @@ -1485,8 +1397,7 @@ static int asus_laptop_get_info(struct asus_laptop *asus) /* * The HWRS method return informations about the hardware. - * 0x80 bit is for WLAN, 0x100 for Bluetooth, - * 0x40 for WWAN, 0x10 for WIMAX. + * 0x80 bit is for WLAN, 0x100 for Bluetooth. * The significance of others is yet to be found. */ status = @@ -1529,12 +1440,6 @@ static int __devinit asus_acpi_init(struct asus_laptop *asus) if (wlan_status >= 0) asus_wlan_set(asus, !!wlan_status); - if (wimax_status >= 0) - asus_wimax_set(asus, !!wimax_status); - - if (wwan_status >= 0) - asus_wwan_set(asus, !!wwan_status); - /* Keyboard Backlight is on by default */ if (!acpi_check_handle(asus->handle, METHOD_KBD_LIGHT_SET, NULL)) asus_kled_set(asus, 1); diff --git a/trunk/drivers/platform/x86/eeepc-wmi.c b/trunk/drivers/platform/x86/eeepc-wmi.c index 0d50fbbe2478..462ceab93f87 100644 --- a/trunk/drivers/platform/x86/eeepc-wmi.c +++ b/trunk/drivers/platform/x86/eeepc-wmi.c @@ -298,8 +298,8 @@ static void eeepc_wmi_notify(u32 value, void *context) kfree(obj); } -static ssize_t store_cpufv(struct device *dev, struct device_attribute *attr, - const char *buf, size_t count) +static int store_cpufv(struct device *dev, struct device_attribute *attr, + const char *buf, size_t count) { int value; struct acpi_buffer input = { (acpi_size)sizeof(value), &value }; diff --git a/trunk/drivers/platform/x86/hp-wmi.c b/trunk/drivers/platform/x86/hp-wmi.c index 9e05af9c41cb..1dac659b5e0c 100644 --- a/trunk/drivers/platform/x86/hp-wmi.c +++ b/trunk/drivers/platform/x86/hp-wmi.c @@ -172,8 +172,6 @@ static int hp_wmi_perform_query(int query, int write, u32 *buffer, bios_return = *((struct bios_return *)obj->buffer.pointer); memcpy(buffer, &bios_return.value, sizeof(bios_return.value)); - - kfree(obj); return 0; } diff --git a/trunk/drivers/platform/x86/ibm_rtl.c b/trunk/drivers/platform/x86/ibm_rtl.c index 94a114aa8e28..3c2c6b91ecb3 100644 --- a/trunk/drivers/platform/x86/ibm_rtl.c +++ b/trunk/drivers/platform/x86/ibm_rtl.c @@ -28,7 +28,6 @@ #include #include #include -#include #include #include @@ -221,13 +220,32 @@ static void rtl_teardown_sysfs(void) { sysdev_class_unregister(&class_rtl); } +static int dmi_check_cb(const struct dmi_system_id *id) +{ + RTL_DEBUG("found IBM server '%s'\n", id->ident); + return 0; +} + +#define ibm_dmi_entry(NAME, TYPE) \ +{ \ + .ident = NAME, \ + .matches = { \ + DMI_MATCH(DMI_SYS_VENDOR, "IBM"), \ + DMI_MATCH(DMI_PRODUCT_NAME, TYPE), \ + }, \ + .callback = dmi_check_cb \ +} static struct dmi_system_id __initdata ibm_rtl_dmi_table[] = { - { \ - .matches = { \ - DMI_MATCH(DMI_SYS_VENDOR, "IBM"), \ - }, \ - }, + ibm_dmi_entry("BladeCenter LS21", "7971"), + ibm_dmi_entry("BladeCenter LS22", "7901"), + ibm_dmi_entry("BladeCenter HS21 XM", "7995"), + ibm_dmi_entry("BladeCenter HS22", "7870"), + ibm_dmi_entry("BladeCenter HS22V", "7871"), + ibm_dmi_entry("System x3550 M2", "7946"), + ibm_dmi_entry("System x3650 M2", "7947"), + ibm_dmi_entry("System x3550 M3", "7944"), + ibm_dmi_entry("System x3650 M3", "7945"), { } }; @@ -239,7 +257,7 @@ static int __init ibm_rtl_init(void) { if (force) pr_warning("ibm-rtl: module loaded by force\n"); /* first ensure that we are running on IBM HW */ - else if (efi_enabled || !dmi_check_system(ibm_rtl_dmi_table)) + else if (!dmi_check_system(ibm_rtl_dmi_table)) return -ENODEV; /* Get the address for the Extended BIOS Data Area */ @@ -284,7 +302,7 @@ static int __init ibm_rtl_init(void) { RTL_DEBUG("rtl_cmd_width = %u, rtl_cmd_type = %u\n", rtl_cmd_width, rtl_cmd_type); addr = ioread32(&rtl_table->cmd_port_address); - RTL_DEBUG("addr = %#llx\n", (unsigned long long)addr); + RTL_DEBUG("addr = %#llx\n", addr); plen = rtl_cmd_width/sizeof(char); rtl_cmd_addr = rtl_port_map(addr, plen); RTL_DEBUG("rtl_cmd_addr = %#llx\n", (u64)rtl_cmd_addr); diff --git a/trunk/drivers/platform/x86/msi-wmi.c b/trunk/drivers/platform/x86/msi-wmi.c index 35278ad7e628..42a5469a2459 100644 --- a/trunk/drivers/platform/x86/msi-wmi.c +++ b/trunk/drivers/platform/x86/msi-wmi.c @@ -43,18 +43,16 @@ MODULE_ALIAS("wmi:B6F3EEF2-3D2F-49DC-9DE3-85BCE18C62F2"); #define dprintk(msg...) pr_debug(DRV_PFX msg) -#define SCANCODE_BASE 0xD0 -#define MSI_WMI_BRIGHTNESSUP SCANCODE_BASE -#define MSI_WMI_BRIGHTNESSDOWN (SCANCODE_BASE + 1) -#define MSI_WMI_VOLUMEUP (SCANCODE_BASE + 2) -#define MSI_WMI_VOLUMEDOWN (SCANCODE_BASE + 3) -#define MSI_WMI_MUTE (SCANCODE_BASE + 4) +#define KEYCODE_BASE 0xD0 +#define MSI_WMI_BRIGHTNESSUP KEYCODE_BASE +#define MSI_WMI_BRIGHTNESSDOWN (KEYCODE_BASE + 1) +#define MSI_WMI_VOLUMEUP (KEYCODE_BASE + 2) +#define MSI_WMI_VOLUMEDOWN (KEYCODE_BASE + 3) static struct key_entry msi_wmi_keymap[] = { { KE_KEY, MSI_WMI_BRIGHTNESSUP, {KEY_BRIGHTNESSUP} }, { KE_KEY, MSI_WMI_BRIGHTNESSDOWN, {KEY_BRIGHTNESSDOWN} }, { KE_KEY, MSI_WMI_VOLUMEUP, {KEY_VOLUMEUP} }, { KE_KEY, MSI_WMI_VOLUMEDOWN, {KEY_VOLUMEDOWN} }, - { KE_KEY, MSI_WMI_MUTE, {KEY_MUTE} }, { KE_END, 0} }; static ktime_t last_pressed[ARRAY_SIZE(msi_wmi_keymap) - 1]; @@ -171,7 +169,7 @@ static void msi_wmi_notify(u32 value, void *context) ktime_t diff; cur = ktime_get_real(); diff = ktime_sub(cur, last_pressed[key->code - - SCANCODE_BASE]); + KEYCODE_BASE]); /* Ignore event if the same event happened in a 50 ms timeframe -> Key press may result in 10-20 GPEs */ if (ktime_to_us(diff) < 1000 * 50) { @@ -180,7 +178,7 @@ static void msi_wmi_notify(u32 value, void *context) key->code, ktime_to_us(diff)); return; } - last_pressed[key->code - SCANCODE_BASE] = cur; + last_pressed[key->code - KEYCODE_BASE] = cur; if (key->type == KE_KEY && /* Brightness is served via acpi video driver */ diff --git a/trunk/drivers/platform/x86/thinkpad_acpi.c b/trunk/drivers/platform/x86/thinkpad_acpi.c index e8c21994b36d..2d61186ad5a2 100644 --- a/trunk/drivers/platform/x86/thinkpad_acpi.c +++ b/trunk/drivers/platform/x86/thinkpad_acpi.c @@ -8497,6 +8497,7 @@ static void ibm_exit(struct ibm_struct *ibm) ibm->acpi->type, dispatch_acpi_notify); ibm->flags.acpi_notify_installed = 0; + ibm->flags.acpi_notify_installed = 0; } if (ibm->flags.proc_created) { diff --git a/trunk/drivers/platform/x86/toshiba_acpi.c b/trunk/drivers/platform/x86/toshiba_acpi.c index 4276da7291b8..06f304f46e02 100644 --- a/trunk/drivers/platform/x86/toshiba_acpi.c +++ b/trunk/drivers/platform/x86/toshiba_acpi.c @@ -135,7 +135,6 @@ static const struct key_entry toshiba_acpi_keymap[] __initconst = { { KE_KEY, 0x141, { KEY_BRIGHTNESSUP } }, { KE_KEY, 0x142, { KEY_WLAN } }, { KE_KEY, 0x143, { KEY_PROG1 } }, - { KE_KEY, 0x17f, { KEY_FN } }, { KE_KEY, 0xb05, { KEY_PROG2 } }, { KE_KEY, 0xb06, { KEY_WWW } }, { KE_KEY, 0xb07, { KEY_MAIL } }, diff --git a/trunk/drivers/platform/x86/wmi.c b/trunk/drivers/platform/x86/wmi.c index aecd9a9b549f..104b77c87ef5 100644 --- a/trunk/drivers/platform/x86/wmi.c +++ b/trunk/drivers/platform/x86/wmi.c @@ -755,7 +755,7 @@ static bool guid_already_parsed(const char *guid_string) struct wmi_block *wblock; list_for_each_entry(wblock, &wmi_block_list, list) - if (memcmp(wblock->gblock.guid, guid_string, 16) == 0) + if (strncmp(wblock->gblock.guid, guid_string, 16) == 0) return true; return false; diff --git a/trunk/drivers/s390/cio/css.c b/trunk/drivers/s390/cio/css.c index 825951b6b83f..a5050e217150 100644 --- a/trunk/drivers/s390/cio/css.c +++ b/trunk/drivers/s390/cio/css.c @@ -635,7 +635,7 @@ static void css_process_crw(struct crw *crw0, struct crw *crw1, int overflow) init_subchannel_id(&mchk_schid); mchk_schid.sch_no = crw0->rsid; if (crw1) - mchk_schid.ssid = (crw1->rsid >> 4) & 3; + mchk_schid.ssid = (crw1->rsid >> 8) & 3; /* * Since we are always presented with IPI in the CRW, we have to diff --git a/trunk/drivers/video/da8xx-fb.c b/trunk/drivers/video/da8xx-fb.c index c265aed09e04..cad7d45c8bac 100644 --- a/trunk/drivers/video/da8xx-fb.c +++ b/trunk/drivers/video/da8xx-fb.c @@ -1029,6 +1029,10 @@ static int __init fb_probe(struct platform_device *device) goto err_release_pl_mem; } + ret = request_irq(par->irq, lcdc_irq_handler, 0, DRIVER_NAME, par); + if (ret) + goto err_release_pl_mem; + /* Initialize par */ da8xx_fb_info->var.bits_per_pixel = lcd_cfg->bpp; @@ -1056,7 +1060,7 @@ static int __init fb_probe(struct platform_device *device) ret = fb_alloc_cmap(&da8xx_fb_info->cmap, PALETTE_SIZE, 0); if (ret) - goto err_release_pl_mem; + goto err_free_irq; da8xx_fb_info->cmap.len = par->palette_sz; /* initialize var_screeninfo */ @@ -1084,13 +1088,8 @@ static int __init fb_probe(struct platform_device *device) goto err_cpu_freq; } #endif - - ret = request_irq(par->irq, lcdc_irq_handler, 0, DRIVER_NAME, par); - if (ret) - goto irq_freq; return 0; -irq_freq: #ifdef CONFIG_CPU_FREQ err_cpu_freq: unregister_framebuffer(da8xx_fb_info); @@ -1099,6 +1098,9 @@ static int __init fb_probe(struct platform_device *device) err_dealloc_cmap: fb_dealloc_cmap(&da8xx_fb_info->cmap); +err_free_irq: + free_irq(par->irq, par); + err_release_pl_mem: dma_free_coherent(NULL, PALETTE_SIZE, par->v_palette_base, par->p_palette_base); diff --git a/trunk/drivers/video/fbcmap.c b/trunk/drivers/video/fbcmap.c index 5c3960da755a..affdf3e32cf3 100644 --- a/trunk/drivers/video/fbcmap.c +++ b/trunk/drivers/video/fbcmap.c @@ -80,7 +80,6 @@ static const struct fb_cmap default_16_colors = { * @cmap: frame buffer colormap structure * @len: length of @cmap * @transp: boolean, 1 if there is transparency, 0 otherwise - * @flags: flags for kmalloc memory allocation * * Allocates memory for a colormap @cmap. @len is the * number of entries in the palette. diff --git a/trunk/drivers/video/geode/lxfb.h b/trunk/drivers/video/geode/lxfb.h index be8ccb47ebe0..e4c4d89b7860 100644 --- a/trunk/drivers/video/geode/lxfb.h +++ b/trunk/drivers/video/geode/lxfb.h @@ -22,7 +22,6 @@ #define DC_HFILT_COUNT 0x100 #define DC_VFILT_COUNT 0x100 #define VP_COEFF_SIZE 0x1000 -#define VP_PAL_COUNT 0x100 #define OUTPUT_CRT 0x01 #define OUTPUT_PANEL 0x02 @@ -49,8 +48,7 @@ struct lxfb_par { uint64_t vp[VP_REG_COUNT]; uint64_t fp[FP_REG_COUNT]; - uint32_t dc_pal[DC_PAL_COUNT]; - uint32_t vp_pal[VP_PAL_COUNT]; + uint32_t pal[DC_PAL_COUNT]; uint32_t hcoeff[DC_HFILT_COUNT * 2]; uint32_t vcoeff[DC_VFILT_COUNT]; uint32_t vp_coeff[VP_COEFF_SIZE / 4]; diff --git a/trunk/drivers/video/geode/lxfb_ops.c b/trunk/drivers/video/geode/lxfb_ops.c index 79e9abc72b83..85ec7f64c42a 100644 --- a/trunk/drivers/video/geode/lxfb_ops.c +++ b/trunk/drivers/video/geode/lxfb_ops.c @@ -610,15 +610,10 @@ static void lx_save_regs(struct lxfb_par *par) memcpy(par->vp, par->vp_regs, sizeof(par->vp)); memcpy(par->fp, par->vp_regs + VP_FP_START, sizeof(par->fp)); - /* save the display controller palette */ + /* save the palette */ write_dc(par, DC_PAL_ADDRESS, 0); - for (i = 0; i < ARRAY_SIZE(par->dc_pal); i++) - par->dc_pal[i] = read_dc(par, DC_PAL_DATA); - - /* save the video processor palette */ - write_vp(par, VP_PAR, 0); - for (i = 0; i < ARRAY_SIZE(par->vp_pal); i++) - par->vp_pal[i] = read_vp(par, VP_PDR); + for (i = 0; i < ARRAY_SIZE(par->pal); i++) + par->pal[i] = read_dc(par, DC_PAL_DATA); /* save the horizontal filter coefficients */ filt = par->dc[DC_IRQ_FILT_CTL] | DC_IRQ_FILT_CTL_H_FILT_SEL; @@ -711,8 +706,8 @@ static void lx_restore_display_ctlr(struct lxfb_par *par) /* restore the palette */ write_dc(par, DC_PAL_ADDRESS, 0); - for (i = 0; i < ARRAY_SIZE(par->dc_pal); i++) - write_dc(par, DC_PAL_DATA, par->dc_pal[i]); + for (i = 0; i < ARRAY_SIZE(par->pal); i++) + write_dc(par, DC_PAL_DATA, par->pal[i]); /* restore the horizontal filter coefficients */ filt = par->dc[DC_IRQ_FILT_CTL] | DC_IRQ_FILT_CTL_H_FILT_SEL; @@ -756,11 +751,6 @@ static void lx_restore_video_proc(struct lxfb_par *par) } } - /* restore video processor palette */ - write_vp(par, VP_PAR, 0); - for (i = 0; i < ARRAY_SIZE(par->vp_pal); i++) - write_vp(par, VP_PDR, par->vp_pal[i]); - /* restore video coeff ram */ memcpy(par->vp_regs + VP_VCR, par->vp_coeff, sizeof(par->vp_coeff)); } diff --git a/trunk/drivers/xen/balloon.c b/trunk/drivers/xen/balloon.c index 43f9f02c7db0..2b17ad5b4b32 100644 --- a/trunk/drivers/xen/balloon.c +++ b/trunk/drivers/xen/balloon.c @@ -412,16 +412,8 @@ static int __init balloon_init(void) register_balloon(&balloon_sysdev); - /* - * Initialise the balloon with excess memory space. We need - * to make sure we don't add memory which doesn't exist or - * logically exist. The E820 map can be trimmed to be smaller - * than the amount of physical memory due to the mem= command - * line parameter. And if this is a 32-bit non-HIGHMEM kernel - * on a system with memory which requires highmem to access, - * don't try to use it. - */ - extra_pfn_end = min(min(max_pfn, e820_end_of_ram_pfn()), + /* Initialise the balloon with excess memory space. */ + extra_pfn_end = min(e820_end_of_ram_pfn(), (unsigned long)PFN_DOWN(xen_extra_mem_start + xen_extra_mem_size)); for (pfn = PFN_UP(xen_extra_mem_start); pfn < extra_pfn_end; diff --git a/trunk/drivers/xen/events.c b/trunk/drivers/xen/events.c index 31af0ac31a98..2811bb988ea0 100644 --- a/trunk/drivers/xen/events.c +++ b/trunk/drivers/xen/events.c @@ -105,6 +105,7 @@ struct irq_info static struct irq_info *irq_info; static int *pirq_to_irq; +static int nr_pirqs; static int *evtchn_to_irq; struct cpu_evtchn_s { @@ -384,17 +385,12 @@ static int get_nr_hw_irqs(void) return ret; } -static int find_unbound_pirq(int type) +/* callers of this function should make sure that PHYSDEVOP_get_nr_pirqs + * succeeded otherwise nr_pirqs won't hold the right value */ +static int find_unbound_pirq(void) { - int rc, i; - struct physdev_get_free_pirq op_get_free_pirq; - op_get_free_pirq.type = type; - - rc = HYPERVISOR_physdev_op(PHYSDEVOP_get_free_pirq, &op_get_free_pirq); - if (!rc) - return op_get_free_pirq.pirq; - - for (i = 0; i < nr_irqs; i++) { + int i; + for (i = nr_pirqs-1; i >= 0; i--) { if (pirq_to_irq[i] < 0) return i; } @@ -427,7 +423,7 @@ static int find_unbound_irq(void) if (irq == start) goto no_irqs; - res = irq_alloc_desc_at(irq, -1); + res = irq_alloc_desc_at(irq, 0); if (WARN_ON(res != irq)) return -1; @@ -615,10 +611,10 @@ int xen_map_pirq_gsi(unsigned pirq, unsigned gsi, int shareable, char *name) spin_lock(&irq_mapping_update_lock); - if ((pirq > nr_irqs) || (gsi > nr_irqs)) { + if ((pirq > nr_pirqs) || (gsi > nr_irqs)) { printk(KERN_WARNING "xen_map_pirq_gsi: %s %s is incorrect!\n", - pirq > nr_irqs ? "pirq" :"", - gsi > nr_irqs ? "gsi" : ""); + pirq > nr_pirqs ? "nr_pirqs" :"", + gsi > nr_irqs ? "nr_irqs" : ""); goto out; } @@ -634,7 +630,7 @@ int xen_map_pirq_gsi(unsigned pirq, unsigned gsi, int shareable, char *name) if (identity_mapped_irq(gsi) || (!xen_initial_domain() && xen_pv_domain())) { irq = gsi; - irq_alloc_desc_at(irq, -1); + irq_alloc_desc_at(irq, 0); } else irq = find_unbound_irq(); @@ -668,21 +664,17 @@ int xen_map_pirq_gsi(unsigned pirq, unsigned gsi, int shareable, char *name) #include #include "../pci/msi.h" -void xen_allocate_pirq_msi(char *name, int *irq, int *pirq, int alloc) +void xen_allocate_pirq_msi(char *name, int *irq, int *pirq) { spin_lock(&irq_mapping_update_lock); - if (alloc & XEN_ALLOC_IRQ) { - *irq = find_unbound_irq(); - if (*irq == -1) - goto out; - } + *irq = find_unbound_irq(); + if (*irq == -1) + goto out; - if (alloc & XEN_ALLOC_PIRQ) { - *pirq = find_unbound_pirq(MAP_PIRQ_TYPE_MSI); - if (*pirq == -1) - goto out; - } + *pirq = find_unbound_pirq(); + if (*pirq == -1) + goto out; set_irq_chip_and_handler_name(*irq, &xen_pirq_chip, handle_level_irq, name); @@ -770,7 +762,6 @@ int xen_destroy_irq(int irq) printk(KERN_WARNING "unmap irq failed %d\n", rc); goto out; } - pirq_to_irq[info->u.pirq.pirq] = -1; } irq_info[irq] = mk_unbound_info(); @@ -791,11 +782,6 @@ int xen_gsi_from_irq(unsigned irq) return gsi_from_irq(irq); } -int xen_irq_from_pirq(unsigned pirq) -{ - return pirq_to_irq[pirq]; -} - int bind_evtchn_to_irq(unsigned int evtchn) { int irq; @@ -1293,42 +1279,6 @@ static int retrigger_dynirq(unsigned int irq) return ret; } -static void restore_cpu_pirqs(void) -{ - int pirq, rc, irq, gsi; - struct physdev_map_pirq map_irq; - - for (pirq = 0; pirq < nr_irqs; pirq++) { - irq = pirq_to_irq[pirq]; - if (irq == -1) - continue; - - /* save/restore of PT devices doesn't work, so at this point the - * only devices present are GSI based emulated devices */ - gsi = gsi_from_irq(irq); - if (!gsi) - continue; - - map_irq.domid = DOMID_SELF; - map_irq.type = MAP_PIRQ_TYPE_GSI; - map_irq.index = gsi; - map_irq.pirq = pirq; - - rc = HYPERVISOR_physdev_op(PHYSDEVOP_map_pirq, &map_irq); - if (rc) { - printk(KERN_WARNING "xen map irq failed gsi=%d irq=%d pirq=%d rc=%d\n", - gsi, irq, pirq, rc); - irq_info[irq] = mk_unbound_info(); - pirq_to_irq[pirq] = -1; - continue; - } - - printk(KERN_DEBUG "xen: --> irq=%d, pirq=%d\n", irq, map_irq.pirq); - - startup_pirq(irq); - } -} - static void restore_cpu_virqs(unsigned int cpu) { struct evtchn_bind_virq bind_virq; @@ -1472,8 +1422,6 @@ void xen_irq_resume(void) unmask_evtchn(evtchn); } - - restore_cpu_pirqs(); } static struct irq_chip xen_dynamic_chip __read_mostly = { @@ -1558,17 +1506,26 @@ void xen_callback_vector(void) {} void __init xen_init_IRQ(void) { - int i; + int i, rc; + struct physdev_nr_pirqs op_nr_pirqs; cpu_evtchn_mask_p = kcalloc(nr_cpu_ids, sizeof(struct cpu_evtchn_s), GFP_KERNEL); irq_info = kcalloc(nr_irqs, sizeof(*irq_info), GFP_KERNEL); - /* We are using nr_irqs as the maximum number of pirq available but - * that number is actually chosen by Xen and we don't know exactly - * what it is. Be careful choosing high pirq numbers. */ - pirq_to_irq = kcalloc(nr_irqs, sizeof(*pirq_to_irq), GFP_KERNEL); - for (i = 0; i < nr_irqs; i++) + rc = HYPERVISOR_physdev_op(PHYSDEVOP_get_nr_pirqs, &op_nr_pirqs); + if (rc < 0) { + nr_pirqs = nr_irqs; + if (rc != -ENOSYS) + printk(KERN_WARNING "PHYSDEVOP_get_nr_pirqs returned rc=%d\n", rc); + } else { + if (xen_pv_domain() && !xen_initial_domain()) + nr_pirqs = max((int)op_nr_pirqs.nr_pirqs, nr_irqs); + else + nr_pirqs = op_nr_pirqs.nr_pirqs; + } + pirq_to_irq = kcalloc(nr_pirqs, sizeof(*pirq_to_irq), GFP_KERNEL); + for (i = 0; i < nr_pirqs; i++) pirq_to_irq[i] = -1; evtchn_to_irq = kcalloc(NR_EVENT_CHANNELS, sizeof(*evtchn_to_irq), diff --git a/trunk/drivers/xen/manage.c b/trunk/drivers/xen/manage.c index db8c4c4ac880..ef9c7db52077 100644 --- a/trunk/drivers/xen/manage.c +++ b/trunk/drivers/xen/manage.c @@ -49,7 +49,6 @@ static int xen_hvm_suspend(void *data) if (!*cancelled) { xen_irq_resume(); - xen_console_resume(); xen_timer_resume(); } diff --git a/trunk/fs/autofs4/root.c b/trunk/fs/autofs4/root.c index d34896cfb19f..d5c1401f0031 100644 --- a/trunk/fs/autofs4/root.c +++ b/trunk/fs/autofs4/root.c @@ -980,11 +980,19 @@ static int autofs4_root_ioctl_unlocked(struct inode *inode, struct file *filp, } } +static DEFINE_MUTEX(autofs4_ioctl_mutex); + static long autofs4_root_ioctl(struct file *filp, unsigned int cmd, unsigned long arg) { + long ret; struct inode *inode = filp->f_dentry->d_inode; - return autofs4_root_ioctl_unlocked(inode, filp, cmd, arg); + + mutex_lock(&autofs4_ioctl_mutex); + ret = autofs4_root_ioctl_unlocked(inode, filp, cmd, arg); + mutex_unlock(&autofs4_ioctl_mutex); + + return ret; } #ifdef CONFIG_COMPAT @@ -994,11 +1002,13 @@ static long autofs4_root_compat_ioctl(struct file *filp, struct inode *inode = filp->f_path.dentry->d_inode; int ret; + mutex_lock(&autofs4_ioctl_mutex); if (cmd == AUTOFS_IOC_READY || cmd == AUTOFS_IOC_FAIL) ret = autofs4_root_ioctl_unlocked(inode, filp, cmd, arg); else ret = autofs4_root_ioctl_unlocked(inode, filp, cmd, (unsigned long)compat_ptr(arg)); + mutex_unlock(&autofs4_ioctl_mutex); return ret; } diff --git a/trunk/fs/ocfs2/cluster/heartbeat.c b/trunk/fs/ocfs2/cluster/heartbeat.c index 9f26ac9be2a4..52c7557f3e25 100644 --- a/trunk/fs/ocfs2/cluster/heartbeat.c +++ b/trunk/fs/ocfs2/cluster/heartbeat.c @@ -1964,10 +1964,8 @@ static struct config_item *o2hb_heartbeat_group_make_item(struct config_group *g if (reg == NULL) return ERR_PTR(-ENOMEM); - if (strlen(name) > O2HB_MAX_REGION_NAME_LEN) { - ret = -ENAMETOOLONG; - goto free; - } + if (strlen(name) > O2HB_MAX_REGION_NAME_LEN) + return ERR_PTR(-ENAMETOOLONG); spin_lock(&o2hb_live_lock); reg->hr_region_num = 0; @@ -1976,8 +1974,7 @@ static struct config_item *o2hb_heartbeat_group_make_item(struct config_group *g O2NM_MAX_REGIONS); if (reg->hr_region_num >= O2NM_MAX_REGIONS) { spin_unlock(&o2hb_live_lock); - ret = -EFBIG; - goto free; + return ERR_PTR(-EFBIG); } set_bit(reg->hr_region_num, o2hb_region_bitmap); } @@ -1989,13 +1986,10 @@ static struct config_item *o2hb_heartbeat_group_make_item(struct config_group *g ret = o2hb_debug_region_init(reg, o2hb_debug_dir); if (ret) { config_item_put(®->hr_item); - goto free; + return ERR_PTR(ret); } return ®->hr_item; -free: - kfree(reg); - return ERR_PTR(ret); } static void o2hb_heartbeat_group_drop_item(struct config_group *group, diff --git a/trunk/fs/ocfs2/dcache.c b/trunk/fs/ocfs2/dcache.c index 895532ac4d98..edaded48e7e9 100644 --- a/trunk/fs/ocfs2/dcache.c +++ b/trunk/fs/ocfs2/dcache.c @@ -476,6 +476,7 @@ static void ocfs2_dentry_iput(struct dentry *dentry, struct inode *inode) out: iput(inode); + ocfs2_dentry_attach_gen(dentry); } /* diff --git a/trunk/fs/ocfs2/dlm/dlmdomain.c b/trunk/fs/ocfs2/dlm/dlmdomain.c index cc2aaa96cfe5..58a93b953735 100644 --- a/trunk/fs/ocfs2/dlm/dlmdomain.c +++ b/trunk/fs/ocfs2/dlm/dlmdomain.c @@ -959,7 +959,7 @@ static int dlm_match_regions(struct dlm_ctxt *dlm, r += O2HB_MAX_REGION_NAME_LEN; } - local = kmalloc(sizeof(qr->qr_regions), GFP_ATOMIC); + local = kmalloc(sizeof(qr->qr_regions), GFP_KERNEL); if (!local) { status = -ENOMEM; goto bail; diff --git a/trunk/fs/ocfs2/ocfs2.h b/trunk/fs/ocfs2/ocfs2.h index 70dd3b1798f1..1efea3615589 100644 --- a/trunk/fs/ocfs2/ocfs2.h +++ b/trunk/fs/ocfs2/ocfs2.h @@ -159,9 +159,9 @@ struct ocfs2_lock_res { char l_name[OCFS2_LOCK_ID_MAX_LEN]; unsigned int l_ro_holders; unsigned int l_ex_holders; - signed char l_level; - signed char l_requested; - signed char l_blocking; + char l_level; + char l_requested; + char l_blocking; /* Data packed - type enum ocfs2_lock_type */ unsigned char l_type; diff --git a/trunk/fs/ocfs2/stack_user.c b/trunk/fs/ocfs2/stack_user.c index a5ebe421195f..252e7c82f929 100644 --- a/trunk/fs/ocfs2/stack_user.c +++ b/trunk/fs/ocfs2/stack_user.c @@ -190,7 +190,7 @@ static struct ocfs2_live_connection *ocfs2_connection_find(const char *name) return c; } - return NULL; + return c; } /* diff --git a/trunk/fs/proc/base.c b/trunk/fs/proc/base.c index 182845147fe4..f3d02ca461ec 100644 --- a/trunk/fs/proc/base.c +++ b/trunk/fs/proc/base.c @@ -1574,7 +1574,7 @@ static int do_proc_readlink(struct path *path, char __user *buffer, int buflen) if (!tmp) return -ENOMEM; - pathname = d_path(path, tmp, PAGE_SIZE); + pathname = d_path_with_unreachable(path, tmp, PAGE_SIZE); len = PTR_ERR(pathname); if (IS_ERR(pathname)) goto out; diff --git a/trunk/fs/reiserfs/xattr_acl.c b/trunk/fs/reiserfs/xattr_acl.c index 90d2fcb67a31..536d697a8a28 100644 --- a/trunk/fs/reiserfs/xattr_acl.c +++ b/trunk/fs/reiserfs/xattr_acl.c @@ -472,9 +472,7 @@ int reiserfs_acl_chmod(struct inode *inode) struct reiserfs_transaction_handle th; size_t size = reiserfs_xattr_nblocks(inode, reiserfs_acl_size(clone->a_count)); - int depth; - - depth = reiserfs_write_lock_once(inode->i_sb); + reiserfs_write_lock(inode->i_sb); error = journal_begin(&th, inode->i_sb, size * 2); if (!error) { int error2; @@ -484,7 +482,7 @@ int reiserfs_acl_chmod(struct inode *inode) if (error2) error = error2; } - reiserfs_write_unlock_once(inode->i_sb, depth); + reiserfs_write_unlock(inode->i_sb); } posix_acl_release(clone); return error; diff --git a/trunk/include/linux/gfp.h b/trunk/include/linux/gfp.h index f54adfcbec9c..e8713d55360a 100644 --- a/trunk/include/linux/gfp.h +++ b/trunk/include/linux/gfp.h @@ -360,7 +360,7 @@ void drain_local_pages(void *dummy); extern gfp_t gfp_allowed_mask; -extern void pm_restrict_gfp_mask(void); -extern void pm_restore_gfp_mask(void); +extern void set_gfp_allowed_mask(gfp_t mask); +extern gfp_t clear_gfp_allowed_mask(gfp_t mask); #endif /* __LINUX_GFP_H */ diff --git a/trunk/include/linux/gpio_keys.h b/trunk/include/linux/gpio_keys.h index dd1a56fbe924..ce73a30113b4 100644 --- a/trunk/include/linux/gpio_keys.h +++ b/trunk/include/linux/gpio_keys.h @@ -16,8 +16,6 @@ struct gpio_keys_button { struct gpio_keys_platform_data { struct gpio_keys_button *buttons; int nbuttons; - unsigned int poll_interval; /* polling interval in msecs - - for polling driver only */ unsigned int rep:1; /* enable input subsystem auto repeat */ int (*enable)(struct device *dev); void (*disable)(struct device *dev); diff --git a/trunk/include/linux/input.h b/trunk/include/linux/input.h index a8af21d42bc1..6ef44465db8d 100644 --- a/trunk/include/linux/input.h +++ b/trunk/include/linux/input.h @@ -47,25 +47,6 @@ struct input_id { __u16 version; }; -/** - * struct input_absinfo - used by EVIOCGABS/EVIOCSABS ioctls - * @value: latest reported value for the axis. - * @minimum: specifies minimum value for the axis. - * @maximum: specifies maximum value for the axis. - * @fuzz: specifies fuzz value that is used to filter noise from - * the event stream. - * @flat: values that are within this value will be discarded by - * joydev interface and reported as 0 instead. - * @resolution: specifies resolution for the values reported for - * the axis. - * - * Note that input core does not clamp reported values to the - * [minimum, maximum] limits, such task is left to userspace. - * - * Resolution for main axes (ABS_X, ABS_Y, ABS_Z) is reported in - * units per millimeter (units/mm), resolution for rotational axes - * (ABS_RX, ABS_RY, ABS_RZ) is reported in units per radian. - */ struct input_absinfo { __s32 value; __s32 minimum; @@ -643,10 +624,6 @@ struct input_keymap_entry { #define KEY_CAMERA_FOCUS 0x210 #define KEY_WPS_BUTTON 0x211 /* WiFi Protected Setup key */ -#define KEY_TOUCHPAD_TOGGLE 0x212 /* Request switch touchpad on or off */ -#define KEY_TOUCHPAD_ON 0x213 -#define KEY_TOUCHPAD_OFF 0x214 - #define BTN_TRIGGER_HAPPY 0x2c0 #define BTN_TRIGGER_HAPPY1 0x2c0 #define BTN_TRIGGER_HAPPY2 0x2c1 @@ -1153,7 +1130,7 @@ struct input_mt_slot { * of tracked contacts * @mtsize: number of MT slots the device uses * @slot: MT slot currently being transmitted - * @absinfo: array of &struct input_absinfo elements holding information + * @absinfo: array of &struct absinfo elements holding information * about absolute axes (current value, min, max, flat, fuzz, * resolution) * @key: reflects current state of device's keys/buttons diff --git a/trunk/include/linux/memory_hotplug.h b/trunk/include/linux/memory_hotplug.h index 31c237a00c48..4307231bd22f 100644 --- a/trunk/include/linux/memory_hotplug.h +++ b/trunk/include/linux/memory_hotplug.h @@ -161,9 +161,6 @@ extern void register_page_bootmem_info_node(struct pglist_data *pgdat); extern void put_page_bootmem(struct page *page); #endif -void lock_memory_hotplug(void); -void unlock_memory_hotplug(void); - #else /* ! CONFIG_MEMORY_HOTPLUG */ /* * Stub functions for when hotplug is off @@ -195,9 +192,6 @@ static inline void register_page_bootmem_info_node(struct pglist_data *pgdat) { } -static inline void lock_memory_hotplug(void) {} -static inline void unlock_memory_hotplug(void) {} - #endif /* ! CONFIG_MEMORY_HOTPLUG */ #ifdef CONFIG_MEMORY_HOTREMOVE diff --git a/trunk/include/linux/vmalloc.h b/trunk/include/linux/vmalloc.h index 44b54f619ac6..a03dcf62ca9d 100644 --- a/trunk/include/linux/vmalloc.h +++ b/trunk/include/linux/vmalloc.h @@ -7,6 +7,8 @@ struct vm_area_struct; /* vma defining user mapping in mm_types.h */ +extern bool vmap_lazy_unmap; + /* bits in flags of vmalloc's vm_struct below */ #define VM_IOREMAP 0x00000001 /* ioremap() and friends */ #define VM_ALLOC 0x00000002 /* vmalloc() */ diff --git a/trunk/include/xen/events.h b/trunk/include/xen/events.h index 00f53ddcc062..646dd17d3aa4 100644 --- a/trunk/include/xen/events.h +++ b/trunk/include/xen/events.h @@ -76,9 +76,7 @@ int xen_map_pirq_gsi(unsigned pirq, unsigned gsi, int shareable, char *name); #ifdef CONFIG_PCI_MSI /* Allocate an irq and a pirq to be used with MSIs. */ -#define XEN_ALLOC_PIRQ (1 << 0) -#define XEN_ALLOC_IRQ (1 << 1) -void xen_allocate_pirq_msi(char *name, int *irq, int *pirq, int alloc_mask); +void xen_allocate_pirq_msi(char *name, int *irq, int *pirq); int xen_create_msi_irq(struct pci_dev *dev, struct msi_desc *msidesc, int type); #endif @@ -91,7 +89,4 @@ int xen_vector_from_irq(unsigned pirq); /* Return gsi allocated to pirq */ int xen_gsi_from_irq(unsigned pirq); -/* Return irq from pirq */ -int xen_irq_from_pirq(unsigned pirq); - #endif /* _XEN_EVENTS_H */ diff --git a/trunk/include/xen/interface/physdev.h b/trunk/include/xen/interface/physdev.h index 534cac89a77d..2b2c66c3df00 100644 --- a/trunk/include/xen/interface/physdev.h +++ b/trunk/include/xen/interface/physdev.h @@ -188,16 +188,6 @@ struct physdev_nr_pirqs { uint32_t nr_pirqs; }; -/* type is MAP_PIRQ_TYPE_GSI or MAP_PIRQ_TYPE_MSI - * the hypercall returns a free pirq */ -#define PHYSDEVOP_get_free_pirq 23 -struct physdev_get_free_pirq { - /* IN */ - int type; - /* OUT */ - uint32_t pirq; -}; - /* * Notify that some PIRQ-bound event channels have been unmasked. * ** This command is obsolete since interface version 0x00030202 and is ** diff --git a/trunk/kernel/exit.c b/trunk/kernel/exit.c index 676149a4ac5f..21aa7b3001fb 100644 --- a/trunk/kernel/exit.c +++ b/trunk/kernel/exit.c @@ -914,15 +914,6 @@ NORET_TYPE void do_exit(long code) if (unlikely(!tsk->pid)) panic("Attempted to kill the idle task!"); - /* - * If do_exit is called because this processes oopsed, it's possible - * that get_fs() was left as KERNEL_DS, so reset it to USER_DS before - * continuing. Amongst other possible reasons, this is to prevent - * mm_release()->clear_child_tid() from writing to a user-controlled - * kernel address. - */ - set_fs(USER_DS); - tracehook_report_exit(&code); validate_creds_for_do_exit(tsk); diff --git a/trunk/kernel/irq/proc.c b/trunk/kernel/irq/proc.c index 6c8a2a9f8a7b..01b1d3a88983 100644 --- a/trunk/kernel/irq/proc.c +++ b/trunk/kernel/irq/proc.c @@ -214,7 +214,7 @@ static int irq_spurious_proc_show(struct seq_file *m, void *v) static int irq_spurious_proc_open(struct inode *inode, struct file *file) { - return single_open(file, irq_spurious_proc_show, PDE(inode)->data); + return single_open(file, irq_spurious_proc_show, NULL); } static const struct file_operations irq_spurious_proc_fops = { diff --git a/trunk/kernel/power/hibernate.c b/trunk/kernel/power/hibernate.c index 048d0b514831..657272e91d0a 100644 --- a/trunk/kernel/power/hibernate.c +++ b/trunk/kernel/power/hibernate.c @@ -327,6 +327,7 @@ static int create_image(int platform_mode) int hibernation_snapshot(int platform_mode) { int error; + gfp_t saved_mask; error = platform_begin(platform_mode); if (error) @@ -338,7 +339,7 @@ int hibernation_snapshot(int platform_mode) goto Close; suspend_console(); - pm_restrict_gfp_mask(); + saved_mask = clear_gfp_allowed_mask(GFP_IOFS); error = dpm_suspend_start(PMSG_FREEZE); if (error) goto Recover_platform; @@ -347,10 +348,7 @@ int hibernation_snapshot(int platform_mode) goto Recover_platform; error = create_image(platform_mode); - /* - * Control returns here (1) after the image has been created or the - * image creation has failed and (2) after a successful restore. - */ + /* Control returns here after successful restore */ Resume_devices: /* We may need to release the preallocated image pages here. */ @@ -359,10 +357,7 @@ int hibernation_snapshot(int platform_mode) dpm_resume_end(in_suspend ? (error ? PMSG_RECOVER : PMSG_THAW) : PMSG_RESTORE); - - if (error || !in_suspend) - pm_restore_gfp_mask(); - + set_gfp_allowed_mask(saved_mask); resume_console(); Close: platform_end(platform_mode); @@ -457,16 +452,17 @@ static int resume_target_kernel(bool platform_mode) int hibernation_restore(int platform_mode) { int error; + gfp_t saved_mask; pm_prepare_console(); suspend_console(); - pm_restrict_gfp_mask(); + saved_mask = clear_gfp_allowed_mask(GFP_IOFS); error = dpm_suspend_start(PMSG_QUIESCE); if (!error) { error = resume_target_kernel(platform_mode); dpm_resume_end(PMSG_RECOVER); } - pm_restore_gfp_mask(); + set_gfp_allowed_mask(saved_mask); resume_console(); pm_restore_console(); return error; @@ -480,6 +476,7 @@ int hibernation_restore(int platform_mode) int hibernation_platform_enter(void) { int error; + gfp_t saved_mask; if (!hibernation_ops) return -ENOSYS; @@ -495,6 +492,7 @@ int hibernation_platform_enter(void) entering_platform_hibernation = true; suspend_console(); + saved_mask = clear_gfp_allowed_mask(GFP_IOFS); error = dpm_suspend_start(PMSG_HIBERNATE); if (error) { if (hibernation_ops->recover) @@ -538,6 +536,7 @@ int hibernation_platform_enter(void) Resume_devices: entering_platform_hibernation = false; dpm_resume_end(PMSG_RESTORE); + set_gfp_allowed_mask(saved_mask); resume_console(); Close: @@ -647,7 +646,6 @@ int hibernate(void) swsusp_free(); if (!error) power_down(); - pm_restore_gfp_mask(); } else { pr_debug("PM: Image restored successfully.\n"); } diff --git a/trunk/kernel/power/suspend.c b/trunk/kernel/power/suspend.c index ecf770509d0d..7335952ee473 100644 --- a/trunk/kernel/power/suspend.c +++ b/trunk/kernel/power/suspend.c @@ -197,6 +197,7 @@ static int suspend_enter(suspend_state_t state) int suspend_devices_and_enter(suspend_state_t state) { int error; + gfp_t saved_mask; if (!suspend_ops) return -ENOSYS; @@ -207,7 +208,7 @@ int suspend_devices_and_enter(suspend_state_t state) goto Close; } suspend_console(); - pm_restrict_gfp_mask(); + saved_mask = clear_gfp_allowed_mask(GFP_IOFS); suspend_test_start(); error = dpm_suspend_start(PMSG_SUSPEND); if (error) { @@ -224,7 +225,7 @@ int suspend_devices_and_enter(suspend_state_t state) suspend_test_start(); dpm_resume_end(PMSG_RESUME); suspend_test_finish("resume devices"); - pm_restore_gfp_mask(); + set_gfp_allowed_mask(saved_mask); resume_console(); Close: if (suspend_ops->end) diff --git a/trunk/kernel/power/swap.c b/trunk/kernel/power/swap.c index baf667bb2794..a0e4a86ccf94 100644 --- a/trunk/kernel/power/swap.c +++ b/trunk/kernel/power/swap.c @@ -6,7 +6,6 @@ * * Copyright (C) 1998,2001-2005 Pavel Machek * Copyright (C) 2006 Rafael J. Wysocki - * Copyright (C) 2010 Bojan Smojver * * This file is released under the GPLv2. * @@ -754,43 +753,30 @@ static int load_image_lzo(struct swap_map_handle *handle, { unsigned int m; int error = 0; - struct bio *bio; struct timeval start; struct timeval stop; unsigned nr_pages; - size_t i, off, unc_len, cmp_len; - unsigned char *unc, *cmp, *page[LZO_CMP_PAGES]; - - for (i = 0; i < LZO_CMP_PAGES; i++) { - page[i] = (void *)__get_free_page(__GFP_WAIT | __GFP_HIGH); - if (!page[i]) { - printk(KERN_ERR "PM: Failed to allocate LZO page\n"); - - while (i) - free_page((unsigned long)page[--i]); + size_t off, unc_len, cmp_len; + unsigned char *unc, *cmp, *page; - return -ENOMEM; - } + page = (void *)__get_free_page(__GFP_WAIT | __GFP_HIGH); + if (!page) { + printk(KERN_ERR "PM: Failed to allocate LZO page\n"); + return -ENOMEM; } unc = vmalloc(LZO_UNC_SIZE); if (!unc) { printk(KERN_ERR "PM: Failed to allocate LZO uncompressed\n"); - - for (i = 0; i < LZO_CMP_PAGES; i++) - free_page((unsigned long)page[i]); - + free_page((unsigned long)page); return -ENOMEM; } cmp = vmalloc(LZO_CMP_SIZE); if (!cmp) { printk(KERN_ERR "PM: Failed to allocate LZO compressed\n"); - vfree(unc); - for (i = 0; i < LZO_CMP_PAGES; i++) - free_page((unsigned long)page[i]); - + free_page((unsigned long)page); return -ENOMEM; } @@ -801,7 +787,6 @@ static int load_image_lzo(struct swap_map_handle *handle, if (!m) m = 1; nr_pages = 0; - bio = NULL; do_gettimeofday(&start); error = snapshot_write_next(snapshot); @@ -809,11 +794,11 @@ static int load_image_lzo(struct swap_map_handle *handle, goto out_finish; for (;;) { - error = swap_read_page(handle, page[0], NULL); /* sync */ + error = swap_read_page(handle, page, NULL); /* sync */ if (error) break; - cmp_len = *(size_t *)page[0]; + cmp_len = *(size_t *)page; if (unlikely(!cmp_len || cmp_len > lzo1x_worst_compress(LZO_UNC_SIZE))) { printk(KERN_ERR "PM: Invalid LZO compressed length\n"); @@ -821,20 +806,13 @@ static int load_image_lzo(struct swap_map_handle *handle, break; } - for (off = PAGE_SIZE, i = 1; - off < LZO_HEADER + cmp_len; off += PAGE_SIZE, i++) { - error = swap_read_page(handle, page[i], &bio); + memcpy(cmp, page, PAGE_SIZE); + for (off = PAGE_SIZE; off < LZO_HEADER + cmp_len; off += PAGE_SIZE) { + error = swap_read_page(handle, page, NULL); /* sync */ if (error) goto out_finish; - } - error = hib_wait_on_bio_chain(&bio); /* need all data now */ - if (error) - goto out_finish; - - for (off = 0, i = 0; - off < LZO_HEADER + cmp_len; off += PAGE_SIZE, i++) { - memcpy(cmp + off, page[i], PAGE_SIZE); + memcpy(cmp + off, page, PAGE_SIZE); } unc_len = LZO_UNC_SIZE; @@ -879,8 +857,7 @@ static int load_image_lzo(struct swap_map_handle *handle, vfree(cmp); vfree(unc); - for (i = 0; i < LZO_CMP_PAGES; i++) - free_page((unsigned long)page[i]); + free_page((unsigned long)page); return error; } diff --git a/trunk/kernel/power/user.c b/trunk/kernel/power/user.c index 1b2ea31e6bd8..e819e17877ca 100644 --- a/trunk/kernel/power/user.c +++ b/trunk/kernel/power/user.c @@ -263,7 +263,6 @@ static long snapshot_ioctl(struct file *filp, unsigned int cmd, case SNAPSHOT_UNFREEZE: if (!data->frozen || data->ready) break; - pm_restore_gfp_mask(); thaw_processes(); usermodehelper_enable(); data->frozen = 0; @@ -276,7 +275,6 @@ static long snapshot_ioctl(struct file *filp, unsigned int cmd, error = -EPERM; break; } - pm_restore_gfp_mask(); error = hibernation_snapshot(data->platform_support); if (!error) error = put_user(in_suspend, (int __user *)arg); diff --git a/trunk/mm/hugetlb.c b/trunk/mm/hugetlb.c index 85855240933d..c4a3558589ab 100644 --- a/trunk/mm/hugetlb.c +++ b/trunk/mm/hugetlb.c @@ -2738,8 +2738,7 @@ int hugetlb_fault(struct mm_struct *mm, struct vm_area_struct *vma, unlock_page(pagecache_page); put_page(pagecache_page); } - if (page != pagecache_page) - unlock_page(page); + unlock_page(page); out_mutex: mutex_unlock(&hugetlb_instantiation_mutex); diff --git a/trunk/mm/ksm.c b/trunk/mm/ksm.c index 43bc893470b4..65ab5c7067d9 100644 --- a/trunk/mm/ksm.c +++ b/trunk/mm/ksm.c @@ -1724,13 +1724,8 @@ static int ksm_memory_callback(struct notifier_block *self, /* * Keep it very simple for now: just lock out ksmd and * MADV_UNMERGEABLE while any memory is going offline. - * mutex_lock_nested() is necessary because lockdep was alarmed - * that here we take ksm_thread_mutex inside notifier chain - * mutex, and later take notifier chain mutex inside - * ksm_thread_mutex to unlock it. But that's safe because both - * are inside mem_hotplug_mutex. */ - mutex_lock_nested(&ksm_thread_mutex, SINGLE_DEPTH_NESTING); + mutex_lock(&ksm_thread_mutex); break; case MEM_OFFLINE: diff --git a/trunk/mm/memory-failure.c b/trunk/mm/memory-failure.c index 46ab2c044b0e..124324134ff6 100644 --- a/trunk/mm/memory-failure.c +++ b/trunk/mm/memory-failure.c @@ -51,7 +51,6 @@ #include #include #include -#include #include "internal.h" int sysctl_memory_failure_early_kill __read_mostly = 0; @@ -1231,10 +1230,11 @@ static int get_any_page(struct page *p, unsigned long pfn, int flags) return 1; /* - * The lock_memory_hotplug prevents a race with memory hotplug. + * The lock_system_sleep prevents a race with memory hotplug, + * because the isolation assumes there's only a single user. * This is a big hammer, a better would be nicer. */ - lock_memory_hotplug(); + lock_system_sleep(); /* * Isolate the page, so that it doesn't get reallocated if it @@ -1264,7 +1264,7 @@ static int get_any_page(struct page *p, unsigned long pfn, int flags) ret = 1; } unset_migratetype_isolate(p); - unlock_memory_hotplug(); + unlock_system_sleep(); return ret; } diff --git a/trunk/mm/memory_hotplug.c b/trunk/mm/memory_hotplug.c index 2c6523af5473..9260314a221e 100644 --- a/trunk/mm/memory_hotplug.c +++ b/trunk/mm/memory_hotplug.c @@ -34,23 +34,6 @@ #include "internal.h" -DEFINE_MUTEX(mem_hotplug_mutex); - -void lock_memory_hotplug(void) -{ - mutex_lock(&mem_hotplug_mutex); - - /* for exclusive hibernation if CONFIG_HIBERNATION=y */ - lock_system_sleep(); -} - -void unlock_memory_hotplug(void) -{ - unlock_system_sleep(); - mutex_unlock(&mem_hotplug_mutex); -} - - /* add this memory to iomem resource */ static struct resource *register_memory_resource(u64 start, u64 size) { @@ -510,7 +493,7 @@ int mem_online_node(int nid) pg_data_t *pgdat; int ret; - lock_memory_hotplug(); + lock_system_sleep(); pgdat = hotadd_new_pgdat(nid, 0); if (pgdat) { ret = -ENOMEM; @@ -521,7 +504,7 @@ int mem_online_node(int nid) BUG_ON(ret); out: - unlock_memory_hotplug(); + unlock_system_sleep(); return ret; } @@ -533,7 +516,7 @@ int __ref add_memory(int nid, u64 start, u64 size) struct resource *res; int ret; - lock_memory_hotplug(); + lock_system_sleep(); res = register_memory_resource(start, size); ret = -EEXIST; @@ -580,7 +563,7 @@ int __ref add_memory(int nid, u64 start, u64 size) release_memory_resource(res); out: - unlock_memory_hotplug(); + unlock_system_sleep(); return ret; } EXPORT_SYMBOL_GPL(add_memory); @@ -808,7 +791,7 @@ static int offline_pages(unsigned long start_pfn, if (!test_pages_in_a_zone(start_pfn, end_pfn)) return -EINVAL; - lock_memory_hotplug(); + lock_system_sleep(); zone = page_zone(pfn_to_page(start_pfn)); node = zone_to_nid(zone); @@ -897,7 +880,7 @@ static int offline_pages(unsigned long start_pfn, writeback_set_ratelimit(); memory_notify(MEM_OFFLINE, &arg); - unlock_memory_hotplug(); + unlock_system_sleep(); return 0; failed_removal: @@ -908,7 +891,7 @@ static int offline_pages(unsigned long start_pfn, undo_isolate_page_range(start_pfn, end_pfn); out: - unlock_memory_hotplug(); + unlock_system_sleep(); return ret; } diff --git a/trunk/mm/mempolicy.c b/trunk/mm/mempolicy.c index 11ff260fb282..4a57f135b76e 100644 --- a/trunk/mm/mempolicy.c +++ b/trunk/mm/mempolicy.c @@ -1307,18 +1307,15 @@ SYSCALL_DEFINE4(migrate_pages, pid_t, pid, unsigned long, maxnode, goto out; /* Find the mm_struct */ - rcu_read_lock(); read_lock(&tasklist_lock); task = pid ? find_task_by_vpid(pid) : current; if (!task) { read_unlock(&tasklist_lock); - rcu_read_unlock(); err = -ESRCH; goto out; } mm = get_task_mm(task); read_unlock(&tasklist_lock); - rcu_read_unlock(); err = -EINVAL; if (!mm) diff --git a/trunk/mm/page_alloc.c b/trunk/mm/page_alloc.c index ff7e15872398..e4092704c1a9 100644 --- a/trunk/mm/page_alloc.c +++ b/trunk/mm/page_alloc.c @@ -104,24 +104,19 @@ gfp_t gfp_allowed_mask __read_mostly = GFP_BOOT_MASK; * only be modified with pm_mutex held, unless the suspend/hibernate code is * guaranteed not to run in parallel with that modification). */ - -static gfp_t saved_gfp_mask; - -void pm_restore_gfp_mask(void) +void set_gfp_allowed_mask(gfp_t mask) { WARN_ON(!mutex_is_locked(&pm_mutex)); - if (saved_gfp_mask) { - gfp_allowed_mask = saved_gfp_mask; - saved_gfp_mask = 0; - } + gfp_allowed_mask = mask; } -void pm_restrict_gfp_mask(void) +gfp_t clear_gfp_allowed_mask(gfp_t mask) { + gfp_t ret = gfp_allowed_mask; + WARN_ON(!mutex_is_locked(&pm_mutex)); - WARN_ON(saved_gfp_mask); - saved_gfp_mask = gfp_allowed_mask; - gfp_allowed_mask &= ~GFP_IOFS; + gfp_allowed_mask &= ~mask; + return ret; } #endif /* CONFIG_PM_SLEEP */ diff --git a/trunk/mm/slub.c b/trunk/mm/slub.c index bec0e355fbad..981fb730aa04 100644 --- a/trunk/mm/slub.c +++ b/trunk/mm/slub.c @@ -3401,13 +3401,13 @@ static int validate_slab(struct kmem_cache *s, struct page *page, for_each_free_object(p, s, page->freelist) { set_bit(slab_index(p, s, addr), map); - if (!check_object(s, page, p, SLUB_RED_INACTIVE)) + if (!check_object(s, page, p, 0)) return 0; } for_each_object(p, s, addr, page->objects) if (!test_bit(slab_index(p, s, addr), map)) - if (!check_object(s, page, p, SLUB_RED_ACTIVE)) + if (!check_object(s, page, p, 1)) return 0; return 1; } diff --git a/trunk/mm/vmalloc.c b/trunk/mm/vmalloc.c index eb5cc7d00c5a..a3d66b3dc5cb 100644 --- a/trunk/mm/vmalloc.c +++ b/trunk/mm/vmalloc.c @@ -31,6 +31,8 @@ #include #include +bool vmap_lazy_unmap __read_mostly = true; + /*** Page table manipulation functions ***/ static void vunmap_pte_range(pmd_t *pmd, unsigned long addr, unsigned long end) @@ -501,6 +503,9 @@ static unsigned long lazy_max_pages(void) { unsigned int log; + if (!vmap_lazy_unmap) + return 0; + log = fls(num_online_cpus()); return log * (32UL * 1024 * 1024 / PAGE_SIZE); @@ -561,6 +566,7 @@ static void __purge_vmap_area_lazy(unsigned long *start, unsigned long *end, if (va->va_end > *end) *end = va->va_end; nr += (va->va_end - va->va_start) >> PAGE_SHIFT; + unmap_vmap_area(va); list_add_tail(&va->purge_list, &valist); va->flags |= VM_LAZY_FREEING; va->flags &= ~VM_LAZY_FREE; @@ -605,11 +611,10 @@ static void purge_vmap_area_lazy(void) } /* - * Free a vmap area, caller ensuring that the area has been unmapped - * and flush_cache_vunmap had been called for the correct range - * previously. + * Free and unmap a vmap area, caller ensuring flush_cache_vunmap had been + * called for the correct range previously. */ -static void free_vmap_area_noflush(struct vmap_area *va) +static void free_unmap_vmap_area_noflush(struct vmap_area *va) { va->flags |= VM_LAZY_FREE; atomic_add((va->va_end - va->va_start) >> PAGE_SHIFT, &vmap_lazy_nr); @@ -617,16 +622,6 @@ static void free_vmap_area_noflush(struct vmap_area *va) try_purge_vmap_area_lazy(); } -/* - * Free and unmap a vmap area, caller ensuring flush_cache_vunmap had been - * called for the correct range previously. - */ -static void free_unmap_vmap_area_noflush(struct vmap_area *va) -{ - unmap_vmap_area(va); - free_vmap_area_noflush(va); -} - /* * Free and unmap a vmap area */ @@ -803,7 +798,7 @@ static void free_vmap_block(struct vmap_block *vb) spin_unlock(&vmap_block_tree_lock); BUG_ON(tmp != vb); - free_vmap_area_noflush(vb->va); + free_unmap_vmap_area_noflush(vb->va); call_rcu(&vb->rcu_head, rcu_free_vb); } @@ -941,8 +936,6 @@ static void vb_free(const void *addr, unsigned long size) rcu_read_unlock(); BUG_ON(!vb); - vunmap_page_range((unsigned long)addr, (unsigned long)addr + size); - spin_lock(&vb->lock); BUG_ON(bitmap_allocate_region(vb->dirty_map, offset >> PAGE_SHIFT, order)); @@ -995,6 +988,7 @@ void vm_unmap_aliases(void) s = vb->va->va_start + (i << PAGE_SHIFT); e = vb->va->va_start + (j << PAGE_SHIFT); + vunmap_page_range(s, e); flush = 1; if (s < start) diff --git a/trunk/mm/vmstat.c b/trunk/mm/vmstat.c index 8f62f17ee1c7..42eac4d33216 100644 --- a/trunk/mm/vmstat.c +++ b/trunk/mm/vmstat.c @@ -750,6 +750,8 @@ static const char * const vmstat_text[] = { "nr_shmem", "nr_dirtied", "nr_written", + "nr_dirty_threshold", + "nr_dirty_background_threshold", #ifdef CONFIG_NUMA "numa_hit", @@ -759,8 +761,6 @@ static const char * const vmstat_text[] = { "numa_local", "numa_other", #endif - "nr_dirty_threshold", - "nr_dirty_background_threshold", #ifdef CONFIG_VM_EVENT_COUNTERS "pgpgin", diff --git a/trunk/net/mac80211/Kconfig b/trunk/net/mac80211/Kconfig index 8e8ea9cb7093..4d6f8653ec88 100644 --- a/trunk/net/mac80211/Kconfig +++ b/trunk/net/mac80211/Kconfig @@ -92,7 +92,7 @@ config MAC80211_MESH config MAC80211_LEDS bool "Enable LED triggers" depends on MAC80211 - depends on LEDS_CLASS + select NEW_LEDS select LEDS_TRIGGERS ---help--- This option enables a few LED triggers for different diff --git a/trunk/scripts/kconfig/expr.h b/trunk/scripts/kconfig/expr.h index e57826ced380..184eb6a0b505 100644 --- a/trunk/scripts/kconfig/expr.h +++ b/trunk/scripts/kconfig/expr.h @@ -164,7 +164,6 @@ struct menu { struct menu *list; struct symbol *sym; struct property *prompt; - struct expr *visibility; struct expr *dep; unsigned int flags; char *help; diff --git a/trunk/scripts/kconfig/lkc.h b/trunk/scripts/kconfig/lkc.h index 3f7240df0f3b..753cdbd7b805 100644 --- a/trunk/scripts/kconfig/lkc.h +++ b/trunk/scripts/kconfig/lkc.h @@ -107,7 +107,6 @@ void menu_end_menu(void); void menu_add_entry(struct symbol *sym); void menu_end_entry(void); void menu_add_dep(struct expr *dep); -void menu_add_visibility(struct expr *dep); struct property *menu_add_prop(enum prop_type type, char *prompt, struct expr *expr, struct expr *dep); struct property *menu_add_prompt(enum prop_type type, char *prompt, struct expr *dep); void menu_add_expr(enum prop_type type, struct expr *expr, struct expr *dep); diff --git a/trunk/scripts/kconfig/menu.c b/trunk/scripts/kconfig/menu.c index b9d9aa18e6d6..7e83aef42c6d 100644 --- a/trunk/scripts/kconfig/menu.c +++ b/trunk/scripts/kconfig/menu.c @@ -152,12 +152,6 @@ struct property *menu_add_prompt(enum prop_type type, char *prompt, struct expr return menu_add_prop(type, prompt, NULL, dep); } -void menu_add_visibility(struct expr *expr) -{ - current_entry->visibility = expr_alloc_and(current_entry->visibility, - expr); -} - void menu_add_expr(enum prop_type type, struct expr *expr, struct expr *dep) { menu_add_prop(type, NULL, expr, dep); @@ -416,11 +410,6 @@ bool menu_is_visible(struct menu *menu) if (!menu->prompt) return false; - if (menu->visibility) { - if (expr_calc_value(menu->visibility) == no) - return no; - } - sym = menu->sym; if (sym) { sym_calc_value(sym); diff --git a/trunk/scripts/kconfig/zconf.gperf b/trunk/scripts/kconfig/zconf.gperf index c9e690eb7545..d8bc74249622 100644 --- a/trunk/scripts/kconfig/zconf.gperf +++ b/trunk/scripts/kconfig/zconf.gperf @@ -38,7 +38,6 @@ hex, T_TYPE, TF_COMMAND, S_HEX string, T_TYPE, TF_COMMAND, S_STRING select, T_SELECT, TF_COMMAND range, T_RANGE, TF_COMMAND -visible, T_VISIBLE, TF_COMMAND option, T_OPTION, TF_COMMAND on, T_ON, TF_PARAM modules, T_OPT_MODULES, TF_OPTION diff --git a/trunk/scripts/kconfig/zconf.hash.c_shipped b/trunk/scripts/kconfig/zconf.hash.c_shipped index 4055d5de1750..c1748faf4634 100644 --- a/trunk/scripts/kconfig/zconf.hash.c_shipped +++ b/trunk/scripts/kconfig/zconf.hash.c_shipped @@ -32,7 +32,7 @@ struct kconf_id; static struct kconf_id *kconf_id_lookup(register const char *str, register unsigned int len); -/* maximum key range = 50, duplicates = 0 */ +/* maximum key range = 47, duplicates = 0 */ #ifdef __GNUC__ __inline @@ -46,32 +46,32 @@ kconf_id_hash (register const char *str, register unsigned int len) { static unsigned char asso_values[] = { - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 40, 5, - 0, 0, 5, 52, 0, 20, 52, 52, 10, 20, - 5, 0, 35, 52, 0, 30, 0, 15, 0, 52, - 15, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52, 52, 52, 52, 52, - 52, 52, 52, 52, 52, 52 + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 11, 5, + 0, 0, 5, 49, 5, 20, 49, 49, 5, 20, + 5, 0, 30, 49, 0, 15, 0, 10, 0, 49, + 25, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49, 49, 49, 49, 49, + 49, 49, 49, 49, 49, 49 }; register int hval = len; @@ -102,26 +102,25 @@ struct kconf_id_strings_t char kconf_id_strings_str12[sizeof("default")]; char kconf_id_strings_str13[sizeof("def_bool")]; char kconf_id_strings_str14[sizeof("help")]; + char kconf_id_strings_str15[sizeof("bool")]; char kconf_id_strings_str16[sizeof("config")]; char kconf_id_strings_str17[sizeof("def_tristate")]; - char kconf_id_strings_str18[sizeof("hex")]; + char kconf_id_strings_str18[sizeof("boolean")]; char kconf_id_strings_str19[sizeof("defconfig_list")]; + char kconf_id_strings_str21[sizeof("string")]; char kconf_id_strings_str22[sizeof("if")]; char kconf_id_strings_str23[sizeof("int")]; + char kconf_id_strings_str26[sizeof("select")]; char kconf_id_strings_str27[sizeof("modules")]; char kconf_id_strings_str28[sizeof("tristate")]; char kconf_id_strings_str29[sizeof("menu")]; + char kconf_id_strings_str31[sizeof("source")]; char kconf_id_strings_str32[sizeof("comment")]; + char kconf_id_strings_str33[sizeof("hex")]; char kconf_id_strings_str35[sizeof("menuconfig")]; - char kconf_id_strings_str36[sizeof("string")]; - char kconf_id_strings_str37[sizeof("visible")]; - char kconf_id_strings_str41[sizeof("prompt")]; - char kconf_id_strings_str42[sizeof("depends")]; - char kconf_id_strings_str44[sizeof("bool")]; - char kconf_id_strings_str46[sizeof("select")]; - char kconf_id_strings_str47[sizeof("boolean")]; + char kconf_id_strings_str36[sizeof("prompt")]; + char kconf_id_strings_str37[sizeof("depends")]; char kconf_id_strings_str48[sizeof("mainmenu")]; - char kconf_id_strings_str51[sizeof("source")]; }; static struct kconf_id_strings_t kconf_id_strings_contents = { @@ -137,26 +136,25 @@ static struct kconf_id_strings_t kconf_id_strings_contents = "default", "def_bool", "help", + "bool", "config", "def_tristate", - "hex", + "boolean", "defconfig_list", + "string", "if", "int", + "select", "modules", "tristate", "menu", + "source", "comment", + "hex", "menuconfig", - "string", - "visible", "prompt", "depends", - "bool", - "select", - "boolean", - "mainmenu", - "source" + "mainmenu" }; #define kconf_id_strings ((const char *) &kconf_id_strings_contents) #ifdef __GNUC__ @@ -170,11 +168,11 @@ kconf_id_lookup (register const char *str, register unsigned int len) { enum { - TOTAL_KEYWORDS = 32, + TOTAL_KEYWORDS = 31, MIN_WORD_LENGTH = 2, MAX_WORD_LENGTH = 14, MIN_HASH_VALUE = 2, - MAX_HASH_VALUE = 51 + MAX_HASH_VALUE = 48 }; static struct kconf_id wordlist[] = @@ -193,35 +191,31 @@ kconf_id_lookup (register const char *str, register unsigned int len) {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str12, T_DEFAULT, TF_COMMAND, S_UNKNOWN}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str13, T_DEFAULT, TF_COMMAND, S_BOOLEAN}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str14, T_HELP, TF_COMMAND}, - {-1}, + {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str15, T_TYPE, TF_COMMAND, S_BOOLEAN}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str16, T_CONFIG, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str17, T_DEFAULT, TF_COMMAND, S_TRISTATE}, - {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str18, T_TYPE, TF_COMMAND, S_HEX}, + {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str18, T_TYPE, TF_COMMAND, S_BOOLEAN}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str19, T_OPT_DEFCONFIG_LIST,TF_OPTION}, - {-1}, {-1}, + {-1}, + {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str21, T_TYPE, TF_COMMAND, S_STRING}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str22, T_IF, TF_COMMAND|TF_PARAM}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str23, T_TYPE, TF_COMMAND, S_INT}, - {-1}, {-1}, {-1}, + {-1}, {-1}, + {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str26, T_SELECT, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str27, T_OPT_MODULES, TF_OPTION}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str28, T_TYPE, TF_COMMAND, S_TRISTATE}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str29, T_MENU, TF_COMMAND}, - {-1}, {-1}, + {-1}, + {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str31, T_SOURCE, TF_COMMAND}, {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str32, T_COMMENT, TF_COMMAND}, - {-1}, {-1}, - {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str35, T_MENUCONFIG, TF_COMMAND}, - {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str36, T_TYPE, TF_COMMAND, S_STRING}, - {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str37, T_VISIBLE, TF_COMMAND}, - {-1}, {-1}, {-1}, - {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str41, T_PROMPT, TF_COMMAND}, - {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str42, T_DEPENDS, TF_COMMAND}, + {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str33, T_TYPE, TF_COMMAND, S_HEX}, {-1}, - {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str44, T_TYPE, TF_COMMAND, S_BOOLEAN}, + {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str35, T_MENUCONFIG, TF_COMMAND}, + {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str36, T_PROMPT, TF_COMMAND}, + {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str37, T_DEPENDS, TF_COMMAND}, + {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, {-1}, - {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str46, T_SELECT, TF_COMMAND}, - {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str47, T_TYPE, TF_COMMAND, S_BOOLEAN}, - {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str48, T_MAINMENU, TF_COMMAND}, - {-1}, {-1}, - {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str51, T_SOURCE, TF_COMMAND} + {(int)(long)&((struct kconf_id_strings_t *)0)->kconf_id_strings_str48, T_MAINMENU, TF_COMMAND} }; if (len <= MAX_WORD_LENGTH && len >= MIN_WORD_LENGTH) diff --git a/trunk/scripts/kconfig/zconf.tab.c_shipped b/trunk/scripts/kconfig/zconf.tab.c_shipped index 4c5495ea205e..699d4b265186 100644 --- a/trunk/scripts/kconfig/zconf.tab.c_shipped +++ b/trunk/scripts/kconfig/zconf.tab.c_shipped @@ -160,19 +160,18 @@ static struct menu *current_menu, *current_entry; T_DEFAULT = 275, T_SELECT = 276, T_RANGE = 277, - T_VISIBLE = 278, - T_OPTION = 279, - T_ON = 280, - T_WORD = 281, - T_WORD_QUOTE = 282, - T_UNEQUAL = 283, - T_CLOSE_PAREN = 284, - T_OPEN_PAREN = 285, - T_EOL = 286, - T_OR = 287, - T_AND = 288, - T_EQUAL = 289, - T_NOT = 290 + T_OPTION = 278, + T_ON = 279, + T_WORD = 280, + T_WORD_QUOTE = 281, + T_UNEQUAL = 282, + T_CLOSE_PAREN = 283, + T_OPEN_PAREN = 284, + T_EOL = 285, + T_OR = 286, + T_AND = 287, + T_EQUAL = 288, + T_NOT = 289 }; #endif @@ -420,20 +419,20 @@ union yyalloc /* YYFINAL -- State number of the termination state. */ #define YYFINAL 11 /* YYLAST -- Last index in YYTABLE. */ -#define YYLAST 290 +#define YYLAST 277 /* YYNTOKENS -- Number of terminals. */ -#define YYNTOKENS 36 +#define YYNTOKENS 35 /* YYNNTS -- Number of nonterminals. */ -#define YYNNTS 50 +#define YYNNTS 48 /* YYNRULES -- Number of rules. */ -#define YYNRULES 118 +#define YYNRULES 113 /* YYNRULES -- Number of states. */ -#define YYNSTATES 191 +#define YYNSTATES 185 /* YYTRANSLATE(YYLEX) -- Bison symbol number corresponding to YYLEX. */ #define YYUNDEFTOK 2 -#define YYMAXUTOK 290 +#define YYMAXUTOK 289 #define YYTRANSLATE(YYX) \ ((unsigned int) (YYX) <= YYMAXUTOK ? yytranslate[YYX] : YYUNDEFTOK) @@ -469,8 +468,7 @@ static const yytype_uint8 yytranslate[] = 2, 2, 2, 2, 2, 2, 1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13, 14, 15, 16, 17, 18, 19, 20, 21, 22, 23, 24, - 25, 26, 27, 28, 29, 30, 31, 32, 33, 34, - 35 + 25, 26, 27, 28, 29, 30, 31, 32, 33, 34 }; #if YYDEBUG @@ -480,73 +478,72 @@ static const yytype_uint16 yyprhs[] = { 0, 0, 3, 6, 8, 11, 13, 14, 17, 20, 23, 26, 31, 36, 40, 42, 44, 46, 48, 50, - 52, 54, 56, 58, 60, 62, 64, 66, 68, 72, - 75, 79, 82, 86, 89, 90, 93, 96, 99, 102, - 105, 108, 112, 117, 122, 127, 133, 137, 138, 142, - 143, 146, 150, 153, 155, 159, 160, 163, 166, 169, - 172, 175, 180, 184, 187, 192, 193, 196, 200, 202, - 206, 207, 210, 213, 216, 220, 224, 228, 230, 234, - 235, 238, 241, 244, 248, 252, 255, 258, 261, 262, - 265, 268, 271, 276, 277, 280, 283, 286, 287, 290, - 292, 294, 297, 300, 303, 305, 308, 309, 312, 314, - 318, 322, 326, 329, 333, 337, 339, 341, 342 + 52, 54, 56, 58, 60, 62, 64, 66, 70, 73, + 77, 80, 84, 87, 88, 91, 94, 97, 100, 103, + 106, 110, 115, 120, 125, 131, 135, 136, 140, 141, + 144, 148, 151, 153, 157, 158, 161, 164, 167, 170, + 173, 178, 182, 185, 190, 191, 194, 198, 200, 204, + 205, 208, 211, 214, 218, 222, 225, 227, 231, 232, + 235, 238, 241, 245, 249, 252, 255, 258, 259, 262, + 265, 268, 273, 274, 277, 279, 281, 284, 287, 290, + 292, 295, 296, 299, 301, 305, 309, 313, 316, 320, + 324, 326, 328, 329 }; /* YYRHS -- A `-1'-separated list of the rules' RHS. */ static const yytype_int8 yyrhs[] = { - 37, 0, -1, 81, 38, -1, 38, -1, 63, 39, - -1, 39, -1, -1, 39, 41, -1, 39, 55, -1, - 39, 67, -1, 39, 80, -1, 39, 26, 1, 31, - -1, 39, 40, 1, 31, -1, 39, 1, 31, -1, + 36, 0, -1, 78, 37, -1, 37, -1, 62, 38, + -1, 38, -1, -1, 38, 40, -1, 38, 54, -1, + 38, 66, -1, 38, 77, -1, 38, 25, 1, 30, + -1, 38, 39, 1, 30, -1, 38, 1, 30, -1, 16, -1, 18, -1, 19, -1, 21, -1, 17, -1, - 22, -1, 20, -1, 23, -1, 31, -1, 61, -1, - 71, -1, 44, -1, 46, -1, 69, -1, 26, 1, - 31, -1, 1, 31, -1, 10, 26, 31, -1, 43, - 47, -1, 11, 26, 31, -1, 45, 47, -1, -1, - 47, 48, -1, 47, 49, -1, 47, 75, -1, 47, - 73, -1, 47, 42, -1, 47, 31, -1, 19, 78, - 31, -1, 18, 79, 82, 31, -1, 20, 83, 82, - 31, -1, 21, 26, 82, 31, -1, 22, 84, 84, - 82, 31, -1, 24, 50, 31, -1, -1, 50, 26, - 51, -1, -1, 34, 79, -1, 7, 85, 31, -1, - 52, 56, -1, 80, -1, 53, 58, 54, -1, -1, - 56, 57, -1, 56, 75, -1, 56, 73, -1, 56, - 31, -1, 56, 42, -1, 18, 79, 82, 31, -1, - 19, 78, 31, -1, 17, 31, -1, 20, 26, 82, - 31, -1, -1, 58, 41, -1, 14, 83, 81, -1, - 80, -1, 59, 62, 60, -1, -1, 62, 41, -1, - 62, 67, -1, 62, 55, -1, 3, 79, 81, -1, - 4, 79, 31, -1, 64, 76, 74, -1, 80, -1, - 65, 68, 66, -1, -1, 68, 41, -1, 68, 67, - -1, 68, 55, -1, 6, 79, 31, -1, 9, 79, - 31, -1, 70, 74, -1, 12, 31, -1, 72, 13, - -1, -1, 74, 75, -1, 74, 31, -1, 74, 42, - -1, 16, 25, 83, 31, -1, -1, 76, 77, -1, - 76, 31, -1, 23, 82, -1, -1, 79, 82, -1, - 26, -1, 27, -1, 5, 31, -1, 8, 31, -1, - 15, 31, -1, 31, -1, 81, 31, -1, -1, 14, - 83, -1, 84, -1, 84, 34, 84, -1, 84, 28, - 84, -1, 30, 83, 29, -1, 35, 83, -1, 83, - 32, 83, -1, 83, 33, 83, -1, 26, -1, 27, - -1, -1, 26, -1 + 22, -1, 20, -1, 30, -1, 60, -1, 70, -1, + 43, -1, 45, -1, 68, -1, 25, 1, 30, -1, + 1, 30, -1, 10, 25, 30, -1, 42, 46, -1, + 11, 25, 30, -1, 44, 46, -1, -1, 46, 47, + -1, 46, 48, -1, 46, 74, -1, 46, 72, -1, + 46, 41, -1, 46, 30, -1, 19, 75, 30, -1, + 18, 76, 79, 30, -1, 20, 80, 79, 30, -1, + 21, 25, 79, 30, -1, 22, 81, 81, 79, 30, + -1, 23, 49, 30, -1, -1, 49, 25, 50, -1, + -1, 33, 76, -1, 7, 82, 30, -1, 51, 55, + -1, 77, -1, 52, 57, 53, -1, -1, 55, 56, + -1, 55, 74, -1, 55, 72, -1, 55, 30, -1, + 55, 41, -1, 18, 76, 79, 30, -1, 19, 75, + 30, -1, 17, 30, -1, 20, 25, 79, 30, -1, + -1, 57, 40, -1, 14, 80, 78, -1, 77, -1, + 58, 61, 59, -1, -1, 61, 40, -1, 61, 66, + -1, 61, 54, -1, 3, 76, 78, -1, 4, 76, + 30, -1, 63, 73, -1, 77, -1, 64, 67, 65, + -1, -1, 67, 40, -1, 67, 66, -1, 67, 54, + -1, 6, 76, 30, -1, 9, 76, 30, -1, 69, + 73, -1, 12, 30, -1, 71, 13, -1, -1, 73, + 74, -1, 73, 30, -1, 73, 41, -1, 16, 24, + 80, 30, -1, -1, 76, 79, -1, 25, -1, 26, + -1, 5, 30, -1, 8, 30, -1, 15, 30, -1, + 30, -1, 78, 30, -1, -1, 14, 80, -1, 81, + -1, 81, 33, 81, -1, 81, 27, 81, -1, 29, + 80, 28, -1, 34, 80, -1, 80, 31, 80, -1, + 80, 32, 80, -1, 25, -1, 26, -1, -1, 25, + -1 }; /* YYRLINE[YYN] -- source line where rule number YYN was defined. */ static const yytype_uint16 yyrline[] = { - 0, 108, 108, 108, 110, 110, 112, 114, 115, 116, - 117, 118, 119, 123, 127, 127, 127, 127, 127, 127, - 127, 127, 131, 132, 133, 134, 135, 136, 140, 141, - 147, 155, 161, 169, 179, 181, 182, 183, 184, 185, - 186, 189, 197, 203, 213, 219, 225, 228, 230, 241, - 242, 247, 256, 261, 269, 272, 274, 275, 276, 277, - 278, 281, 287, 298, 304, 314, 316, 321, 329, 337, - 340, 342, 343, 344, 349, 356, 363, 368, 376, 379, - 381, 382, 383, 386, 394, 401, 408, 414, 421, 423, - 424, 425, 428, 436, 438, 439, 442, 449, 451, 456, - 457, 460, 461, 462, 466, 467, 470, 471, 474, 475, - 476, 477, 478, 479, 480, 483, 484, 487, 488 + 0, 107, 107, 107, 109, 109, 111, 113, 114, 115, + 116, 117, 118, 122, 126, 126, 126, 126, 126, 126, + 126, 130, 131, 132, 133, 134, 135, 139, 140, 146, + 154, 160, 168, 178, 180, 181, 182, 183, 184, 185, + 188, 196, 202, 212, 218, 224, 227, 229, 240, 241, + 246, 255, 260, 268, 271, 273, 274, 275, 276, 277, + 280, 286, 297, 303, 313, 315, 320, 328, 336, 339, + 341, 342, 343, 348, 355, 362, 367, 375, 378, 380, + 381, 382, 385, 393, 400, 407, 413, 420, 422, 423, + 424, 427, 435, 437, 442, 443, 446, 447, 448, 452, + 453, 456, 457, 460, 461, 462, 463, 464, 465, 466, + 469, 470, 473, 474 }; #endif @@ -559,7 +556,7 @@ static const char *const yytname[] = "T_SOURCE", "T_CHOICE", "T_ENDCHOICE", "T_COMMENT", "T_CONFIG", "T_MENUCONFIG", "T_HELP", "T_HELPTEXT", "T_IF", "T_ENDIF", "T_DEPENDS", "T_OPTIONAL", "T_PROMPT", "T_TYPE", "T_DEFAULT", "T_SELECT", "T_RANGE", - "T_VISIBLE", "T_OPTION", "T_ON", "T_WORD", "T_WORD_QUOTE", "T_UNEQUAL", + "T_OPTION", "T_ON", "T_WORD", "T_WORD_QUOTE", "T_UNEQUAL", "T_CLOSE_PAREN", "T_OPEN_PAREN", "T_EOL", "T_OR", "T_AND", "T_EQUAL", "T_NOT", "$accept", "input", "start", "stmt_list", "option_name", "common_stmt", "option_error", "config_entry_start", "config_stmt", @@ -570,8 +567,8 @@ static const char *const yytname[] = "if_entry", "if_end", "if_stmt", "if_block", "mainmenu_stmt", "menu", "menu_entry", "menu_end", "menu_stmt", "menu_block", "source_stmt", "comment", "comment_stmt", "help_start", "help", "depends_list", - "depends", "visibility_list", "visible", "prompt_stmt_opt", "prompt", - "end", "nl", "if_expr", "expr", "symbol", "word_opt", 0 + "depends", "prompt_stmt_opt", "prompt", "end", "nl", "if_expr", "expr", + "symbol", "word_opt", 0 }; #endif @@ -583,25 +580,25 @@ static const yytype_uint16 yytoknum[] = 0, 256, 257, 258, 259, 260, 261, 262, 263, 264, 265, 266, 267, 268, 269, 270, 271, 272, 273, 274, 275, 276, 277, 278, 279, 280, 281, 282, 283, 284, - 285, 286, 287, 288, 289, 290 + 285, 286, 287, 288, 289 }; # endif /* YYR1[YYN] -- Symbol number of symbol that rule YYN derives. */ static const yytype_uint8 yyr1[] = { - 0, 36, 37, 37, 38, 38, 39, 39, 39, 39, - 39, 39, 39, 39, 40, 40, 40, 40, 40, 40, - 40, 40, 41, 41, 41, 41, 41, 41, 42, 42, - 43, 44, 45, 46, 47, 47, 47, 47, 47, 47, - 47, 48, 48, 48, 48, 48, 49, 50, 50, 51, - 51, 52, 53, 54, 55, 56, 56, 56, 56, 56, - 56, 57, 57, 57, 57, 58, 58, 59, 60, 61, - 62, 62, 62, 62, 63, 64, 65, 66, 67, 68, - 68, 68, 68, 69, 70, 71, 72, 73, 74, 74, - 74, 74, 75, 76, 76, 76, 77, 78, 78, 79, - 79, 80, 80, 80, 81, 81, 82, 82, 83, 83, - 83, 83, 83, 83, 83, 84, 84, 85, 85 + 0, 35, 36, 36, 37, 37, 38, 38, 38, 38, + 38, 38, 38, 38, 39, 39, 39, 39, 39, 39, + 39, 40, 40, 40, 40, 40, 40, 41, 41, 42, + 43, 44, 45, 46, 46, 46, 46, 46, 46, 46, + 47, 47, 47, 47, 47, 48, 49, 49, 50, 50, + 51, 52, 53, 54, 55, 55, 55, 55, 55, 55, + 56, 56, 56, 56, 57, 57, 58, 59, 60, 61, + 61, 61, 61, 62, 63, 64, 65, 66, 67, 67, + 67, 67, 68, 69, 70, 71, 72, 73, 73, 73, + 73, 74, 75, 75, 76, 76, 77, 77, 77, 78, + 78, 79, 79, 80, 80, 80, 80, 80, 80, 80, + 81, 81, 82, 82 }; /* YYR2[YYN] -- Number of symbols composing right hand side of rule YYN. */ @@ -609,16 +606,16 @@ static const yytype_uint8 yyr2[] = { 0, 2, 2, 1, 2, 1, 0, 2, 2, 2, 2, 4, 4, 3, 1, 1, 1, 1, 1, 1, - 1, 1, 1, 1, 1, 1, 1, 1, 3, 2, - 3, 2, 3, 2, 0, 2, 2, 2, 2, 2, - 2, 3, 4, 4, 4, 5, 3, 0, 3, 0, - 2, 3, 2, 1, 3, 0, 2, 2, 2, 2, - 2, 4, 3, 2, 4, 0, 2, 3, 1, 3, - 0, 2, 2, 2, 3, 3, 3, 1, 3, 0, - 2, 2, 2, 3, 3, 2, 2, 2, 0, 2, - 2, 2, 4, 0, 2, 2, 2, 0, 2, 1, - 1, 2, 2, 2, 1, 2, 0, 2, 1, 3, - 3, 3, 2, 3, 3, 1, 1, 0, 1 + 1, 1, 1, 1, 1, 1, 1, 3, 2, 3, + 2, 3, 2, 0, 2, 2, 2, 2, 2, 2, + 3, 4, 4, 4, 5, 3, 0, 3, 0, 2, + 3, 2, 1, 3, 0, 2, 2, 2, 2, 2, + 4, 3, 2, 4, 0, 2, 3, 1, 3, 0, + 2, 2, 2, 3, 3, 2, 1, 3, 0, 2, + 2, 2, 3, 3, 2, 2, 2, 0, 2, 2, + 2, 4, 0, 2, 1, 1, 2, 2, 2, 1, + 2, 0, 2, 1, 3, 3, 3, 2, 3, 3, + 1, 1, 0, 1 }; /* YYDEFACT[STATE-NAME] -- Default rule to reduce with in state @@ -626,172 +623,165 @@ static const yytype_uint8 yyr2[] = means the default is an error. */ static const yytype_uint8 yydefact[] = { - 6, 0, 104, 0, 3, 0, 6, 6, 99, 100, - 0, 1, 0, 0, 0, 0, 117, 0, 0, 0, + 6, 0, 99, 0, 3, 0, 6, 6, 94, 95, + 0, 1, 0, 0, 0, 0, 112, 0, 0, 0, 0, 0, 0, 14, 18, 15, 16, 20, 17, 19, - 21, 0, 22, 0, 7, 34, 25, 34, 26, 55, - 65, 8, 70, 23, 93, 79, 9, 27, 88, 24, - 10, 0, 105, 2, 74, 13, 0, 101, 0, 118, - 0, 102, 0, 0, 0, 115, 116, 0, 0, 0, - 108, 103, 0, 0, 0, 0, 0, 0, 0, 88, - 0, 0, 75, 83, 51, 84, 30, 32, 0, 112, - 0, 0, 67, 0, 0, 11, 12, 0, 0, 0, - 0, 97, 0, 0, 0, 47, 0, 40, 39, 35, - 36, 0, 38, 37, 0, 0, 97, 0, 59, 60, - 56, 58, 57, 66, 54, 53, 71, 73, 69, 72, - 68, 106, 95, 0, 94, 80, 82, 78, 81, 77, - 90, 91, 89, 111, 113, 114, 110, 109, 29, 86, - 0, 106, 0, 106, 106, 106, 0, 0, 0, 87, - 63, 106, 0, 106, 0, 96, 0, 0, 41, 98, - 0, 0, 106, 49, 46, 28, 0, 62, 0, 107, - 92, 42, 43, 44, 0, 0, 48, 61, 64, 45, - 50 + 0, 21, 0, 7, 33, 24, 33, 25, 54, 64, + 8, 69, 22, 87, 78, 9, 26, 87, 23, 10, + 0, 100, 2, 73, 13, 0, 96, 0, 113, 0, + 97, 0, 0, 0, 110, 111, 0, 0, 0, 103, + 98, 0, 0, 0, 0, 0, 0, 0, 0, 0, + 0, 74, 82, 50, 83, 29, 31, 0, 107, 0, + 0, 66, 0, 0, 11, 12, 0, 0, 0, 0, + 92, 0, 0, 0, 46, 0, 39, 38, 34, 35, + 0, 37, 36, 0, 0, 92, 0, 58, 59, 55, + 57, 56, 65, 53, 52, 70, 72, 68, 71, 67, + 89, 90, 88, 79, 81, 77, 80, 76, 106, 108, + 109, 105, 104, 28, 85, 0, 101, 0, 101, 101, + 101, 0, 0, 0, 86, 62, 101, 0, 101, 0, + 0, 0, 40, 93, 0, 0, 101, 48, 45, 27, + 0, 61, 0, 91, 102, 41, 42, 43, 0, 0, + 47, 60, 63, 44, 49 }; /* YYDEFGOTO[NTERM-NUM]. */ static const yytype_int16 yydefgoto[] = { - -1, 3, 4, 5, 33, 34, 108, 35, 36, 37, - 38, 74, 109, 110, 157, 186, 39, 40, 124, 41, - 76, 120, 77, 42, 128, 43, 78, 6, 44, 45, - 137, 46, 80, 47, 48, 49, 111, 112, 81, 113, - 79, 134, 152, 153, 50, 7, 165, 69, 70, 60 + -1, 3, 4, 5, 32, 33, 107, 34, 35, 36, + 37, 73, 108, 109, 152, 180, 38, 39, 123, 40, + 75, 119, 76, 41, 127, 42, 77, 6, 43, 44, + 135, 45, 79, 46, 47, 48, 110, 111, 78, 112, + 147, 148, 49, 7, 161, 68, 69, 59 }; /* YYPACT[STATE-NUM] -- Index in YYTABLE of the portion describing STATE-NUM. */ -#define YYPACT_NINF -90 +#define YYPACT_NINF -89 static const yytype_int16 yypact[] = { - 4, 42, -90, 96, -90, 111, -90, 15, -90, -90, - 75, -90, 82, 42, 104, 42, 110, 107, 42, 115, - 125, -4, 121, -90, -90, -90, -90, -90, -90, -90, - -90, 162, -90, 163, -90, -90, -90, -90, -90, -90, - -90, -90, -90, -90, -90, -90, -90, -90, -90, -90, - -90, 139, -90, -90, 138, -90, 142, -90, 143, -90, - 152, -90, 164, 167, 168, -90, -90, -4, -4, 77, - -18, -90, 177, 185, 33, 71, 195, 247, 236, -2, - 236, 171, -90, -90, -90, -90, -90, -90, 41, -90, - -4, -4, 138, 97, 97, -90, -90, 186, 187, 194, - 42, 42, -4, 196, 97, -90, 219, -90, -90, -90, - -90, 210, -90, -90, 204, 42, 42, 199, -90, -90, - -90, -90, -90, -90, -90, -90, -90, -90, -90, -90, - -90, 222, -90, 223, -90, -90, -90, -90, -90, -90, - -90, -90, -90, -90, 215, -90, -90, -90, -90, -90, - -4, 222, 228, 222, -5, 222, 97, 35, 229, -90, - -90, 222, 232, 222, -4, -90, 135, 233, -90, -90, - 234, 235, 222, 240, -90, -90, 237, -90, 239, -13, - -90, -90, -90, -90, 244, 42, -90, -90, -90, -90, - -90 + 3, 4, -89, 20, -89, 100, -89, 7, -89, -89, + -8, -89, 17, 4, 28, 4, 37, 36, 4, 68, + 87, -18, 69, -89, -89, -89, -89, -89, -89, -89, + 128, -89, 138, -89, -89, -89, -89, -89, -89, -89, + -89, -89, -89, -89, -89, -89, -89, -89, -89, -89, + 127, -89, -89, 110, -89, 126, -89, 136, -89, 137, + -89, 147, 150, 152, -89, -89, -18, -18, 171, -14, + -89, 153, 157, 34, 67, 180, 233, 220, 207, 220, + 154, -89, -89, -89, -89, -89, -89, 0, -89, -18, + -18, 110, 44, 44, -89, -89, 163, 174, 182, 4, + 4, -18, 194, 44, -89, 219, -89, -89, -89, -89, + 223, -89, -89, 203, 4, 4, 215, -89, -89, -89, + -89, -89, -89, -89, -89, -89, -89, -89, -89, -89, + -89, -89, -89, -89, -89, -89, -89, -89, -89, 213, + -89, -89, -89, -89, -89, -18, 232, 227, 232, -5, + 232, 44, 35, 234, -89, -89, 232, 235, 232, 224, + -18, 236, -89, -89, 237, 238, 232, 216, -89, -89, + 240, -89, 241, -89, 71, -89, -89, -89, 242, 4, + -89, -89, -89, -89, -89 }; /* YYPGOTO[NTERM-NUM]. */ static const yytype_int16 yypgoto[] = { - -90, -90, 269, 271, -90, 23, -70, -90, -90, -90, - -90, 243, -90, -90, -90, -90, -90, -90, -90, -48, - -90, -90, -90, -90, -90, -90, -90, -90, -90, -90, - -90, -20, -90, -90, -90, -90, -90, 206, 205, -68, - -90, -90, 169, -1, 27, -7, 118, -66, -89, -90 + -89, -89, 255, 267, -89, 47, -57, -89, -89, -89, + -89, 239, -89, -89, -89, -89, -89, -89, -89, 130, + -89, -89, -89, -89, -89, -89, -89, -89, -89, -89, + -89, 181, -89, -89, -89, -89, -89, 199, 229, 16, + 162, -1, 74, -7, 103, -65, -88, -89 }; /* YYTABLE[YYPACT[STATE-NUM]]. What to do in state STATE-NUM. If positive, shift that token. If negative, reduce the rule which number is the opposite. If zero, do what YYDEFACT says. If YYTABLE_NINF, syntax error. */ -#define YYTABLE_NINF -86 +#define YYTABLE_NINF -85 static const yytype_int16 yytable[] = { - 10, 88, 89, 54, 146, 147, 119, 1, 122, 164, - 93, 141, 56, 142, 58, 156, 94, 62, 1, 90, - 91, 131, 65, 66, 144, 145, 67, 90, 91, 132, - 127, 68, 136, -31, 97, 2, 154, -31, -31, -31, - -31, -31, -31, -31, -31, 98, 52, -31, -31, 99, - -31, 100, 101, 102, 103, 104, -31, 105, 129, 106, - 138, 173, 92, 141, 107, 142, 174, 172, 8, 9, - 143, -33, 97, 90, 91, -33, -33, -33, -33, -33, - -33, -33, -33, 98, 166, -33, -33, 99, -33, 100, - 101, 102, 103, 104, -33, 105, 11, 106, 179, 151, - 123, 126, 107, 135, 125, 130, 2, 139, 2, 90, - 91, -5, 12, 55, 161, 13, 14, 15, 16, 17, - 18, 19, 20, 65, 66, 21, 22, 23, 24, 25, - 26, 27, 28, 29, 30, 57, 59, 31, 61, -4, - 12, 63, 32, 13, 14, 15, 16, 17, 18, 19, - 20, 64, 71, 21, 22, 23, 24, 25, 26, 27, - 28, 29, 30, 72, 73, 31, 180, 90, 91, 52, - 32, -85, 97, 82, 83, -85, -85, -85, -85, -85, - -85, -85, -85, 84, 190, -85, -85, 99, -85, -85, - -85, -85, -85, -85, -85, 85, 97, 106, 86, 87, - -52, -52, 140, -52, -52, -52, -52, 98, 95, -52, - -52, 99, 114, 115, 116, 117, 96, 148, 149, 150, - 158, 106, 155, 159, 97, 163, 118, -76, -76, -76, - -76, -76, -76, -76, -76, 160, 164, -76, -76, 99, - 13, 14, 15, 16, 17, 18, 19, 20, 91, 106, - 21, 22, 14, 15, 140, 17, 18, 19, 20, 168, - 175, 21, 22, 177, 181, 182, 183, 32, 187, 167, - 188, 169, 170, 171, 185, 189, 53, 51, 32, 176, - 75, 178, 121, 0, 133, 162, 0, 0, 0, 0, - 184 + 10, 87, 88, 53, 141, 142, 1, 64, 65, 160, + 1, 66, 55, 92, 57, 151, 67, 61, 118, 93, + 11, 131, 2, 131, 139, 140, 89, 90, 138, 8, + 9, 89, 90, 2, -30, 96, 149, 51, -30, -30, + -30, -30, -30, -30, -30, -30, 97, 54, -30, -30, + 98, -30, 99, 100, 101, 102, 103, 104, 56, 105, + 167, 91, 58, 166, 106, 168, 60, -32, 96, 64, + 65, -32, -32, -32, -32, -32, -32, -32, -32, 97, + 159, -32, -32, 98, -32, 99, 100, 101, 102, 103, + 104, 121, 105, 62, 132, 174, 132, 106, 146, 70, + -5, 12, 89, 90, 13, 14, 15, 16, 17, 18, + 19, 20, 63, 156, 21, 22, 23, 24, 25, 26, + 27, 28, 29, 122, 125, 30, 133, -4, 12, 71, + 31, 13, 14, 15, 16, 17, 18, 19, 20, 72, + 51, 21, 22, 23, 24, 25, 26, 27, 28, 29, + 124, 129, 30, 137, -84, 96, 81, 31, -84, -84, + -84, -84, -84, -84, -84, -84, 82, 83, -84, -84, + 98, -84, -84, -84, -84, -84, -84, 84, 184, 105, + 85, 96, 86, 94, 130, -51, -51, 95, -51, -51, + -51, -51, 97, 143, -51, -51, 98, 113, 114, 115, + 116, 2, 89, 90, 144, 105, 145, 126, 96, 134, + 117, -75, -75, -75, -75, -75, -75, -75, -75, 150, + 153, -75, -75, 98, 13, 14, 15, 16, 17, 18, + 19, 20, 105, 155, 21, 22, 154, 130, 14, 15, + 158, 17, 18, 19, 20, 90, 160, 21, 22, 179, + 31, 163, 164, 165, 173, 89, 90, 162, 128, 170, + 136, 172, 52, 31, 169, 171, 175, 176, 177, 178, + 181, 182, 183, 50, 120, 74, 80, 157 }; -static const yytype_int16 yycheck[] = +static const yytype_uint8 yycheck[] = { - 1, 67, 68, 10, 93, 94, 76, 3, 76, 14, - 28, 81, 13, 81, 15, 104, 34, 18, 3, 32, - 33, 23, 26, 27, 90, 91, 30, 32, 33, 31, - 78, 35, 80, 0, 1, 31, 102, 4, 5, 6, - 7, 8, 9, 10, 11, 12, 31, 14, 15, 16, - 17, 18, 19, 20, 21, 22, 23, 24, 78, 26, - 80, 26, 69, 133, 31, 133, 31, 156, 26, 27, - 29, 0, 1, 32, 33, 4, 5, 6, 7, 8, - 9, 10, 11, 12, 150, 14, 15, 16, 17, 18, - 19, 20, 21, 22, 23, 24, 0, 26, 164, 100, - 77, 78, 31, 80, 77, 78, 31, 80, 31, 32, - 33, 0, 1, 31, 115, 4, 5, 6, 7, 8, - 9, 10, 11, 26, 27, 14, 15, 16, 17, 18, - 19, 20, 21, 22, 23, 31, 26, 26, 31, 0, - 1, 26, 31, 4, 5, 6, 7, 8, 9, 10, - 11, 26, 31, 14, 15, 16, 17, 18, 19, 20, - 21, 22, 23, 1, 1, 26, 31, 32, 33, 31, - 31, 0, 1, 31, 31, 4, 5, 6, 7, 8, - 9, 10, 11, 31, 185, 14, 15, 16, 17, 18, - 19, 20, 21, 22, 23, 31, 1, 26, 31, 31, - 5, 6, 31, 8, 9, 10, 11, 12, 31, 14, - 15, 16, 17, 18, 19, 20, 31, 31, 31, 25, - 1, 26, 26, 13, 1, 26, 31, 4, 5, 6, - 7, 8, 9, 10, 11, 31, 14, 14, 15, 16, - 4, 5, 6, 7, 8, 9, 10, 11, 33, 26, - 14, 15, 5, 6, 31, 8, 9, 10, 11, 31, - 31, 14, 15, 31, 31, 31, 31, 31, 31, 151, - 31, 153, 154, 155, 34, 31, 7, 6, 31, 161, - 37, 163, 76, -1, 79, 116, -1, -1, -1, -1, - 172 + 1, 66, 67, 10, 92, 93, 3, 25, 26, 14, + 3, 29, 13, 27, 15, 103, 34, 18, 75, 33, + 0, 78, 30, 80, 89, 90, 31, 32, 28, 25, + 26, 31, 32, 30, 0, 1, 101, 30, 4, 5, + 6, 7, 8, 9, 10, 11, 12, 30, 14, 15, + 16, 17, 18, 19, 20, 21, 22, 23, 30, 25, + 25, 68, 25, 151, 30, 30, 30, 0, 1, 25, + 26, 4, 5, 6, 7, 8, 9, 10, 11, 12, + 145, 14, 15, 16, 17, 18, 19, 20, 21, 22, + 23, 75, 25, 25, 78, 160, 80, 30, 99, 30, + 0, 1, 31, 32, 4, 5, 6, 7, 8, 9, + 10, 11, 25, 114, 14, 15, 16, 17, 18, 19, + 20, 21, 22, 76, 77, 25, 79, 0, 1, 1, + 30, 4, 5, 6, 7, 8, 9, 10, 11, 1, + 30, 14, 15, 16, 17, 18, 19, 20, 21, 22, + 76, 77, 25, 79, 0, 1, 30, 30, 4, 5, + 6, 7, 8, 9, 10, 11, 30, 30, 14, 15, + 16, 17, 18, 19, 20, 21, 22, 30, 179, 25, + 30, 1, 30, 30, 30, 5, 6, 30, 8, 9, + 10, 11, 12, 30, 14, 15, 16, 17, 18, 19, + 20, 30, 31, 32, 30, 25, 24, 77, 1, 79, + 30, 4, 5, 6, 7, 8, 9, 10, 11, 25, + 1, 14, 15, 16, 4, 5, 6, 7, 8, 9, + 10, 11, 25, 30, 14, 15, 13, 30, 5, 6, + 25, 8, 9, 10, 11, 32, 14, 14, 15, 33, + 30, 148, 149, 150, 30, 31, 32, 30, 77, 156, + 79, 158, 7, 30, 30, 30, 30, 30, 30, 166, + 30, 30, 30, 6, 75, 36, 47, 115 }; /* YYSTOS[STATE-NUM] -- The (internal number of the) accessing symbol of state STATE-NUM. */ static const yytype_uint8 yystos[] = { - 0, 3, 31, 37, 38, 39, 63, 81, 26, 27, - 79, 0, 1, 4, 5, 6, 7, 8, 9, 10, + 0, 3, 30, 36, 37, 38, 62, 78, 25, 26, + 76, 0, 1, 4, 5, 6, 7, 8, 9, 10, 11, 14, 15, 16, 17, 18, 19, 20, 21, 22, - 23, 26, 31, 40, 41, 43, 44, 45, 46, 52, - 53, 55, 59, 61, 64, 65, 67, 69, 70, 71, - 80, 39, 31, 38, 81, 31, 79, 31, 79, 26, - 85, 31, 79, 26, 26, 26, 27, 30, 35, 83, - 84, 31, 1, 1, 47, 47, 56, 58, 62, 76, - 68, 74, 31, 31, 31, 31, 31, 31, 83, 83, - 32, 33, 81, 28, 34, 31, 31, 1, 12, 16, - 18, 19, 20, 21, 22, 24, 26, 31, 42, 48, - 49, 72, 73, 75, 17, 18, 19, 20, 31, 42, - 57, 73, 75, 41, 54, 80, 41, 55, 60, 67, - 80, 23, 31, 74, 77, 41, 55, 66, 67, 80, - 31, 42, 75, 29, 83, 83, 84, 84, 31, 31, - 25, 79, 78, 79, 83, 26, 84, 50, 1, 13, - 31, 79, 78, 26, 14, 82, 83, 82, 31, 82, - 82, 82, 84, 26, 31, 31, 82, 31, 82, 83, - 31, 31, 31, 31, 82, 34, 51, 31, 31, 31, - 79 + 25, 30, 39, 40, 42, 43, 44, 45, 51, 52, + 54, 58, 60, 63, 64, 66, 68, 69, 70, 77, + 38, 30, 37, 78, 30, 76, 30, 76, 25, 82, + 30, 76, 25, 25, 25, 26, 29, 34, 80, 81, + 30, 1, 1, 46, 46, 55, 57, 61, 73, 67, + 73, 30, 30, 30, 30, 30, 30, 80, 80, 31, + 32, 78, 27, 33, 30, 30, 1, 12, 16, 18, + 19, 20, 21, 22, 23, 25, 30, 41, 47, 48, + 71, 72, 74, 17, 18, 19, 20, 30, 41, 56, + 72, 74, 40, 53, 77, 40, 54, 59, 66, 77, + 30, 41, 74, 40, 54, 65, 66, 77, 28, 80, + 80, 81, 81, 30, 30, 24, 76, 75, 76, 80, + 25, 81, 49, 1, 13, 30, 76, 75, 25, 80, + 14, 79, 30, 79, 79, 79, 81, 25, 30, 30, + 79, 30, 79, 30, 80, 30, 30, 30, 79, 33, + 50, 30, 30, 30, 76 }; #define yyerrok (yyerrstatus = 0) @@ -1302,7 +1292,7 @@ yydestruct (yymsg, yytype, yyvaluep) switch (yytype) { - case 53: /* "choice_entry" */ + case 52: /* "choice_entry" */ { fprintf(stderr, "%s:%d: missing end statement for this entry\n", @@ -1312,7 +1302,7 @@ yydestruct (yymsg, yytype, yyvaluep) }; break; - case 59: /* "if_entry" */ + case 58: /* "if_entry" */ { fprintf(stderr, "%s:%d: missing end statement for this entry\n", @@ -1322,7 +1312,7 @@ yydestruct (yymsg, yytype, yyvaluep) }; break; - case 65: /* "menu_entry" */ + case 64: /* "menu_entry" */ { fprintf(stderr, "%s:%d: missing end statement for this entry\n", @@ -1654,17 +1644,17 @@ yyreduce: { zconf_error("invalid statement"); ;} break; - case 28: + case 27: { zconf_error("unknown option \"%s\"", (yyvsp[(1) - (3)].string)); ;} break; - case 29: + case 28: { zconf_error("invalid option"); ;} break; - case 30: + case 29: { struct symbol *sym = sym_lookup((yyvsp[(2) - (3)].string), 0); @@ -1674,7 +1664,7 @@ yyreduce: ;} break; - case 31: + case 30: { menu_end_entry(); @@ -1682,7 +1672,7 @@ yyreduce: ;} break; - case 32: + case 31: { struct symbol *sym = sym_lookup((yyvsp[(2) - (3)].string), 0); @@ -1692,7 +1682,7 @@ yyreduce: ;} break; - case 33: + case 32: { if (current_entry->prompt) @@ -1704,7 +1694,7 @@ yyreduce: ;} break; - case 41: + case 40: { menu_set_type((yyvsp[(1) - (3)].id)->stype); @@ -1714,7 +1704,7 @@ yyreduce: ;} break; - case 42: + case 41: { menu_add_prompt(P_PROMPT, (yyvsp[(2) - (4)].string), (yyvsp[(3) - (4)].expr)); @@ -1722,7 +1712,7 @@ yyreduce: ;} break; - case 43: + case 42: { menu_add_expr(P_DEFAULT, (yyvsp[(2) - (4)].expr), (yyvsp[(3) - (4)].expr)); @@ -1734,7 +1724,7 @@ yyreduce: ;} break; - case 44: + case 43: { menu_add_symbol(P_SELECT, sym_lookup((yyvsp[(2) - (4)].string), 0), (yyvsp[(3) - (4)].expr)); @@ -1742,7 +1732,7 @@ yyreduce: ;} break; - case 45: + case 44: { menu_add_expr(P_RANGE, expr_alloc_comp(E_RANGE,(yyvsp[(2) - (5)].symbol), (yyvsp[(3) - (5)].symbol)), (yyvsp[(4) - (5)].expr)); @@ -1750,7 +1740,7 @@ yyreduce: ;} break; - case 48: + case 47: { struct kconf_id *id = kconf_id_lookup((yyvsp[(2) - (3)].string), strlen((yyvsp[(2) - (3)].string))); @@ -1762,17 +1752,17 @@ yyreduce: ;} break; - case 49: + case 48: { (yyval.string) = NULL; ;} break; - case 50: + case 49: { (yyval.string) = (yyvsp[(2) - (2)].string); ;} break; - case 51: + case 50: { struct symbol *sym = sym_lookup((yyvsp[(2) - (3)].string), SYMBOL_CHOICE); @@ -1783,14 +1773,14 @@ yyreduce: ;} break; - case 52: + case 51: { (yyval.menu) = menu_add_menu(); ;} break; - case 53: + case 52: { if (zconf_endtoken((yyvsp[(1) - (1)].id), T_CHOICE, T_ENDCHOICE)) { @@ -1800,7 +1790,7 @@ yyreduce: ;} break; - case 61: + case 60: { menu_add_prompt(P_PROMPT, (yyvsp[(2) - (4)].string), (yyvsp[(3) - (4)].expr)); @@ -1808,7 +1798,7 @@ yyreduce: ;} break; - case 62: + case 61: { if ((yyvsp[(1) - (3)].id)->stype == S_BOOLEAN || (yyvsp[(1) - (3)].id)->stype == S_TRISTATE) { @@ -1821,7 +1811,7 @@ yyreduce: ;} break; - case 63: + case 62: { current_entry->sym->flags |= SYMBOL_OPTIONAL; @@ -1829,7 +1819,7 @@ yyreduce: ;} break; - case 64: + case 63: { if ((yyvsp[(1) - (4)].id)->stype == S_UNKNOWN) { @@ -1841,7 +1831,7 @@ yyreduce: ;} break; - case 67: + case 66: { printd(DEBUG_PARSE, "%s:%d:if\n", zconf_curname(), zconf_lineno()); @@ -1851,7 +1841,7 @@ yyreduce: ;} break; - case 68: + case 67: { if (zconf_endtoken((yyvsp[(1) - (1)].id), T_IF, T_ENDIF)) { @@ -1861,14 +1851,14 @@ yyreduce: ;} break; - case 74: + case 73: { menu_add_prompt(P_MENU, (yyvsp[(2) - (3)].string), NULL); ;} break; - case 75: + case 74: { menu_add_entry(NULL); @@ -1877,14 +1867,14 @@ yyreduce: ;} break; - case 76: + case 75: { (yyval.menu) = menu_add_menu(); ;} break; - case 77: + case 76: { if (zconf_endtoken((yyvsp[(1) - (1)].id), T_MENU, T_ENDMENU)) { @@ -1894,7 +1884,7 @@ yyreduce: ;} break; - case 83: + case 82: { printd(DEBUG_PARSE, "%s:%d:source %s\n", zconf_curname(), zconf_lineno(), (yyvsp[(2) - (3)].string)); @@ -1902,7 +1892,7 @@ yyreduce: ;} break; - case 84: + case 83: { menu_add_entry(NULL); @@ -1911,14 +1901,14 @@ yyreduce: ;} break; - case 85: + case 84: { menu_end_entry(); ;} break; - case 86: + case 85: { printd(DEBUG_PARSE, "%s:%d:help\n", zconf_curname(), zconf_lineno()); @@ -1926,14 +1916,14 @@ yyreduce: ;} break; - case 87: + case 86: { current_entry->help = (yyvsp[(2) - (2)].string); ;} break; - case 92: + case 91: { menu_add_dep((yyvsp[(3) - (4)].expr)); @@ -1941,91 +1931,84 @@ yyreduce: ;} break; - case 96: - - { - menu_add_visibility((yyvsp[(2) - (2)].expr)); -;} - break; - - case 98: + case 93: { menu_add_prompt(P_PROMPT, (yyvsp[(1) - (2)].string), (yyvsp[(2) - (2)].expr)); ;} break; - case 101: + case 96: { (yyval.id) = (yyvsp[(1) - (2)].id); ;} break; - case 102: + case 97: { (yyval.id) = (yyvsp[(1) - (2)].id); ;} break; - case 103: + case 98: { (yyval.id) = (yyvsp[(1) - (2)].id); ;} break; - case 106: + case 101: { (yyval.expr) = NULL; ;} break; - case 107: + case 102: { (yyval.expr) = (yyvsp[(2) - (2)].expr); ;} break; - case 108: + case 103: { (yyval.expr) = expr_alloc_symbol((yyvsp[(1) - (1)].symbol)); ;} break; - case 109: + case 104: { (yyval.expr) = expr_alloc_comp(E_EQUAL, (yyvsp[(1) - (3)].symbol), (yyvsp[(3) - (3)].symbol)); ;} break; - case 110: + case 105: { (yyval.expr) = expr_alloc_comp(E_UNEQUAL, (yyvsp[(1) - (3)].symbol), (yyvsp[(3) - (3)].symbol)); ;} break; - case 111: + case 106: { (yyval.expr) = (yyvsp[(2) - (3)].expr); ;} break; - case 112: + case 107: { (yyval.expr) = expr_alloc_one(E_NOT, (yyvsp[(2) - (2)].expr)); ;} break; - case 113: + case 108: { (yyval.expr) = expr_alloc_two(E_OR, (yyvsp[(1) - (3)].expr), (yyvsp[(3) - (3)].expr)); ;} break; - case 114: + case 109: { (yyval.expr) = expr_alloc_two(E_AND, (yyvsp[(1) - (3)].expr), (yyvsp[(3) - (3)].expr)); ;} break; - case 115: + case 110: { (yyval.symbol) = sym_lookup((yyvsp[(1) - (1)].string), 0); free((yyvsp[(1) - (1)].string)); ;} break; - case 116: + case 111: { (yyval.symbol) = sym_lookup((yyvsp[(1) - (1)].string), SYMBOL_CONST); free((yyvsp[(1) - (1)].string)); ;} break; - case 117: + case 112: { (yyval.string) = NULL; ;} break; @@ -2295,7 +2278,6 @@ static const char *zconf_tokenname(int token) case T_IF: return "if"; case T_ENDIF: return "endif"; case T_DEPENDS: return "depends"; - case T_VISIBLE: return "visible"; } return ""; } diff --git a/trunk/scripts/kconfig/zconf.y b/trunk/scripts/kconfig/zconf.y index 49fb4ab664c3..2abd3c7ff15d 100644 --- a/trunk/scripts/kconfig/zconf.y +++ b/trunk/scripts/kconfig/zconf.y @@ -36,7 +36,7 @@ static struct menu *current_menu, *current_entry; #define YYERROR_VERBOSE #endif %} -%expect 30 +%expect 28 %union { @@ -68,7 +68,6 @@ static struct menu *current_menu, *current_entry; %token T_DEFAULT %token T_SELECT %token T_RANGE -%token T_VISIBLE %token T_OPTION %token T_ON %token T_WORD @@ -124,7 +123,7 @@ stmt_list: ; option_name: - T_DEPENDS | T_PROMPT | T_TYPE | T_SELECT | T_OPTIONAL | T_RANGE | T_DEFAULT | T_VISIBLE + T_DEPENDS | T_PROMPT | T_TYPE | T_SELECT | T_OPTIONAL | T_RANGE | T_DEFAULT ; common_stmt: @@ -360,7 +359,7 @@ menu: T_MENU prompt T_EOL printd(DEBUG_PARSE, "%s:%d:menu\n", zconf_curname(), zconf_lineno()); }; -menu_entry: menu visibility_list depends_list +menu_entry: menu depends_list { $$ = menu_add_menu(); }; @@ -431,19 +430,6 @@ depends: T_DEPENDS T_ON expr T_EOL printd(DEBUG_PARSE, "%s:%d:depends on\n", zconf_curname(), zconf_lineno()); }; -/* visibility option */ - -visibility_list: - /* empty */ - | visibility_list visible - | visibility_list T_EOL -; - -visible: T_VISIBLE if_expr -{ - menu_add_visibility($2); -}; - /* prompt statement */ prompt_stmt_opt: @@ -540,7 +526,6 @@ static const char *zconf_tokenname(int token) case T_IF: return "if"; case T_ENDIF: return "endif"; case T_DEPENDS: return "depends"; - case T_VISIBLE: return "visible"; } return ""; } diff --git a/trunk/sound/core/oss/pcm_oss.c b/trunk/sound/core/oss/pcm_oss.c index b753ec661fcf..5c8c7dff8ede 100644 --- a/trunk/sound/core/oss/pcm_oss.c +++ b/trunk/sound/core/oss/pcm_oss.c @@ -1510,19 +1510,16 @@ static ssize_t snd_pcm_oss_read1(struct snd_pcm_substream *substream, char __use static int snd_pcm_oss_reset(struct snd_pcm_oss_file *pcm_oss_file) { struct snd_pcm_substream *substream; - struct snd_pcm_runtime *runtime; - int i; - for (i = 0; i < 2; i++) { - substream = pcm_oss_file->streams[i]; - if (!substream) - continue; - runtime = substream->runtime; + substream = pcm_oss_file->streams[SNDRV_PCM_STREAM_PLAYBACK]; + if (substream != NULL) { snd_pcm_kernel_ioctl(substream, SNDRV_PCM_IOCTL_DROP, NULL); - runtime->oss.prepare = 1; - runtime->oss.buffer_used = 0; - runtime->oss.prev_hw_ptr_period = 0; - runtime->oss.period_ptr = 0; + substream->runtime->oss.prepare = 1; + } + substream = pcm_oss_file->streams[SNDRV_PCM_STREAM_CAPTURE]; + if (substream != NULL) { + snd_pcm_kernel_ioctl(substream, SNDRV_PCM_IOCTL_DROP, NULL); + substream->runtime->oss.prepare = 1; } return 0; } diff --git a/trunk/sound/pci/hda/patch_realtek.c b/trunk/sound/pci/hda/patch_realtek.c index 8fddc9d08726..886d7c72936e 100644 --- a/trunk/sound/pci/hda/patch_realtek.c +++ b/trunk/sound/pci/hda/patch_realtek.c @@ -9865,6 +9865,7 @@ static struct snd_pci_quirk alc882_cfg_tbl[] = { SND_PCI_QUIRK(0x17aa, 0x3bfc, "Lenovo NB0763", ALC883_LENOVO_NB0763), SND_PCI_QUIRK(0x17aa, 0x3bfd, "Lenovo NB0763", ALC883_LENOVO_NB0763), SND_PCI_QUIRK(0x17aa, 0x101d, "Lenovo Sky", ALC888_LENOVO_SKY), + SND_PCI_QUIRK(0x17c0, 0x4071, "MEDION MD2", ALC883_MEDION_MD2), SND_PCI_QUIRK(0x17c0, 0x4085, "MEDION MD96630", ALC888_LENOVO_MS7195_DIG), SND_PCI_QUIRK(0x17f2, 0x5000, "Albatron KI690-AM2", ALC883_6ST_DIG), SND_PCI_QUIRK(0x1991, 0x5625, "Haier W66", ALC883_HAIER_W66), diff --git a/trunk/sound/pci/hda/patch_sigmatel.c b/trunk/sound/pci/hda/patch_sigmatel.c index efa4225f5fd6..5c710807dfe5 100644 --- a/trunk/sound/pci/hda/patch_sigmatel.c +++ b/trunk/sound/pci/hda/patch_sigmatel.c @@ -1627,8 +1627,6 @@ static struct snd_pci_quirk stac92hd73xx_cfg_tbl[] = { static struct snd_pci_quirk stac92hd73xx_codec_id_cfg_tbl[] = { SND_PCI_QUIRK(PCI_VENDOR_ID_DELL, 0x02a1, "Alienware M17x", STAC_ALIENWARE_M17X), - SND_PCI_QUIRK(PCI_VENDOR_ID_DELL, 0x043a, - "Alienware M17x", STAC_ALIENWARE_M17X), {} /* terminator */ }; diff --git a/trunk/sound/soc/codecs/wm8731.c b/trunk/sound/soc/codecs/wm8731.c index e725c09a3e79..631385802eb4 100644 --- a/trunk/sound/soc/codecs/wm8731.c +++ b/trunk/sound/soc/codecs/wm8731.c @@ -526,7 +526,7 @@ static int wm8731_probe(struct snd_soc_codec *codec) snd_soc_update_bits(codec, WM8731_RINVOL, 0x100, 0); /* Disable bypass path by default */ - snd_soc_update_bits(codec, WM8731_APANA, 0x8, 0); + snd_soc_update_bits(codec, WM8731_APANA, 0x4, 0); snd_soc_add_controls(codec, wm8731_snd_controls, ARRAY_SIZE(wm8731_snd_controls)); diff --git a/trunk/sound/soc/fsl/mpc8610_hpcd.c b/trunk/sound/soc/fsl/mpc8610_hpcd.c index 7d7847a1e66b..0d7dcf1e4863 100644 --- a/trunk/sound/soc/fsl/mpc8610_hpcd.c +++ b/trunk/sound/soc/fsl/mpc8610_hpcd.c @@ -498,7 +498,6 @@ static int mpc8610_hpcd_probe(struct platform_device *pdev) dev_err(&pdev->dev, "platform device add failed\n"); goto error; } - dev_set_drvdata(&pdev->dev, sound_device); of_node_put(codec_np); diff --git a/trunk/sound/soc/fsl/p1022_ds.c b/trunk/sound/soc/fsl/p1022_ds.c index 026b756961e0..63b9eaa1ebc2 100644 --- a/trunk/sound/soc/fsl/p1022_ds.c +++ b/trunk/sound/soc/fsl/p1022_ds.c @@ -498,7 +498,6 @@ static int p1022_ds_probe(struct platform_device *pdev) dev_err(&pdev->dev, "platform device add failed\n"); goto error; } - dev_set_drvdata(&pdev->dev, sound_device); of_node_put(codec_np); diff --git a/trunk/sound/soc/nuc900/nuc900-ac97.c b/trunk/sound/soc/nuc900/nuc900-ac97.c index dac6732da969..e00e39dd6576 100644 --- a/trunk/sound/soc/nuc900/nuc900-ac97.c +++ b/trunk/sound/soc/nuc900/nuc900-ac97.c @@ -49,7 +49,7 @@ static unsigned short nuc900_ac97_read(struct snd_ac97 *ac97, mutex_lock(&ac97_mutex); val = nuc900_checkready(); - if (val) { + if (!!val) { dev_err(nuc900_audio->dev, "AC97 codec is not ready\n"); goto out; } @@ -102,7 +102,7 @@ static void nuc900_ac97_write(struct snd_ac97 *ac97, unsigned short reg, mutex_lock(&ac97_mutex); tmp = nuc900_checkready(); - if (tmp) + if (!!tmp) dev_err(nuc900_audio->dev, "AC97 codec is not ready\n"); /* clear the R_WB bit and write register index */ @@ -149,7 +149,7 @@ static void nuc900_ac97_warm_reset(struct snd_ac97 *ac97) udelay(100); val = nuc900_checkready(); - if (val) + if (!!val) dev_err(nuc900_audio->dev, "AC97 codec is not ready\n"); mutex_unlock(&ac97_mutex); @@ -263,7 +263,8 @@ static int nuc900_ac97_trigger(struct snd_pcm_substream *substream, return ret; } -static int nuc900_ac97_probe(struct snd_soc_dai *dai) +static int nuc900_ac97_probe(struct platform_device *pdev, + struct snd_soc_dai *dai) { struct nuc900_audio *nuc900_audio = nuc900_ac97_data; unsigned long val; @@ -283,12 +284,12 @@ static int nuc900_ac97_probe(struct snd_soc_dai *dai) return 0; } -static int nuc900_ac97_remove(struct snd_soc_dai *dai) +static void nuc900_ac97_remove(struct platform_device *pdev, + struct snd_soc_dai *dai) { struct nuc900_audio *nuc900_audio = nuc900_ac97_data; clk_disable(nuc900_audio->clk); - return 0; } static struct snd_soc_dai_ops nuc900_ac97_dai_ops = { @@ -312,7 +313,7 @@ static struct snd_soc_dai_driver nuc900_ac97_dai = { .channels_max = 2, }, .ops = &nuc900_ac97_dai_ops, -}; +} static int __devinit nuc900_ac97_drvprobe(struct platform_device *pdev) { diff --git a/trunk/sound/soc/nuc900/nuc900-audio.h b/trunk/sound/soc/nuc900/nuc900-audio.h index 59f7e8ed1a68..aeed8ead2b2b 100644 --- a/trunk/sound/soc/nuc900/nuc900-audio.h +++ b/trunk/sound/soc/nuc900/nuc900-audio.h @@ -110,6 +110,4 @@ struct nuc900_audio { }; -extern struct nuc900_audio *nuc900_ac97_data; - #endif /*end _NUC900_AUDIO_H */ diff --git a/trunk/sound/soc/nuc900/nuc900-pcm.c b/trunk/sound/soc/nuc900/nuc900-pcm.c index 8263f56dc665..195d1ac94771 100644 --- a/trunk/sound/soc/nuc900/nuc900-pcm.c +++ b/trunk/sound/soc/nuc900/nuc900-pcm.c @@ -50,12 +50,12 @@ static int nuc900_dma_hw_params(struct snd_pcm_substream *substream, unsigned long flags; int ret = 0; + spin_lock_irqsave(&nuc900_audio->lock, flags); + ret = snd_pcm_lib_malloc_pages(substream, params_buffer_bytes(params)); if (ret < 0) return ret; - spin_lock_irqsave(&nuc900_audio->lock, flags); - nuc900_audio->substream = substream; nuc900_audio->dma_addr[substream->stream] = runtime->dma_addr; nuc900_audio->buffersize[substream->stream] = @@ -169,7 +169,6 @@ static int nuc900_dma_prepare(struct snd_pcm_substream *substream) struct snd_pcm_runtime *runtime = substream->runtime; struct nuc900_audio *nuc900_audio = runtime->private_data; unsigned long flags, val; - int ret = 0; spin_lock_irqsave(&nuc900_audio->lock, flags); @@ -198,10 +197,10 @@ static int nuc900_dma_prepare(struct snd_pcm_substream *substream) AUDIO_WRITE(nuc900_audio->mmio + ACTL_RESET, val); break; default: - ret = -EINVAL; + return -EINVAL; } spin_unlock_irqrestore(&nuc900_audio->lock, flags); - return ret; + return 0; } static int nuc900_dma_trigger(struct snd_pcm_substream *substream, int cmd) @@ -333,7 +332,7 @@ static struct snd_soc_platform_driver nuc900_soc_platform = { .ops = &nuc900_dma_ops, .pcm_new = nuc900_dma_new, .pcm_free = nuc900_dma_free_dma_buffers, -}; +} static int __devinit nuc900_soc_platform_probe(struct platform_device *pdev) { diff --git a/trunk/sound/soc/omap/Kconfig b/trunk/sound/soc/omap/Kconfig index a088db6d5091..d542ea2ff6be 100644 --- a/trunk/sound/soc/omap/Kconfig +++ b/trunk/sound/soc/omap/Kconfig @@ -12,8 +12,8 @@ config SND_OMAP_SOC_MCPDM config SND_OMAP_SOC_N810 tristate "SoC Audio support for Nokia N810" depends on SND_OMAP_SOC && MACH_NOKIA_N810 && I2C - depends on OMAP_MUX select SND_OMAP_SOC_MCBSP + select OMAP_MUX select SND_SOC_TLV320AIC3X help Say Y if you want to add support for SoC audio on Nokia N810. diff --git a/trunk/sound/soc/s6000/s6000-i2s.c b/trunk/sound/soc/s6000/s6000-i2s.c index 3052f64b2403..8778faa174a6 100644 --- a/trunk/sound/soc/s6000/s6000-i2s.c +++ b/trunk/sound/soc/s6000/s6000-i2s.c @@ -434,7 +434,7 @@ static struct snd_soc_dai_driver s6000_i2s_dai = { .rate_max = 1562500, }, .ops = &s6000_i2s_dai_ops, -}; +} static int __devinit s6000_i2s_probe(struct platform_device *pdev) { diff --git a/trunk/sound/soc/s6000/s6000-pcm.c b/trunk/sound/soc/s6000/s6000-pcm.c index ab3ccaec72d2..271fd222bf19 100644 --- a/trunk/sound/soc/s6000/s6000-pcm.c +++ b/trunk/sound/soc/s6000/s6000-pcm.c @@ -473,7 +473,7 @@ static int s6000_pcm_new(struct snd_card *card, } res = request_irq(params->irq, s6000_pcm_irq, IRQF_SHARED, - "s6000-audio", pcm); + s6000_soc_platform.name, pcm); if (res) { printk(KERN_ERR "s6000-pcm couldn't get IRQ\n"); return res; diff --git a/trunk/sound/soc/s6000/s6105-ipcam.c b/trunk/sound/soc/s6000/s6105-ipcam.c index c1244c5bc730..96c05e137538 100644 --- a/trunk/sound/soc/s6000/s6105-ipcam.c +++ b/trunk/sound/soc/s6000/s6105-ipcam.c @@ -167,7 +167,7 @@ static int s6105_aic3x_init(struct snd_soc_pcm_runtime *rtd) snd_soc_dapm_sync(codec); - snd_ctl_add(codec->card->snd_card, snd_ctl_new1(&audio_out_mux, codec)); + snd_ctl_add(codec->snd_card, snd_ctl_new1(&audio_out_mux, codec)); return 0; } diff --git a/trunk/usr/initramfs_data.S b/trunk/usr/initramfs_data.S index c14322d1c0cf..792a750d9441 100644 --- a/trunk/usr/initramfs_data.S +++ b/trunk/usr/initramfs_data.S @@ -22,15 +22,14 @@ */ #include -#include .section .init.ramfs,"a" __irf_start: .incbin __stringify(INITRAMFS_IMAGE) __irf_end: .section .init.ramfs.info,"a" -.globl VMLINUX_SYMBOL(__initramfs_size) -VMLINUX_SYMBOL(__initramfs_size): +.globl __initramfs_size +__initramfs_size: #ifdef CONFIG_64BIT .quad __irf_end - __irf_start #else