From 03f87143d66ecd1ff6cdf18421c5b39d17731dd2 Mon Sep 17 00:00:00 2001 From: Dave Jones Date: Tue, 31 Jan 2006 15:53:55 -0800 Subject: [PATCH] --- yaml --- r: 20260 b: refs/heads/master c: e4472cb3706ceea42797ae1dc79d624026986694 h: refs/heads/master v: v3 --- [refs] | 2 +- trunk/CREDITS | 2 +- trunk/Documentation/RCU/RTFP.txt | 25 +- trunk/Documentation/RCU/checklist.txt | 6 - trunk/Documentation/RCU/listRCU.txt | 21 +- trunk/Documentation/RCU/rcu.txt | 5 - trunk/Documentation/RCU/rcuref.txt | 31 +- trunk/Documentation/RCU/whatisRCU.txt | 29 +- trunk/Documentation/cputopology.txt | 41 - trunk/Documentation/driver-model/overview.txt | 57 +- trunk/Documentation/drivers/edac/edac.txt | 673 ----- .../feature-removal-schedule.txt | 23 - .../filesystems/configfs/configfs_example.c | 2 - trunk/Documentation/filesystems/ocfs2.txt | 1 - trunk/Documentation/hwmon/f71805f | 105 - trunk/Documentation/hwmon/it87 | 2 +- trunk/Documentation/hwmon/sysfs-interface | 18 +- .../i2c/busses/{i2c-sis96x => i2c-sis69x} | 4 +- trunk/Documentation/kernel-doc-nano-HOWTO.txt | 39 +- trunk/Documentation/kernel-parameters.txt | 5 - trunk/Documentation/networking/ip-sysctl.txt | 17 - trunk/Documentation/parport-lowlevel.txt | 8 +- trunk/Documentation/pci-error-recovery.txt | 472 +-- trunk/Documentation/power/interface.txt | 2 +- trunk/Documentation/power/swsusp.txt | 2 +- .../powerpc/booting-without-of.txt | 1486 ---------- .../Documentation/scsi/ChangeLog.megaraid_sas | 24 - trunk/Documentation/scsi/aic79xx.txt | 93 +- trunk/Documentation/scsi/aic7xxx.txt | 86 +- .../sound/alsa/ALSA-Configuration.txt | 10 +- .../alsa/DocBook/writing-an-alsa-driver.tmpl | 4 +- trunk/Documentation/spi/butterfly | 23 +- trunk/Documentation/sysctl/vm.txt | 58 - trunk/Documentation/unshare.txt | 295 -- trunk/Documentation/usb/et61x251.txt | 306 -- trunk/Documentation/usb/sn9c102.txt | 95 +- trunk/Documentation/usb/w9968cf.txt | 30 +- trunk/Documentation/video4linux/CARDLIST.cx88 | 2 +- .../video4linux/CARDLIST.saa7134 | 6 +- trunk/Documentation/vm/page_migration | 129 - trunk/Documentation/x86_64/boot-options.txt | 12 - trunk/MAINTAINERS | 81 +- trunk/Makefile | 4 +- trunk/arch/alpha/kernel/asm-offsets.c | 1 - trunk/arch/alpha/kernel/entry.S | 16 +- trunk/arch/alpha/kernel/irq.c | 36 +- trunk/arch/alpha/kernel/osf_sys.c | 2 +- trunk/arch/alpha/kernel/smp.c | 25 +- trunk/arch/arm/Kconfig | 49 +- trunk/arch/arm/boot/compressed/head.S | 2 +- trunk/arch/arm/configs/at91rm9200dk_defconfig | 1 + trunk/arch/arm/configs/at91rm9200ek_defconfig | 1 + trunk/arch/arm/configs/bast_defconfig | 5 +- trunk/arch/arm/configs/collie_defconfig | 7 +- trunk/arch/arm/configs/csb337_defconfig | 1 + trunk/arch/arm/configs/csb637_defconfig | 1 + trunk/arch/arm/configs/enp2611_defconfig | 2 +- trunk/arch/arm/configs/ep80219_defconfig | 1 - trunk/arch/arm/configs/iq31244_defconfig | 1 - trunk/arch/arm/configs/iq80321_defconfig | 1 - trunk/arch/arm/configs/iq80331_defconfig | 1 - trunk/arch/arm/configs/iq80332_defconfig | 1 - trunk/arch/arm/configs/ixdp2400_defconfig | 2 +- trunk/arch/arm/configs/ixdp2401_defconfig | 2 +- trunk/arch/arm/configs/ixdp2801_defconfig | 2 +- trunk/arch/arm/configs/s3c2410_defconfig | 56 +- trunk/arch/arm/kernel/calls.S | 661 ++--- trunk/arch/arm/kernel/entry-armv.S | 22 +- trunk/arch/arm/kernel/entry-common.S | 4 - trunk/arch/arm/kernel/signal.c | 29 +- trunk/arch/arm/kernel/signal.h | 2 +- trunk/arch/arm/kernel/sys_oabi-compat.c | 71 - trunk/arch/arm/mach-clps711x/Kconfig | 2 - trunk/arch/arm/mach-imx/mx1ads.c | 1 + .../arch/arm/mach-integrator/integrator_cp.c | 4 +- trunk/arch/arm/mach-ixp2000/enp2611.c | 1 - trunk/arch/arm/mach-ixp2000/ixdp2400.c | 1 - trunk/arch/arm/mach-ixp2000/ixdp2x01.c | 5 +- trunk/arch/arm/mach-ixp4xx/common.c | 3 +- trunk/arch/arm/mach-omap1/board-generic.c | 3 +- trunk/arch/arm/mach-omap1/board-h2.c | 3 +- trunk/arch/arm/mach-omap1/board-h3.c | 3 +- trunk/arch/arm/mach-omap1/board-innovator.c | 3 +- trunk/arch/arm/mach-omap1/board-netstar.c | 3 +- trunk/arch/arm/mach-omap1/board-osk.c | 3 +- trunk/arch/arm/mach-omap1/board-palmte.c | 3 +- trunk/arch/arm/mach-omap1/board-perseus2.c | 3 +- trunk/arch/arm/mach-omap1/board-voiceblue.c | 3 +- trunk/arch/arm/mach-omap1/clock.c | 44 +- trunk/arch/arm/mach-omap1/clock.h | 168 +- trunk/arch/arm/mach-omap1/io.c | 42 +- trunk/arch/arm/mach-omap1/serial.c | 6 +- trunk/arch/arm/mach-omap2/board-generic.c | 3 +- trunk/arch/arm/mach-omap2/board-h4.c | 3 +- trunk/arch/arm/mach-omap2/clock.c | 32 +- trunk/arch/arm/mach-omap2/clock.h | 12 +- trunk/arch/arm/mach-omap2/serial.c | 12 +- trunk/arch/arm/mach-omap2/timer-gp.c | 2 +- trunk/arch/arm/mach-pxa/pxa27x.c | 2 +- trunk/arch/arm/mach-realview/core.c | 2 +- trunk/arch/arm/mach-s3c2410/Makefile | 5 - trunk/arch/arm/mach-s3c2410/clock.c | 43 +- trunk/arch/arm/mach-s3c2410/clock.h | 1 - trunk/arch/arm/mach-s3c2410/cpu.c | 18 +- trunk/arch/arm/mach-s3c2410/cpu.h | 3 +- trunk/arch/arm/mach-s3c2410/devs.c | 62 +- trunk/arch/arm/mach-s3c2410/dma.c | 2 +- trunk/arch/arm/mach-s3c2410/gpio.c | 72 +- trunk/arch/arm/mach-s3c2410/mach-h1940.c | 29 +- trunk/arch/arm/mach-s3c2410/s3c2400-gpio.c | 45 - trunk/arch/arm/mach-s3c2410/s3c2400.h | 31 - trunk/arch/arm/mach-s3c2410/s3c2410-gpio.c | 93 - trunk/arch/arm/mach-s3c2410/sleep.S | 8 +- trunk/arch/arm/mm/cache-v6.S | 18 +- trunk/arch/arm/mm/ioremap.c | 2 +- trunk/arch/arm/mm/mm-armv.c | 6 - trunk/arch/arm/mm/proc-xscale.S | 16 +- trunk/arch/arm/oprofile/common.c | 5 +- trunk/arch/arm/plat-omap/clock.c | 41 +- trunk/arch/arm/plat-omap/gpio.c | 6 +- trunk/arch/arm/plat-omap/mcbsp.c | 12 +- trunk/arch/arm/plat-omap/ocpi.c | 4 +- trunk/arch/arm/plat-omap/sram.c | 9 - trunk/arch/arm26/Kconfig | 6 +- trunk/arch/arm26/kernel/fiq.c | 32 +- trunk/arch/arm26/kernel/signal.c | 3 +- trunk/arch/cris/Makefile | 2 +- trunk/arch/cris/arch-v10/kernel/ptrace.c | 8 +- trunk/arch/cris/kernel/setup.c | 1 + trunk/arch/frv/kernel/signal.c | 120 +- trunk/arch/i386/Kconfig | 56 +- trunk/arch/i386/defconfig | 2 - trunk/arch/i386/kernel/acpi/Makefile | 2 +- trunk/arch/i386/kernel/acpi/boot.c | 19 +- trunk/arch/i386/kernel/acpi/cstate.c | 58 + trunk/arch/i386/kernel/acpi/processor.c | 75 - trunk/arch/i386/kernel/apic.c | 5 +- trunk/arch/i386/kernel/cpu/amd.c | 8 - trunk/arch/i386/kernel/cpu/centaur.c | 12 +- trunk/arch/i386/kernel/cpu/common.c | 11 +- .../i386/kernel/cpu/cpufreq/acpi-cpufreq.c | 71 + .../kernel/cpu/cpufreq/speedstep-centrino.c | 12 + trunk/arch/i386/kernel/cpu/cyrix.c | 18 +- trunk/arch/i386/kernel/cpu/intel_cacheinfo.c | 12 - trunk/arch/i386/kernel/cpu/mtrr/main.c | 15 +- trunk/arch/i386/kernel/cpu/nexgen.c | 8 - trunk/arch/i386/kernel/cpu/rise.c | 8 - trunk/arch/i386/kernel/cpu/transmeta.c | 10 +- trunk/arch/i386/kernel/cpu/umc.c | 8 - trunk/arch/i386/kernel/head.S | 4 - trunk/arch/i386/kernel/mpparse.c | 8 +- trunk/arch/i386/kernel/nmi.c | 2 +- trunk/arch/i386/kernel/process.c | 6 +- trunk/arch/i386/kernel/quirks.c | 9 +- trunk/arch/i386/kernel/signal.c | 109 +- trunk/arch/i386/kernel/smpboot.c | 4 + trunk/arch/i386/kernel/syscall_table.S | 16 - trunk/arch/i386/kernel/timers/timer_tsc.c | 14 +- trunk/arch/i386/kernel/traps.c | 9 +- trunk/arch/i386/mach-voyager/voyager_smp.c | 2 +- trunk/arch/i386/oprofile/backtrace.c | 19 +- trunk/arch/i386/pci/irq.c | 5 - trunk/arch/i386/pci/mmconfig.c | 15 +- trunk/arch/ia64/Kconfig | 4 +- trunk/arch/ia64/configs/gensparse_defconfig | 1 - trunk/arch/ia64/configs/tiger_defconfig | 1 - trunk/arch/ia64/configs/zx1_defconfig | 1 - trunk/arch/ia64/defconfig | 1 - trunk/arch/ia64/dig/setup.c | 10 + trunk/arch/ia64/ia32/ia32_signal.c | 1 - trunk/arch/ia64/ia32/sys_ia32.c | 28 +- trunk/arch/ia64/kernel/Makefile | 5 - trunk/arch/ia64/kernel/acpi-ext.c | 22 +- trunk/arch/ia64/kernel/acpi-processor.c | 67 - trunk/arch/ia64/kernel/acpi.c | 6 +- trunk/arch/ia64/kernel/cpufreq/Makefile | 1 - trunk/arch/ia64/kernel/cpufreq/acpi-cpufreq.c | 51 + trunk/arch/ia64/kernel/efi.c | 16 +- trunk/arch/ia64/kernel/entry.S | 16 - trunk/arch/ia64/kernel/fsys.S | 29 +- trunk/arch/ia64/kernel/head.S | 1 - trunk/arch/ia64/kernel/mca_asm.S | 2 +- trunk/arch/ia64/kernel/mca_drv.c | 3 - trunk/arch/ia64/kernel/perfmon.c | 11 +- trunk/arch/ia64/kernel/sal.c | 75 - trunk/arch/ia64/kernel/setup.c | 4 - trunk/arch/ia64/kernel/time.c | 27 - trunk/arch/ia64/kernel/topology.c | 18 +- trunk/arch/ia64/kernel/unaligned.c | 3 +- trunk/arch/ia64/kernel/uncached.c | 1 - trunk/arch/ia64/pci/pci.c | 10 +- trunk/arch/ia64/sn/Makefile | 2 + trunk/arch/ia64/sn/include/xtalk/hubdev.h | 9 - trunk/arch/ia64/sn/kernel/Makefile | 2 - trunk/arch/ia64/sn/kernel/bte.c | 17 +- trunk/arch/ia64/sn/kernel/io_init.c | 77 +- trunk/arch/ia64/sn/kernel/irq.c | 25 +- trunk/arch/ia64/sn/kernel/klconflib.c | 29 +- trunk/arch/ia64/sn/kernel/mca.c | 12 +- trunk/arch/ia64/sn/kernel/setup.c | 73 +- trunk/arch/ia64/sn/kernel/sn2/Makefile | 2 - trunk/arch/ia64/sn/kernel/sn2/sn2_smp.c | 196 +- trunk/arch/ia64/sn/kernel/sn2/sn_hwperf.c | 5 +- trunk/arch/ia64/sn/kernel/xp_main.c | 17 +- trunk/arch/ia64/sn/kernel/xpc_channel.c | 40 +- trunk/arch/ia64/sn/kernel/xpc_main.c | 36 +- trunk/arch/ia64/sn/pci/Makefile | 2 - trunk/arch/ia64/sn/pci/pci_dma.c | 4 +- trunk/arch/ia64/sn/pci/pcibr/Makefile | 2 - trunk/arch/ia64/sn/pci/pcibr/pcibr_provider.c | 12 +- trunk/arch/m32r/kernel/m32r_ksyms.c | 5 + trunk/arch/m32r/kernel/setup.c | 6 + trunk/arch/m68k/fpsp040/bindec.S | 5 +- trunk/arch/m68k/fpsp040/binstr.S | 5 +- trunk/arch/m68k/fpsp040/bugfix.S | 5 +- trunk/arch/m68k/fpsp040/decbin.S | 5 +- trunk/arch/m68k/fpsp040/do_func.S | 5 +- trunk/arch/m68k/fpsp040/fpsp.h | 5 +- trunk/arch/m68k/fpsp040/gen_except.S | 5 +- trunk/arch/m68k/fpsp040/get_op.S | 5 +- trunk/arch/m68k/fpsp040/kernel_ex.S | 5 +- trunk/arch/m68k/fpsp040/res_func.S | 5 +- trunk/arch/m68k/fpsp040/round.S | 5 +- trunk/arch/m68k/fpsp040/sacos.S | 5 +- trunk/arch/m68k/fpsp040/sasin.S | 5 +- trunk/arch/m68k/fpsp040/satan.S | 5 +- trunk/arch/m68k/fpsp040/satanh.S | 5 +- trunk/arch/m68k/fpsp040/scale.S | 5 +- trunk/arch/m68k/fpsp040/scosh.S | 5 +- trunk/arch/m68k/fpsp040/setox.S | 5 +- trunk/arch/m68k/fpsp040/sgetem.S | 5 +- trunk/arch/m68k/fpsp040/sint.S | 5 +- trunk/arch/m68k/fpsp040/skeleton.S | 5 +- trunk/arch/m68k/fpsp040/slog2.S | 5 +- trunk/arch/m68k/fpsp040/slogn.S | 5 +- trunk/arch/m68k/fpsp040/smovecr.S | 5 +- trunk/arch/m68k/fpsp040/srem_mod.S | 5 +- trunk/arch/m68k/fpsp040/ssin.S | 5 +- trunk/arch/m68k/fpsp040/ssinh.S | 5 +- trunk/arch/m68k/fpsp040/stan.S | 5 +- trunk/arch/m68k/fpsp040/stanh.S | 5 +- trunk/arch/m68k/fpsp040/sto_res.S | 5 +- trunk/arch/m68k/fpsp040/stwotox.S | 5 +- trunk/arch/m68k/fpsp040/tbldo.S | 5 +- trunk/arch/m68k/fpsp040/util.S | 5 +- trunk/arch/m68k/fpsp040/x_bsun.S | 5 +- trunk/arch/m68k/fpsp040/x_fline.S | 5 +- trunk/arch/m68k/fpsp040/x_operr.S | 5 +- trunk/arch/m68k/fpsp040/x_ovfl.S | 5 +- trunk/arch/m68k/fpsp040/x_snan.S | 5 +- trunk/arch/m68k/fpsp040/x_store.S | 5 +- trunk/arch/m68k/fpsp040/x_unfl.S | 5 +- trunk/arch/m68k/fpsp040/x_unimp.S | 5 +- trunk/arch/m68k/fpsp040/x_unsupp.S | 5 +- trunk/arch/m68knommu/kernel/process.c | 8 - trunk/arch/mips/Kconfig | 1 - trunk/arch/mips/Makefile | 25 +- trunk/arch/mips/au1000/common/reset.c | 2 +- trunk/arch/mips/au1000/common/setup.c | 3 +- trunk/arch/mips/cobalt/int-handler.S | 2 +- trunk/arch/mips/cobalt/irq.c | 2 +- trunk/arch/mips/cobalt/reset.c | 2 +- trunk/arch/mips/cobalt/setup.c | 9 +- trunk/arch/mips/configs/ip32_defconfig | 1 - trunk/arch/mips/configs/qemu_defconfig | 78 +- trunk/arch/mips/ddb5xxx/ddb5074/setup.c | 3 +- trunk/arch/mips/ddb5xxx/ddb5476/setup.c | 3 +- trunk/arch/mips/ddb5xxx/ddb5477/setup.c | 3 +- trunk/arch/mips/dec/setup.c | 3 +- trunk/arch/mips/gt64120/ev64120/setup.c | 4 +- .../arch/mips/gt64120/momenco_ocelot/setup.c | 6 +- .../mips/ite-boards/generic/it8172_setup.c | 3 +- trunk/arch/mips/jazz/setup.c | 4 +- trunk/arch/mips/jmr3927/rbhma3100/setup.c | 3 +- trunk/arch/mips/kernel/cpu-probe.c | 7 +- trunk/arch/mips/kernel/gdb-stub.c | 2 +- trunk/arch/mips/kernel/genex.S | 2 +- trunk/arch/mips/kernel/process.c | 5 +- trunk/arch/mips/kernel/ptrace32.c | 22 +- trunk/arch/mips/kernel/reset.c | 18 +- trunk/arch/mips/kernel/rtlx.c | 4 - trunk/arch/mips/kernel/scall32-o32.S | 17 - trunk/arch/mips/kernel/scall64-64.S | 17 - trunk/arch/mips/kernel/scall64-n32.S | 17 - trunk/arch/mips/kernel/scall64-o32.S | 17 - trunk/arch/mips/kernel/signal-common.h | 8 +- trunk/arch/mips/kernel/signal.c | 104 +- trunk/arch/mips/kernel/signal32.c | 67 +- trunk/arch/mips/kernel/signal_n32.c | 14 +- trunk/arch/mips/kernel/syscall.c | 48 +- trunk/arch/mips/kernel/traps.c | 2 +- trunk/arch/mips/kernel/vmlinux.lds.S | 11 +- trunk/arch/mips/lasat/reset.c | 5 +- trunk/arch/mips/lasat/setup.c | 4 +- trunk/arch/mips/lib-32/dump_tlb.c | 33 +- trunk/arch/mips/math-emu/dp_simple.c | 14 +- trunk/arch/mips/math-emu/sp_simple.c | 14 +- .../arch/mips/mips-boards/atlas/atlas_setup.c | 4 +- trunk/arch/mips/mips-boards/generic/reset.c | 5 +- trunk/arch/mips/mips-boards/sead/sead_setup.c | 4 +- trunk/arch/mips/mips-boards/sim/sim_setup.c | 4 +- trunk/arch/mips/mm/c-r4k.c | 7 +- trunk/arch/mips/mm/cache.c | 5 +- trunk/arch/mips/mm/init.c | 16 - .../mips/momentum/jaguar_atx/ja-console.c | 2 +- trunk/arch/mips/momentum/jaguar_atx/setup.c | 3 +- trunk/arch/mips/momentum/ocelot_3/setup.c | 4 +- trunk/arch/mips/momentum/ocelot_c/setup.c | 4 +- trunk/arch/mips/momentum/ocelot_g/setup.c | 4 +- trunk/arch/mips/oprofile/Makefile | 1 - trunk/arch/mips/oprofile/common.c | 3 - trunk/arch/mips/oprofile/op_model_mipsxx.c | 11 - trunk/arch/mips/pci/Makefile | 1 - trunk/arch/mips/pci/fixup-cobalt.c | 6 +- trunk/arch/mips/pci/ops-gt64111.c | 2 +- trunk/arch/mips/pci/pci-bcm1480.c | 2 + .../mips/philips/pnx8550/common/platform.c | 8 +- .../arch/mips/philips/pnx8550/common/setup.c | 3 +- trunk/arch/mips/pmc-sierra/yosemite/prom.c | 3 +- trunk/arch/mips/pmc-sierra/yosemite/setup.c | 2 +- trunk/arch/mips/sgi-ip22/ip22-reset.c | 55 +- trunk/arch/mips/sgi-ip22/ip22-setup.c | 10 +- trunk/arch/mips/sgi-ip27/ip27-reset.c | 5 +- trunk/arch/mips/sgi-ip32/ip32-reset.c | 3 +- trunk/arch/mips/sgi-ip32/ip32-setup.c | 13 +- trunk/arch/mips/sibyte/cfe/setup.c | 3 +- trunk/arch/mips/sibyte/sb1250/prom.c | 3 +- trunk/arch/mips/sibyte/sb1250/setup.c | 36 +- trunk/arch/mips/sni/setup.c | 5 +- .../toshiba_rbtx4927/toshiba_rbtx4927_prom.c | 10 +- .../toshiba_rbtx4927/toshiba_rbtx4927_setup.c | 140 +- .../arch/mips/tx4938/toshiba_rbtx4938/setup.c | 4 +- trunk/arch/mips/vr41xx/common/pmu.c | 3 +- trunk/arch/parisc/Kconfig | 20 +- trunk/arch/parisc/Kconfig.debug | 10 - trunk/arch/parisc/configs/a500_defconfig | 1 - trunk/arch/parisc/configs/b180_defconfig | 182 +- trunk/arch/parisc/configs/c3000_defconfig | 1 - trunk/arch/parisc/hpux/entry_hpux.S | 3 +- trunk/arch/parisc/hpux/sys_hpux.c | 10 +- trunk/arch/parisc/kernel/drivers.c | 3 +- trunk/arch/parisc/kernel/parisc_ksyms.c | 3 + trunk/arch/parisc/kernel/pci.c | 13 +- trunk/arch/parisc/kernel/perf.c | 38 +- trunk/arch/parisc/kernel/perf_images.h | 4 +- trunk/arch/parisc/kernel/process.c | 35 +- trunk/arch/parisc/kernel/ptrace.c | 8 +- trunk/arch/parisc/kernel/signal.c | 2 +- trunk/arch/parisc/kernel/signal32.c | 102 +- trunk/arch/parisc/kernel/signal32.h | 127 +- trunk/arch/parisc/kernel/syscall.S | 2 - trunk/arch/parisc/kernel/syscall_table.S | 19 - trunk/arch/parisc/kernel/traps.c | 3 +- trunk/arch/parisc/math-emu/decode_exc.c | 1 - trunk/arch/parisc/mm/init.c | 35 +- trunk/arch/powerpc/Kconfig | 6 - trunk/arch/powerpc/Makefile | 3 - trunk/arch/powerpc/configs/cell_defconfig | 1 - trunk/arch/powerpc/configs/g5_defconfig | 1 - trunk/arch/powerpc/configs/iseries_defconfig | 1 - trunk/arch/powerpc/configs/maple_defconfig | 1 - trunk/arch/powerpc/configs/ppc64_defconfig | 1 - trunk/arch/powerpc/configs/pseries_defconfig | 1 - trunk/arch/powerpc/kernel/Makefile | 6 +- trunk/arch/powerpc/kernel/entry_32.S | 8 +- trunk/arch/powerpc/kernel/entry_64.S | 2 +- trunk/arch/powerpc/kernel/fpu.S | 2 +- trunk/arch/powerpc/kernel/head_64.S | 5 +- trunk/arch/powerpc/kernel/iommu.c | 9 +- trunk/arch/powerpc/kernel/legacy_serial.c | 4 + trunk/arch/powerpc/kernel/prom.c | 38 +- trunk/arch/powerpc/kernel/prom_init.c | 4 - trunk/arch/powerpc/kernel/prom_parse.c | 4 +- trunk/arch/powerpc/kernel/rtas.c | 12 +- trunk/arch/powerpc/kernel/rtas_flash.c | 3 +- trunk/arch/powerpc/kernel/setup_64.c | 3 - trunk/arch/powerpc/kernel/signal_32.c | 98 +- trunk/arch/powerpc/kernel/signal_64.c | 60 +- trunk/arch/powerpc/kernel/smp.c | 3 - trunk/arch/powerpc/kernel/systbl.S | 5 +- trunk/arch/powerpc/kernel/time.c | 8 +- trunk/arch/powerpc/kernel/udbg_16550.c | 2 +- trunk/arch/powerpc/mm/lmb.c | 4 - trunk/arch/powerpc/mm/mem.c | 14 +- trunk/arch/powerpc/platforms/cell/Makefile | 2 +- trunk/arch/powerpc/platforms/chrp/chrp.h | 1 + trunk/arch/powerpc/platforms/chrp/pci.c | 2 - trunk/arch/powerpc/platforms/chrp/setup.c | 2 +- trunk/arch/powerpc/platforms/chrp/time.c | 21 + .../arch/powerpc/platforms/powermac/low_i2c.c | 3 +- trunk/arch/powerpc/platforms/powermac/pci.c | 89 +- .../powerpc/platforms/powermac/pfunc_core.c | 13 +- trunk/arch/powerpc/platforms/powermac/setup.c | 2 + .../powerpc/platforms/pseries/eeh_driver.c | 8 +- .../powerpc/platforms/pseries/pci_dlpar.c | 3 - trunk/arch/powerpc/platforms/pseries/setup.c | 2 +- trunk/arch/powerpc/sysdev/dart_iommu.c | 2 +- trunk/arch/ppc/configs/bamboo_defconfig | 1 - trunk/arch/ppc/configs/katana_defconfig | 1 - trunk/arch/ppc/configs/mpc834x_sys_defconfig | 1 - trunk/arch/ppc/configs/power3_defconfig | 1 - trunk/arch/ppc/kernel/head_8xx.S | 7 +- trunk/arch/ppc/kernel/misc.S | 283 ++ trunk/arch/ppc/kernel/ppc_ksyms.c | 4 - trunk/arch/ppc/platforms/4xx/bamboo.c | 4 +- trunk/arch/ppc/platforms/4xx/bubinga.c | 4 +- trunk/arch/ppc/platforms/4xx/ebony.c | 4 +- trunk/arch/ppc/platforms/4xx/luan.c | 4 +- trunk/arch/ppc/platforms/4xx/ocotea.c | 4 +- trunk/arch/ppc/platforms/4xx/xilinx_ml300.c | 4 +- trunk/arch/ppc/platforms/4xx/yucca.c | 4 +- trunk/arch/ppc/platforms/83xx/mpc834x_sys.c | 4 +- trunk/arch/ppc/platforms/85xx/mpc8540_ads.c | 4 +- .../ppc/platforms/85xx/mpc85xx_cds_common.c | 4 +- trunk/arch/ppc/platforms/85xx/sbc8560.c | 2 +- trunk/arch/ppc/platforms/85xx/tqm85xx.c | 4 +- trunk/arch/ppc/platforms/chestnut.c | 2 +- trunk/arch/ppc/platforms/ev64260.c | 2 +- trunk/arch/ppc/platforms/radstone_ppc7d.c | 2 +- trunk/arch/ppc/platforms/spruce.c | 4 +- trunk/arch/ppc/syslib/mv64x60.c | 4 +- trunk/arch/ppc/syslib/ocp.c | 4 +- trunk/arch/ppc/syslib/ppc83xx_setup.c | 2 +- trunk/arch/ppc/syslib/ppc85xx_setup.c | 2 +- trunk/arch/s390/defconfig | 41 +- trunk/arch/s390/kernel/compat_linux.c | 103 +- trunk/arch/s390/kernel/compat_signal.c | 105 +- trunk/arch/s390/kernel/compat_wrapper.S | 142 +- trunk/arch/s390/kernel/entry.S | 51 +- trunk/arch/s390/kernel/entry64.S | 75 +- trunk/arch/s390/kernel/machine_kexec.c | 5 +- trunk/arch/s390/kernel/signal.c | 146 +- trunk/arch/s390/kernel/smp.c | 6 +- trunk/arch/s390/kernel/sys_s390.c | 4 +- trunk/arch/s390/kernel/syscalls.S | 23 +- trunk/arch/s390/kernel/time.c | 11 +- trunk/arch/s390/kernel/traps.c | 2 +- trunk/arch/s390/lib/Makefile | 2 +- trunk/arch/s390/mm/cmm.c | 10 +- trunk/arch/sh/Kconfig | 6 + trunk/arch/sh/boards/renesas/rts7751r2d/io.c | 30 +- trunk/arch/sh/boards/superh/microdev/io.c | 192 +- trunk/arch/sh/boards/superh/microdev/irq.c | 2 +- trunk/arch/sh/boards/superh/microdev/setup.c | 166 +- trunk/arch/sh/boards/unknown/Makefile | 2 +- trunk/arch/sh/boards/unknown/io.c | 46 + trunk/arch/sh/boards/unknown/mach.c | 67 + trunk/arch/sh/boards/unknown/setup.c | 12 +- trunk/arch/sh/cchips/voyagergx/consistent.c | 15 +- trunk/arch/sh/cchips/voyagergx/irq.c | 7 +- trunk/arch/sh/configs/microdev_defconfig | 410 +-- trunk/arch/sh/kernel/Makefile | 2 +- trunk/arch/sh/kernel/cpu/Makefile | 2 +- trunk/arch/sh/kernel/cpu/bus.c | 197 ++ trunk/arch/sh/kernel/cpu/clock.c | 13 +- trunk/arch/sh/kernel/cpu/irq/ipr.c | 59 +- trunk/arch/sh/kernel/entry.S | 18 +- trunk/arch/sh/kernel/process.c | 54 +- trunk/arch/sh/kernel/setup.c | 51 +- trunk/arch/sh64/kernel/sh_ksyms.c | 8 + trunk/arch/sh64/kernel/time.c | 1 - trunk/arch/sparc/kernel/entry.S | 58 +- trunk/arch/sparc/kernel/process.c | 2 +- trunk/arch/sparc/kernel/rtrap.S | 9 +- trunk/arch/sparc/kernel/signal.c | 117 +- trunk/arch/sparc/kernel/sparc_ksyms.c | 2 + trunk/arch/sparc/kernel/systbls.S | 11 +- trunk/arch/sparc/math-emu/math.c | 10 + trunk/arch/sparc64/boot/.gitignore | 4 - trunk/arch/sparc64/defconfig | 33 +- trunk/arch/sparc64/kernel/entry.S | 25 +- trunk/arch/sparc64/kernel/process.c | 4 - trunk/arch/sparc64/kernel/rtrap.S | 33 +- trunk/arch/sparc64/kernel/setup.c | 2 - trunk/arch/sparc64/kernel/signal.c | 151 +- trunk/arch/sparc64/kernel/signal32.c | 122 +- trunk/arch/sparc64/kernel/sparc64_ksyms.c | 4 +- trunk/arch/sparc64/kernel/sys32.S | 1 + trunk/arch/sparc64/kernel/sys_sparc32.c | 25 +- trunk/arch/sparc64/kernel/systbls.S | 22 +- trunk/arch/sparc64/prom/console.c | 8 - trunk/arch/sparc64/solaris/entry64.S | 2 - trunk/arch/sparc64/solaris/systbl.S | 29 + trunk/arch/um/Kconfig | 27 +- trunk/arch/um/Kconfig.i386 | 6 +- trunk/arch/um/Makefile | 25 +- trunk/arch/um/drivers/chan_kern.c | 6 +- trunk/arch/um/drivers/chan_user.c | 15 +- trunk/arch/um/drivers/daemon_kern.c | 8 +- trunk/arch/um/drivers/daemon_user.c | 6 - trunk/arch/um/drivers/fd.c | 1 - trunk/arch/um/drivers/line.c | 2 +- trunk/arch/um/drivers/mcast_kern.c | 4 +- trunk/arch/um/drivers/mconsole_kern.c | 11 +- trunk/arch/um/drivers/net_kern.c | 50 +- trunk/arch/um/drivers/slip_common.h | 13 +- trunk/arch/um/drivers/slip_kern.c | 15 +- trunk/arch/um/drivers/slirp_kern.c | 13 +- trunk/arch/um/drivers/ssl.c | 6 +- trunk/arch/um/drivers/ubd_kern.c | 59 +- trunk/arch/um/include/kern_util.h | 6 +- trunk/arch/um/include/longjmp.h | 19 - trunk/arch/um/include/mode_kern.h | 15 +- trunk/arch/um/include/os.h | 58 +- trunk/arch/um/include/registers.h | 2 +- trunk/arch/um/include/skas/mmu-skas.h | 24 - trunk/arch/um/include/skas/mode-skas.h | 19 - trunk/arch/um/include/skas/skas.h | 26 - trunk/arch/um/include/time_user.h | 19 + trunk/arch/um/include/tt/mmu-tt.h | 12 - trunk/arch/um/include/tt/mode-tt.h | 23 - trunk/arch/um/include/tt/mode_kern_tt.h | 41 - trunk/arch/um/include/user.h | 1 - trunk/arch/um/include/user_util.h | 18 + trunk/arch/um/kernel/Makefile | 7 +- trunk/arch/um/kernel/exec_kern.c | 3 +- trunk/arch/um/kernel/physmem.c | 2 +- trunk/arch/um/kernel/process_kern.c | 22 +- trunk/arch/um/kernel/reboot.c | 1 - trunk/arch/um/kernel/sigio_user.c | 83 +- trunk/arch/um/kernel/signal_kern.c | 91 +- trunk/arch/um/kernel/skas/Makefile | 6 +- .../skas => kernel/skas/include}/mm_id.h | 0 trunk/arch/um/kernel/skas/include/mmu-skas.h | 35 + trunk/arch/um/kernel/skas/include/mode-skas.h | 33 + .../skas/include/mode_kern-skas.h} | 12 + .../skas => kernel/skas/include}/proc_mm.h | 17 +- trunk/arch/um/kernel/skas/include/skas.h | 49 + .../skas => kernel/skas/include}/stub-data.h | 0 .../skas/include}/uaccess-skas.h | 11 + .../skas/mem.c => kernel/skas/mem_user.c} | 202 +- trunk/arch/um/kernel/skas/mmu.c | 8 +- .../um/{os-Linux => kernel}/skas/process.c | 247 +- trunk/arch/um/kernel/skas/process_kern.c | 35 +- trunk/arch/um/kernel/skas/uaccess.c | 2 +- trunk/arch/um/kernel/syscall.c | 4 +- trunk/arch/um/kernel/time_kern.c | 132 +- trunk/arch/um/kernel/tt/exec_kern.c | 1 + trunk/arch/um/kernel/tt/gdb.c | 1 - .../{include/tt => kernel/tt/include}/debug.h | 2 +- trunk/arch/um/kernel/tt/include/mmu-tt.h | 23 + .../um/{include/tt => kernel/tt/include}/tt.h | 12 +- .../tt => kernel/tt/include}/uaccess-tt.h | 11 + trunk/arch/um/kernel/tt/process_kern.c | 1 + trunk/arch/um/kernel/tt/ptproxy/ptrace.c | 1 - trunk/arch/um/kernel/tt/ptproxy/sysdep.c | 1 - trunk/arch/um/kernel/tt/syscall_kern.c | 8 +- trunk/arch/um/kernel/tt/trap_user.c | 5 +- trunk/arch/um/kernel/um_arch.c | 18 - .../{os-Linux/util.c => kernel/user_util.c} | 69 +- trunk/arch/um/os-Linux/Makefile | 4 +- trunk/arch/um/os-Linux/drivers/tuntap_user.c | 4 +- trunk/arch/um/os-Linux/helper.c | 4 +- trunk/arch/um/os-Linux/main.c | 13 + trunk/arch/um/os-Linux/process.c | 30 +- trunk/arch/um/os-Linux/signal.c | 218 +- trunk/arch/um/os-Linux/skas/Makefile | 4 +- trunk/arch/um/os-Linux/start_up.c | 2 +- trunk/arch/um/os-Linux/sys-i386/registers.c | 5 +- trunk/arch/um/os-Linux/sys-x86_64/registers.c | 5 +- trunk/arch/um/os-Linux/time.c | 131 +- trunk/arch/um/os-Linux/trap.c | 3 +- trunk/arch/um/os-Linux/tt.c | 49 +- trunk/arch/um/os-Linux/uaccess.c | 4 +- trunk/arch/um/sys-i386/ldt.c | 26 +- trunk/arch/um/sys-x86_64/ptrace_user.c | 7 - trunk/arch/um/sys-x86_64/user-offsets.c | 2 +- trunk/arch/v850/kernel/simcons.c | 25 +- trunk/arch/x86_64/Kconfig.debug | 7 + trunk/arch/x86_64/defconfig | 22 +- trunk/arch/x86_64/ia32/ia32entry.S | 16 - trunk/arch/x86_64/ia32/sys_ia32.c | 22 - trunk/arch/x86_64/kernel/acpi/Makefile | 5 - trunk/arch/x86_64/kernel/acpi/processor.c | 72 - trunk/arch/x86_64/kernel/apic.c | 91 +- trunk/arch/x86_64/kernel/entry.S | 7 +- trunk/arch/x86_64/kernel/io_apic.c | 18 +- trunk/arch/x86_64/kernel/mce.c | 2 +- trunk/arch/x86_64/kernel/mpparse.c | 8 +- trunk/arch/x86_64/kernel/nmi.c | 7 +- trunk/arch/x86_64/kernel/pci-dma.c | 3 - trunk/arch/x86_64/kernel/pci-gart.c | 25 +- trunk/arch/x86_64/kernel/pci-nommu.c | 7 + trunk/arch/x86_64/kernel/pci-swiotlb.c | 2 +- trunk/arch/x86_64/kernel/pmtimer.c | 25 - trunk/arch/x86_64/kernel/process.c | 4 +- trunk/arch/x86_64/kernel/setup.c | 10 +- trunk/arch/x86_64/kernel/setup64.c | 2 +- trunk/arch/x86_64/kernel/smpboot.c | 3 - trunk/arch/x86_64/kernel/time.c | 73 +- trunk/arch/x86_64/kernel/traps.c | 39 +- trunk/arch/x86_64/kernel/vmlinux.lds.S | 10 +- trunk/arch/x86_64/kernel/x8664_ksyms.c | 5 + trunk/arch/x86_64/lib/Makefile | 2 +- trunk/arch/x86_64/lib/clear_page.S | 38 - trunk/arch/x86_64/lib/copy_page.S | 87 - trunk/arch/x86_64/lib/copy_user.S | 247 +- trunk/arch/x86_64/lib/iomap_copy.S | 26 - trunk/arch/x86_64/lib/memcpy.S | 93 +- trunk/arch/x86_64/lib/memset.S | 94 - trunk/arch/x86_64/mm/fault.c | 3 +- trunk/arch/x86_64/mm/srat.c | 45 +- trunk/arch/x86_64/pci/mmconfig.c | 19 +- trunk/arch/xtensa/platform-iss/console.c | 4 +- trunk/block/elevator.c | 114 +- trunk/block/ll_rw_blk.c | 53 +- trunk/block/scsi_ioctl.c | 3 - trunk/crypto/scatterwalk.c | 1 + trunk/drivers/Kconfig | 2 - trunk/drivers/Makefile | 3 +- trunk/drivers/acpi/Kconfig | 1 + trunk/drivers/acpi/acpi_memhotplug.c | 17 +- trunk/drivers/acpi/asus_acpi.c | 35 +- trunk/drivers/acpi/dispatcher/dsfield.c | 37 +- trunk/drivers/acpi/dispatcher/dsinit.c | 51 +- trunk/drivers/acpi/dispatcher/dsmethod.c | 360 +-- trunk/drivers/acpi/dispatcher/dsmthdat.c | 37 +- trunk/drivers/acpi/dispatcher/dsobject.c | 106 +- trunk/drivers/acpi/dispatcher/dsopcode.c | 58 +- trunk/drivers/acpi/dispatcher/dsutils.c | 33 +- trunk/drivers/acpi/dispatcher/dswexec.c | 80 +- trunk/drivers/acpi/dispatcher/dswload.c | 270 +- trunk/drivers/acpi/dispatcher/dswscope.c | 6 +- trunk/drivers/acpi/dispatcher/dswstate.c | 128 +- trunk/drivers/acpi/ec.c | 291 +- trunk/drivers/acpi/events/evevent.c | 63 +- trunk/drivers/acpi/events/evgpe.c | 54 +- trunk/drivers/acpi/events/evgpeblk.c | 215 +- trunk/drivers/acpi/events/evmisc.c | 26 +- trunk/drivers/acpi/events/evregion.c | 63 +- trunk/drivers/acpi/events/evrgnini.c | 8 +- trunk/drivers/acpi/events/evsci.c | 6 +- trunk/drivers/acpi/events/evxface.c | 19 +- trunk/drivers/acpi/events/evxfevnt.c | 34 +- trunk/drivers/acpi/events/evxfregn.c | 2 +- trunk/drivers/acpi/executer/exconfig.c | 8 +- trunk/drivers/acpi/executer/exconvrt.c | 36 +- trunk/drivers/acpi/executer/excreate.c | 6 +- trunk/drivers/acpi/executer/exdump.c | 671 ++--- trunk/drivers/acpi/executer/exfield.c | 11 +- trunk/drivers/acpi/executer/exfldio.c | 93 +- trunk/drivers/acpi/executer/exmisc.c | 113 +- trunk/drivers/acpi/executer/exmutex.c | 28 +- trunk/drivers/acpi/executer/exnames.c | 23 +- trunk/drivers/acpi/executer/exoparg1.c | 72 +- trunk/drivers/acpi/executer/exoparg2.c | 46 +- trunk/drivers/acpi/executer/exoparg3.c | 12 +- trunk/drivers/acpi/executer/exoparg6.c | 16 +- trunk/drivers/acpi/executer/exprep.c | 34 +- trunk/drivers/acpi/executer/exregion.c | 35 +- trunk/drivers/acpi/executer/exresnte.c | 51 +- trunk/drivers/acpi/executer/exresolv.c | 35 +- trunk/drivers/acpi/executer/exresop.c | 143 +- trunk/drivers/acpi/executer/exstore.c | 27 +- trunk/drivers/acpi/executer/exstoren.c | 24 +- trunk/drivers/acpi/executer/exstorob.c | 6 +- trunk/drivers/acpi/executer/exsystem.c | 6 +- trunk/drivers/acpi/executer/exutils.c | 20 +- trunk/drivers/acpi/glue.c | 8 +- trunk/drivers/acpi/hardware/hwacpi.c | 25 +- trunk/drivers/acpi/hardware/hwgpe.c | 2 +- trunk/drivers/acpi/hardware/hwregs.c | 59 +- trunk/drivers/acpi/hardware/hwsleep.c | 23 +- trunk/drivers/acpi/hardware/hwtimer.c | 2 +- trunk/drivers/acpi/motherboard.c | 30 +- trunk/drivers/acpi/namespace/nsaccess.c | 35 +- trunk/drivers/acpi/namespace/nsalloc.c | 11 +- trunk/drivers/acpi/namespace/nsdump.c | 13 +- trunk/drivers/acpi/namespace/nsdumpdv.c | 2 +- trunk/drivers/acpi/namespace/nseval.c | 5 +- trunk/drivers/acpi/namespace/nsinit.c | 105 +- trunk/drivers/acpi/namespace/nsload.c | 10 +- trunk/drivers/acpi/namespace/nsnames.c | 14 +- trunk/drivers/acpi/namespace/nsobject.c | 13 +- trunk/drivers/acpi/namespace/nsparse.c | 2 +- trunk/drivers/acpi/namespace/nssearch.c | 30 +- trunk/drivers/acpi/namespace/nsutils.c | 43 +- trunk/drivers/acpi/namespace/nswalk.c | 2 +- trunk/drivers/acpi/namespace/nsxfeval.c | 29 +- trunk/drivers/acpi/namespace/nsxfname.c | 5 +- trunk/drivers/acpi/namespace/nsxfobj.c | 2 +- trunk/drivers/acpi/osl.c | 10 +- trunk/drivers/acpi/parser/psargs.c | 358 ++- trunk/drivers/acpi/parser/psloop.c | 39 +- trunk/drivers/acpi/parser/psopcode.c | 4 +- trunk/drivers/acpi/parser/psparse.c | 55 +- trunk/drivers/acpi/parser/psscope.c | 2 +- trunk/drivers/acpi/parser/pstree.c | 5 +- trunk/drivers/acpi/parser/psutils.c | 2 +- trunk/drivers/acpi/parser/pswalk.c | 2 +- trunk/drivers/acpi/parser/psxface.c | 144 +- trunk/drivers/acpi/pci_irq.c | 48 +- trunk/drivers/acpi/pci_link.c | 100 +- trunk/drivers/acpi/pci_root.c | 8 +- trunk/drivers/acpi/processor_core.c | 30 +- trunk/drivers/acpi/processor_idle.c | 139 +- trunk/drivers/acpi/processor_perflib.c | 4 +- trunk/drivers/acpi/processor_thermal.c | 7 +- trunk/drivers/acpi/processor_throttling.c | 7 +- trunk/drivers/acpi/resources/Makefile | 2 +- trunk/drivers/acpi/resources/rsaddr.c | 1164 ++++++-- trunk/drivers/acpi/resources/rscalc.c | 831 ++++-- trunk/drivers/acpi/resources/rscreate.c | 231 +- trunk/drivers/acpi/resources/rsdump.c | 1399 +++++---- trunk/drivers/acpi/resources/rsinfo.c | 204 -- trunk/drivers/acpi/resources/rsio.c | 544 +++- trunk/drivers/acpi/resources/rsirq.c | 568 +++- trunk/drivers/acpi/resources/rslist.c | 534 +++- trunk/drivers/acpi/resources/rsmemory.c | 517 +++- trunk/drivers/acpi/resources/rsmisc.c | 860 +++--- trunk/drivers/acpi/resources/rsutils.c | 390 +-- trunk/drivers/acpi/resources/rsxface.c | 230 +- trunk/drivers/acpi/scan.c | 2 +- trunk/drivers/acpi/sleep/poweroff.c | 15 +- trunk/drivers/acpi/sleep/sleep.h | 2 +- trunk/drivers/acpi/sleep/wakeup.c | 6 +- trunk/drivers/acpi/tables/tbconvrt.c | 23 +- trunk/drivers/acpi/tables/tbget.c | 39 +- trunk/drivers/acpi/tables/tbgetall.c | 27 +- trunk/drivers/acpi/tables/tbinstal.c | 12 +- trunk/drivers/acpi/tables/tbrsdt.c | 30 +- trunk/drivers/acpi/tables/tbutils.c | 50 +- trunk/drivers/acpi/tables/tbxface.c | 18 +- trunk/drivers/acpi/tables/tbxfroot.c | 35 +- trunk/drivers/acpi/utilities/Makefile | 5 +- trunk/drivers/acpi/utilities/utalloc.c | 61 +- trunk/drivers/acpi/utilities/utcache.c | 2 +- trunk/drivers/acpi/utilities/utcopy.c | 27 +- trunk/drivers/acpi/utilities/utdebug.c | 2 +- trunk/drivers/acpi/utilities/utdelete.c | 15 +- trunk/drivers/acpi/utilities/uteval.c | 46 +- trunk/drivers/acpi/utilities/utglobal.c | 108 +- trunk/drivers/acpi/utilities/utinit.c | 13 +- trunk/drivers/acpi/utilities/utmath.c | 10 +- trunk/drivers/acpi/utilities/utmisc.c | 209 +- trunk/drivers/acpi/utilities/utmutex.c | 58 +- trunk/drivers/acpi/utilities/utobject.c | 33 +- trunk/drivers/acpi/utilities/utresrc.c | 554 ---- trunk/drivers/acpi/utilities/utstate.c | 4 +- trunk/drivers/acpi/utilities/utxface.c | 69 +- trunk/drivers/acpi/video.c | 8 +- trunk/drivers/base/Makefile | 1 - trunk/drivers/base/base.h | 4 - trunk/drivers/base/bus.c | 3 - trunk/drivers/base/memory.c | 2 +- trunk/drivers/base/power/resume.c | 3 +- trunk/drivers/base/power/shutdown.c | 2 +- trunk/drivers/base/power/suspend.c | 3 +- trunk/drivers/base/power/sysfs.c | 24 +- trunk/drivers/base/sys.c | 3 - trunk/drivers/base/topology.c | 148 - trunk/drivers/block/Kconfig | 8 +- trunk/drivers/block/cciss.c | 5 +- trunk/drivers/block/pktcdvd.c | 58 +- trunk/drivers/block/ub.c | 139 +- trunk/drivers/block/umem.c | 2 +- trunk/drivers/bluetooth/bt3c_cs.c | 17 +- trunk/drivers/cdrom/viocd.c | 2 + trunk/drivers/char/Kconfig | 4 +- trunk/drivers/char/agp/amd64-agp.c | 24 - trunk/drivers/char/agp/ati-agp.c | 20 - trunk/drivers/char/agp/frontend.c | 28 +- trunk/drivers/char/agp/intel-agp.c | 15 +- trunk/drivers/char/agp/isoch.c | 4 +- trunk/drivers/char/cyclades.c | 6 +- trunk/drivers/char/drm/ati_pcigart.c | 17 +- trunk/drivers/char/drm/drmP.h | 15 +- trunk/drivers/char/drm/drm_auth.c | 20 +- trunk/drivers/char/drm/drm_bufs.c | 80 +- trunk/drivers/char/drm/drm_context.c | 52 +- trunk/drivers/char/drm/drm_drv.c | 4 +- trunk/drivers/char/drm/drm_fops.c | 12 +- trunk/drivers/char/drm/drm_ioctl.c | 18 +- trunk/drivers/char/drm/drm_irq.c | 16 +- trunk/drivers/char/drm/drm_pciids.h | 3 +- trunk/drivers/char/drm/drm_proc.c | 28 +- trunk/drivers/char/drm/drm_stub.c | 6 +- trunk/drivers/char/drm/drm_sysfs.c | 131 +- trunk/drivers/char/drm/drm_vm.c | 12 +- trunk/drivers/char/drm/i810_dma.c | 2 +- trunk/drivers/char/drm/i810_drv.h | 2 + trunk/drivers/char/drm/i830_dma.c | 2 +- trunk/drivers/char/drm/i830_drv.h | 3 + trunk/drivers/char/drm/i915_dma.c | 42 +- trunk/drivers/char/drm/i915_drm.h | 33 - trunk/drivers/char/drm/i915_drv.h | 6 +- trunk/drivers/char/drm/i915_mem.c | 31 - trunk/drivers/char/drm/radeon_cp.c | 2 +- trunk/drivers/char/drm/savage_bci.c | 4 +- trunk/drivers/char/drm/savage_drv.h | 1 + trunk/drivers/char/drm/via_dma.c | 10 +- trunk/drivers/char/drm/via_dmablit.c | 6 +- trunk/drivers/char/drm/via_drv.h | 7 + trunk/drivers/char/drm/via_irq.c | 2 +- trunk/drivers/char/esp.c | 4 +- trunk/drivers/char/hangcheck-timer.c | 12 +- trunk/drivers/char/hpet.c | 26 +- trunk/drivers/char/ip2/i2cmd.c | 1 + trunk/drivers/char/ip2main.c | 67 +- trunk/drivers/char/ipmi/ipmi_msghandler.c | 4 +- trunk/drivers/char/ipmi/ipmi_si_intf.c | 32 +- trunk/drivers/char/rio/cirrus.h | 142 + trunk/drivers/char/rio/defaults.h | 7 + trunk/drivers/char/rio/link.h | 34 + trunk/drivers/char/rio/list.h | 140 + trunk/drivers/char/rio/parmmap.h | 5 + trunk/drivers/char/rio/phb.h | 133 + trunk/drivers/char/rio/pkt.h | 27 + trunk/drivers/char/rio/qbuf.h | 4 + trunk/drivers/char/rio/riotypes.h | 66 + trunk/drivers/char/rio/rup.h | 5 + trunk/drivers/char/rio/sam.h | 4 + trunk/drivers/char/rocket.c | 2 +- trunk/drivers/char/ser_a2232.c | 1 - trunk/drivers/char/sx.c | 6 +- trunk/drivers/char/synclink_gt.c | 2 +- trunk/drivers/char/tipar.c | 15 +- trunk/drivers/char/tlclk.c | 93 +- trunk/drivers/char/tpm/tpm_bios.c | 25 +- trunk/drivers/char/tpm/tpm_infineon.c | 2 +- trunk/drivers/char/tty_io.c | 97 +- trunk/drivers/char/vt.c | 1 - trunk/drivers/char/watchdog/pcwd.c | 450 ++- trunk/drivers/char/watchdog/sa1100_wdt.c | 12 +- trunk/drivers/char/watchdog/sbc_epx_c3.c | 28 +- trunk/drivers/cpufreq/cpufreq.c | 47 +- trunk/drivers/edac/Kconfig | 101 - trunk/drivers/edac/Makefile | 18 - trunk/drivers/edac/amd76x_edac.c | 356 --- trunk/drivers/edac/e752x_edac.c | 1071 ------- trunk/drivers/edac/e7xxx_edac.c | 558 ---- trunk/drivers/edac/edac_mc.c | 2208 -------------- trunk/drivers/edac/edac_mc.h | 448 --- trunk/drivers/edac/i82860_edac.c | 299 -- trunk/drivers/edac/i82875p_edac.c | 532 ---- trunk/drivers/edac/r82600_edac.c | 407 --- trunk/drivers/hwmon/Kconfig | 10 - trunk/drivers/hwmon/Makefile | 1 - trunk/drivers/hwmon/f71805f.c | 908 ------ trunk/drivers/hwmon/it87.c | 8 +- trunk/drivers/hwmon/lm77.c | 8 +- trunk/drivers/hwmon/w83792d.c | 31 +- trunk/drivers/i2c/algos/i2c-algo-sibyte.c | 2 +- trunk/drivers/i2c/busses/Kconfig | 1 - trunk/drivers/i2c/busses/i2c-i801.c | 2 - trunk/drivers/i2c/busses/i2c-parport-light.c | 9 +- trunk/drivers/i2c/busses/i2c-parport.c | 7 +- trunk/drivers/i2c/busses/i2c-pxa.c | 2 +- trunk/drivers/i2c/i2c-core.c | 15 - trunk/drivers/ide/Kconfig | 25 +- trunk/drivers/ide/ide-disk.c | 14 +- trunk/drivers/ide/ide-io.c | 5 +- trunk/drivers/ide/ide-iops.c | 1 - trunk/drivers/ide/ide-probe.c | 51 +- trunk/drivers/ide/ide.c | 1 + trunk/drivers/ide/pci/aec62xx.c | 15 - trunk/drivers/ide/pci/hpt366.c | 4 - trunk/drivers/ide/pci/it821x.c | 2 +- trunk/drivers/ide/pci/pdc202xx_new.c | 6 + trunk/drivers/ide/pci/pdc202xx_old.c | 15 + trunk/drivers/ide/pci/piix.c | 4 - trunk/drivers/ide/pci/sgiioc4.c | 9 +- trunk/drivers/infiniband/core/sa_query.c | 2 - trunk/drivers/infiniband/core/ucm.c | 13 +- trunk/drivers/infiniband/core/uverbs_main.c | 1 - trunk/drivers/infiniband/hw/mthca/mthca_av.c | 2 +- trunk/drivers/infiniband/hw/mthca/mthca_cmd.c | 13 +- trunk/drivers/infiniband/hw/mthca/mthca_dev.h | 8 +- .../drivers/infiniband/hw/mthca/mthca_main.c | 10 +- trunk/drivers/infiniband/hw/mthca/mthca_mcg.c | 20 +- .../infiniband/hw/mthca/mthca_memfree.c | 36 +- .../infiniband/hw/mthca/mthca_memfree.h | 7 +- .../infiniband/hw/mthca/mthca_provider.c | 6 +- .../drivers/infiniband/ulp/ipoib/ipoib_main.c | 4 +- .../infiniband/ulp/ipoib/ipoib_multicast.c | 25 +- trunk/drivers/infiniband/ulp/srp/ib_srp.c | 14 +- trunk/drivers/infiniband/ulp/srp/ib_srp.h | 5 +- trunk/drivers/input/joystick/a3d.c | 88 +- trunk/drivers/input/joystick/db9.c | 85 +- trunk/drivers/input/joystick/gamecon.c | 361 +-- trunk/drivers/input/joystick/grip.c | 11 +- .../input/joystick/iforce/iforce-main.c | 2 +- .../input/joystick/iforce/iforce-packets.c | 4 +- .../input/joystick/iforce/iforce-usb.c | 1 + trunk/drivers/input/joystick/sidewinder.c | 10 +- trunk/drivers/input/joystick/tmdc.c | 15 +- trunk/drivers/input/joystick/turbografx.c | 20 +- trunk/drivers/input/joystick/twidjoy.c | 4 +- trunk/drivers/input/misc/Kconfig | 12 - trunk/drivers/input/misc/Makefile | 1 - trunk/drivers/input/misc/ixp4xx-beeper.c | 183 -- trunk/drivers/input/mouse/psmouse-base.c | 1 - trunk/drivers/input/mousedev.c | 9 +- trunk/drivers/input/touchscreen/ads7846.c | 9 +- trunk/drivers/input/touchscreen/mk712.c | 2 +- trunk/drivers/isdn/hisax/Kconfig | 2 +- trunk/drivers/isdn/hisax/hisax.h | 2 +- trunk/drivers/isdn/sc/ioctl.c | 4 +- trunk/drivers/macintosh/Kconfig | 8 - trunk/drivers/macintosh/Makefile | 5 - trunk/drivers/macintosh/macio_asic.c | 72 +- trunk/drivers/macintosh/windfarm.h | 3 - trunk/drivers/macintosh/windfarm_core.c | 122 +- .../macintosh/windfarm_max6690_sensor.c | 169 -- trunk/drivers/macintosh/windfarm_pid.c | 8 +- trunk/drivers/macintosh/windfarm_pid.h | 1 - trunk/drivers/macintosh/windfarm_pm112.c | 698 ----- trunk/drivers/macintosh/windfarm_pm81.c | 87 +- trunk/drivers/macintosh/windfarm_pm91.c | 95 +- .../drivers/macintosh/windfarm_smu_controls.c | 69 +- trunk/drivers/macintosh/windfarm_smu_sat.c | 418 --- .../drivers/macintosh/windfarm_smu_sensors.c | 43 +- trunk/drivers/md/dm-ioctl.c | 14 +- trunk/drivers/md/dm-log.c | 48 +- trunk/drivers/md/dm-snap.c | 29 +- trunk/drivers/md/dm-snap.h | 4 +- trunk/drivers/md/dm-table.c | 2 +- trunk/drivers/md/dm.c | 39 +- trunk/drivers/md/kcopyd.c | 1 - trunk/drivers/md/md.c | 48 +- trunk/drivers/md/raid0.c | 2 +- trunk/drivers/md/raid10.c | 2 - trunk/drivers/md/raid5.c | 3 +- trunk/drivers/md/raid6main.c | 152 +- trunk/drivers/media/dvb/b2c2/Kconfig | 2 +- trunk/drivers/media/dvb/b2c2/flexcop-common.h | 2 + trunk/drivers/media/dvb/b2c2/flexcop-dma.c | 35 + .../drivers/media/dvb/b2c2/flexcop-fe-tuner.c | 9 +- trunk/drivers/media/dvb/b2c2/flexcop-misc.c | 6 +- trunk/drivers/media/dvb/b2c2/flexcop-pci.c | 6 +- trunk/drivers/media/dvb/b2c2/flexcop-reg.h | 4 + trunk/drivers/media/dvb/bt8xx/bt878.c | 44 +- trunk/drivers/media/dvb/bt8xx/bt878.h | 17 - trunk/drivers/media/dvb/dvb-usb/Kconfig | 12 +- trunk/drivers/media/dvb/dvb-usb/cxusb.c | 12 +- trunk/drivers/media/dvb/dvb-usb/digitv.c | 13 +- trunk/drivers/media/dvb/dvb-usb/dtt200u.c | 4 +- .../media/dvb/dvb-usb/dvb-usb-firmware.c | 8 +- trunk/drivers/media/dvb/dvb-usb/dvb-usb.h | 1 + trunk/drivers/media/dvb/dvb-usb/vp702x.c | 6 +- trunk/drivers/media/dvb/dvb-usb/vp702x.h | 2 + trunk/drivers/media/dvb/dvb-usb/vp7045-fe.c | 6 +- trunk/drivers/media/dvb/dvb-usb/vp7045.c | 2 +- trunk/drivers/media/dvb/frontends/Kconfig | 24 + trunk/drivers/media/dvb/frontends/Makefile | 3 + trunk/drivers/media/dvb/frontends/at76c651.c | 450 +++ trunk/drivers/media/dvb/frontends/at76c651.h | 47 + trunk/drivers/media/dvb/frontends/dvb-pll.c | 8 +- trunk/drivers/media/dvb/frontends/dvb-pll.h | 2 +- trunk/drivers/media/dvb/frontends/nxt2002.c | 706 +++++ trunk/drivers/media/dvb/frontends/nxt2002.h | 23 + trunk/drivers/media/dvb/frontends/nxt200x.c | 58 +- trunk/drivers/media/dvb/frontends/tda80xx.c | 734 +++++ trunk/drivers/media/dvb/frontends/tda80xx.h | 51 + trunk/drivers/media/dvb/ttpci/av7110.c | 14 +- trunk/drivers/media/dvb/ttpci/av7110.h | 2 + trunk/drivers/media/dvb/ttpci/av7110_ir.c | 26 +- trunk/drivers/media/video/bttv-driver.c | 2 +- trunk/drivers/media/video/compat_ioctl32.c | 89 +- .../media/video/cx25840/cx25840-core.c | 50 +- trunk/drivers/media/video/cx88/Kconfig | 12 - trunk/drivers/media/video/cx88/Makefile | 5 +- trunk/drivers/media/video/cx88/cx88-alsa.c | 6 +- trunk/drivers/media/video/cx88/cx88-cards.c | 6 - trunk/drivers/media/video/cx88/cx88-core.c | 10 +- trunk/drivers/media/video/cx88/cx88-input.c | 1 - .../drivers/media/video/em28xx/em28xx-core.c | 17 +- trunk/drivers/media/video/em28xx/em28xx-i2c.c | 8 +- .../drivers/media/video/em28xx/em28xx-video.c | 3 - trunk/drivers/media/video/hexium_orion.c | 2 +- .../media/video/saa7134/saa7134-cards.c | 47 +- .../drivers/media/video/saa7134/saa7134-dvb.c | 2 +- trunk/drivers/media/video/saa7134/saa7134.h | 2 +- trunk/drivers/media/video/stradis.c | 15 +- trunk/drivers/media/video/tda9887.c | 9 +- trunk/drivers/media/video/tuner-core.c | 8 +- trunk/drivers/media/video/tvaudio.c | 9 - trunk/drivers/media/video/tvp5150.c | 32 +- trunk/drivers/message/fusion/Makefile | 2 - trunk/drivers/message/fusion/mptbase.c | 184 +- trunk/drivers/message/fusion/mptbase.h | 16 +- trunk/drivers/message/fusion/mptfc.c | 203 +- trunk/drivers/message/fusion/mptsas.c | 241 +- trunk/drivers/message/fusion/mptscsih.c | 116 +- trunk/drivers/message/fusion/mptscsih.h | 1 - trunk/drivers/message/fusion/mptspi.c | 10 +- trunk/drivers/message/i2o/core.h | 3 - trunk/drivers/message/i2o/i2o_scsi.c | 2 +- trunk/drivers/message/i2o/pci.c | 47 +- trunk/drivers/misc/ibmasm/uart.c | 2 +- trunk/drivers/mmc/Kconfig | 2 +- trunk/drivers/mmc/au1xmmc.c | 59 +- trunk/drivers/mmc/mmc.c | 28 +- trunk/drivers/mmc/mmc_block.c | 8 +- trunk/drivers/mmc/mmci.c | 11 +- trunk/drivers/mmc/pxamci.c | 9 +- trunk/drivers/mmc/wbsd.c | 8 +- trunk/drivers/mtd/chips/Kconfig | 2 +- trunk/drivers/mtd/maps/dc21285.c | 9 +- trunk/drivers/mtd/maps/tsunami_flash.c | 2 +- trunk/drivers/net/3c59x.c | 33 +- trunk/drivers/net/8139too.c | 38 +- trunk/drivers/net/Kconfig | 45 +- trunk/drivers/net/acenic.c | 4 - trunk/drivers/net/appletalk/cops.h | 2 +- trunk/drivers/net/b44.c | 5 +- trunk/drivers/net/bnx2.c | 308 +- trunk/drivers/net/bnx2.h | 34 +- trunk/drivers/net/bnx2_fw.h | 825 +++--- trunk/drivers/net/bonding/bond_main.c | 17 +- trunk/drivers/net/bonding/bond_sysfs.c | 6 +- trunk/drivers/net/cassini.c | 36 +- trunk/drivers/net/e100.c | 2 + trunk/drivers/net/e1000/e1000_ethtool.c | 307 +- trunk/drivers/net/e1000/e1000_hw.c | 18 +- trunk/drivers/net/e1000/e1000_hw.h | 20 +- trunk/drivers/net/e1000/e1000_main.c | 802 ++--- trunk/drivers/net/e1000/e1000_osdep.h | 2 +- trunk/drivers/net/e1000/e1000_param.c | 44 +- trunk/drivers/net/gianfar.c | 24 +- trunk/drivers/net/gianfar.h | 8 +- trunk/drivers/net/gianfar_ethtool.c | 8 +- trunk/drivers/net/gianfar_mii.c | 17 +- trunk/drivers/net/hamradio/baycom_par.c | 1 + trunk/drivers/net/lp486e.c | 2 + trunk/drivers/net/mv643xx_eth.c | 110 +- trunk/drivers/net/ppp_generic.c | 3 - trunk/drivers/net/r8169.c | 13 +- trunk/drivers/net/s2io.c | 2 +- trunk/drivers/net/sis900.h | 1 + trunk/drivers/net/sky2.c | 186 +- trunk/drivers/net/sky2.h | 9 +- trunk/drivers/net/tg3.c | 30 +- trunk/drivers/net/tg3.h | 1 - trunk/drivers/net/tulip/uli526x.c | 2 +- trunk/drivers/net/wan/dscc4.c | 2 +- trunk/drivers/net/wan/pci200syn.c | 2 +- trunk/drivers/net/wan/wanxl.c | 2 +- trunk/drivers/net/wireless/Kconfig | 2 +- trunk/drivers/net/wireless/hostap/Kconfig | 2 +- trunk/drivers/net/wireless/ipw2100.c | 49 +- trunk/drivers/net/wireless/ipw2200.c | 9 +- trunk/drivers/net/wireless/orinoco_cs.c | 5 +- .../drivers/net/wireless/prism54/isl_ioctl.c | 2 +- trunk/drivers/parisc/ccio-dma.c | 7 +- trunk/drivers/parisc/dino.c | 4 +- trunk/drivers/parisc/hppb.c | 3 +- trunk/drivers/parisc/iosapic.c | 8 +- trunk/drivers/parisc/lasi.c | 5 +- trunk/drivers/parisc/lba_pci.c | 6 +- trunk/drivers/parisc/pdc_stable.c | 356 +-- trunk/drivers/parisc/sba_iommu.c | 3 +- trunk/drivers/parisc/superio.c | 41 +- trunk/drivers/parisc/wax.c | 2 +- trunk/drivers/parport/Kconfig | 9 - trunk/drivers/parport/Makefile | 1 - trunk/drivers/parport/ieee1284.c | 10 +- trunk/drivers/parport/parport_gsc.c | 2 +- trunk/drivers/parport/parport_ip32.c | 2253 -------------- trunk/drivers/parport/parport_serial.c | 4 +- trunk/drivers/parport/probe.c | 4 +- trunk/drivers/pci/hotplug/Kconfig | 3 +- trunk/drivers/pci/hotplug/acpiphp_ibm.c | 21 +- trunk/drivers/pci/hotplug/ibmphp_core.c | 4 +- trunk/drivers/pci/hotplug/rpadlpar_core.c | 64 +- trunk/drivers/pci/hotplug/rpaphp.h | 14 +- trunk/drivers/pci/hotplug/rpaphp_core.c | 114 +- trunk/drivers/pci/hotplug/rpaphp_pci.c | 267 +- trunk/drivers/pci/hotplug/rpaphp_slot.c | 17 +- trunk/drivers/pci/hotplug/shpchp.h | 94 - trunk/drivers/pci/hotplug/shpchp_ctrl.c | 12 +- trunk/drivers/pci/msi.c | 14 +- trunk/drivers/pci/msi.h | 6 + trunk/drivers/pci/pci.c | 2 - trunk/drivers/pci/setup-res.c | 1 - trunk/drivers/pnp/card.c | 9 +- trunk/drivers/pnp/pnpacpi/core.c | 14 +- trunk/drivers/pnp/pnpacpi/rsparser.c | 547 ++-- trunk/drivers/s390/Kconfig | 7 - trunk/drivers/s390/block/Kconfig | 14 +- trunk/drivers/s390/block/Makefile | 2 - trunk/drivers/s390/block/dasd.c | 122 +- trunk/drivers/s390/block/dasd_3370_erp.c | 1 + trunk/drivers/s390/block/dasd_3990_erp.c | 4 +- trunk/drivers/s390/block/dasd_9336_erp.c | 1 + trunk/drivers/s390/block/dasd_9343_erp.c | 1 + trunk/drivers/s390/block/dasd_cmb.c | 2 + trunk/drivers/s390/block/dasd_devmap.c | 1 + trunk/drivers/s390/block/dasd_diag.c | 1 + trunk/drivers/s390/block/dasd_diag.h | 1 + trunk/drivers/s390/block/dasd_eckd.c | 1 + trunk/drivers/s390/block/dasd_eckd.h | 2 +- trunk/drivers/s390/block/dasd_eer.c | 1090 ------- trunk/drivers/s390/block/dasd_erp.c | 1 + trunk/drivers/s390/block/dasd_fba.c | 1 + trunk/drivers/s390/block/dasd_fba.h | 1 + trunk/drivers/s390/block/dasd_genhd.c | 1 + trunk/drivers/s390/block/dasd_int.h | 38 +- trunk/drivers/s390/block/dasd_ioctl.c | 11 +- trunk/drivers/s390/block/dasd_proc.c | 1 + trunk/drivers/s390/char/con3215.c | 3 +- trunk/drivers/s390/char/con3270.c | 3 +- trunk/drivers/s390/char/keyboard.c | 6 +- trunk/drivers/s390/char/sclp.c | 13 +- trunk/drivers/s390/char/tape_34xx.c | 5 +- trunk/drivers/s390/char/tape_class.c | 4 +- trunk/drivers/s390/char/tape_class.h | 2 +- trunk/drivers/s390/char/tape_core.c | 5 +- trunk/drivers/s390/cio/airq.c | 2 + trunk/drivers/s390/cio/blacklist.c | 1 + trunk/drivers/s390/cio/ccwgroup.c | 1 + trunk/drivers/s390/cio/chsc.c | 11 +- trunk/drivers/s390/cio/chsc.h | 2 +- trunk/drivers/s390/cio/cio.c | 1 + trunk/drivers/s390/cio/cmf.c | 2 +- trunk/drivers/s390/cio/css.c | 1 + trunk/drivers/s390/cio/device.c | 5 +- trunk/drivers/s390/cio/device_ops.c | 2 + trunk/drivers/s390/cio/qdio.c | 5 +- trunk/drivers/s390/cio/qdio.h | 2 + trunk/drivers/s390/crypto/z90common.h | 2 + trunk/drivers/s390/crypto/z90crypt.h | 2 + trunk/drivers/s390/crypto/z90hardware.c | 6 + trunk/drivers/s390/crypto/z90main.c | 10 + trunk/drivers/s390/net/claw.c | 11 +- trunk/drivers/s390/net/claw.h | 2 +- trunk/drivers/s390/net/ctcdbug.c | 5 +- trunk/drivers/s390/net/ctcdbug.h | 4 +- trunk/drivers/s390/net/ctcmain.c | 19 +- trunk/drivers/s390/net/ctcmain.h | 4 + trunk/drivers/s390/net/ctctty.c | 2 + trunk/drivers/s390/net/ctctty.h | 2 + trunk/drivers/s390/net/cu3088.c | 2 + trunk/drivers/s390/net/fsm.c | 2 + trunk/drivers/s390/net/fsm.h | 2 + trunk/drivers/s390/net/iucv.c | 16 +- trunk/drivers/s390/net/lcs.c | 5 +- trunk/drivers/s390/net/lcs.h | 2 + trunk/drivers/s390/net/netiucv.c | 15 +- trunk/drivers/s390/net/qeth.h | 2 + trunk/drivers/s390/net/qeth_eddp.c | 5 +- trunk/drivers/s390/net/qeth_eddp.h | 6 +- trunk/drivers/s390/net/qeth_fs.h | 5 + trunk/drivers/s390/net/qeth_main.c | 13 +- trunk/drivers/s390/net/qeth_mpc.c | 2 + trunk/drivers/s390/net/qeth_mpc.h | 4 + trunk/drivers/s390/net/qeth_proc.c | 4 +- trunk/drivers/s390/net/qeth_sys.c | 4 +- trunk/drivers/s390/net/qeth_tso.h | 4 +- trunk/drivers/s390/s390_rdev.c | 1 + trunk/drivers/s390/s390mach.h | 17 +- trunk/drivers/s390/scsi/zfcp_aux.c | 2 + trunk/drivers/s390/scsi/zfcp_ccw.c | 2 + trunk/drivers/s390/scsi/zfcp_dbf.c | 2 + trunk/drivers/s390/scsi/zfcp_def.h | 2 + trunk/drivers/s390/scsi/zfcp_erp.c | 2 + trunk/drivers/s390/scsi/zfcp_ext.h | 2 + trunk/drivers/s390/scsi/zfcp_fsf.c | 2 + trunk/drivers/s390/scsi/zfcp_qdio.c | 2 + trunk/drivers/s390/scsi/zfcp_scsi.c | 2 + trunk/drivers/s390/scsi/zfcp_sysfs_adapter.c | 2 + trunk/drivers/s390/scsi/zfcp_sysfs_driver.c | 2 + trunk/drivers/s390/scsi/zfcp_sysfs_port.c | 2 + trunk/drivers/s390/scsi/zfcp_sysfs_unit.c | 2 + trunk/drivers/scsi/aacraid/commsup.c | 2 +- trunk/drivers/scsi/ahci.c | 19 +- trunk/drivers/scsi/aic7xxx/Kconfig.aic79xx | 4 +- trunk/drivers/scsi/aic7xxx/aic79xx.h | 3 +- trunk/drivers/scsi/aic7xxx/aic79xx.reg | 29 +- trunk/drivers/scsi/aic7xxx/aic79xx.seq | 143 +- trunk/drivers/scsi/aic7xxx/aic79xx_core.c | 286 +- trunk/drivers/scsi/aic7xxx/aic79xx_inline.h | 7 +- trunk/drivers/scsi/aic7xxx/aic79xx_osm.c | 43 +- trunk/drivers/scsi/aic7xxx/aic79xx_osm.h | 10 +- trunk/drivers/scsi/aic7xxx/aic79xx_osm_pci.c | 17 +- trunk/drivers/scsi/aic7xxx/aic79xx_pci.c | 11 +- .../scsi/aic7xxx/aic79xx_reg.h_shipped | 27 +- .../scsi/aic7xxx/aic79xx_reg_print.c_shipped | 21 +- .../scsi/aic7xxx/aic79xx_seq.h_shipped | 881 +++--- trunk/drivers/scsi/aic7xxx/aicasm/aicasm.c | 23 +- .../drivers/scsi/aic7xxx/aicasm/aicasm_gram.y | 19 +- .../scsi/aic7xxx/aicasm/aicasm_insformat.h | 88 +- .../drivers/scsi/aic7xxx/aicasm/aicasm_scan.l | 27 +- trunk/drivers/scsi/dc395x.c | 6 +- trunk/drivers/scsi/ibmvscsi/ibmvscsi.c | 67 +- trunk/drivers/scsi/ibmvscsi/ibmvscsi.h | 3 - trunk/drivers/scsi/ibmvscsi/iseries_vscsi.c | 13 - trunk/drivers/scsi/ibmvscsi/rpa_vscsi.c | 22 - trunk/drivers/scsi/ide-scsi.c | 14 +- trunk/drivers/scsi/ips.c | 54 +- trunk/drivers/scsi/libata-scsi.c | 27 +- trunk/drivers/scsi/mac53c94.c | 4 +- trunk/drivers/scsi/megaraid/megaraid_sas.c | 291 +- trunk/drivers/scsi/megaraid/megaraid_sas.h | 24 +- trunk/drivers/scsi/qla1280.c | 311 +- trunk/drivers/scsi/qla2xxx/qla_def.h | 4 +- trunk/drivers/scsi/qla2xxx/qla_gbl.h | 6 +- trunk/drivers/scsi/qla2xxx/qla_init.c | 83 +- trunk/drivers/scsi/qla2xxx/qla_isr.c | 16 +- trunk/drivers/scsi/qla2xxx/qla_os.c | 55 +- trunk/drivers/scsi/sata_mv.c | 11 +- trunk/drivers/scsi/sata_sil.c | 10 +- trunk/drivers/scsi/scsi.c | 2 +- trunk/drivers/scsi/scsi_error.c | 2 +- trunk/drivers/scsi/scsi_lib.c | 5 +- trunk/drivers/scsi/scsi_transport_iscsi.c | 2 +- trunk/drivers/scsi/scsi_transport_sas.c | 6 +- trunk/drivers/scsi/sg.c | 4 +- trunk/drivers/scsi/st.c | 2 +- trunk/drivers/serial/21285.c | 4 +- trunk/drivers/serial/68328serial.c | 4 +- trunk/drivers/serial/68360serial.c | 4 +- trunk/drivers/serial/8250.c | 33 +- trunk/drivers/serial/8250_acpi.c | 22 +- trunk/drivers/serial/8250_au1x00.c | 1 + trunk/drivers/serial/8250_pci.c | 39 +- trunk/drivers/serial/Kconfig | 33 +- trunk/drivers/serial/amba-pl010.c | 8 +- trunk/drivers/serial/at91_serial.c | 2 + trunk/drivers/serial/au1x00_uart.c | 12 +- trunk/drivers/serial/clps711x.c | 4 +- trunk/drivers/serial/cpm_uart/cpm_uart_core.c | 25 +- trunk/drivers/serial/dz.c | 3 +- trunk/drivers/serial/imx.c | 12 +- trunk/drivers/serial/ioc4_serial.c | 14 + trunk/drivers/serial/ip22zilog.c | 8 +- trunk/drivers/serial/jsm/jsm.h | 1 + trunk/drivers/serial/jsm/jsm_driver.c | 3 + trunk/drivers/serial/jsm/jsm_neo.c | 85 +- trunk/drivers/serial/jsm/jsm_tty.c | 209 +- trunk/drivers/serial/m32r_sio.c | 2 +- trunk/drivers/serial/m32r_sio.h | 2 +- trunk/drivers/serial/mcfserial.c | 17 +- trunk/drivers/serial/mux.c | 2 +- trunk/drivers/serial/pmac_zilog.c | 2 +- trunk/drivers/serial/s3c2410.c | 6 +- trunk/drivers/serial/sa1100.c | 8 +- trunk/drivers/serial/serial_core.c | 18 +- trunk/drivers/serial/serial_lh7a40x.c | 12 +- trunk/drivers/serial/sh-sci.c | 317 +- trunk/drivers/serial/sh-sci.h | 114 +- trunk/drivers/serial/sn_console.c | 129 +- trunk/drivers/serial/suncore.c | 34 +- trunk/drivers/serial/sunsab.c | 9 +- trunk/drivers/serial/sunsu.c | 24 +- trunk/drivers/serial/sunzilog.c | 4 +- trunk/drivers/serial/v850e_uart.c | 2 +- trunk/drivers/sn/ioc3.c | 30 +- trunk/drivers/spi/Kconfig | 10 + trunk/drivers/spi/spi_butterfly.c | 36 +- trunk/drivers/tc/tc.c | 1 + trunk/drivers/telephony/ixj.c | 14 +- trunk/drivers/usb/Makefile | 1 - trunk/drivers/usb/atm/cxacru.c | 92 +- trunk/drivers/usb/atm/speedtch.c | 167 +- trunk/drivers/usb/atm/ueagle-atm.c | 96 +- trunk/drivers/usb/atm/usbatm.c | 574 ++-- trunk/drivers/usb/atm/usbatm.h | 59 +- trunk/drivers/usb/atm/xusbatm.c | 137 +- trunk/drivers/usb/class/cdc-acm.c | 9 +- trunk/drivers/usb/class/usblp.c | 71 +- trunk/drivers/usb/core/driver.c | 6 +- trunk/drivers/usb/core/message.c | 1 - trunk/drivers/usb/core/urb.c | 1 - trunk/drivers/usb/gadget/inode.c | 8 +- trunk/drivers/usb/gadget/net2280.c | 1 - trunk/drivers/usb/gadget/zero.c | 8 +- trunk/drivers/usb/host/ehci-pci.c | 64 +- trunk/drivers/usb/host/ehci-sched.c | 4 +- trunk/drivers/usb/host/isp116x-hcd.c | 21 +- trunk/drivers/usb/host/ohci-au1xxx.c | 2 +- trunk/drivers/usb/host/pci-quirks.c | 106 +- trunk/drivers/usb/host/uhci-q.c | 4 +- trunk/drivers/usb/input/hid-core.c | 9 +- trunk/drivers/usb/input/hiddev.c | 5 +- trunk/drivers/usb/input/touchkitusb.c | 3 - trunk/drivers/usb/input/yealink.c | 48 +- trunk/drivers/usb/media/Kconfig | 17 +- trunk/drivers/usb/media/Makefile | 2 - trunk/drivers/usb/media/et61x251.h | 220 -- trunk/drivers/usb/media/et61x251_core.c | 2605 ----------------- trunk/drivers/usb/media/et61x251_sensor.h | 115 - trunk/drivers/usb/media/et61x251_tas5130d1b.c | 137 - trunk/drivers/usb/media/ov511.c | 196 +- trunk/drivers/usb/media/pwc/pwc-ctrl.c | 264 +- trunk/drivers/usb/media/sn9c102.h | 50 +- trunk/drivers/usb/media/sn9c102_core.c | 1687 +++++------ trunk/drivers/usb/media/sn9c102_hv7131d.c | 2 +- trunk/drivers/usb/media/sn9c102_mi0343.c | 2 +- trunk/drivers/usb/media/sn9c102_ov7630.c | 8 +- trunk/drivers/usb/media/sn9c102_pas106b.c | 2 +- trunk/drivers/usb/media/sn9c102_sensor.h | 85 +- trunk/drivers/usb/media/sn9c102_tas5110c1b.c | 2 +- trunk/drivers/usb/media/sn9c102_tas5130d1b.c | 2 +- trunk/drivers/usb/media/w9968cf.c | 128 +- trunk/drivers/usb/media/w9968cf.h | 1 + trunk/drivers/usb/media/w9968cf_vpp.h | 3 + trunk/drivers/usb/misc/auerswald.c | 2 - trunk/drivers/usb/misc/ldusb.c | 2 +- trunk/drivers/usb/net/asix.c | 4 - trunk/drivers/usb/serial/cp2101.c | 14 +- trunk/drivers/usb/serial/ftdi_sio.c | 6 - trunk/drivers/usb/serial/ftdi_sio.h | 23 +- trunk/drivers/usb/serial/pl2303.c | 4 +- trunk/drivers/usb/serial/pl2303.h | 7 - trunk/drivers/usb/storage/initializers.c | 73 - trunk/drivers/usb/storage/initializers.h | 1 - trunk/drivers/usb/storage/libusual.c | 2 +- trunk/drivers/usb/storage/unusual_devs.h | 15 +- trunk/drivers/usb/usb-skeleton.c | 2 +- trunk/drivers/video/Kconfig | 5 + trunk/drivers/video/amba-clcd.c | 54 +- trunk/drivers/video/backlight/Kconfig | 8 - trunk/drivers/video/backlight/Makefile | 1 - trunk/drivers/video/backlight/backlight.c | 1 + trunk/drivers/video/backlight/hp680_bl.c | 189 -- trunk/drivers/video/backlight/lcd.c | 1 + trunk/drivers/video/console/sticore.c | 45 +- trunk/drivers/video/cyblafb.c | 1 + trunk/drivers/video/fbmem.c | 2 - trunk/drivers/video/i810/i810-i2c.c | 6 +- trunk/drivers/video/i810/i810.h | 1 - trunk/drivers/video/i810/i810_main.c | 13 +- trunk/drivers/video/nvidia/nvidia.c | 2 - trunk/drivers/video/pmag-ba-fb.c | 1 + trunk/drivers/video/pmagb-b-fb.c | 1 + trunk/fs/9p/Makefile | 1 - trunk/fs/9p/conv.c | 28 +- trunk/fs/9p/mux.c | 15 +- trunk/fs/9p/v9fs_vfs.h | 1 - trunk/fs/9p/vfs_addr.c | 109 - trunk/fs/9p/vfs_file.c | 4 - trunk/fs/9p/vfs_inode.c | 7 +- trunk/fs/Kconfig | 4 +- trunk/fs/bio.c | 1 - trunk/fs/buffer.c | 65 +- trunk/fs/cifs/CHANGES | 10 - trunk/fs/cifs/README | 12 +- trunk/fs/cifs/cifs_debug.c | 51 +- trunk/fs/cifs/cifs_fs_sb.h | 5 +- trunk/fs/cifs/cifsacl.h | 38 - trunk/fs/cifs/cifsencrypt.c | 55 +- trunk/fs/cifs/cifsfs.c | 28 +- trunk/fs/cifs/cifsfs.h | 2 +- trunk/fs/cifs/cifsglob.h | 18 +- trunk/fs/cifs/cifspdu.h | 97 +- trunk/fs/cifs/cifsproto.h | 23 +- trunk/fs/cifs/cifssmb.c | 294 +- trunk/fs/cifs/connect.c | 100 +- trunk/fs/cifs/dir.c | 8 +- trunk/fs/cifs/file.c | 81 +- trunk/fs/cifs/inode.c | 9 +- trunk/fs/cifs/misc.c | 17 +- trunk/fs/cifs/readdir.c | 17 +- trunk/fs/cifs/rfc1002pdu.h | 4 +- trunk/fs/cifs/transport.c | 39 +- trunk/fs/cifs/xattr.c | 22 +- trunk/fs/compat.c | 327 +-- trunk/fs/compat_ioctl.c | 8 +- trunk/fs/configfs/configfs_internal.h | 11 +- trunk/fs/configfs/dir.c | 36 +- trunk/fs/configfs/file.c | 19 +- trunk/fs/configfs/inode.c | 120 +- trunk/fs/configfs/mount.c | 28 +- trunk/fs/configfs/symlink.c | 4 +- trunk/fs/dcache.c | 2 - trunk/fs/debugfs/file.c | 6 +- trunk/fs/direct-io.c | 9 +- trunk/fs/exec.c | 2 +- trunk/fs/exportfs/expfs.c | 79 +- trunk/fs/ext2/acl.c | 2 +- trunk/fs/ext2/ialloc.c | 2 +- trunk/fs/ext2/inode.c | 2 - trunk/fs/ext2/super.c | 5 - trunk/fs/ext3/acl.c | 2 +- trunk/fs/ext3/inode.c | 2 - trunk/fs/fat/file.c | 50 +- trunk/fs/fat/misc.c | 14 +- trunk/fs/fcntl.c | 7 +- trunk/fs/file.c | 3 +- trunk/fs/fuse/dev.c | 40 +- trunk/fs/fuse/file.c | 9 +- trunk/fs/fuse/fuse_i.h | 3 - trunk/fs/fuse/inode.c | 14 +- trunk/fs/hfs/bfind.c | 3 +- trunk/fs/hfs/bnode.c | 6 +- trunk/fs/hfs/brec.c | 2 +- trunk/fs/hfs/btree.c | 10 +- trunk/fs/hfs/catalog.c | 2 +- trunk/fs/hfs/dir.c | 12 +- trunk/fs/hfs/hfs_fs.h | 3 + trunk/fs/hfs/inode.c | 1 + trunk/fs/hfs/mdb.c | 22 +- trunk/fs/hfs/super.c | 40 +- trunk/fs/hfsplus/bfind.c | 3 +- trunk/fs/hfsplus/bnode.c | 11 +- trunk/fs/hfsplus/brec.c | 2 +- trunk/fs/hfsplus/btree.c | 37 +- trunk/fs/hfsplus/catalog.c | 44 +- trunk/fs/hfsplus/dir.c | 47 +- trunk/fs/hfsplus/extents.c | 6 +- trunk/fs/hfsplus/hfsplus_fs.h | 12 +- trunk/fs/hfsplus/hfsplus_raw.h | 13 +- trunk/fs/hfsplus/inode.c | 11 +- trunk/fs/hfsplus/options.c | 18 +- trunk/fs/hfsplus/super.c | 54 +- trunk/fs/hfsplus/unicode.c | 30 +- trunk/fs/hfsplus/wrapper.c | 17 +- trunk/fs/hugetlbfs/inode.c | 4 +- trunk/fs/inode.c | 2 +- trunk/fs/inotify.c | 3 +- trunk/fs/jbd/checkpoint.c | 2 +- trunk/fs/jbd/commit.c | 3 +- trunk/fs/jbd/transaction.c | 10 +- trunk/fs/jffs/intrep.c | 2 +- trunk/fs/libfs.c | 1 - trunk/fs/lockd/clntproc.c | 11 +- trunk/fs/namei.c | 185 +- trunk/fs/namespace.c | 58 +- trunk/fs/nfs/direct.c | 2 +- trunk/fs/nfs/nfsroot.c | 3 +- trunk/fs/nfsctl.c | 1 - trunk/fs/nfsd/nfs4proc.c | 57 +- trunk/fs/nfsd/nfs4recover.c | 10 +- trunk/fs/nfsd/nfs4state.c | 220 +- trunk/fs/nfsd/nfs4xdr.c | 10 +- trunk/fs/nfsd/nfsproc.c | 37 +- trunk/fs/nfsd/nfssvc.c | 76 +- trunk/fs/nfsd/vfs.c | 89 +- trunk/fs/ocfs2/buffer_head_io.c | 10 +- trunk/fs/ocfs2/cluster/heartbeat.c | 5 +- trunk/fs/ocfs2/cluster/tcp.c | 16 +- trunk/fs/ocfs2/dlm/dlmcommon.h | 1 - trunk/fs/ocfs2/dlm/dlmdomain.c | 18 +- trunk/fs/ocfs2/dlm/dlmmaster.c | 24 +- trunk/fs/ocfs2/dlm/dlmrecovery.c | 250 +- trunk/fs/ocfs2/dlm/dlmunlock.c | 13 - trunk/fs/ocfs2/dlm/userdlm.c | 2 +- trunk/fs/ocfs2/extent_map.c | 12 +- trunk/fs/ocfs2/file.c | 10 +- trunk/fs/ocfs2/inode.c | 6 +- trunk/fs/ocfs2/inode.h | 4 +- trunk/fs/ocfs2/journal.c | 32 +- trunk/fs/ocfs2/ocfs2.h | 3 +- trunk/fs/ocfs2/super.c | 11 +- trunk/fs/ocfs2/sysfile.c | 6 +- trunk/fs/ocfs2/uptodate.c | 12 +- trunk/fs/ocfs2/uptodate.h | 2 +- trunk/fs/open.c | 83 +- trunk/fs/proc/proc_misc.c | 2 +- trunk/fs/quota_v2.c | 2 +- trunk/fs/reiserfs/dir.c | 16 +- trunk/fs/reiserfs/file.c | 19 - trunk/fs/reiserfs/fix_node.c | 50 +- trunk/fs/reiserfs/hashes.c | 1 + trunk/fs/reiserfs/inode.c | 11 +- trunk/fs/reiserfs/journal.c | 140 +- trunk/fs/reiserfs/namei.c | 16 +- trunk/fs/reiserfs/procfs.c | 3 +- trunk/fs/reiserfs/super.c | 8 + trunk/fs/reiserfs/xattr.c | 128 +- trunk/fs/reiserfs/xattr_acl.c | 3 +- trunk/fs/select.c | 362 +-- trunk/fs/smbfs/dir.c | 5 +- trunk/fs/stat.c | 88 +- trunk/fs/super.c | 5 +- trunk/fs/udf/balloc.c | 7 +- trunk/fs/udf/namei.c | 4 +- trunk/fs/ufs/inode.c | 2 +- trunk/fs/ufs/super.c | 10 +- trunk/fs/ufs/truncate.c | 72 +- trunk/fs/xfs/linux-2.6/xfs_aops.c | 4 +- trunk/fs/xfs/linux-2.6/xfs_buf.c | 8 - trunk/fs/xfs/linux-2.6/xfs_iops.c | 52 +- trunk/include/acpi/acconfig.h | 24 +- trunk/include/acpi/acdebug.h | 2 +- trunk/include/acpi/acdisasm.h | 81 +- trunk/include/acpi/acdispat.h | 5 +- trunk/include/acpi/acevents.h | 8 +- trunk/include/acpi/acexcep.h | 2 +- trunk/include/acpi/acglobal.h | 23 +- trunk/include/acpi/achware.h | 2 +- trunk/include/acpi/acinterp.h | 48 +- trunk/include/acpi/aclocal.h | 112 +- trunk/include/acpi/acmacros.h | 201 +- trunk/include/acpi/acnames.h | 2 +- trunk/include/acpi/acnamesp.h | 4 +- trunk/include/acpi/acobject.h | 4 +- trunk/include/acpi/acopcode.h | 2 +- trunk/include/acpi/acoutput.h | 12 +- trunk/include/acpi/acparser.h | 2 +- trunk/include/acpi/acpi.h | 2 +- trunk/include/acpi/acpi_drivers.h | 4 +- trunk/include/acpi/acpiosxf.h | 6 +- trunk/include/acpi/acpixf.h | 13 +- trunk/include/acpi/acresrc.h | 390 +-- trunk/include/acpi/acstruct.h | 2 +- trunk/include/acpi/actables.h | 2 +- trunk/include/acpi/actbl.h | 8 +- trunk/include/acpi/actbl1.h | 2 +- trunk/include/acpi/actbl2.h | 2 +- trunk/include/acpi/actypes.h | 613 ++-- trunk/include/acpi/acutils.h | 82 +- trunk/include/acpi/amlcode.h | 2 +- trunk/include/acpi/amlresrc.h | 271 +- trunk/include/acpi/pdc_intel.h | 4 +- trunk/include/acpi/platform/acenv.h | 24 +- trunk/include/acpi/platform/acgcc.h | 10 +- trunk/include/acpi/platform/aclinux.h | 8 +- trunk/include/acpi/processor.h | 28 +- trunk/include/asm-alpha/dma-mapping.h | 1 - trunk/include/asm-alpha/system.h | 2 +- trunk/include/asm-arm/arch-omap/clock.h | 2 + trunk/include/asm-arm/arch-omap/io.h | 6 +- trunk/include/asm-arm/arch-pxa/pxa-regs.h | 14 - .../asm-arm/arch-s3c2410/debug-macro.S | 6 +- .../asm-arm/arch-s3c2410/h1940-latch.h | 64 - trunk/include/asm-arm/arch-s3c2410/hardware.h | 7 - trunk/include/asm-arm/arch-s3c2410/map.h | 38 - .../include/asm-arm/arch-s3c2410/regs-gpio.h | 22 - .../asm-arm/arch-s3c2410/regs-serial.h | 6 +- .../include/asm-arm/arch-s3c2410/uncompress.h | 6 +- trunk/include/asm-arm/checksum.h | 2 +- trunk/include/asm-arm/mach/map.h | 1 - trunk/include/asm-arm/mutex.h | 131 +- trunk/include/asm-arm/pgtable.h | 1 - trunk/include/asm-arm26/bitops.h | 4 +- trunk/include/asm-arm26/hardirq.h | 8 +- trunk/include/asm-arm26/posix_types.h | 1 - trunk/include/asm-arm26/system.h | 5 +- trunk/include/asm-cris/bitops.h | 2 +- trunk/include/asm-frv/bitops.h | 2 +- trunk/include/asm-frv/thread_info.h | 2 - trunk/include/asm-frv/unistd.h | 1 - trunk/include/asm-h8300/bitops.h | 2 +- trunk/include/asm-i386/acpi.h | 2 +- trunk/include/asm-i386/edac.h | 18 - trunk/include/asm-i386/futex.h | 2 +- trunk/include/asm-i386/page.h | 4 +- trunk/include/asm-i386/signal.h | 1 + trunk/include/asm-i386/system.h | 2 +- trunk/include/asm-i386/thread_info.h | 2 - trunk/include/asm-i386/topology.h | 9 - trunk/include/asm-i386/unistd.h | 19 +- trunk/include/asm-ia64/ide.h | 8 + trunk/include/asm-ia64/processor.h | 17 - trunk/include/asm-ia64/sal.h | 10 +- trunk/include/asm-ia64/semaphore.h | 8 +- trunk/include/asm-ia64/sn/bte.h | 23 +- trunk/include/asm-ia64/sn/intr.h | 38 +- trunk/include/asm-ia64/sn/sn_feature_sets.h | 14 +- trunk/include/asm-ia64/sn/xp.h | 3 +- trunk/include/asm-ia64/sn/xpc.h | 9 +- trunk/include/asm-ia64/system.h | 25 + trunk/include/asm-ia64/topology.h | 11 - trunk/include/asm-ia64/unistd.h | 17 +- trunk/include/asm-m68knommu/hardirq.h | 1 - trunk/include/asm-mips/abi.h | 4 +- trunk/include/asm-mips/bitops.h | 58 +- trunk/include/asm-mips/byteorder.h | 29 - trunk/include/asm-mips/cacheflush.h | 3 +- .../asm-mips/{mach-cobalt => cobalt}/cobalt.h | 0 .../{mach-cobalt => cobalt}/mach-gt64120.h | 0 trunk/include/asm-mips/hazards.h | 2 +- trunk/include/asm-mips/interrupt.h | 27 +- trunk/include/asm-mips/io.h | 35 +- trunk/include/asm-mips/mach-au1x00/au1000.h | 4 - .../mach-cobalt/cpu-feature-overrides.h | 56 - .../mach-ip32/cpu-feature-overrides.h | 2 +- trunk/include/asm-mips/r4kcache.h | 400 ++- trunk/include/asm-mips/reboot.h | 3 +- trunk/include/asm-mips/string.h | 22 + trunk/include/asm-mips/thread_info.h | 2 - trunk/include/asm-mips/tx4927/tx4927.h | 21 +- trunk/include/asm-mips/tx4927/tx4927_pci.h | 10 - trunk/include/asm-mips/uaccess.h | 71 +- trunk/include/asm-mips/unistd.h | 64 +- trunk/include/asm-parisc/atomic.h | 84 +- trunk/include/asm-parisc/cacheflush.h | 6 - trunk/include/asm-parisc/compat_ucontext.h | 3 +- trunk/include/asm-parisc/grfioctl.h | 2 +- trunk/include/asm-parisc/pci.h | 17 +- trunk/include/asm-parisc/pgalloc.h | 1 + trunk/include/asm-parisc/pgtable.h | 2 +- trunk/include/asm-parisc/rt_sigframe.h | 4 + trunk/include/asm-parisc/unistd.h | 21 +- trunk/include/asm-powerpc/compat.h | 5 - trunk/include/asm-powerpc/dma-mapping.h | 1 + trunk/include/asm-powerpc/kexec.h | 4 +- trunk/include/asm-powerpc/pmac_pfunc.h | 5 +- trunk/include/asm-powerpc/prom.h | 2 - trunk/include/asm-powerpc/smu.h | 5 - trunk/include/asm-powerpc/thread_info.h | 7 +- trunk/include/asm-powerpc/unistd.h | 7 +- trunk/include/asm-s390/bitops.h | 4 +- trunk/include/asm-s390/dasd.h | 15 +- trunk/include/asm-s390/io.h | 6 - trunk/include/asm-s390/qdio.h | 2 + trunk/include/asm-s390/setup.h | 10 +- trunk/include/asm-s390/smp.h | 1 - trunk/include/asm-s390/thread_info.h | 6 +- trunk/include/asm-s390/timer.h | 8 +- trunk/include/asm-s390/uaccess.h | 10 +- trunk/include/asm-s390/unistd.h | 27 +- trunk/include/asm-sh/bus-sh.h | 66 + trunk/include/asm-sh/cpu-sh3/mmu_context.h | 10 - trunk/include/asm-sh/cpu-sh4/mmu_context.h | 8 - trunk/include/asm-sh/ioctls.h | 2 +- trunk/include/asm-sh/irq-sh73180.h | 36 +- trunk/include/asm-sh/irq-sh7780.h | 23 + trunk/include/asm-sh/irq.h | 10 +- trunk/include/asm-sh/microdev/io.h | 53 + .../asm-sh/{microdev.h => microdev/irq.h} | 60 +- trunk/include/asm-sh/processor.h | 36 +- trunk/include/asm-sh64/ioctls.h | 2 +- trunk/include/asm-sparc/oplib.h | 2 - trunk/include/asm-sparc/thread_info.h | 5 +- trunk/include/asm-sparc/unistd.h | 23 +- trunk/include/asm-sparc64/oplib.h | 2 - trunk/include/asm-sparc64/spinlock.h | 24 +- trunk/include/asm-sparc64/thread_info.h | 6 +- trunk/include/asm-sparc64/unistd.h | 24 +- trunk/include/asm-um/io.h | 16 - trunk/include/asm-um/ldt-x86_64.h | 12 +- trunk/include/asm-um/smp.h | 2 - trunk/include/asm-um/thread_info.h | 13 +- trunk/include/asm-um/unistd.h | 1 - trunk/include/asm-v850/bitops.h | 2 +- trunk/include/asm-x86_64/apic.h | 1 - trunk/include/asm-x86_64/cpufeature.h | 2 +- trunk/include/asm-x86_64/edac.h | 18 - trunk/include/asm-x86_64/hardirq.h | 21 +- trunk/include/asm-x86_64/hpet.h | 2 - trunk/include/asm-x86_64/ia32_unistd.h | 18 +- trunk/include/asm-x86_64/kexec.h | 3 +- trunk/include/asm-x86_64/mpspec.h | 2 +- trunk/include/asm-x86_64/numa.h | 7 - trunk/include/asm-x86_64/proto.h | 11 - trunk/include/asm-x86_64/system.h | 2 +- trunk/include/asm-x86_64/topology.h | 9 - trunk/include/asm-x86_64/unistd.h | 35 +- trunk/include/asm-xtensa/futex.h | 1 - trunk/include/linux/acpi.h | 2 +- trunk/include/linux/agpgart.h | 3 +- trunk/include/linux/bitops.h | 2 +- trunk/include/linux/blkdev.h | 6 +- trunk/include/linux/compat.h | 20 - trunk/include/linux/configfs.h | 2 +- trunk/include/linux/cpumask.h | 3 +- trunk/include/linux/dcache.h | 3 +- trunk/include/linux/device-mapper.h | 2 +- trunk/include/linux/dvb/video.h | 2 +- trunk/include/linux/elevator.h | 1 - trunk/include/linux/elfcore.h | 1 - trunk/include/linux/fcntl.h | 7 - trunk/include/linux/fs.h | 15 +- trunk/include/linux/fuse.h | 16 +- trunk/include/linux/hrtimer.h | 6 +- trunk/include/linux/i2c.h | 3 - trunk/include/linux/i2o.h | 6 +- trunk/include/linux/ide.h | 2 + trunk/include/linux/if_ether.h | 1 - trunk/include/linux/io.h | 25 - trunk/include/linux/ioc3.h | 2 +- trunk/include/linux/jbd.h | 5 +- trunk/include/linux/kbd_kern.h | 7 - trunk/include/linux/kernel.h | 1 - trunk/include/linux/kexec.h | 1 - trunk/include/linux/ktime.h | 6 - trunk/include/linux/list.h | 14 +- trunk/include/linux/lockd/lockd.h | 2 +- trunk/include/linux/mempolicy.h | 1 - trunk/include/linux/mm.h | 2 +- trunk/include/linux/mm_inline.h | 21 + trunk/include/linux/mmc/mmc.h | 35 +- trunk/include/linux/mmc/protocol.h | 2 +- trunk/include/linux/mmzone.h | 25 +- trunk/include/linux/mtd/map.h | 1 + trunk/include/linux/namei.h | 7 +- trunk/include/linux/namespace.h | 1 - trunk/include/linux/netfilter/x_tables.h | 16 +- .../linux/netfilter_ipv4/ipt_connbytes.h | 4 +- .../include/linux/netfilter_ipv4/ipt_policy.h | 22 +- .../linux/netfilter_ipv6/ip6t_policy.h | 22 +- trunk/include/linux/netlink.h | 3 +- trunk/include/linux/nfsd/nfsd.h | 2 +- trunk/include/linux/nfsd/xdr4.h | 5 +- trunk/include/linux/nodemask.h | 1 + trunk/include/linux/parport.h | 6 - trunk/include/linux/pci.h | 2 + trunk/include/linux/pci_ids.h | 24 +- trunk/include/linux/pktcdvd.h | 8 +- trunk/include/linux/poll.h | 6 +- trunk/include/linux/posix-timers.h | 1 + trunk/include/linux/quotaops.h | 1 + trunk/include/linux/rcupdate.h | 5 +- trunk/include/linux/reboot.h | 3 +- trunk/include/linux/reiserfs_acl.h | 6 +- trunk/include/linux/reiserfs_fs.h | 16 + trunk/include/linux/reiserfs_fs_sb.h | 1 + trunk/include/linux/reiserfs_xattr.h | 2 + trunk/include/linux/rmap.h | 5 +- trunk/include/linux/sched.h | 3 +- trunk/include/linux/security.h | 23 +- trunk/include/linux/serial_8250.h | 2 +- trunk/include/linux/serial_core.h | 72 +- trunk/include/linux/slab.h | 7 - trunk/include/linux/smp.h | 1 + trunk/include/linux/sunrpc/auth.h | 10 +- trunk/include/linux/sunrpc/svc.h | 1 - trunk/include/linux/suspend.h | 8 +- trunk/include/linux/swap.h | 21 - trunk/include/linux/syscalls.h | 54 +- trunk/include/linux/sysctl.h | 2 - trunk/include/linux/time.h | 29 +- trunk/include/linux/tipc_config.h | 7 +- trunk/include/linux/topology.h | 8 - trunk/include/linux/tty.h | 4 - trunk/include/linux/tty_flip.h | 9 +- trunk/include/linux/types.h | 2 - trunk/include/linux/ufs_fs.h | 14 +- trunk/include/linux/ufs_fs_sb.h | 2 +- trunk/include/linux/usb_ch9.h | 6 +- trunk/include/linux/videodev2.h | 7 +- trunk/include/net/bluetooth/rfcomm.h | 2 +- trunk/include/net/ieee80211.h | 4 +- trunk/include/net/irda/irda.h | 6 +- trunk/include/net/irda/irlap.h | 3 - .../net/netfilter/nf_conntrack_l3proto.h | 15 +- trunk/include/net/route.h | 5 +- trunk/include/net/sctp/sctp.h | 2 - trunk/include/net/sctp/structs.h | 91 +- trunk/include/net/sock.h | 8 +- trunk/include/scsi/scsi_device.h | 2 +- trunk/include/scsi/scsi_host.h | 1 + trunk/include/scsi/scsi_transport_spi.h | 1 - trunk/init/Kconfig | 12 + trunk/init/initramfs.c | 24 +- trunk/init/main.c | 1 + trunk/ipc/mqueue.c | 3 +- trunk/ipc/shm.c | 1 - trunk/kernel/audit.c | 2 +- trunk/kernel/auditsc.c | 2 +- trunk/kernel/compat.c | 29 +- trunk/kernel/cpuset.c | 2 +- trunk/kernel/fork.c | 396 +-- trunk/kernel/hrtimer.c | 70 +- trunk/kernel/intermodule.c | 3 - trunk/kernel/itimer.c | 11 +- trunk/kernel/kprobes.c | 36 +- trunk/kernel/module.c | 6 +- trunk/kernel/panic.c | 1 - trunk/kernel/posix-timers.c | 53 +- trunk/kernel/power/console.c | 16 +- trunk/kernel/power/disk.c | 15 +- trunk/kernel/power/main.c | 4 +- trunk/kernel/power/power.h | 15 +- trunk/kernel/power/swsusp.c | 14 +- trunk/kernel/rcutorture.c | 10 +- trunk/kernel/sched.c | 157 +- trunk/kernel/signal.c | 37 +- trunk/kernel/sys.c | 27 +- trunk/kernel/sysctl.c | 21 - trunk/kernel/time.c | 15 +- trunk/kernel/timer.c | 2 +- trunk/kernel/user.c | 32 +- trunk/lib/Makefile | 2 +- trunk/lib/int_sqrt.c | 2 +- trunk/lib/iomap_copy.c | 42 - trunk/lib/kobject.c | 9 - trunk/lib/kobject_uevent.c | 2 +- trunk/lib/spinlock_debug.c | 6 +- trunk/lib/ts_bm.c | 40 +- trunk/mm/filemap.c | 1 - trunk/mm/hugetlb.c | 10 +- trunk/mm/memory.c | 7 - trunk/mm/mempolicy.c | 266 +- trunk/mm/oom_kill.c | 1 - trunk/mm/page-writeback.c | 7 +- trunk/mm/page_alloc.c | 33 +- trunk/mm/rmap.c | 53 +- trunk/mm/shmem.c | 8 - trunk/mm/slab.c | 879 +++--- trunk/mm/slob.c | 2 +- trunk/mm/swap.c | 58 +- trunk/mm/swap_state.c | 1 - trunk/mm/swapfile.c | 33 +- trunk/mm/vmscan.c | 553 +--- trunk/net/802/p8023.c | 2 - trunk/net/802/psnap.c | 2 - trunk/net/Kconfig | 9 +- trunk/net/atm/signaling.c | 3 +- trunk/net/bluetooth/hci_sock.c | 10 +- trunk/net/bluetooth/rfcomm/core.c | 13 +- trunk/net/bridge/br_if.c | 105 +- trunk/net/bridge/br_input.c | 19 +- trunk/net/bridge/br_netfilter.c | 57 +- trunk/net/bridge/br_private.h | 5 +- trunk/net/bridge/br_stp_bpdu.c | 30 +- trunk/net/bridge/br_sysfs_if.c | 50 +- trunk/net/bridge/netfilter/ebt_ulog.c | 10 +- trunk/net/bridge/netfilter/ebtables.c | 7 - trunk/net/core/datagram.c | 81 +- trunk/net/core/dev.c | 7 +- trunk/net/core/filter.c | 6 +- trunk/net/core/pktgen.c | 5 +- trunk/net/core/rtnetlink.c | 2 +- trunk/net/core/skbuff.c | 8 +- trunk/net/core/utils.c | 4 +- trunk/net/dccp/ccids/lib/tfrc_equation.c | 1 + trunk/net/dccp/ipv4.c | 3 +- trunk/net/dccp/ipv6.c | 1 - trunk/net/ieee80211/ieee80211_rx.c | 26 +- trunk/net/ieee80211/ieee80211_wx.c | 12 +- trunk/net/ipv4/devinet.c | 2 +- trunk/net/ipv4/fib_semantics.c | 2 +- trunk/net/ipv4/icmp.c | 7 +- trunk/net/ipv4/igmp.c | 154 +- trunk/net/ipv4/multipath_wrandom.c | 8 +- trunk/net/ipv4/netfilter/arp_tables.c | 7 - .../net/ipv4/netfilter/ip_conntrack_netlink.c | 3 +- trunk/net/ipv4/netfilter/ip_conntrack_tftp.c | 1 - trunk/net/ipv4/netfilter/ip_nat_standalone.c | 4 +- trunk/net/ipv4/netfilter/ip_tables.c | 7 - trunk/net/ipv4/netfilter/ipt_ULOG.c | 26 +- trunk/net/ipv4/netfilter/ipt_policy.c | 11 +- trunk/net/ipv4/proc.c | 2 +- trunk/net/ipv4/raw.c | 2 +- trunk/net/ipv4/route.c | 3 +- trunk/net/ipv4/tcp_htcp.c | 1 + trunk/net/ipv4/tcp_input.c | 3 +- trunk/net/ipv4/tcp_ipv4.c | 3 +- trunk/net/ipv4/xfrm4_policy.c | 1 + trunk/net/ipv6/addrconf.c | 9 +- trunk/net/ipv6/af_inet6.c | 6 + trunk/net/ipv6/mcast.c | 56 +- trunk/net/ipv6/netfilter/ip6_tables.c | 7 - trunk/net/ipv6/netfilter/ip6t_policy.c | 7 +- trunk/net/ipv6/proc.c | 2 +- trunk/net/ipv6/raw.c | 6 +- trunk/net/ipv6/tcp_ipv6.c | 1 - trunk/net/ipv6/xfrm6_policy.c | 1 + trunk/net/irda/irda_device.c | 4 +- trunk/net/irda/irnet/irnet_irda.c | 2 +- trunk/net/key/af_key.c | 2 - trunk/net/netfilter/Kconfig | 4 +- trunk/net/netfilter/nf_conntrack_core.c | 2 +- trunk/net/netfilter/nf_conntrack_ftp.c | 2 + trunk/net/netfilter/nf_conntrack_netlink.c | 3 +- trunk/net/netfilter/nfnetlink_log.c | 20 +- trunk/net/netfilter/nfnetlink_queue.c | 3 +- trunk/net/netlink/af_netlink.c | 7 +- trunk/net/netlink/genetlink.c | 11 +- trunk/net/packet/af_packet.c | 16 +- trunk/net/sctp/input.c | 75 +- trunk/net/sctp/inqueue.c | 4 +- trunk/net/sctp/output.c | 2 +- trunk/net/sctp/outqueue.c | 12 +- trunk/net/sctp/proc.c | 32 +- trunk/net/sctp/sm_make_chunk.c | 16 +- trunk/net/sctp/sm_sideeffect.c | 4 +- trunk/net/sctp/sm_statefuns.c | 10 +- trunk/net/sctp/socket.c | 8 +- trunk/net/sctp/sysctl.c | 7 +- trunk/net/sctp/transport.c | 2 +- trunk/net/socket.c | 2 +- trunk/net/sunrpc/auth.c | 25 +- trunk/net/sunrpc/auth_gss/auth_gss.c | 40 +- trunk/net/sunrpc/auth_gss/svcauth_gss.c | 38 +- trunk/net/sunrpc/auth_unix.c | 6 +- trunk/net/sunrpc/rpc_pipe.c | 102 +- trunk/net/sunrpc/sched.c | 9 +- trunk/net/sunrpc/svcsock.c | 2 - trunk/net/tipc/Kconfig | 7 +- trunk/net/tipc/addr.c | 10 +- trunk/net/tipc/addr.h | 4 +- trunk/net/tipc/bcast.c | 166 +- trunk/net/tipc/bcast.h | 44 +- trunk/net/tipc/bearer.c | 189 +- trunk/net/tipc/bearer.h | 40 +- trunk/net/tipc/cluster.c | 154 +- trunk/net/tipc/cluster.h | 40 +- trunk/net/tipc/config.c | 218 +- trunk/net/tipc/config.h | 41 +- trunk/net/tipc/core.c | 87 +- trunk/net/tipc/core.h | 35 +- trunk/net/tipc/dbg.c | 112 +- trunk/net/tipc/dbg.h | 18 +- trunk/net/tipc/discover.c | 52 +- trunk/net/tipc/discover.h | 18 +- trunk/net/tipc/eth_media.c | 20 +- trunk/net/tipc/handler.c | 6 +- trunk/net/tipc/link.c | 605 ++-- trunk/net/tipc/link.h | 73 +- trunk/net/tipc/msg.c | 19 +- trunk/net/tipc/msg.h | 18 +- trunk/net/tipc/name_distr.c | 92 +- trunk/net/tipc/name_distr.h | 10 +- trunk/net/tipc/name_table.c | 206 +- trunk/net/tipc/name_table.h | 26 +- trunk/net/tipc/net.c | 126 +- trunk/net/tipc/net.h | 20 +- trunk/net/tipc/netlink.c | 16 +- trunk/net/tipc/node.c | 215 +- trunk/net/tipc/node.h | 50 +- trunk/net/tipc/node_subscr.c | 20 +- trunk/net/tipc/node_subscr.h | 6 +- trunk/net/tipc/port.c | 274 +- trunk/net/tipc/port.h | 60 +- trunk/net/tipc/ref.c | 72 +- trunk/net/tipc/ref.h | 38 +- trunk/net/tipc/socket.c | 12 +- trunk/net/tipc/subscr.c | 58 +- trunk/net/tipc/subscr.h | 24 +- trunk/net/tipc/user_reg.c | 22 +- trunk/net/tipc/user_reg.h | 8 +- trunk/net/tipc/zone.c | 40 +- trunk/net/tipc/zone.h | 20 +- trunk/net/xfrm/xfrm_policy.c | 5 +- trunk/scripts/kconfig/lxdialog/Makefile | 7 +- .../kconfig/lxdialog/check-lxdialog.sh | 14 +- trunk/scripts/kernel-doc | 80 +- trunk/security/keys/keyctl.c | 15 +- trunk/security/seclvl.c | 4 +- trunk/security/selinux/Kconfig | 2 +- trunk/security/selinux/Makefile | 4 +- trunk/security/selinux/avc.c | 2 + trunk/security/selinux/hooks.c | 122 +- trunk/security/selinux/include/objsec.h | 8 + trunk/sound/arm/aaci.c | 14 +- trunk/sound/core/info.c | 33 +- trunk/sound/drivers/serial-u16550.c | 2 +- trunk/sound/isa/cmi8330.c | 6 - trunk/sound/isa/cs423x/cs4236.c | 13 +- trunk/sound/isa/es18xx.c | 6 +- trunk/sound/isa/gus/gusclassic.c | 2 +- trunk/sound/isa/opl3sa2.c | 12 +- trunk/sound/isa/opti9xx/opti92x-ad1848.c | 2 +- trunk/sound/isa/sb/sb16.c | 4 +- trunk/sound/isa/sscape.c | 6 +- trunk/sound/isa/wavefront/wavefront.c | 7 +- trunk/sound/isa/wavefront/wavefront_synth.c | 2 +- trunk/sound/oss/au1550_ac97.c | 12 +- trunk/sound/oss/dmasound/tas_common.h | 16 +- trunk/sound/oss/emu10k1/recmgr.c | 2 +- trunk/sound/oss/trident.c | 18 +- trunk/sound/pci/ac97/ac97_patch.c | 53 +- trunk/sound/pci/ali5451/ali5451.c | 2 +- trunk/sound/pci/au88x0/au88x0_eq.c | 2 +- trunk/sound/pci/bt87x.c | 4 +- trunk/sound/pci/ca0106/ca0106_main.c | 12 +- trunk/sound/pci/cs46xx/dsp_spos_scb_lib.c | 2 +- trunk/sound/pci/cs5535audio/cs5535audio.c | 6 +- trunk/sound/pci/emu10k1/emumixer.c | 10 +- trunk/sound/pci/hda/hda_intel.c | 2 - trunk/sound/pci/hda/patch_realtek.c | 11 +- trunk/sound/pci/hda/patch_si3054.c | 1 - trunk/sound/pci/hda/patch_sigmatel.c | 176 +- trunk/sound/pci/intel8x0.c | 15 +- trunk/sound/pci/pcxhr/pcxhr.c | 9 +- trunk/sound/pci/rme9652/hdspm.c | 6 +- trunk/sound/pci/trident/trident.c | 8 +- trunk/sound/pci/via82xx.c | 5 - trunk/sound/pci/ymfpci/ymfpci_main.c | 2 - trunk/sound/ppc/pmac.c | 5 +- trunk/sound/ppc/tumbler.c | 19 +- trunk/sound/usb/usbaudio.c | 31 +- 1967 files changed, 31050 insertions(+), 54780 deletions(-) delete mode 100644 trunk/Documentation/cputopology.txt delete mode 100644 trunk/Documentation/drivers/edac/edac.txt delete mode 100644 trunk/Documentation/hwmon/f71805f rename trunk/Documentation/i2c/busses/{i2c-sis96x => i2c-sis69x} (98%) delete mode 100644 trunk/Documentation/powerpc/booting-without-of.txt delete mode 100644 trunk/Documentation/scsi/ChangeLog.megaraid_sas delete mode 100644 trunk/Documentation/unshare.txt delete mode 100644 trunk/Documentation/usb/et61x251.txt delete mode 100644 trunk/Documentation/vm/page_migration delete mode 100644 trunk/arch/arm/mach-s3c2410/s3c2400-gpio.c delete mode 100644 trunk/arch/arm/mach-s3c2410/s3c2400.h delete mode 100644 trunk/arch/arm/mach-s3c2410/s3c2410-gpio.c delete mode 100644 trunk/arch/i386/kernel/acpi/processor.c delete mode 100644 trunk/arch/ia64/kernel/acpi-processor.c create mode 100644 trunk/arch/sh/boards/unknown/io.c create mode 100644 trunk/arch/sh/boards/unknown/mach.c create mode 100644 trunk/arch/sh/kernel/cpu/bus.c delete mode 100644 trunk/arch/sparc64/boot/.gitignore delete mode 100644 trunk/arch/um/include/longjmp.h delete mode 100644 trunk/arch/um/include/skas/mmu-skas.h delete mode 100644 trunk/arch/um/include/skas/mode-skas.h delete mode 100644 trunk/arch/um/include/skas/skas.h create mode 100644 trunk/arch/um/include/time_user.h delete mode 100644 trunk/arch/um/include/tt/mmu-tt.h delete mode 100644 trunk/arch/um/include/tt/mode-tt.h delete mode 100644 trunk/arch/um/include/tt/mode_kern_tt.h rename trunk/arch/um/{include/skas => kernel/skas/include}/mm_id.h (100%) create mode 100644 trunk/arch/um/kernel/skas/include/mmu-skas.h create mode 100644 trunk/arch/um/kernel/skas/include/mode-skas.h rename trunk/arch/um/{include/skas/mode_kern_skas.h => kernel/skas/include/mode_kern-skas.h} (77%) rename trunk/arch/um/{include/skas => kernel/skas/include}/proc_mm.h (60%) create mode 100644 trunk/arch/um/kernel/skas/include/skas.h rename trunk/arch/um/{include/skas => kernel/skas/include}/stub-data.h (100%) rename trunk/arch/um/{include/skas => kernel/skas/include}/uaccess-skas.h (63%) rename trunk/arch/um/{os-Linux/skas/mem.c => kernel/skas/mem_user.c} (52%) rename trunk/arch/um/{os-Linux => kernel}/skas/process.c (72%) rename trunk/arch/um/{include/tt => kernel/tt/include}/debug.h (99%) create mode 100644 trunk/arch/um/kernel/tt/include/mmu-tt.h rename trunk/arch/um/{include/tt => kernel/tt/include}/tt.h (73%) rename trunk/arch/um/{include/tt => kernel/tt/include}/uaccess-tt.h (80%) rename trunk/arch/um/{os-Linux/util.c => kernel/user_util.c} (56%) delete mode 100644 trunk/arch/x86_64/kernel/acpi/processor.c delete mode 100644 trunk/arch/x86_64/lib/iomap_copy.S delete mode 100644 trunk/drivers/acpi/resources/rsinfo.c delete mode 100644 trunk/drivers/acpi/utilities/utresrc.c delete mode 100644 trunk/drivers/base/topology.c delete mode 100644 trunk/drivers/edac/Kconfig delete mode 100644 trunk/drivers/edac/Makefile delete mode 100644 trunk/drivers/edac/amd76x_edac.c delete mode 100644 trunk/drivers/edac/e752x_edac.c delete mode 100644 trunk/drivers/edac/e7xxx_edac.c delete mode 100644 trunk/drivers/edac/edac_mc.c delete mode 100644 trunk/drivers/edac/edac_mc.h delete mode 100644 trunk/drivers/edac/i82860_edac.c delete mode 100644 trunk/drivers/edac/i82875p_edac.c delete mode 100644 trunk/drivers/edac/r82600_edac.c delete mode 100644 trunk/drivers/hwmon/f71805f.c delete mode 100644 trunk/drivers/input/misc/ixp4xx-beeper.c delete mode 100644 trunk/drivers/macintosh/windfarm_max6690_sensor.c delete mode 100644 trunk/drivers/macintosh/windfarm_pm112.c delete mode 100644 trunk/drivers/macintosh/windfarm_smu_sat.c create mode 100644 trunk/drivers/media/dvb/frontends/at76c651.c create mode 100644 trunk/drivers/media/dvb/frontends/at76c651.h create mode 100644 trunk/drivers/media/dvb/frontends/nxt2002.c create mode 100644 trunk/drivers/media/dvb/frontends/nxt2002.h create mode 100644 trunk/drivers/media/dvb/frontends/tda80xx.c create mode 100644 trunk/drivers/media/dvb/frontends/tda80xx.h delete mode 100644 trunk/drivers/parport/parport_ip32.c delete mode 100644 trunk/drivers/s390/block/dasd_eer.c delete mode 100644 trunk/drivers/usb/media/et61x251.h delete mode 100644 trunk/drivers/usb/media/et61x251_core.c delete mode 100644 trunk/drivers/usb/media/et61x251_sensor.h delete mode 100644 trunk/drivers/usb/media/et61x251_tas5130d1b.c delete mode 100644 trunk/drivers/video/backlight/hp680_bl.c delete mode 100644 trunk/fs/9p/vfs_addr.c delete mode 100644 trunk/fs/cifs/cifsacl.h delete mode 100644 trunk/include/asm-arm/arch-s3c2410/h1940-latch.h delete mode 100644 trunk/include/asm-i386/edac.h rename trunk/include/asm-mips/{mach-cobalt => cobalt}/cobalt.h (100%) rename trunk/include/asm-mips/{mach-cobalt => cobalt}/mach-gt64120.h (100%) delete mode 100644 trunk/include/asm-mips/mach-cobalt/cpu-feature-overrides.h create mode 100644 trunk/include/asm-sh/bus-sh.h create mode 100644 trunk/include/asm-sh/microdev/io.h rename trunk/include/asm-sh/{microdev.h => microdev/irq.h} (65%) delete mode 100644 trunk/include/asm-x86_64/edac.h delete mode 100644 trunk/include/asm-xtensa/futex.h delete mode 100644 trunk/include/linux/io.h delete mode 100644 trunk/lib/iomap_copy.c diff --git a/[refs] b/[refs] index 40762828bc76..0c9bcceaf074 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: b4d9eda028e8becbb5057b554e63eea12e496a88 +refs/heads/master: e4472cb3706ceea42797ae1dc79d624026986694 diff --git a/trunk/CREDITS b/trunk/CREDITS index 6957ef4efab3..8e577ce4abeb 100644 --- a/trunk/CREDITS +++ b/trunk/CREDITS @@ -3101,7 +3101,7 @@ S: Minto, NSW, 2566 S: Australia N: Stephen Smalley -E: sds@tycho.nsa.gov +E: sds@epoch.ncsc.mil D: portions of the Linux Security Module (LSM) framework and security modules N: Chris Smith diff --git a/trunk/Documentation/RCU/RTFP.txt b/trunk/Documentation/RCU/RTFP.txt index 6221464d1a7e..fcbcbc35b122 100644 --- a/trunk/Documentation/RCU/RTFP.txt +++ b/trunk/Documentation/RCU/RTFP.txt @@ -90,20 +90,16 @@ at OLS. The resulting abundance of RCU patches was presented the following year [McKenney02a], and use of RCU in dcache was first described that same year [Linder02a]. -Also in 2002, Michael [Michael02b,Michael02a] presented "hazard-pointer" -techniques that defer the destruction of data structures to simplify -non-blocking synchronization (wait-free synchronization, lock-free -synchronization, and obstruction-free synchronization are all examples of -non-blocking synchronization). In particular, this technique eliminates -locking, reduces contention, reduces memory latency for readers, and -parallelizes pipeline stalls and memory latency for writers. However, -these techniques still impose significant read-side overhead in the -form of memory barriers. Researchers at Sun worked along similar lines -in the same timeframe [HerlihyLM02,HerlihyLMS03]. These techniques -can be thought of as inside-out reference counts, where the count is -represented by the number of hazard pointers referencing a given data -structure (rather than the more conventional counter field within the -data structure itself). +Also in 2002, Michael [Michael02b,Michael02a] presented techniques +that defer the destruction of data structures to simplify non-blocking +synchronization (wait-free synchronization, lock-free synchronization, +and obstruction-free synchronization are all examples of non-blocking +synchronization). In particular, this technique eliminates locking, +reduces contention, reduces memory latency for readers, and parallelizes +pipeline stalls and memory latency for writers. However, these +techniques still impose significant read-side overhead in the form of +memory barriers. Researchers at Sun worked along similar lines in the +same timeframe [HerlihyLM02,HerlihyLMS03]. In 2003, the K42 group described how RCU could be used to create hot-pluggable implementations of operating-system functions. Later that @@ -117,6 +113,7 @@ number of operating-system kernels [PaulEdwardMcKenneyPhD], a paper describing how to make RCU safe for soft-realtime applications [Sarma04c], and a paper describing SELinux performance with RCU [JamesMorris04b]. + 2005 has seen further adaptation of RCU to realtime use, permitting preemption of RCU realtime critical sections [PaulMcKenney05a, PaulMcKenney05b]. diff --git a/trunk/Documentation/RCU/checklist.txt b/trunk/Documentation/RCU/checklist.txt index 49e27cc19385..e118a7c1a092 100644 --- a/trunk/Documentation/RCU/checklist.txt +++ b/trunk/Documentation/RCU/checklist.txt @@ -177,9 +177,3 @@ over a rather long period of time, but improvements are always welcome! If you want to wait for some of these other things, you might instead need to use synchronize_irq() or synchronize_sched(). - -12. Any lock acquired by an RCU callback must be acquired elsewhere - with irq disabled, e.g., via spin_lock_irqsave(). Failing to - disable irq on a given acquisition of that lock will result in - deadlock as soon as the RCU callback happens to interrupt that - acquisition's critical section. diff --git a/trunk/Documentation/RCU/listRCU.txt b/trunk/Documentation/RCU/listRCU.txt index 1fd175368a87..f8a54fa0d8ab 100644 --- a/trunk/Documentation/RCU/listRCU.txt +++ b/trunk/Documentation/RCU/listRCU.txt @@ -232,7 +232,7 @@ entry does not exist. For this to be helpful, the search function must return holding the per-entry spinlock, as ipc_lock() does in fact do. Quick Quiz: Why does the search function need to return holding the - per-entry lock for this deleted-flag technique to be helpful? +per-entry lock for this deleted-flag technique to be helpful? If the system-call audit module were to ever need to reject stale data, one way to accomplish this would be to add a "deleted" flag and a "lock" @@ -275,8 +275,8 @@ flag under the spinlock as follows: { struct audit_entry *e; - /* Do not need to use the _rcu iterator here, since this - * is the only deletion routine. */ + /* Do not use the _rcu iterator here, since this is the only + * deletion routine. */ list_for_each_entry(e, list, list) { if (!audit_compare_rule(rule, &e->rule)) { spin_lock(&e->lock); @@ -304,12 +304,9 @@ function to reject newly deleted data. Answer to Quick Quiz - Why does the search function need to return holding the per-entry - lock for this deleted-flag technique to be helpful? - - If the search function drops the per-entry lock before returning, - then the caller will be processing stale data in any case. If it - is really OK to be processing stale data, then you don't need a - "deleted" flag. If processing stale data really is a problem, - then you need to hold the per-entry lock across all of the code - that uses the value that was returned. + +If the search function drops the per-entry lock before returning, then +the caller will be processing stale data in any case. If it is really +OK to be processing stale data, then you don't need a "deleted" flag. +If processing stale data really is a problem, then you need to hold the +per-entry lock across all of the code that uses the value looked up. diff --git a/trunk/Documentation/RCU/rcu.txt b/trunk/Documentation/RCU/rcu.txt index 02e27bf1d365..6fa092251586 100644 --- a/trunk/Documentation/RCU/rcu.txt +++ b/trunk/Documentation/RCU/rcu.txt @@ -111,11 +111,6 @@ o What are all these files in this directory? You are reading it! - rcuref.txt - - Describes how to combine use of reference counts - with RCU. - whatisRCU.txt Overview of how the RCU implementation works. Along diff --git a/trunk/Documentation/RCU/rcuref.txt b/trunk/Documentation/RCU/rcuref.txt index 451de2ad8329..3f60db41b2f0 100644 --- a/trunk/Documentation/RCU/rcuref.txt +++ b/trunk/Documentation/RCU/rcuref.txt @@ -1,7 +1,7 @@ -Reference-count design for elements of lists/arrays protected by RCU. +Refcounter design for elements of lists/arrays protected by RCU. -Reference counting on elements of lists which are protected by traditional -reader/writer spinlocks or semaphores are straightforward: +Refcounting on elements of lists which are protected by traditional +reader/writer spinlocks or semaphores are straight forward as in: 1. 2. add() search_and_reference() @@ -28,12 +28,12 @@ release_referenced() delete() ... } -If this list/array is made lock free using RCU as in changing the -write_lock() in add() and delete() to spin_lock and changing read_lock +If this list/array is made lock free using rcu as in changing the +write_lock in add() and delete() to spin_lock and changing read_lock in search_and_reference to rcu_read_lock(), the atomic_get in search_and_reference could potentially hold reference to an element which -has already been deleted from the list/array. Use atomic_inc_not_zero() -in this scenario as follows: +has already been deleted from the list/array. atomic_inc_not_zero takes +care of this scenario. search_and_reference should look as; 1. 2. add() search_and_reference() @@ -51,16 +51,17 @@ add() search_and_reference() release_referenced() delete() { { ... write_lock(&list_lock); - if (atomic_dec_and_test(&el->rc)) ... - call_rcu(&el->head, el_free); delete_element - ... write_unlock(&list_lock); -} ... + atomic_dec(&el->rc, relfunc) ... + ... delete_element +} write_unlock(&list_lock); + ... if (atomic_dec_and_test(&el->rc)) call_rcu(&el->head, el_free); ... } -Sometimes, a reference to the element needs to be obtained in the -update (write) stream. In such cases, atomic_inc_not_zero() might be -overkill, since we hold the update-side spinlock. One might instead -use atomic_inc() in such cases. +Sometimes, reference to the element need to be obtained in the +update (write) stream. In such cases, atomic_inc_not_zero might be an +overkill since the spinlock serialising list updates are held. atomic_inc +is to be used in such cases. + diff --git a/trunk/Documentation/RCU/whatisRCU.txt b/trunk/Documentation/RCU/whatisRCU.txt index 5ed85af88789..15da16861fa3 100644 --- a/trunk/Documentation/RCU/whatisRCU.txt +++ b/trunk/Documentation/RCU/whatisRCU.txt @@ -200,11 +200,10 @@ rcu_assign_pointer() the new value, and also executes any memory-barrier instructions required for a given CPU architecture. - Perhaps just as important, it serves to document (1) which - pointers are protected by RCU and (2) the point at which a - given structure becomes accessible to other CPUs. That said, - rcu_assign_pointer() is most frequently used indirectly, via - the _rcu list-manipulation primitives such as list_add_rcu(). + Perhaps more important, it serves to document which pointers + are protected by RCU. That said, rcu_assign_pointer() is most + frequently used indirectly, via the _rcu list-manipulation + primitives such as list_add_rcu(). rcu_dereference() @@ -259,11 +258,9 @@ rcu_dereference() locking. As with rcu_assign_pointer(), an important function of - rcu_dereference() is to document which pointers are protected by - RCU, in particular, flagging a pointer that is subject to changing - at any time, including immediately after the rcu_dereference(). - And, again like rcu_assign_pointer(), rcu_dereference() is - typically used indirectly, via the _rcu list-manipulation + rcu_dereference() is to document which pointers are protected + by RCU. And, again like rcu_assign_pointer(), rcu_dereference() + is typically used indirectly, via the _rcu list-manipulation primitives, such as list_for_each_entry_rcu(). The following diagram shows how each API communicates among the @@ -330,7 +327,7 @@ for specialized uses, but are relatively uncommon. 3. WHAT ARE SOME EXAMPLE USES OF CORE RCU API? This section shows a simple use of the core RCU API to protect a -global pointer to a dynamically allocated structure. More-typical +global pointer to a dynamically allocated structure. More typical uses of RCU may be found in listRCU.txt, arrayRCU.txt, and NMI-RCU.txt. struct foo { @@ -413,8 +410,6 @@ o Use synchronize_rcu() -after- removing a data element from an data item. See checklist.txt for additional rules to follow when using RCU. -And again, more-typical uses of RCU may be found in listRCU.txt, -arrayRCU.txt, and NMI-RCU.txt. 4. WHAT IF MY UPDATING THREAD CANNOT BLOCK? @@ -518,7 +513,7 @@ production-quality implementation, and see: for papers describing the Linux kernel RCU implementation. The OLS'01 and OLS'02 papers are a good introduction, and the dissertation provides -more details on the current implementation as of early 2004. +more details on the current implementation. 5A. "TOY" IMPLEMENTATION #1: LOCKING @@ -773,6 +768,7 @@ RCU pointer/list traversal: rcu_dereference list_for_each_rcu (to be deprecated in favor of list_for_each_entry_rcu) + list_for_each_safe_rcu (deprecated, not used) list_for_each_entry_rcu list_for_each_continue_rcu (to be deprecated in favor of new list_for_each_entry_continue_rcu) @@ -811,8 +807,7 @@ Quick Quiz #1: Why is this argument naive? How could a deadlock Answer: Consider the following sequence of events: 1. CPU 0 acquires some unrelated lock, call it - "problematic_lock", disabling irq via - spin_lock_irqsave(). + "problematic_lock". 2. CPU 1 enters synchronize_rcu(), write-acquiring rcu_gp_mutex. @@ -899,7 +894,7 @@ Answer: Just as PREEMPT_RT permits preemption of spinlock ACKNOWLEDGEMENTS My thanks to the people who helped make this human-readable, including -Jon Walpole, Josh Triplett, Serge Hallyn, Suzanne Wood, and Alan Stern. +Jon Walpole, Josh Triplett, Serge Hallyn, and Suzanne Wood. For more information, see http://www.rdrop.com/users/paulmck/RCU. diff --git a/trunk/Documentation/cputopology.txt b/trunk/Documentation/cputopology.txt deleted file mode 100644 index ff280e2e1613..000000000000 --- a/trunk/Documentation/cputopology.txt +++ /dev/null @@ -1,41 +0,0 @@ - -Export cpu topology info by sysfs. Items (attributes) are similar -to /proc/cpuinfo. - -1) /sys/devices/system/cpu/cpuX/topology/physical_package_id: -represent the physical package id of cpu X; -2) /sys/devices/system/cpu/cpuX/topology/core_id: -represent the cpu core id to cpu X; -3) /sys/devices/system/cpu/cpuX/topology/thread_siblings: -represent the thread siblings to cpu X in the same core; -4) /sys/devices/system/cpu/cpuX/topology/core_siblings: -represent the thread siblings to cpu X in the same physical package; - -To implement it in an architecture-neutral way, a new source file, -driver/base/topology.c, is to export the 5 attributes. - -If one architecture wants to support this feature, it just needs to -implement 4 defines, typically in file include/asm-XXX/topology.h. -The 4 defines are: -#define topology_physical_package_id(cpu) -#define topology_core_id(cpu) -#define topology_thread_siblings(cpu) -#define topology_core_siblings(cpu) - -The type of **_id is int. -The type of siblings is cpumask_t. - -To be consistent on all architectures, the 4 attributes should have -deafult values if their values are unavailable. Below is the rule. -1) physical_package_id: If cpu has no physical package id, -1 is the -default value. -2) core_id: If cpu doesn't support multi-core, its core id is 0. -3) thread_siblings: Just include itself, if the cpu doesn't support -HT/multi-thread. -4) core_siblings: Just include itself, if the cpu doesn't support -multi-core and HT/Multi-thread. - -So be careful when declaring the 4 defines in include/asm-XXX/topology.h. - -If an attribute isn't defined on an architecture, it won't be exported. - diff --git a/trunk/Documentation/driver-model/overview.txt b/trunk/Documentation/driver-model/overview.txt index ac4a7a737e43..44662735cf81 100644 --- a/trunk/Documentation/driver-model/overview.txt +++ b/trunk/Documentation/driver-model/overview.txt @@ -1,43 +1,50 @@ The Linux Kernel Device Model -Patrick Mochel +Patrick Mochel -Drafted 26 August 2002 -Updated 31 January 2006 +26 August 2002 Overview ~~~~~~~~ -The Linux Kernel Driver Model is a unification of all the disparate driver -models that were previously used in the kernel. It is intended to augment the +This driver model is a unification of all the current, disparate driver models +that are currently in the kernel. It is intended to augment the bus-specific drivers for bridges and devices by consolidating a set of data and operations into globally accessible data structures. -Traditional driver models implemented some sort of tree-like structure -(sometimes just a list) for the devices they control. There wasn't any -uniformity across the different bus types. +Current driver models implement some sort of tree-like structure (sometimes +just a list) for the devices they control. But, there is no linkage between +the different bus types. -The current driver model provides a comon, uniform data model for describing -a bus and the devices that can appear under the bus. The unified bus -model includes a set of common attributes which all busses carry, and a set -of common callbacks, such as device discovery during bus probing, bus -shutdown, bus power management, etc. +A common data structure can provide this linkage with little overhead: when a +bus driver discovers a particular device, it can insert it into the global +tree as well as its local tree. In fact, the local tree becomes just a subset +of the global tree. + +Common data fields can also be moved out of the local bus models into the +global model. Some of the manipulations of these fields can also be +consolidated. Most likely, manipulation functions will become a set +of helper functions, which the bus drivers wrap around to include any +bus-specific items. + +The common device and bridge interface currently reflects the goals of the +modern PC: namely the ability to do seamless Plug and Play, power management, +and hot plug. (The model dictated by Intel and Microsoft (read: ACPI) ensures +us that any device in the system may fit any of these criteria.) + +In reality, not every bus will be able to support such operations. But, most +buses will support a majority of those operations, and all future buses will. +In other words, a bus that doesn't support an operation is the exception, +instead of the other way around. -The common device and bridge interface reflects the goals of the modern -computer: namely the ability to do seamless device "plug and play", power -management, and hot plug. In particular, the model dictated by Intel and -Microsoft (namely ACPI) ensures that almost every device on almost any bus -on an x86-compatible system can work within this paradigm. Of course, -not every bus is able to support all such operations, although most -buses support a most of those operations. Downstream Access ~~~~~~~~~~~~~~~~~ Common data fields have been moved out of individual bus layers into a common -data structure. These fields must still be accessed by the bus layers, +data structure. But, these fields must still be accessed by the bus layers, and sometimes by the device-specific drivers. Other bus layers are encouraged to do what has been done for the PCI layer. @@ -46,7 +53,7 @@ struct pci_dev now looks like this: struct pci_dev { ... - struct device dev; + struct device device; }; Note first that it is statically allocated. This means only one allocation on @@ -57,9 +64,9 @@ the two. The PCI bus layer freely accesses the fields of struct device. It knows about the structure of struct pci_dev, and it should know the structure of struct -device. Individual PCI device drivers that have been converted the the current -driver model generally do not and should not touch the fields of struct device, -unless there is a strong compelling reason to do so. +device. PCI devices that have been converted generally do not touch the fields +of struct device. More precisely, device-specific drivers should not touch +fields of struct device unless there is a strong compelling reason to do so. This abstraction is prevention of unnecessary pain during transitional phases. If the name of the field changes or is removed, then every downstream driver diff --git a/trunk/Documentation/drivers/edac/edac.txt b/trunk/Documentation/drivers/edac/edac.txt deleted file mode 100644 index d37191fe5681..000000000000 --- a/trunk/Documentation/drivers/edac/edac.txt +++ /dev/null @@ -1,673 +0,0 @@ - - -EDAC - Error Detection And Correction - -Written by Doug Thompson -7 Dec 2005 - - -EDAC was written by: - Thayne Harbaugh, - modified by Dave Peterson, Doug Thompson, et al, - from the bluesmoke.sourceforge.net project. - - -============================================================================ -EDAC PURPOSE - -The 'edac' kernel module goal is to detect and report errors that occur -within the computer system. In the initial release, memory Correctable Errors -(CE) and Uncorrectable Errors (UE) are the primary errors being harvested. - -Detecting CE events, then harvesting those events and reporting them, -CAN be a predictor of future UE events. With CE events, the system can -continue to operate, but with less safety. Preventive maintainence and -proactive part replacement of memory DIMMs exhibiting CEs can reduce -the likelihood of the dreaded UE events and system 'panics'. - - -In addition, PCI Bus Parity and SERR Errors are scanned for on PCI devices -in order to determine if errors are occurring on data transfers. -The presence of PCI Parity errors must be examined with a grain of salt. -There are several addin adapters that do NOT follow the PCI specification -with regards to Parity generation and reporting. The specification says -the vendor should tie the parity status bits to 0 if they do not intend -to generate parity. Some vendors do not do this, and thus the parity bit -can "float" giving false positives. - -The PCI Parity EDAC device has the ability to "skip" known flakey -cards during the parity scan. These are set by the parity "blacklist" -interface in the sysfs for PCI Parity. (See the PCI section in the sysfs -section below.) There is also a parity "whitelist" which is used as -an explicit list of devices to scan, while the blacklist is a list -of devices to skip. - -EDAC will have future error detectors that will be added or integrated -into EDAC in the following list: - - MCE Machine Check Exception - MCA Machine Check Architecture - NMI NMI notification of ECC errors - MSRs Machine Specific Register error cases - and other mechanisms. - -These errors are usually bus errors, ECC errors, thermal throttling -and the like. - - -============================================================================ -EDAC VERSIONING - -EDAC is composed of a "core" module (edac_mc.ko) and several Memory -Controller (MC) driver modules. On a given system, the CORE -is loaded and one MC driver will be loaded. Both the CORE and -the MC driver have individual versions that reflect current release -level of their respective modules. Thus, to "report" on what version -a system is running, one must report both the CORE's and the -MC driver's versions. - - -LOADING - -If 'edac' was statically linked with the kernel then no loading is -necessary. If 'edac' was built as modules then simply modprobe the -'edac' pieces that you need. You should be able to modprobe -hardware-specific modules and have the dependencies load the necessary core -modules. - -Example: - -$> modprobe amd76x_edac - -loads both the amd76x_edac.ko memory controller module and the edac_mc.ko -core module. - - -============================================================================ -EDAC sysfs INTERFACE - -EDAC presents a 'sysfs' interface for control, reporting and attribute -reporting purposes. - -EDAC lives in the /sys/devices/system/edac directory. Within this directory -there currently reside 2 'edac' components: - - mc memory controller(s) system - pci PCI status system - - -============================================================================ -Memory Controller (mc) Model - -First a background on the memory controller's model abstracted in EDAC. -Each mc device controls a set of DIMM memory modules. These modules are -layed out in a Chip-Select Row (csrowX) and Channel table (chX). There can -be multiple csrows and two channels. - -Memory controllers allow for several csrows, with 8 csrows being a typical value. -Yet, the actual number of csrows depends on the electrical "loading" -of a given motherboard, memory controller and DIMM characteristics. - -Dual channels allows for 128 bit data transfers to the CPU from memory. - - - Channel 0 Channel 1 - =================================== - csrow0 | DIMM_A0 | DIMM_B0 | - csrow1 | DIMM_A0 | DIMM_B0 | - =================================== - - =================================== - csrow2 | DIMM_A1 | DIMM_B1 | - csrow3 | DIMM_A1 | DIMM_B1 | - =================================== - -In the above example table there are 4 physical slots on the motherboard -for memory DIMMs: - - DIMM_A0 - DIMM_B0 - DIMM_A1 - DIMM_B1 - -Labels for these slots are usually silk screened on the motherboard. Slots -labeled 'A' are channel 0 in this example. Slots labled 'B' -are channel 1. Notice that there are two csrows possible on a -physical DIMM. These csrows are allocated their csrow assignment -based on the slot into which the memory DIMM is placed. Thus, when 1 DIMM -is placed in each Channel, the csrows cross both DIMMs. - -Memory DIMMs come single or dual "ranked". A rank is a populated csrow. -Thus, 2 single ranked DIMMs, placed in slots DIMM_A0 and DIMM_B0 above -will have 1 csrow, csrow0. csrow1 will be empty. On the other hand, -when 2 dual ranked DIMMs are similiaryly placed, then both csrow0 and -csrow1 will be populated. The pattern repeats itself for csrow2 and -csrow3. - -The representation of the above is reflected in the directory tree -in EDAC's sysfs interface. Starting in directory -/sys/devices/system/edac/mc each memory controller will be represented -by its own 'mcX' directory, where 'X" is the index of the MC. - - - ..../edac/mc/ - | - |->mc0 - |->mc1 - |->mc2 - .... - -Under each 'mcX' directory each 'csrowX' is again represented by a -'csrowX', where 'X" is the csrow index: - - - .../mc/mc0/ - | - |->csrow0 - |->csrow2 - |->csrow3 - .... - -Notice that there is no csrow1, which indicates that csrow0 is -composed of a single ranked DIMMs. This should also apply in both -Channels, in order to have dual-channel mode be operational. Since -both csrow2 and csrow3 are populated, this indicates a dual ranked -set of DIMMs for channels 0 and 1. - - -Within each of the 'mc','mcX' and 'csrowX' directories are several -EDAC control and attribute files. - - -============================================================================ -DIRECTORY 'mc' - -In directory 'mc' are EDAC system overall control and attribute files: - - -Panic on UE control file: - - 'panic_on_ue' - - An uncorrectable error will cause a machine panic. This is usually - desirable. It is a bad idea to continue when an uncorrectable error - occurs - it is indeterminate what was uncorrected and the operating - system context might be so mangled that continuing will lead to further - corruption. If the kernel has MCE configured, then EDAC will never - notice the UE. - - LOAD TIME: module/kernel parameter: panic_on_ue=[0|1] - - RUN TIME: echo "1" >/sys/devices/system/edac/mc/panic_on_ue - - -Log UE control file: - - 'log_ue' - - Generate kernel messages describing uncorrectable errors. These errors - are reported through the system message log system. UE statistics - will be accumulated even when UE logging is disabled. - - LOAD TIME: module/kernel parameter: log_ue=[0|1] - - RUN TIME: echo "1" >/sys/devices/system/edac/mc/log_ue - - -Log CE control file: - - 'log_ce' - - Generate kernel messages describing correctable errors. These - errors are reported through the system message log system. - CE statistics will be accumulated even when CE logging is disabled. - - LOAD TIME: module/kernel parameter: log_ce=[0|1] - - RUN TIME: echo "1" >/sys/devices/system/edac/mc/log_ce - - -Polling period control file: - - 'poll_msec' - - The time period, in milliseconds, for polling for error information. - Too small a value wastes resources. Too large a value might delay - necessary handling of errors and might loose valuable information for - locating the error. 1000 milliseconds (once each second) is about - right for most uses. - - LOAD TIME: module/kernel parameter: poll_msec=[0|1] - - RUN TIME: echo "1000" >/sys/devices/system/edac/mc/poll_msec - - -Module Version read-only attribute file: - - 'mc_version' - - The EDAC CORE modules's version and compile date are shown here to - indicate what EDAC is running. - - - -============================================================================ -'mcX' DIRECTORIES - - -In 'mcX' directories are EDAC control and attribute files for -this 'X" instance of the memory controllers: - - -Counter reset control file: - - 'reset_counters' - - This write-only control file will zero all the statistical counters - for UE and CE errors. Zeroing the counters will also reset the timer - indicating how long since the last counter zero. This is useful - for computing errors/time. Since the counters are always reset at - driver initialization time, no module/kernel parameter is available. - - RUN TIME: echo "anything" >/sys/devices/system/edac/mc/mc0/counter_reset - - This resets the counters on memory controller 0 - - -Seconds since last counter reset control file: - - 'seconds_since_reset' - - This attribute file displays how many seconds have elapsed since the - last counter reset. This can be used with the error counters to - measure error rates. - - - -DIMM capability attribute file: - - 'edac_capability' - - The EDAC (Error Detection and Correction) capabilities/modes of - the memory controller hardware. - - -DIMM Current Capability attribute file: - - 'edac_current_capability' - - The EDAC capabilities available with the hardware - configuration. This may not be the same as "EDAC capability" - if the correct memory is not used. If a memory controller is - capable of EDAC, but DIMMs without check bits are in use, then - Parity, SECDED, S4ECD4ED capabilities will not be available - even though the memory controller might be capable of those - modes with the proper memory loaded. - - -Memory Type supported on this controller attribute file: - - 'supported_mem_type' - - This attribute file displays the memory type, usually - buffered and unbuffered DIMMs. - - -Memory Controller name attribute file: - - 'mc_name' - - This attribute file displays the type of memory controller - that is being utilized. - - -Memory Controller Module name attribute file: - - 'module_name' - - This attribute file displays the memory controller module name, - version and date built. The name of the memory controller - hardware - some drivers work with multiple controllers and - this field shows which hardware is present. - - -Total memory managed by this memory controller attribute file: - - 'size_mb' - - This attribute file displays, in count of megabytes, of memory - that this instance of memory controller manages. - - -Total Uncorrectable Errors count attribute file: - - 'ue_count' - - This attribute file displays the total count of uncorrectable - errors that have occurred on this memory controller. If panic_on_ue - is set this counter will not have a chance to increment, - since EDAC will panic the system. - - -Total UE count that had no information attribute fileY: - - 'ue_noinfo_count' - - This attribute file displays the number of UEs that - have occurred have occurred with no informations as to which DIMM - slot is having errors. - - -Total Correctable Errors count attribute file: - - 'ce_count' - - This attribute file displays the total count of correctable - errors that have occurred on this memory controller. This - count is very important to examine. CEs provide early - indications that a DIMM is beginning to fail. This count - field should be monitored for non-zero values and report - such information to the system administrator. - - -Total Correctable Errors count attribute file: - - 'ce_noinfo_count' - - This attribute file displays the number of CEs that - have occurred wherewith no informations as to which DIMM slot - is having errors. Memory is handicapped, but operational, - yet no information is available to indicate which slot - the failing memory is in. This count field should be also - be monitored for non-zero values. - -Device Symlink: - - 'device' - - Symlink to the memory controller device - - - -============================================================================ -'csrowX' DIRECTORIES - -In the 'csrowX' directories are EDAC control and attribute files for -this 'X" instance of csrow: - - -Total Uncorrectable Errors count attribute file: - - 'ue_count' - - This attribute file displays the total count of uncorrectable - errors that have occurred on this csrow. If panic_on_ue is set - this counter will not have a chance to increment, since EDAC - will panic the system. - - -Total Correctable Errors count attribute file: - - 'ce_count' - - This attribute file displays the total count of correctable - errors that have occurred on this csrow. This - count is very important to examine. CEs provide early - indications that a DIMM is beginning to fail. This count - field should be monitored for non-zero values and report - such information to the system administrator. - - -Total memory managed by this csrow attribute file: - - 'size_mb' - - This attribute file displays, in count of megabytes, of memory - that this csrow contatins. - - -Memory Type attribute file: - - 'mem_type' - - This attribute file will display what type of memory is currently - on this csrow. Normally, either buffered or unbuffered memory. - - -EDAC Mode of operation attribute file: - - 'edac_mode' - - This attribute file will display what type of Error detection - and correction is being utilized. - - -Device type attribute file: - - 'dev_type' - - This attribute file will display what type of DIMM device is - being utilized. Example: x4 - - -Channel 0 CE Count attribute file: - - 'ch0_ce_count' - - This attribute file will display the count of CEs on this - DIMM located in channel 0. - - -Channel 0 UE Count attribute file: - - 'ch0_ue_count' - - This attribute file will display the count of UEs on this - DIMM located in channel 0. - - -Channel 0 DIMM Label control file: - - 'ch0_dimm_label' - - This control file allows this DIMM to have a label assigned - to it. With this label in the module, when errors occur - the output can provide the DIMM label in the system log. - This becomes vital for panic events to isolate the - cause of the UE event. - - DIMM Labels must be assigned after booting, with information - that correctly identifies the physical slot with its - silk screen label. This information is currently very - motherboard specific and determination of this information - must occur in userland at this time. - - -Channel 1 CE Count attribute file: - - 'ch1_ce_count' - - This attribute file will display the count of CEs on this - DIMM located in channel 1. - - -Channel 1 UE Count attribute file: - - 'ch1_ue_count' - - This attribute file will display the count of UEs on this - DIMM located in channel 0. - - -Channel 1 DIMM Label control file: - - 'ch1_dimm_label' - - This control file allows this DIMM to have a label assigned - to it. With this label in the module, when errors occur - the output can provide the DIMM label in the system log. - This becomes vital for panic events to isolate the - cause of the UE event. - - DIMM Labels must be assigned after booting, with information - that correctly identifies the physical slot with its - silk screen label. This information is currently very - motherboard specific and determination of this information - must occur in userland at this time. - - -============================================================================ -SYSTEM LOGGING - -If logging for UEs and CEs are enabled then system logs will have -error notices indicating errors that have been detected: - -MC0: CE page 0x283, offset 0xce0, grain 8, syndrome 0x6ec3, row 0, -channel 1 "DIMM_B1": amd76x_edac - -MC0: CE page 0x1e5, offset 0xfb0, grain 8, syndrome 0xb741, row 0, -channel 1 "DIMM_B1": amd76x_edac - - -The structure of the message is: - the memory controller (MC0) - Error type (CE) - memory page (0x283) - offset in the page (0xce0) - the byte granularity (grain 8) - or resolution of the error - the error syndrome (0xb741) - memory row (row 0) - memory channel (channel 1) - DIMM label, if set prior (DIMM B1 - and then an optional, driver-specific message that may - have additional information. - -Both UEs and CEs with no info will lack all but memory controller, -error type, a notice of "no info" and then an optional, -driver-specific error message. - - - -============================================================================ -PCI Bus Parity Detection - - -On Header Type 00 devices the primary status is looked at -for any parity error regardless of whether Parity is enabled on the -device. (The spec indicates parity is generated in some cases). -On Header Type 01 bridges, the secondary status register is also -looked at to see if parity ocurred on the bus on the other side of -the bridge. - - -SYSFS CONFIGURATION - -Under /sys/devices/system/edac/pci are control and attribute files as follows: - - -Enable/Disable PCI Parity checking control file: - - 'check_pci_parity' - - - This control file enables or disables the PCI Bus Parity scanning - operation. Writing a 1 to this file enables the scanning. Writing - a 0 to this file disables the scanning. - - Enable: - echo "1" >/sys/devices/system/edac/pci/check_pci_parity - - Disable: - echo "0" >/sys/devices/system/edac/pci/check_pci_parity - - - -Panic on PCI PARITY Error: - - 'panic_on_pci_parity' - - - This control files enables or disables panic'ing when a parity - error has been detected. - - - module/kernel parameter: panic_on_pci_parity=[0|1] - - Enable: - echo "1" >/sys/devices/system/edac/pci/panic_on_pci_parity - - Disable: - echo "0" >/sys/devices/system/edac/pci/panic_on_pci_parity - - -Parity Count: - - 'pci_parity_count' - - This attribute file will display the number of parity errors that - have been detected. - - - -PCI Device Whitelist: - - 'pci_parity_whitelist' - - This control file allows for an explicit list of PCI devices to be - scanned for parity errors. Only devices found on this list will - be examined. The list is a line of hexadecimel VENDOR and DEVICE - ID tuples: - - 1022:7450,1434:16a6 - - One or more can be inserted, seperated by a comma. - - To write the above list doing the following as one command line: - - echo "1022:7450,1434:16a6" - > /sys/devices/system/edac/pci/pci_parity_whitelist - - - - To display what the whitelist is, simply 'cat' the same file. - - -PCI Device Blacklist: - - 'pci_parity_blacklist' - - This control file allows for a list of PCI devices to be - skipped for scanning. - The list is a line of hexadecimel VENDOR and DEVICE ID tuples: - - 1022:7450,1434:16a6 - - One or more can be inserted, seperated by a comma. - - To write the above list doing the following as one command line: - - echo "1022:7450,1434:16a6" - > /sys/devices/system/edac/pci/pci_parity_blacklist - - - To display what the whitelist current contatins, - simply 'cat' the same file. - -======================================================================= - -PCI Vendor and Devices IDs can be obtained with the lspci command. Using -the -n option lspci will display the vendor and device IDs. The system -adminstrator will have to determine which devices should be scanned or -skipped. - - - -The two lists (white and black) are prioritized. blacklist is the lower -priority and will NOT be utilized when a whitelist has been set. -Turn OFF a whitelist by an empty echo command: - - echo > /sys/devices/system/edac/pci/pci_parity_whitelist - -and any previous blacklist will be utililzed. - diff --git a/trunk/Documentation/feature-removal-schedule.txt b/trunk/Documentation/feature-removal-schedule.txt index b730d765b525..b4a1ea762698 100644 --- a/trunk/Documentation/feature-removal-schedule.txt +++ b/trunk/Documentation/feature-removal-schedule.txt @@ -148,26 +148,3 @@ Why: The 8250 serial driver now has the ability to deal with the differences brother on Alchemy SOCs. The loss of features is not considered an issue. Who: Ralf Baechle - ---------------------------- - -What: Legacy /proc/pci interface (PCI_LEGACY_PROC) -When: March 2006 -Why: deprecated since 2.5.53 in favor of lspci(8) -Who: Adrian Bunk - ---------------------------- - -What: pci_module_init(driver) -When: January 2007 -Why: Is replaced by pci_register_driver(pci_driver). -Who: Richard Knutsson and Greg Kroah-Hartman - ---------------------------- - -What: I2C interface of the it87 driver -When: January 2007 -Why: The ISA interface is faster and should be always available. The I2C - probing is also known to cause trouble in at least one case (see - bug #5889.) -Who: Jean Delvare diff --git a/trunk/Documentation/filesystems/configfs/configfs_example.c b/trunk/Documentation/filesystems/configfs/configfs_example.c index 3d4713a6c207..f3c6e4946f98 100644 --- a/trunk/Documentation/filesystems/configfs/configfs_example.c +++ b/trunk/Documentation/filesystems/configfs/configfs_example.c @@ -320,7 +320,6 @@ static struct config_item_type simple_children_type = { .ct_item_ops = &simple_children_item_ops, .ct_group_ops = &simple_children_group_ops, .ct_attrs = simple_children_attrs, - .ct_owner = THIS_MODULE, }; static struct configfs_subsystem simple_children_subsys = { @@ -404,7 +403,6 @@ static struct config_item_type group_children_type = { .ct_item_ops = &group_children_item_ops, .ct_group_ops = &group_children_group_ops, .ct_attrs = group_children_attrs, - .ct_owner = THIS_MODULE, }; static struct configfs_subsystem group_children_subsys = { diff --git a/trunk/Documentation/filesystems/ocfs2.txt b/trunk/Documentation/filesystems/ocfs2.txt index 4389c684a80a..f2595caf052e 100644 --- a/trunk/Documentation/filesystems/ocfs2.txt +++ b/trunk/Documentation/filesystems/ocfs2.txt @@ -35,7 +35,6 @@ Features which OCFS2 does not support yet: be cluster coherent. - quotas - cluster aware flock - - cluster aware lockf - Directory change notification (F_NOTIFY) - Distributed Caching (F_SETLEASE/F_GETLEASE/break_lease) - POSIX ACLs diff --git a/trunk/Documentation/hwmon/f71805f b/trunk/Documentation/hwmon/f71805f deleted file mode 100644 index 28c5b7d1eb90..000000000000 --- a/trunk/Documentation/hwmon/f71805f +++ /dev/null @@ -1,105 +0,0 @@ -Kernel driver f71805f -===================== - -Supported chips: - * Fintek F71805F/FG - Prefix: 'f71805f' - Addresses scanned: none, address read from Super I/O config space - Datasheet: Provided by Fintek on request - -Author: Jean Delvare - -Thanks to Denis Kieft from Barracuda Networks for the donation of a -test system (custom Jetway K8M8MS motherboard, with CPU and RAM) and -for providing initial documentation. - -Thanks to Kris Chen from Fintek for answering technical questions and -providing additional documentation. - -Thanks to Chris Lin from Jetway for providing wiring schematics and -anwsering technical questions. - - -Description ------------ - -The Fintek F71805F/FG Super I/O chip includes complete hardware monitoring -capabilities. It can monitor up to 9 voltages (counting its own power -source), 3 fans and 3 temperature sensors. - -This chip also has fan controlling features, using either DC or PWM, in -three different modes (one manual, two automatic). The driver doesn't -support these features yet. - -The driver assumes that no more than one chip is present, which seems -reasonable. - - -Voltage Monitoring ------------------- - -Voltages are sampled by an 8-bit ADC with a LSB of 8 mV. The supported -range is thus from 0 to 2.040 V. Voltage values outside of this range -need external resistors. An exception is in0, which is used to monitor -the chip's own power source (+3.3V), and is divided internally by a -factor 2. - -The two LSB of the voltage limit registers are not used (always 0), so -you can only set the limits in steps of 32 mV (before scaling). - -The wirings and resistor values suggested by Fintek are as follow: - - pin expected - name use R1 R2 divider raw val. - -in0 VCC VCC3.3V int. int. 2.00 1.65 V -in1 VIN1 VTT1.2V 10K - 1.00 1.20 V -in2 VIN2 VRAM 100K 100K 2.00 ~1.25 V (1) -in3 VIN3 VCHIPSET 47K 100K 1.47 2.24 V (2) -in4 VIN4 VCC5V 200K 47K 5.25 0.95 V -in5 VIN5 +12V 200K 20K 11.00 1.05 V -in6 VIN6 VCC1.5V 10K - 1.00 1.50 V -in7 VIN7 VCORE 10K - 1.00 ~1.40 V (1) -in8 VIN8 VSB5V 200K 47K 1.00 0.95 V - -(1) Depends on your hardware setup. -(2) Obviously not correct, swapping R1 and R2 would make more sense. - -These values can be used as hints at best, as motherboard manufacturers -are free to use a completely different setup. As a matter of fact, the -Jetway K8M8MS uses a significantly different setup. You will have to -find out documentation about your own motherboard, and edit sensors.conf -accordingly. - -Each voltage measured has associated low and high limits, each of which -triggers an alarm when crossed. - - -Fan Monitoring --------------- - -Fan rotation speeds are reported as 12-bit values from a gated clock -signal. Speeds down to 366 RPM can be measured. There is no theoretical -high limit, but values over 6000 RPM seem to cause problem. The effective -resolution is much lower than you would expect, the step between different -register values being 10 rather than 1. - -The chip assumes 2 pulse-per-revolution fans. - -An alarm is triggered if the rotation speed drops below a programmable -limit or is too low to be measured. - - -Temperature Monitoring ----------------------- - -Temperatures are reported in degrees Celsius. Each temperature measured -has a high limit, those crossing triggers an alarm. There is an associated -hysteresis value, below which the temperature has to drop before the -alarm is cleared. - -All temperature channels are external, there is no embedded temperature -sensor. Each channel can be used for connecting either a thermal diode -or a thermistor. The driver reports the currently selected mode, but -doesn't allow changing it. In theory, the BIOS should have configured -everything properly. diff --git a/trunk/Documentation/hwmon/it87 b/trunk/Documentation/hwmon/it87 index 9555be1ed999..7f42e441c645 100644 --- a/trunk/Documentation/hwmon/it87 +++ b/trunk/Documentation/hwmon/it87 @@ -9,7 +9,7 @@ Supported chips: http://www.ite.com.tw/ * IT8712F Prefix: 'it8712' - Addresses scanned: I2C 0x2d + Addresses scanned: I2C 0x28 - 0x2f from Super I/O config space (8 I/O ports) Datasheet: Publicly available at the ITE website http://www.ite.com.tw/ diff --git a/trunk/Documentation/hwmon/sysfs-interface b/trunk/Documentation/hwmon/sysfs-interface index a0d0ab24288e..764cdc5480e7 100644 --- a/trunk/Documentation/hwmon/sysfs-interface +++ b/trunk/Documentation/hwmon/sysfs-interface @@ -179,12 +179,11 @@ temp[1-*]_auto_point[1-*]_temp_hyst **************** temp[1-3]_type Sensor type selection. - Integers 1 to 4 or thermistor Beta value (typically 3435) + Integers 1, 2, 3 or thermistor Beta value (3435) Read/Write. 1: PII/Celeron Diode 2: 3904 transistor 3: thermal diode - 4: thermistor (default/unknown Beta) Not all types are supported by all chips temp[1-4]_max Temperature max value. @@ -262,21 +261,6 @@ alarms Alarm bitmask. of individual bits. Bits are defined in kernel/include/sensors.h. -alarms_in Alarm bitmask relative to in (voltage) channels - Read only - A '1' bit means an alarm, LSB corresponds to in0 and so on - Prefered to 'alarms' for newer chips - -alarms_fan Alarm bitmask relative to fan channels - Read only - A '1' bit means an alarm, LSB corresponds to fan1 and so on - Prefered to 'alarms' for newer chips - -alarms_temp Alarm bitmask relative to temp (temperature) channels - Read only - A '1' bit means an alarm, LSB corresponds to temp1 and so on - Prefered to 'alarms' for newer chips - beep_enable Beep/interrupt enable 0 to disable. 1 to enable. diff --git a/trunk/Documentation/i2c/busses/i2c-sis96x b/trunk/Documentation/i2c/busses/i2c-sis69x similarity index 98% rename from trunk/Documentation/i2c/busses/i2c-sis96x rename to trunk/Documentation/i2c/busses/i2c-sis69x index 00a009b977e9..b88953dfd580 100644 --- a/trunk/Documentation/i2c/busses/i2c-sis96x +++ b/trunk/Documentation/i2c/busses/i2c-sis69x @@ -7,7 +7,7 @@ Supported adapters: Any combination of these host bridges: 645, 645DX (aka 646), 648, 650, 651, 655, 735, 745, 746 and these south bridges: - 961, 962, 963(L) + 961, 962, 963(L) Author: Mark M. Hoffman @@ -29,7 +29,7 @@ The command "lspci" as root should produce something like these lines: or perhaps this... -00:00.0 Host bridge: Silicon Integrated Systems [SiS]: Unknown device 0645 +00:00.0 Host bridge: Silicon Integrated Systems [SiS]: Unknown device 0645 00:02.0 ISA bridge: Silicon Integrated Systems [SiS]: Unknown device 0961 00:02.1 SMBus: Silicon Integrated Systems [SiS]: Unknown device 0016 diff --git a/trunk/Documentation/kernel-doc-nano-HOWTO.txt b/trunk/Documentation/kernel-doc-nano-HOWTO.txt index c65233d430f0..c406ce67edd0 100644 --- a/trunk/Documentation/kernel-doc-nano-HOWTO.txt +++ b/trunk/Documentation/kernel-doc-nano-HOWTO.txt @@ -45,10 +45,10 @@ How to extract the documentation If you just want to read the ready-made books on the various subsystems (see Documentation/DocBook/*.tmpl), just type 'make -psdocs', or 'make pdfdocs', or 'make htmldocs', depending on your -preference. If you would rather read a different format, you can type -'make sgmldocs' and then use DocBook tools to convert -Documentation/DocBook/*.sgml to a format of your choice (for example, +psdocs', or 'make pdfdocs', or 'make htmldocs', depending on your +preference. If you would rather read a different format, you can type +'make sgmldocs' and then use DocBook tools to convert +Documentation/DocBook/*.sgml to a format of your choice (for example, 'db2html ...' if 'make htmldocs' was not defined). If you want to see man pages instead, you can do this: @@ -124,36 +124,6 @@ patterns, which are highlighted appropriately. Take a look around the source tree for examples. -kernel-doc for structs, unions, enums, and typedefs ---------------------------------------------------- - -Beside functions you can also write documentation for structs, unions, -enums and typedefs. Instead of the function name you must write the name -of the declaration; the struct/union/enum/typedef must always precede -the name. Nesting of declarations is not supported. -Use the argument mechanism to document members or constants. - -Inside a struct description, you can use the "private:" and "public:" -comment tags. Structure fields that are inside a "private:" area -are not listed in the generated output documentation. - -Example: - -/** - * struct my_struct - short description - * @a: first member - * @b: second member - * - * Longer description - */ -struct my_struct { - int a; - int b; -/* private: */ - int c; -}; - - How to make new SGML template files ----------------------------------- @@ -177,3 +147,4 @@ documentation, in , for the functions listed. Tim. */ + diff --git a/trunk/Documentation/kernel-parameters.txt b/trunk/Documentation/kernel-parameters.txt index 84370363da80..1cbcf65b764b 100644 --- a/trunk/Documentation/kernel-parameters.txt +++ b/trunk/Documentation/kernel-parameters.txt @@ -452,11 +452,6 @@ running once the system is up. eata= [HW,SCSI] - ec_intr= [HW,ACPI] ACPI Embedded Controller interrupt mode - Format: - 0: polling mode - non-0: interrupt mode (default) - eda= [HW,PS2] edb= [HW,PS2] diff --git a/trunk/Documentation/networking/ip-sysctl.txt b/trunk/Documentation/networking/ip-sysctl.txt index 26364d06ae92..2b7cf19a06ad 100644 --- a/trunk/Documentation/networking/ip-sysctl.txt +++ b/trunk/Documentation/networking/ip-sysctl.txt @@ -427,23 +427,6 @@ icmp_ignore_bogus_error_responses - BOOLEAN will avoid log file clutter. Default: FALSE -icmp_errors_use_inbound_ifaddr - BOOLEAN - - If zero, icmp error messages are sent with the primary address of - the exiting interface. - - If non-zero, the message will be sent with the primary address of - the interface that received the packet that caused the icmp error. - This is the behaviour network many administrators will expect from - a router. And it can make debugging complicated network layouts - much easier. - - Note that if no primary address exists for the interface selected, - then the primary address of the first non-loopback interface that - has one will be used regarldess of this setting. - - Default: 0 - igmp_max_memberships - INTEGER Change the maximum number of multicast groups we can subscribe to. Default: 20 diff --git a/trunk/Documentation/parport-lowlevel.txt b/trunk/Documentation/parport-lowlevel.txt index 8f2302415eff..1d40008a1926 100644 --- a/trunk/Documentation/parport-lowlevel.txt +++ b/trunk/Documentation/parport-lowlevel.txt @@ -1068,7 +1068,7 @@ SYNOPSIS struct parport_operations { ... - void (*write_control) (struct parport *port, unsigned char s); + void (*write_status) (struct parport *port, unsigned char s); ... }; @@ -1097,9 +1097,9 @@ SYNOPSIS struct parport_operations { ... - unsigned char (*frob_control) (struct parport *port, - unsigned char mask, - unsigned char val); + void (*frob_control) (struct parport *port, + unsigned char mask, + unsigned char val); ... }; diff --git a/trunk/Documentation/pci-error-recovery.txt b/trunk/Documentation/pci-error-recovery.txt index 634d3e5b5756..d089967e4948 100644 --- a/trunk/Documentation/pci-error-recovery.txt +++ b/trunk/Documentation/pci-error-recovery.txt @@ -1,396 +1,246 @@ PCI Error Recovery ------------------ - February 2, 2006 - - Current document maintainer: - Linas Vepstas - - -Many PCI bus controllers are able to detect a variety of hardware -PCI errors on the bus, such as parity errors on the data and address -busses, as well as SERR and PERR errors. Some of the more advanced -chipsets are able to deal with these errors; these include PCI-E chipsets, -and the PCI-host bridges found on IBM Power4 and Power5-based pSeries -boxes. A typical action taken is to disconnect the affected device, -halting all I/O to it. The goal of a disconnection is to avoid system -corruption; for example, to halt system memory corruption due to DMA's -to "wild" addresses. Typically, a reconnection mechanism is also -offered, so that the affected PCI device(s) are reset and put back -into working condition. The reset phase requires coordination -between the affected device drivers and the PCI controller chip. -This document describes a generic API for notifying device drivers -of a bus disconnection, and then performing error recovery. -This API is currently implemented in the 2.6.16 and later kernels. - -Reporting and recovery is performed in several steps. First, when -a PCI hardware error has resulted in a bus disconnect, that event -is reported as soon as possible to all affected device drivers, -including multiple instances of a device driver on multi-function -cards. This allows device drivers to avoid deadlocking in spinloops, -waiting for some i/o-space register to change, when it never will. -It also gives the drivers a chance to defer incoming I/O as -needed. - -Next, recovery is performed in several stages. Most of the complexity -is forced by the need to handle multi-function devices, that is, -devices that have multiple device drivers associated with them. -In the first stage, each driver is allowed to indicate what type -of reset it desires, the choices being a simple re-enabling of I/O -or requesting a hard reset (a full electrical #RST of the PCI card). -If any driver requests a full reset, that is what will be done. - -After a full reset and/or a re-enabling of I/O, all drivers are -again notified, so that they may then perform any device setup/config -that may be required. After these have all completed, a final -"resume normal operations" event is sent out. - -The biggest reason for choosing a kernel-based implementation rather -than a user-space implementation was the need to deal with bus -disconnects of PCI devices attached to storage media, and, in particular, -disconnects from devices holding the root file system. If the root -file system is disconnected, a user-space mechanism would have to go -through a large number of contortions to complete recovery. Almost all -of the current Linux file systems are not tolerant of disconnection -from/reconnection to their underlying block device. By contrast, -bus errors are easy to manage in the device driver. Indeed, most -device drivers already handle very similar recovery procedures; -for example, the SCSI-generic layer already provides significant -mechanisms for dealing with SCSI bus errors and SCSI bus resets. - - -Detailed Design ---------------- -Design and implementation details below, based on a chain of -public email discussions with Ben Herrenschmidt, circa 5 April 2005. + May 31, 2005 + + Current document maintainer: + Linas Vepstas + + +Some PCI bus controllers are able to detect certain "hard" PCI errors +on the bus, such as parity errors on the data and address busses, as +well as SERR and PERR errors. These chipsets are then able to disable +I/O to/from the affected device, so that, for example, a bad DMA +address doesn't end up corrupting system memory. These same chipsets +are also able to reset the affected PCI device, and return it to +working condition. This document describes a generic API form +performing error recovery. + +The core idea is that after a PCI error has been detected, there must +be a way for the kernel to coordinate with all affected device drivers +so that the pci card can be made operational again, possibly after +performing a full electrical #RST of the PCI card. The API below +provides a generic API for device drivers to be notified of PCI +errors, and to be notified of, and respond to, a reset sequence. + +Preliminary sketch of API, cut-n-pasted-n-modified email from +Ben Herrenschmidt, circa 5 april 2005 The error recovery API support is exposed to the driver in the form of a structure of function pointers pointed to by a new field in struct -pci_driver. A driver that fails to provide the structure is "non-aware", -and the actual recovery steps taken are platform dependent. The -arch/powerpc implementation will simulate a PCI hotplug remove/add. +pci_driver. The absence of this pointer in pci_driver denotes an +"non-aware" driver, behaviour on these is platform dependant. +Platforms like ppc64 can try to simulate pci hotplug remove/add. + +The definition of "pci_error_token" is not covered here. It is based on +Seto's work on the synchronous error detection. We still need to define +functions for extracting infos out of an opaque error token. This is +separate from this API. This structure has the form: + struct pci_error_handlers { - int (*error_detected)(struct pci_dev *dev, enum pci_channel_state); + int (*error_detected)(struct pci_dev *dev, pci_error_token error); int (*mmio_enabled)(struct pci_dev *dev); + int (*resume)(struct pci_dev *dev); int (*link_reset)(struct pci_dev *dev); int (*slot_reset)(struct pci_dev *dev); - void (*resume)(struct pci_dev *dev); }; -The possible channel states are: -enum pci_channel_state { - pci_channel_io_normal, /* I/O channel is in normal state */ - pci_channel_io_frozen, /* I/O to channel is blocked */ - pci_channel_io_perm_failure, /* PCI card is dead */ -}; - -Possible return values are: -enum pci_ers_result { - PCI_ERS_RESULT_NONE, /* no result/none/not supported in device driver */ - PCI_ERS_RESULT_CAN_RECOVER, /* Device driver can recover without slot reset */ - PCI_ERS_RESULT_NEED_RESET, /* Device driver wants slot to be reset. */ - PCI_ERS_RESULT_DISCONNECT, /* Device has completely failed, is unrecoverable */ - PCI_ERS_RESULT_RECOVERED, /* Device driver is fully recovered and operational */ -}; - -A driver does not have to implement all of these callbacks; however, -if it implements any, it must implement error_detected(). If a callback -is not implemented, the corresponding feature is considered unsupported. -For example, if mmio_enabled() and resume() aren't there, then it -is assumed that the driver is not doing any direct recovery and requires +A driver doesn't have to implement all of these callbacks. The +only mandatory one is error_detected(). If a callback is not +implemented, the corresponding feature is considered unsupported. +For example, if mmio_enabled() and resume() aren't there, then the +driver is assumed as not doing any direct recovery and requires a reset. If link_reset() is not implemented, the card is assumed as -not care about link resets. Typically a driver will want to know about -a slot_reset(). - -The actual steps taken by a platform to recover from a PCI error -event will be platform-dependent, but will follow the general -sequence described below. - -STEP 0: Error Event -------------------- -PCI bus error is detect by the PCI hardware. On powerpc, the slot -is isolated, in that all I/O is blocked: all reads return 0xffffffff, -all writes are ignored. - - -STEP 1: Notification --------------------- -Platform calls the error_detected() callback on every instance of -every driver affected by the error. - -At this point, the device might not be accessible anymore, depending on -the platform (the slot will be isolated on powerpc). The driver may -already have "noticed" the error because of a failing I/O, but this -is the proper "synchronization point", that is, it gives the driver -a chance to cleanup, waiting for pending stuff (timers, whatever, etc...) -to complete; it can take semaphores, schedule, etc... everything but -touch the device. Within this function and after it returns, the driver +not caring about link resets, in which case, if recover is supported, +the core can try recover (but not slot_reset() unless it really did +reset the slot). If slot_reset() is not supported, link_reset() can +be called instead on a slot reset. + +At first, the call will always be : + + 1) error_detected() + + Error detected. This is sent once after an error has been detected. At +this point, the device might not be accessible anymore depending on the +platform (the slot will be isolated on ppc64). The driver may already +have "noticed" the error because of a failing IO, but this is the proper +"synchronisation point", that is, it gives a chance to the driver to +cleanup, waiting for pending stuff (timers, whatever, etc...) to +complete; it can take semaphores, schedule, etc... everything but touch +the device. Within this function and after it returns, the driver shouldn't do any new IOs. Called in task context. This is sort of a "quiesce" point. See note about interrupts at the end of this doc. -All drivers participating in this system must implement this call. -The driver must return one of the following result codes: - - PCI_ERS_RESULT_CAN_RECOVER: - Driver returns this if it thinks it might be able to recover + Result codes: + - PCIERR_RESULT_CAN_RECOVER: + Driever returns this if it thinks it might be able to recover the HW by just banging IOs or if it wants to be given - a chance to extract some diagnostic information (see - mmio_enable, below). - - PCI_ERS_RESULT_NEED_RESET: - Driver returns this if it can't recover without a hard - slot reset. - - PCI_ERS_RESULT_DISCONNECT: - Driver returns this if it doesn't want to recover at all. - -The next step taken will depend on the result codes returned by the -drivers. - -If all drivers on the segment/slot return PCI_ERS_RESULT_CAN_RECOVER, -then the platform should re-enable IOs on the slot (or do nothing in -particular, if the platform doesn't isolate slots), and recovery -proceeds to STEP 2 (MMIO Enable). - -If any driver requested a slot reset (by returning PCI_ERS_RESULT_NEED_RESET), -then recovery proceeds to STEP 4 (Slot Reset). - -If the platform is unable to recover the slot, the next step -is STEP 6 (Permanent Failure). - ->>> The current powerpc implementation assumes that a device driver will ->>> *not* schedule or semaphore in this routine; the current powerpc + a chance to extract some diagnostic informations (see + below). + - PCIERR_RESULT_NEED_RESET: + Driver returns this if it thinks it can't recover unless the + slot is reset. + - PCIERR_RESULT_DISCONNECT: + Return this if driver thinks it won't recover at all, + (this will detach the driver ? or just leave it + dangling ? to be decided) + +So at this point, we have called error_detected() for all drivers +on the segment that had the error. On ppc64, the slot is isolated. What +happens now typically depends on the result from the drivers. If all +drivers on the segment/slot return PCIERR_RESULT_CAN_RECOVER, we would +re-enable IOs on the slot (or do nothing special if the platform doesn't +isolate slots) and call 2). If not and we can reset slots, we go to 4), +if neither, we have a dead slot. If it's an hotplug slot, we might +"simulate" reset by triggering HW unplug/replug though. + +>>> Current ppc64 implementation assumes that a device driver will +>>> *not* schedule or semaphore in this routine; the current ppc64 >>> implementation uses one kernel thread to notify all devices; ->>> thus, if one device sleeps/schedules, all devices are affected. +>>> thus, of one device sleeps/schedules, all devices are affected. >>> Doing better requires complex multi-threaded logic in the error >>> recovery implementation (e.g. waiting for all notification threads >>> to "join" before proceeding with recovery.) This seems excessively >>> complex and not worth implementing. ->>> The current powerpc implementation doesn't much care if the device ->>> attempts I/O at this point, or not. I/O's will fail, returning +>>> The current ppc64 implementation doesn't much care if the device +>>> attempts i/o at this point, or not. I/O's will fail, returning >>> a value of 0xff on read, and writes will be dropped. If the device >>> driver attempts more than 10K I/O's to a frozen adapter, it will >>> assume that the device driver has gone into an infinite loop, and ->>> it will panic the the kernel. There doesn't seem to be any other ->>> way of stopping a device driver that insists on spinning on I/O. +>>> it will panic the the kernel. -STEP 2: MMIO Enabled -------------------- -The platform re-enables MMIO to the device (but typically not the -DMA), and then calls the mmio_enabled() callback on all affected -device drivers. + 2) mmio_enabled() -This is the "early recovery" call. IOs are allowed again, but DMA is + This is the "early recovery" call. IOs are allowed again, but DMA is not (hrm... to be discussed, I prefer not), with some restrictions. This is NOT a callback for the driver to start operations again, only to peek/poke at the device, extract diagnostic information, if any, and eventually do things like trigger a device local reset or some such, -but not restart operations. This is callback is made if all drivers on -a segment agree that they can try to recover and if no automatic link reset -was performed by the HW. If the platform can't just re-enable IOs without -a slot reset or a link reset, it wont call this callback, and instead -will have gone directly to STEP 3 (Link Reset) or STEP 4 (Slot Reset) - ->>> The following is proposed; no platform implements this yet: ->>> Proposal: All I/O's should be done _synchronously_ from within ->>> this callback, errors triggered by them will be returned via ->>> the normal pci_check_whatever() API, no new error_detected() ->>> callback will be issued due to an error happening here. However, ->>> such an error might cause IOs to be re-blocked for the whole ->>> segment, and thus invalidate the recovery that other devices ->>> on the same segment might have done, forcing the whole segment ->>> into one of the next states, that is, link reset or slot reset. - -The driver should return one of the following result codes: - - PCI_ERS_RESULT_RECOVERED +but not restart operations. This is sent if all drivers on a segment +agree that they can try to recover and no automatic link reset was +performed by the HW. If the platform can't just re-enable IOs without +a slot reset or a link reset, it doesn't call this callback and goes +directly to 3) or 4). All IOs should be done _synchronously_ from +within this callback, errors triggered by them will be returned via +the normal pci_check_whatever() api, no new error_detected() callback +will be issued due to an error happening here. However, such an error +might cause IOs to be re-blocked for the whole segment, and thus +invalidate the recovery that other devices on the same segment might +have done, forcing the whole segment into one of the next states, +that is link reset or slot reset. + + Result codes: + - PCIERR_RESULT_RECOVERED Driver returns this if it thinks the device is fully - functional and thinks it is ready to start + functionnal and thinks it is ready to start normal driver operations again. There is no guarantee that the driver will actually be allowed to proceed, as another driver on the same segment might have failed and thus triggered a slot reset on platforms that support it. - - PCI_ERS_RESULT_NEED_RESET + - PCIERR_RESULT_NEED_RESET Driver returns this if it thinks the device is not recoverable in it's current state and it needs a slot reset to proceed. - - PCI_ERS_RESULT_DISCONNECT + - PCIERR_RESULT_DISCONNECT Same as above. Total failure, no recovery even after reset driver dead. (To be defined more precisely) -The next step taken depends on the results returned by the drivers. -If all drivers returned PCI_ERS_RESULT_RECOVERED, then the platform -proceeds to either STEP3 (Link Reset) or to STEP 5 (Resume Operations). - -If any driver returned PCI_ERS_RESULT_NEED_RESET, then the platform -proceeds to STEP 4 (Slot Reset) +>>> The current ppc64 implementation does not implement this callback. ->>> The current powerpc implementation does not implement this callback. + 3) link_reset() - -STEP 3: Link Reset ------------------- -The platform resets the link, and then calls the link_reset() callback -on all affected device drivers. This is a PCI-Express specific state -and is done whenever a non-fatal error has been detected that can be -"solved" by resetting the link. This call informs the driver of the -reset and the driver should check to see if the device appears to be -in working condition. - -The driver is not supposed to restart normal driver I/O operations -at this point. It should limit itself to "probing" the device to -check it's recoverability status. If all is right, then the platform -will call resume() once all drivers have ack'd link_reset(). + This is called after the link has been reset. This is typically +a PCI Express specific state at this point and is done whenever a +non-fatal error has been detected that can be "solved" by resetting +the link. This call informs the driver of the reset and the driver +should check if the device appears to be in working condition. +This function acts a bit like 2) mmio_enabled(), in that the driver +is not supposed to restart normal driver I/O operations right away. +Instead, it should just "probe" the device to check it's recoverability +status. If all is right, then the core will call resume() once all +drivers have ack'd link_reset(). Result codes: - (identical to STEP 3 (MMIO Enabled) - -The platform then proceeds to either STEP 4 (Slot Reset) or STEP 5 -(Resume Operations). - ->>> The current powerpc implementation does not implement this callback. - - -STEP 4: Slot Reset ------------------- -The platform performs a soft or hard reset of the device, and then -calls the slot_reset() callback. - -A soft reset consists of asserting the adapter #RST line and then -restoring the PCI BAR's and PCI configuration header to a state -that is equivalent to what it would be after a fresh system -power-on followed by power-on BIOS/system firmware initialization. -If the platform supports PCI hotplug, then the reset might be -performed by toggling the slot electrical power off/on. + (identical to mmio_enabled) -It is important for the platform to restore the PCI config space -to the "fresh poweron" state, rather than the "last state". After -a slot reset, the device driver will almost always use its standard -device initialization routines, and an unusual config space setup -may result in hung devices, kernel panics, or silent data corruption. +>>> The current ppc64 implementation does not implement this callback. -This call gives drivers the chance to re-initialize the hardware -(re-download firmware, etc.). At this point, the driver may assume -that he card is in a fresh state and is fully functional. In -particular, interrupt generation should work normally. + 4) slot_reset() -Drivers should not yet restart normal I/O processing operations -at this point. If all device drivers report success on this -callback, the platform will call resume() to complete the sequence, -and let the driver restart normal I/O processing. + This is called after the slot has been soft or hard reset by the +platform. A soft reset consists of asserting the adapter #RST line +and then restoring the PCI BARs and PCI configuration header. If the +platform supports PCI hotplug, then it might instead perform a hard +reset by toggling power on the slot off/on. This call gives drivers +the chance to re-initialize the hardware (re-download firmware, etc.), +but drivers shouldn't restart normal I/O processing operations at +this point. (See note about interrupts; interrupts aren't guaranteed +to be delivered until the resume() callback has been called). If all +device drivers report success on this callback, the patform will call +resume() to complete the error handling and let the driver restart +normal I/O processing. A driver can still return a critical failure for this function if it can't get the device operational after reset. If the platform -previously tried a soft reset, it might now try a hard reset (power +previously tried a soft reset, it migh now try a hard reset (power cycle) and then call slot_reset() again. It the device still can't be recovered, there is nothing more that can be done; the platform will typically report a "permanent failure" in such a case. The device will be considered "dead" in this case. -Drivers for multi-function cards will need to coordinate among -themselves as to which driver instance will perform any "one-shot" -or global device initialization. For example, the Symbios sym53cxx2 -driver performs device init only from PCI function 0: - -+ if (PCI_FUNC(pdev->devfn) == 0) -+ sym_reset_scsi_bus(np, 0); - Result codes: - - PCI_ERS_RESULT_DISCONNECT + - PCIERR_RESULT_DISCONNECT Same as above. -Platform proceeds either to STEP 5 (Resume Operations) or STEP 6 (Permanent -Failure). - ->>> The current powerpc implementation does not currently try a ->>> power-cycle reset if the driver returned PCI_ERS_RESULT_DISCONNECT. ->>> However, it probably should. - - -STEP 5: Resume Operations -------------------------- -The platform will call the resume() callback on all affected device -drivers if all drivers on the segment have returned -PCI_ERS_RESULT_RECOVERED from one of the 3 previous callbacks. -The goal of this callback is to tell the driver to restart activity, -that everything is back and running. This callback does not return -a result code. - -At this point, if a new error happens, the platform will restart -a new error recovery sequence. - -STEP 6: Permanent Failure -------------------------- -A "permanent failure" has occurred, and the platform cannot recover -the device. The platform will call error_detected() with a -pci_channel_state value of pci_channel_io_perm_failure. - -The device driver should, at this point, assume the worst. It should -cancel all pending I/O, refuse all new I/O, returning -EIO to -higher layers. The device driver should then clean up all of its -memory and remove itself from kernel operations, much as it would -during system shutdown. - -The platform will typically notify the system operator of the -permanent failure in some way. If the device is hotplug-capable, -the operator will probably want to remove and replace the device. -Note, however, not all failures are truly "permanent". Some are -caused by over-heating, some by a poorly seated card. Many -PCI error events are caused by software bugs, e.g. DMA's to -wild addresses or bogus split transactions due to programming -errors. See the discussion in powerpc/eeh-pci-error-recovery.txt -for additional detail on real-life experience of the causes of -software errors. - - -Conclusion; General Remarks ---------------------------- -The way those callbacks are called is platform policy. A platform with -no slot reset capability may want to just "ignore" drivers that can't +>>> The current ppc64 implementation does not try a power-cycle reset +>>> if the driver returned PCIERR_RESULT_DISCONNECT. However, it should. + + 5) resume() + + This is called if all drivers on the segment have returned +PCIERR_RESULT_RECOVERED from one of the 3 prevous callbacks. +That basically tells the driver to restart activity, tht everything +is back and running. No result code is taken into account here. If +a new error happens, it will restart a new error handling process. + +That's it. I think this covers all the possibilities. The way those +callbacks are called is platform policy. A platform with no slot reset +capability for example may want to just "ignore" drivers that can't recover (disconnect them) and try to let other cards on the same segment recover. Keep in mind that in most real life cases, though, there will be only one driver per segment. -Now, a note about interrupts. If you get an interrupt and your +Now, there is a note about interrupts. If you get an interrupt and your device is dead or has been isolated, there is a problem :) -The current policy is to turn this into a platform policy. -That is, the recovery API only requires that: + +After much thinking, I decided to leave that to the platform. That is, +the recovery API only precies that: - There is no guarantee that interrupt delivery can proceed from any device on the segment starting from the error detection and until the -resume callback is sent, at which point interrupts are expected to be +restart callback is sent, at which point interrupts are expected to be fully operational. - - There is no guarantee that interrupt delivery is stopped, that is, -a driver that gets an interrupt after detecting an error, or that detects -an error within the interrupt handler such that it prevents proper + - There is no guarantee that interrupt delivery is stopped, that is, ad +river that gets an interrupts after detecting an error, or that detects +and error within the interrupt handler such that it prevents proper ack'ing of the interrupt (and thus removal of the source) should just -return IRQ_NOTHANDLED. It's up to the platform to deal with that -condition, typically by masking the IRQ source during the duration of +return IRQ_NOTHANDLED. It's up to the platform to deal with taht +condition, typically by masking the irq source during the duration of the error handling. It is expected that the platform "knows" which interrupts are routed to error-management capable slots and can deal -with temporarily disabling that IRQ number during error processing (this +with temporarily disabling that irq number during error processing (this isn't terribly complex). That means some IRQ latency for other devices sharing the interrupt, but there is simply no other way. High end platforms aren't supposed to share interrupts between many devices anyway :) ->>> Implementation details for the powerpc platform are discussed in ->>> the file Documentation/powerpc/eeh-pci-error-recovery.txt - ->>> As of this writing, there are six device drivers with patches ->>> implementing error recovery. Not all of these patches are in ->>> mainline yet. These may be used as "examples": ->>> ->>> drivers/scsi/ipr.c ->>> drivers/scsi/sym53cxx_2 ->>> drivers/next/e100.c ->>> drivers/net/e1000 ->>> drivers/net/ixgb ->>> drivers/net/s2io.c - -The End -------- + +Revised: 31 May 2005 Linas Vepstas diff --git a/trunk/Documentation/power/interface.txt b/trunk/Documentation/power/interface.txt index 4117802af0f8..bd4ffb5bd49a 100644 --- a/trunk/Documentation/power/interface.txt +++ b/trunk/Documentation/power/interface.txt @@ -44,7 +44,7 @@ it. /sys/power/image_size controls the size of the image created by the suspend-to-disk mechanism. It can be written a string representing a non-negative integer that will be used as an upper -limit of the image size, in bytes. The suspend-to-disk mechanism will +limit of the image size, in megabytes. The suspend-to-disk mechanism will do its best to ensure the image size will not exceed that number. However, if this turns out to be impossible, it will try to suspend anyway using the smallest image possible. In particular, if "0" is written to this file, the diff --git a/trunk/Documentation/power/swsusp.txt b/trunk/Documentation/power/swsusp.txt index b28b7f04abb8..08c79d4dc540 100644 --- a/trunk/Documentation/power/swsusp.txt +++ b/trunk/Documentation/power/swsusp.txt @@ -27,7 +27,7 @@ echo shutdown > /sys/power/disk; echo disk > /sys/power/state echo platform > /sys/power/disk; echo disk > /sys/power/state -If you want to limit the suspend image size to N bytes, do +If you want to limit the suspend image size to N megabytes, do echo N > /sys/power/image_size diff --git a/trunk/Documentation/powerpc/booting-without-of.txt b/trunk/Documentation/powerpc/booting-without-of.txt deleted file mode 100644 index d02c64953dcd..000000000000 --- a/trunk/Documentation/powerpc/booting-without-of.txt +++ /dev/null @@ -1,1486 +0,0 @@ - Booting the Linux/ppc kernel without Open Firmware - -------------------------------------------------- - - -(c) 2005 Benjamin Herrenschmidt , - IBM Corp. -(c) 2005 Becky Bruce , - Freescale Semiconductor, FSL SOC and 32-bit additions - - May 18, 2005: Rev 0.1 - Initial draft, no chapter III yet. - - May 19, 2005: Rev 0.2 - Add chapter III and bits & pieces here or - clarifies the fact that a lot of things are - optional, the kernel only requires a very - small device tree, though it is encouraged - to provide an as complete one as possible. - - May 24, 2005: Rev 0.3 - Precise that DT block has to be in RAM - - Misc fixes - - Define version 3 and new format version 16 - for the DT block (version 16 needs kernel - patches, will be fwd separately). - String block now has a size, and full path - is replaced by unit name for more - compactness. - linux,phandle is made optional, only nodes - that are referenced by other nodes need it. - "name" property is now automatically - deduced from the unit name - - June 1, 2005: Rev 0.4 - Correct confusion between OF_DT_END and - OF_DT_END_NODE in structure definition. - - Change version 16 format to always align - property data to 4 bytes. Since tokens are - already aligned, that means no specific - required alignement between property size - and property data. The old style variable - alignment would make it impossible to do - "simple" insertion of properties using - memove (thanks Milton for - noticing). Updated kernel patch as well - - Correct a few more alignement constraints - - Add a chapter about the device-tree - compiler and the textural representation of - the tree that can be "compiled" by dtc. - - November 21, 2005: Rev 0.5 - - Additions/generalizations for 32-bit - - Changed to reflect the new arch/powerpc - structure - - Added chapter VI - - - ToDo: - - Add some definitions of interrupt tree (simple/complex) - - Add some definitions for pci host bridges - - Add some common address format examples - - Add definitions for standard properties and "compatible" - names for cells that are not already defined by the existing - OF spec. - - Compare FSL SOC use of PCI to standard and make sure no new - node definition required. - - Add more information about node definitions for SOC devices - that currently have no standard, like the FSL CPM. - - -I - Introduction -================ - -During the recent development of the Linux/ppc64 kernel, and more -specifically, the addition of new platform types outside of the old -IBM pSeries/iSeries pair, it was decided to enforce some strict rules -regarding the kernel entry and bootloader <-> kernel interfaces, in -order to avoid the degeneration that had become the ppc32 kernel entry -point and the way a new platform should be added to the kernel. The -legacy iSeries platform breaks those rules as it predates this scheme, -but no new board support will be accepted in the main tree that -doesn't follows them properly. In addition, since the advent of the -arch/powerpc merged architecture for ppc32 and ppc64, new 32-bit -platforms and 32-bit platforms which move into arch/powerpc will be -required to use these rules as well. - -The main requirement that will be defined in more detail below is -the presence of a device-tree whose format is defined after Open -Firmware specification. However, in order to make life easier -to embedded board vendors, the kernel doesn't require the device-tree -to represent every device in the system and only requires some nodes -and properties to be present. This will be described in detail in -section III, but, for example, the kernel does not require you to -create a node for every PCI device in the system. It is a requirement -to have a node for PCI host bridges in order to provide interrupt -routing informations and memory/IO ranges, among others. It is also -recommended to define nodes for on chip devices and other busses that -don't specifically fit in an existing OF specification. This creates a -great flexibility in the way the kernel can then probe those and match -drivers to device, without having to hard code all sorts of tables. It -also makes it more flexible for board vendors to do minor hardware -upgrades without significantly impacting the kernel code or cluttering -it with special cases. - - -1) Entry point for arch/powerpc -------------------------------- - - There is one and one single entry point to the kernel, at the start - of the kernel image. That entry point supports two calling - conventions: - - a) Boot from Open Firmware. If your firmware is compatible - with Open Firmware (IEEE 1275) or provides an OF compatible - client interface API (support for "interpret" callback of - forth words isn't required), you can enter the kernel with: - - r5 : OF callback pointer as defined by IEEE 1275 - bindings to powerpc. Only the 32 bit client interface - is currently supported - - r3, r4 : address & length of an initrd if any or 0 - - The MMU is either on or off; the kernel will run the - trampoline located in arch/powerpc/kernel/prom_init.c to - extract the device-tree and other information from open - firmware and build a flattened device-tree as described - in b). prom_init() will then re-enter the kernel using - the second method. This trampoline code runs in the - context of the firmware, which is supposed to handle all - exceptions during that time. - - b) Direct entry with a flattened device-tree block. This entry - point is called by a) after the OF trampoline and can also be - called directly by a bootloader that does not support the Open - Firmware client interface. It is also used by "kexec" to - implement "hot" booting of a new kernel from a previous - running one. This method is what I will describe in more - details in this document, as method a) is simply standard Open - Firmware, and thus should be implemented according to the - various standard documents defining it and its binding to the - PowerPC platform. The entry point definition then becomes: - - r3 : physical pointer to the device-tree block - (defined in chapter II) in RAM - - r4 : physical pointer to the kernel itself. This is - used by the assembly code to properly disable the MMU - in case you are entering the kernel with MMU enabled - and a non-1:1 mapping. - - r5 : NULL (as to differenciate with method a) - - Note about SMP entry: Either your firmware puts your other - CPUs in some sleep loop or spin loop in ROM where you can get - them out via a soft reset or some other means, in which case - you don't need to care, or you'll have to enter the kernel - with all CPUs. The way to do that with method b) will be - described in a later revision of this document. - - -2) Board support ----------------- - -64-bit kernels: - - Board supports (platforms) are not exclusive config options. An - arbitrary set of board supports can be built in a single kernel - image. The kernel will "know" what set of functions to use for a - given platform based on the content of the device-tree. Thus, you - should: - - a) add your platform support as a _boolean_ option in - arch/powerpc/Kconfig, following the example of PPC_PSERIES, - PPC_PMAC and PPC_MAPLE. The later is probably a good - example of a board support to start from. - - b) create your main platform file as - "arch/powerpc/platforms/myplatform/myboard_setup.c" and add it - to the Makefile under the condition of your CONFIG_ - option. This file will define a structure of type "ppc_md" - containing the various callbacks that the generic code will - use to get to your platform specific code - - c) Add a reference to your "ppc_md" structure in the - "machines" table in arch/powerpc/kernel/setup_64.c if you are - a 64-bit platform. - - d) request and get assigned a platform number (see PLATFORM_* - constants in include/asm-powerpc/processor.h - -32-bit embedded kernels: - - Currently, board support is essentially an exclusive config option. - The kernel is configured for a single platform. Part of the reason - for this is to keep kernels on embedded systems small and efficient; - part of this is due to the fact the code is already that way. In the - future, a kernel may support multiple platforms, but only if the - platforms feature the same core architectire. A single kernel build - cannot support both configurations with Book E and configurations - with classic Powerpc architectures. - - 32-bit embedded platforms that are moved into arch/powerpc using a - flattened device tree should adopt the merged tree practice of - setting ppc_md up dynamically, even though the kernel is currently - built with support for only a single platform at a time. This allows - unification of the setup code, and will make it easier to go to a - multiple-platform-support model in the future. - -NOTE: I believe the above will be true once Ben's done with the merge -of the boot sequences.... someone speak up if this is wrong! - - To add a 32-bit embedded platform support, follow the instructions - for 64-bit platforms above, with the exception that the Kconfig - option should be set up such that the kernel builds exclusively for - the platform selected. The processor type for the platform should - enable another config option to select the specific board - supported. - -NOTE: If ben doesn't merge the setup files, may need to change this to -point to setup_32.c - - - I will describe later the boot process and various callbacks that - your platform should implement. - - -II - The DT block format -======================== - - -This chapter defines the actual format of the flattened device-tree -passed to the kernel. The actual content of it and kernel requirements -are described later. You can find example of code manipulating that -format in various places, including arch/powerpc/kernel/prom_init.c -which will generate a flattened device-tree from the Open Firmware -representation, or the fs2dt utility which is part of the kexec tools -which will generate one from a filesystem representation. It is -expected that a bootloader like uboot provides a bit more support, -that will be discussed later as well. - -Note: The block has to be in main memory. It has to be accessible in -both real mode and virtual mode with no mapping other than main -memory. If you are writing a simple flash bootloader, it should copy -the block to RAM before passing it to the kernel. - - -1) Header ---------- - - The kernel is entered with r3 pointing to an area of memory that is - roughtly described in include/asm-powerpc/prom.h by the structure - boot_param_header: - -struct boot_param_header { - u32 magic; /* magic word OF_DT_HEADER */ - u32 totalsize; /* total size of DT block */ - u32 off_dt_struct; /* offset to structure */ - u32 off_dt_strings; /* offset to strings */ - u32 off_mem_rsvmap; /* offset to memory reserve map -*/ - u32 version; /* format version */ - u32 last_comp_version; /* last compatible version */ - - /* version 2 fields below */ - u32 boot_cpuid_phys; /* Which physical CPU id we're - booting on */ - /* version 3 fields below */ - u32 size_dt_strings; /* size of the strings block */ -}; - - Along with the constants: - -/* Definitions used by the flattened device tree */ -#define OF_DT_HEADER 0xd00dfeed /* 4: version, - 4: total size */ -#define OF_DT_BEGIN_NODE 0x1 /* Start node: full name -*/ -#define OF_DT_END_NODE 0x2 /* End node */ -#define OF_DT_PROP 0x3 /* Property: name off, - size, content */ -#define OF_DT_END 0x9 - - All values in this header are in big endian format, the various - fields in this header are defined more precisely below. All - "offset" values are in bytes from the start of the header; that is - from the value of r3. - - - magic - - This is a magic value that "marks" the beginning of the - device-tree block header. It contains the value 0xd00dfeed and is - defined by the constant OF_DT_HEADER - - - totalsize - - This is the total size of the DT block including the header. The - "DT" block should enclose all data structures defined in this - chapter (who are pointed to by offsets in this header). That is, - the device-tree structure, strings, and the memory reserve map. - - - off_dt_struct - - This is an offset from the beginning of the header to the start - of the "structure" part the device tree. (see 2) device tree) - - - off_dt_strings - - This is an offset from the beginning of the header to the start - of the "strings" part of the device-tree - - - off_mem_rsvmap - - This is an offset from the beginning of the header to the start - of the reserved memory map. This map is a list of pairs of 64 - bit integers. Each pair is a physical address and a size. The - - list is terminated by an entry of size 0. This map provides the - kernel with a list of physical memory areas that are "reserved" - and thus not to be used for memory allocations, especially during - early initialization. The kernel needs to allocate memory during - boot for things like un-flattening the device-tree, allocating an - MMU hash table, etc... Those allocations must be done in such a - way to avoid overriding critical things like, on Open Firmware - capable machines, the RTAS instance, or on some pSeries, the TCE - tables used for the iommu. Typically, the reserve map should - contain _at least_ this DT block itself (header,total_size). If - you are passing an initrd to the kernel, you should reserve it as - well. You do not need to reserve the kernel image itself. The map - should be 64 bit aligned. - - - version - - This is the version of this structure. Version 1 stops - here. Version 2 adds an additional field boot_cpuid_phys. - Version 3 adds the size of the strings block, allowing the kernel - to reallocate it easily at boot and free up the unused flattened - structure after expansion. Version 16 introduces a new more - "compact" format for the tree itself that is however not backward - compatible. You should always generate a structure of the highest - version defined at the time of your implementation. Currently - that is version 16, unless you explicitely aim at being backward - compatible. - - - last_comp_version - - Last compatible version. This indicates down to what version of - the DT block you are backward compatible. For example, version 2 - is backward compatible with version 1 (that is, a kernel build - for version 1 will be able to boot with a version 2 format). You - should put a 1 in this field if you generate a device tree of - version 1 to 3, or 0x10 if you generate a tree of version 0x10 - using the new unit name format. - - - boot_cpuid_phys - - This field only exist on version 2 headers. It indicate which - physical CPU ID is calling the kernel entry point. This is used, - among others, by kexec. If you are on an SMP system, this value - should match the content of the "reg" property of the CPU node in - the device-tree corresponding to the CPU calling the kernel entry - point (see further chapters for more informations on the required - device-tree contents) - - - So the typical layout of a DT block (though the various parts don't - need to be in that order) looks like this (addresses go from top to - bottom): - - - ------------------------------ - r3 -> | struct boot_param_header | - ------------------------------ - | (alignment gap) (*) | - ------------------------------ - | memory reserve map | - ------------------------------ - | (alignment gap) | - ------------------------------ - | | - | device-tree structure | - | | - ------------------------------ - | (alignment gap) | - ------------------------------ - | | - | device-tree strings | - | | - -----> ------------------------------ - | - | - --- (r3 + totalsize) - - (*) The alignment gaps are not necessarily present; their presence - and size are dependent on the various alignment requirements of - the individual data blocks. - - -2) Device tree generalities ---------------------------- - -This device-tree itself is separated in two different blocks, a -structure block and a strings block. Both need to be aligned to a 4 -byte boundary. - -First, let's quickly describe the device-tree concept before detailing -the storage format. This chapter does _not_ describe the detail of the -required types of nodes & properties for the kernel, this is done -later in chapter III. - -The device-tree layout is strongly inherited from the definition of -the Open Firmware IEEE 1275 device-tree. It's basically a tree of -nodes, each node having two or more named properties. A property can -have a value or not. - -It is a tree, so each node has one and only one parent except for the -root node who has no parent. - -A node has 2 names. The actual node name is generally contained in a -property of type "name" in the node property list whose value is a -zero terminated string and is mandatory for version 1 to 3 of the -format definition (as it is in Open Firmware). Version 0x10 makes it -optional as it can generate it from the unit name defined below. - -There is also a "unit name" that is used to differenciate nodes with -the same name at the same level, it is usually made of the node -name's, the "@" sign, and a "unit address", which definition is -specific to the bus type the node sits on. - -The unit name doesn't exist as a property per-se but is included in -the device-tree structure. It is typically used to represent "path" in -the device-tree. More details about the actual format of these will be -below. - -The kernel powerpc generic code does not make any formal use of the -unit address (though some board support code may do) so the only real -requirement here for the unit address is to ensure uniqueness of -the node unit name at a given level of the tree. Nodes with no notion -of address and no possible sibling of the same name (like /memory or -/cpus) may omit the unit address in the context of this specification, -or use the "@0" default unit address. The unit name is used to define -a node "full path", which is the concatenation of all parent node -unit names separated with "/". - -The root node doesn't have a defined name, and isn't required to have -a name property either if you are using version 3 or earlier of the -format. It also has no unit address (no @ symbol followed by a unit -address). The root node unit name is thus an empty string. The full -path to the root node is "/". - -Every node which actually represents an actual device (that is, a node -which isn't only a virtual "container" for more nodes, like "/cpus" -is) is also required to have a "device_type" property indicating the -type of node . - -Finally, every node that can be referenced from a property in another -node is required to have a "linux,phandle" property. Real open -firmware implementations provide a unique "phandle" value for every -node that the "prom_init()" trampoline code turns into -"linux,phandle" properties. However, this is made optional if the -flattened device tree is used directly. An example of a node -referencing another node via "phandle" is when laying out the -interrupt tree which will be described in a further version of this -document. - -This "linux, phandle" property is a 32 bit value that uniquely -identifies a node. You are free to use whatever values or system of -values, internal pointers, or whatever to generate these, the only -requirement is that every node for which you provide that property has -a unique value for it. - -Here is an example of a simple device-tree. In this example, an "o" -designates a node followed by the node unit name. Properties are -presented with their name followed by their content. "content" -represents an ASCII string (zero terminated) value, while -represents a 32 bit hexadecimal value. The various nodes in this -example will be discussed in a later chapter. At this point, it is -only meant to give you a idea of what a device-tree looks like. I have -purposefully kept the "name" and "linux,phandle" properties which -aren't necessary in order to give you a better idea of what the tree -looks like in practice. - - / o device-tree - |- name = "device-tree" - |- model = "MyBoardName" - |- compatible = "MyBoardFamilyName" - |- #address-cells = <2> - |- #size-cells = <2> - |- linux,phandle = <0> - | - o cpus - | | - name = "cpus" - | | - linux,phandle = <1> - | | - #address-cells = <1> - | | - #size-cells = <0> - | | - | o PowerPC,970@0 - | |- name = "PowerPC,970" - | |- device_type = "cpu" - | |- reg = <0> - | |- clock-frequency = <5f5e1000> - | |- linux,boot-cpu - | |- linux,phandle = <2> - | - o memory@0 - | |- name = "memory" - | |- device_type = "memory" - | |- reg = <00000000 00000000 00000000 20000000> - | |- linux,phandle = <3> - | - o chosen - |- name = "chosen" - |- bootargs = "root=/dev/sda2" - |- linux,platform = <00000600> - |- linux,phandle = <4> - -This tree is almost a minimal tree. It pretty much contains the -minimal set of required nodes and properties to boot a linux kernel; -that is, some basic model informations at the root, the CPUs, and the -physical memory layout. It also includes misc information passed -through /chosen, like in this example, the platform type (mandatory) -and the kernel command line arguments (optional). - -The /cpus/PowerPC,970@0/linux,boot-cpu property is an example of a -property without a value. All other properties have a value. The -significance of the #address-cells and #size-cells properties will be -explained in chapter IV which defines precisely the required nodes and -properties and their content. - - -3) Device tree "structure" block - -The structure of the device tree is a linearized tree structure. The -"OF_DT_BEGIN_NODE" token starts a new node, and the "OF_DT_END_NODE" -ends that node definition. Child nodes are simply defined before -"OF_DT_END_NODE" (that is nodes within the node). A 'token' is a 32 -bit value. The tree has to be "finished" with a OF_DT_END token - -Here's the basic structure of a single node: - - * token OF_DT_BEGIN_NODE (that is 0x00000001) - * for version 1 to 3, this is the node full path as a zero - terminated string, starting with "/". For version 16 and later, - this is the node unit name only (or an empty string for the - root node) - * [align gap to next 4 bytes boundary] - * for each property: - * token OF_DT_PROP (that is 0x00000003) - * 32 bit value of property value size in bytes (or 0 of no - * value) - * 32 bit value of offset in string block of property name - * property value data if any - * [align gap to next 4 bytes boundary] - * [child nodes if any] - * token OF_DT_END_NODE (that is 0x00000002) - -So the node content can be summmarised as a start token, a full path, -a list of properties, a list of child node and an end token. Every -child node is a full node structure itself as defined above. - -4) Device tree 'strings" block - -In order to save space, property names, which are generally redundant, -are stored separately in the "strings" block. This block is simply the -whole bunch of zero terminated strings for all property names -concatenated together. The device-tree property definitions in the -structure block will contain offset values from the beginning of the -strings block. - - -III - Required content of the device tree -========================================= - -WARNING: All "linux,*" properties defined in this document apply only -to a flattened device-tree. If your platform uses a real -implementation of Open Firmware or an implementation compatible with -the Open Firmware client interface, those properties will be created -by the trampoline code in the kernel's prom_init() file. For example, -that's where you'll have to add code to detect your board model and -set the platform number. However, when using the flatenned device-tree -entry point, there is no prom_init() pass, and thus you have to -provide those properties yourself. - - -1) Note about cells and address representation ----------------------------------------------- - -The general rule is documented in the various Open Firmware -documentations. If you chose to describe a bus with the device-tree -and there exist an OF bus binding, then you should follow the -specification. However, the kernel does not require every single -device or bus to be described by the device tree. - -In general, the format of an address for a device is defined by the -parent bus type, based on the #address-cells and #size-cells -property. In the absence of such a property, the parent's parent -values are used, etc... The kernel requires the root node to have -those properties defining addresses format for devices directly mapped -on the processor bus. - -Those 2 properties define 'cells' for representing an address and a -size. A "cell" is a 32 bit number. For example, if both contain 2 -like the example tree given above, then an address and a size are both -composed of 2 cells, and each is a 64 bit number (cells are -concatenated and expected to be in big endian format). Another example -is the way Apple firmware defines them, with 2 cells for an address -and one cell for a size. Most 32-bit implementations should define -#address-cells and #size-cells to 1, which represents a 32-bit value. -Some 32-bit processors allow for physical addresses greater than 32 -bits; these processors should define #address-cells as 2. - -"reg" properties are always a tuple of the type "address size" where -the number of cells of address and size is specified by the bus -#address-cells and #size-cells. When a bus supports various address -spaces and other flags relative to a given address allocation (like -prefetchable, etc...) those flags are usually added to the top level -bits of the physical address. For example, a PCI physical address is -made of 3 cells, the bottom two containing the actual address itself -while the top cell contains address space indication, flags, and pci -bus & device numbers. - -For busses that support dynamic allocation, it's the accepted practice -to then not provide the address in "reg" (keep it 0) though while -providing a flag indicating the address is dynamically allocated, and -then, to provide a separate "assigned-addresses" property that -contains the fully allocated addresses. See the PCI OF bindings for -details. - -In general, a simple bus with no address space bits and no dynamic -allocation is preferred if it reflects your hardware, as the existing -kernel address parsing functions will work out of the box. If you -define a bus type with a more complex address format, including things -like address space bits, you'll have to add a bus translator to the -prom_parse.c file of the recent kernels for your bus type. - -The "reg" property only defines addresses and sizes (if #size-cells -is -non-0) within a given bus. In order to translate addresses upward -(that is into parent bus addresses, and possibly into cpu physical -addresses), all busses must contain a "ranges" property. If the -"ranges" property is missing at a given level, it's assumed that -translation isn't possible. The format of the "ranges" proprety for a -bus is a list of: - - bus address, parent bus address, size - -"bus address" is in the format of the bus this bus node is defining, -that is, for a PCI bridge, it would be a PCI address. Thus, (bus -address, size) defines a range of addresses for child devices. "parent -bus address" is in the format of the parent bus of this bus. For -example, for a PCI host controller, that would be a CPU address. For a -PCI<->ISA bridge, that would be a PCI address. It defines the base -address in the parent bus where the beginning of that range is mapped. - -For a new 64 bit powerpc board, I recommend either the 2/2 format or -Apple's 2/1 format which is slightly more compact since sizes usually -fit in a single 32 bit word. New 32 bit powerpc boards should use a -1/1 format, unless the processor supports physical addresses greater -than 32-bits, in which case a 2/1 format is recommended. - - -2) Note about "compatible" properties -------------------------------------- - -These properties are optional, but recommended in devices and the root -node. The format of a "compatible" property is a list of concatenated -zero terminated strings. They allow a device to express its -compatibility with a family of similar devices, in some cases, -allowing a single driver to match against several devices regardless -of their actual names. - -3) Note about "name" properties -------------------------------- - -While earlier users of Open Firmware like OldWorld macintoshes tended -to use the actual device name for the "name" property, it's nowadays -considered a good practice to use a name that is closer to the device -class (often equal to device_type). For example, nowadays, ethernet -controllers are named "ethernet", an additional "model" property -defining precisely the chip type/model, and "compatible" property -defining the family in case a single driver can driver more than one -of these chips. However, the kernel doesn't generally put any -restriction on the "name" property; it is simply considered good -practice to follow the standard and its evolutions as closely as -possible. - -Note also that the new format version 16 makes the "name" property -optional. If it's absent for a node, then the node's unit name is then -used to reconstruct the name. That is, the part of the unit name -before the "@" sign is used (or the entire unit name if no "@" sign -is present). - -4) Note about node and property names and character set -------------------------------------------------------- - -While open firmware provides more flexibe usage of 8859-1, this -specification enforces more strict rules. Nodes and properties should -be comprised only of ASCII characters 'a' to 'z', '0' to -'9', ',', '.', '_', '+', '#', '?', and '-'. Node names additionally -allow uppercase characters 'A' to 'Z' (property names should be -lowercase. The fact that vendors like Apple don't respect this rule is -irrelevant here). Additionally, node and property names should always -begin with a character in the range 'a' to 'z' (or 'A' to 'Z' for node -names). - -The maximum number of characters for both nodes and property names -is 31. In the case of node names, this is only the leftmost part of -a unit name (the pure "name" property), it doesn't include the unit -address which can extend beyond that limit. - - -5) Required nodes and properties --------------------------------- - These are all that are currently required. However, it is strongly - recommended that you expose PCI host bridges as documented in the - PCI binding to open firmware, and your interrupt tree as documented - in OF interrupt tree specification. - - a) The root node - - The root node requires some properties to be present: - - - model : this is your board name/model - - #address-cells : address representation for "root" devices - - #size-cells: the size representation for "root" devices - - Additionally, some recommended properties are: - - - compatible : the board "family" generally finds its way here, - for example, if you have 2 board models with a similar layout, - that typically get driven by the same platform code in the - kernel, you would use a different "model" property but put a - value in "compatible". The kernel doesn't directly use that - value (see /chosen/linux,platform for how the kernel choses a - platform type) but it is generally useful. - - The root node is also generally where you add additional properties - specific to your board like the serial number if any, that sort of - thing. it is recommended that if you add any "custom" property whose - name may clash with standard defined ones, you prefix them with your - vendor name and a comma. - - b) The /cpus node - - This node is the parent of all individual CPU nodes. It doesn't - have any specific requirements, though it's generally good practice - to have at least: - - #address-cells = <00000001> - #size-cells = <00000000> - - This defines that the "address" for a CPU is a single cell, and has - no meaningful size. This is not necessary but the kernel will assume - that format when reading the "reg" properties of a CPU node, see - below - - c) The /cpus/* nodes - - So under /cpus, you are supposed to create a node for every CPU on - the machine. There is no specific restriction on the name of the - CPU, though It's common practice to call it PowerPC,. For - example, Apple uses PowerPC,G5 while IBM uses PowerPC,970FX. - - Required properties: - - - device_type : has to be "cpu" - - reg : This is the physical cpu number, it's a single 32 bit cell - and is also used as-is as the unit number for constructing the - unit name in the full path. For example, with 2 CPUs, you would - have the full path: - /cpus/PowerPC,970FX@0 - /cpus/PowerPC,970FX@1 - (unit addresses do not require leading zeroes) - - d-cache-line-size : one cell, L1 data cache line size in bytes - - i-cache-line-size : one cell, L1 instruction cache line size in - bytes - - d-cache-size : one cell, size of L1 data cache in bytes - - i-cache-size : one cell, size of L1 instruction cache in bytes - - linux, boot-cpu : Should be defined if this cpu is the boot cpu. - - Recommended properties: - - - timebase-frequency : a cell indicating the frequency of the - timebase in Hz. This is not directly used by the generic code, - but you are welcome to copy/paste the pSeries code for setting - the kernel timebase/decrementer calibration based on this - value. - - clock-frequency : a cell indicating the CPU core clock frequency - in Hz. A new property will be defined for 64 bit values, but if - your frequency is < 4Ghz, one cell is enough. Here as well as - for the above, the common code doesn't use that property, but - you are welcome to re-use the pSeries or Maple one. A future - kernel version might provide a common function for this. - - You are welcome to add any property you find relevant to your board, - like some information about the mechanism used to soft-reset the - CPUs. For example, Apple puts the GPIO number for CPU soft reset - lines in there as a "soft-reset" property since they start secondary - CPUs by soft-resetting them. - - - d) the /memory node(s) - - To define the physical memory layout of your board, you should - create one or more memory node(s). You can either create a single - node with all memory ranges in its reg property, or you can create - several nodes, as you wish. The unit address (@ part) used for the - full path is the address of the first range of memory defined by a - given node. If you use a single memory node, this will typically be - @0. - - Required properties: - - - device_type : has to be "memory" - - reg : This property contains all the physical memory ranges of - your board. It's a list of addresses/sizes concatenated - together, with the number of cells of each defined by the - #address-cells and #size-cells of the root node. For example, - with both of these properties beeing 2 like in the example given - earlier, a 970 based machine with 6Gb of RAM could typically - have a "reg" property here that looks like: - - 00000000 00000000 00000000 80000000 - 00000001 00000000 00000001 00000000 - - That is a range starting at 0 of 0x80000000 bytes and a range - starting at 0x100000000 and of 0x100000000 bytes. You can see - that there is no memory covering the IO hole between 2Gb and - 4Gb. Some vendors prefer splitting those ranges into smaller - segments, but the kernel doesn't care. - - e) The /chosen node - - This node is a bit "special". Normally, that's where open firmware - puts some variable environment information, like the arguments, or - phandle pointers to nodes like the main interrupt controller, or the - default input/output devices. - - This specification makes a few of these mandatory, but also defines - some linux-specific properties that would be normally constructed by - the prom_init() trampoline when booting with an OF client interface, - but that you have to provide yourself when using the flattened format. - - Required properties: - - - linux,platform : This is your platform number as assigned by the - architecture maintainers - - Recommended properties: - - - bootargs : This zero-terminated string is passed as the kernel - command line - - linux,stdout-path : This is the full path to your standard - console device if any. Typically, if you have serial devices on - your board, you may want to put the full path to the one set as - the default console in the firmware here, for the kernel to pick - it up as it's own default console. If you look at the funciton - set_preferred_console() in arch/ppc64/kernel/setup.c, you'll see - that the kernel tries to find out the default console and has - knowledge of various types like 8250 serial ports. You may want - to extend this function to add your own. - - interrupt-controller : This is one cell containing a phandle - value that matches the "linux,phandle" property of your main - interrupt controller node. May be used for interrupt routing. - - - Note that u-boot creates and fills in the chosen node for platforms - that use it. - - f) the /soc node - - This node is used to represent a system-on-a-chip (SOC) and must be - present if the processor is a SOC. The top-level soc node contains - information that is global to all devices on the SOC. The node name - should contain a unit address for the SOC, which is the base address - of the memory-mapped register set for the SOC. The name of an soc - node should start with "soc", and the remainder of the name should - represent the part number for the soc. For example, the MPC8540's - soc node would be called "soc8540". - - Required properties: - - - device_type : Should be "soc" - - ranges : Should be defined as specified in 1) to describe the - translation of SOC addresses for memory mapped SOC registers. - - bus-frequency: Contains the bus frequency for the SOC node. - Typically, the value of this field is filled in by the boot - loader. - - - Recommended properties: - - - reg : This property defines the address and size of the - memory-mapped registers that are used for the SOC node itself. - It does not include the child device registers - these will be - defined inside each child node. The address specified in the - "reg" property should match the unit address of the SOC node. - - #address-cells : Address representation for "soc" devices. The - format of this field may vary depending on whether or not the - device registers are memory mapped. For memory mapped - registers, this field represents the number of cells needed to - represent the address of the registers. For SOCs that do not - use MMIO, a special address format should be defined that - contains enough cells to represent the required information. - See 1) above for more details on defining #address-cells. - - #size-cells : Size representation for "soc" devices - - #interrupt-cells : Defines the width of cells used to represent - interrupts. Typically this value is <2>, which includes a - 32-bit number that represents the interrupt number, and a - 32-bit number that represents the interrupt sense and level. - This field is only needed if the SOC contains an interrupt - controller. - - The SOC node may contain child nodes for each SOC device that the - platform uses. Nodes should not be created for devices which exist - on the SOC but are not used by a particular platform. See chapter VI - for more information on how to specify devices that are part of an -SOC. - - Example SOC node for the MPC8540: - - soc8540@e0000000 { - #address-cells = <1>; - #size-cells = <1>; - #interrupt-cells = <2>; - device_type = "soc"; - ranges = <00000000 e0000000 00100000> - reg = ; - bus-frequency = <0>; - } - - - -IV - "dtc", the device tree compiler -==================================== - - -dtc source code can be found at - - -WARNING: This version is still in early development stage; the -resulting device-tree "blobs" have not yet been validated with the -kernel. The current generated bloc lacks a useful reserve map (it will -be fixed to generate an empty one, it's up to the bootloader to fill -it up) among others. The error handling needs work, bugs are lurking, -etc... - -dtc basically takes a device-tree in a given format and outputs a -device-tree in another format. The currently supported formats are: - - Input formats: - ------------- - - - "dtb": "blob" format, that is a flattened device-tree block - with - header all in a binary blob. - - "dts": "source" format. This is a text file containing a - "source" for a device-tree. The format is defined later in this - chapter. - - "fs" format. This is a representation equivalent to the - output of /proc/device-tree, that is nodes are directories and - properties are files - - Output formats: - --------------- - - - "dtb": "blob" format - - "dts": "source" format - - "asm": assembly language file. This is a file that can be - sourced by gas to generate a device-tree "blob". That file can - then simply be added to your Makefile. Additionally, the - assembly file exports some symbols that can be use - - -The syntax of the dtc tool is - - dtc [-I ] [-O ] - [-o output-filename] [-V output_version] input_filename - - -The "output_version" defines what versio of the "blob" format will be -generated. Supported versions are 1,2,3 and 16. The default is -currently version 3 but that may change in the future to version 16. - -Additionally, dtc performs various sanity checks on the tree, like the -uniqueness of linux,phandle properties, validity of strings, etc... - -The format of the .dts "source" file is "C" like, supports C and C++ -style commments. - -/ { -} - -The above is the "device-tree" definition. It's the only statement -supported currently at the toplevel. - -/ { - property1 = "string_value"; /* define a property containing a 0 - * terminated string - */ - - property2 = <1234abcd>; /* define a property containing a - * numerical 32 bits value (hexadecimal) - */ - - property3 = <12345678 12345678 deadbeef>; - /* define a property containing 3 - * numerical 32 bits values (cells) in - * hexadecimal - */ - property4 = [0a 0b 0c 0d de ea ad be ef]; - /* define a property whose content is - * an arbitrary array of bytes - */ - - childnode@addresss { /* define a child node named "childnode" - * whose unit name is "childnode at - * address" - */ - - childprop = "hello\n"; /* define a property "childprop" of - * childnode (in this case, a string) - */ - }; -}; - -Nodes can contain other nodes etc... thus defining the hierarchical -structure of the tree. - -Strings support common escape sequences from C: "\n", "\t", "\r", -"\(octal value)", "\x(hex value)". - -It is also suggested that you pipe your source file through cpp (gcc -preprocessor) so you can use #include's, #define for constants, etc... - -Finally, various options are planned but not yet implemented, like -automatic generation of phandles, labels (exported to the asm file so -you can point to a property content and change it easily from whatever -you link the device-tree with), label or path instead of numeric value -in some cells to "point" to a node (replaced by a phandle at compile -time), export of reserve map address to the asm file, ability to -specify reserve map content at compile time, etc... - -We may provide a .h include file with common definitions of that -proves useful for some properties (like building PCI properties or -interrupt maps) though it may be better to add a notion of struct -definitions to the compiler... - - -V - Recommendations for a bootloader -==================================== - - -Here are some various ideas/recommendations that have been proposed -while all this has been defined and implemented. - - - The bootloader may want to be able to use the device-tree itself - and may want to manipulate it (to add/edit some properties, - like physical memory size or kernel arguments). At this point, 2 - choices can be made. Either the bootloader works directly on the - flattened format, or the bootloader has its own internal tree - representation with pointers (similar to the kernel one) and - re-flattens the tree when booting the kernel. The former is a bit - more difficult to edit/modify, the later requires probably a bit - more code to handle the tree structure. Note that the structure - format has been designed so it's relatively easy to "insert" - properties or nodes or delete them by just memmoving things - around. It contains no internal offsets or pointers for this - purpose. - - - An example of code for iterating nodes & retreiving properties - directly from the flattened tree format can be found in the kernel - file arch/ppc64/kernel/prom.c, look at scan_flat_dt() function, - it's usage in early_init_devtree(), and the corresponding various - early_init_dt_scan_*() callbacks. That code can be re-used in a - GPL bootloader, and as the author of that code, I would be happy - do discuss possible free licencing to any vendor who wishes to - integrate all or part of this code into a non-GPL bootloader. - - - -VI - System-on-a-chip devices and nodes -======================================= - -Many companies are now starting to develop system-on-a-chip -processors, where the processor core (cpu) and many peripheral devices -exist on a single piece of silicon. For these SOCs, an SOC node -should be used that defines child nodes for the devices that make -up the SOC. While platforms are not required to use this model in -order to boot the kernel, it is highly encouraged that all SOC -implementations define as complete a flat-device-tree as possible to -describe the devices on the SOC. This will allow for the -genericization of much of the kernel code. - - -1) Defining child nodes of an SOC ---------------------------------- - -Each device that is part of an SOC may have its own node entry inside -the SOC node. For each device that is included in the SOC, the unit -address property represents the address offset for this device's -memory-mapped registers in the parent's address space. The parent's -address space is defined by the "ranges" property in the top-level soc -node. The "reg" property for each node that exists directly under the -SOC node should contain the address mapping from the child address space -to the parent SOC address space and the size of the device's -memory-mapped register file. - -For many devices that may exist inside an SOC, there are predefined -specifications for the format of the device tree node. All SOC child -nodes should follow these specifications, except where noted in this -document. - -See appendix A for an example partial SOC node definition for the -MPC8540. - - -2) Specifying interrupt information for SOC devices ---------------------------------------------------- - -Each device that is part of an SOC and which generates interrupts -should have the following properties: - - - interrupt-parent : contains the phandle of the interrupt - controller which handles interrupts for this device - - interrupts : a list of tuples representing the interrupt - number and the interrupt sense and level for each interupt - for this device. - -This information is used by the kernel to build the interrupt table -for the interrupt controllers in the system. - -Sense and level information should be encoded as follows: - - Devices connected to openPIC-compatible controllers should encode - sense and polarity as follows: - - 0 = high to low edge sensitive type enabled - 1 = active low level sensitive type enabled - 2 = low to high edge sensitive type enabled - 3 = active high level sensitive type enabled - - ISA PIC interrupt controllers should adhere to the ISA PIC - encodings listed below: - - 0 = active low level sensitive type enabled - 1 = active high level sensitive type enabled - 2 = high to low edge sensitive type enabled - 3 = low to high edge sensitive type enabled - - - -3) Representing devices without a current OF specification ----------------------------------------------------------- - -Currently, there are many devices on SOCs that do not have a standard -representation pre-defined as part of the open firmware -specifications, mainly because the boards that contain these SOCs are -not currently booted using open firmware. This section contains -descriptions for the SOC devices for which new nodes have been -defined; this list will expand as more and more SOC-containing -platforms are moved over to use the flattened-device-tree model. - - a) MDIO IO device - - The MDIO is a bus to which the PHY devices are connected. For each - device that exists on this bus, a child node should be created. See - the definition of the PHY node below for an example of how to define - a PHY. - - Required properties: - - reg : Offset and length of the register set for the device - - device_type : Should be "mdio" - - compatible : Should define the compatible device type for the - mdio. Currently, this is most likely to be "gianfar" - - Example: - - mdio@24520 { - reg = <24520 20>; - device_type = "mdio"; - compatible = "gianfar"; - - ethernet-phy@0 { - ...... - }; - }; - - - b) Gianfar-compatible ethernet nodes - - Required properties: - - - device_type : Should be "network" - - model : Model of the device. Can be "TSEC", "eTSEC", or "FEC" - - compatible : Should be "gianfar" - - reg : Offset and length of the register set for the device - - address : List of bytes representing the ethernet address of - this controller - - interrupts : where a is the interrupt number and b is a - field that represents an encoding of the sense and level - information for the interrupt. This should be encoded based on - the information in section 2) depending on the type of interrupt - controller you have. - - interrupt-parent : the phandle for the interrupt controller that - services interrupts for this device. - - phy-handle : The phandle for the PHY connected to this ethernet - controller. - - Example: - - ethernet@24000 { - #size-cells = <0>; - device_type = "network"; - model = "TSEC"; - compatible = "gianfar"; - reg = <24000 1000>; - address = [ 00 E0 0C 00 73 00 ]; - interrupts = ; - interrupt-parent = <40000>; - phy-handle = <2452000> - }; - - - - c) PHY nodes - - Required properties: - - - device_type : Should be "ethernet-phy" - - interrupts : where a is the interrupt number and b is a - field that represents an encoding of the sense and level - information for the interrupt. This should be encoded based on - the information in section 2) depending on the type of interrupt - controller you have. - - interrupt-parent : the phandle for the interrupt controller that - services interrupts for this device. - - reg : The ID number for the phy, usually a small integer - - linux,phandle : phandle for this node; likely referenced by an - ethernet controller node. - - - Example: - - ethernet-phy@0 { - linux,phandle = <2452000> - interrupt-parent = <40000>; - interrupts = <35 1>; - reg = <0>; - device_type = "ethernet-phy"; - }; - - - d) Interrupt controllers - - Some SOC devices contain interrupt controllers that are different - from the standard Open PIC specification. The SOC device nodes for - these types of controllers should be specified just like a standard - OpenPIC controller. Sense and level information should be encoded - as specified in section 2) of this chapter for each device that - specifies an interrupt. - - Example : - - pic@40000 { - linux,phandle = <40000>; - clock-frequency = <0>; - interrupt-controller; - #address-cells = <0>; - reg = <40000 40000>; - built-in; - compatible = "chrp,open-pic"; - device_type = "open-pic"; - big-endian; - }; - - - e) I2C - - Required properties : - - - device_type : Should be "i2c" - - reg : Offset and length of the register set for the device - - Recommended properties : - - - compatible : Should be "fsl-i2c" for parts compatible with - Freescale I2C specifications. - - interrupts : where a is the interrupt number and b is a - field that represents an encoding of the sense and level - information for the interrupt. This should be encoded based on - the information in section 2) depending on the type of interrupt - controller you have. - - interrupt-parent : the phandle for the interrupt controller that - services interrupts for this device. - - dfsrr : boolean; if defined, indicates that this I2C device has - a digital filter sampling rate register - - fsl5200-clocking : boolean; if defined, indicated that this device - uses the FSL 5200 clocking mechanism. - - Example : - - i2c@3000 { - interrupt-parent = <40000>; - interrupts = <1b 3>; - reg = <3000 18>; - device_type = "i2c"; - compatible = "fsl-i2c"; - dfsrr; - }; - - - f) Freescale SOC USB controllers - - The device node for a USB controller that is part of a Freescale - SOC is as described in the document "Open Firmware Recommended - Practice : Universal Serial Bus" with the following modifications - and additions : - - Required properties : - - compatible : Should be "fsl-usb2-mph" for multi port host usb - controllers, or "fsl-usb2-dr" for dual role usb controllers - - phy_type : For multi port host usb controllers, should be one of - "ulpi", or "serial". For dual role usb controllers, should be - one of "ulpi", "utmi", "utmi_wide", or "serial". - - reg : Offset and length of the register set for the device - - port0 : boolean; if defined, indicates port0 is connected for - fsl-usb2-mph compatible controllers. Either this property or - "port1" (or both) must be defined for "fsl-usb2-mph" compatible - controllers. - - port1 : boolean; if defined, indicates port1 is connected for - fsl-usb2-mph compatible controllers. Either this property or - "port0" (or both) must be defined for "fsl-usb2-mph" compatible - controllers. - - Recommended properties : - - interrupts : where a is the interrupt number and b is a - field that represents an encoding of the sense and level - information for the interrupt. This should be encoded based on - the information in section 2) depending on the type of interrupt - controller you have. - - interrupt-parent : the phandle for the interrupt controller that - services interrupts for this device. - - Example multi port host usb controller device node : - usb@22000 { - device_type = "usb"; - compatible = "fsl-usb2-mph"; - reg = <22000 1000>; - #address-cells = <1>; - #size-cells = <0>; - interrupt-parent = <700>; - interrupts = <27 1>; - phy_type = "ulpi"; - port0; - port1; - }; - - Example dual role usb controller device node : - usb@23000 { - device_type = "usb"; - compatible = "fsl-usb2-dr"; - reg = <23000 1000>; - #address-cells = <1>; - #size-cells = <0>; - interrupt-parent = <700>; - interrupts = <26 1>; - phy = "ulpi"; - }; - - - More devices will be defined as this spec matures. - - -Appendix A - Sample SOC node for MPC8540 -======================================== - -Note that the #address-cells and #size-cells for the SoC node -in this example have been explicitly listed; these are likely -not necessary as they are usually the same as the root node. - - soc8540@e0000000 { - #address-cells = <1>; - #size-cells = <1>; - #interrupt-cells = <2>; - device_type = "soc"; - ranges = <00000000 e0000000 00100000> - reg = ; - bus-frequency = <0>; - - mdio@24520 { - reg = <24520 20>; - device_type = "mdio"; - compatible = "gianfar"; - - ethernet-phy@0 { - linux,phandle = <2452000> - interrupt-parent = <40000>; - interrupts = <35 1>; - reg = <0>; - device_type = "ethernet-phy"; - }; - - ethernet-phy@1 { - linux,phandle = <2452001> - interrupt-parent = <40000>; - interrupts = <35 1>; - reg = <1>; - device_type = "ethernet-phy"; - }; - - ethernet-phy@3 { - linux,phandle = <2452002> - interrupt-parent = <40000>; - interrupts = <35 1>; - reg = <3>; - device_type = "ethernet-phy"; - }; - - }; - - ethernet@24000 { - #size-cells = <0>; - device_type = "network"; - model = "TSEC"; - compatible = "gianfar"; - reg = <24000 1000>; - address = [ 00 E0 0C 00 73 00 ]; - interrupts = ; - interrupt-parent = <40000>; - phy-handle = <2452000>; - }; - - ethernet@25000 { - #address-cells = <1>; - #size-cells = <0>; - device_type = "network"; - model = "TSEC"; - compatible = "gianfar"; - reg = <25000 1000>; - address = [ 00 E0 0C 00 73 01 ]; - interrupts = <13 3 14 3 18 3>; - interrupt-parent = <40000>; - phy-handle = <2452001>; - }; - - ethernet@26000 { - #address-cells = <1>; - #size-cells = <0>; - device_type = "network"; - model = "FEC"; - compatible = "gianfar"; - reg = <26000 1000>; - address = [ 00 E0 0C 00 73 02 ]; - interrupts = <19 3>; - interrupt-parent = <40000>; - phy-handle = <2452002>; - }; - - serial@4500 { - device_type = "serial"; - compatible = "ns16550"; - reg = <4500 100>; - clock-frequency = <0>; - interrupts = <1a 3>; - interrupt-parent = <40000>; - }; - - pic@40000 { - linux,phandle = <40000>; - clock-frequency = <0>; - interrupt-controller; - #address-cells = <0>; - reg = <40000 40000>; - built-in; - compatible = "chrp,open-pic"; - device_type = "open-pic"; - big-endian; - }; - - i2c@3000 { - interrupt-parent = <40000>; - interrupts = <1b 3>; - reg = <3000 18>; - device_type = "i2c"; - compatible = "fsl-i2c"; - dfsrr; - }; - - }; diff --git a/trunk/Documentation/scsi/ChangeLog.megaraid_sas b/trunk/Documentation/scsi/ChangeLog.megaraid_sas deleted file mode 100644 index f8c16cbf56ba..000000000000 --- a/trunk/Documentation/scsi/ChangeLog.megaraid_sas +++ /dev/null @@ -1,24 +0,0 @@ -1 Release Date : Mon Jan 23 14:09:01 PST 2006 - Sumant Patro -2 Current Version : 00.00.02.02 -3 Older Version : 00.00.02.01 - -i. New template defined to represent each family of controllers (identified by processor used). - The template will have defintions that will be initialised to appropritae values for a specific family of controllers. The template definition has four function pointers. During driver initialisation the function pointers will be set based on the controller family type. This change is done to support new controllers that has different processors and thus different register set. - - -Sumant Patro - -1 Release Date : Mon Dec 19 14:36:26 PST 2005 - Sumant Patro -2 Current Version : 00.00.02.00-rc4 -3 Older Version : 00.00.02.01 - -i. Code reorganized to remove code duplication in megasas_build_cmd. - - "There's a lot of duplicate code megasas_build_cmd. Move that out of the different codepathes and merge the reminder of megasas_build_cmd into megasas_queue_command" - - - Christoph Hellwig - -ii. Defined MEGASAS_IOC_FIRMWARE32 for code paths that handles 32 bit applications in 64 bit systems. - - "MEGASAS_IOC_FIRMWARE can't be redefined if CONFIG_COMPAT is set, we need to define a MEGASAS_IOC_FIRMWARE32 define so native binaries continue to work" - - - Christoph Hellwig diff --git a/trunk/Documentation/scsi/aic79xx.txt b/trunk/Documentation/scsi/aic79xx.txt index 382b439b439e..0aeef740a95a 100644 --- a/trunk/Documentation/scsi/aic79xx.txt +++ b/trunk/Documentation/scsi/aic79xx.txt @@ -1,5 +1,5 @@ ==================================================================== -= Adaptec Ultra320 Family Manager Set = += Adaptec Ultra320 Family Manager Set v1.3.11 = = = = README for = = The Linux Operating System = @@ -63,11 +63,6 @@ The following information is available in this file: 68-pin) 2. Version History - 3.0 (December 1st, 2005) - - Updated driver to use SCSI transport class infrastructure - - Upported sequencer and core fixes from adaptec released - version 2.0.15 of the driver. - 1.3.11 (July 11, 2003) - Fix several deadlock issues. - Add 29320ALP and 39320B Id's. @@ -199,7 +194,7 @@ The following information is available in this file: supported) - Support for the PCI-X standard up to 133MHz - Support for the PCI v2.2 standard - - Domain Validation + - Domain Validation 2.2. Operating System Support: - Redhat Linux 7.2, 7.3, 8.0, Advanced Server 2.1 @@ -416,53 +411,77 @@ The following information is available in this file: http://www.adaptec.com. -5. Adaptec Customer Support +5. Contacting Adaptec A Technical Support Identification (TSID) Number is required for Adaptec technical support. - The 12-digit TSID can be found on the white barcode-type label - included inside the box with your product. The TSID helps us + included inside the box with your product. The TSID helps us provide more efficient service by accurately identifying your product and support status. - Support Options - Search the Adaptec Support Knowledgebase (ASK) at http://ask.adaptec.com for articles, troubleshooting tips, and - frequently asked questions about your product. + frequently asked questions for your product. - For support via Email, submit your question to Adaptec's - Technical Support Specialists at http://ask.adaptec.com/. + Technical Support Specialists at http://ask.adaptec.com. North America - - Visit our Web site at http://www.adaptec.com/. - - For information about Adaptec's support options, call - 408-957-2550, 24 hours a day, 7 days a week. - - To speak with a Technical Support Specialist, - * For hardware products, call 408-934-7274, - Monday to Friday, 3:00 am to 5:00 pm, PDT. - * For RAID and Fibre Channel products, call 321-207-2000, - Monday to Friday, 3:00 am to 5:00 pm, PDT. - To expedite your service, have your computer with you. - - To order Adaptec products, including accessories and cables, - call 408-957-7274. To order cables online go to - http://www.adaptec.com/buy-cables/. + - Visit our Web site at http://www.adaptec.com. + - To speak with a Fibre Channel/RAID/External Storage Technical + Support Specialist, call 1-321-207-2000, + Hours: Monday-Friday, 3:00 A.M. to 5:00 P.M., PST. + (Not open on holidays) + - For Technical Support in all other technologies including + SCSI, call 1-408-934-7274, + Hours: Monday-Friday, 6:00 A.M. to 5:00 P.M., PST. + (Not open on holidays) + - For after hours support, call 1-800-416-8066 ($99/call, + $149/call on holidays) + - To order Adaptec products including software and cables, call + 1-800-442-7274 or 1-408-957-7274. You can also visit our + online store at http://www.adaptecstore.com Europe - - Visit our Web site at http://www.adaptec-europe.com/. - - To speak with a Technical Support Specialist, call, or email, - * German: +49 89 4366 5522, Monday-Friday, 9:00-17:00 CET, - http://ask-de.adaptec.com/. - * French: +49 89 4366 5533, Monday-Friday, 9:00-17:00 CET, - http://ask-fr.adaptec.com/. - * English: +49 89 4366 5544, Monday-Friday, 9:00-17:00 GMT, - http://ask.adaptec.com/. - - You can order Adaptec cables online at - http://www.adaptec.com/buy-cables/. + - Visit our Web site at http://www.adaptec-europe.com. + - English and French: To speak with a Technical Support + Specialist, call one of the following numbers: + - English: +32-2-352-3470 + - French: +32-2-352-3460 + Hours: Monday-Thursday, 10:00 to 12:30, 13:30 to 17:30 CET + Friday, 10:00 to 12:30, 13:30 to 16:30 CET + - German: To speak with a Technical Support Specialist, + call +49-89-456-40660 + Hours: Monday-Thursday, 09:30 to 12:30, 13:30 to 16:30 CET + Friday, 09:30 to 12:30, 13:30 to 15:00 CET + - To order Adaptec products, including accessories and cables: + - UK: +0800-96-65-26 or fax +0800-731-02-95 + - Other European countries: +32-11-300-379 + + Australia and New Zealand + - Visit our Web site at http://www.adaptec.com.au. + - To speak with a Technical Support Specialist, call + +612-9416-0698 + Hours: Monday-Friday, 10:00 A.M. to 4:30 P.M., EAT + (Not open on holidays) Japan - - Visit our web site at http://www.adaptec.co.jp/. - To speak with a Technical Support Specialist, call - +81 3 5308 6120, Monday-Friday, 9:00 a.m. to 12:00 p.m., - 1:00 p.m. to 6:00 p.m. + +81-3-5308-6120 + Hours: Monday-Friday, 9:00 a.m. to 12:00 p.m., 1:00 p.m. to + 6:00 p.m. TSC + + Hong Kong and China + - To speak with a Technical Support Specialist, call + +852-2869-7200 + Hours: Monday-Friday, 10:00 to 17:00. + - Fax Technical Support at +852-2869-7100. + + Singapore + - To speak with a Technical Support Specialist, call + +65-245-7470 + Hours: Monday-Friday, 10:00 to 17:00. + - Fax Technical Support at +852-2869-7100 ------------------------------------------------------------------- /* diff --git a/trunk/Documentation/scsi/aic7xxx.txt b/trunk/Documentation/scsi/aic7xxx.txt index 3481fcded4c2..47e74ddc4bc9 100644 --- a/trunk/Documentation/scsi/aic7xxx.txt +++ b/trunk/Documentation/scsi/aic7xxx.txt @@ -309,57 +309,81 @@ The following information is available in this file: ----------------------------------------------------------------- Example: - 'options aic7xxx aic7xxx=verbose,no_probe,tag_info:{{},{,,10}},seltime:1' + 'options aic7xxx aic7xxx=verbose,no_probe,tag_info:{{},{,,10}},seltime:1" enables verbose logging, Disable EISA/VLB probing, and set tag depth on Controller 1/Target 2 to 10 tags. -4. Adaptec Customer Support +3. Contacting Adaptec A Technical Support Identification (TSID) Number is required for Adaptec technical support. - The 12-digit TSID can be found on the white barcode-type label - included inside the box with your product. The TSID helps us + included inside the box with your product. The TSID helps us provide more efficient service by accurately identifying your product and support status. - Support Options - Search the Adaptec Support Knowledgebase (ASK) at http://ask.adaptec.com for articles, troubleshooting tips, and - frequently asked questions about your product. + frequently asked questions for your product. - For support via Email, submit your question to Adaptec's - Technical Support Specialists at http://ask.adaptec.com/. + Technical Support Specialists at http://ask.adaptec.com. North America - - Visit our Web site at http://www.adaptec.com/. - - For information about Adaptec's support options, call - 408-957-2550, 24 hours a day, 7 days a week. - - To speak with a Technical Support Specialist, - * For hardware products, call 408-934-7274, - Monday to Friday, 3:00 am to 5:00 pm, PDT. - * For RAID and Fibre Channel products, call 321-207-2000, - Monday to Friday, 3:00 am to 5:00 pm, PDT. - To expedite your service, have your computer with you. - - To order Adaptec products, including accessories and cables, - call 408-957-7274. To order cables online go to - http://www.adaptec.com/buy-cables/. + - Visit our Web site at http://www.adaptec.com. + - To speak with a Fibre Channel/RAID/External Storage Technical + Support Specialist, call 1-321-207-2000, + Hours: Monday-Friday, 3:00 A.M. to 5:00 P.M., PST. + (Not open on holidays) + - For Technical Support in all other technologies including + SCSI, call 1-408-934-7274, + Hours: Monday-Friday, 6:00 A.M. to 5:00 P.M., PST. + (Not open on holidays) + - For after hours support, call 1-800-416-8066 ($99/call, + $149/call on holidays) + - To order Adaptec products including software and cables, call + 1-800-442-7274 or 1-408-957-7274. You can also visit our + online store at http://www.adaptecstore.com Europe - - Visit our Web site at http://www.adaptec-europe.com/. - - To speak with a Technical Support Specialist, call, or email, - * German: +49 89 4366 5522, Monday-Friday, 9:00-17:00 CET, - http://ask-de.adaptec.com/. - * French: +49 89 4366 5533, Monday-Friday, 9:00-17:00 CET, - http://ask-fr.adaptec.com/. - * English: +49 89 4366 5544, Monday-Friday, 9:00-17:00 GMT, - http://ask.adaptec.com/. - - You can order Adaptec cables online at - http://www.adaptec.com/buy-cables/. + - Visit our Web site at http://www.adaptec-europe.com. + - English and French: To speak with a Technical Support + Specialist, call one of the following numbers: + - English: +32-2-352-3470 + - French: +32-2-352-3460 + Hours: Monday-Thursday, 10:00 to 12:30, 13:30 to 17:30 CET + Friday, 10:00 to 12:30, 13:30 to 16:30 CET + - German: To speak with a Technical Support Specialist, + call +49-89-456-40660 + Hours: Monday-Thursday, 09:30 to 12:30, 13:30 to 16:30 CET + Friday, 09:30 to 12:30, 13:30 to 15:00 CET + - To order Adaptec products, including accessories and cables: + - UK: +0800-96-65-26 or fax +0800-731-02-95 + - Other European countries: +32-11-300-379 + + Australia and New Zealand + - Visit our Web site at http://www.adaptec.com.au. + - To speak with a Technical Support Specialist, call + +612-9416-0698 + Hours: Monday-Friday, 10:00 A.M. to 4:30 P.M., EAT + (Not open on holidays) Japan - - Visit our web site at http://www.adaptec.co.jp/. - To speak with a Technical Support Specialist, call - +81 3 5308 6120, Monday-Friday, 9:00 a.m. to 12:00 p.m., - 1:00 p.m. to 6:00 p.m. + +81-3-5308-6120 + Hours: Monday-Friday, 9:00 a.m. to 12:00 p.m., 1:00 p.m. to + 6:00 p.m. TSC + + Hong Kong and China + - To speak with a Technical Support Specialist, call + +852-2869-7200 + Hours: Monday-Friday, 10:00 to 17:00. + - Fax Technical Support at +852-2869-7100. + + Singapore + - To speak with a Technical Support Specialist, call + +65-245-7470 + Hours: Monday-Friday, 10:00 to 17:00. + - Fax Technical Support at +852-2869-7100 ------------------------------------------------------------------- /* diff --git a/trunk/Documentation/sound/alsa/ALSA-Configuration.txt b/trunk/Documentation/sound/alsa/ALSA-Configuration.txt index 36b511c7cade..d2578013e829 100644 --- a/trunk/Documentation/sound/alsa/ALSA-Configuration.txt +++ b/trunk/Documentation/sound/alsa/ALSA-Configuration.txt @@ -837,10 +837,8 @@ Prior to version 0.9.0rc4 options had a 'snd_' prefix. This was removed. Module for AC'97 motherboards from Intel and compatibles. * Intel i810/810E, i815, i820, i830, i84x, MX440 - ICH5, ICH6, ICH7, ESB2 * SiS 7012 (SiS 735) - * NVidia NForce, NForce2, NForce3, MCP04, CK804 - CK8, CK8S, MCP501 + * NVidia NForce, NForce2 * AMD AMD768, AMD8111 * ALi m5455 @@ -870,12 +868,6 @@ Prior to version 0.9.0rc4 options had a 'snd_' prefix. This was removed. -------------------- Module for Intel ICH (i8x0) chipset MC97 modems. - * Intel i810/810E, i815, i820, i830, i84x, MX440 - ICH5, ICH6, ICH7 - * SiS 7013 (SiS 735) - * NVidia NForce, NForce2, NForce2s, NForce3 - * AMD AMD8111 - * ALi m5455 ac97_clock - AC'97 codec clock base (0 = auto-detect) diff --git a/trunk/Documentation/sound/alsa/DocBook/writing-an-alsa-driver.tmpl b/trunk/Documentation/sound/alsa/DocBook/writing-an-alsa-driver.tmpl index 4251085d38d3..e651ed8d1e6f 100644 --- a/trunk/Documentation/sound/alsa/DocBook/writing-an-alsa-driver.tmpl +++ b/trunk/Documentation/sound/alsa/DocBook/writing-an-alsa-driver.tmpl @@ -5206,14 +5206,14 @@ struct _snd_pcm_runtime { You need to pass the snd_dma_pci_data(pci), where pci is the struct pci_dev pointer of the chip as well. - The struct snd_sg_buf instance is created as + The snd_sg_buf_t instance is created as substream->dma_private. You can cast the pointer like: dma_private; + struct snd_sg_buf *sgbuf = (struct snd_sg_buf_t*)substream->dma_private; ]]> diff --git a/trunk/Documentation/spi/butterfly b/trunk/Documentation/spi/butterfly index 9927af7a629c..a2e8c8d90e35 100644 --- a/trunk/Documentation/spi/butterfly +++ b/trunk/Documentation/spi/butterfly @@ -12,20 +12,13 @@ You can make this adapter from an old printer cable and solder things directly to the Butterfly. Or (if you have the parts and skills) you can come up with something fancier, providing ciruit protection to the Butterfly and the printer port, or with a better power supply than two -signal pins from the printer port. Or for that matter, you can use -similar cables to talk to many AVR boards, even a breadboard. - -This is more powerful than "ISP programming" cables since it lets kernel -SPI protocol drivers interact with the AVR, and could even let the AVR -issue interrupts to them. Later, your protocol driver should work -easily with a "real SPI controller", instead of this bitbanger. +signal pins from the printer port. The first cable connections will hook Linux up to one SPI bus, with the AVR and a DataFlash chip; and to the AVR reset line. This is all you need to reflash the firmware, and the pins are the standard Atmel "ISP" -connector pins (used also on non-Butterfly AVR boards). On the parport -side this is like "sp12" programming cables. +connector pins (used also on non-Butterfly AVR boards). Signal Butterfly Parport (DB-25) ------ --------- --------------- @@ -47,14 +40,10 @@ by clearing PORTB.[0-3]); (b) configure the mtd_dataflash driver; and SELECT = J400.PB0/nSS = pin 17/C3,nSELECT GND = J400.GND = pin 24/GND -Or you could flash firmware making the AVR into an SPI slave (keeping the -DataFlash in reset) and tweak the spi_butterfly driver to make it bind to -the driver for your custom SPI-based protocol. - -The "USI" controller, using J405, can also be used for a second SPI bus. -That would let you talk to the AVR using custom SPI-with-USI firmware, -while letting either Linux or the AVR use the DataFlash. There are plenty -of spare parport pins to wire this one up, such as: +The "USI" controller, using J405, can be used for a second SPI bus. That +would let you talk to the AVR over SPI, running firmware that makes it act +as an SPI slave, while letting either Linux or the AVR use the DataFlash. +There are plenty of spare parport pins to wire this one up, such as: Signal Butterfly Parport (DB-25) ------ --------- --------------- diff --git a/trunk/Documentation/sysctl/vm.txt b/trunk/Documentation/sysctl/vm.txt index a46c10fcddfc..6910c0136f8d 100644 --- a/trunk/Documentation/sysctl/vm.txt +++ b/trunk/Documentation/sysctl/vm.txt @@ -27,8 +27,6 @@ Currently, these files are in /proc/sys/vm: - laptop_mode - block_dump - drop-caches -- zone_reclaim_mode -- zone_reclaim_interval ============================================================== @@ -122,59 +120,3 @@ set to pcp->high/4. The upper limit of batch is (PAGE_SHIFT * 8) The initial value is zero. Kernel does not use this value at boot time to set the high water marks for each per cpu page list. - -=============================================================== - -zone_reclaim_mode: - -Zone_reclaim_mode allows to set more or less agressive approaches to -reclaim memory when a zone runs out of memory. If it is set to zero then no -zone reclaim occurs. Allocations will be satisfied from other zones / nodes -in the system. - -This is value ORed together of - -1 = Zone reclaim on -2 = Zone reclaim writes dirty pages out -4 = Zone reclaim swaps pages -8 = Also do a global slab reclaim pass - -zone_reclaim_mode is set during bootup to 1 if it is determined that pages -from remote zones will cause a measurable performance reduction. The -page allocator will then reclaim easily reusable pages (those page -cache pages that are currently not used) before allocating off node pages. - -It may be beneficial to switch off zone reclaim if the system is -used for a file server and all of memory should be used for caching files -from disk. In that case the caching effect is more important than -data locality. - -Allowing zone reclaim to write out pages stops processes that are -writing large amounts of data from dirtying pages on other nodes. Zone -reclaim will write out dirty pages if a zone fills up and so effectively -throttle the process. This may decrease the performance of a single process -since it cannot use all of system memory to buffer the outgoing writes -anymore but it preserve the memory on other nodes so that the performance -of other processes running on other nodes will not be affected. - -Allowing regular swap effectively restricts allocations to the local -node unless explicitly overridden by memory policies or cpuset -configurations. - -It may be advisable to allow slab reclaim if the system makes heavy -use of files and builds up large slab caches. However, the slab -shrink operation is global, may take a long time and free slabs -in all nodes of the system. - -================================================================ - -zone_reclaim_interval: - -The time allowed for off node allocations after zone reclaim -has failed to reclaim enough pages to allow a local allocation. - -Time is set in seconds and set by default to 30 seconds. - -Reduce the interval if undesired off node allocations occur. However, too -frequent scans will have a negative impact onoff node allocation performance. - diff --git a/trunk/Documentation/unshare.txt b/trunk/Documentation/unshare.txt deleted file mode 100644 index 90a5e9e5bef1..000000000000 --- a/trunk/Documentation/unshare.txt +++ /dev/null @@ -1,295 +0,0 @@ - -unshare system call: --------------------- -This document describes the new system call, unshare. The document -provides an overview of the feature, why it is needed, how it can -be used, its interface specification, design, implementation and -how it can be tested. - -Change Log: ------------ -version 0.1 Initial document, Janak Desai (janak@us.ibm.com), Jan 11, 2006 - -Contents: ---------- - 1) Overview - 2) Benefits - 3) Cost - 4) Requirements - 5) Functional Specification - 6) High Level Design - 7) Low Level Design - 8) Test Specification - 9) Future Work - -1) Overview ------------ -Most legacy operating system kernels support an abstraction of threads -as multiple execution contexts within a process. These kernels provide -special resources and mechanisms to maintain these "threads". The Linux -kernel, in a clever and simple manner, does not make distinction -between processes and "threads". The kernel allows processes to share -resources and thus they can achieve legacy "threads" behavior without -requiring additional data structures and mechanisms in the kernel. The -power of implementing threads in this manner comes not only from -its simplicity but also from allowing application programmers to work -outside the confinement of all-or-nothing shared resources of legacy -threads. On Linux, at the time of thread creation using the clone system -call, applications can selectively choose which resources to share -between threads. - -unshare system call adds a primitive to the Linux thread model that -allows threads to selectively 'unshare' any resources that were being -shared at the time of their creation. unshare was conceptualized by -Al Viro in the August of 2000, on the Linux-Kernel mailing list, as part -of the discussion on POSIX threads on Linux. unshare augments the -usefulness of Linux threads for applications that would like to control -shared resources without creating a new process. unshare is a natural -addition to the set of available primitives on Linux that implement -the concept of process/thread as a virtual machine. - -2) Benefits ------------ -unshare would be useful to large application frameworks such as PAM -where creating a new process to control sharing/unsharing of process -resources is not possible. Since namespaces are shared by default -when creating a new process using fork or clone, unshare can benefit -even non-threaded applications if they have a need to disassociate -from default shared namespace. The following lists two use-cases -where unshare can be used. - -2.1 Per-security context namespaces ------------------------------------ -unshare can be used to implement polyinstantiated directories using -the kernel's per-process namespace mechanism. Polyinstantiated directories, -such as per-user and/or per-security context instance of /tmp, /var/tmp or -per-security context instance of a user's home directory, isolate user -processes when working with these directories. Using unshare, a PAM -module can easily setup a private namespace for a user at login. -Polyinstantiated directories are required for Common Criteria certification -with Labeled System Protection Profile, however, with the availability -of shared-tree feature in the Linux kernel, even regular Linux systems -can benefit from setting up private namespaces at login and -polyinstantiating /tmp, /var/tmp and other directories deemed -appropriate by system administrators. - -2.2 unsharing of virtual memory and/or open files -------------------------------------------------- -Consider a client/server application where the server is processing -client requests by creating processes that share resources such as -virtual memory and open files. Without unshare, the server has to -decide what needs to be shared at the time of creating the process -which services the request. unshare allows the server an ability to -disassociate parts of the context during the servicing of the -request. For large and complex middleware application frameworks, this -ability to unshare after the process was created can be very -useful. - -3) Cost -------- -In order to not duplicate code and to handle the fact that unshare -works on an active task (as opposed to clone/fork working on a newly -allocated inactive task) unshare had to make minor reorganizational -changes to copy_* functions utilized by clone/fork system call. -There is a cost associated with altering existing, well tested and -stable code to implement a new feature that may not get exercised -extensively in the beginning. However, with proper design and code -review of the changes and creation of an unshare test for the LTP -the benefits of this new feature can exceed its cost. - -4) Requirements ---------------- -unshare reverses sharing that was done using clone(2) system call, -so unshare should have a similar interface as clone(2). That is, -since flags in clone(int flags, void *stack) specifies what should -be shared, similar flags in unshare(int flags) should specify -what should be unshared. Unfortunately, this may appear to invert -the meaning of the flags from the way they are used in clone(2). -However, there was no easy solution that was less confusing and that -allowed incremental context unsharing in future without an ABI change. - -unshare interface should accommodate possible future addition of -new context flags without requiring a rebuild of old applications. -If and when new context flags are added, unshare design should allow -incremental unsharing of those resources on an as needed basis. - -5) Functional Specification ---------------------------- -NAME - unshare - disassociate parts of the process execution context - -SYNOPSIS - #include - - int unshare(int flags); - -DESCRIPTION - unshare allows a process to disassociate parts of its execution - context that are currently being shared with other processes. Part - of execution context, such as the namespace, is shared by default - when a new process is created using fork(2), while other parts, - such as the virtual memory, open file descriptors, etc, may be - shared by explicit request to share them when creating a process - using clone(2). - - The main use of unshare is to allow a process to control its - shared execution context without creating a new process. - - The flags argument specifies one or bitwise-or'ed of several of - the following constants. - - CLONE_FS - If CLONE_FS is set, file system information of the caller - is disassociated from the shared file system information. - - CLONE_FILES - If CLONE_FILES is set, the file descriptor table of the - caller is disassociated from the shared file descriptor - table. - - CLONE_NEWNS - If CLONE_NEWNS is set, the namespace of the caller is - disassociated from the shared namespace. - - CLONE_VM - If CLONE_VM is set, the virtual memory of the caller is - disassociated from the shared virtual memory. - -RETURN VALUE - On success, zero returned. On failure, -1 is returned and errno is - -ERRORS - EPERM CLONE_NEWNS was specified by a non-root process (process - without CAP_SYS_ADMIN). - - ENOMEM Cannot allocate sufficient memory to copy parts of caller's - context that need to be unshared. - - EINVAL Invalid flag was specified as an argument. - -CONFORMING TO - The unshare() call is Linux-specific and should not be used - in programs intended to be portable. - -SEE ALSO - clone(2), fork(2) - -6) High Level Design --------------------- -Depending on the flags argument, the unshare system call allocates -appropriate process context structures, populates it with values from -the current shared version, associates newly duplicated structures -with the current task structure and releases corresponding shared -versions. Helper functions of clone (copy_*) could not be used -directly by unshare because of the following two reasons. - 1) clone operates on a newly allocated not-yet-active task - structure, where as unshare operates on the current active - task. Therefore unshare has to take appropriate task_lock() - before associating newly duplicated context structures - 2) unshare has to allocate and duplicate all context structures - that are being unshared, before associating them with the - current task and releasing older shared structures. Failure - do so will create race conditions and/or oops when trying - to backout due to an error. Consider the case of unsharing - both virtual memory and namespace. After successfully unsharing - vm, if the system call encounters an error while allocating - new namespace structure, the error return code will have to - reverse the unsharing of vm. As part of the reversal the - system call will have to go back to older, shared, vm - structure, which may not exist anymore. - -Therefore code from copy_* functions that allocated and duplicated -current context structure was moved into new dup_* functions. Now, -copy_* functions call dup_* functions to allocate and duplicate -appropriate context structures and then associate them with the -task structure that is being constructed. unshare system call on -the other hand performs the following: - 1) Check flags to force missing, but implied, flags - 2) For each context structure, call the corresponding unshare - helper function to allocate and duplicate a new context - structure, if the appropriate bit is set in the flags argument. - 3) If there is no error in allocation and duplication and there - are new context structures then lock the current task structure, - associate new context structures with the current task structure, - and release the lock on the current task structure. - 4) Appropriately release older, shared, context structures. - -7) Low Level Design -------------------- -Implementation of unshare can be grouped in the following 4 different -items: - a) Reorganization of existing copy_* functions - b) unshare system call service function - c) unshare helper functions for each different process context - d) Registration of system call number for different architectures - - 7.1) Reorganization of copy_* functions - Each copy function such as copy_mm, copy_namespace, copy_files, - etc, had roughly two components. The first component allocated - and duplicated the appropriate structure and the second component - linked it to the task structure passed in as an argument to the copy - function. The first component was split into its own function. - These dup_* functions allocated and duplicated the appropriate - context structure. The reorganized copy_* functions invoked - their corresponding dup_* functions and then linked the newly - duplicated structures to the task structure with which the - copy function was called. - - 7.2) unshare system call service function - * Check flags - Force implied flags. If CLONE_THREAD is set force CLONE_VM. - If CLONE_VM is set, force CLONE_SIGHAND. If CLONE_SIGHAND is - set and signals are also being shared, force CLONE_THREAD. If - CLONE_NEWNS is set, force CLONE_FS. - * For each context flag, invoke the corresponding unshare_* - helper routine with flags passed into the system call and a - reference to pointer pointing the new unshared structure - * If any new structures are created by unshare_* helper - functions, take the task_lock() on the current task, - modify appropriate context pointers, and release the - task lock. - * For all newly unshared structures, release the corresponding - older, shared, structures. - - 7.3) unshare_* helper functions - For unshare_* helpers corresponding to CLONE_SYSVSEM, CLONE_SIGHAND, - and CLONE_THREAD, return -EINVAL since they are not implemented yet. - For others, check the flag value to see if the unsharing is - required for that structure. If it is, invoke the corresponding - dup_* function to allocate and duplicate the structure and return - a pointer to it. - - 7.4) Appropriately modify architecture specific code to register the - the new system call. - -8) Test Specification ---------------------- -The test for unshare should test the following: - 1) Valid flags: Test to check that clone flags for signal and - signal handlers, for which unsharing is not implemented - yet, return -EINVAL. - 2) Missing/implied flags: Test to make sure that if unsharing - namespace without specifying unsharing of filesystem, correctly - unshares both namespace and filesystem information. - 3) For each of the four (namespace, filesystem, files and vm) - supported unsharing, verify that the system call correctly - unshares the appropriate structure. Verify that unsharing - them individually as well as in combination with each - other works as expected. - 4) Concurrent execution: Use shared memory segments and futex on - an address in the shm segment to synchronize execution of - about 10 threads. Have a couple of threads execute execve, - a couple _exit and the rest unshare with different combination - of flags. Verify that unsharing is performed as expected and - that there are no oops or hangs. - -9) Future Work --------------- -The current implementation of unshare does not allow unsharing of -signals and signal handlers. Signals are complex to begin with and -to unshare signals and/or signal handlers of a currently running -process is even more complex. If in the future there is a specific -need to allow unsharing of signals and/or signal handlers, it can -be incrementally added to unshare without affecting legacy -applications using unshare. - diff --git a/trunk/Documentation/usb/et61x251.txt b/trunk/Documentation/usb/et61x251.txt deleted file mode 100644 index b44dda407ce2..000000000000 --- a/trunk/Documentation/usb/et61x251.txt +++ /dev/null @@ -1,306 +0,0 @@ - - ET61X[12]51 PC Camera Controllers - Driver for Linux - ================================= - - - Documentation - - - -Index -===== -1. Copyright -2. Disclaimer -3. License -4. Overview and features -5. Module dependencies -6. Module loading -7. Module parameters -8. Optional device control through "sysfs" -9. Supported devices -10. Notes for V4L2 application developers -11. Contact information - - -1. Copyright -============ -Copyright (C) 2006 by Luca Risolia - - -2. Disclaimer -============= -Etoms is a trademark of Etoms Electronics Corp. -This software is not developed or sponsored by Etoms Electronics. - - -3. License -========== -This program is free software; you can redistribute it and/or modify -it under the terms of the GNU General Public License as published by -the Free Software Foundation; either version 2 of the License, or -(at your option) any later version. - -This program is distributed in the hope that it will be useful, -but WITHOUT ANY WARRANTY; without even the implied warranty of -MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the -GNU General Public License for more details. - -You should have received a copy of the GNU General Public License -along with this program; if not, write to the Free Software -Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. - - -4. Overview and features -======================== -This driver supports the video interface of the devices mounting the ET61X151 -or ET61X251 PC Camera Controllers. - -It's worth to note that Etoms Electronics has never collaborated with the -author during the development of this project; despite several requests, -Etoms Electronics also refused to release enough detailed specifications of -the video compression engine. - -The driver relies on the Video4Linux2 and USB core modules. It has been -designed to run properly on SMP systems as well. - -The latest version of the ET61X[12]51 driver can be found at the following URL: -http://www.linux-projects.org/ - -Some of the features of the driver are: - -- full compliance with the Video4Linux2 API (see also "Notes for V4L2 - application developers" paragraph); -- available mmap or read/poll methods for video streaming through isochronous - data transfers; -- automatic detection of image sensor; -- support for any window resolutions and optional panning within the maximum - pixel area of image sensor; -- image downscaling with arbitrary scaling factors from 1 and 2 in both - directions (see "Notes for V4L2 application developers" paragraph); -- two different video formats for uncompressed or compressed data in low or - high compression quality (see also "Notes for V4L2 application developers" - paragraph); -- full support for the capabilities of every possible image sensors that can - be connected to the ET61X[12]51 bridges, including, for istance, red, green, - blue and global gain adjustments and exposure control (see "Supported - devices" paragraph for details); -- use of default color settings for sunlight conditions; -- dynamic I/O interface for both ET61X[12]51 and image sensor control (see - "Optional device control through 'sysfs'" paragraph); -- dynamic driver control thanks to various module parameters (see "Module - parameters" paragraph); -- up to 64 cameras can be handled at the same time; they can be connected and - disconnected from the host many times without turning off the computer, if - the system supports hotplugging; -- no known bugs. - - -5. Module dependencies -====================== -For it to work properly, the driver needs kernel support for Video4Linux and -USB. - -The following options of the kernel configuration file must be enabled and -corresponding modules must be compiled: - - # Multimedia devices - # - CONFIG_VIDEO_DEV=m - -To enable advanced debugging functionality on the device through /sysfs: - - # Multimedia devices - # - CONFIG_VIDEO_ADV_DEBUG=y - - # USB support - # - CONFIG_USB=m - -In addition, depending on the hardware being used, the modules below are -necessary: - - # USB Host Controller Drivers - # - CONFIG_USB_EHCI_HCD=m - CONFIG_USB_UHCI_HCD=m - CONFIG_USB_OHCI_HCD=m - -And finally: - - # USB Multimedia devices - # - CONFIG_USB_ET61X251=m - - -6. Module loading -================= -To use the driver, it is necessary to load the "et61x251" module into memory -after every other module required: "videodev", "usbcore" and, depending on -the USB host controller you have, "ehci-hcd", "uhci-hcd" or "ohci-hcd". - -Loading can be done as shown below: - - [root@localhost home]# modprobe et61x251 - -At this point the devices should be recognized. You can invoke "dmesg" to -analyze kernel messages and verify that the loading process has gone well: - - [user@localhost home]$ dmesg - - -7. Module parameters -==================== -Module parameters are listed below: -------------------------------------------------------------------------------- -Name: video_nr -Type: short array (min = 0, max = 64) -Syntax: <-1|n[,...]> -Description: Specify V4L2 minor mode number: - -1 = use next available - n = use minor number n - You can specify up to 64 cameras this way. - For example: - video_nr=-1,2,-1 would assign minor number 2 to the second - registered camera and use auto for the first one and for every - other camera. -Default: -1 -------------------------------------------------------------------------------- -Name: force_munmap -Type: bool array (min = 0, max = 64) -Syntax: <0|1[,...]> -Description: Force the application to unmap previously mapped buffer memory - before calling any VIDIOC_S_CROP or VIDIOC_S_FMT ioctl's. Not - all the applications support this feature. This parameter is - specific for each detected camera. - 0 = do not force memory unmapping - 1 = force memory unmapping (save memory) -Default: 0 -------------------------------------------------------------------------------- -Name: debug -Type: ushort -Syntax: -Description: Debugging information level, from 0 to 3: - 0 = none (use carefully) - 1 = critical errors - 2 = significant informations - 3 = more verbose messages - Level 3 is useful for testing only, when only one device - is used at the same time. It also shows some more informations - about the hardware being detected. This module parameter can be - changed at runtime thanks to the /sys filesystem interface. -Default: 2 -------------------------------------------------------------------------------- - - -8. Optional device control through "sysfs" -========================================== -If the kernel has been compiled with the CONFIG_VIDEO_ADV_DEBUG option enabled, -it is possible to read and write both the ET61X[12]51 and the image sensor -registers by using the "sysfs" filesystem interface. - -There are four files in the /sys/class/video4linux/videoX directory for each -registered camera: "reg", "val", "i2c_reg" and "i2c_val". The first two files -control the ET61X[12]51 bridge, while the other two control the sensor chip. -"reg" and "i2c_reg" hold the values of the current register index where the -following reading/writing operations are addressed at through "val" and -"i2c_val". Their use is not intended for end-users, unless you know what you -are doing. Remember that you must be logged in as root before writing to them. - -As an example, suppose we were to want to read the value contained in the -register number 1 of the sensor register table - which is usually the product -identifier - of the camera registered as "/dev/video0": - - [root@localhost #] cd /sys/class/video4linux/video0 - [root@localhost #] echo 1 > i2c_reg - [root@localhost #] cat i2c_val - -Note that if the sensor registers can not be read, "cat" will fail. -To avoid race conditions, all the I/O accesses to the files are serialized. - - -9. Supported devices -==================== -None of the names of the companies as well as their products will be mentioned -here. They have never collaborated with the author, so no advertising. - -From the point of view of a driver, what unambiguously identify a device are -its vendor and product USB identifiers. Below is a list of known identifiers of -devices mounting the ET61X[12]51 PC camera controllers: - -Vendor ID Product ID ---------- ---------- -0x102c 0x6151 -0x102c 0x6251 -0x102c 0x6253 -0x102c 0x6254 -0x102c 0x6255 -0x102c 0x6256 -0x102c 0x6257 -0x102c 0x6258 -0x102c 0x6259 -0x102c 0x625a -0x102c 0x625b -0x102c 0x625c -0x102c 0x625d -0x102c 0x625e -0x102c 0x625f -0x102c 0x6260 -0x102c 0x6261 -0x102c 0x6262 -0x102c 0x6263 -0x102c 0x6264 -0x102c 0x6265 -0x102c 0x6266 -0x102c 0x6267 -0x102c 0x6268 -0x102c 0x6269 - -The following image sensors are supported: - -Model Manufacturer ------ ------------ -TAS5130D1B Taiwan Advanced Sensor Corporation - -All the available control settings of each image sensor are supported through -the V4L2 interface. - - -10. Notes for V4L2 application developers -======================================== -This driver follows the V4L2 API specifications. In particular, it enforces two -rules: - -- exactly one I/O method, either "mmap" or "read", is associated with each -file descriptor. Once it is selected, the application must close and reopen the -device to switch to the other I/O method; - -- although it is not mandatory, previously mapped buffer memory should always -be unmapped before calling any "VIDIOC_S_CROP" or "VIDIOC_S_FMT" ioctl's. -The same number of buffers as before will be allocated again to match the size -of the new video frames, so you have to map the buffers again before any I/O -attempts on them. - -Consistently with the hardware limits, this driver also supports image -downscaling with arbitrary scaling factors from 1 and 2 in both directions. -However, the V4L2 API specifications don't correctly define how the scaling -factor can be chosen arbitrarily by the "negotiation" of the "source" and -"target" rectangles. To work around this flaw, we have added the convention -that, during the negotiation, whenever the "VIDIOC_S_CROP" ioctl is issued, the -scaling factor is restored to 1. - -This driver supports two different video formats: the first one is the "8-bit -Sequential Bayer" format and can be used to obtain uncompressed video data -from the device through the current I/O method, while the second one provides -"raw" compressed video data (without frame headers not related to the -compressed data). The current compression quality may vary from 0 to 1 and can -be selected or queried thanks to the VIDIOC_S_JPEGCOMP and VIDIOC_G_JPEGCOMP -V4L2 ioctl's. - - -11. Contact information -======================= -The author may be contacted by e-mail at . - -GPG/PGP encrypted e-mail's are accepted. The GPG key ID of the author is -'FCE635A4'; the public 1024-bit key should be available at any keyserver; -the fingerprint is: '88E8 F32F 7244 68BA 3958 5D40 99DA 5D2A FCE6 35A4'. diff --git a/trunk/Documentation/usb/sn9c102.txt b/trunk/Documentation/usb/sn9c102.txt index c6b76414172c..3f8a119db31b 100644 --- a/trunk/Documentation/usb/sn9c102.txt +++ b/trunk/Documentation/usb/sn9c102.txt @@ -17,15 +17,16 @@ Index 7. Module parameters 8. Optional device control through "sysfs" 9. Supported devices -10. Notes for V4L2 application developers -11. Video frame formats -12. Contact information -13. Credits +10. How to add plug-in's for new image sensors +11. Notes for V4L2 application developers +12. Video frame formats +13. Contact information +14. Credits 1. Copyright ============ -Copyright (C) 2004-2006 by Luca Risolia +Copyright (C) 2004-2005 by Luca Risolia 2. Disclaimer @@ -53,8 +54,9 @@ Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 4. Overview and features ======================== -This driver attempts to support the video interface of the devices mounting the -SONiX SN9C101, SN9C102 and SN9C103 PC Camera Controllers. +This driver attempts to support the video and audio streaming capabilities of +the devices mounting the SONiX SN9C101, SN9C102 and SN9C103 PC Camera +Controllers. It's worth to note that SONiX has never collaborated with the author during the development of this project, despite several requests for enough detailed @@ -76,7 +78,6 @@ Some of the features of the driver are: - available mmap or read/poll methods for video streaming through isochronous data transfers; - automatic detection of image sensor; -- support for built-in microphone interface; - support for any window resolutions and optional panning within the maximum pixel area of image sensor; - image downscaling with arbitrary scaling factors from 1, 2 and 4 in both @@ -95,7 +96,7 @@ Some of the features of the driver are: parameters" paragraph); - up to 64 cameras can be handled at the same time; they can be connected and disconnected from the host many times without turning off the computer, if - the system supports hotplugging; + your system supports hotplugging; - no known bugs. @@ -111,12 +112,6 @@ corresponding modules must be compiled: # CONFIG_VIDEO_DEV=m -To enable advanced debugging functionality on the device through /sysfs: - - # Multimedia devices - # - CONFIG_VIDEO_ADV_DEBUG=y - # USB support # CONFIG_USB=m @@ -130,21 +125,6 @@ necessary: CONFIG_USB_UHCI_HCD=m CONFIG_USB_OHCI_HCD=m -The SN9C103 controller also provides a built-in microphone interface. It is -supported by the USB Audio driver thanks to the ALSA API: - - # Sound - # - CONFIG_SOUND=y - - # Advanced Linux Sound Architecture - # - CONFIG_SND=m - - # USB devices - # - CONFIG_SND_USB_AUDIO=m - And finally: # USB Multimedia devices @@ -173,7 +153,7 @@ analyze kernel messages and verify that the loading process has gone well: Module parameters are listed below: ------------------------------------------------------------------------------- Name: video_nr -Type: short array (min = 0, max = 64) +Type: int array (min = 0, max = 64) Syntax: <-1|n[,...]> Description: Specify V4L2 minor mode number: -1 = use next available @@ -185,19 +165,19 @@ Description: Specify V4L2 minor mode number: other camera. Default: -1 ------------------------------------------------------------------------------- -Name: force_munmap +Name: force_munmap; Type: bool array (min = 0, max = 64) Syntax: <0|1[,...]> Description: Force the application to unmap previously mapped buffer memory before calling any VIDIOC_S_CROP or VIDIOC_S_FMT ioctl's. Not all the applications support this feature. This parameter is specific for each detected camera. - 0 = do not force memory unmapping - 1 = force memory unmapping (save memory) + 0 = do not force memory unmapping" + 1 = force memory unmapping (save memory)" Default: 0 ------------------------------------------------------------------------------- Name: debug -Type: ushort +Type: int Syntax: Description: Debugging information level, from 0 to 3: 0 = none (use carefully) @@ -207,15 +187,14 @@ Description: Debugging information level, from 0 to 3: Level 3 is useful for testing only, when only one device is used. It also shows some more informations about the hardware being detected. This parameter can be changed at - runtime thanks to the /sys filesystem interface. + runtime thanks to the /sys filesystem. Default: 2 ------------------------------------------------------------------------------- 8. Optional device control through "sysfs" [1] ========================================== -If the kernel has been compiled with the CONFIG_VIDEO_ADV_DEBUG option enabled, -it is possible to read and write both the SN9C10x and the image sensor +It is possible to read and write both the SN9C10x and the image sensor registers by using the "sysfs" filesystem interface. Every time a supported device is recognized, a write-only file named "green" is @@ -257,7 +236,7 @@ serialized. The sysfs interface also provides the "frame_header" entry, which exports the frame header of the most recent requested and captured video frame. The header -is always 18-bytes long and is appended to every video frame by the SN9C10x +is 12-bytes long and is appended to every video frame by the SN9C10x controllers. As an example, this additional information can be used by the user application for implementing auto-exposure features via software. @@ -271,8 +250,7 @@ Byte # Value Description 0x03 0xC4 Frame synchronisation pattern. 0x04 0xC4 Frame synchronisation pattern. 0x05 0x96 Frame synchronisation pattern. -0x06 0xXX Unknown meaning. The exact value depends on the chip; - possible values are 0x00, 0x01 and 0x20. +0x06 0x00 or 0x01 Unknown meaning. The exact value depends on the chip. 0x07 0xXX Variable value, whose bits are ff00uzzc, where ff is a frame counter, u is unknown, zz is a size indicator (00 = VGA, 01 = SIF, 10 = QSIF) and c stands for @@ -289,23 +267,12 @@ Byte # Value Description times the area outside of the specified AE area. For images that are not pure white, the value scales down according to relative whiteness. - according to relative whiteness. - -The following bytes are used by the SN9C103 bridge only: - -0x0C 0xXX Unknown meaning -0x0D 0xXX Unknown meaning -0x0E 0xXX Unknown meaning -0x0F 0xXX Unknown meaning -0x10 0xXX Unknown meaning -0x11 0xXX Unknown meaning The AE area (sx, sy, ex, ey) in the active window can be set by programming the registers 0x1c, 0x1d, 0x1e and 0x1f of the SN9C10x controllers, where one unit corresponds to 32 pixels. -[1] Part of the meaning of the frame header has been documented by Bertrik - Sikken. +[1] The frame header has been documented by Bertrik Sikken. 9. Supported devices @@ -331,7 +298,6 @@ Vendor ID Product ID 0x0c45 0x602b 0x0c45 0x602c 0x0c45 0x602d -0x0c45 0x602e 0x0c45 0x6030 0x0c45 0x6080 0x0c45 0x6082 @@ -382,7 +348,18 @@ appreciated. Non-available hardware will not be supported by the author of this driver. -10. Notes for V4L2 application developers +10. How to add plug-in's for new image sensors +============================================== +It should be easy to write plug-in's for new sensors by using the small API +that has been created for this purpose, which is present in "sn9c102_sensor.h" +(documentation is included there). As an example, have a look at the code in +"sn9c102_pas106b.c", which uses the mentioned interface. + +At the moment, possible unsupported image sensors are: CIS-VF10 (VGA), +OV7620 (VGA), OV7630 (VGA). + + +11. Notes for V4L2 application developers ========================================= This driver follows the V4L2 API specifications. In particular, it enforces two rules: @@ -417,7 +394,7 @@ initialized (as described in the documentation of the API for the image sensors supplied by this driver). -11. Video frame formats [1] +12. Video frame formats [1] ======================= The SN9C10x PC Camera Controllers can send images in two possible video formats over the USB: either native "Sequential RGB Bayer" or Huffman @@ -478,7 +455,7 @@ The following Huffman codes have been found: documented by Bertrik Sikken. -12. Contact information +13. Contact information ======================= The author may be contacted by e-mail at . @@ -487,7 +464,7 @@ GPG/PGP encrypted e-mail's are accepted. The GPG key ID of the author is the fingerprint is: '88E8 F32F 7244 68BA 3958 5D40 99DA 5D2A FCE6 35A4'. -13. Credits +14. Credits =========== Many thanks to following persons for their contribute (listed in alphabetical order): @@ -503,5 +480,5 @@ order): - Bertrik Sikken, who reverse-engineered and documented the Huffman compression algorithm used in the SN9C10x controllers and implemented the first decoder; - Mizuno Takafumi for the donation of a webcam; -- an "anonymous" donator (who didn't want his name to be revealed) for the +- An "anonymous" donator (who didn't want his name to be revealed) for the donation of a webcam. diff --git a/trunk/Documentation/usb/w9968cf.txt b/trunk/Documentation/usb/w9968cf.txt index 9d46cd0b19e3..18a47738d56c 100644 --- a/trunk/Documentation/usb/w9968cf.txt +++ b/trunk/Documentation/usb/w9968cf.txt @@ -57,12 +57,16 @@ based cameras should be supported as well. The driver is divided into two modules: the basic one, "w9968cf", is needed for the supported devices to work; the second one, "w9968cf-vpp", is an optional module, which provides some useful video post-processing functions like video -decoding, up-scaling and colour conversions. +decoding, up-scaling and colour conversions. Once the driver is installed, +every time an application tries to open a recognized device, "w9968cf" checks +the presence of the "w9968cf-vpp" module and loads it automatically by default. -Note that the official kernels do neither include nor support the second -module for performance purposes. Therefore, it is always recommended to -download and install the latest and complete release of the driver, -replacing the existing one, if present. +Please keep in mind that official kernels do not include the second module for +performance purposes. However it is always recommended to download and install +the latest and complete release of the driver, replacing the existing one, if +present: it will be still even possible not to load the "w9968cf-vpp" module at +all, if you ever want to. Another important missing feature of the version in +the official Linux 2.4 kernels is the writeable /proc filesystem interface. The latest and full-featured version of the W996[87]CF driver can be found at: http://www.linux-projects.org. Please refer to the documentation included in @@ -197,6 +201,22 @@ Note: The kernel must be compiled with the CONFIG_KMOD option enabled for the 'ovcamchip' module to be loaded and for this parameter to be present. ------------------------------------------------------------------------------- +Name: vppmod_load +Type: bool +Syntax: <0|1> +Description: Automatic 'w9968cf-vpp' module loading: 0 disabled, 1 enabled. + If enabled, every time an application attempts to open a + camera, 'insmod' searches for the video post-processing module + in the system and loads it automatically (if present). + The optional 'w9968cf-vpp' module adds extra image manipulation + capabilities to the 'w9968cf' module,like software up-scaling, + colour conversions and video decompression for very high frame + rates. +Default: 1 +Note: The kernel must be compiled with the CONFIG_KMOD option + enabled for the 'w9968cf-vpp' module to be loaded and for + this parameter to be present. +------------------------------------------------------------------------------- Name: simcams Type: int Syntax: diff --git a/trunk/Documentation/video4linux/CARDLIST.cx88 b/trunk/Documentation/video4linux/CARDLIST.cx88 index 8bea3fbd0548..56e194f1a0b0 100644 --- a/trunk/Documentation/video4linux/CARDLIST.cx88 +++ b/trunk/Documentation/video4linux/CARDLIST.cx88 @@ -42,4 +42,4 @@ 41 -> Hauppauge WinTV-HVR1100 DVB-T/Hybrid (Low Profile) [0070:9800,0070:9802] 42 -> digitalnow DNTV Live! DVB-T Pro [1822:0025] 43 -> KWorld/VStream XPert DVB-T with cx22702 [17de:08a1] - 44 -> DViCO FusionHDTV DVB-T Dual Digital [18ac:db50,18ac:db54] + 44 -> DViCO FusionHDTV DVB-T Dual Digital [18ac:db50] diff --git a/trunk/Documentation/video4linux/CARDLIST.saa7134 b/trunk/Documentation/video4linux/CARDLIST.saa7134 index 8a352597830f..cb3a59bbeb17 100644 --- a/trunk/Documentation/video4linux/CARDLIST.saa7134 +++ b/trunk/Documentation/video4linux/CARDLIST.saa7134 @@ -1,7 +1,7 @@ 0 -> UNKNOWN/GENERIC 1 -> Proteus Pro [philips reference design] [1131:2001,1131:2001] 2 -> LifeView FlyVIDEO3000 [5168:0138,4e42:0138] - 3 -> LifeView/Typhoon FlyVIDEO2000 [5168:0138,4e42:0138] + 3 -> LifeView FlyVIDEO2000 [5168:0138] 4 -> EMPRESS [1131:6752] 5 -> SKNet Monster TV [1131:4e85] 6 -> Tevion MD 9717 @@ -53,12 +53,12 @@ 52 -> AverMedia AverTV/305 [1461:2108] 53 -> ASUS TV-FM 7135 [1043:4845] 54 -> LifeView FlyTV Platinum FM [5168:0214,1489:0214] - 55 -> LifeView FlyDVB-T DUO [5168:0306] + 55 -> LifeView FlyDVB-T DUO [5168:0502,5168:0306] 56 -> Avermedia AVerTV 307 [1461:a70a] 57 -> Avermedia AVerTV GO 007 FM [1461:f31f] 58 -> ADS Tech Instant TV (saa7135) [1421:0350,1421:0351,1421:0370,1421:1370] 59 -> Kworld/Tevion V-Stream Xpert TV PVR7134 - 60 -> LifeView/Typhoon FlyDVB-T Duo Cardbus [5168:0502,4e42:0502] + 60 -> Typhoon DVB-T Duo Digital/Analog Cardbus [4e42:0502] 61 -> Philips TOUGH DVB-T reference design [1131:2004] 62 -> Compro VideoMate TV Gold+II 63 -> Kworld Xpert TV PVR7134 diff --git a/trunk/Documentation/vm/page_migration b/trunk/Documentation/vm/page_migration deleted file mode 100644 index c52820fcf500..000000000000 --- a/trunk/Documentation/vm/page_migration +++ /dev/null @@ -1,129 +0,0 @@ -Page migration --------------- - -Page migration allows the moving of the physical location of pages between -nodes in a numa system while the process is running. This means that the -virtual addresses that the process sees do not change. However, the -system rearranges the physical location of those pages. - -The main intend of page migration is to reduce the latency of memory access -by moving pages near to the processor where the process accessing that memory -is running. - -Page migration allows a process to manually relocate the node on which its -pages are located through the MF_MOVE and MF_MOVE_ALL options while setting -a new memory policy. The pages of process can also be relocated -from another process using the sys_migrate_pages() function call. The -migrate_pages function call takes two sets of nodes and moves pages of a -process that are located on the from nodes to the destination nodes. - -Manual migration is very useful if for example the scheduler has relocated -a process to a processor on a distant node. A batch scheduler or an -administrator may detect the situation and move the pages of the process -nearer to the new processor. At some point in the future we may have -some mechanism in the scheduler that will automatically move the pages. - -Larger installations usually partition the system using cpusets into -sections of nodes. Paul Jackson has equipped cpusets with the ability to -move pages when a task is moved to another cpuset. This allows automatic -control over locality of a process. If a task is moved to a new cpuset -then also all its pages are moved with it so that the performance of the -process does not sink dramatically (as is the case today). - -Page migration allows the preservation of the relative location of pages -within a group of nodes for all migration techniques which will preserve a -particular memory allocation pattern generated even after migrating a -process. This is necessary in order to preserve the memory latencies. -Processes will run with similar performance after migration. - -Page migration occurs in several steps. First a high level -description for those trying to use migrate_pages() and then -a low level description of how the low level details work. - -A. Use of migrate_pages() -------------------------- - -1. Remove pages from the LRU. - - Lists of pages to be migrated are generated by scanning over - pages and moving them into lists. This is done by - calling isolate_lru_page() or __isolate_lru_page(). - Calling isolate_lru_page increases the references to the page - so that it cannot vanish under us. - -2. Generate a list of newly allocates page to move the contents - of the first list to. - -3. The migrate_pages() function is called which attempts - to do the migration. It returns the moved pages in the - list specified as the third parameter and the failed - migrations in the fourth parameter. The first parameter - will contain the pages that could still be retried. - -4. The leftover pages of various types are returned - to the LRU using putback_to_lru_pages() or otherwise - disposed of. The pages will still have the refcount as - increased by isolate_lru_pages()! - -B. Operation of migrate_pages() --------------------------------- - -migrate_pages does several passes over its list of pages. A page is moved -if all references to a page are removable at the time. - -Steps: - -1. Lock the page to be migrated - -2. Insure that writeback is complete. - -3. Make sure that the page has assigned swap cache entry if - it is an anonyous page. The swap cache reference is necessary - to preserve the information contain in the page table maps. - -4. Prep the new page that we want to move to. It is locked - and set to not being uptodate so that all accesses to the new - page immediately lock while we are moving references. - -5. All the page table references to the page are either dropped (file backed) - or converted to swap references (anonymous pages). This should decrease the - reference count. - -6. The radix tree lock is taken - -7. The refcount of the page is examined and we back out if references remain - otherwise we know that we are the only one referencing this page. - -8. The radix tree is checked and if it does not contain the pointer to this - page then we back out. - -9. The mapping is checked. If the mapping is gone then a truncate action may - be in progress and we back out. - -10. The new page is prepped with some settings from the old page so that accesses - to the new page will be discovered to have the correct settings. - -11. The radix tree is changed to point to the new page. - -12. The reference count of the old page is dropped because the reference has now - been removed. - -13. The radix tree lock is dropped. - -14. The page contents are copied to the new page. - -15. The remaining page flags are copied to the new page. - -16. The old page flags are cleared to indicate that the page does - not use any information anymore. - -17. Queued up writeback on the new page is triggered. - -18. If swap pte's were generated for the page then remove them again. - -19. The locks are dropped from the old and new page. - -20. The new page is moved to the LRU. - -Christoph Lameter, December 19, 2005. - diff --git a/trunk/Documentation/x86_64/boot-options.txt b/trunk/Documentation/x86_64/boot-options.txt index 153740f460a6..9c5fc15d03d1 100644 --- a/trunk/Documentation/x86_64/boot-options.txt +++ b/trunk/Documentation/x86_64/boot-options.txt @@ -40,18 +40,6 @@ APICs no_timer_check Don't check the IO-APIC timer. This can work around problems with incorrect timer initialization on some boards. - apicmaintimer Run time keeping from the local APIC timer instead - of using the PIT/HPET interrupt for this. This is useful - when the PIT/HPET interrupts are unreliable. - - noapicmaintimer Don't do time keeping using the APIC timer. - Useful when this option was auto selected, but doesn't work. - - apicpmtimer - Do APIC timer calibration using the pmtimer. Implies - apicmaintimer. Useful when your PIT timer is totally - broken. - Early Console syntax: earlyprintk=vga diff --git a/trunk/MAINTAINERS b/trunk/MAINTAINERS index 9c592aa0280c..ff16eac8cf5b 100644 --- a/trunk/MAINTAINERS +++ b/trunk/MAINTAINERS @@ -540,8 +540,7 @@ S: Supported BTTV VIDEO4LINUX DRIVER P: Mauro Carvalho Chehab -M: mchehab@infradead.org -M: v4l-dvb-maintainer@linuxtv.org +M: mchehab@brturbo.com.br L: video4linux-list@redhat.com W: http://linuxtv.org T: git kernel.org:/pub/scm/linux/kernel/git/mchehab/v4l-dvb.git @@ -558,8 +557,7 @@ S: Supported CONFIGFS P: Joel Becker -M: joel.becker@oracle.com -L: linux-kernel@vger.kernel.org +M: Joel Becker S: Supported CIRRUS LOGIC GENERIC FBDEV DRIVER @@ -838,12 +836,11 @@ S: Maintained DVB SUBSYSTEM AND DRIVERS P: LinuxTV.org Project -M: mchehab@infradead.org -M: v4l-dvb-maintainer@linuxtv.org +M: linux-dvb-maintainer@linuxtv.org L: linux-dvb@linuxtv.org (subscription required) W: http://linuxtv.org/ T: git kernel.org:/pub/scm/linux/kernel/git/mchehab/v4l-dvb.git -S: Maintained +S: Supported EATA-DMA SCSI DRIVER P: Michael Neuffer @@ -870,15 +867,6 @@ L: ebtables-devel@lists.sourceforge.net W: http://ebtables.sourceforge.net/ S: Maintained -EDAC-CORE -P: Doug Thompson -M: norsk5@xmission.com, dthompson@linuxnetworx.com -P: Dave Peterson -M: dsp@llnl.gov, dave_peterson@pobox.com -L: bluesmoke-devel@lists.sourceforge.net -W: bluesmoke.sourceforge.net -S: Maintained - EEPRO100 NETWORK DRIVER P: Andrey V. Savochkin M: saw@saw.sw.com.sg @@ -931,12 +919,6 @@ M: sct@redhat.com, akpm@osdl.org, adilger@clusterfs.com L: ext3-users@redhat.com S: Maintained -F71805F HARDWARE MONITORING DRIVER -P: Jean Delvare -M: khali@linux-fr.org -L: lm-sensors@lm-sensors.org -S: Maintained - FARSYNC SYNCHRONOUS DRIVER P: Kevin Curtis M: kevin.curtis@farsite.co.uk @@ -1185,8 +1167,8 @@ T: git kernel.org:/pub/scm/linux/kernel/git/aegl/linux-2.6.git S: Maintained SN-IA64 (Itanium) SUB-PLATFORM -P: Jes Sorensen -M: jes@sgi.com +P: Greg Edwards +M: edwardsg@sgi.com L: linux-altix@sgi.com L: linux-ia64@vger.kernel.org W: http://www.sgi.com/altix @@ -1416,7 +1398,7 @@ IRDA SUBSYSTEM P: Jean Tourrilhes L: irda-users@lists.sourceforge.net (subscribers-only) W: http://irda.sourceforge.net/ -S: Odd Fixes +S: Maintained ISAPNP P: Jaroslav Kysela @@ -1861,14 +1843,7 @@ M: yoshfuji@linux-ipv6.org P: Patrick McHardy M: kaber@coreworks.de L: netdev@vger.kernel.org -T: git kernel.org:/pub/scm/linux/kernel/git/davem/net-2.6.git -S: Maintained - -NETWORKING [WIRELESS] -P: John W. Linville -M: linville@tuxdriver.com -L: netdev@vger.kernel.org -T: git kernel.org:/pub/scm/linux/kernel/git/linville/wireless-2.6.git +T: git kernel.org:/pub/scm/linux/kernel/davem/net-2.6.git S: Maintained IPVS @@ -1993,6 +1968,7 @@ M: philb@gnu.org P: Tim Waugh M: tim@cyberelk.net P: David Campbell +M: campbell@torque.net P: Andrea Arcangeli M: andrea@suse.de L: linux-parport@lists.infradead.org @@ -2232,23 +2208,7 @@ P: Martin Schwidefsky M: schwidefsky@de.ibm.com M: linux390@de.ibm.com L: linux-390@vm.marist.edu -W: http://www.ibm.com/developerworks/linux/linux390/ -S: Supported - -S390 NETWORK DRIVERS -P: Frank Pavlic -M: fpavlic@de.ibm.com -M: linux390@de.ibm.com -L: linux-390@vm.marist.edu -W: http://www.ibm.com/developerworks/linux/linux390/ -S: Supported - -S390 ZFCP DRIVER -P: Andreas Herrmann -M: aherrman@de.ibm.com -M: linux390@de.ibm.com -L: linux-390@vm.marist.edu -W: http://www.ibm.com/developerworks/linux/linux390/ +W: http://oss.software.ibm.com/developerworks/opensource/linux390 S: Supported SAA7146 VIDEO4LINUX-2 DRIVER @@ -2322,7 +2282,7 @@ S: Supported SELINUX SECURITY MODULE P: Stephen Smalley -M: sds@tycho.nsa.gov +M: sds@epoch.ncsc.mil P: James Morris M: jmorris@namei.org L: linux-kernel@vger.kernel.org (kernel issues) @@ -2576,11 +2536,11 @@ S: Maintained TIPC NETWORK LAYER P: Per Liden -M: per.liden@ericsson.com +M: per.liden@nospam.ericsson.com P: Jon Maloy -M: jon.maloy@ericsson.com +M: jon.maloy@nospam.ericsson.com P: Allan Stephens -M: allan.stephens@windriver.com +M: allan.stephens@nospam.windriver.com L: tipc-discussion@lists.sourceforge.net W: http://tipc.sourceforge.net/ W: http://tipc.cslab.ericsson.net/ @@ -2697,14 +2657,6 @@ M: dbrownell@users.sourceforge.net L: linux-usb-devel@lists.sourceforge.net S: Maintained -USB ET61X[12]51 DRIVER -P: Luca Risolia -M: luca.risolia@studio.unibo.it -L: linux-usb-devel@lists.sourceforge.net -L: video4linux-list@redhat.com -W: http://www.linux-projects.org -S: Maintained - USB HID/HIDBP DRIVERS P: Vojtech Pavlik M: vojtech@suse.cz @@ -2868,7 +2820,6 @@ USB SN9C10x DRIVER P: Luca Risolia M: luca.risolia@studio.unibo.it L: linux-usb-devel@lists.sourceforge.net -L: video4linux-list@redhat.com W: http://www.linux-projects.org S: Maintained @@ -2898,7 +2849,6 @@ USB W996[87]CF DRIVER P: Luca Risolia M: luca.risolia@studio.unibo.it L: linux-usb-devel@lists.sourceforge.net -L: video4linux-list@redhat.com W: http://www.linux-projects.org S: Maintained @@ -2980,8 +2930,7 @@ S: Maintained VIDEO FOR LINUX P: Mauro Carvalho Chehab -M: mchehab@infradead.org -M: v4l-dvb-maintainer@linuxtv.org +M: mchehab@brturbo.com.br L: video4linux-list@redhat.com W: http://linuxtv.org T: git kernel.org:/pub/scm/linux/kernel/git/mchehab/v4l-dvb.git diff --git a/trunk/Makefile b/trunk/Makefile index 74d67b2c35d9..252a659896f3 100644 --- a/trunk/Makefile +++ b/trunk/Makefile @@ -1,7 +1,7 @@ VERSION = 2 PATCHLEVEL = 6 SUBLEVEL = 16 -EXTRAVERSION =-rc3 +EXTRAVERSION =-rc1 NAME=Sliding Snow Leopard # *DOCUMENTATION* @@ -442,7 +442,7 @@ export KBUILD_DEFCONFIG config %config: scripts_basic outputmakefile FORCE $(Q)mkdir -p include/linux $(Q)$(MAKE) $(build)=scripts/kconfig $@ - $(Q)$(MAKE) -C $(srctree) KBUILD_SRC= .kernelrelease + $(Q)$(MAKE) .kernelrelease else # =========================================================================== diff --git a/trunk/arch/alpha/kernel/asm-offsets.c b/trunk/arch/alpha/kernel/asm-offsets.c index 6c56c754a0b5..8f2e5c718b50 100644 --- a/trunk/arch/alpha/kernel/asm-offsets.c +++ b/trunk/arch/alpha/kernel/asm-offsets.c @@ -28,7 +28,6 @@ void foo(void) DEFINE(TASK_GID, offsetof(struct task_struct, gid)); DEFINE(TASK_EGID, offsetof(struct task_struct, egid)); DEFINE(TASK_REAL_PARENT, offsetof(struct task_struct, real_parent)); - DEFINE(TASK_GROUP_LEADER, offsetof(struct task_struct, group_leader)); DEFINE(TASK_TGID, offsetof(struct task_struct, tgid)); BLANK(); diff --git a/trunk/arch/alpha/kernel/entry.S b/trunk/arch/alpha/kernel/entry.S index 7af15bf7e5ab..e38671c922bc 100644 --- a/trunk/arch/alpha/kernel/entry.S +++ b/trunk/arch/alpha/kernel/entry.S @@ -879,19 +879,17 @@ sys_getxpid: /* See linux/kernel/timer.c sys_getppid for discussion about this loop. */ - ldq $3, TASK_GROUP_LEADER($2) - ldq $4, TASK_REAL_PARENT($3) - ldl $0, TASK_TGID($2) -1: ldl $1, TASK_TGID($4) + ldq $3, TASK_REAL_PARENT($2) +1: ldl $1, TASK_TGID($3) #ifdef CONFIG_SMP - mov $4, $5 + mov $3, $4 mb - ldq $3, TASK_GROUP_LEADER($2) - ldq $4, TASK_REAL_PARENT($3) - cmpeq $4, $5, $5 - beq $5, 1b + ldq $3, TASK_REAL_PARENT($2) + cmpeq $3, $4, $4 + beq $4, 1b #endif stq $1, 80($sp) + ldl $0, TASK_TGID($2) ret .end sys_getxpid diff --git a/trunk/arch/alpha/kernel/irq.c b/trunk/arch/alpha/kernel/irq.c index 9006063e7369..76be5cf0de13 100644 --- a/trunk/arch/alpha/kernel/irq.c +++ b/trunk/arch/alpha/kernel/irq.c @@ -68,32 +68,34 @@ show_interrupts(struct seq_file *p, void *v) #ifdef CONFIG_SMP int j; #endif - int irq = *(loff_t *) v; + int i = *(loff_t *) v; struct irqaction * action; unsigned long flags; #ifdef CONFIG_SMP - if (irq == 0) { + if (i == 0) { seq_puts(p, " "); - for_each_online_cpu(j) - seq_printf(p, "CPU%d ", j); + for (i = 0; i < NR_CPUS; i++) + if (cpu_online(i)) + seq_printf(p, "CPU%d ", i); seq_putc(p, '\n'); } #endif - if (irq < ACTUAL_NR_IRQS) { - spin_lock_irqsave(&irq_desc[irq].lock, flags); - action = irq_desc[irq].action; + if (i < ACTUAL_NR_IRQS) { + spin_lock_irqsave(&irq_desc[i].lock, flags); + action = irq_desc[i].action; if (!action) goto unlock; - seq_printf(p, "%3d: ", irq); + seq_printf(p, "%3d: ",i); #ifndef CONFIG_SMP - seq_printf(p, "%10u ", kstat_irqs(irq)); + seq_printf(p, "%10u ", kstat_irqs(i)); #else - for_each_online_cpu(j) - seq_printf(p, "%10u ", kstat_cpu(j).irqs[irq]); + for (j = 0; j < NR_CPUS; j++) + if (cpu_online(j)) + seq_printf(p, "%10u ", kstat_cpu(j).irqs[i]); #endif - seq_printf(p, " %14s", irq_desc[irq].handler->typename); + seq_printf(p, " %14s", irq_desc[i].handler->typename); seq_printf(p, " %c%s", (action->flags & SA_INTERRUPT)?'+':' ', action->name); @@ -106,12 +108,13 @@ show_interrupts(struct seq_file *p, void *v) seq_putc(p, '\n'); unlock: - spin_unlock_irqrestore(&irq_desc[irq].lock, flags); - } else if (irq == ACTUAL_NR_IRQS) { + spin_unlock_irqrestore(&irq_desc[i].lock, flags); + } else if (i == ACTUAL_NR_IRQS) { #ifdef CONFIG_SMP seq_puts(p, "IPI: "); - for_each_online_cpu(j) - seq_printf(p, "%10lu ", cpu_data[j].ipi_count); + for (i = 0; i < NR_CPUS; i++) + if (cpu_online(i)) + seq_printf(p, "%10lu ", cpu_data[i].ipi_count); seq_putc(p, '\n'); #endif seq_printf(p, "ERR: %10lu\n", irq_err_count); @@ -119,6 +122,7 @@ show_interrupts(struct seq_file *p, void *v) return 0; } + /* * handle_irq handles all normal device IRQ's (the special * SMP cross-CPU interrupts have their own specific diff --git a/trunk/arch/alpha/kernel/osf_sys.c b/trunk/arch/alpha/kernel/osf_sys.c index 7fb14f42a125..01fe990d3e54 100644 --- a/trunk/arch/alpha/kernel/osf_sys.c +++ b/trunk/arch/alpha/kernel/osf_sys.c @@ -960,7 +960,7 @@ osf_utimes(char __user *filename, struct timeval32 __user *tvs) return -EFAULT; } - return do_utimes(AT_FDCWD, filename, tvs ? ktvs : NULL); + return do_utimes(filename, tvs ? ktvs : NULL); } #define MAX_SELECT_SECONDS \ diff --git a/trunk/arch/alpha/kernel/smp.c b/trunk/arch/alpha/kernel/smp.c index 02c2db08114a..4b873527ce1c 100644 --- a/trunk/arch/alpha/kernel/smp.c +++ b/trunk/arch/alpha/kernel/smp.c @@ -73,6 +73,9 @@ cpumask_t cpu_online_map; EXPORT_SYMBOL(cpu_online_map); +/* cpus reported in the hwrpb */ +static unsigned long hwrpb_cpu_present_mask __initdata = 0; + int smp_num_probed; /* Internal processor count */ int smp_num_cpus = 1; /* Number that came online. */ @@ -439,7 +442,7 @@ setup_smp(void) if ((cpu->flags & 0x1cc) == 0x1cc) { smp_num_probed++; /* Assume here that "whami" == index */ - cpu_set(i, cpu_possible_map); + hwrpb_cpu_present_mask |= (1UL << i); cpu->pal_revision = boot_cpu_palrev; } @@ -450,12 +453,12 @@ setup_smp(void) } } else { smp_num_probed = 1; - cpu_set(boot_cpuid, cpu_possible_map); + hwrpb_cpu_present_mask = (1UL << boot_cpuid); } cpu_present_mask = cpumask_of_cpu(boot_cpuid); printk(KERN_INFO "SMP: %d CPUs probed -- cpu_present_mask = %lx\n", - smp_num_probed, cpu_possible_map.bits[0]); + smp_num_probed, hwrpb_cpu_present_mask); } /* @@ -464,6 +467,8 @@ setup_smp(void) void __init smp_prepare_cpus(unsigned int max_cpus) { + int cpu_count, i; + /* Take care of some initial bookkeeping. */ memset(ipi_data, 0, sizeof(ipi_data)); @@ -481,7 +486,19 @@ smp_prepare_cpus(unsigned int max_cpus) printk(KERN_INFO "SMP starting up secondaries.\n"); - smp_num_cpus = smp_num_probed; + cpu_count = 1; + for (i = 0; (i < NR_CPUS) && (cpu_count < max_cpus); i++) { + if (i == boot_cpuid) + continue; + + if (((hwrpb_cpu_present_mask >> i) & 1) == 0) + continue; + + cpu_set(i, cpu_possible_map); + cpu_count++; + } + + smp_num_cpus = cpu_count; } void __devinit diff --git a/trunk/arch/arm/Kconfig b/trunk/arch/arm/Kconfig index 15dc1a0dffbb..5959e36c3b4c 100644 --- a/trunk/arch/arm/Kconfig +++ b/trunk/arch/arm/Kconfig @@ -10,9 +10,9 @@ config ARM default y help The ARM series is a line of low-power-consumption RISC chip designs - licensed by ARM Ltd and targeted at embedded applications and + licensed by ARM ltd and targeted at embedded applications and handhelds such as the Compaq IPAQ. ARM-based PCs are no longer - manufactured, but legacy ARM-based PC hardware remains popular in + manufactured, but legacy ARM-based PC hardware remains popular in Europe. There is an ARM Linux project with a web page at . @@ -69,9 +69,6 @@ config GENERIC_ISA_DMA config FIQ bool -config ARCH_MTD_XIP - bool - source "init/Kconfig" menu "System Type" @@ -84,62 +81,45 @@ config ARCH_CLPS7500 bool "Cirrus-CL-PS7500FE" select TIMER_ACORN select ISA - help - Support for the Cirrus Logic PS7500FE system-on-a-chip. config ARCH_CLPS711X bool "CLPS711x/EP721x-based" - help - Support for Cirrus Logic 711x/721x based boards. config ARCH_CO285 bool "Co-EBSA285" select FOOTBRIDGE select FOOTBRIDGE_ADDIN - help - Support for Intel's EBSA285 companion chip. config ARCH_EBSA110 bool "EBSA-110" select ISA help This is an evaluation board for the StrongARM processor available - from Digital. It has limited hardware on-board, including an + from Digital. It has limited hardware on-board, including an onboard Ethernet interface, two PCMCIA sockets, two serial ports and a parallel port. config ARCH_FOOTBRIDGE bool "FootBridge" select FOOTBRIDGE - help - Support for systems based on the DC21285 companion chip - ("FootBridge"), such as the Simtec CATS and the Rebel NetWinder. config ARCH_INTEGRATOR bool "Integrator" select ARM_AMBA select ICST525 - help - Support for ARM's Integrator platform. config ARCH_IOP3XX bool "IOP3xx-based" select PCI - help - Support for Intel's IOP3XX (XScale) family of processors. config ARCH_IXP4XX bool "IXP4xx-based" select DMABOUNCE select PCI - help - Support for Intel's IXP4XX (XScale) family of processors. config ARCH_IXP2000 bool "IXP2400/2800-based" select PCI - help - Support for Intel's IXP2400/2800 (XScale) family of processors. config ARCH_L7200 bool "LinkUp-L7200" @@ -156,9 +136,6 @@ config ARCH_L7200 config ARCH_PXA bool "PXA2xx-based" - select ARCH_MTD_XIP - help - Support for Intel's PXA2XX processor line. config ARCH_RPC bool "RiscPC" @@ -175,25 +152,19 @@ config ARCH_SA1100 bool "SA1100-based" select ISA select ARCH_DISCONTIGMEM_ENABLE - select ARCH_MTD_XIP - help - Support for StrongARM 11x0 based boards. config ARCH_S3C2410 bool "Samsung S3C2410" help Samsung S3C2410X CPU based systems, such as the Simtec Electronics BAST (), the IPAQ 1940 or - the Samsung SMDK2410 development board (and derivatives). + the Samsung SMDK2410 development board (and derviatives). config ARCH_SHARK bool "Shark" select ISA select ISA_DMA select PCI - help - Support for the StrongARM based Digital DNARD machine, also known - as "Shark" (). config ARCH_LH7A40X bool "Sharp LH7A40X" @@ -205,8 +176,6 @@ config ARCH_LH7A40X config ARCH_OMAP bool "TI OMAP" - help - Support for TI's OMAP platform (OMAP1 and OMAP2). config ARCH_VERSATILE bool "Versatile" @@ -225,8 +194,6 @@ config ARCH_REALVIEW config ARCH_IMX bool "IMX" - help - Support for Motorola's i.MX family of processors (MX1, MXL). config ARCH_H720X bool "Hynix-HMS720x-based" @@ -243,8 +210,8 @@ config ARCH_AAEC2000 config ARCH_AT91RM9200 bool "AT91RM9200" help - Say Y here if you intend to run this kernel on an Atmel - AT91RM9200-based board. + Say Y here if you intend to run this kernel on an AT91RM9200-based + board. endchoice @@ -450,8 +417,8 @@ config AEABI To use this you need GCC version 4.0.0 or later. config OABI_COMPAT - bool "Allow old ABI binaries to run with this kernel (EXPERIMENTAL)" - depends on AEABI && EXPERIMENTAL + bool "Allow old ABI binaries to run with this kernel" + depends on AEABI default y help This option preserves the old syscall interface along with the diff --git a/trunk/arch/arm/boot/compressed/head.S b/trunk/arch/arm/boot/compressed/head.S index db3389d8e027..aaa47400eb9c 100644 --- a/trunk/arch/arm/boot/compressed/head.S +++ b/trunk/arch/arm/boot/compressed/head.S @@ -334,7 +334,7 @@ __setup_mmu: sub r3, r4, #16384 @ Page directory size mov r1, #0x12 orr r1, r1, #3 << 10 add r2, r3, #16384 -1: cmp r1, r9 @ if virt > start of RAM +1: cmp r1, r8 @ if virt > start of RAM orrhs r1, r1, #0x0c @ set cacheable, bufferable cmp r1, r10 @ if virt > end of RAM bichs r1, r1, #0x0c @ clear cacheable, bufferable diff --git a/trunk/arch/arm/configs/at91rm9200dk_defconfig b/trunk/arch/arm/configs/at91rm9200dk_defconfig index 1fe73d198888..5cdd13acf8ff 100644 --- a/trunk/arch/arm/configs/at91rm9200dk_defconfig +++ b/trunk/arch/arm/configs/at91rm9200dk_defconfig @@ -85,6 +85,7 @@ CONFIG_DEFAULT_IOSCHED="anticipatory" # CONFIG_ARCH_CLPS711X is not set # CONFIG_ARCH_CO285 is not set # CONFIG_ARCH_EBSA110 is not set +# CONFIG_ARCH_CAMELOT is not set # CONFIG_ARCH_FOOTBRIDGE is not set # CONFIG_ARCH_INTEGRATOR is not set # CONFIG_ARCH_IOP3XX is not set diff --git a/trunk/arch/arm/configs/at91rm9200ek_defconfig b/trunk/arch/arm/configs/at91rm9200ek_defconfig index b7d934cdb1b7..20838ccf1da7 100644 --- a/trunk/arch/arm/configs/at91rm9200ek_defconfig +++ b/trunk/arch/arm/configs/at91rm9200ek_defconfig @@ -85,6 +85,7 @@ CONFIG_DEFAULT_IOSCHED="anticipatory" # CONFIG_ARCH_CLPS711X is not set # CONFIG_ARCH_CO285 is not set # CONFIG_ARCH_EBSA110 is not set +# CONFIG_ARCH_CAMELOT is not set # CONFIG_ARCH_FOOTBRIDGE is not set # CONFIG_ARCH_INTEGRATOR is not set # CONFIG_ARCH_IOP3XX is not set diff --git a/trunk/arch/arm/configs/bast_defconfig b/trunk/arch/arm/configs/bast_defconfig index 4a8564f386af..6886001b5366 100644 --- a/trunk/arch/arm/configs/bast_defconfig +++ b/trunk/arch/arm/configs/bast_defconfig @@ -14,7 +14,8 @@ CONFIG_GENERIC_IOMAP=y # Code maturity level options # CONFIG_EXPERIMENTAL=y -CONFIG_CLEAN_COMPILE=y +# CONFIG_CLEAN_COMPILE is not set +CONFIG_BROKEN=y CONFIG_BROKEN_ON_SMP=y # @@ -359,6 +360,7 @@ CONFIG_BLK_DEV_IDE_BAST=y # # IEEE 1394 (FireWire) support # +# CONFIG_IEEE1394 is not set # # I2O device support @@ -779,6 +781,7 @@ CONFIG_SYSFS=y # CONFIG_DEVFS_FS is not set # CONFIG_DEVPTS_FS_XATTR is not set # CONFIG_TMPFS is not set +# CONFIG_HUGETLBFS is not set # CONFIG_HUGETLB_PAGE is not set CONFIG_RAMFS=y diff --git a/trunk/arch/arm/configs/collie_defconfig b/trunk/arch/arm/configs/collie_defconfig index c9aa878e610a..15468a0cf70e 100644 --- a/trunk/arch/arm/configs/collie_defconfig +++ b/trunk/arch/arm/configs/collie_defconfig @@ -13,7 +13,8 @@ CONFIG_GENERIC_CALIBRATE_DELAY=y # Code maturity level options # CONFIG_EXPERIMENTAL=y -CONFIG_CLEAN_COMPILE=y +# CONFIG_CLEAN_COMPILE is not set +CONFIG_BROKEN=y CONFIG_BROKEN_ON_SMP=y CONFIG_LOCK_KERNEL=y CONFIG_INIT_ENV_ARG_LIMIT=32 @@ -307,7 +308,9 @@ CONFIG_MTD_CFI_I2=y # CONFIG_MTD_ROM is not set # CONFIG_MTD_ABSENT is not set CONFIG_MTD_OBSOLETE_CHIPS=y +# CONFIG_MTD_AMDSTD is not set CONFIG_MTD_SHARP=y +# CONFIG_MTD_JEDEC is not set # # Mapping drivers for chip access @@ -393,6 +396,7 @@ CONFIG_ATA_OVER_ETH=m # # IEEE 1394 (FireWire) support # +# CONFIG_IEEE1394 is not set # # I2O device support @@ -737,6 +741,7 @@ CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1" CONFIG_PROC_FS=y CONFIG_SYSFS=y CONFIG_TMPFS=y +# CONFIG_HUGETLBFS is not set # CONFIG_HUGETLB_PAGE is not set CONFIG_RAMFS=y # CONFIG_RELAYFS_FS is not set diff --git a/trunk/arch/arm/configs/csb337_defconfig b/trunk/arch/arm/configs/csb337_defconfig index 94bd9932a402..885a3184830a 100644 --- a/trunk/arch/arm/configs/csb337_defconfig +++ b/trunk/arch/arm/configs/csb337_defconfig @@ -85,6 +85,7 @@ CONFIG_DEFAULT_IOSCHED="anticipatory" # CONFIG_ARCH_CLPS711X is not set # CONFIG_ARCH_CO285 is not set # CONFIG_ARCH_EBSA110 is not set +# CONFIG_ARCH_CAMELOT is not set # CONFIG_ARCH_FOOTBRIDGE is not set # CONFIG_ARCH_INTEGRATOR is not set # CONFIG_ARCH_IOP3XX is not set diff --git a/trunk/arch/arm/configs/csb637_defconfig b/trunk/arch/arm/configs/csb637_defconfig index 1519124c5501..95a96a5462a0 100644 --- a/trunk/arch/arm/configs/csb637_defconfig +++ b/trunk/arch/arm/configs/csb637_defconfig @@ -85,6 +85,7 @@ CONFIG_DEFAULT_IOSCHED="anticipatory" # CONFIG_ARCH_CLPS711X is not set # CONFIG_ARCH_CO285 is not set # CONFIG_ARCH_EBSA110 is not set +# CONFIG_ARCH_CAMELOT is not set # CONFIG_ARCH_FOOTBRIDGE is not set # CONFIG_ARCH_INTEGRATOR is not set # CONFIG_ARCH_IOP3XX is not set diff --git a/trunk/arch/arm/configs/enp2611_defconfig b/trunk/arch/arm/configs/enp2611_defconfig index 5fdaf3ce9d56..9592e3925c79 100644 --- a/trunk/arch/arm/configs/enp2611_defconfig +++ b/trunk/arch/arm/configs/enp2611_defconfig @@ -171,7 +171,7 @@ CONFIG_ALIGNMENT_TRAP=y # CONFIG_ZBOOT_ROM_TEXT=0x0 CONFIG_ZBOOT_ROM_BSS=0x0 -CONFIG_CMDLINE="console=ttyS0,57600 root=/dev/nfs ip=bootp mem=64M@0x0" +CONFIG_CMDLINE="console=ttyS0,57600 root=/dev/nfs ip=bootp mem=64M@0x0 pci=firmware" # CONFIG_XIP_KERNEL is not set # diff --git a/trunk/arch/arm/configs/ep80219_defconfig b/trunk/arch/arm/configs/ep80219_defconfig index 3c73b707c2f3..fbe312e757cb 100644 --- a/trunk/arch/arm/configs/ep80219_defconfig +++ b/trunk/arch/arm/configs/ep80219_defconfig @@ -522,7 +522,6 @@ CONFIG_E100=y # CONFIG_DL2K is not set CONFIG_E1000=y CONFIG_E1000_NAPI=y -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/arm/configs/iq31244_defconfig b/trunk/arch/arm/configs/iq31244_defconfig index 32467160a6df..c07628ceaf0c 100644 --- a/trunk/arch/arm/configs/iq31244_defconfig +++ b/trunk/arch/arm/configs/iq31244_defconfig @@ -493,7 +493,6 @@ CONFIG_NETDEVICES=y # CONFIG_DL2K is not set CONFIG_E1000=y CONFIG_E1000_NAPI=y -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/arm/configs/iq80321_defconfig b/trunk/arch/arm/configs/iq80321_defconfig index b000da753c41..18fa1615fdfd 100644 --- a/trunk/arch/arm/configs/iq80321_defconfig +++ b/trunk/arch/arm/configs/iq80321_defconfig @@ -415,7 +415,6 @@ CONFIG_NETDEVICES=y # CONFIG_DL2K is not set CONFIG_E1000=y CONFIG_E1000_NAPI=y -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/arm/configs/iq80331_defconfig b/trunk/arch/arm/configs/iq80331_defconfig index 46c79e1efe07..f50035de1fff 100644 --- a/trunk/arch/arm/configs/iq80331_defconfig +++ b/trunk/arch/arm/configs/iq80331_defconfig @@ -496,7 +496,6 @@ CONFIG_NETDEVICES=y # CONFIG_DL2K is not set CONFIG_E1000=y CONFIG_E1000_NAPI=y -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/arm/configs/iq80332_defconfig b/trunk/arch/arm/configs/iq80332_defconfig index 11959b705d82..18b3f372ed68 100644 --- a/trunk/arch/arm/configs/iq80332_defconfig +++ b/trunk/arch/arm/configs/iq80332_defconfig @@ -496,7 +496,6 @@ CONFIG_NETDEVICES=y # CONFIG_DL2K is not set CONFIG_E1000=y CONFIG_E1000_NAPI=y -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/arm/configs/ixdp2400_defconfig b/trunk/arch/arm/configs/ixdp2400_defconfig index c67fc449a11f..d9d6bb86a6fa 100644 --- a/trunk/arch/arm/configs/ixdp2400_defconfig +++ b/trunk/arch/arm/configs/ixdp2400_defconfig @@ -172,7 +172,7 @@ CONFIG_ALIGNMENT_TRAP=y # CONFIG_ZBOOT_ROM_TEXT=0x0 CONFIG_ZBOOT_ROM_BSS=0x0 -CONFIG_CMDLINE="console=ttyS0,57600 root=/dev/nfs ip=bootp mem=64M@0x0" +CONFIG_CMDLINE="console=ttyS0,57600 root=/dev/nfs ip=bootp mem=64M@0x0 pci=firmware" # CONFIG_XIP_KERNEL is not set # diff --git a/trunk/arch/arm/configs/ixdp2401_defconfig b/trunk/arch/arm/configs/ixdp2401_defconfig index 60d66e82c51f..2dc9d499c7d7 100644 --- a/trunk/arch/arm/configs/ixdp2401_defconfig +++ b/trunk/arch/arm/configs/ixdp2401_defconfig @@ -172,7 +172,7 @@ CONFIG_ALIGNMENT_TRAP=y # CONFIG_ZBOOT_ROM_TEXT=0x0 CONFIG_ZBOOT_ROM_BSS=0x0 -CONFIG_CMDLINE="console=ttyS0,115200 root=/dev/nfs ip=bootp mem=64M@0x0" +CONFIG_CMDLINE="console=ttyS0,115200 root=/dev/nfs ip=bootp mem=64M@0x0 pci=firmware" # CONFIG_XIP_KERNEL is not set # diff --git a/trunk/arch/arm/configs/ixdp2801_defconfig b/trunk/arch/arm/configs/ixdp2801_defconfig index f54f3dcc5b33..ea8f4b478fa3 100644 --- a/trunk/arch/arm/configs/ixdp2801_defconfig +++ b/trunk/arch/arm/configs/ixdp2801_defconfig @@ -172,7 +172,7 @@ CONFIG_ALIGNMENT_TRAP=y # CONFIG_ZBOOT_ROM_TEXT=0x0 CONFIG_ZBOOT_ROM_BSS=0x0 -CONFIG_CMDLINE="console=ttyS0,115200 root=/dev/nfs ip=bootp mem=64M@0x0" +CONFIG_CMDLINE="console=ttyS0,115200 root=/dev/nfs ip=bootp mem=64M@0x0 pci=firmware ixdp2x01_clock=50000000" # CONFIG_XIP_KERNEL is not set # diff --git a/trunk/arch/arm/configs/s3c2410_defconfig b/trunk/arch/arm/configs/s3c2410_defconfig index 6695b07cf1ba..33f31080a98c 100644 --- a/trunk/arch/arm/configs/s3c2410_defconfig +++ b/trunk/arch/arm/configs/s3c2410_defconfig @@ -1,10 +1,11 @@ # # Automatically generated make config: don't edit -# Linux kernel version: 2.6.16-rc2 -# Mon Feb 6 11:17:23 2006 +# Linux kernel version: 2.6.15-rc1 +# Sun Nov 13 17:41:24 2005 # CONFIG_ARM=y CONFIG_MMU=y +CONFIG_UID16=y CONFIG_RWSEM_GENERIC_SPINLOCK=y CONFIG_GENERIC_CALIBRATE_DELAY=y @@ -12,7 +13,8 @@ CONFIG_GENERIC_CALIBRATE_DELAY=y # Code maturity level options # CONFIG_EXPERIMENTAL=y -CONFIG_CLEAN_COMPILE=y +# CONFIG_CLEAN_COMPILE is not set +CONFIG_BROKEN=y CONFIG_BROKEN_ON_SMP=y CONFIG_INIT_ENV_ARG_LIMIT=32 @@ -27,31 +29,27 @@ CONFIG_SYSVIPC=y # CONFIG_BSD_PROCESS_ACCT is not set CONFIG_SYSCTL=y # CONFIG_AUDIT is not set +# CONFIG_HOTPLUG is not set +CONFIG_KOBJECT_UEVENT=y # CONFIG_IKCONFIG is not set CONFIG_INITRAMFS_SOURCE="" -CONFIG_UID16=y -CONFIG_CC_OPTIMIZE_FOR_SIZE=y # CONFIG_EMBEDDED is not set CONFIG_KALLSYMS=y # CONFIG_KALLSYMS_ALL is not set # CONFIG_KALLSYMS_EXTRA_PASS is not set -CONFIG_HOTPLUG=y CONFIG_PRINTK=y CONFIG_BUG=y -CONFIG_ELF_CORE=y CONFIG_BASE_FULL=y CONFIG_FUTEX=y CONFIG_EPOLL=y +CONFIG_CC_OPTIMIZE_FOR_SIZE=y CONFIG_SHMEM=y CONFIG_CC_ALIGN_FUNCTIONS=0 CONFIG_CC_ALIGN_LABELS=0 CONFIG_CC_ALIGN_LOOPS=0 CONFIG_CC_ALIGN_JUMPS=0 -CONFIG_SLAB=y # CONFIG_TINY_SHMEM is not set CONFIG_BASE_SMALL=0 -# CONFIG_SLOB is not set -CONFIG_OBSOLETE_INTERMODULE=y # # Loadable module support @@ -105,7 +103,6 @@ CONFIG_ARCH_S3C2410=y # CONFIG_ARCH_IMX is not set # CONFIG_ARCH_H720X is not set # CONFIG_ARCH_AAEC2000 is not set -# CONFIG_ARCH_AT91RM9200 is not set # # S3C24XX Implementations @@ -164,6 +161,7 @@ CONFIG_CPU_TLB_V4WBI=y # Bus support # CONFIG_ISA=y +CONFIG_ISA_DMA_API=y # # PCCARD (PCMCIA/CardBus) support @@ -175,7 +173,6 @@ CONFIG_ISA=y # # CONFIG_PREEMPT is not set # CONFIG_NO_IDLE_HZ is not set -# CONFIG_AEABI is not set # CONFIG_ARCH_DISCONTIGMEM_ENABLE is not set CONFIG_SELECT_MEMORY_MODEL=y CONFIG_FLATMEM_MANUAL=y @@ -218,8 +215,6 @@ CONFIG_BINFMT_AOUT=y # Power management options # CONFIG_PM=y -CONFIG_PM_LEGACY=y -# CONFIG_PM_DEBUG is not set CONFIG_APM=y # @@ -265,11 +260,6 @@ CONFIG_TCP_CONG_BIC=y # SCTP Configuration (EXPERIMENTAL) # # CONFIG_IP_SCTP is not set - -# -# TIPC Configuration (EXPERIMENTAL) -# -# CONFIG_TIPC is not set # CONFIG_ATM is not set # CONFIG_BRIDGE is not set # CONFIG_VLAN_8021Q is not set @@ -287,6 +277,7 @@ CONFIG_TCP_CONG_BIC=y # QoS and/or fair queueing # # CONFIG_NET_SCHED is not set +# CONFIG_NET_CLS_ROUTE is not set # # Network testing @@ -309,11 +300,6 @@ CONFIG_PREVENT_FIRMWARE_BUILD=y # CONFIG_FW_LOADER is not set # CONFIG_DEBUG_DRIVER is not set -# -# Connector - unified userspace <-> kernelspace linker -# -# CONFIG_CONNECTOR is not set - # # Memory Technology Devices (MTD) # @@ -427,6 +413,8 @@ CONFIG_PARPORT_1284=y # # Block devices # +# CONFIG_BLK_DEV_XD is not set +# CONFIG_PARIDE is not set # CONFIG_BLK_DEV_COW_COMMON is not set CONFIG_BLK_DEV_LOOP=y # CONFIG_BLK_DEV_CRYPTOLOOP is not set @@ -485,6 +473,7 @@ CONFIG_BLK_DEV_IDE_BAST=y # # IEEE 1394 (FireWire) support # +# CONFIG_IEEE1394 is not set # # I2O device support @@ -515,6 +504,7 @@ CONFIG_NETDEVICES=y CONFIG_NET_ETHERNET=y CONFIG_MII=y # CONFIG_NET_VENDOR_3COM is not set +# CONFIG_LANCE is not set # CONFIG_NET_VENDOR_SMC is not set # CONFIG_SMC91X is not set CONFIG_DM9000=y @@ -619,11 +609,11 @@ CONFIG_SERIAL_NONSTANDARD=y # CONFIG_ROCKETPORT is not set # CONFIG_CYCLADES is not set # CONFIG_DIGIEPCA is not set +# CONFIG_ESPSERIAL is not set # CONFIG_MOXA_INTELLIO is not set # CONFIG_MOXA_SMARTIO is not set # CONFIG_ISI is not set # CONFIG_SYNCLINKMP is not set -# CONFIG_SYNCLINK_GT is not set # CONFIG_N_HDLC is not set # CONFIG_RISCOM8 is not set # CONFIG_SPECIALIX is not set @@ -637,7 +627,6 @@ CONFIG_SERIAL_NONSTANDARD=y CONFIG_SERIAL_8250=y CONFIG_SERIAL_8250_CONSOLE=y CONFIG_SERIAL_8250_NR_UARTS=8 -CONFIG_SERIAL_8250_RUNTIME_UARTS=4 CONFIG_SERIAL_8250_EXTENDED=y CONFIG_SERIAL_8250_MANY_PORTS=y CONFIG_SERIAL_8250_SHARE_IRQ=y @@ -700,7 +689,6 @@ CONFIG_S3C2410_RTC=y # # TPM devices # -# CONFIG_TCG_TPM is not set # CONFIG_TELCLOCK is not set # @@ -744,12 +732,6 @@ CONFIG_SENSORS_EEPROM=m # CONFIG_I2C_DEBUG_BUS is not set # CONFIG_I2C_DEBUG_CHIP is not set -# -# SPI support -# -# CONFIG_SPI is not set -# CONFIG_SPI_MASTER is not set - # # Hardware Monitoring support # @@ -883,7 +865,6 @@ CONFIG_FS_MBCACHE=y # CONFIG_JFS_FS is not set # CONFIG_FS_POSIX_ACL is not set # CONFIG_XFS_FS is not set -# CONFIG_OCFS2_FS is not set # CONFIG_MINIX_FS is not set CONFIG_ROMFS_FS=y CONFIG_INOTIFY=y @@ -915,10 +896,10 @@ CONFIG_FAT_DEFAULT_IOCHARSET="iso8859-1" CONFIG_PROC_FS=y CONFIG_SYSFS=y # CONFIG_TMPFS is not set +# CONFIG_HUGETLBFS is not set # CONFIG_HUGETLB_PAGE is not set CONFIG_RAMFS=y # CONFIG_RELAYFS_FS is not set -# CONFIG_CONFIGFS_FS is not set # # Miscellaneous filesystems @@ -987,7 +968,6 @@ CONFIG_SOLARIS_X86_PARTITION=y # CONFIG_SGI_PARTITION is not set # CONFIG_ULTRIX_PARTITION is not set # CONFIG_SUN_PARTITION is not set -# CONFIG_KARMA_PARTITION is not set # CONFIG_EFI_PARTITION is not set # @@ -1043,13 +1023,12 @@ CONFIG_NLS_DEFAULT="iso8859-1" # Kernel hacking # # CONFIG_PRINTK_TIME is not set -CONFIG_MAGIC_SYSRQ=y CONFIG_DEBUG_KERNEL=y +CONFIG_MAGIC_SYSRQ=y CONFIG_LOG_BUF_SHIFT=16 CONFIG_DETECT_SOFTLOCKUP=y # CONFIG_SCHEDSTATS is not set # CONFIG_DEBUG_SLAB is not set -CONFIG_DEBUG_MUTEXES=y # CONFIG_DEBUG_SPINLOCK is not set # CONFIG_DEBUG_SPINLOCK_SLEEP is not set # CONFIG_DEBUG_KOBJECT is not set @@ -1058,7 +1037,6 @@ CONFIG_DEBUG_INFO=y # CONFIG_DEBUG_FS is not set # CONFIG_DEBUG_VM is not set CONFIG_FRAME_POINTER=y -CONFIG_FORCED_INLINING=y # CONFIG_RCU_TORTURE_TEST is not set CONFIG_DEBUG_USER=y # CONFIG_DEBUG_WAITQ is not set diff --git a/trunk/arch/arm/kernel/calls.S b/trunk/arch/arm/kernel/calls.S index 8c3035d5ffc9..75e6f9a94713 100644 --- a/trunk/arch/arm/kernel/calls.S +++ b/trunk/arch/arm/kernel/calls.S @@ -7,334 +7,337 @@ * it under the terms of the GNU General Public License version 2 as * published by the Free Software Foundation. * - * This file is included thrice in entry-common.S + * This file is included twice in entry-common.S */ -/* 0 */ CALL(sys_restart_syscall) - CALL(sys_exit) - CALL(sys_fork_wrapper) - CALL(sys_read) - CALL(sys_write) -/* 5 */ CALL(sys_open) - CALL(sys_close) - CALL(sys_ni_syscall) /* was sys_waitpid */ - CALL(sys_creat) - CALL(sys_link) -/* 10 */ CALL(sys_unlink) - CALL(sys_execve_wrapper) - CALL(sys_chdir) - CALL(OBSOLETE(sys_time)) /* used by libc4 */ - CALL(sys_mknod) -/* 15 */ CALL(sys_chmod) - CALL(sys_lchown16) - CALL(sys_ni_syscall) /* was sys_break */ - CALL(sys_ni_syscall) /* was sys_stat */ - CALL(sys_lseek) -/* 20 */ CALL(sys_getpid) - CALL(sys_mount) - CALL(OBSOLETE(sys_oldumount)) /* used by libc4 */ - CALL(sys_setuid16) - CALL(sys_getuid16) -/* 25 */ CALL(OBSOLETE(sys_stime)) - CALL(sys_ptrace) - CALL(OBSOLETE(sys_alarm)) /* used by libc4 */ - CALL(sys_ni_syscall) /* was sys_fstat */ - CALL(sys_pause) -/* 30 */ CALL(OBSOLETE(sys_utime)) /* used by libc4 */ - CALL(sys_ni_syscall) /* was sys_stty */ - CALL(sys_ni_syscall) /* was sys_getty */ - CALL(sys_access) - CALL(sys_nice) -/* 35 */ CALL(sys_ni_syscall) /* was sys_ftime */ - CALL(sys_sync) - CALL(sys_kill) - CALL(sys_rename) - CALL(sys_mkdir) -/* 40 */ CALL(sys_rmdir) - CALL(sys_dup) - CALL(sys_pipe) - CALL(sys_times) - CALL(sys_ni_syscall) /* was sys_prof */ -/* 45 */ CALL(sys_brk) - CALL(sys_setgid16) - CALL(sys_getgid16) - CALL(sys_ni_syscall) /* was sys_signal */ - CALL(sys_geteuid16) -/* 50 */ CALL(sys_getegid16) - CALL(sys_acct) - CALL(sys_umount) - CALL(sys_ni_syscall) /* was sys_lock */ - CALL(sys_ioctl) -/* 55 */ CALL(sys_fcntl) - CALL(sys_ni_syscall) /* was sys_mpx */ - CALL(sys_setpgid) - CALL(sys_ni_syscall) /* was sys_ulimit */ - CALL(sys_ni_syscall) /* was sys_olduname */ -/* 60 */ CALL(sys_umask) - CALL(sys_chroot) - CALL(sys_ustat) - CALL(sys_dup2) - CALL(sys_getppid) -/* 65 */ CALL(sys_getpgrp) - CALL(sys_setsid) - CALL(sys_sigaction) - CALL(sys_ni_syscall) /* was sys_sgetmask */ - CALL(sys_ni_syscall) /* was sys_ssetmask */ -/* 70 */ CALL(sys_setreuid16) - CALL(sys_setregid16) - CALL(sys_sigsuspend_wrapper) - CALL(sys_sigpending) - CALL(sys_sethostname) -/* 75 */ CALL(sys_setrlimit) - CALL(OBSOLETE(sys_old_getrlimit)) /* used by libc4 */ - CALL(sys_getrusage) - CALL(sys_gettimeofday) - CALL(sys_settimeofday) -/* 80 */ CALL(sys_getgroups16) - CALL(sys_setgroups16) - CALL(OBSOLETE(old_select)) /* used by libc4 */ - CALL(sys_symlink) - CALL(sys_ni_syscall) /* was sys_lstat */ -/* 85 */ CALL(sys_readlink) - CALL(sys_uselib) - CALL(sys_swapon) - CALL(sys_reboot) - CALL(OBSOLETE(old_readdir)) /* used by libc4 */ -/* 90 */ CALL(OBSOLETE(old_mmap)) /* used by libc4 */ - CALL(sys_munmap) - CALL(sys_truncate) - CALL(sys_ftruncate) - CALL(sys_fchmod) -/* 95 */ CALL(sys_fchown16) - CALL(sys_getpriority) - CALL(sys_setpriority) - CALL(sys_ni_syscall) /* was sys_profil */ - CALL(sys_statfs) -/* 100 */ CALL(sys_fstatfs) - CALL(sys_ni_syscall) - CALL(OBSOLETE(sys_socketcall)) - CALL(sys_syslog) - CALL(sys_setitimer) -/* 105 */ CALL(sys_getitimer) - CALL(sys_newstat) - CALL(sys_newlstat) - CALL(sys_newfstat) - CALL(sys_ni_syscall) /* was sys_uname */ -/* 110 */ CALL(sys_ni_syscall) /* was sys_iopl */ - CALL(sys_vhangup) - CALL(sys_ni_syscall) - CALL(OBSOLETE(sys_syscall)) /* call a syscall */ - CALL(sys_wait4) -/* 115 */ CALL(sys_swapoff) - CALL(sys_sysinfo) - CALL(OBSOLETE(ABI(sys_ipc, sys_oabi_ipc))) - CALL(sys_fsync) - CALL(sys_sigreturn_wrapper) -/* 120 */ CALL(sys_clone_wrapper) - CALL(sys_setdomainname) - CALL(sys_newuname) - CALL(sys_ni_syscall) - CALL(sys_adjtimex) -/* 125 */ CALL(sys_mprotect) - CALL(sys_sigprocmask) - CALL(sys_ni_syscall) /* was sys_create_module */ - CALL(sys_init_module) - CALL(sys_delete_module) -/* 130 */ CALL(sys_ni_syscall) /* was sys_get_kernel_syms */ - CALL(sys_quotactl) - CALL(sys_getpgid) - CALL(sys_fchdir) - CALL(sys_bdflush) -/* 135 */ CALL(sys_sysfs) - CALL(sys_personality) - CALL(sys_ni_syscall) /* CALL(_sys_afs_syscall) */ - CALL(sys_setfsuid16) - CALL(sys_setfsgid16) -/* 140 */ CALL(sys_llseek) - CALL(sys_getdents) - CALL(sys_select) - CALL(sys_flock) - CALL(sys_msync) -/* 145 */ CALL(sys_readv) - CALL(sys_writev) - CALL(sys_getsid) - CALL(sys_fdatasync) - CALL(sys_sysctl) -/* 150 */ CALL(sys_mlock) - CALL(sys_munlock) - CALL(sys_mlockall) - CALL(sys_munlockall) - CALL(sys_sched_setparam) -/* 155 */ CALL(sys_sched_getparam) - CALL(sys_sched_setscheduler) - CALL(sys_sched_getscheduler) - CALL(sys_sched_yield) - CALL(sys_sched_get_priority_max) -/* 160 */ CALL(sys_sched_get_priority_min) - CALL(sys_sched_rr_get_interval) - CALL(sys_nanosleep) - CALL(sys_arm_mremap) - CALL(sys_setresuid16) -/* 165 */ CALL(sys_getresuid16) - CALL(sys_ni_syscall) - CALL(sys_ni_syscall) /* was sys_query_module */ - CALL(sys_poll) - CALL(sys_nfsservctl) -/* 170 */ CALL(sys_setresgid16) - CALL(sys_getresgid16) - CALL(sys_prctl) - CALL(sys_rt_sigreturn_wrapper) - CALL(sys_rt_sigaction) -/* 175 */ CALL(sys_rt_sigprocmask) - CALL(sys_rt_sigpending) - CALL(sys_rt_sigtimedwait) - CALL(sys_rt_sigqueueinfo) - CALL(sys_rt_sigsuspend_wrapper) -/* 180 */ CALL(ABI(sys_pread64, sys_oabi_pread64)) - CALL(ABI(sys_pwrite64, sys_oabi_pwrite64)) - CALL(sys_chown16) - CALL(sys_getcwd) - CALL(sys_capget) -/* 185 */ CALL(sys_capset) - CALL(sys_sigaltstack_wrapper) - CALL(sys_sendfile) - CALL(sys_ni_syscall) - CALL(sys_ni_syscall) -/* 190 */ CALL(sys_vfork_wrapper) - CALL(sys_getrlimit) - CALL(sys_mmap2) - CALL(ABI(sys_truncate64, sys_oabi_truncate64)) - CALL(ABI(sys_ftruncate64, sys_oabi_ftruncate64)) -/* 195 */ CALL(ABI(sys_stat64, sys_oabi_stat64)) - CALL(ABI(sys_lstat64, sys_oabi_lstat64)) - CALL(ABI(sys_fstat64, sys_oabi_fstat64)) - CALL(sys_lchown) - CALL(sys_getuid) -/* 200 */ CALL(sys_getgid) - CALL(sys_geteuid) - CALL(sys_getegid) - CALL(sys_setreuid) - CALL(sys_setregid) -/* 205 */ CALL(sys_getgroups) - CALL(sys_setgroups) - CALL(sys_fchown) - CALL(sys_setresuid) - CALL(sys_getresuid) -/* 210 */ CALL(sys_setresgid) - CALL(sys_getresgid) - CALL(sys_chown) - CALL(sys_setuid) - CALL(sys_setgid) -/* 215 */ CALL(sys_setfsuid) - CALL(sys_setfsgid) - CALL(sys_getdents64) - CALL(sys_pivot_root) - CALL(sys_mincore) -/* 220 */ CALL(sys_madvise) - CALL(ABI(sys_fcntl64, sys_oabi_fcntl64)) - CALL(sys_ni_syscall) /* TUX */ - CALL(sys_ni_syscall) - CALL(sys_gettid) -/* 225 */ CALL(ABI(sys_readahead, sys_oabi_readahead)) - CALL(sys_setxattr) - CALL(sys_lsetxattr) - CALL(sys_fsetxattr) - CALL(sys_getxattr) -/* 230 */ CALL(sys_lgetxattr) - CALL(sys_fgetxattr) - CALL(sys_listxattr) - CALL(sys_llistxattr) - CALL(sys_flistxattr) -/* 235 */ CALL(sys_removexattr) - CALL(sys_lremovexattr) - CALL(sys_fremovexattr) - CALL(sys_tkill) - CALL(sys_sendfile64) -/* 240 */ CALL(sys_futex) - CALL(sys_sched_setaffinity) - CALL(sys_sched_getaffinity) - CALL(sys_io_setup) - CALL(sys_io_destroy) -/* 245 */ CALL(sys_io_getevents) - CALL(sys_io_submit) - CALL(sys_io_cancel) - CALL(sys_exit_group) - CALL(sys_lookup_dcookie) -/* 250 */ CALL(sys_epoll_create) - CALL(ABI(sys_epoll_ctl, sys_oabi_epoll_ctl)) - CALL(ABI(sys_epoll_wait, sys_oabi_epoll_wait)) - CALL(sys_remap_file_pages) - CALL(sys_ni_syscall) /* sys_set_thread_area */ -/* 255 */ CALL(sys_ni_syscall) /* sys_get_thread_area */ - CALL(sys_set_tid_address) - CALL(sys_timer_create) - CALL(sys_timer_settime) - CALL(sys_timer_gettime) -/* 260 */ CALL(sys_timer_getoverrun) - CALL(sys_timer_delete) - CALL(sys_clock_settime) - CALL(sys_clock_gettime) - CALL(sys_clock_getres) -/* 265 */ CALL(sys_clock_nanosleep) - CALL(sys_statfs64_wrapper) - CALL(sys_fstatfs64_wrapper) - CALL(sys_tgkill) - CALL(sys_utimes) -/* 270 */ CALL(sys_arm_fadvise64_64) - CALL(sys_pciconfig_iobase) - CALL(sys_pciconfig_read) - CALL(sys_pciconfig_write) - CALL(sys_mq_open) -/* 275 */ CALL(sys_mq_unlink) - CALL(sys_mq_timedsend) - CALL(sys_mq_timedreceive) - CALL(sys_mq_notify) - CALL(sys_mq_getsetattr) -/* 280 */ CALL(sys_waitid) - CALL(sys_socket) - CALL(ABI(sys_bind, sys_oabi_bind)) - CALL(ABI(sys_connect, sys_oabi_connect)) - CALL(sys_listen) -/* 285 */ CALL(sys_accept) - CALL(sys_getsockname) - CALL(sys_getpeername) - CALL(sys_socketpair) - CALL(sys_send) -/* 290 */ CALL(ABI(sys_sendto, sys_oabi_sendto)) - CALL(sys_recv) - CALL(sys_recvfrom) - CALL(sys_shutdown) - CALL(sys_setsockopt) -/* 295 */ CALL(sys_getsockopt) - CALL(ABI(sys_sendmsg, sys_oabi_sendmsg)) - CALL(sys_recvmsg) - CALL(ABI(sys_semop, sys_oabi_semop)) - CALL(sys_semget) -/* 300 */ CALL(sys_semctl) - CALL(sys_msgsnd) - CALL(sys_msgrcv) - CALL(sys_msgget) - CALL(sys_msgctl) -/* 305 */ CALL(sys_shmat) - CALL(sys_shmdt) - CALL(sys_shmget) - CALL(sys_shmctl) - CALL(sys_add_key) -/* 310 */ CALL(sys_request_key) - CALL(sys_keyctl) - CALL(ABI(sys_semtimedop, sys_oabi_semtimedop)) -/* vserver */ CALL(sys_ni_syscall) - CALL(sys_ioprio_set) -/* 315 */ CALL(sys_ioprio_get) - CALL(sys_inotify_init) - CALL(sys_inotify_add_watch) - CALL(sys_inotify_rm_watch) - CALL(sys_mbind) -/* 320 */ CALL(sys_get_mempolicy) - CALL(sys_set_mempolicy) -#ifndef syscalls_counted -.equ syscalls_padding, ((NR_syscalls + 3) & ~3) - NR_syscalls -#define syscalls_counted +#ifndef NR_syscalls +#define NR_syscalls 328 +#else + +100: +/* 0 */ .long sys_restart_syscall + .long sys_exit + .long sys_fork_wrapper + .long sys_read + .long sys_write +/* 5 */ .long sys_open + .long sys_close + .long sys_ni_syscall /* was sys_waitpid */ + .long sys_creat + .long sys_link +/* 10 */ .long sys_unlink + .long sys_execve_wrapper + .long sys_chdir + .long OBSOLETE(sys_time) /* used by libc4 */ + .long sys_mknod +/* 15 */ .long sys_chmod + .long sys_lchown16 + .long sys_ni_syscall /* was sys_break */ + .long sys_ni_syscall /* was sys_stat */ + .long sys_lseek +/* 20 */ .long sys_getpid + .long sys_mount + .long OBSOLETE(sys_oldumount) /* used by libc4 */ + .long sys_setuid16 + .long sys_getuid16 +/* 25 */ .long OBSOLETE(sys_stime) + .long sys_ptrace + .long OBSOLETE(sys_alarm) /* used by libc4 */ + .long sys_ni_syscall /* was sys_fstat */ + .long sys_pause +/* 30 */ .long OBSOLETE(sys_utime) /* used by libc4 */ + .long sys_ni_syscall /* was sys_stty */ + .long sys_ni_syscall /* was sys_getty */ + .long sys_access + .long sys_nice +/* 35 */ .long sys_ni_syscall /* was sys_ftime */ + .long sys_sync + .long sys_kill + .long sys_rename + .long sys_mkdir +/* 40 */ .long sys_rmdir + .long sys_dup + .long sys_pipe + .long sys_times + .long sys_ni_syscall /* was sys_prof */ +/* 45 */ .long sys_brk + .long sys_setgid16 + .long sys_getgid16 + .long sys_ni_syscall /* was sys_signal */ + .long sys_geteuid16 +/* 50 */ .long sys_getegid16 + .long sys_acct + .long sys_umount + .long sys_ni_syscall /* was sys_lock */ + .long sys_ioctl +/* 55 */ .long sys_fcntl + .long sys_ni_syscall /* was sys_mpx */ + .long sys_setpgid + .long sys_ni_syscall /* was sys_ulimit */ + .long sys_ni_syscall /* was sys_olduname */ +/* 60 */ .long sys_umask + .long sys_chroot + .long sys_ustat + .long sys_dup2 + .long sys_getppid +/* 65 */ .long sys_getpgrp + .long sys_setsid + .long sys_sigaction + .long sys_ni_syscall /* was sys_sgetmask */ + .long sys_ni_syscall /* was sys_ssetmask */ +/* 70 */ .long sys_setreuid16 + .long sys_setregid16 + .long sys_sigsuspend_wrapper + .long sys_sigpending + .long sys_sethostname +/* 75 */ .long sys_setrlimit + .long OBSOLETE(sys_old_getrlimit) /* used by libc4 */ + .long sys_getrusage + .long sys_gettimeofday + .long sys_settimeofday +/* 80 */ .long sys_getgroups16 + .long sys_setgroups16 + .long OBSOLETE(old_select) /* used by libc4 */ + .long sys_symlink + .long sys_ni_syscall /* was sys_lstat */ +/* 85 */ .long sys_readlink + .long sys_uselib + .long sys_swapon + .long sys_reboot + .long OBSOLETE(old_readdir) /* used by libc4 */ +/* 90 */ .long OBSOLETE(old_mmap) /* used by libc4 */ + .long sys_munmap + .long sys_truncate + .long sys_ftruncate + .long sys_fchmod +/* 95 */ .long sys_fchown16 + .long sys_getpriority + .long sys_setpriority + .long sys_ni_syscall /* was sys_profil */ + .long sys_statfs +/* 100 */ .long sys_fstatfs + .long sys_ni_syscall + .long OBSOLETE(sys_socketcall) + .long sys_syslog + .long sys_setitimer +/* 105 */ .long sys_getitimer + .long sys_newstat + .long sys_newlstat + .long sys_newfstat + .long sys_ni_syscall /* was sys_uname */ +/* 110 */ .long sys_ni_syscall /* was sys_iopl */ + .long sys_vhangup + .long sys_ni_syscall + .long OBSOLETE(sys_syscall) /* call a syscall */ + .long sys_wait4 +/* 115 */ .long sys_swapoff + .long sys_sysinfo + .long OBSOLETE(ABI(sys_ipc, sys_oabi_ipc)) + .long sys_fsync + .long sys_sigreturn_wrapper +/* 120 */ .long sys_clone_wrapper + .long sys_setdomainname + .long sys_newuname + .long sys_ni_syscall + .long sys_adjtimex +/* 125 */ .long sys_mprotect + .long sys_sigprocmask + .long sys_ni_syscall /* was sys_create_module */ + .long sys_init_module + .long sys_delete_module +/* 130 */ .long sys_ni_syscall /* was sys_get_kernel_syms */ + .long sys_quotactl + .long sys_getpgid + .long sys_fchdir + .long sys_bdflush +/* 135 */ .long sys_sysfs + .long sys_personality + .long sys_ni_syscall /* .long _sys_afs_syscall */ + .long sys_setfsuid16 + .long sys_setfsgid16 +/* 140 */ .long sys_llseek + .long sys_getdents + .long sys_select + .long sys_flock + .long sys_msync +/* 145 */ .long sys_readv + .long sys_writev + .long sys_getsid + .long sys_fdatasync + .long sys_sysctl +/* 150 */ .long sys_mlock + .long sys_munlock + .long sys_mlockall + .long sys_munlockall + .long sys_sched_setparam +/* 155 */ .long sys_sched_getparam + .long sys_sched_setscheduler + .long sys_sched_getscheduler + .long sys_sched_yield + .long sys_sched_get_priority_max +/* 160 */ .long sys_sched_get_priority_min + .long sys_sched_rr_get_interval + .long sys_nanosleep + .long sys_arm_mremap + .long sys_setresuid16 +/* 165 */ .long sys_getresuid16 + .long sys_ni_syscall + .long sys_ni_syscall /* was sys_query_module */ + .long sys_poll + .long sys_nfsservctl +/* 170 */ .long sys_setresgid16 + .long sys_getresgid16 + .long sys_prctl + .long sys_rt_sigreturn_wrapper + .long sys_rt_sigaction +/* 175 */ .long sys_rt_sigprocmask + .long sys_rt_sigpending + .long sys_rt_sigtimedwait + .long sys_rt_sigqueueinfo + .long sys_rt_sigsuspend_wrapper +/* 180 */ .long ABI(sys_pread64, sys_oabi_pread64) + .long ABI(sys_pwrite64, sys_oabi_pwrite64) + .long sys_chown16 + .long sys_getcwd + .long sys_capget +/* 185 */ .long sys_capset + .long sys_sigaltstack_wrapper + .long sys_sendfile + .long sys_ni_syscall + .long sys_ni_syscall +/* 190 */ .long sys_vfork_wrapper + .long sys_getrlimit + .long sys_mmap2 + .long ABI(sys_truncate64, sys_oabi_truncate64) + .long ABI(sys_ftruncate64, sys_oabi_ftruncate64) +/* 195 */ .long ABI(sys_stat64, sys_oabi_stat64) + .long ABI(sys_lstat64, sys_oabi_lstat64) + .long ABI(sys_fstat64, sys_oabi_fstat64) + .long sys_lchown + .long sys_getuid +/* 200 */ .long sys_getgid + .long sys_geteuid + .long sys_getegid + .long sys_setreuid + .long sys_setregid +/* 205 */ .long sys_getgroups + .long sys_setgroups + .long sys_fchown + .long sys_setresuid + .long sys_getresuid +/* 210 */ .long sys_setresgid + .long sys_getresgid + .long sys_chown + .long sys_setuid + .long sys_setgid +/* 215 */ .long sys_setfsuid + .long sys_setfsgid + .long sys_getdents64 + .long sys_pivot_root + .long sys_mincore +/* 220 */ .long sys_madvise + .long ABI(sys_fcntl64, sys_oabi_fcntl64) + .long sys_ni_syscall /* TUX */ + .long sys_ni_syscall + .long sys_gettid +/* 225 */ .long ABI(sys_readahead, sys_oabi_readahead) + .long sys_setxattr + .long sys_lsetxattr + .long sys_fsetxattr + .long sys_getxattr +/* 230 */ .long sys_lgetxattr + .long sys_fgetxattr + .long sys_listxattr + .long sys_llistxattr + .long sys_flistxattr +/* 235 */ .long sys_removexattr + .long sys_lremovexattr + .long sys_fremovexattr + .long sys_tkill + .long sys_sendfile64 +/* 240 */ .long sys_futex + .long sys_sched_setaffinity + .long sys_sched_getaffinity + .long sys_io_setup + .long sys_io_destroy +/* 245 */ .long sys_io_getevents + .long sys_io_submit + .long sys_io_cancel + .long sys_exit_group + .long sys_lookup_dcookie +/* 250 */ .long sys_epoll_create + .long ABI(sys_epoll_ctl, sys_oabi_epoll_ctl) + .long ABI(sys_epoll_wait, sys_oabi_epoll_wait) + .long sys_remap_file_pages + .long sys_ni_syscall /* sys_set_thread_area */ +/* 255 */ .long sys_ni_syscall /* sys_get_thread_area */ + .long sys_set_tid_address + .long sys_timer_create + .long sys_timer_settime + .long sys_timer_gettime +/* 260 */ .long sys_timer_getoverrun + .long sys_timer_delete + .long sys_clock_settime + .long sys_clock_gettime + .long sys_clock_getres +/* 265 */ .long sys_clock_nanosleep + .long sys_statfs64_wrapper + .long sys_fstatfs64_wrapper + .long sys_tgkill + .long sys_utimes +/* 270 */ .long sys_arm_fadvise64_64 + .long sys_pciconfig_iobase + .long sys_pciconfig_read + .long sys_pciconfig_write + .long sys_mq_open +/* 275 */ .long sys_mq_unlink + .long sys_mq_timedsend + .long sys_mq_timedreceive + .long sys_mq_notify + .long sys_mq_getsetattr +/* 280 */ .long sys_waitid + .long sys_socket + .long sys_bind + .long sys_connect + .long sys_listen +/* 285 */ .long sys_accept + .long sys_getsockname + .long sys_getpeername + .long sys_socketpair + .long sys_send +/* 290 */ .long sys_sendto + .long sys_recv + .long sys_recvfrom + .long sys_shutdown + .long sys_setsockopt +/* 295 */ .long sys_getsockopt + .long sys_sendmsg + .long sys_recvmsg + .long ABI(sys_semop, sys_oabi_semop) + .long sys_semget +/* 300 */ .long sys_semctl + .long sys_msgsnd + .long sys_msgrcv + .long sys_msgget + .long sys_msgctl +/* 305 */ .long sys_shmat + .long sys_shmdt + .long sys_shmget + .long sys_shmctl + .long sys_add_key +/* 310 */ .long sys_request_key + .long sys_keyctl + .long ABI(sys_semtimedop, sys_oabi_semtimedop) +/* vserver */ .long sys_ni_syscall + .long sys_ioprio_set +/* 315 */ .long sys_ioprio_get + .long sys_inotify_init + .long sys_inotify_add_watch + .long sys_inotify_rm_watch + .long sys_mbind +/* 320 */ .long sys_get_mempolicy + .long sys_set_mempolicy + + .rept NR_syscalls - (. - 100b) / 4 + .long sys_ni_syscall + .endr #endif -.rept syscalls_padding - CALL(sys_ni_syscall) -.endr diff --git a/trunk/arch/arm/kernel/entry-armv.S b/trunk/arch/arm/kernel/entry-armv.S index 964cd717506b..874e6bb79405 100644 --- a/trunk/arch/arm/kernel/entry-armv.S +++ b/trunk/arch/arm/kernel/entry-armv.S @@ -333,13 +333,9 @@ __pabt_svc: @ from the exception stack #if __LINUX_ARM_ARCH__ < 6 && !defined(CONFIG_NEEDS_SYSCALL_FOR_CMPXCHG) -#ifndef CONFIG_MMU -#warning "NPTL on non MMU needs fixing" -#else @ make sure our user space atomic helper is aborted cmp r2, #TASK_SIZE bichs r3, r3, #PSR_Z_BIT -#endif #endif @ @@ -709,12 +705,7 @@ __kuser_memory_barrier: @ 0xffff0fa0 * The C flag is also set if *ptr was changed to allow for assembly * optimization in the calling code. * - * Notes: - * - * - This routine already includes memory barriers as needed. - * - * - A failure might be transient, i.e. it is possible, although unlikely, - * that "failure" be returned even if *ptr == oldval. + * Note: this routine already includes memory barriers as needed. * * For example, a user space atomic_add implementation could look like this: * @@ -744,11 +735,8 @@ __kuser_cmpxchg: @ 0xffff0fc0 * The kernel itself must perform the operation. * A special ghost syscall is used for that (see traps.c). */ - stmfd sp!, {r7, lr} - mov r7, #0xff00 @ 0xfff0 into r7 for EABI - orr r7, r7, #0xf0 swi #0x9ffff0 - ldmfd sp!, {r7, pc} + mov pc, lr #elif __LINUX_ARM_ARCH__ < 6 @@ -765,18 +753,12 @@ __kuser_cmpxchg: @ 0xffff0fc0 * exception happening just after the str instruction which would * clear the Z flag although the exchange was done. */ -#ifdef CONFIG_MMU teq ip, ip @ set Z flag ldr ip, [r2] @ load current val add r3, r2, #1 @ prepare store ptr teqeq ip, r0 @ compare with oldval if still allowed streq r1, [r3, #-1]! @ store newval if still allowed subs r0, r2, r3 @ if r2 == r3 the str occured -#else -#warning "NPTL on non MMU needs fixing" - mov r0, #-1 - adds r0, r0, #0 -#endif mov pc, lr #else diff --git a/trunk/arch/arm/kernel/entry-common.S b/trunk/arch/arm/kernel/entry-common.S index dbcb11a31f78..2b92ce85f97f 100644 --- a/trunk/arch/arm/kernel/entry-common.S +++ b/trunk/arch/arm/kernel/entry-common.S @@ -87,11 +87,7 @@ ENTRY(ret_from_fork) b ret_slow_syscall - .equ NR_syscalls,0 -#define CALL(x) .equ NR_syscalls,NR_syscalls+1 #include "calls.S" -#undef CALL -#define CALL(x) .long x /*============================================================================= * SWI handler diff --git a/trunk/arch/arm/kernel/signal.c b/trunk/arch/arm/kernel/signal.c index a0cd0a90a10d..765922bcf9e7 100644 --- a/trunk/arch/arm/kernel/signal.c +++ b/trunk/arch/arm/kernel/signal.c @@ -29,12 +29,6 @@ #define SWI_SYS_SIGRETURN (0xef000000|(__NR_sigreturn)) #define SWI_SYS_RT_SIGRETURN (0xef000000|(__NR_rt_sigreturn)) -/* - * With EABI, the syscall number has to be loaded into r7. - */ -#define MOV_R7_NR_SIGRETURN (0xe3a07000 | (__NR_sigreturn - __NR_SYSCALL_BASE)) -#define MOV_R7_NR_RT_SIGRETURN (0xe3a07000 | (__NR_rt_sigreturn - __NR_SYSCALL_BASE)) - /* * For Thumb syscalls, we pass the syscall number via r7. We therefore * need two 16-bit instructions. @@ -42,9 +36,9 @@ #define SWI_THUMB_SIGRETURN (0xdf00 << 16 | 0x2700 | (__NR_sigreturn - __NR_SYSCALL_BASE)) #define SWI_THUMB_RT_SIGRETURN (0xdf00 << 16 | 0x2700 | (__NR_rt_sigreturn - __NR_SYSCALL_BASE)) -const unsigned long sigreturn_codes[7] = { - MOV_R7_NR_SIGRETURN, SWI_SYS_SIGRETURN, SWI_THUMB_SIGRETURN, - MOV_R7_NR_RT_SIGRETURN, SWI_SYS_RT_SIGRETURN, SWI_THUMB_RT_SIGRETURN, +const unsigned long sigreturn_codes[4] = { + SWI_SYS_SIGRETURN, SWI_THUMB_SIGRETURN, + SWI_SYS_RT_SIGRETURN, SWI_THUMB_RT_SIGRETURN }; static int do_signal(sigset_t *oldset, struct pt_regs * regs, int syscall); @@ -195,7 +189,7 @@ struct aux_sigframe { struct sigframe { struct sigcontext sc; unsigned long extramask[_NSIG_WORDS-1]; - unsigned long retcode[2]; + unsigned long retcode; struct aux_sigframe aux __attribute__((aligned(8))); }; @@ -204,7 +198,7 @@ struct rt_sigframe { void __user *puc; struct siginfo info; struct ucontext uc; - unsigned long retcode[2]; + unsigned long retcode; struct aux_sigframe aux __attribute__((aligned(8))); }; @@ -442,13 +436,12 @@ setup_return(struct pt_regs *regs, struct k_sigaction *ka, if (ka->sa.sa_flags & SA_RESTORER) { retcode = (unsigned long)ka->sa.sa_restorer; } else { - unsigned int idx = thumb << 1; + unsigned int idx = thumb; if (ka->sa.sa_flags & SA_SIGINFO) - idx += 3; + idx += 2; - if (__put_user(sigreturn_codes[idx], rc) || - __put_user(sigreturn_codes[idx+1], rc+1)) + if (__put_user(sigreturn_codes[idx], rc)) return 1; if (cpsr & MODE32_BIT) { @@ -463,7 +456,7 @@ setup_return(struct pt_regs *regs, struct k_sigaction *ka, * the return code written onto the stack. */ flush_icache_range((unsigned long)rc, - (unsigned long)(rc + 2)); + (unsigned long)(rc + 1)); retcode = ((unsigned long)rc) + thumb; } @@ -495,7 +488,7 @@ setup_frame(int usig, struct k_sigaction *ka, sigset_t *set, struct pt_regs *reg } if (err == 0) - err = setup_return(regs, ka, frame->retcode, frame, usig); + err = setup_return(regs, ka, &frame->retcode, frame, usig); return err; } @@ -529,7 +522,7 @@ setup_rt_frame(int usig, struct k_sigaction *ka, siginfo_t *info, err |= __copy_to_user(&frame->uc.uc_sigmask, set, sizeof(*set)); if (err == 0) - err = setup_return(regs, ka, frame->retcode, frame, usig); + err = setup_return(regs, ka, &frame->retcode, frame, usig); if (err == 0) { /* diff --git a/trunk/arch/arm/kernel/signal.h b/trunk/arch/arm/kernel/signal.h index 9991049c522d..91d26faca62b 100644 --- a/trunk/arch/arm/kernel/signal.h +++ b/trunk/arch/arm/kernel/signal.h @@ -9,4 +9,4 @@ */ #define KERN_SIGRETURN_CODE 0xffff0500 -extern const unsigned long sigreturn_codes[7]; +extern const unsigned long sigreturn_codes[4]; diff --git a/trunk/arch/arm/kernel/sys_oabi-compat.c b/trunk/arch/arm/kernel/sys_oabi-compat.c index 9d4b76409c64..eafa8e5284af 100644 --- a/trunk/arch/arm/kernel/sys_oabi-compat.c +++ b/trunk/arch/arm/kernel/sys_oabi-compat.c @@ -59,16 +59,6 @@ * struct sembuf loses its padding with EABI. Since arrays of them are * used they have to be copyed to remove the padding. Compatibility wrappers * provided below. - * - * sys_bind: - * sys_connect: - * sys_sendmsg: - * sys_sendto: - * - * struct sockaddr_un loses its padding with EABI. Since the size of the - * structure is used as a validation test in unix_mkname(), we need to - * change the length argument to 110 whenever it is 112. Compatibility - * wrappers provided below. */ #include @@ -77,7 +67,6 @@ #include #include #include -#include #include #include @@ -348,63 +337,3 @@ asmlinkage int sys_oabi_ipc(uint call, int first, int second, int third, return sys_ipc(call, first, second, third, ptr, fifth); } } - -asmlinkage long sys_oabi_bind(int fd, struct sockaddr __user *addr, int addrlen) -{ - sa_family_t sa_family; - if (addrlen == 112 && - get_user(sa_family, &addr->sa_family) == 0 && - sa_family == AF_UNIX) - addrlen = 110; - return sys_bind(fd, addr, addrlen); -} - -asmlinkage long sys_oabi_connect(int fd, struct sockaddr __user *addr, int addrlen) -{ - sa_family_t sa_family; - if (addrlen == 112 && - get_user(sa_family, &addr->sa_family) == 0 && - sa_family == AF_UNIX) - addrlen = 110; - return sys_connect(fd, addr, addrlen); -} - -asmlinkage long sys_oabi_sendto(int fd, void __user *buff, - size_t len, unsigned flags, - struct sockaddr __user *addr, - int addrlen) -{ - sa_family_t sa_family; - if (addrlen == 112 && - get_user(sa_family, &addr->sa_family) == 0 && - sa_family == AF_UNIX) - addrlen = 110; - return sys_sendto(fd, buff, len, flags, addr, addrlen); -} - -asmlinkage long sys_oabi_sendmsg(int fd, struct msghdr __user *msg, unsigned flags) -{ - struct sockaddr __user *addr; - int msg_namelen; - sa_family_t sa_family; - if (msg && - get_user(msg_namelen, &msg->msg_namelen) == 0 && - msg_namelen == 112 && - get_user(addr, &msg->msg_name) == 0 && - get_user(sa_family, &addr->sa_family) == 0 && - sa_family == AF_UNIX) - { - /* - * HACK ALERT: there is a limit to how much backward bending - * we should do for what is actually a transitional - * compatibility layer. This already has known flaws with - * a few ioctls that we don't intend to fix. Therefore - * consider this blatent hack as another one... and take care - * to run for cover. In most cases it will "just work fine". - * If it doesn't, well, tough. - */ - put_user(110, &msg->msg_namelen); - } - return sys_sendmsg(fd, msg, flags); -} - diff --git a/trunk/arch/arm/mach-clps711x/Kconfig b/trunk/arch/arm/mach-clps711x/Kconfig index 0e2b641268ad..0793dcf54f2e 100644 --- a/trunk/arch/arm/mach-clps711x/Kconfig +++ b/trunk/arch/arm/mach-clps711x/Kconfig @@ -24,8 +24,6 @@ config ARCH_CEIVA config ARCH_CLEP7312 bool "CLEP7312" - help - Boards based on the Cirrus Logic 7212/7312 chips. config ARCH_EDB7211 bool "EDB7211" diff --git a/trunk/arch/arm/mach-imx/mx1ads.c b/trunk/arch/arm/mach-imx/mx1ads.c index 8ab1b040288c..dc31e3fd6c57 100644 --- a/trunk/arch/arm/mach-imx/mx1ads.c +++ b/trunk/arch/arm/mach-imx/mx1ads.c @@ -27,6 +27,7 @@ #include #include #include "generic.h" +#include static struct resource cs89x0_resources[] = { [0] = { diff --git a/trunk/arch/arm/mach-integrator/integrator_cp.c b/trunk/arch/arm/mach-integrator/integrator_cp.c index a0724f2b24ce..31820170f306 100644 --- a/trunk/arch/arm/mach-integrator/integrator_cp.c +++ b/trunk/arch/arm/mach-integrator/integrator_cp.c @@ -469,9 +469,7 @@ static void cp_clcd_enable(struct clcd_fb *fb) if (fb->fb.var.bits_per_pixel <= 8) val = CM_CTRL_LCDMUXSEL_VGA_8421BPP; else if (fb->fb.var.bits_per_pixel <= 16) - val = CM_CTRL_LCDMUXSEL_VGA_16BPP - | CM_CTRL_LCDEN0 | CM_CTRL_LCDEN1 - | CM_CTRL_STATIC1 | CM_CTRL_STATIC2; + val = CM_CTRL_LCDMUXSEL_VGA_16BPP; else val = 0; /* no idea for this, don't trust the docs */ diff --git a/trunk/arch/arm/mach-ixp2000/enp2611.c b/trunk/arch/arm/mach-ixp2000/enp2611.c index 52fac89e95b5..9e5a13bb39d0 100644 --- a/trunk/arch/arm/mach-ixp2000/enp2611.c +++ b/trunk/arch/arm/mach-ixp2000/enp2611.c @@ -106,7 +106,6 @@ static void __init enp2611_pci_preinit(void) { ixp2000_reg_write(IXP2000_PCI_ADDR_EXT, 0x00100000); ixp2000_pci_preinit(); - pcibios_setup("firmware"); } static inline int enp2611_pci_valid_device(struct pci_bus *bus, diff --git a/trunk/arch/arm/mach-ixp2000/ixdp2400.c b/trunk/arch/arm/mach-ixp2000/ixdp2400.c index 09101271298e..7c782403042a 100644 --- a/trunk/arch/arm/mach-ixp2000/ixdp2400.c +++ b/trunk/arch/arm/mach-ixp2000/ixdp2400.c @@ -68,7 +68,6 @@ void __init ixdp2400_pci_preinit(void) { ixp2000_reg_write(IXP2000_PCI_ADDR_EXT, 0x00100000); ixp2000_pci_preinit(); - pcibios_setup("firmware"); } int ixdp2400_pci_setup(int nr, struct pci_sys_data *sys) diff --git a/trunk/arch/arm/mach-ixp2000/ixdp2x01.c b/trunk/arch/arm/mach-ixp2000/ixdp2x01.c index 150519fb38ec..10f06606d460 100644 --- a/trunk/arch/arm/mach-ixp2000/ixdp2x01.c +++ b/trunk/arch/arm/mach-ixp2000/ixdp2x01.c @@ -212,7 +212,6 @@ void __init ixdp2x01_pci_preinit(void) { ixp2000_reg_write(IXP2000_PCI_ADDR_EXT, 0x00000000); ixp2000_pci_preinit(); - pcibios_setup("firmware"); } #define DEVPIN(dev, pin) ((pin) | ((dev) << 3)) @@ -300,9 +299,7 @@ struct hw_pci ixdp2x01_pci __initdata = { int __init ixdp2x01_pci_init(void) { - if (machine_is_ixdp2401() || machine_is_ixdp2801()) - pci_common_init(&ixdp2x01_pci); - + pci_common_init(&ixdp2x01_pci); return 0; } diff --git a/trunk/arch/arm/mach-ixp4xx/common.c b/trunk/arch/arm/mach-ixp4xx/common.c index 4bdc9d4526cd..6b393691d0e8 100644 --- a/trunk/arch/arm/mach-ixp4xx/common.c +++ b/trunk/arch/arm/mach-ixp4xx/common.c @@ -333,7 +333,6 @@ static struct platform_device *ixp46x_devices[] __initdata = { }; unsigned long ixp4xx_exp_bus_size; -EXPORT_SYMBOL(ixp4xx_exp_bus_size); void __init ixp4xx_sys_init(void) { @@ -353,7 +352,7 @@ void __init ixp4xx_sys_init(void) } } - printk("IXP4xx: Using %luMiB expansion bus window size\n", + printk("IXP4xx: Using %uMiB expansion bus window size\n", ixp4xx_exp_bus_size >> 20); } diff --git a/trunk/arch/arm/mach-omap1/board-generic.c b/trunk/arch/arm/mach-omap1/board-generic.c index a177e78b2b87..bdc20b51b076 100644 --- a/trunk/arch/arm/mach-omap1/board-generic.c +++ b/trunk/arch/arm/mach-omap1/board-generic.c @@ -30,7 +30,6 @@ static void __init omap_generic_init_irq(void) { - omap1_init_common_hw(); omap_init_irq(); } @@ -105,7 +104,7 @@ static void __init omap_generic_init(void) static void __init omap_generic_map_io(void) { - omap1_map_common_io(); + omap_map_common_io(); } MACHINE_START(OMAP_GENERIC, "Generic OMAP1510/1610/1710") diff --git a/trunk/arch/arm/mach-omap1/board-h2.c b/trunk/arch/arm/mach-omap1/board-h2.c index 89f0cc74a519..9533c36a92df 100644 --- a/trunk/arch/arm/mach-omap1/board-h2.c +++ b/trunk/arch/arm/mach-omap1/board-h2.c @@ -128,7 +128,6 @@ static void __init h2_init_smc91x(void) static void __init h2_init_irq(void) { - omap1_init_common_hw(); omap_init_irq(); omap_gpio_init(); h2_init_smc91x(); @@ -195,7 +194,7 @@ static void __init h2_init(void) static void __init h2_map_io(void) { - omap1_map_common_io(); + omap_map_common_io(); } MACHINE_START(OMAP_H2, "TI-H2") diff --git a/trunk/arch/arm/mach-omap1/board-h3.c b/trunk/arch/arm/mach-omap1/board-h3.c index d9f386265996..d665efc1c344 100644 --- a/trunk/arch/arm/mach-omap1/board-h3.c +++ b/trunk/arch/arm/mach-omap1/board-h3.c @@ -203,7 +203,6 @@ static void __init h3_init_smc91x(void) void h3_init_irq(void) { - omap1_init_common_hw(); omap_init_irq(); omap_gpio_init(); h3_init_smc91x(); @@ -211,7 +210,7 @@ void h3_init_irq(void) static void __init h3_map_io(void) { - omap1_map_common_io(); + omap_map_common_io(); } MACHINE_START(OMAP_H3, "TI OMAP1710 H3 board") diff --git a/trunk/arch/arm/mach-omap1/board-innovator.c b/trunk/arch/arm/mach-omap1/board-innovator.c index a04e4332915e..652f37c7f906 100644 --- a/trunk/arch/arm/mach-omap1/board-innovator.c +++ b/trunk/arch/arm/mach-omap1/board-innovator.c @@ -181,7 +181,6 @@ static void __init innovator_init_smc91x(void) void innovator_init_irq(void) { - omap1_init_common_hw(); omap_init_irq(); omap_gpio_init(); #ifdef CONFIG_ARCH_OMAP15XX @@ -286,7 +285,7 @@ static void __init innovator_init(void) static void __init innovator_map_io(void) { - omap1_map_common_io(); + omap_map_common_io(); #ifdef CONFIG_ARCH_OMAP15XX if (cpu_is_omap1510()) { diff --git a/trunk/arch/arm/mach-omap1/board-netstar.c b/trunk/arch/arm/mach-omap1/board-netstar.c index 60d5f8a3339c..58f783930d45 100644 --- a/trunk/arch/arm/mach-omap1/board-netstar.c +++ b/trunk/arch/arm/mach-omap1/board-netstar.c @@ -65,7 +65,6 @@ static struct omap_board_config_kernel netstar_config[] = { static void __init netstar_init_irq(void) { - omap1_init_common_hw(); omap_init_irq(); omap_gpio_init(); } @@ -109,7 +108,7 @@ static void __init netstar_init(void) static void __init netstar_map_io(void) { - omap1_map_common_io(); + omap_map_common_io(); } #define MACHINE_PANICED 1 diff --git a/trunk/arch/arm/mach-omap1/board-osk.c b/trunk/arch/arm/mach-omap1/board-osk.c index 543fa136106d..e5d126e8f276 100644 --- a/trunk/arch/arm/mach-omap1/board-osk.c +++ b/trunk/arch/arm/mach-omap1/board-osk.c @@ -169,7 +169,6 @@ static void __init osk_init_cf(void) static void __init osk_init_irq(void) { - omap1_init_common_hw(); omap_init_irq(); omap_gpio_init(); osk_init_smc91x(); @@ -270,7 +269,7 @@ static void __init osk_init(void) static void __init osk_map_io(void) { - omap1_map_common_io(); + omap_map_common_io(); } MACHINE_START(OMAP_OSK, "TI-OSK") diff --git a/trunk/arch/arm/mach-omap1/board-palmte.c b/trunk/arch/arm/mach-omap1/board-palmte.c index e488f7236775..67fada207622 100644 --- a/trunk/arch/arm/mach-omap1/board-palmte.c +++ b/trunk/arch/arm/mach-omap1/board-palmte.c @@ -34,7 +34,6 @@ static void __init omap_generic_init_irq(void) { - omap1_init_common_hw(); omap_init_irq(); } @@ -73,7 +72,7 @@ static void __init omap_generic_init(void) static void __init omap_generic_map_io(void) { - omap1_map_common_io(); + omap_map_common_io(); } MACHINE_START(OMAP_PALMTE, "OMAP310 based Palm Tungsten E") diff --git a/trunk/arch/arm/mach-omap1/board-perseus2.c b/trunk/arch/arm/mach-omap1/board-perseus2.c index 3913a3cc0ce6..88708a0c52a2 100644 --- a/trunk/arch/arm/mach-omap1/board-perseus2.c +++ b/trunk/arch/arm/mach-omap1/board-perseus2.c @@ -144,7 +144,6 @@ static void __init perseus2_init_smc91x(void) void omap_perseus2_init_irq(void) { - omap1_init_common_hw(); omap_init_irq(); omap_gpio_init(); perseus2_init_smc91x(); @@ -161,7 +160,7 @@ static struct map_desc omap_perseus2_io_desc[] __initdata = { static void __init omap_perseus2_map_io(void) { - omap1_map_common_io(); + omap_map_common_io(); iotable_init(omap_perseus2_io_desc, ARRAY_SIZE(omap_perseus2_io_desc)); diff --git a/trunk/arch/arm/mach-omap1/board-voiceblue.c b/trunk/arch/arm/mach-omap1/board-voiceblue.c index bfd5fdd1a875..959b4b847c87 100644 --- a/trunk/arch/arm/mach-omap1/board-voiceblue.c +++ b/trunk/arch/arm/mach-omap1/board-voiceblue.c @@ -162,7 +162,6 @@ static struct omap_board_config_kernel voiceblue_config[] = { static void __init voiceblue_init_irq(void) { - omap1_init_common_hw(); omap_init_irq(); omap_gpio_init(); } @@ -207,7 +206,7 @@ static void __init voiceblue_init(void) static void __init voiceblue_map_io(void) { - omap1_map_common_io(); + omap_map_common_io(); } #define MACHINE_PANICED 1 diff --git a/trunk/arch/arm/mach-omap1/clock.c b/trunk/arch/arm/mach-omap1/clock.c index 75110ba10424..9d862f86bba6 100644 --- a/trunk/arch/arm/mach-omap1/clock.c +++ b/trunk/arch/arm/mach-omap1/clock.c @@ -50,10 +50,10 @@ static int omap1_clk_enable_dsp_domain(struct clk *clk) { int retval; - retval = omap1_clk_enable(&api_ck.clk); + retval = omap1_clk_use(&api_ck.clk); if (!retval) { - retval = omap1_clk_enable_generic(clk); - omap1_clk_disable(&api_ck.clk); + retval = omap1_clk_enable(clk); + omap1_clk_unuse(&api_ck.clk); } return retval; @@ -61,9 +61,9 @@ static int omap1_clk_enable_dsp_domain(struct clk *clk) static void omap1_clk_disable_dsp_domain(struct clk *clk) { - if (omap1_clk_enable(&api_ck.clk) == 0) { - omap1_clk_disable_generic(clk); - omap1_clk_disable(&api_ck.clk); + if (omap1_clk_use(&api_ck.clk) == 0) { + omap1_clk_disable(clk); + omap1_clk_unuse(&api_ck.clk); } } @@ -72,7 +72,7 @@ static int omap1_clk_enable_uart_functional(struct clk *clk) int ret; struct uart_clk *uclk; - ret = omap1_clk_enable_generic(clk); + ret = omap1_clk_enable(clk); if (ret == 0) { /* Set smart idle acknowledgement mode */ uclk = (struct uart_clk *)clk; @@ -91,7 +91,7 @@ static void omap1_clk_disable_uart_functional(struct clk *clk) uclk = (struct uart_clk *)clk; omap_writeb((omap_readb(uclk->sysc_addr) & ~0x18), uclk->sysc_addr); - omap1_clk_disable_generic(clk); + omap1_clk_disable(clk); } static void omap1_clk_allow_idle(struct clk *clk) @@ -230,9 +230,9 @@ static void omap1_ckctl_recalc_dsp_domain(struct clk * clk) * Note that DSP_CKCTL virt addr = phys addr, so * we must use __raw_readw() instead of omap_readw(). */ - omap1_clk_enable(&api_ck.clk); + omap1_clk_use(&api_ck.clk); dsor = 1 << (3 & (__raw_readw(DSP_CKCTL) >> clk->rate_offset)); - omap1_clk_disable(&api_ck.clk); + omap1_clk_unuse(&api_ck.clk); if (unlikely(clk->rate == clk->parent->rate / dsor)) return; /* No change, quick exit */ @@ -412,12 +412,12 @@ static void omap1_init_ext_clk(struct clk * clk) clk-> rate = 96000000 / dsor; } -static int omap1_clk_enable(struct clk *clk) +static int omap1_clk_use(struct clk *clk) { int ret = 0; if (clk->usecount++ == 0) { if (likely(clk->parent)) { - ret = omap1_clk_enable(clk->parent); + ret = omap1_clk_use(clk->parent); if (unlikely(ret != 0)) { clk->usecount--; @@ -432,7 +432,7 @@ static int omap1_clk_enable(struct clk *clk) ret = clk->enable(clk); if (unlikely(ret != 0) && clk->parent) { - omap1_clk_disable(clk->parent); + omap1_clk_unuse(clk->parent); clk->usecount--; } } @@ -440,12 +440,12 @@ static int omap1_clk_enable(struct clk *clk) return ret; } -static void omap1_clk_disable(struct clk *clk) +static void omap1_clk_unuse(struct clk *clk) { if (clk->usecount > 0 && !(--clk->usecount)) { clk->disable(clk); if (likely(clk->parent)) { - omap1_clk_disable(clk->parent); + omap1_clk_unuse(clk->parent); if (clk->flags & CLOCK_NO_IDLE_PARENT) if (!cpu_is_omap24xx()) omap1_clk_allow_idle(clk->parent); @@ -453,7 +453,7 @@ static void omap1_clk_disable(struct clk *clk) } } -static int omap1_clk_enable_generic(struct clk *clk) +static int omap1_clk_enable(struct clk *clk) { __u16 regval16; __u32 regval32; @@ -492,7 +492,7 @@ static int omap1_clk_enable_generic(struct clk *clk) return 0; } -static void omap1_clk_disable_generic(struct clk *clk) +static void omap1_clk_disable(struct clk *clk) { __u16 regval16; __u32 regval32; @@ -654,8 +654,8 @@ late_initcall(omap1_late_clk_reset); #endif static struct clk_functions omap1_clk_functions = { - .clk_enable = omap1_clk_enable, - .clk_disable = omap1_clk_disable, + .clk_use = omap1_clk_use, + .clk_unuse = omap1_clk_unuse, .clk_round_rate = omap1_clk_round_rate, .clk_set_rate = omap1_clk_set_rate, }; @@ -780,9 +780,9 @@ int __init omap1_clk_init(void) * Only enable those clocks we will need, let the drivers * enable other clocks as necessary */ - clk_enable(&armper_ck.clk); - clk_enable(&armxor_ck.clk); - clk_enable(&armtim_ck.clk); /* This should be done by timer code */ + clk_use(&armper_ck.clk); + clk_use(&armxor_ck.clk); + clk_use(&armtim_ck.clk); /* This should be done by timer code */ if (cpu_is_omap1510()) clk_enable(&arm_gpio_ck); diff --git a/trunk/arch/arm/mach-omap1/clock.h b/trunk/arch/arm/mach-omap1/clock.h index 4f18d1b94449..f3bdfb50e01a 100644 --- a/trunk/arch/arm/mach-omap1/clock.h +++ b/trunk/arch/arm/mach-omap1/clock.h @@ -13,8 +13,8 @@ #ifndef __ARCH_ARM_MACH_OMAP1_CLOCK_H #define __ARCH_ARM_MACH_OMAP1_CLOCK_H -static int omap1_clk_enable_generic(struct clk * clk); -static void omap1_clk_disable_generic(struct clk * clk); +static int omap1_clk_enable(struct clk * clk); +static void omap1_clk_disable(struct clk * clk); static void omap1_ckctl_recalc(struct clk * clk); static void omap1_watchdog_recalc(struct clk * clk); static void omap1_ckctl_recalc_dsp_domain(struct clk * clk); @@ -30,8 +30,8 @@ static long omap1_round_ext_clk_rate(struct clk * clk, unsigned long rate); static void omap1_init_ext_clk(struct clk * clk); static int omap1_select_table_rate(struct clk * clk, unsigned long rate); static long omap1_round_to_table_rate(struct clk * clk, unsigned long rate); -static int omap1_clk_enable(struct clk *clk); -static void omap1_clk_disable(struct clk *clk); +static int omap1_clk_use(struct clk *clk); +static void omap1_clk_unuse(struct clk *clk); struct mpu_rate { unsigned long rate; @@ -152,8 +152,8 @@ static struct clk ck_ref = { .rate = 12000000, .flags = CLOCK_IN_OMAP1510 | CLOCK_IN_OMAP16XX | ALWAYS_ENABLED, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk ck_dpll1 = { @@ -161,8 +161,8 @@ static struct clk ck_dpll1 = { .parent = &ck_ref, .flags = CLOCK_IN_OMAP1510 | CLOCK_IN_OMAP16XX | RATE_PROPAGATES | ALWAYS_ENABLED, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct arm_idlect1_clk ck_dpll1out = { @@ -173,8 +173,8 @@ static struct arm_idlect1_clk ck_dpll1out = { .enable_reg = (void __iomem *)ARM_IDLECT2, .enable_bit = EN_CKOUT_ARM, .recalc = &followparent_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }, .idlect_shift = 12, }; @@ -186,8 +186,8 @@ static struct clk arm_ck = { RATE_CKCTL | RATE_PROPAGATES | ALWAYS_ENABLED, .rate_offset = CKCTL_ARMDIV_OFFSET, .recalc = &omap1_ckctl_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct arm_idlect1_clk armper_ck = { @@ -200,8 +200,8 @@ static struct arm_idlect1_clk armper_ck = { .enable_bit = EN_PERCK, .rate_offset = CKCTL_PERDIV_OFFSET, .recalc = &omap1_ckctl_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }, .idlect_shift = 2, }; @@ -213,8 +213,8 @@ static struct clk arm_gpio_ck = { .enable_reg = (void __iomem *)ARM_IDLECT2, .enable_bit = EN_GPIOCK, .recalc = &followparent_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct arm_idlect1_clk armxor_ck = { @@ -226,8 +226,8 @@ static struct arm_idlect1_clk armxor_ck = { .enable_reg = (void __iomem *)ARM_IDLECT2, .enable_bit = EN_XORPCK, .recalc = &followparent_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }, .idlect_shift = 1, }; @@ -241,8 +241,8 @@ static struct arm_idlect1_clk armtim_ck = { .enable_reg = (void __iomem *)ARM_IDLECT2, .enable_bit = EN_TIMCK, .recalc = &followparent_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }, .idlect_shift = 9, }; @@ -256,8 +256,8 @@ static struct arm_idlect1_clk armwdt_ck = { .enable_reg = (void __iomem *)ARM_IDLECT2, .enable_bit = EN_WDTCK, .recalc = &omap1_watchdog_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }, .idlect_shift = 0, }; @@ -272,8 +272,8 @@ static struct clk arminth_ck16xx = { * * 1510 version is in TC clocks. */ - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk dsp_ck = { @@ -285,8 +285,8 @@ static struct clk dsp_ck = { .enable_bit = EN_DSPCK, .rate_offset = CKCTL_DSPDIV_OFFSET, .recalc = &omap1_ckctl_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk dspmmu_ck = { @@ -296,8 +296,8 @@ static struct clk dspmmu_ck = { RATE_CKCTL | ALWAYS_ENABLED, .rate_offset = CKCTL_DSPMMUDIV_OFFSET, .recalc = &omap1_ckctl_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk dspper_ck = { @@ -349,8 +349,8 @@ static struct arm_idlect1_clk tc_ck = { CLOCK_IDLE_CONTROL, .rate_offset = CKCTL_TCDIV_OFFSET, .recalc = &omap1_ckctl_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }, .idlect_shift = 6, }; @@ -364,8 +364,8 @@ static struct clk arminth_ck1510 = { * * 16xx version is in MPU clocks. */ - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk tipb_ck = { @@ -374,8 +374,8 @@ static struct clk tipb_ck = { .parent = &tc_ck.clk, .flags = CLOCK_IN_OMAP1510 | ALWAYS_ENABLED, .recalc = &followparent_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk l3_ocpi_ck = { @@ -386,8 +386,8 @@ static struct clk l3_ocpi_ck = { .enable_reg = (void __iomem *)ARM_IDLECT3, .enable_bit = EN_OCPI_CK, .recalc = &followparent_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk tc1_ck = { @@ -397,8 +397,8 @@ static struct clk tc1_ck = { .enable_reg = (void __iomem *)ARM_IDLECT3, .enable_bit = EN_TC1_CK, .recalc = &followparent_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk tc2_ck = { @@ -408,8 +408,8 @@ static struct clk tc2_ck = { .enable_reg = (void __iomem *)ARM_IDLECT3, .enable_bit = EN_TC2_CK, .recalc = &followparent_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk dma_ck = { @@ -419,8 +419,8 @@ static struct clk dma_ck = { .flags = CLOCK_IN_OMAP1510 | CLOCK_IN_OMAP16XX | ALWAYS_ENABLED, .recalc = &followparent_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk dma_lcdfree_ck = { @@ -428,8 +428,8 @@ static struct clk dma_lcdfree_ck = { .parent = &tc_ck.clk, .flags = CLOCK_IN_OMAP16XX | ALWAYS_ENABLED, .recalc = &followparent_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct arm_idlect1_clk api_ck = { @@ -441,8 +441,8 @@ static struct arm_idlect1_clk api_ck = { .enable_reg = (void __iomem *)ARM_IDLECT2, .enable_bit = EN_APICK, .recalc = &followparent_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }, .idlect_shift = 8, }; @@ -455,8 +455,8 @@ static struct arm_idlect1_clk lb_ck = { .enable_reg = (void __iomem *)ARM_IDLECT2, .enable_bit = EN_LBCK, .recalc = &followparent_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }, .idlect_shift = 4, }; @@ -466,8 +466,8 @@ static struct clk rhea1_ck = { .parent = &tc_ck.clk, .flags = CLOCK_IN_OMAP16XX | ALWAYS_ENABLED, .recalc = &followparent_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk rhea2_ck = { @@ -475,8 +475,8 @@ static struct clk rhea2_ck = { .parent = &tc_ck.clk, .flags = CLOCK_IN_OMAP16XX | ALWAYS_ENABLED, .recalc = &followparent_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk lcd_ck_16xx = { @@ -487,8 +487,8 @@ static struct clk lcd_ck_16xx = { .enable_bit = EN_LCDCK, .rate_offset = CKCTL_LCDDIV_OFFSET, .recalc = &omap1_ckctl_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct arm_idlect1_clk lcd_ck_1510 = { @@ -501,8 +501,8 @@ static struct arm_idlect1_clk lcd_ck_1510 = { .enable_bit = EN_LCDCK, .rate_offset = CKCTL_LCDDIV_OFFSET, .recalc = &omap1_ckctl_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }, .idlect_shift = 3, }; @@ -518,8 +518,8 @@ static struct clk uart1_1510 = { .enable_bit = 29, /* Chooses between 12MHz and 48MHz */ .set_rate = &omap1_set_uart_rate, .recalc = &omap1_uart_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct uart_clk uart1_16xx = { @@ -550,8 +550,8 @@ static struct clk uart2_ck = { .enable_bit = 30, /* Chooses between 12MHz and 48MHz */ .set_rate = &omap1_set_uart_rate, .recalc = &omap1_uart_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk uart3_1510 = { @@ -565,8 +565,8 @@ static struct clk uart3_1510 = { .enable_bit = 31, /* Chooses between 12MHz and 48MHz */ .set_rate = &omap1_set_uart_rate, .recalc = &omap1_uart_recalc, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct uart_clk uart3_16xx = { @@ -593,8 +593,8 @@ static struct clk usb_clko = { /* 6 MHz output on W4_USB_CLKO */ RATE_FIXED | ENABLE_REG_32BIT, .enable_reg = (void __iomem *)ULPD_CLOCK_CTRL, .enable_bit = USB_MCLK_EN_BIT, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk usb_hhc_ck1510 = { @@ -605,8 +605,8 @@ static struct clk usb_hhc_ck1510 = { RATE_FIXED | ENABLE_REG_32BIT, .enable_reg = (void __iomem *)MOD_CONF_CTRL_0, .enable_bit = USB_HOST_HHC_UHOST_EN, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk usb_hhc_ck16xx = { @@ -618,8 +618,8 @@ static struct clk usb_hhc_ck16xx = { RATE_FIXED | ENABLE_REG_32BIT, .enable_reg = (void __iomem *)OTG_BASE + 0x08 /* OTG_SYSCON_2 */, .enable_bit = 8 /* UHOST_EN */, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk usb_dc_ck = { @@ -629,8 +629,8 @@ static struct clk usb_dc_ck = { .flags = CLOCK_IN_OMAP16XX | RATE_FIXED, .enable_reg = (void __iomem *)SOFT_REQ_REG, .enable_bit = 4, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk mclk_1510 = { @@ -638,8 +638,8 @@ static struct clk mclk_1510 = { /* Direct from ULPD, no parent. May be enabled by ext hardware. */ .rate = 12000000, .flags = CLOCK_IN_OMAP1510 | RATE_FIXED, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk mclk_16xx = { @@ -651,8 +651,8 @@ static struct clk mclk_16xx = { .set_rate = &omap1_set_ext_clk_rate, .round_rate = &omap1_round_ext_clk_rate, .init = &omap1_init_ext_clk, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk bclk_1510 = { @@ -660,8 +660,8 @@ static struct clk bclk_1510 = { /* Direct from ULPD, no parent. May be enabled by ext hardware. */ .rate = 12000000, .flags = CLOCK_IN_OMAP1510 | RATE_FIXED, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk bclk_16xx = { @@ -673,8 +673,8 @@ static struct clk bclk_16xx = { .set_rate = &omap1_set_ext_clk_rate, .round_rate = &omap1_round_ext_clk_rate, .init = &omap1_init_ext_clk, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk mmc1_ck = { @@ -686,8 +686,8 @@ static struct clk mmc1_ck = { RATE_FIXED | ENABLE_REG_32BIT | CLOCK_NO_IDLE_PARENT, .enable_reg = (void __iomem *)MOD_CONF_CTRL_0, .enable_bit = 23, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk mmc2_ck = { @@ -699,8 +699,8 @@ static struct clk mmc2_ck = { RATE_FIXED | ENABLE_REG_32BIT | CLOCK_NO_IDLE_PARENT, .enable_reg = (void __iomem *)MOD_CONF_CTRL_0, .enable_bit = 20, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk virtual_ck_mpu = { @@ -711,8 +711,8 @@ static struct clk virtual_ck_mpu = { .recalc = &followparent_recalc, .set_rate = &omap1_select_table_rate, .round_rate = &omap1_round_to_table_rate, - .enable = &omap1_clk_enable_generic, - .disable = &omap1_clk_disable_generic, + .enable = &omap1_clk_enable, + .disable = &omap1_clk_disable, }; static struct clk * onchip_clks[] = { diff --git a/trunk/arch/arm/mach-omap1/io.c b/trunk/arch/arm/mach-omap1/io.c index 82d556be79c5..a7a19f75b9e1 100644 --- a/trunk/arch/arm/mach-omap1/io.c +++ b/trunk/arch/arm/mach-omap1/io.c @@ -13,7 +13,6 @@ #include #include -#include #include #include #include @@ -84,24 +83,15 @@ static struct map_desc omap16xx_io_desc[] __initdata = { }; #endif -/* - * Maps common IO regions for omap1. This should only get called from - * board specific init. - */ -void __init omap1_map_common_io(void) -{ - iotable_init(omap_io_desc, ARRAY_SIZE(omap_io_desc)); +static int initialized = 0; - /* Normally devicemaps_init() would flush caches and tlb after - * mdesc->map_io(), but we must also do it here because of the CPU - * revision check below. - */ - local_flush_tlb_all(); - flush_cache_all(); +static void __init _omap_map_io(void) +{ + initialized = 1; - /* We want to check CPU revision early for cpu_is_omapxxxx() macros. - * IO space mapping must be initialized before we can do that. - */ + /* We have to initialize the IO space mapping before we can run + * cpu_is_omapxxx() macros. */ + iotable_init(omap_io_desc, ARRAY_SIZE(omap_io_desc)); omap_check_revision(); #ifdef CONFIG_ARCH_OMAP730 @@ -121,14 +111,7 @@ void __init omap1_map_common_io(void) #endif omap_sram_init(); -} -/* - * Common low-level hardware init for omap1. This should only get called from - * board specific init. - */ -void __init omap1_init_common_hw() -{ /* REVISIT: Refer to OMAP5910 Errata, Advisory SYS_1: "Timeout Abort * on a Posted Write in the TIPB Bridge". */ @@ -138,7 +121,16 @@ void __init omap1_init_common_hw() /* Must init clocks early to assure that timer interrupt works */ omap1_clk_init(); +} - omap1_mux_init(); +/* + * This should only get called from board specific init + */ +void __init omap_map_common_io(void) +{ + if (!initialized) { + _omap_map_io(); + omap1_mux_init(); + } } diff --git a/trunk/arch/arm/mach-omap1/serial.c b/trunk/arch/arm/mach-omap1/serial.c index e924e0c6a4ce..7a68f098a025 100644 --- a/trunk/arch/arm/mach-omap1/serial.c +++ b/trunk/arch/arm/mach-omap1/serial.c @@ -146,7 +146,7 @@ void __init omap_serial_init(void) if (IS_ERR(uart1_ck)) printk("Could not get uart1_ck\n"); else { - clk_enable(uart1_ck); + clk_use(uart1_ck); if (cpu_is_omap1510()) clk_set_rate(uart1_ck, 12000000); } @@ -166,7 +166,7 @@ void __init omap_serial_init(void) if (IS_ERR(uart2_ck)) printk("Could not get uart2_ck\n"); else { - clk_enable(uart2_ck); + clk_use(uart2_ck); if (cpu_is_omap1510()) clk_set_rate(uart2_ck, 12000000); else @@ -188,7 +188,7 @@ void __init omap_serial_init(void) if (IS_ERR(uart3_ck)) printk("Could not get uart3_ck\n"); else { - clk_enable(uart3_ck); + clk_use(uart3_ck); if (cpu_is_omap1510()) clk_set_rate(uart3_ck, 12000000); } diff --git a/trunk/arch/arm/mach-omap2/board-generic.c b/trunk/arch/arm/mach-omap2/board-generic.c index eaecbf422d8c..b937123e5c65 100644 --- a/trunk/arch/arm/mach-omap2/board-generic.c +++ b/trunk/arch/arm/mach-omap2/board-generic.c @@ -33,7 +33,6 @@ static void __init omap_generic_init_irq(void) { - omap2_init_common_hw(); omap_init_irq(); } @@ -65,7 +64,7 @@ static void __init omap_generic_init(void) static void __init omap_generic_map_io(void) { - omap2_map_common_io(); + omap_map_common_io(); } MACHINE_START(OMAP_GENERIC, "Generic OMAP24xx") diff --git a/trunk/arch/arm/mach-omap2/board-h4.c b/trunk/arch/arm/mach-omap2/board-h4.c index a300d634d8a5..c3c35d40378a 100644 --- a/trunk/arch/arm/mach-omap2/board-h4.c +++ b/trunk/arch/arm/mach-omap2/board-h4.c @@ -136,7 +136,6 @@ static inline void __init h4_init_smc91x(void) static void __init omap_h4_init_irq(void) { - omap2_init_common_hw(); omap_init_irq(); omap_gpio_init(); h4_init_smc91x(); @@ -182,7 +181,7 @@ static void __init omap_h4_init(void) static void __init omap_h4_map_io(void) { - omap2_map_common_io(); + omap_map_common_io(); } MACHINE_START(OMAP_H4, "OMAP2420 H4 board") diff --git a/trunk/arch/arm/mach-omap2/clock.c b/trunk/arch/arm/mach-omap2/clock.c index 180f675c9064..5407b9549150 100644 --- a/trunk/arch/arm/mach-omap2/clock.c +++ b/trunk/arch/arm/mach-omap2/clock.c @@ -111,7 +111,7 @@ static void omap2_clk_fixed_enable(struct clk *clk) /* Enables clock without considering parent dependencies or use count * REVISIT: Maybe change this to use clk->enable like on omap1? */ -static int _omap2_clk_enable(struct clk * clk) +static int omap2_clk_enable(struct clk * clk) { u32 regval32; @@ -150,7 +150,7 @@ static void omap2_clk_fixed_disable(struct clk *clk) } /* Disables clock without considering parent dependencies or use count */ -static void _omap2_clk_disable(struct clk *clk) +static void omap2_clk_disable(struct clk *clk) { u32 regval32; @@ -167,23 +167,23 @@ static void _omap2_clk_disable(struct clk *clk) __raw_writel(regval32, clk->enable_reg); } -static int omap2_clk_enable(struct clk *clk) +static int omap2_clk_use(struct clk *clk) { int ret = 0; if (clk->usecount++ == 0) { if (likely((u32)clk->parent)) - ret = omap2_clk_enable(clk->parent); + ret = omap2_clk_use(clk->parent); if (unlikely(ret != 0)) { clk->usecount--; return ret; } - ret = _omap2_clk_enable(clk); + ret = omap2_clk_enable(clk); if (unlikely(ret != 0) && clk->parent) { - omap2_clk_disable(clk->parent); + omap2_clk_unuse(clk->parent); clk->usecount--; } } @@ -191,12 +191,12 @@ static int omap2_clk_enable(struct clk *clk) return ret; } -static void omap2_clk_disable(struct clk *clk) +static void omap2_clk_unuse(struct clk *clk) { if (clk->usecount > 0 && !(--clk->usecount)) { - _omap2_clk_disable(clk); + omap2_clk_disable(clk); if (likely((u32)clk->parent)) - omap2_clk_disable(clk->parent); + omap2_clk_unuse(clk->parent); } } @@ -873,7 +873,7 @@ static int omap2_clk_set_parent(struct clk *clk, struct clk *new_parent) reg = (void __iomem *)src_sel; if (clk->usecount > 0) - _omap2_clk_disable(clk); + omap2_clk_disable(clk); /* Set new source value (previous dividers if any in effect) */ reg_val = __raw_readl(reg) & ~(field_mask << src_off); @@ -884,7 +884,7 @@ static int omap2_clk_set_parent(struct clk *clk, struct clk *new_parent) __raw_writel(0x1, (void __iomem *)&PRCM_CLKCFG_CTRL); if (clk->usecount > 0) - _omap2_clk_enable(clk); + omap2_clk_enable(clk); clk->parent = new_parent; @@ -999,6 +999,8 @@ static int omap2_select_table_rate(struct clk * clk, unsigned long rate) static struct clk_functions omap2_clk_functions = { .clk_enable = omap2_clk_enable, .clk_disable = omap2_clk_disable, + .clk_use = omap2_clk_use, + .clk_unuse = omap2_clk_unuse, .clk_round_rate = omap2_clk_round_rate, .clk_set_rate = omap2_clk_set_rate, .clk_set_parent = omap2_clk_set_parent, @@ -1043,7 +1045,7 @@ static void __init omap2_disable_unused_clocks(void) continue; printk(KERN_INFO "Disabling unused clock \"%s\"\n", ck->name); - _omap2_clk_disable(ck); + omap2_clk_disable(ck); } } late_initcall(omap2_disable_unused_clocks); @@ -1118,10 +1120,10 @@ int __init omap2_clk_init(void) * Only enable those clocks we will need, let the drivers * enable other clocks as necessary */ - clk_enable(&sync_32k_ick); - clk_enable(&omapctrl_ick); + clk_use(&sync_32k_ick); + clk_use(&omapctrl_ick); if (cpu_is_omap2430()) - clk_enable(&sdrc_ick); + clk_use(&sdrc_ick); return 0; } diff --git a/trunk/arch/arm/mach-omap2/clock.h b/trunk/arch/arm/mach-omap2/clock.h index 6cab20b1d3c1..4aeab5591bd3 100644 --- a/trunk/arch/arm/mach-omap2/clock.h +++ b/trunk/arch/arm/mach-omap2/clock.h @@ -24,7 +24,7 @@ static void omap2_propagate_rate(struct clk * clk); static void omap2_mpu_recalc(struct clk * clk); static int omap2_select_table_rate(struct clk * clk, unsigned long rate); static long omap2_round_to_table_rate(struct clk * clk, unsigned long rate); -static void omap2_clk_disable(struct clk *clk); +static void omap2_clk_unuse(struct clk *clk); static void omap2_sys_clk_recalc(struct clk * clk); static u32 omap2_clksel_to_divisor(u32 div_sel, u32 field_val); static u32 omap2_clksel_get_divisor(struct clk *clk); @@ -859,7 +859,7 @@ static struct clk core_l3_ck = { /* Used for ick and fck, interconnect */ static struct clk usb_l4_ick = { /* FS-USB interface clock */ .name = "usb_l4_ick", - .parent = &core_l3_ck, + .parent = &core_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | RATE_CKCTL | CM_CORE_SEL1 | DELAYED_APP | CONFIG_PARTICIPANT, @@ -1045,7 +1045,7 @@ static struct clk gpt1_ick = { .name = "gpt1_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, - .enable_reg = (void __iomem *)&CM_ICLKEN_WKUP, /* Bit0 */ + .enable_reg = (void __iomem *)&CM_ICLKEN_WKUP, /* Bit4 */ .enable_bit = 0, .recalc = &omap2_followparent_recalc, }; @@ -1055,7 +1055,7 @@ static struct clk gpt1_fck = { .parent = &func_32k_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X | CM_WKUP_SEL1, - .enable_reg = (void __iomem *)&CM_FCLKEN_WKUP, /* Bit0 */ + .enable_reg = (void __iomem *)&CM_FCLKEN_WKUP, .enable_bit = 0, .src_offset = 0, .recalc = &omap2_followparent_recalc, @@ -1065,7 +1065,7 @@ static struct clk gpt2_ick = { .name = "gpt2_ick", .parent = &l4_ck, .flags = CLOCK_IN_OMAP242X | CLOCK_IN_OMAP243X, - .enable_reg = (void __iomem *)&CM_ICLKEN1_CORE, /* Bit4 */ + .enable_reg = (void __iomem *)&CM_ICLKEN1_CORE, /* bit4 */ .enable_bit = 0, .recalc = &omap2_followparent_recalc, }; @@ -1839,7 +1839,7 @@ static struct clk usb_fck = { static struct clk usbhs_ick = { .name = "usbhs_ick", - .parent = &core_l3_ck, + .parent = &l4_ck, .flags = CLOCK_IN_OMAP243X, .enable_reg = (void __iomem *)&CM_ICLKEN2_CORE, .enable_bit = 6, diff --git a/trunk/arch/arm/mach-omap2/serial.c b/trunk/arch/arm/mach-omap2/serial.c index 24dd374224af..e1bd46a96e11 100644 --- a/trunk/arch/arm/mach-omap2/serial.c +++ b/trunk/arch/arm/mach-omap2/serial.c @@ -119,14 +119,14 @@ void __init omap_serial_init() if (IS_ERR(uart1_ick)) printk("Could not get uart1_ick\n"); else { - clk_enable(uart1_ick); + clk_use(uart1_ick); } uart1_fck = clk_get(NULL, "uart1_fck"); if (IS_ERR(uart1_fck)) printk("Could not get uart1_fck\n"); else { - clk_enable(uart1_fck); + clk_use(uart1_fck); } break; case 1: @@ -134,14 +134,14 @@ void __init omap_serial_init() if (IS_ERR(uart2_ick)) printk("Could not get uart2_ick\n"); else { - clk_enable(uart2_ick); + clk_use(uart2_ick); } uart2_fck = clk_get(NULL, "uart2_fck"); if (IS_ERR(uart2_fck)) printk("Could not get uart2_fck\n"); else { - clk_enable(uart2_fck); + clk_use(uart2_fck); } break; case 2: @@ -149,14 +149,14 @@ void __init omap_serial_init() if (IS_ERR(uart3_ick)) printk("Could not get uart3_ick\n"); else { - clk_enable(uart3_ick); + clk_use(uart3_ick); } uart3_fck = clk_get(NULL, "uart3_fck"); if (IS_ERR(uart3_fck)) printk("Could not get uart3_fck\n"); else { - clk_enable(uart3_fck); + clk_use(uart3_fck); } break; } diff --git a/trunk/arch/arm/mach-omap2/timer-gp.c b/trunk/arch/arm/mach-omap2/timer-gp.c index 1d2f5ac2f69b..23d36b1c40fe 100644 --- a/trunk/arch/arm/mach-omap2/timer-gp.c +++ b/trunk/arch/arm/mach-omap2/timer-gp.c @@ -104,7 +104,7 @@ static void __init omap2_gp_timer_init(void) if (IS_ERR(sys_ck)) printk(KERN_ERR "Could not get sys_ck\n"); else { - clk_enable(sys_ck); + clk_use(sys_ck); tick_period = clk_get_rate(sys_ck) / 100; clk_put(sys_ck); } diff --git a/trunk/arch/arm/mach-pxa/pxa27x.c b/trunk/arch/arm/mach-pxa/pxa27x.c index 3baa70819f24..b41b1efaa2cf 100644 --- a/trunk/arch/arm/mach-pxa/pxa27x.c +++ b/trunk/arch/arm/mach-pxa/pxa27x.c @@ -44,7 +44,7 @@ unsigned int get_clk_frequency_khz( int info) /* Read clkcfg register: it has turbo, b, half-turbo (and f) */ asm( "mrc\tp14, 0, %0, c6, c0, 0" : "=r" (clkcfg) ); - t = clkcfg & (1 << 0); + t = clkcfg & (1 << 1); ht = clkcfg & (1 << 2); b = clkcfg & (1 << 3); diff --git a/trunk/arch/arm/mach-realview/core.c b/trunk/arch/arm/mach-realview/core.c index 4303d988c4bf..4a222f59f2cf 100644 --- a/trunk/arch/arm/mach-realview/core.c +++ b/trunk/arch/arm/mach-realview/core.c @@ -182,7 +182,7 @@ static const struct icst307_params realview_oscvco_params = { static void realview_oscvco_set(struct clk *clk, struct icst307_vco vco) { void __iomem *sys_lock = __io_address(REALVIEW_SYS_BASE) + REALVIEW_SYS_LOCK_OFFSET; - void __iomem *sys_osc = __io_address(REALVIEW_SYS_BASE) + REALVIEW_SYS_OSC4_OFFSET; + void __iomem *sys_osc = __io_address(REALVIEW_SYS_BASE) + REALVIEW_SYS_OSC1_OFFSET; u32 val; val = readl(sys_osc) & ~0x7ffff; diff --git a/trunk/arch/arm/mach-s3c2410/Makefile b/trunk/arch/arm/mach-s3c2410/Makefile index 1217bf00309c..b4f1e051c768 100644 --- a/trunk/arch/arm/mach-s3c2410/Makefile +++ b/trunk/arch/arm/mach-s3c2410/Makefile @@ -10,13 +10,9 @@ obj-m := obj-n := obj- := -# S3C2400 support files -obj-$(CONFIG_CPU_S3C2400) += s3c2400-gpio.o - # S3C2410 support files obj-$(CONFIG_CPU_S3C2410) += s3c2410.o -obj-$(CONFIG_CPU_S3C2410) += s3c2410-gpio.o obj-$(CONFIG_S3C2410_DMA) += dma.o # Power Management support @@ -29,7 +25,6 @@ obj-$(CONFIG_PM_SIMTEC) += pm-simtec.o obj-$(CONFIG_CPU_S3C2440) += s3c2440.o s3c2440-dsc.o obj-$(CONFIG_CPU_S3C2440) += s3c2440-irq.o obj-$(CONFIG_CPU_S3C2440) += s3c2440-clock.o -obj-$(CONFIG_CPU_S3C2440) += s3c2410-gpio.o # bast extras diff --git a/trunk/arch/arm/mach-s3c2410/clock.c b/trunk/arch/arm/mach-s3c2410/clock.c index 08489efdaf06..af2f3d52b61b 100644 --- a/trunk/arch/arm/mach-s3c2410/clock.c +++ b/trunk/arch/arm/mach-s3c2410/clock.c @@ -40,6 +40,7 @@ #include #include +#include #include #include @@ -58,18 +59,22 @@ static DEFINE_MUTEX(clocks_mutex); void inline s3c24xx_clk_enable(unsigned int clocks, unsigned int enable) { unsigned long clkcon; + unsigned long flags; + + local_irq_save(flags); clkcon = __raw_readl(S3C2410_CLKCON); + clkcon &= ~clocks; if (enable) clkcon |= clocks; - else - clkcon &= ~clocks; /* ensure none of the special function bits set */ clkcon &= ~(S3C2410_CLKCON_IDLE|S3C2410_CLKCON_POWER); __raw_writel(clkcon, S3C2410_CLKCON); + + local_irq_restore(flags); } /* enable and disable calls for use with the clk struct */ @@ -133,32 +138,16 @@ void clk_put(struct clk *clk) int clk_enable(struct clk *clk) { - if (IS_ERR(clk) || clk == NULL) + if (IS_ERR(clk)) return -EINVAL; - clk_enable(clk->parent); - - mutex_lock(&clocks_mutex); - - if ((clk->usage++) == 0) - (clk->enable)(clk, 1); - - mutex_unlock(&clocks_mutex); - return 0; + return (clk->enable)(clk, 1); } void clk_disable(struct clk *clk) { - if (IS_ERR(clk) || clk == NULL) - return; - - mutex_lock(&clocks_mutex); - - if ((--clk->usage) == 0) + if (!IS_ERR(clk)) (clk->enable)(clk, 0); - - mutex_unlock(&clocks_mutex); - clk_disable(clk->parent); } @@ -372,14 +361,6 @@ int s3c24xx_register_clock(struct clk *clk) if (clk->enable == NULL) clk->enable = clk_null_enable; - /* if this is a standard clock, set the usage state */ - - if (clk->ctrlbit) { - unsigned long clkcon = __raw_readl(S3C2410_CLKCON); - - clk->usage = (clkcon & clk->ctrlbit) ? 1 : 0; - } - /* add to the list of available clocks */ mutex_lock(&clocks_mutex); @@ -421,8 +402,6 @@ int __init s3c24xx_setup_clocks(unsigned long xtal, * the LCD clock if it is not needed. */ - mutex_lock(&clocks_mutex); - s3c24xx_clk_enable(S3C2410_CLKCON_NAND, 0); s3c24xx_clk_enable(S3C2410_CLKCON_USBH, 0); s3c24xx_clk_enable(S3C2410_CLKCON_USBD, 0); @@ -430,8 +409,6 @@ int __init s3c24xx_setup_clocks(unsigned long xtal, s3c24xx_clk_enable(S3C2410_CLKCON_IIC, 0); s3c24xx_clk_enable(S3C2410_CLKCON_SPI, 0); - mutex_unlock(&clocks_mutex); - /* assume uart clocks are correctly setup */ /* register our clocks */ diff --git a/trunk/arch/arm/mach-s3c2410/clock.h b/trunk/arch/arm/mach-s3c2410/clock.h index eb5c95d1e7f2..177d5c8decf7 100644 --- a/trunk/arch/arm/mach-s3c2410/clock.h +++ b/trunk/arch/arm/mach-s3c2410/clock.h @@ -16,7 +16,6 @@ struct clk { struct clk *parent; const char *name; int id; - int usage; unsigned long rate; unsigned long ctrlbit; int (*enable)(struct clk *, int enable); diff --git a/trunk/arch/arm/mach-s3c2410/cpu.c b/trunk/arch/arm/mach-s3c2410/cpu.c index 00a379334b60..687fe371369d 100644 --- a/trunk/arch/arm/mach-s3c2410/cpu.c +++ b/trunk/arch/arm/mach-s3c2410/cpu.c @@ -40,7 +40,6 @@ #include "cpu.h" #include "clock.h" -#include "s3c2400.h" #include "s3c2410.h" #include "s3c2440.h" @@ -56,7 +55,6 @@ struct cpu_table { /* table of supported CPUs */ -static const char name_s3c2400[] = "S3C2400"; static const char name_s3c2410[] = "S3C2410"; static const char name_s3c2440[] = "S3C2440"; static const char name_s3c2410a[] = "S3C2410A"; @@ -98,16 +96,7 @@ static struct cpu_table cpu_ids[] __initdata = { .init_uarts = s3c2440_init_uarts, .init = s3c2440_init, .name = name_s3c2440a - }, - { - .idcode = 0x0, /* S3C2400 doesn't have an idcode */ - .idmask = 0xffffffff, - .map_io = s3c2400_map_io, - .init_clocks = s3c2400_init_clocks, - .init_uarts = s3c2400_init_uarts, - .init = s3c2400_init, - .name = name_s3c2400 - }, + } }; /* minimal IO mapping */ @@ -159,15 +148,12 @@ static struct cpu_table *cpu; void __init s3c24xx_init_io(struct map_desc *mach_desc, int size) { - unsigned long idcode = 0x0; + unsigned long idcode; /* initialise the io descriptors we need for initialisation */ iotable_init(s3c_iodesc, ARRAY_SIZE(s3c_iodesc)); -#ifndef CONFIG_CPU_S3C2400 idcode = __raw_readl(S3C2410_GSTATUS1); -#endif - cpu = s3c_lookup_cpu(idcode); if (cpu == NULL) { diff --git a/trunk/arch/arm/mach-s3c2410/cpu.h b/trunk/arch/arm/mach-s3c2410/cpu.h index fc1067783f6d..9cbe5eef492b 100644 --- a/trunk/arch/arm/mach-s3c2410/cpu.h +++ b/trunk/arch/arm/mach-s3c2410/cpu.h @@ -17,12 +17,11 @@ * 14-Jan-2005 BJD Added s3c24xx_init_clocks() call * 10-Mar-2005 LCVR Changed S3C2410_{VA,SZ} to S3C24XX_{VA,SZ} & IODESC_ENT * 14-Mar-2005 BJD Updated for __iomem - * 15-Jan-2006 LCVR Updated S3C2410_PA_##x to new S3C24XX_PA_##x macro */ /* todo - fix when rmk changes iodescs to use `void __iomem *` */ -#define IODESC_ENT(x) { (unsigned long)S3C24XX_VA_##x, __phys_to_pfn(S3C24XX_PA_##x), S3C24XX_SZ_##x, MT_DEVICE } +#define IODESC_ENT(x) { (unsigned long)S3C24XX_VA_##x, __phys_to_pfn(S3C2410_PA_##x), S3C24XX_SZ_##x, MT_DEVICE } #ifndef MHZ #define MHZ (1000*1000) diff --git a/trunk/arch/arm/mach-s3c2410/devs.c b/trunk/arch/arm/mach-s3c2410/devs.c index 0a47d38789a5..f58406e6ef5a 100644 --- a/trunk/arch/arm/mach-s3c2410/devs.c +++ b/trunk/arch/arm/mach-s3c2410/devs.c @@ -10,7 +10,6 @@ * published by the Free Software Foundation. * * Modifications: - * 15-Jan-2006 LCVR Using S3C24XX_PA_##x macro for common S3C24XX devices * 10-Mar-2005 LCVR Changed S3C2410_{VA,SZ} to S3C24XX_{VA,SZ} * 10-Feb-2005 BJD Added camera from guillaume.gourat@nexvision.tv * 29-Aug-2004 BJD Added timers 0 through 3 @@ -47,8 +46,8 @@ struct platform_device *s3c24xx_uart_devs[3]; static struct resource s3c_usb_resource[] = { [0] = { - .start = S3C24XX_PA_USBHOST, - .end = S3C24XX_PA_USBHOST + S3C24XX_SZ_USBHOST - 1, + .start = S3C2410_PA_USBHOST, + .end = S3C2410_PA_USBHOST + S3C24XX_SZ_USBHOST - 1, .flags = IORESOURCE_MEM, }, [1] = { @@ -77,8 +76,8 @@ EXPORT_SYMBOL(s3c_device_usb); static struct resource s3c_lcd_resource[] = { [0] = { - .start = S3C24XX_PA_LCD, - .end = S3C24XX_PA_LCD + S3C24XX_SZ_LCD - 1, + .start = S3C2410_PA_LCD, + .end = S3C2410_PA_LCD + S3C24XX_SZ_LCD - 1, .flags = IORESOURCE_MEM, }, [1] = { @@ -140,8 +139,8 @@ EXPORT_SYMBOL(s3c_device_nand); static struct resource s3c_usbgadget_resource[] = { [0] = { - .start = S3C24XX_PA_USBDEV, - .end = S3C24XX_PA_USBDEV + S3C24XX_SZ_USBDEV - 1, + .start = S3C2410_PA_USBDEV, + .end = S3C2410_PA_USBDEV + S3C24XX_SZ_USBDEV - 1, .flags = IORESOURCE_MEM, }, [1] = { @@ -165,8 +164,8 @@ EXPORT_SYMBOL(s3c_device_usbgadget); static struct resource s3c_wdt_resource[] = { [0] = { - .start = S3C24XX_PA_WATCHDOG, - .end = S3C24XX_PA_WATCHDOG + S3C24XX_SZ_WATCHDOG - 1, + .start = S3C2410_PA_WATCHDOG, + .end = S3C2410_PA_WATCHDOG + S3C24XX_SZ_WATCHDOG - 1, .flags = IORESOURCE_MEM, }, [1] = { @@ -190,8 +189,8 @@ EXPORT_SYMBOL(s3c_device_wdt); static struct resource s3c_i2c_resource[] = { [0] = { - .start = S3C24XX_PA_IIC, - .end = S3C24XX_PA_IIC + S3C24XX_SZ_IIC - 1, + .start = S3C2410_PA_IIC, + .end = S3C2410_PA_IIC + S3C24XX_SZ_IIC - 1, .flags = IORESOURCE_MEM, }, [1] = { @@ -215,8 +214,8 @@ EXPORT_SYMBOL(s3c_device_i2c); static struct resource s3c_iis_resource[] = { [0] = { - .start = S3C24XX_PA_IIS, - .end = S3C24XX_PA_IIS + S3C24XX_SZ_IIS -1, + .start = S3C2410_PA_IIS, + .end = S3C2410_PA_IIS + S3C24XX_SZ_IIS -1, .flags = IORESOURCE_MEM, } }; @@ -240,8 +239,8 @@ EXPORT_SYMBOL(s3c_device_iis); static struct resource s3c_rtc_resource[] = { [0] = { - .start = S3C24XX_PA_RTC, - .end = S3C24XX_PA_RTC + 0xff, + .start = S3C2410_PA_RTC, + .end = S3C2410_PA_RTC + 0xff, .flags = IORESOURCE_MEM, }, [1] = { @@ -269,17 +268,12 @@ EXPORT_SYMBOL(s3c_device_rtc); static struct resource s3c_adc_resource[] = { [0] = { - .start = S3C24XX_PA_ADC, - .end = S3C24XX_PA_ADC + S3C24XX_SZ_ADC - 1, + .start = S3C2410_PA_ADC, + .end = S3C2410_PA_ADC + S3C24XX_SZ_ADC - 1, .flags = IORESOURCE_MEM, }, [1] = { .start = IRQ_TC, - .end = IRQ_TC, - .flags = IORESOURCE_IRQ, - }, - [2] = { - .start = IRQ_ADC, .end = IRQ_ADC, .flags = IORESOURCE_IRQ, } @@ -322,8 +316,8 @@ EXPORT_SYMBOL(s3c_device_sdi); static struct resource s3c_spi0_resource[] = { [0] = { - .start = S3C24XX_PA_SPI, - .end = S3C24XX_PA_SPI + 0x1f, + .start = S3C2410_PA_SPI, + .end = S3C2410_PA_SPI + 0x1f, .flags = IORESOURCE_MEM, }, [1] = { @@ -347,8 +341,8 @@ EXPORT_SYMBOL(s3c_device_spi0); static struct resource s3c_spi1_resource[] = { [0] = { - .start = S3C24XX_PA_SPI + 0x20, - .end = S3C24XX_PA_SPI + 0x20 + 0x1f, + .start = S3C2410_PA_SPI + 0x20, + .end = S3C2410_PA_SPI + 0x20 + 0x1f, .flags = IORESOURCE_MEM, }, [1] = { @@ -372,8 +366,8 @@ EXPORT_SYMBOL(s3c_device_spi1); static struct resource s3c_timer0_resource[] = { [0] = { - .start = S3C24XX_PA_TIMER + 0x0C, - .end = S3C24XX_PA_TIMER + 0x0C + 0xB, + .start = S3C2410_PA_TIMER + 0x0C, + .end = S3C2410_PA_TIMER + 0x0C + 0xB, .flags = IORESOURCE_MEM, }, [1] = { @@ -397,8 +391,8 @@ EXPORT_SYMBOL(s3c_device_timer0); static struct resource s3c_timer1_resource[] = { [0] = { - .start = S3C24XX_PA_TIMER + 0x18, - .end = S3C24XX_PA_TIMER + 0x23, + .start = S3C2410_PA_TIMER + 0x18, + .end = S3C2410_PA_TIMER + 0x23, .flags = IORESOURCE_MEM, }, [1] = { @@ -422,8 +416,8 @@ EXPORT_SYMBOL(s3c_device_timer1); static struct resource s3c_timer2_resource[] = { [0] = { - .start = S3C24XX_PA_TIMER + 0x24, - .end = S3C24XX_PA_TIMER + 0x2F, + .start = S3C2410_PA_TIMER + 0x24, + .end = S3C2410_PA_TIMER + 0x2F, .flags = IORESOURCE_MEM, }, [1] = { @@ -447,8 +441,8 @@ EXPORT_SYMBOL(s3c_device_timer2); static struct resource s3c_timer3_resource[] = { [0] = { - .start = S3C24XX_PA_TIMER + 0x30, - .end = S3C24XX_PA_TIMER + 0x3B, + .start = S3C2410_PA_TIMER + 0x30, + .end = S3C2410_PA_TIMER + 0x3B, .flags = IORESOURCE_MEM, }, [1] = { diff --git a/trunk/arch/arm/mach-s3c2410/dma.c b/trunk/arch/arm/mach-s3c2410/dma.c index 4dbd8e758ea6..65feaf20d23e 100644 --- a/trunk/arch/arm/mach-s3c2410/dma.c +++ b/trunk/arch/arm/mach-s3c2410/dma.c @@ -1152,7 +1152,7 @@ static int __init s3c2410_init_dma(void) printk("S3C2410 DMA Driver, (c) 2003-2004 Simtec Electronics\n"); - dma_base = ioremap(S3C24XX_PA_DMA, 0x200); + dma_base = ioremap(S3C2410_PA_DMA, 0x200); if (dma_base == NULL) { printk(KERN_ERR "dma failed to remap register block\n"); return -ENOMEM; diff --git a/trunk/arch/arm/mach-s3c2410/gpio.c b/trunk/arch/arm/mach-s3c2410/gpio.c index cd39e8684584..23ea3d5fa09c 100644 --- a/trunk/arch/arm/mach-s3c2410/gpio.c +++ b/trunk/arch/arm/mach-s3c2410/gpio.c @@ -31,7 +31,6 @@ * 05-Nov-2004 BJD EXPORT_SYMBOL() added for all code * 13-Mar-2005 BJD Updates for __iomem * 26-Oct-2005 BJD Added generic configuration types - * 15-Jan-2006 LCVR Added support for the S3C2400 */ @@ -49,7 +48,7 @@ void s3c2410_gpio_cfgpin(unsigned int pin, unsigned int function) { - void __iomem *base = S3C24XX_GPIO_BASE(pin); + void __iomem *base = S3C2410_GPIO_BASE(pin); unsigned long mask; unsigned long con; unsigned long flags; @@ -96,7 +95,7 @@ EXPORT_SYMBOL(s3c2410_gpio_cfgpin); unsigned int s3c2410_gpio_getcfg(unsigned int pin) { - void __iomem *base = S3C24XX_GPIO_BASE(pin); + void __iomem *base = S3C2410_GPIO_BASE(pin); unsigned long mask; if (pin < S3C2410_GPIO_BANKB) { @@ -112,7 +111,7 @@ EXPORT_SYMBOL(s3c2410_gpio_getcfg); void s3c2410_gpio_pullup(unsigned int pin, unsigned int to) { - void __iomem *base = S3C24XX_GPIO_BASE(pin); + void __iomem *base = S3C2410_GPIO_BASE(pin); unsigned long offs = S3C2410_GPIO_OFFSET(pin); unsigned long flags; unsigned long up; @@ -134,7 +133,7 @@ EXPORT_SYMBOL(s3c2410_gpio_pullup); void s3c2410_gpio_setpin(unsigned int pin, unsigned int to) { - void __iomem *base = S3C24XX_GPIO_BASE(pin); + void __iomem *base = S3C2410_GPIO_BASE(pin); unsigned long offs = S3C2410_GPIO_OFFSET(pin); unsigned long flags; unsigned long dat; @@ -153,7 +152,7 @@ EXPORT_SYMBOL(s3c2410_gpio_setpin); unsigned int s3c2410_gpio_getpin(unsigned int pin) { - void __iomem *base = S3C24XX_GPIO_BASE(pin); + void __iomem *base = S3C2410_GPIO_BASE(pin); unsigned long offs = S3C2410_GPIO_OFFSET(pin); return __raw_readl(base + 0x04) & (1<< offs); @@ -167,13 +166,70 @@ unsigned int s3c2410_modify_misccr(unsigned int clear, unsigned int change) unsigned long misccr; local_irq_save(flags); - misccr = __raw_readl(S3C24XX_MISCCR); + misccr = __raw_readl(S3C2410_MISCCR); misccr &= ~clear; misccr ^= change; - __raw_writel(misccr, S3C24XX_MISCCR); + __raw_writel(misccr, S3C2410_MISCCR); local_irq_restore(flags); return misccr; } EXPORT_SYMBOL(s3c2410_modify_misccr); + +int s3c2410_gpio_getirq(unsigned int pin) +{ + if (pin < S3C2410_GPF0 || pin > S3C2410_GPG15_EINT23) + return -1; /* not valid interrupts */ + + if (pin < S3C2410_GPG0 && pin > S3C2410_GPF7) + return -1; /* not valid pin */ + + if (pin < S3C2410_GPF4) + return (pin - S3C2410_GPF0) + IRQ_EINT0; + + if (pin < S3C2410_GPG0) + return (pin - S3C2410_GPF4) + IRQ_EINT4; + + return (pin - S3C2410_GPG0) + IRQ_EINT8; +} + +EXPORT_SYMBOL(s3c2410_gpio_getirq); + +int s3c2410_gpio_irqfilter(unsigned int pin, unsigned int on, + unsigned int config) +{ + void __iomem *reg = S3C2410_EINFLT0; + unsigned long flags; + unsigned long val; + + if (pin < S3C2410_GPG8 || pin > S3C2410_GPG15) + return -1; + + config &= 0xff; + + pin -= S3C2410_GPG8_EINT16; + reg += pin & ~3; + + local_irq_save(flags); + + /* update filter width and clock source */ + + val = __raw_readl(reg); + val &= ~(0xff << ((pin & 3) * 8)); + val |= config << ((pin & 3) * 8); + __raw_writel(val, reg); + + /* update filter enable */ + + val = __raw_readl(S3C2410_EXTINT2); + val &= ~(1 << ((pin * 4) + 3)); + val |= on << ((pin * 4) + 3); + __raw_writel(val, S3C2410_EXTINT2); + + local_irq_restore(flags); + + return 0; +} + +EXPORT_SYMBOL(s3c2410_gpio_irqfilter); diff --git a/trunk/arch/arm/mach-s3c2410/mach-h1940.c b/trunk/arch/arm/mach-s3c2410/mach-h1940.c index 646a3a5d33a5..1c316f14ed94 100644 --- a/trunk/arch/arm/mach-s3c2410/mach-h1940.c +++ b/trunk/arch/arm/mach-s3c2410/mach-h1940.c @@ -46,11 +46,10 @@ #include #include - +//#include #include #include -#include #include #include @@ -60,12 +59,7 @@ #include "cpu.h" static struct map_desc h1940_iodesc[] __initdata = { - [0] = { - .virtual = (unsigned long)H1940_LATCH, - .pfn = __phys_to_pfn(H1940_PA_LATCH), - .length = SZ_16K, - .type = MT_DEVICE - }, + /* nothing here yet */ }; #define UCON S3C2410_UCON_DEFAULT | S3C2410_UCON_UCLK @@ -98,25 +92,6 @@ static struct s3c2410_uartcfg h1940_uartcfgs[] = { } }; -/* Board control latch control */ - -static unsigned int latch_state = H1940_LATCH_DEFAULT; - -void h1940_latch_control(unsigned int clear, unsigned int set) -{ - unsigned long flags; - - local_irq_save(flags); - - latch_state &= ~clear; - latch_state |= set; - - __raw_writel(latch_state, H1940_LATCH); - - local_irq_restore(flags); -} - -EXPORT_SYMBOL_GPL(h1940_latch_control); /** diff --git a/trunk/arch/arm/mach-s3c2410/s3c2400-gpio.c b/trunk/arch/arm/mach-s3c2410/s3c2400-gpio.c deleted file mode 100644 index 5127f39fa9bf..000000000000 --- a/trunk/arch/arm/mach-s3c2410/s3c2400-gpio.c +++ /dev/null @@ -1,45 +0,0 @@ -/* linux/arch/arm/mach-s3c2410/gpio.c - * - * Copyright (c) 2006 Lucas Correia Villa Real - * - * S3C2400 GPIO support - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * Changelog - * 15-Jan-2006 LCVR Splitted from gpio.c, adding support for the S3C2400 - */ - -#include -#include -#include -#include -#include - -#include -#include -#include - -#include - -int s3c2400_gpio_getirq(unsigned int pin) -{ - if (pin < S3C2410_GPE0 || pin > S3C2400_GPE7_EINT7) - return -1; /* not valid interrupts */ - - return (pin - S3C2410_GPE0) + IRQ_EINT0; -} - -EXPORT_SYMBOL(s3c2400_gpio_getirq); diff --git a/trunk/arch/arm/mach-s3c2410/s3c2400.h b/trunk/arch/arm/mach-s3c2410/s3c2400.h deleted file mode 100644 index 8b2394e1ed40..000000000000 --- a/trunk/arch/arm/mach-s3c2410/s3c2400.h +++ /dev/null @@ -1,31 +0,0 @@ -/* arch/arm/mach-s3c2410/s3c2400.h - * - * Copyright (c) 2004 Simtec Electronics - * Ben Dooks - * - * Header file for S3C2400 cpu support - * - * 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. - * - * Modifications: - * 09-Fev-2006 LCVR First version, based on s3c2410.h -*/ - -#ifdef CONFIG_CPU_S3C2400 - -extern int s3c2400_init(void); - -extern void s3c2400_map_io(struct map_desc *mach_desc, int size); - -extern void s3c2400_init_uarts(struct s3c2410_uartcfg *cfg, int no); - -extern void s3c2400_init_clocks(int xtal); - -#else -#define s3c2400_init_clocks NULL -#define s3c2400_init_uarts NULL -#define s3c2400_map_io NULL -#define s3c2400_init NULL -#endif diff --git a/trunk/arch/arm/mach-s3c2410/s3c2410-gpio.c b/trunk/arch/arm/mach-s3c2410/s3c2410-gpio.c deleted file mode 100644 index d5e1caea1d23..000000000000 --- a/trunk/arch/arm/mach-s3c2410/s3c2410-gpio.c +++ /dev/null @@ -1,93 +0,0 @@ -/* linux/arch/arm/mach-s3c2410/gpio.c - * - * Copyright (c) 2004-2006 Simtec Electronics - * Ben Dooks - * - * S3C2410 GPIO support - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License as published by - * the Free Software Foundation; either version 2 of the License, or - * (at your option) any later version. - * - * This program is distributed in the hope that it will be useful, - * but WITHOUT ANY WARRANTY; without even the implied warranty of - * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the - * GNU General Public License for more details. - * - * You should have received a copy of the GNU General Public License - * along with this program; if not, write to the Free Software - * Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA - * - * Changelog - * 15-Jan-2006 LCVR Splitted from gpio.c - */ - -#include -#include -#include -#include -#include - -#include -#include -#include - -#include - -int s3c2410_gpio_irqfilter(unsigned int pin, unsigned int on, - unsigned int config) -{ - void __iomem *reg = S3C2410_EINFLT0; - unsigned long flags; - unsigned long val; - - if (pin < S3C2410_GPG8 || pin > S3C2410_GPG15) - return -1; - - config &= 0xff; - - pin -= S3C2410_GPG8_EINT16; - reg += pin & ~3; - - local_irq_save(flags); - - /* update filter width and clock source */ - - val = __raw_readl(reg); - val &= ~(0xff << ((pin & 3) * 8)); - val |= config << ((pin & 3) * 8); - __raw_writel(val, reg); - - /* update filter enable */ - - val = __raw_readl(S3C2410_EXTINT2); - val &= ~(1 << ((pin * 4) + 3)); - val |= on << ((pin * 4) + 3); - __raw_writel(val, S3C2410_EXTINT2); - - local_irq_restore(flags); - - return 0; -} - -EXPORT_SYMBOL(s3c2410_gpio_irqfilter); - -int s3c2410_gpio_getirq(unsigned int pin) -{ - if (pin < S3C2410_GPF0 || pin > S3C2410_GPG15_EINT23) - return -1; /* not valid interrupts */ - - if (pin < S3C2410_GPG0 && pin > S3C2410_GPF7) - return -1; /* not valid pin */ - - if (pin < S3C2410_GPF4) - return (pin - S3C2410_GPF0) + IRQ_EINT0; - - if (pin < S3C2410_GPG0) - return (pin - S3C2410_GPF4) + IRQ_EINT4; - - return (pin - S3C2410_GPG0) + IRQ_EINT8; -} - -EXPORT_SYMBOL(s3c2410_gpio_getirq); diff --git a/trunk/arch/arm/mach-s3c2410/sleep.S b/trunk/arch/arm/mach-s3c2410/sleep.S index 832fb86a03b4..61768dac7fee 100644 --- a/trunk/arch/arm/mach-s3c2410/sleep.S +++ b/trunk/arch/arm/mach-s3c2410/sleep.S @@ -72,7 +72,7 @@ ENTRY(s3c2410_cpu_suspend) @@ prepare cpu to sleep ldr r4, =S3C2410_REFRESH - ldr r5, =S3C24XX_MISCCR + ldr r5, =S3C2410_MISCCR ldr r6, =S3C2410_CLKCON ldr r7, [ r4 ] @ get REFRESH (and ensure in TLB) ldr r8, [ r5 ] @ get MISCCR (and ensure in TLB) @@ -133,12 +133,12 @@ ENTRY(s3c2410_cpu_resume) @@ load UART to allow us to print the two characters for @@ resume debug - mov r2, #S3C24XX_PA_UART & 0xff000000 - orr r2, r2, #S3C24XX_PA_UART & 0xff000 + mov r2, #S3C2410_PA_UART & 0xff000000 + orr r2, r2, #S3C2410_PA_UART & 0xff000 #if 0 /* SMDK2440 LED set */ - mov r14, #S3C24XX_PA_GPIO + mov r14, #S3C2410_PA_GPIO ldr r12, [ r14, #0x54 ] bic r12, r12, #3<<4 orr r12, r12, #1<<7 diff --git a/trunk/arch/arm/mm/cache-v6.S b/trunk/arch/arm/mm/cache-v6.S index d921c1024ae0..72966d90e956 100644 --- a/trunk/arch/arm/mm/cache-v6.S +++ b/trunk/arch/arm/mm/cache-v6.S @@ -92,16 +92,22 @@ ENTRY(v6_coherent_kern_range) * - the Icache does not read data from the write buffer */ ENTRY(v6_coherent_user_range) - -#ifdef HARVARD_CACHE bic r0, r0, #CACHE_LINE_SIZE - 1 -1: mcr p15, 0, r0, c7, c10, 1 @ clean D line +1: +#ifdef HARVARD_CACHE + mcr p15, 0, r0, c7, c10, 1 @ clean D line mcr p15, 0, r0, c7, c5, 1 @ invalidate I line - add r0, r0, #CACHE_LINE_SIZE +#endif + mcr p15, 0, r0, c7, c5, 7 @ invalidate BTB entry + add r0, r0, #BTB_FLUSH_SIZE + mcr p15, 0, r0, c7, c5, 7 @ invalidate BTB entry + add r0, r0, #BTB_FLUSH_SIZE + mcr p15, 0, r0, c7, c5, 7 @ invalidate BTB entry + add r0, r0, #BTB_FLUSH_SIZE + mcr p15, 0, r0, c7, c5, 7 @ invalidate BTB entry + add r0, r0, #BTB_FLUSH_SIZE cmp r0, r1 blo 1b -#endif - mcr p15, 0, r0, c7, c5, 6 @ invalidate BTB #ifdef HARVARD_CACHE mov r0, #0 mcr p15, 0, r0, c7, c10, 4 @ drain write buffer diff --git a/trunk/arch/arm/mm/ioremap.c b/trunk/arch/arm/mm/ioremap.c index da9b35974118..de3ce1eec2ec 100644 --- a/trunk/arch/arm/mm/ioremap.c +++ b/trunk/arch/arm/mm/ioremap.c @@ -142,7 +142,7 @@ __ioremap_pfn(unsigned long pfn, unsigned long offset, size_t size, return NULL; addr = (unsigned long)area->addr; if (remap_area_pages(addr, pfn, size, flags)) { - vfree((void *)addr); + vfree(addr); return NULL; } return (void __iomem *) (offset + (char *)addr); diff --git a/trunk/arch/arm/mm/mm-armv.c b/trunk/arch/arm/mm/mm-armv.c index ef8d30a185a9..d0245a31d4dd 100644 --- a/trunk/arch/arm/mm/mm-armv.c +++ b/trunk/arch/arm/mm/mm-armv.c @@ -343,12 +343,6 @@ static struct mem_types mem_types[] __initdata = { PMD_SECT_AP_WRITE | PMD_SECT_BUFFERABLE | PMD_SECT_TEX(1), .domain = DOMAIN_IO, - }, - [MT_NONSHARED_DEVICE] = { - .prot_l1 = PMD_TYPE_TABLE, - .prot_sect = PMD_TYPE_SECT | PMD_SECT_NONSHARED_DEV | - PMD_SECT_AP_WRITE, - .domain = DOMAIN_IO, } }; diff --git a/trunk/arch/arm/mm/proc-xscale.S b/trunk/arch/arm/mm/proc-xscale.S index 2d3823ec3153..861b35947280 100644 --- a/trunk/arch/arm/mm/proc-xscale.S +++ b/trunk/arch/arm/mm/proc-xscale.S @@ -241,15 +241,7 @@ ENTRY(xscale_flush_user_cache_range) * it also trashes the mini I-cache used by JTAG debuggers. */ ENTRY(xscale_coherent_kern_range) - bic r0, r0, #CACHELINESIZE - 1 -1: mcr p15, 0, r0, c7, c10, 1 @ clean D entry - add r0, r0, #CACHELINESIZE - cmp r0, r1 - blo 1b - mov r0, #0 - mcr p15, 0, r0, c7, c5, 0 @ Invalidate I cache & BTB - mcr p15, 0, r0, c7, c10, 4 @ Drain Write (& Fill) Buffer - mov pc, lr + /* FALLTHROUGH */ /* * coherent_user_range(start, end) @@ -260,16 +252,18 @@ ENTRY(xscale_coherent_kern_range) * * - start - virtual start address * - end - virtual end address + * + * Note: single I-cache line invalidation isn't used here since + * it also trashes the mini I-cache used by JTAG debuggers. */ ENTRY(xscale_coherent_user_range) bic r0, r0, #CACHELINESIZE - 1 1: mcr p15, 0, r0, c7, c10, 1 @ clean D entry - mcr p15, 0, r0, c7, c5, 1 @ Invalidate I cache entry add r0, r0, #CACHELINESIZE cmp r0, r1 blo 1b mov r0, #0 - mcr p15, 0, r0, c7, c5, 6 @ Invalidate BTB + mcr p15, 0, r0, c7, c5, 0 @ Invalidate I cache & BTB mcr p15, 0, r0, c7, c10, 4 @ Drain Write (& Fill) Buffer mov pc, lr diff --git a/trunk/arch/arm/oprofile/common.c b/trunk/arch/arm/oprofile/common.c index 6f8bc1f0e6a1..1415930ceee1 100644 --- a/trunk/arch/arm/oprofile/common.c +++ b/trunk/arch/arm/oprofile/common.c @@ -137,9 +137,8 @@ int __init oprofile_arch_init(struct oprofile_operations *ops) if (spec) { init_MUTEX(&op_arm_sem); - ret = spec->init(); - if (ret < 0) - return ret; + if (spec->init() < 0) + return -ENODEV; op_arm_model = spec; init_driverfs(); diff --git a/trunk/arch/arm/plat-omap/clock.c b/trunk/arch/arm/plat-omap/clock.c index 3c2bfc0efdaf..7ebc5a29db8d 100644 --- a/trunk/arch/arm/plat-omap/clock.c +++ b/trunk/arch/arm/plat-omap/clock.c @@ -34,7 +34,7 @@ DEFINE_SPINLOCK(clockfw_lock); static struct clk_functions *arch_clock; /*------------------------------------------------------------------------- - * Standard clock functions defined in include/linux/clk.h + * Standard clock functions defined in asm/hardware/clock.h *-------------------------------------------------------------------------*/ struct clk * clk_get(struct device *dev, const char *id) @@ -60,8 +60,12 @@ int clk_enable(struct clk *clk) int ret = 0; spin_lock_irqsave(&clockfw_lock, flags); - if (arch_clock->clk_enable) + if (clk->enable) + ret = clk->enable(clk); + else if (arch_clock->clk_enable) ret = arch_clock->clk_enable(clk); + else + printk(KERN_ERR "Could not enable clock %s\n", clk->name); spin_unlock_irqrestore(&clockfw_lock, flags); return ret; @@ -73,12 +77,41 @@ void clk_disable(struct clk *clk) unsigned long flags; spin_lock_irqsave(&clockfw_lock, flags); - if (arch_clock->clk_disable) + if (clk->disable) + clk->disable(clk); + else if (arch_clock->clk_disable) arch_clock->clk_disable(clk); + else + printk(KERN_ERR "Could not disable clock %s\n", clk->name); spin_unlock_irqrestore(&clockfw_lock, flags); } EXPORT_SYMBOL(clk_disable); +int clk_use(struct clk *clk) +{ + unsigned long flags; + int ret = 0; + + spin_lock_irqsave(&clockfw_lock, flags); + if (arch_clock->clk_use) + ret = arch_clock->clk_use(clk); + spin_unlock_irqrestore(&clockfw_lock, flags); + + return ret; +} +EXPORT_SYMBOL(clk_use); + +void clk_unuse(struct clk *clk) +{ + unsigned long flags; + + spin_lock_irqsave(&clockfw_lock, flags); + if (arch_clock->clk_unuse) + arch_clock->clk_unuse(clk); + spin_unlock_irqrestore(&clockfw_lock, flags); +} +EXPORT_SYMBOL(clk_unuse); + int clk_get_usecount(struct clk *clk) { unsigned long flags; @@ -113,7 +146,7 @@ void clk_put(struct clk *clk) EXPORT_SYMBOL(clk_put); /*------------------------------------------------------------------------- - * Optional clock functions defined in include/linux/clk.h + * Optional clock functions defined in asm/hardware/clock.h *-------------------------------------------------------------------------*/ long clk_round_rate(struct clk *clk, unsigned long rate) diff --git a/trunk/arch/arm/plat-omap/gpio.c b/trunk/arch/arm/plat-omap/gpio.c index b4d5b9e4bfce..ca3681a824ac 100644 --- a/trunk/arch/arm/plat-omap/gpio.c +++ b/trunk/arch/arm/plat-omap/gpio.c @@ -853,19 +853,19 @@ static int __init _omap_gpio_init(void) if (IS_ERR(gpio_ick)) printk("Could not get arm_gpio_ck\n"); else - clk_enable(gpio_ick); + clk_use(gpio_ick); } if (cpu_is_omap24xx()) { gpio_ick = clk_get(NULL, "gpios_ick"); if (IS_ERR(gpio_ick)) printk("Could not get gpios_ick\n"); else - clk_enable(gpio_ick); + clk_use(gpio_ick); gpio_fck = clk_get(NULL, "gpios_fck"); if (IS_ERR(gpio_ick)) printk("Could not get gpios_fck\n"); else - clk_enable(gpio_fck); + clk_use(gpio_fck); } #ifdef CONFIG_ARCH_OMAP15XX diff --git a/trunk/arch/arm/plat-omap/mcbsp.c b/trunk/arch/arm/plat-omap/mcbsp.c index 1cd2cace7e1b..be0e0f32a598 100644 --- a/trunk/arch/arm/plat-omap/mcbsp.c +++ b/trunk/arch/arm/plat-omap/mcbsp.c @@ -190,11 +190,11 @@ static int omap_mcbsp_check(unsigned int id) static void omap_mcbsp_dsp_request(void) { if (cpu_is_omap1510() || cpu_is_omap16xx()) { - clk_enable(mcbsp_dsp_ck); - clk_enable(mcbsp_api_ck); + clk_use(mcbsp_dsp_ck); + clk_use(mcbsp_api_ck); /* enable 12MHz clock to mcbsp 1 & 3 */ - clk_enable(mcbsp_dspxor_ck); + clk_use(mcbsp_dspxor_ck); /* * DSP external peripheral reset @@ -208,9 +208,9 @@ static void omap_mcbsp_dsp_request(void) static void omap_mcbsp_dsp_free(void) { if (cpu_is_omap1510() || cpu_is_omap16xx()) { - clk_disable(mcbsp_dspxor_ck); - clk_disable(mcbsp_dsp_ck); - clk_disable(mcbsp_api_ck); + clk_unuse(mcbsp_dspxor_ck); + clk_unuse(mcbsp_dsp_ck); + clk_unuse(mcbsp_api_ck); } } diff --git a/trunk/arch/arm/plat-omap/ocpi.c b/trunk/arch/arm/plat-omap/ocpi.c index 5cc6775c789c..e40fcc8b43d4 100644 --- a/trunk/arch/arm/plat-omap/ocpi.c +++ b/trunk/arch/arm/plat-omap/ocpi.c @@ -88,7 +88,7 @@ static int __init omap_ocpi_init(void) if (IS_ERR(ocpi_ck)) return PTR_ERR(ocpi_ck); - clk_enable(ocpi_ck); + clk_use(ocpi_ck); ocpi_enable(); printk("OMAP OCPI interconnect driver loaded\n"); @@ -102,7 +102,7 @@ static void __exit omap_ocpi_exit(void) if (!cpu_is_omap16xx()) return; - clk_disable(ocpi_ck); + clk_unuse(ocpi_ck); clk_put(ocpi_ck); } diff --git a/trunk/arch/arm/plat-omap/sram.c b/trunk/arch/arm/plat-omap/sram.c index ee82763b02b8..792f66375830 100644 --- a/trunk/arch/arm/plat-omap/sram.c +++ b/trunk/arch/arm/plat-omap/sram.c @@ -17,7 +17,6 @@ #include #include -#include #include #include @@ -96,14 +95,6 @@ void __init omap_map_sram(void) omap_sram_io_desc[0].pfn, omap_sram_io_desc[0].virtual, omap_sram_io_desc[0].length); - /* - * Normally devicemaps_init() would flush caches and tlb after - * mdesc->map_io(), but since we're called from map_io(), we - * must do it here. - */ - local_flush_tlb_all(); - flush_cache_all(); - /* * Looks like we need to preserve some bootloader code at the * beginning of SRAM for jumping to flash for reboot to work... diff --git a/trunk/arch/arm26/Kconfig b/trunk/arch/arm26/Kconfig index dee23d87fc5a..274e07019b46 100644 --- a/trunk/arch/arm26/Kconfig +++ b/trunk/arch/arm26/Kconfig @@ -53,14 +53,14 @@ config GENERIC_ISA_DMA config ARCH_MAY_HAVE_PC_FDC bool + default y source "init/Kconfig" menu "System Type" -choice - prompt "Archimedes/A5000 Implementations" +comment "Archimedes/A5000 Implementations (select only ONE)" config ARCH_ARC bool "Archimedes" @@ -73,7 +73,6 @@ config ARCH_ARC config ARCH_A5K bool "A5000" - select ARCH_MAY_HAVE_PC_FDC help Say Y here to to support the Acorn A5000. @@ -88,7 +87,6 @@ config PAGESIZE_16 Say Y here if your Archimedes or A5000 system has only 2MB of memory, otherwise say N. The resulting kernel will not run on a machine with 4MB of memory. -endchoice endmenu config ISA_DMA_API diff --git a/trunk/arch/arm26/kernel/fiq.c b/trunk/arch/arm26/kernel/fiq.c index a24272b61f30..08a97c9498ff 100644 --- a/trunk/arch/arm26/kernel/fiq.c +++ b/trunk/arch/arm26/kernel/fiq.c @@ -104,14 +104,14 @@ void set_fiq_regs(struct pt_regs *regs) { register unsigned long tmp, tmp2; __asm__ volatile ( - "mov %0, pc \n" - "bic %1, %0, #0x3 \n" - "orr %1, %1, %3 \n" - "teqp %1, #0 @ select FIQ mode \n" - "mov r0, r0 \n" - "ldmia %2, {r8 - r14} \n" - "teqp %0, #0 @ return to SVC mode \n" - "mov r0, r0 " + "mov %0, pc + bic %1, %0, #0x3 + orr %1, %1, %3 + teqp %1, #0 @ select FIQ mode + mov r0, r0 + ldmia %2, {r8 - r14} + teqp %0, #0 @ return to SVC mode + mov r0, r0" : "=&r" (tmp), "=&r" (tmp2) : "r" (®s->ARM_r8), "I" (PSR_I_BIT | PSR_F_BIT | MODE_FIQ26) /* These registers aren't modified by the above code in a way @@ -125,14 +125,14 @@ void get_fiq_regs(struct pt_regs *regs) { register unsigned long tmp, tmp2; __asm__ volatile ( - "mov %0, pc \n" - "bic %1, %0, #0x3 \n" - "orr %1, %1, %3 \n" - "teqp %1, #0 @ select FIQ mode \n" - "mov r0, r0 \n" - "stmia %2, {r8 - r14} \n" - "teqp %0, #0 @ return to SVC mode \n" - "mov r0, r0 " + "mov %0, pc + bic %1, %0, #0x3 + orr %1, %1, %3 + teqp %1, #0 @ select FIQ mode + mov r0, r0 + stmia %2, {r8 - r14} + teqp %0, #0 @ return to SVC mode + mov r0, r0" : "=&r" (tmp), "=&r" (tmp2) : "r" (®s->ARM_r8), "I" (PSR_I_BIT | PSR_F_BIT | MODE_FIQ26) /* These registers aren't modified by the above code in a way diff --git a/trunk/arch/arm26/kernel/signal.c b/trunk/arch/arm26/kernel/signal.c index 2a48c12100c0..ce2055bdc9ee 100644 --- a/trunk/arch/arm26/kernel/signal.c +++ b/trunk/arch/arm26/kernel/signal.c @@ -480,7 +480,6 @@ static int do_signal(sigset_t *oldset, struct pt_regs *regs, int syscall) { siginfo_t info; int signr; - struct k_sigaction ka; /* * We want the common case to go fast, which @@ -494,7 +493,7 @@ static int do_signal(sigset_t *oldset, struct pt_regs *regs, int syscall) if (current->ptrace & PT_SINGLESTEP) ptrace_cancel_bpt(current); - signr = get_signal_to_deliver(&info, &ka, regs, NULL); + signr = get_signal_to_deliver(&info, regs, NULL); if (signr > 0) { handle_signal(signr, &info, oldset, regs, syscall); if (current->ptrace & PT_SINGLESTEP) diff --git a/trunk/arch/cris/Makefile b/trunk/arch/cris/Makefile index ee114699ef8e..ea65d585cf5e 100644 --- a/trunk/arch/cris/Makefile +++ b/trunk/arch/cris/Makefile @@ -119,7 +119,7 @@ $(SRC_ARCH)/.links: @ln -sfn $(SRC_ARCH)/$(SARCH)/lib $(SRC_ARCH)/lib @ln -sfn $(SRC_ARCH)/$(SARCH) $(SRC_ARCH)/arch @ln -sfn $(SRC_ARCH)/$(SARCH)/vmlinux.lds.S $(SRC_ARCH)/kernel/vmlinux.lds.S - @ln -sfn $(SRC_ARCH)/$(SARCH)/kernel/asm-offsets.c $(SRC_ARCH)/kernel/asm-offsets.c + @ln -sfn $(SRC_ARCH)/$(SARCH)/asm-offsets.c $(SRC_ARCH)/kernel/asm-offsets.c @touch $@ # Create link to sub arch includes diff --git a/trunk/arch/cris/arch-v10/kernel/ptrace.c b/trunk/arch/cris/arch-v10/kernel/ptrace.c index 961c0d58ded4..f214f74f264e 100644 --- a/trunk/arch/cris/arch-v10/kernel/ptrace.c +++ b/trunk/arch/cris/arch-v10/kernel/ptrace.c @@ -202,18 +202,18 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) int i; unsigned long tmp; - ret = 0; for (i = 0; i <= PT_MAX; i++) { tmp = get_reg(child, i); if (put_user(tmp, datap)) { ret = -EFAULT; - break; + goto out_tsk; } data += sizeof(long); } + ret = 0; break; } @@ -222,11 +222,10 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) int i; unsigned long tmp; - ret = 0; for (i = 0; i <= PT_MAX; i++) { if (get_user(tmp, datap)) { ret = -EFAULT; - break; + goto out_tsk; } if (i == PT_DCCR) { @@ -238,6 +237,7 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) data += sizeof(long); } + ret = 0; break; } diff --git a/trunk/arch/cris/kernel/setup.c b/trunk/arch/cris/kernel/setup.c index 1ba57efff60d..d11206e467ab 100644 --- a/trunk/arch/cris/kernel/setup.c +++ b/trunk/arch/cris/kernel/setup.c @@ -24,6 +24,7 @@ /* * Setup options */ +struct drive_info_struct { char dummy[32]; } drive_info; struct screen_info screen_info; extern int root_mountflags; diff --git a/trunk/arch/frv/kernel/signal.c b/trunk/arch/frv/kernel/signal.c index 679c1d5cc958..5b7146f54fd5 100644 --- a/trunk/arch/frv/kernel/signal.c +++ b/trunk/arch/frv/kernel/signal.c @@ -35,22 +35,74 @@ struct fdpic_func_descriptor { unsigned long GOT; }; +static int do_signal(sigset_t *oldset); + /* * Atomically swap in the new signal mask, and wait for a signal. */ asmlinkage int sys_sigsuspend(int history0, int history1, old_sigset_t mask) { + sigset_t saveset; + mask &= _BLOCKABLE; spin_lock_irq(¤t->sighand->siglock); - current->saved_sigmask = current->blocked; + saveset = current->blocked; siginitset(¤t->blocked, mask); recalc_sigpending(); spin_unlock_irq(¤t->sighand->siglock); - current->state = TASK_INTERRUPTIBLE; - schedule(); - set_thread_flag(TIF_RESTORE_SIGMASK); - return -ERESTARTNOHAND; + __frame->gr8 = -EINTR; + while (1) { + current->state = TASK_INTERRUPTIBLE; + schedule(); + if (do_signal(&saveset)) + /* return the signal number as the return value of this function + * - this is an utterly evil hack. syscalls should not invoke do_signal() + * as entry.S sets regs->gr8 to the return value of the system call + * - we can't just use sigpending() as we'd have to discard SIG_IGN signals + * and call waitpid() if SIGCHLD needed discarding + * - this only works on the i386 because it passes arguments to the signal + * handler on the stack, and the return value in EAX is effectively + * discarded + */ + return __frame->gr8; + } +} + +asmlinkage int sys_rt_sigsuspend(sigset_t __user *unewset, size_t sigsetsize) +{ + sigset_t saveset, newset; + + /* XXX: Don't preclude handling different sized sigset_t's. */ + if (sigsetsize != sizeof(sigset_t)) + return -EINVAL; + + if (copy_from_user(&newset, unewset, sizeof(newset))) + return -EFAULT; + sigdelsetmask(&newset, ~_BLOCKABLE); + + spin_lock_irq(¤t->sighand->siglock); + saveset = current->blocked; + current->blocked = newset; + recalc_sigpending(); + spin_unlock_irq(¤t->sighand->siglock); + + __frame->gr8 = -EINTR; + while (1) { + current->state = TASK_INTERRUPTIBLE; + schedule(); + if (do_signal(&saveset)) + /* return the signal number as the return value of this function + * - this is an utterly evil hack. syscalls should not invoke do_signal() + * as entry.S sets regs->gr8 to the return value of the system call + * - we can't just use sigpending() as we'd have to discard SIG_IGN signals + * and call waitpid() if SIGCHLD needed discarding + * - this only works on the i386 because it passes arguments to the signal + * handler on the stack, and the return value in EAX is effectively + * discarded + */ + return __frame->gr8; + } } asmlinkage int sys_sigaction(int sig, @@ -320,11 +372,11 @@ static int setup_frame(int sig, struct k_sigaction *ka, sigset_t *set) frame->pretcode); #endif - return 0; + return 1; give_sigsegv: force_sig(SIGSEGV, current); - return -EFAULT; + return 0; } /* end setup_frame() */ @@ -419,11 +471,11 @@ static int setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info, frame->pretcode); #endif - return 0; + return 1; give_sigsegv: force_sig(SIGSEGV, current); - return -EFAULT; + return 0; } /* end setup_rt_frame() */ @@ -464,7 +516,7 @@ static int handle_signal(unsigned long sig, siginfo_t *info, else ret = setup_frame(sig, ka, oldset); - if (ret == 0) { + if (ret) { spin_lock_irq(¤t->sighand->siglock); sigorsets(¤t->blocked, ¤t->blocked, &ka->sa.sa_mask); @@ -484,11 +536,10 @@ static int handle_signal(unsigned long sig, siginfo_t *info, * want to handle. Thus you cannot kill init even with a SIGKILL even by * mistake. */ -static void do_signal(void) +static int do_signal(sigset_t *oldset) { struct k_sigaction ka; siginfo_t info; - sigset_t *oldset; int signr; /* @@ -498,62 +549,43 @@ static void do_signal(void) * if so. */ if (!user_mode(__frame)) - return; + return 1; if (try_to_freeze()) goto no_signal; - if (test_thread_flag(TIF_RESTORE_SIGMASK)) - oldset = ¤t->saved_sigmask; - else + if (!oldset) oldset = ¤t->blocked; signr = get_signal_to_deliver(&info, &ka, __frame, NULL); - if (signr > 0) { - if (handle_signal(signr, &info, &ka, oldset) == 0) { - /* a signal was successfully delivered; the saved - * sigmask will have been stored in the signal frame, - * and will be restored by sigreturn, so we can simply - * clear the TIF_RESTORE_SIGMASK flag */ - if (test_thread_flag(TIF_RESTORE_SIGMASK)) - clear_thread_flag(TIF_RESTORE_SIGMASK); - } - - return; - } + if (signr > 0) + return handle_signal(signr, &info, &ka, oldset); no_signal: /* Did we come from a system call? */ if (__frame->syscallno >= 0) { /* Restart the system call - no handlers present */ - switch (__frame->gr8) { - case -ERESTARTNOHAND: - case -ERESTARTSYS: - case -ERESTARTNOINTR: + if (__frame->gr8 == -ERESTARTNOHAND || + __frame->gr8 == -ERESTARTSYS || + __frame->gr8 == -ERESTARTNOINTR) { __frame->gr8 = __frame->orig_gr8; __frame->pc -= 4; - break; + } - case -ERESTART_RESTARTBLOCK: + if (__frame->gr8 == -ERESTART_RESTARTBLOCK){ __frame->gr8 = __NR_restart_syscall; __frame->pc -= 4; - break; } } - /* if there's no signal to deliver, we just put the saved sigmask - * back */ - if (test_thread_flag(TIF_RESTORE_SIGMASK)) { - clear_thread_flag(TIF_RESTORE_SIGMASK); - sigprocmask(SIG_SETMASK, ¤t->saved_sigmask, NULL); - } + return 0; } /* end do_signal() */ /*****************************************************************************/ /* * notification of userspace execution resumption - * - triggered by the TIF_WORK_MASK flags + * - triggered by current->work.notify_resume */ asmlinkage void do_notify_resume(__u32 thread_info_flags) { @@ -562,7 +594,7 @@ asmlinkage void do_notify_resume(__u32 thread_info_flags) clear_thread_flag(TIF_SINGLESTEP); /* deal with pending signal delivery */ - if (thread_info_flags & (_TIF_SIGPENDING | _TIF_RESTORE_SIGMASK)) - do_signal(); + if (thread_info_flags & _TIF_SIGPENDING) + do_signal(NULL); } /* end do_notify_resume() */ diff --git a/trunk/arch/i386/Kconfig b/trunk/arch/i386/Kconfig index 0afec8566e7b..cbde675bc95c 100644 --- a/trunk/arch/i386/Kconfig +++ b/trunk/arch/i386/Kconfig @@ -47,6 +47,15 @@ config DMI source "init/Kconfig" +config DOUBLEFAULT + default y + bool "Enable doublefault exception handler" if EMBEDDED + help + This option allows trapping of rare doublefault exceptions that + would otherwise cause a system to silently reboot. Disabling this + option saves about 4k and might cause you much additional grey + hair. + menu "Processor type and features" choice @@ -442,50 +451,12 @@ config HIGHMEM4G config HIGHMEM64G bool "64GB" - depends on X86_CMPXCHG64 help Select this if you have a 32-bit processor and more than 4 gigabytes of physical RAM. endchoice -choice - depends on EXPERIMENTAL && !X86_PAE - prompt "Memory split" - default VMSPLIT_3G - help - Select the desired split between kernel and user memory. - - If the address range available to the kernel is less than the - physical memory installed, the remaining memory will be available - as "high memory". Accessing high memory is a little more costly - than low memory, as it needs to be mapped into the kernel first. - Note that increasing the kernel address space limits the range - available to user programs, making the address space there - tighter. Selecting anything other than the default 3G/1G split - will also likely make your kernel incompatible with binary-only - kernel modules. - - If you are not absolutely sure what you are doing, leave this - option alone! - - config VMSPLIT_3G - bool "3G/1G user/kernel split" - config VMSPLIT_3G_OPT - bool "3G/1G user/kernel split (for full 1G low memory)" - config VMSPLIT_2G - bool "2G/2G user/kernel split" - config VMSPLIT_1G - bool "1G/3G user/kernel split" -endchoice - -config PAGE_OFFSET - hex - default 0xB0000000 if VMSPLIT_3G_OPT - default 0x78000000 if VMSPLIT_2G - default 0x40000000 if VMSPLIT_1G - default 0xC0000000 - config HIGHMEM bool depends on HIGHMEM64G || HIGHMEM4G @@ -740,15 +711,6 @@ config HOTPLUG_CPU Say N. -config DOUBLEFAULT - default y - bool "Enable doublefault exception handler" if EMBEDDED - help - This option allows trapping of rare doublefault exceptions that - would otherwise cause a system to silently reboot. Disabling this - option saves about 4k and might cause you much additional grey - hair. - endmenu diff --git a/trunk/arch/i386/defconfig b/trunk/arch/i386/defconfig index 3cbe6e9cb9fc..6a431b926019 100644 --- a/trunk/arch/i386/defconfig +++ b/trunk/arch/i386/defconfig @@ -644,8 +644,6 @@ CONFIG_8139TOO_PIO=y # CONFIG_ACENIC is not set # CONFIG_DL2K is not set # CONFIG_E1000 is not set -# CONFIG_E1000_NAPI is not set -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/i386/kernel/acpi/Makefile b/trunk/arch/i386/kernel/acpi/Makefile index d51c7313cae8..267ca48e1b6c 100644 --- a/trunk/arch/i386/kernel/acpi/Makefile +++ b/trunk/arch/i386/kernel/acpi/Makefile @@ -3,6 +3,6 @@ obj-$(CONFIG_X86_IO_APIC) += earlyquirk.o obj-$(CONFIG_ACPI_SLEEP) += sleep.o wakeup.o ifneq ($(CONFIG_ACPI_PROCESSOR),) -obj-y += cstate.o processor.o +obj-y += cstate.o endif diff --git a/trunk/arch/i386/kernel/acpi/boot.c b/trunk/arch/i386/kernel/acpi/boot.c index 79577f0ace98..2111529dea77 100644 --- a/trunk/arch/i386/kernel/acpi/boot.c +++ b/trunk/arch/i386/kernel/acpi/boot.c @@ -248,17 +248,10 @@ acpi_parse_lapic(acpi_table_entry_header * header, const unsigned long end) acpi_table_print_madt_entry(header); - /* Record local apic id only when enabled */ - if (processor->flags.enabled) - x86_acpiid_to_apicid[processor->acpi_id] = processor->id; + /* Register even disabled CPUs for cpu hotplug */ + + x86_acpiid_to_apicid[processor->acpi_id] = processor->id; - /* - * We need to register disabled CPU as well to permit - * counting disabled CPUs. This allows us to size - * cpus_possible_map more accurately, to permit - * to not preallocating memory for all NR_CPUS - * when we use CPU hotplug. - */ mp_register_lapic(processor->id, /* APIC ID */ processor->flags.enabled); /* Enabled? */ @@ -471,7 +464,7 @@ int acpi_gsi_to_irq(u32 gsi, unsigned int *irq) * success: return IRQ number (>=0) * failure: return < 0 */ -int acpi_register_gsi(u32 gsi, int triggering, int polarity) +int acpi_register_gsi(u32 gsi, int edge_level, int active_high_low) { unsigned int irq; unsigned int plat_gsi = gsi; @@ -483,14 +476,14 @@ int acpi_register_gsi(u32 gsi, int triggering, int polarity) if (acpi_irq_model == ACPI_IRQ_MODEL_PIC) { extern void eisa_set_level_irq(unsigned int irq); - if (triggering == ACPI_LEVEL_SENSITIVE) + if (edge_level == ACPI_LEVEL_SENSITIVE) eisa_set_level_irq(gsi); } #endif #ifdef CONFIG_X86_IO_APIC if (acpi_irq_model == ACPI_IRQ_MODEL_IOAPIC) { - plat_gsi = mp_register_gsi(gsi, triggering, polarity); + plat_gsi = mp_register_gsi(gsi, edge_level, active_high_low); } #endif acpi_gsi_to_irq(plat_gsi, &irq); diff --git a/trunk/arch/i386/kernel/acpi/cstate.c b/trunk/arch/i386/kernel/acpi/cstate.c index 25db49ef1770..4c3036ba65df 100644 --- a/trunk/arch/i386/kernel/acpi/cstate.c +++ b/trunk/arch/i386/kernel/acpi/cstate.c @@ -14,6 +14,64 @@ #include #include +static void acpi_processor_power_init_intel_pdc(struct acpi_processor_power + *pow) +{ + struct acpi_object_list *obj_list; + union acpi_object *obj; + u32 *buf; + + /* allocate and initialize pdc. It will be used later. */ + obj_list = kmalloc(sizeof(struct acpi_object_list), GFP_KERNEL); + if (!obj_list) { + printk(KERN_ERR "Memory allocation error\n"); + return; + } + + obj = kmalloc(sizeof(union acpi_object), GFP_KERNEL); + if (!obj) { + printk(KERN_ERR "Memory allocation error\n"); + kfree(obj_list); + return; + } + + buf = kmalloc(12, GFP_KERNEL); + if (!buf) { + printk(KERN_ERR "Memory allocation error\n"); + kfree(obj); + kfree(obj_list); + return; + } + + buf[0] = ACPI_PDC_REVISION_ID; + buf[1] = 1; + buf[2] = ACPI_PDC_C_CAPABILITY_SMP; + + obj->type = ACPI_TYPE_BUFFER; + obj->buffer.length = 12; + obj->buffer.pointer = (u8 *) buf; + obj_list->count = 1; + obj_list->pointer = obj; + pow->pdc = obj_list; + + return; +} + +/* Initialize _PDC data based on the CPU vendor */ +void acpi_processor_power_init_pdc(struct acpi_processor_power *pow, + unsigned int cpu) +{ + struct cpuinfo_x86 *c = cpu_data + cpu; + + pow->pdc = NULL; + if (c->x86_vendor == X86_VENDOR_INTEL) + acpi_processor_power_init_intel_pdc(pow); + + return; +} + +EXPORT_SYMBOL(acpi_processor_power_init_pdc); + /* * Initialize bm_flags based on the CPU cache properties * On SMP it depends on cache configuration diff --git a/trunk/arch/i386/kernel/acpi/processor.c b/trunk/arch/i386/kernel/acpi/processor.c deleted file mode 100644 index 9f4cc02717ec..000000000000 --- a/trunk/arch/i386/kernel/acpi/processor.c +++ /dev/null @@ -1,75 +0,0 @@ -/* - * arch/i386/kernel/acpi/processor.c - * - * Copyright (C) 2005 Intel Corporation - * Venkatesh Pallipadi - * - Added _PDC for platforms with Intel CPUs - */ - -#include -#include -#include -#include - -#include -#include - -static void init_intel_pdc(struct acpi_processor *pr, struct cpuinfo_x86 *c) -{ - struct acpi_object_list *obj_list; - union acpi_object *obj; - u32 *buf; - - /* allocate and initialize pdc. It will be used later. */ - obj_list = kmalloc(sizeof(struct acpi_object_list), GFP_KERNEL); - if (!obj_list) { - printk(KERN_ERR "Memory allocation error\n"); - return; - } - - obj = kmalloc(sizeof(union acpi_object), GFP_KERNEL); - if (!obj) { - printk(KERN_ERR "Memory allocation error\n"); - kfree(obj_list); - return; - } - - buf = kmalloc(12, GFP_KERNEL); - if (!buf) { - printk(KERN_ERR "Memory allocation error\n"); - kfree(obj); - kfree(obj_list); - return; - } - - buf[0] = ACPI_PDC_REVISION_ID; - buf[1] = 1; - buf[2] = ACPI_PDC_C_CAPABILITY_SMP; - - if (cpu_has(c, X86_FEATURE_EST)) - buf[2] |= ACPI_PDC_EST_CAPABILITY_SMP; - - obj->type = ACPI_TYPE_BUFFER; - obj->buffer.length = 12; - obj->buffer.pointer = (u8 *) buf; - obj_list->count = 1; - obj_list->pointer = obj; - pr->pdc = obj_list; - - return; -} - -/* Initialize _PDC data based on the CPU vendor */ -void arch_acpi_processor_init_pdc(struct acpi_processor *pr) -{ - unsigned int cpu = pr->id; - struct cpuinfo_x86 *c = cpu_data + cpu; - - pr->pdc = NULL; - if (c->x86_vendor == X86_VENDOR_INTEL) - init_intel_pdc(pr, c); - - return; -} - -EXPORT_SYMBOL(arch_acpi_processor_init_pdc); diff --git a/trunk/arch/i386/kernel/apic.c b/trunk/arch/i386/kernel/apic.c index f39e09ef64ec..acd3f1e34ca6 100644 --- a/trunk/arch/i386/kernel/apic.c +++ b/trunk/arch/i386/kernel/apic.c @@ -75,10 +75,8 @@ void ack_bad_irq(unsigned int irq) * holds up an irq slot - in excessive cases (when multiple * unexpected vectors occur) that might lock up the APIC * completely. - * But only ack when the APIC is enabled -AK */ - if (cpu_has_apic) - ack_APIC_irq(); + ack_APIC_irq(); } void __init apic_intr_init(void) @@ -1305,7 +1303,6 @@ int __init APIC_init_uniprocessor (void) if (!cpu_has_apic && APIC_INTEGRATED(apic_version[boot_cpu_physical_apicid])) { printk(KERN_ERR "BIOS bug, local APIC #%d not detected!...\n", boot_cpu_physical_apicid); - clear_bit(X86_FEATURE_APIC, boot_cpu_data.x86_capability); return -1; } diff --git a/trunk/arch/i386/kernel/cpu/amd.c b/trunk/arch/i386/kernel/cpu/amd.c index 0810f81f2a05..333578a4e91a 100644 --- a/trunk/arch/i386/kernel/cpu/amd.c +++ b/trunk/arch/i386/kernel/cpu/amd.c @@ -282,11 +282,3 @@ int __init amd_init_cpu(void) } //early_arch_initcall(amd_init_cpu); - -static int __init amd_exit_cpu(void) -{ - cpu_devs[X86_VENDOR_AMD] = NULL; - return 0; -} - -late_initcall(amd_exit_cpu); diff --git a/trunk/arch/i386/kernel/cpu/centaur.c b/trunk/arch/i386/kernel/cpu/centaur.c index f52669ecb93f..394814e57672 100644 --- a/trunk/arch/i386/kernel/cpu/centaur.c +++ b/trunk/arch/i386/kernel/cpu/centaur.c @@ -405,6 +405,10 @@ static void __init init_centaur(struct cpuinfo_x86 *c) winchip2_protect_mcr(); #endif break; + case 10: + name="4"; + /* no info on the WC4 yet */ + break; default: name="??"; } @@ -470,11 +474,3 @@ int __init centaur_init_cpu(void) } //early_arch_initcall(centaur_init_cpu); - -static int __init centaur_exit_cpu(void) -{ - cpu_devs[X86_VENDOR_CENTAUR] = NULL; - return 0; -} - -late_initcall(centaur_exit_cpu); diff --git a/trunk/arch/i386/kernel/cpu/common.c b/trunk/arch/i386/kernel/cpu/common.c index 7eb9213734a3..15aee26ec2b6 100644 --- a/trunk/arch/i386/kernel/cpu/common.c +++ b/trunk/arch/i386/kernel/cpu/common.c @@ -44,7 +44,6 @@ static void default_init(struct cpuinfo_x86 * c) static struct cpu_dev default_cpu = { .c_init = default_init, - .c_vendor = "Unknown", }; static struct cpu_dev * this_cpu = &default_cpu; @@ -151,7 +150,6 @@ static void __devinit get_cpu_vendor(struct cpuinfo_x86 *c, int early) { char *v = c->x86_vendor_id; int i; - static int printed; for (i = 0; i < X86_VENDOR_NUM; i++) { if (cpu_devs[i]) { @@ -161,17 +159,10 @@ static void __devinit get_cpu_vendor(struct cpuinfo_x86 *c, int early) c->x86_vendor = i; if (!early) this_cpu = cpu_devs[i]; - return; + break; } } } - if (!printed) { - printed++; - printk(KERN_ERR "CPU: Vendor unknown, using generic init.\n"); - printk(KERN_ERR "CPU: Your system may be unstable.\n"); - } - c->x86_vendor = X86_VENDOR_UNKNOWN; - this_cpu = &default_cpu; } diff --git a/trunk/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c b/trunk/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c index 3852d0a4c1b5..7975e79d5fa4 100644 --- a/trunk/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c +++ b/trunk/arch/i386/kernel/cpu/cpufreq/acpi-cpufreq.c @@ -295,6 +295,68 @@ acpi_cpufreq_guess_freq ( } +/* + * acpi_processor_cpu_init_pdc_est - let BIOS know about the SMP capabilities + * of this driver + * @perf: processor-specific acpi_io_data struct + * @cpu: CPU being initialized + * + * To avoid issues with legacy OSes, some BIOSes require to be informed of + * the SMP capabilities of OS P-state driver. Here we set the bits in _PDC + * accordingly, for Enhanced Speedstep. Actual call to _PDC is done in + * driver/acpi/processor.c + */ +static void +acpi_processor_cpu_init_pdc_est( + struct acpi_processor_performance *perf, + unsigned int cpu, + struct acpi_object_list *obj_list + ) +{ + union acpi_object *obj; + u32 *buf; + struct cpuinfo_x86 *c = cpu_data + cpu; + dprintk("acpi_processor_cpu_init_pdc_est\n"); + + if (!cpu_has(c, X86_FEATURE_EST)) + return; + + /* Initialize pdc. It will be used later. */ + if (!obj_list) + return; + + if (!(obj_list->count && obj_list->pointer)) + return; + + obj = obj_list->pointer; + if ((obj->buffer.length == 12) && obj->buffer.pointer) { + buf = (u32 *)obj->buffer.pointer; + buf[0] = ACPI_PDC_REVISION_ID; + buf[1] = 1; + buf[2] = ACPI_PDC_EST_CAPABILITY_SMP; + perf->pdc = obj_list; + } + return; +} + + +/* CPU specific PDC initialization */ +static void +acpi_processor_cpu_init_pdc( + struct acpi_processor_performance *perf, + unsigned int cpu, + struct acpi_object_list *obj_list + ) +{ + struct cpuinfo_x86 *c = cpu_data + cpu; + dprintk("acpi_processor_cpu_init_pdc\n"); + perf->pdc = NULL; + if (cpu_has(c, X86_FEATURE_EST)) + acpi_processor_cpu_init_pdc_est(perf, cpu, obj_list); + return; +} + + static int acpi_cpufreq_cpu_init ( struct cpufreq_policy *policy) @@ -305,7 +367,14 @@ acpi_cpufreq_cpu_init ( unsigned int result = 0; struct cpuinfo_x86 *c = &cpu_data[policy->cpu]; + union acpi_object arg0 = {ACPI_TYPE_BUFFER}; + u32 arg0_buf[3]; + struct acpi_object_list arg_list = {1, &arg0}; + dprintk("acpi_cpufreq_cpu_init\n"); + /* setup arg_list for _PDC settings */ + arg0.buffer.length = 12; + arg0.buffer.pointer = (u8 *) arg0_buf; data = kzalloc(sizeof(struct cpufreq_acpi_io), GFP_KERNEL); if (!data) @@ -313,7 +382,9 @@ acpi_cpufreq_cpu_init ( acpi_io_data[cpu] = data; + acpi_processor_cpu_init_pdc(&data->acpi_data, cpu, &arg_list); result = acpi_processor_register_performance(&data->acpi_data, cpu); + data->acpi_data.pdc = NULL; if (result) goto err_free; diff --git a/trunk/arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c b/trunk/arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c index c173c0fa117a..9a826cde4fd1 100644 --- a/trunk/arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c +++ b/trunk/arch/i386/kernel/cpu/cpufreq/speedstep-centrino.c @@ -362,10 +362,22 @@ static struct acpi_processor_performance p; */ static int centrino_cpu_init_acpi(struct cpufreq_policy *policy) { + union acpi_object arg0 = {ACPI_TYPE_BUFFER}; + u32 arg0_buf[3]; + struct acpi_object_list arg_list = {1, &arg0}; unsigned long cur_freq; int result = 0, i; unsigned int cpu = policy->cpu; + /* _PDC settings */ + arg0.buffer.length = 12; + arg0.buffer.pointer = (u8 *) arg0_buf; + arg0_buf[0] = ACPI_PDC_REVISION_ID; + arg0_buf[1] = 1; + arg0_buf[2] = ACPI_PDC_EST_CAPABILITY_SMP_MSR; + + p.pdc = &arg_list; + /* register with ACPI core */ if (acpi_processor_register_performance(&p, cpu)) { dprintk(KERN_INFO PFX "obtaining ACPI data failed\n"); diff --git a/trunk/arch/i386/kernel/cpu/cyrix.c b/trunk/arch/i386/kernel/cpu/cyrix.c index 00f2e058797c..75015975d038 100644 --- a/trunk/arch/i386/kernel/cpu/cyrix.c +++ b/trunk/arch/i386/kernel/cpu/cyrix.c @@ -345,7 +345,7 @@ static void __init init_cyrix(struct cpuinfo_x86 *c) /* * Handle National Semiconductor branded processors */ -static void __init init_nsc(struct cpuinfo_x86 *c) +static void __devinit init_nsc(struct cpuinfo_x86 *c) { /* There may be GX1 processors in the wild that are branded * NSC and not Cyrix. @@ -444,14 +444,6 @@ int __init cyrix_init_cpu(void) //early_arch_initcall(cyrix_init_cpu); -static int __init cyrix_exit_cpu(void) -{ - cpu_devs[X86_VENDOR_CYRIX] = NULL; - return 0; -} - -late_initcall(cyrix_exit_cpu); - static struct cpu_dev nsc_cpu_dev __initdata = { .c_vendor = "NSC", .c_ident = { "Geode by NSC" }, @@ -466,11 +458,3 @@ int __init nsc_init_cpu(void) } //early_arch_initcall(nsc_init_cpu); - -static int __init nsc_exit_cpu(void) -{ - cpu_devs[X86_VENDOR_NSC] = NULL; - return 0; -} - -late_initcall(nsc_exit_cpu); diff --git a/trunk/arch/i386/kernel/cpu/intel_cacheinfo.c b/trunk/arch/i386/kernel/cpu/intel_cacheinfo.c index ffe58cee0c48..fbfd374aa336 100644 --- a/trunk/arch/i386/kernel/cpu/intel_cacheinfo.c +++ b/trunk/arch/i386/kernel/cpu/intel_cacheinfo.c @@ -43,23 +43,13 @@ static struct _cache_table cache_table[] __cpuinitdata = { 0x2c, LVL_1_DATA, 32 }, /* 8-way set assoc, 64 byte line size */ { 0x30, LVL_1_INST, 32 }, /* 8-way set assoc, 64 byte line size */ { 0x39, LVL_2, 128 }, /* 4-way set assoc, sectored cache, 64 byte line size */ - { 0x3a, LVL_2, 192 }, /* 6-way set assoc, sectored cache, 64 byte line size */ { 0x3b, LVL_2, 128 }, /* 2-way set assoc, sectored cache, 64 byte line size */ { 0x3c, LVL_2, 256 }, /* 4-way set assoc, sectored cache, 64 byte line size */ - { 0x3d, LVL_2, 384 }, /* 6-way set assoc, sectored cache, 64 byte line size */ - { 0x3e, LVL_2, 512 }, /* 4-way set assoc, sectored cache, 64 byte line size */ { 0x41, LVL_2, 128 }, /* 4-way set assoc, 32 byte line size */ { 0x42, LVL_2, 256 }, /* 4-way set assoc, 32 byte line size */ { 0x43, LVL_2, 512 }, /* 4-way set assoc, 32 byte line size */ { 0x44, LVL_2, 1024 }, /* 4-way set assoc, 32 byte line size */ { 0x45, LVL_2, 2048 }, /* 4-way set assoc, 32 byte line size */ - { 0x46, LVL_3, 4096 }, /* 4-way set assoc, 64 byte line size */ - { 0x47, LVL_3, 8192 }, /* 8-way set assoc, 64 byte line size */ - { 0x49, LVL_3, 4096 }, /* 16-way set assoc, 64 byte line size */ - { 0x4a, LVL_3, 6144 }, /* 12-way set assoc, 64 byte line size */ - { 0x4b, LVL_3, 8192 }, /* 16-way set assoc, 64 byte line size */ - { 0x4c, LVL_3, 12288 }, /* 12-way set assoc, 64 byte line size */ - { 0x4d, LVL_3, 16384 }, /* 16-way set assoc, 64 byte line size */ { 0x60, LVL_1_DATA, 16 }, /* 8-way set assoc, sectored cache, 64 byte line size */ { 0x66, LVL_1_DATA, 8 }, /* 4-way set assoc, sectored cache, 64 byte line size */ { 0x67, LVL_1_DATA, 16 }, /* 4-way set assoc, sectored cache, 64 byte line size */ @@ -67,7 +57,6 @@ static struct _cache_table cache_table[] __cpuinitdata = { 0x70, LVL_TRACE, 12 }, /* 8-way set assoc */ { 0x71, LVL_TRACE, 16 }, /* 8-way set assoc */ { 0x72, LVL_TRACE, 32 }, /* 8-way set assoc */ - { 0x73, LVL_TRACE, 64 }, /* 8-way set assoc */ { 0x78, LVL_2, 1024 }, /* 4-way set assoc, 64 byte line size */ { 0x79, LVL_2, 128 }, /* 8-way set assoc, sectored cache, 64 byte line size */ { 0x7a, LVL_2, 256 }, /* 8-way set assoc, sectored cache, 64 byte line size */ @@ -152,7 +141,6 @@ static int __cpuinit cpuid4_cache_lookup(int index, struct _cpuid4_info *this_le return 0; } -/* will only be called once; __init is safe here */ static int __init find_num_cache_leaves(void) { unsigned int eax, ebx, ecx, edx; diff --git a/trunk/arch/i386/kernel/cpu/mtrr/main.c b/trunk/arch/i386/kernel/cpu/mtrr/main.c index 3b4618bed70d..1e9db198c440 100644 --- a/trunk/arch/i386/kernel/cpu/mtrr/main.c +++ b/trunk/arch/i386/kernel/cpu/mtrr/main.c @@ -44,10 +44,12 @@ #include #include "mtrr.h" +#define MTRR_VERSION "2.0 (20020519)" + u32 num_var_ranges = 0; unsigned int *usage_table; -static DECLARE_MUTEX(mtrr_sem); +static DECLARE_MUTEX(main_lock); u32 size_or_mask, size_and_mask; @@ -333,7 +335,7 @@ int mtrr_add_page(unsigned long base, unsigned long size, /* No CPU hotplug when we change MTRR entries */ lock_cpu_hotplug(); /* Search for existing MTRR */ - down(&mtrr_sem); + down(&main_lock); for (i = 0; i < num_var_ranges; ++i) { mtrr_if->get(i, &lbase, &lsize, <ype); if (base >= lbase + lsize) @@ -371,7 +373,7 @@ int mtrr_add_page(unsigned long base, unsigned long size, printk(KERN_INFO "mtrr: no more MTRRs available\n"); error = i; out: - up(&mtrr_sem); + up(&main_lock); unlock_cpu_hotplug(); return error; } @@ -464,7 +466,7 @@ int mtrr_del_page(int reg, unsigned long base, unsigned long size) max = num_var_ranges; /* No CPU hotplug when we change MTRR entries */ lock_cpu_hotplug(); - down(&mtrr_sem); + down(&main_lock); if (reg < 0) { /* Search for existing MTRR */ for (i = 0; i < max; ++i) { @@ -503,7 +505,7 @@ int mtrr_del_page(int reg, unsigned long base, unsigned long size) set_mtrr(reg, 0, 0, 0); error = reg; out: - up(&mtrr_sem); + up(&main_lock); unlock_cpu_hotplug(); return error; } @@ -669,6 +671,7 @@ void __init mtrr_bp_init(void) break; } } + printk(KERN_INFO "mtrr: v%s\n",MTRR_VERSION); if (mtrr_if) { set_num_var_ranges(); @@ -685,7 +688,7 @@ void mtrr_ap_init(void) if (!mtrr_if || !use_intel()) return; /* - * Ideally we should hold mtrr_sem here to avoid mtrr entries changed, + * Ideally we should hold main_lock here to avoid mtrr entries changed, * but this routine will be called in cpu boot time, holding the lock * breaks it. This routine is called in two cases: 1.very earily time * of software resume, when there absolutely isn't mtrr entry changes; diff --git a/trunk/arch/i386/kernel/cpu/nexgen.c b/trunk/arch/i386/kernel/cpu/nexgen.c index ad87fa58058d..30898a260a5c 100644 --- a/trunk/arch/i386/kernel/cpu/nexgen.c +++ b/trunk/arch/i386/kernel/cpu/nexgen.c @@ -61,11 +61,3 @@ int __init nexgen_init_cpu(void) } //early_arch_initcall(nexgen_init_cpu); - -static int __init nexgen_exit_cpu(void) -{ - cpu_devs[X86_VENDOR_NEXGEN] = NULL; - return 0; -} - -late_initcall(nexgen_exit_cpu); diff --git a/trunk/arch/i386/kernel/cpu/rise.c b/trunk/arch/i386/kernel/cpu/rise.c index d08d5a2811c8..8602425628ca 100644 --- a/trunk/arch/i386/kernel/cpu/rise.c +++ b/trunk/arch/i386/kernel/cpu/rise.c @@ -51,11 +51,3 @@ int __init rise_init_cpu(void) } //early_arch_initcall(rise_init_cpu); - -static int __init rise_exit_cpu(void) -{ - cpu_devs[X86_VENDOR_RISE] = NULL; - return 0; -} - -late_initcall(rise_exit_cpu); diff --git a/trunk/arch/i386/kernel/cpu/transmeta.c b/trunk/arch/i386/kernel/cpu/transmeta.c index bdbeb77f4e22..fc426380366b 100644 --- a/trunk/arch/i386/kernel/cpu/transmeta.c +++ b/trunk/arch/i386/kernel/cpu/transmeta.c @@ -84,7 +84,7 @@ static void __init init_transmeta(struct cpuinfo_x86 *c) #endif } -static void __init transmeta_identify(struct cpuinfo_x86 * c) +static void transmeta_identify(struct cpuinfo_x86 * c) { u32 xlvl; generic_identify(c); @@ -111,11 +111,3 @@ int __init transmeta_init_cpu(void) } //early_arch_initcall(transmeta_init_cpu); - -static int __init transmeta_exit_cpu(void) -{ - cpu_devs[X86_VENDOR_TRANSMETA] = NULL; - return 0; -} - -late_initcall(transmeta_exit_cpu); diff --git a/trunk/arch/i386/kernel/cpu/umc.c b/trunk/arch/i386/kernel/cpu/umc.c index 2cd988f6dc55..264fcad559d5 100644 --- a/trunk/arch/i386/kernel/cpu/umc.c +++ b/trunk/arch/i386/kernel/cpu/umc.c @@ -31,11 +31,3 @@ int __init umc_init_cpu(void) } //early_arch_initcall(umc_init_cpu); - -static int __init umc_exit_cpu(void) -{ - cpu_devs[X86_VENDOR_UMC] = NULL; - return 0; -} - -late_initcall(umc_exit_cpu); diff --git a/trunk/arch/i386/kernel/head.S b/trunk/arch/i386/kernel/head.S index 2bee6499edd9..5884469f6bfe 100644 --- a/trunk/arch/i386/kernel/head.S +++ b/trunk/arch/i386/kernel/head.S @@ -398,11 +398,7 @@ ignore_int: pushl 32(%esp) pushl 40(%esp) pushl $int_msg -#ifdef CONFIG_EARLY_PRINTK - call early_printk -#else call printk -#endif addl $(5*4),%esp popl %ds popl %es diff --git a/trunk/arch/i386/kernel/mpparse.c b/trunk/arch/i386/kernel/mpparse.c index 0102f3d50e57..91a64016956e 100644 --- a/trunk/arch/i386/kernel/mpparse.c +++ b/trunk/arch/i386/kernel/mpparse.c @@ -1080,7 +1080,7 @@ void __init mp_config_acpi_legacy_irqs (void) #define MAX_GSI_NUM 4096 -int mp_register_gsi (u32 gsi, int triggering, int polarity) +int mp_register_gsi (u32 gsi, int edge_level, int active_high_low) { int ioapic = -1; int ioapic_pin = 0; @@ -1129,7 +1129,7 @@ int mp_register_gsi (u32 gsi, int triggering, int polarity) mp_ioapic_routing[ioapic].pin_programmed[idx] |= (1<xss,regs->esp); - printk(" EFLAGS: %08lx %s (%s %.*s)\n", - regs->eflags, print_tainted(), system_utsname.release, - (int)strcspn(system_utsname.version, " "), - system_utsname.version); + printk(" EFLAGS: %08lx %s (%s)\n", + regs->eflags, print_tainted(), system_utsname.release); printk("EAX: %08lx EBX: %08lx ECX: %08lx EDX: %08lx\n", regs->eax,regs->ebx,regs->ecx,regs->edx); printk("ESI: %08lx EDI: %08lx EBP: %08lx", diff --git a/trunk/arch/i386/kernel/quirks.c b/trunk/arch/i386/kernel/quirks.c index 87ccdac84928..aaf89cb2bc51 100644 --- a/trunk/arch/i386/kernel/quirks.c +++ b/trunk/arch/i386/kernel/quirks.c @@ -25,7 +25,8 @@ static void __devinit quirk_intel_irqbalance(struct pci_dev *dev) /* enable access to config space*/ pci_read_config_byte(dev, 0xf4, &config); - pci_write_config_byte(dev, 0xf4, config|0x2); + config |= 0x2; + pci_write_config_byte(dev, 0xf4, config); /* read xTPR register */ raw_pci_ops->read(0, 0, 0x40, 0x4c, 2, &word); @@ -41,9 +42,9 @@ static void __devinit quirk_intel_irqbalance(struct pci_dev *dev) #endif } - /* put back the original value for config space*/ - if (!(config & 0x2)) - pci_write_config_byte(dev, 0xf4, config); + config &= ~0x2; + /* disable access to config space*/ + pci_write_config_byte(dev, 0xf4, config); } DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_E7320_MCH, quirk_intel_irqbalance); DECLARE_PCI_FIXUP_FINAL(PCI_VENDOR_ID_INTEL, PCI_DEVICE_ID_INTEL_E7525_MCH, quirk_intel_irqbalance); diff --git a/trunk/arch/i386/kernel/signal.c b/trunk/arch/i386/kernel/signal.c index 963616d364ec..adcd069db91e 100644 --- a/trunk/arch/i386/kernel/signal.c +++ b/trunk/arch/i386/kernel/signal.c @@ -37,17 +37,51 @@ asmlinkage int sys_sigsuspend(int history0, int history1, old_sigset_t mask) { + struct pt_regs * regs = (struct pt_regs *) &history0; + sigset_t saveset; + mask &= _BLOCKABLE; spin_lock_irq(¤t->sighand->siglock); - current->saved_sigmask = current->blocked; + saveset = current->blocked; siginitset(¤t->blocked, mask); recalc_sigpending(); spin_unlock_irq(¤t->sighand->siglock); - current->state = TASK_INTERRUPTIBLE; - schedule(); - set_thread_flag(TIF_RESTORE_SIGMASK); - return -ERESTARTNOHAND; + regs->eax = -EINTR; + while (1) { + current->state = TASK_INTERRUPTIBLE; + schedule(); + if (do_signal(regs, &saveset)) + return -EINTR; + } +} + +asmlinkage int +sys_rt_sigsuspend(struct pt_regs regs) +{ + sigset_t saveset, newset; + + /* XXX: Don't preclude handling different sized sigset_t's. */ + if (regs.ecx != sizeof(sigset_t)) + return -EINVAL; + + if (copy_from_user(&newset, (sigset_t __user *)regs.ebx, sizeof(newset))) + return -EFAULT; + sigdelsetmask(&newset, ~_BLOCKABLE); + + spin_lock_irq(¤t->sighand->siglock); + saveset = current->blocked; + current->blocked = newset; + recalc_sigpending(); + spin_unlock_irq(¤t->sighand->siglock); + + regs.eax = -EINTR; + while (1) { + current->state = TASK_INTERRUPTIBLE; + schedule(); + if (do_signal(®s, &saveset)) + return -EINTR; + } } asmlinkage int @@ -399,11 +433,11 @@ static int setup_frame(int sig, struct k_sigaction *ka, current->comm, current->pid, frame, regs->eip, frame->pretcode); #endif - return 0; + return 1; give_sigsegv: force_sigsegv(sig, current); - return -EFAULT; + return 0; } static int setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info, @@ -493,11 +527,11 @@ static int setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info, current->comm, current->pid, frame, regs->eip, frame->pretcode); #endif - return 0; + return 1; give_sigsegv: force_sigsegv(sig, current); - return -EFAULT; + return 0; } /* @@ -547,7 +581,7 @@ handle_signal(unsigned long sig, siginfo_t *info, struct k_sigaction *ka, else ret = setup_frame(sig, ka, oldset, regs); - if (ret == 0) { + if (ret) { spin_lock_irq(¤t->sighand->siglock); sigorsets(¤t->blocked,¤t->blocked,&ka->sa.sa_mask); if (!(ka->sa.sa_flags & SA_NODEFER)) @@ -564,12 +598,11 @@ handle_signal(unsigned long sig, siginfo_t *info, struct k_sigaction *ka, * want to handle. Thus you cannot kill init even with a SIGKILL even by * mistake. */ -static void fastcall do_signal(struct pt_regs *regs) +int fastcall do_signal(struct pt_regs *regs, sigset_t *oldset) { siginfo_t info; int signr; struct k_sigaction ka; - sigset_t *oldset; /* * We want the common case to go fast, which @@ -580,14 +613,12 @@ static void fastcall do_signal(struct pt_regs *regs) * CS suffices. */ if (!user_mode(regs)) - return; + return 1; if (try_to_freeze()) goto no_signal; - if (test_thread_flag(TIF_RESTORE_SIGMASK)) - oldset = ¤t->saved_sigmask; - else + if (!oldset) oldset = ¤t->blocked; signr = get_signal_to_deliver(&info, &ka, regs, NULL); @@ -597,55 +628,38 @@ static void fastcall do_signal(struct pt_regs *regs) * have been cleared if the watchpoint triggered * inside the kernel. */ - if (unlikely(current->thread.debugreg[7])) + if (unlikely(current->thread.debugreg[7])) { set_debugreg(current->thread.debugreg[7], 7); - - /* Whee! Actually deliver the signal. */ - if (handle_signal(signr, &info, &ka, oldset, regs) == 0) { - /* a signal was successfully delivered; the saved - * sigmask will have been stored in the signal frame, - * and will be restored by sigreturn, so we can simply - * clear the TIF_RESTORE_SIGMASK flag */ - if (test_thread_flag(TIF_RESTORE_SIGMASK)) - clear_thread_flag(TIF_RESTORE_SIGMASK); } - return; + /* Whee! Actually deliver the signal. */ + return handle_signal(signr, &info, &ka, oldset, regs); } -no_signal: + no_signal: /* Did we come from a system call? */ if (regs->orig_eax >= 0) { /* Restart the system call - no handlers present */ - switch (regs->eax) { - case -ERESTARTNOHAND: - case -ERESTARTSYS: - case -ERESTARTNOINTR: + if (regs->eax == -ERESTARTNOHAND || + regs->eax == -ERESTARTSYS || + regs->eax == -ERESTARTNOINTR) { regs->eax = regs->orig_eax; regs->eip -= 2; - break; - - case -ERESTART_RESTARTBLOCK: + } + if (regs->eax == -ERESTART_RESTARTBLOCK){ regs->eax = __NR_restart_syscall; regs->eip -= 2; - break; } } - - /* if there's no signal to deliver, we just put the saved sigmask - * back */ - if (test_thread_flag(TIF_RESTORE_SIGMASK)) { - clear_thread_flag(TIF_RESTORE_SIGMASK); - sigprocmask(SIG_SETMASK, ¤t->saved_sigmask, NULL); - } + return 0; } /* * notification of userspace execution resumption - * - triggered by the TIF_WORK_MASK flags + * - triggered by current->work.notify_resume */ __attribute__((regparm(3))) -void do_notify_resume(struct pt_regs *regs, void *_unused, +void do_notify_resume(struct pt_regs *regs, sigset_t *oldset, __u32 thread_info_flags) { /* Pending single-step? */ @@ -653,10 +667,9 @@ void do_notify_resume(struct pt_regs *regs, void *_unused, regs->eflags |= TF_MASK; clear_thread_flag(TIF_SINGLESTEP); } - /* deal with pending signal delivery */ - if (thread_info_flags & (_TIF_SIGPENDING | _TIF_RESTORE_SIGMASK)) - do_signal(regs); + if (thread_info_flags & _TIF_SIGPENDING) + do_signal(regs,oldset); clear_thread_flag(TIF_IRET); } diff --git a/trunk/arch/i386/kernel/smpboot.c b/trunk/arch/i386/kernel/smpboot.c index fb00ab7b7612..255adb498268 100644 --- a/trunk/arch/i386/kernel/smpboot.c +++ b/trunk/arch/i386/kernel/smpboot.c @@ -87,7 +87,11 @@ EXPORT_SYMBOL(cpu_online_map); cpumask_t cpu_callin_map; cpumask_t cpu_callout_map; EXPORT_SYMBOL(cpu_callout_map); +#ifdef CONFIG_HOTPLUG_CPU +cpumask_t cpu_possible_map = CPU_MASK_ALL; +#else cpumask_t cpu_possible_map; +#endif EXPORT_SYMBOL(cpu_possible_map); static cpumask_t smp_commenced_mask; diff --git a/trunk/arch/i386/kernel/syscall_table.S b/trunk/arch/i386/kernel/syscall_table.S index ac687d00a1ce..6ff3e5243226 100644 --- a/trunk/arch/i386/kernel/syscall_table.S +++ b/trunk/arch/i386/kernel/syscall_table.S @@ -294,19 +294,3 @@ ENTRY(sys_call_table) .long sys_inotify_add_watch .long sys_inotify_rm_watch .long sys_migrate_pages - .long sys_openat /* 295 */ - .long sys_mkdirat - .long sys_mknodat - .long sys_fchownat - .long sys_futimesat - .long sys_fstatat64 /* 300 */ - .long sys_unlinkat - .long sys_renameat - .long sys_linkat - .long sys_symlinkat - .long sys_readlinkat /* 305 */ - .long sys_fchmodat - .long sys_faccessat - .long sys_pselect6 - .long sys_ppoll - .long sys_unshare /* 310 */ diff --git a/trunk/arch/i386/kernel/timers/timer_tsc.c b/trunk/arch/i386/kernel/timers/timer_tsc.c index 7c86e3c5f1c1..47675bbbb316 100644 --- a/trunk/arch/i386/kernel/timers/timer_tsc.c +++ b/trunk/arch/i386/kernel/timers/timer_tsc.c @@ -45,15 +45,6 @@ static unsigned long last_tsc_high; /* msb 32 bits of Time Stamp Counter */ static unsigned long long monotonic_base; static seqlock_t monotonic_lock = SEQLOCK_UNLOCKED; -/* Avoid compensating for lost ticks before TSCs are synched */ -static int detect_lost_ticks; -static int __init start_lost_tick_compensation(void) -{ - detect_lost_ticks = 1; - return 0; -} -late_initcall(start_lost_tick_compensation); - /* convert from cycles(64bits) => nanoseconds (64bits) * basic equation: * ns = cycles / (freq / ns_per_sec) @@ -205,8 +196,7 @@ static void mark_offset_tsc_hpet(void) /* lost tick compensation */ offset = hpet_readl(HPET_T0_CMP) - hpet_tick; - if (unlikely(((offset - hpet_last) > hpet_tick) && (hpet_last != 0)) - && detect_lost_ticks) { + if (unlikely(((offset - hpet_last) > hpet_tick) && (hpet_last != 0))) { int lost_ticks = (offset - hpet_last) / hpet_tick; jiffies_64 += lost_ticks; } @@ -431,7 +421,7 @@ static void mark_offset_tsc(void) delta += delay_at_last_interrupt; lost = delta/(1000000/HZ); delay = delta%(1000000/HZ); - if (lost >= 2 && detect_lost_ticks) { + if (lost >= 2) { jiffies_64 += lost-1; /* sanity check to ensure we're not always losing ticks */ diff --git a/trunk/arch/i386/kernel/traps.c b/trunk/arch/i386/kernel/traps.c index b814dbdcc91e..0aaebf3e1cfa 100644 --- a/trunk/arch/i386/kernel/traps.c +++ b/trunk/arch/i386/kernel/traps.c @@ -166,8 +166,7 @@ static void show_trace_log_lvl(struct task_struct *task, stack = (unsigned long*)context->previous_esp; if (!stack) break; - printk(log_lvl); - printk(" =======================\n"); + printk(KERN_EMERG " =======================\n"); } } @@ -240,11 +239,9 @@ void show_registers(struct pt_regs *regs) } print_modules(); printk(KERN_EMERG "CPU: %d\nEIP: %04x:[<%08lx>] %s VLI\n" - "EFLAGS: %08lx (%s %.*s) \n", + "EFLAGS: %08lx (%s) \n", smp_processor_id(), 0xffff & regs->xcs, regs->eip, - print_tainted(), regs->eflags, system_utsname.release, - (int)strcspn(system_utsname.version, " "), - system_utsname.version); + print_tainted(), regs->eflags, system_utsname.release); print_symbol(KERN_EMERG "EIP is at %s\n", regs->eip); printk(KERN_EMERG "eax: %08lx ebx: %08lx ecx: %08lx edx: %08lx\n", regs->eax, regs->ebx, regs->ecx, regs->edx); diff --git a/trunk/arch/i386/mach-voyager/voyager_smp.c b/trunk/arch/i386/mach-voyager/voyager_smp.c index 6e4c3baef6cc..72a1b9cae2e4 100644 --- a/trunk/arch/i386/mach-voyager/voyager_smp.c +++ b/trunk/arch/i386/mach-voyager/voyager_smp.c @@ -240,7 +240,7 @@ static cpumask_t smp_commenced_mask = CPU_MASK_NONE; cpumask_t cpu_callin_map = CPU_MASK_NONE; cpumask_t cpu_callout_map = CPU_MASK_NONE; EXPORT_SYMBOL(cpu_callout_map); -cpumask_t cpu_possible_map = CPU_MASK_NONE; +cpumask_t cpu_possible_map = CPU_MASK_ALL; EXPORT_SYMBOL(cpu_possible_map); /* The per processor IRQ masks (these are usually kept in sync) */ diff --git a/trunk/arch/i386/oprofile/backtrace.c b/trunk/arch/i386/oprofile/backtrace.c index acc18138fb22..21654be3f73f 100644 --- a/trunk/arch/i386/oprofile/backtrace.c +++ b/trunk/arch/i386/oprofile/backtrace.c @@ -49,9 +49,7 @@ dump_backtrace(struct frame_head * head) * | stack | * --------------- saved regs->ebp value if valid (frame_head address) * . . - * --------------- saved regs->rsp value if x86_64 - * | | - * --------------- struct pt_regs * stored on stack if 32-bit + * --------------- struct pt_regs stored on stack (struct pt_regs *) * | | * . . * | | @@ -59,26 +57,13 @@ dump_backtrace(struct frame_head * head) * | | * | | \/ Lower addresses * - * Thus, regs (or regs->rsp for x86_64) <-> stack base restricts the - * valid(ish) ebp values. Note: (1) for x86_64, NMI and several other - * exceptions use special stacks, maintained by the interrupt stack table - * (IST). These stacks are set up in trap_init() in - * arch/x86_64/kernel/traps.c. Thus, for x86_64, regs now does not point - * to the kernel stack; instead, it points to some location on the NMI - * stack. On the other hand, regs->rsp is the stack pointer saved when the - * NMI occurred. (2) For 32-bit, regs->esp is not valid because the - * processor does not save %esp on the kernel stack when interrupts occur - * in the kernel mode. + * Thus, &pt_regs <-> stack base restricts the valid(ish) ebp values */ #ifdef CONFIG_FRAME_POINTER static int valid_kernel_stack(struct frame_head * head, struct pt_regs * regs) { unsigned long headaddr = (unsigned long)head; -#ifdef CONFIG_X86_64 - unsigned long stack = (unsigned long)regs->rsp; -#else unsigned long stack = (unsigned long)regs; -#endif unsigned long stack_base = (stack & ~(THREAD_SIZE - 1)) + THREAD_SIZE; return headaddr > stack && headaddr < stack_base; diff --git a/trunk/arch/i386/pci/irq.c b/trunk/arch/i386/pci/irq.c index 3ca59cad05f3..e715aa930036 100644 --- a/trunk/arch/i386/pci/irq.c +++ b/trunk/arch/i386/pci/irq.c @@ -539,11 +539,6 @@ static __init int intel_router_probe(struct irq_router *r, struct pci_dev *route case PCI_DEVICE_ID_INTEL_ICH7_30: case PCI_DEVICE_ID_INTEL_ICH7_31: case PCI_DEVICE_ID_INTEL_ESB2_0: - case PCI_DEVICE_ID_INTEL_ICH8_0: - case PCI_DEVICE_ID_INTEL_ICH8_1: - case PCI_DEVICE_ID_INTEL_ICH8_2: - case PCI_DEVICE_ID_INTEL_ICH8_3: - case PCI_DEVICE_ID_INTEL_ICH8_4: r->name = "PIIX/ICH"; r->get = pirq_piix_get; r->set = pirq_piix_set; diff --git a/trunk/arch/i386/pci/mmconfig.c b/trunk/arch/i386/pci/mmconfig.c index 0ee8a983708c..4bb4d4b0f73a 100644 --- a/trunk/arch/i386/pci/mmconfig.c +++ b/trunk/arch/i386/pci/mmconfig.c @@ -36,7 +36,8 @@ static u32 get_base_addr(unsigned int seg, int bus, unsigned devfn) while (1) { ++cfg_num; if (cfg_num >= pci_mmcfg_config_num) { - break; + /* Not found - fallback to type 1 */ + return 0; } cfg = &pci_mmcfg_config[cfg_num]; if (cfg->pci_segment_group_number != seg) @@ -45,18 +46,6 @@ static u32 get_base_addr(unsigned int seg, int bus, unsigned devfn) (cfg->end_bus_number >= bus)) return cfg->base_address; } - - /* Handle more broken MCFG tables on Asus etc. - They only contain a single entry for bus 0-0. Assume - this applies to all busses. */ - cfg = &pci_mmcfg_config[0]; - if (pci_mmcfg_config_num == 1 && - cfg->pci_segment_group_number == 0 && - (cfg->start_bus_number | cfg->end_bus_number) == 0) - return cfg->base_address; - - /* Fall back to type 0 */ - return 0; } static inline void pci_exp_set_dev_base(unsigned int base, int bus, int devfn) diff --git a/trunk/arch/ia64/Kconfig b/trunk/arch/ia64/Kconfig index 845cd0902a50..199eeaf0f4e3 100644 --- a/trunk/arch/ia64/Kconfig +++ b/trunk/arch/ia64/Kconfig @@ -194,6 +194,7 @@ config IA64_L1_CACHE_SHIFT default "7" if MCKINLEY default "6" if ITANIUM +# align cache-sensitive data to 64 bytes config IA64_CYCLONE bool "Cyclone (EXA) Time Source support" help @@ -373,9 +374,6 @@ config IA64_PALINFO To use this option, you have to ensure that the "/proc file system support" (CONFIG_PROC_FS) is enabled, too. -config SGI_SN - def_bool y if (IA64_SGI_SN2 || IA64_GENERIC) - source "drivers/firmware/Kconfig" source "fs/Kconfig.binfmt" diff --git a/trunk/arch/ia64/configs/gensparse_defconfig b/trunk/arch/ia64/configs/gensparse_defconfig index 991c07b57c24..1d07d8072ec2 100644 --- a/trunk/arch/ia64/configs/gensparse_defconfig +++ b/trunk/arch/ia64/configs/gensparse_defconfig @@ -557,7 +557,6 @@ CONFIG_E100=m # CONFIG_DL2K is not set CONFIG_E1000=y # CONFIG_E1000_NAPI is not set -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/ia64/configs/tiger_defconfig b/trunk/arch/ia64/configs/tiger_defconfig index 6859119bc9dd..b1e8f09e9fd5 100644 --- a/trunk/arch/ia64/configs/tiger_defconfig +++ b/trunk/arch/ia64/configs/tiger_defconfig @@ -565,7 +565,6 @@ CONFIG_E100=m # CONFIG_DL2K is not set CONFIG_E1000=y # CONFIG_E1000_NAPI is not set -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/ia64/configs/zx1_defconfig b/trunk/arch/ia64/configs/zx1_defconfig index 53899dc8eb53..0856ca67dd50 100644 --- a/trunk/arch/ia64/configs/zx1_defconfig +++ b/trunk/arch/ia64/configs/zx1_defconfig @@ -548,7 +548,6 @@ CONFIG_E100=y # CONFIG_DL2K is not set CONFIG_E1000=y # CONFIG_E1000_NAPI is not set -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/ia64/defconfig b/trunk/arch/ia64/defconfig index dcbc78a4cfa4..275a26c6e5aa 100644 --- a/trunk/arch/ia64/defconfig +++ b/trunk/arch/ia64/defconfig @@ -565,7 +565,6 @@ CONFIG_E100=m # CONFIG_DL2K is not set CONFIG_E1000=y # CONFIG_E1000_NAPI is not set -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/ia64/dig/setup.c b/trunk/arch/ia64/dig/setup.c index c9104bfff667..d58003f1ad02 100644 --- a/trunk/arch/ia64/dig/setup.c +++ b/trunk/arch/ia64/dig/setup.c @@ -25,6 +25,16 @@ #include #include +/* + * This is here so we can use the CMOS detection in ide-probe.c to + * determine what drives are present. In theory, we don't need this + * as the auto-detection could be done via ide-probe.c:do_probe() but + * in practice that would be much slower, which is painful when + * running in the simulator. Note that passing zeroes in DRIVE_INFO + * is sufficient (the IDE driver will autodetect the drive geometry). + */ +char drive_info[4*16]; + void __init dig_setup (char **cmdline_p) { diff --git a/trunk/arch/ia64/ia32/ia32_signal.c b/trunk/arch/ia64/ia32/ia32_signal.c index b3355a9ca2c3..5856510210fa 100644 --- a/trunk/arch/ia64/ia32/ia32_signal.c +++ b/trunk/arch/ia64/ia32/ia32_signal.c @@ -515,7 +515,6 @@ sys32_signal (int sig, unsigned int handler) sigact_set_handler(&new_sa, handler, 0); new_sa.sa.sa_flags = SA_ONESHOT | SA_NOMASK; - sigemptyset(&new_sa.sa.sa_mask); ret = do_sigaction(sig, &new_sa, &old_sa); diff --git a/trunk/arch/ia64/ia32/sys_ia32.c b/trunk/arch/ia64/ia32/sys_ia32.c index 70dba1f0e2ee..3945d378bd7e 100644 --- a/trunk/arch/ia64/ia32/sys_ia32.c +++ b/trunk/arch/ia64/ia32/sys_ia32.c @@ -52,9 +52,9 @@ #include #include #include -#include #include +#include #include #include #include @@ -86,7 +86,7 @@ * while doing so. */ /* XXX make per-mm: */ -static DEFINE_MUTEX(ia32_mmap_mutex); +static DECLARE_MUTEX(ia32_mmap_sem); asmlinkage long sys32_execve (char __user *name, compat_uptr_t __user *argv, compat_uptr_t __user *envp, @@ -895,11 +895,11 @@ ia32_do_mmap (struct file *file, unsigned long addr, unsigned long len, int prot prot = get_prot32(prot); #if PAGE_SHIFT > IA32_PAGE_SHIFT - mutex_lock(&ia32_mmap_mutex); + down(&ia32_mmap_sem); { addr = emulate_mmap(file, addr, len, prot, flags, offset); } - mutex_unlock(&ia32_mmap_mutex); + up(&ia32_mmap_sem); #else down_write(¤t->mm->mmap_sem); { @@ -1000,9 +1000,11 @@ sys32_munmap (unsigned int start, unsigned int len) if (start >= end) return 0; - mutex_lock(&ia32_mmap_mutex); - ret = sys_munmap(start, end - start); - mutex_unlock(&ia32_mmap_mutex); + down(&ia32_mmap_sem); + { + ret = sys_munmap(start, end - start); + } + up(&ia32_mmap_sem); #endif return ret; } @@ -1054,7 +1056,7 @@ sys32_mprotect (unsigned int start, unsigned int len, int prot) if (retval < 0) return retval; - mutex_lock(&ia32_mmap_mutex); + down(&ia32_mmap_sem); { if (offset_in_page(start)) { /* start address is 4KB aligned but not page aligned. */ @@ -1078,7 +1080,7 @@ sys32_mprotect (unsigned int start, unsigned int len, int prot) retval = sys_mprotect(start, end - start, prot); } out: - mutex_unlock(&ia32_mmap_mutex); + up(&ia32_mmap_sem); return retval; #endif } @@ -1122,9 +1124,11 @@ sys32_mremap (unsigned int addr, unsigned int old_len, unsigned int new_len, old_len = PAGE_ALIGN(old_end) - addr; new_len = PAGE_ALIGN(new_end) - addr; - mutex_lock(&ia32_mmap_mutex); - ret = sys_mremap(addr, old_len, new_len, flags, new_addr); - mutex_unlock(&ia32_mmap_mutex); + down(&ia32_mmap_sem); + { + ret = sys_mremap(addr, old_len, new_len, flags, new_addr); + } + up(&ia32_mmap_sem); if ((ret >= 0) && (old_len < new_len)) { /* mremap expanded successfully */ diff --git a/trunk/arch/ia64/kernel/Makefile b/trunk/arch/ia64/kernel/Makefile index 09a0dbc17fb6..307514f7a282 100644 --- a/trunk/arch/ia64/kernel/Makefile +++ b/trunk/arch/ia64/kernel/Makefile @@ -13,11 +13,6 @@ obj-$(CONFIG_IA64_BRL_EMU) += brl_emu.o obj-$(CONFIG_IA64_GENERIC) += acpi-ext.o obj-$(CONFIG_IA64_HP_ZX1) += acpi-ext.o obj-$(CONFIG_IA64_HP_ZX1_SWIOTLB) += acpi-ext.o - -ifneq ($(CONFIG_ACPI_PROCESSOR),) -obj-y += acpi-processor.o -endif - obj-$(CONFIG_IA64_PALINFO) += palinfo.o obj-$(CONFIG_IOSAPIC) += iosapic.o obj-$(CONFIG_MODULES) += module.o diff --git a/trunk/arch/ia64/kernel/acpi-ext.c b/trunk/arch/ia64/kernel/acpi-ext.c index 4a5574ff007b..13a5b3b49bf8 100644 --- a/trunk/arch/ia64/kernel/acpi-ext.c +++ b/trunk/arch/ia64/kernel/acpi-ext.c @@ -33,33 +33,33 @@ acpi_vendor_resource_match(struct acpi_resource *resource, void *context) struct acpi_vendor_info *info = (struct acpi_vendor_info *)context; struct acpi_resource_vendor *vendor; struct acpi_vendor_descriptor *descriptor; - u32 byte_length; + u32 length; - if (resource->type != ACPI_RESOURCE_TYPE_VENDOR) + if (resource->id != ACPI_RSTYPE_VENDOR) return AE_OK; vendor = (struct acpi_resource_vendor *)&resource->data; - descriptor = (struct acpi_vendor_descriptor *)vendor->byte_data; - if (vendor->byte_length <= sizeof(*info->descriptor) || + descriptor = (struct acpi_vendor_descriptor *)vendor->reserved; + if (vendor->length <= sizeof(*info->descriptor) || descriptor->guid_id != info->descriptor->guid_id || efi_guidcmp(descriptor->guid, info->descriptor->guid)) return AE_OK; - byte_length = vendor->byte_length - sizeof(struct acpi_vendor_descriptor); - info->data = acpi_os_allocate(byte_length); + length = vendor->length - sizeof(struct acpi_vendor_descriptor); + info->data = acpi_os_allocate(length); if (!info->data) return AE_NO_MEMORY; memcpy(info->data, - vendor->byte_data + sizeof(struct acpi_vendor_descriptor), - byte_length); - info->length = byte_length; + vendor->reserved + sizeof(struct acpi_vendor_descriptor), + length); + info->length = length; return AE_CTRL_TERMINATE; } acpi_status acpi_find_vendor_resource(acpi_handle obj, struct acpi_vendor_descriptor * id, - u8 ** data, u32 * byte_length) + u8 ** data, u32 * length) { struct acpi_vendor_info info; @@ -72,7 +72,7 @@ acpi_find_vendor_resource(acpi_handle obj, struct acpi_vendor_descriptor * id, return AE_NOT_FOUND; *data = info.data; - *byte_length = info.length; + *length = info.length; return AE_OK; } diff --git a/trunk/arch/ia64/kernel/acpi-processor.c b/trunk/arch/ia64/kernel/acpi-processor.c deleted file mode 100644 index e683630c8ce2..000000000000 --- a/trunk/arch/ia64/kernel/acpi-processor.c +++ /dev/null @@ -1,67 +0,0 @@ -/* - * arch/ia64/kernel/cpufreq/processor.c - * - * Copyright (C) 2005 Intel Corporation - * Venkatesh Pallipadi - * - Added _PDC for platforms with Intel CPUs - */ - -#include -#include -#include -#include - -#include -#include - -static void init_intel_pdc(struct acpi_processor *pr) -{ - struct acpi_object_list *obj_list; - union acpi_object *obj; - u32 *buf; - - /* allocate and initialize pdc. It will be used later. */ - obj_list = kmalloc(sizeof(struct acpi_object_list), GFP_KERNEL); - if (!obj_list) { - printk(KERN_ERR "Memory allocation error\n"); - return; - } - - obj = kmalloc(sizeof(union acpi_object), GFP_KERNEL); - if (!obj) { - printk(KERN_ERR "Memory allocation error\n"); - kfree(obj_list); - return; - } - - buf = kmalloc(12, GFP_KERNEL); - if (!buf) { - printk(KERN_ERR "Memory allocation error\n"); - kfree(obj); - kfree(obj_list); - return; - } - - buf[0] = ACPI_PDC_REVISION_ID; - buf[1] = 1; - buf[2] |= ACPI_PDC_EST_CAPABILITY_SMP; - - obj->type = ACPI_TYPE_BUFFER; - obj->buffer.length = 12; - obj->buffer.pointer = (u8 *) buf; - obj_list->count = 1; - obj_list->pointer = obj; - pr->pdc = obj_list; - - return; -} - -/* Initialize _PDC data based on the CPU vendor */ -void arch_acpi_processor_init_pdc(struct acpi_processor *pr) -{ - pr->pdc = NULL; - init_intel_pdc(pr); - return; -} - -EXPORT_SYMBOL(arch_acpi_processor_init_pdc); diff --git a/trunk/arch/ia64/kernel/acpi.c b/trunk/arch/ia64/kernel/acpi.c index d2702c419cf8..9ad94ddf6687 100644 --- a/trunk/arch/ia64/kernel/acpi.c +++ b/trunk/arch/ia64/kernel/acpi.c @@ -567,16 +567,16 @@ void __init acpi_numa_arch_fixup(void) * success: return IRQ number (>=0) * failure: return < 0 */ -int acpi_register_gsi(u32 gsi, int triggering, int polarity) +int acpi_register_gsi(u32 gsi, int edge_level, int active_high_low) { if (has_8259 && gsi < 16) return isa_irq_to_vector(gsi); return iosapic_register_intr(gsi, - (polarity == + (active_high_low == ACPI_ACTIVE_HIGH) ? IOSAPIC_POL_HIGH : IOSAPIC_POL_LOW, - (triggering == + (edge_level == ACPI_EDGE_SENSITIVE) ? IOSAPIC_EDGE : IOSAPIC_LEVEL); } diff --git a/trunk/arch/ia64/kernel/cpufreq/Makefile b/trunk/arch/ia64/kernel/cpufreq/Makefile index 4838f2a57c7a..f748d34c02f0 100644 --- a/trunk/arch/ia64/kernel/cpufreq/Makefile +++ b/trunk/arch/ia64/kernel/cpufreq/Makefile @@ -1,2 +1 @@ obj-$(CONFIG_IA64_ACPI_CPUFREQ) += acpi-cpufreq.o - diff --git a/trunk/arch/ia64/kernel/cpufreq/acpi-cpufreq.c b/trunk/arch/ia64/kernel/cpufreq/acpi-cpufreq.c index 5a1bf815282d..da4d5cf80a48 100644 --- a/trunk/arch/ia64/kernel/cpufreq/acpi-cpufreq.c +++ b/trunk/arch/ia64/kernel/cpufreq/acpi-cpufreq.c @@ -269,6 +269,48 @@ acpi_cpufreq_verify ( } +/* + * processor_init_pdc - let BIOS know about the SMP capabilities + * of this driver + * @perf: processor-specific acpi_io_data struct + * @cpu: CPU being initialized + * + * To avoid issues with legacy OSes, some BIOSes require to be informed of + * the SMP capabilities of OS P-state driver. Here we set the bits in _PDC + * accordingly. Actual call to _PDC is done in driver/acpi/processor.c + */ +static void +processor_init_pdc ( + struct acpi_processor_performance *perf, + unsigned int cpu, + struct acpi_object_list *obj_list + ) +{ + union acpi_object *obj; + u32 *buf; + + dprintk("processor_init_pdc\n"); + + perf->pdc = NULL; + /* Initialize pdc. It will be used later. */ + if (!obj_list) + return; + + if (!(obj_list->count && obj_list->pointer)) + return; + + obj = obj_list->pointer; + if ((obj->buffer.length == 12) && obj->buffer.pointer) { + buf = (u32 *)obj->buffer.pointer; + buf[0] = ACPI_PDC_REVISION_ID; + buf[1] = 1; + buf[2] = ACPI_PDC_EST_CAPABILITY_SMP; + perf->pdc = obj_list; + } + return; +} + + static int acpi_cpufreq_cpu_init ( struct cpufreq_policy *policy) @@ -278,7 +320,14 @@ acpi_cpufreq_cpu_init ( struct cpufreq_acpi_io *data; unsigned int result = 0; + union acpi_object arg0 = {ACPI_TYPE_BUFFER}; + u32 arg0_buf[3]; + struct acpi_object_list arg_list = {1, &arg0}; + dprintk("acpi_cpufreq_cpu_init\n"); + /* setup arg_list for _PDC settings */ + arg0.buffer.length = 12; + arg0.buffer.pointer = (u8 *) arg0_buf; data = kmalloc(sizeof(struct cpufreq_acpi_io), GFP_KERNEL); if (!data) @@ -288,7 +337,9 @@ acpi_cpufreq_cpu_init ( acpi_io_data[cpu] = data; + processor_init_pdc(&data->acpi_data, cpu, &arg_list); result = acpi_processor_register_performance(&data->acpi_data, cpu); + data->acpi_data.pdc = NULL; if (result) goto err_free; diff --git a/trunk/arch/ia64/kernel/efi.c b/trunk/arch/ia64/kernel/efi.c index 9990320b6f9a..c485a3b32ba8 100644 --- a/trunk/arch/ia64/kernel/efi.c +++ b/trunk/arch/ia64/kernel/efi.c @@ -410,16 +410,24 @@ efi_init (void) efi_config_table_t *config_tables; efi_char16_t *c16; u64 efi_desc_size; - char *cp, vendor[100] = "unknown"; + char *cp, *end, vendor[100] = "unknown"; extern char saved_command_line[]; int i; /* it's too early to be able to use the standard kernel command line support... */ for (cp = saved_command_line; *cp; ) { if (memcmp(cp, "mem=", 4) == 0) { - mem_limit = memparse(cp + 4, &cp); + cp += 4; + mem_limit = memparse(cp, &end); + if (end != cp) + break; + cp = end; } else if (memcmp(cp, "max_addr=", 9) == 0) { - max_addr = GRANULEROUNDDOWN(memparse(cp + 9, &cp)); + cp += 9; + max_addr = GRANULEROUNDDOWN(memparse(cp, &end)); + if (end != cp) + break; + cp = end; } else { while (*cp != ' ' && *cp) ++cp; @@ -450,7 +458,7 @@ efi_init (void) /* Show what we know for posterity */ c16 = __va(efi.systab->fw_vendor); if (c16) { - for (i = 0;i < (int) sizeof(vendor) - 1 && *c16; ++i) + for (i = 0;i < (int) sizeof(vendor) && *c16; ++i) vendor[i] = *c16++; vendor[i] = '\0'; } diff --git a/trunk/arch/ia64/kernel/entry.S b/trunk/arch/ia64/kernel/entry.S index 27b222c277e4..7a6ffd613789 100644 --- a/trunk/arch/ia64/kernel/entry.S +++ b/trunk/arch/ia64/kernel/entry.S @@ -1601,21 +1601,5 @@ sys_call_table: data8 sys_inotify_add_watch data8 sys_inotify_rm_watch data8 sys_migrate_pages // 1280 - data8 sys_openat - data8 sys_mkdirat - data8 sys_mknodat - data8 sys_fchownat - data8 sys_futimesat // 1285 - data8 sys_newfstatat - data8 sys_unlinkat - data8 sys_renameat - data8 sys_linkat - data8 sys_symlinkat // 1290 - data8 sys_readlinkat - data8 sys_fchmodat - data8 sys_faccessat - data8 sys_ni_syscall // reserved for pselect - data8 sys_ni_syscall // 1295 reserved for ppoll - data8 sys_unshare .org sys_call_table + 8*NR_syscalls // guard against failures to increase NR_syscalls diff --git a/trunk/arch/ia64/kernel/fsys.S b/trunk/arch/ia64/kernel/fsys.S index ac6055c83115..ce423910ca97 100644 --- a/trunk/arch/ia64/kernel/fsys.S +++ b/trunk/arch/ia64/kernel/fsys.S @@ -878,8 +878,31 @@ fsyscall_table: data8 0 // timer_delete data8 0 // clock_settime data8 fsys_clock_gettime // clock_gettime - #define __NR_syscall_last 1255 - - .space 8*(NR_syscalls + 1024 - __NR_syscall_last), 0 + data8 0 // clock_getres // 1255 + data8 0 // clock_nanosleep + data8 0 // fstatfs64 + data8 0 // statfs64 + data8 0 + data8 0 // 1260 + data8 0 + data8 0 // mq_open + data8 0 // mq_unlink + data8 0 // mq_timedsend + data8 0 // mq_timedreceive // 1265 + data8 0 // mq_notify + data8 0 // mq_getsetattr + data8 0 // kexec_load + data8 0 + data8 0 // 1270 + data8 0 + data8 0 + data8 0 + data8 0 + data8 0 // 1275 + data8 0 + data8 0 + data8 0 + data8 0 + data8 0 // 1280 .org fsyscall_table + 8*NR_syscalls // guard against failures to increase NR_syscalls diff --git a/trunk/arch/ia64/kernel/head.S b/trunk/arch/ia64/kernel/head.S index f1778a84ea61..fbc7ea35dd57 100644 --- a/trunk/arch/ia64/kernel/head.S +++ b/trunk/arch/ia64/kernel/head.S @@ -352,7 +352,6 @@ start_ap: mov ar.rsc=0 // place RSE in enforced lazy mode ;; loadrs // clear the dirty partition - mov IA64_KR(PER_CPU_DATA)=r0 // clear physical per-CPU base ;; mov ar.bspstore=r2 // establish the new RSE stack ;; diff --git a/trunk/arch/ia64/kernel/mca_asm.S b/trunk/arch/ia64/kernel/mca_asm.S index 60a464bfd9e2..403a80a58c13 100644 --- a/trunk/arch/ia64/kernel/mca_asm.S +++ b/trunk/arch/ia64/kernel/mca_asm.S @@ -512,7 +512,7 @@ ia64_state_save: st8 [temp1]=r12 // os_status, default is cold boot mov r6=IA64_MCA_SAME_CONTEXT ;; - st8 [temp2]=r6 // context, default is same context + st8 [temp1]=r6 // context, default is same context // Save the pt_regs data that is not in minstate. The previous code // left regs at sos. diff --git a/trunk/arch/ia64/kernel/mca_drv.c b/trunk/arch/ia64/kernel/mca_drv.c index 8fd93afa75a7..3492e3211a44 100644 --- a/trunk/arch/ia64/kernel/mca_drv.c +++ b/trunk/arch/ia64/kernel/mca_drv.c @@ -437,9 +437,6 @@ recover_from_read_error(slidx_table_t *slidx, * the process not have any locks of kernel. */ - /* Is minstate valid? */ - if (!peidx_bottom(peidx) || !(peidx_bottom(peidx)->valid.minstate)) - return 0; psr1 =(struct ia64_psr *)&(peidx_minstate_area(peidx)->pmsa_ipsr); /* diff --git a/trunk/arch/ia64/kernel/perfmon.c b/trunk/arch/ia64/kernel/perfmon.c index 9c5194b385da..2ea4b39efffa 100644 --- a/trunk/arch/ia64/kernel/perfmon.c +++ b/trunk/arch/ia64/kernel/perfmon.c @@ -40,7 +40,6 @@ #include #include #include -#include #include #include @@ -287,7 +286,7 @@ typedef struct pfm_context { unsigned long ctx_ovfl_regs[4]; /* which registers overflowed (notification) */ - struct completion ctx_restart_done; /* use for blocking notification mode */ + struct semaphore ctx_restart_sem; /* use for blocking notification mode */ unsigned long ctx_used_pmds[4]; /* bitmask of PMD used */ unsigned long ctx_all_pmds[4]; /* bitmask of all accessible PMDs */ @@ -1992,7 +1991,7 @@ pfm_close(struct inode *inode, struct file *filp) /* * force task to wake up from MASKED state */ - complete(&ctx->ctx_restart_done); + up(&ctx->ctx_restart_sem); DPRINT(("waking up ctx_state=%d\n", state)); @@ -2707,7 +2706,7 @@ pfm_context_create(pfm_context_t *ctx, void *arg, int count, struct pt_regs *reg /* * init restart semaphore to locked */ - init_completion(&ctx->ctx_restart_done); + sema_init(&ctx->ctx_restart_sem, 0); /* * activation is used in SMP only @@ -3688,7 +3687,7 @@ pfm_restart(pfm_context_t *ctx, void *arg, int count, struct pt_regs *regs) */ if (CTX_OVFL_NOBLOCK(ctx) == 0 && state == PFM_CTX_MASKED) { DPRINT(("unblocking [%d] \n", task->pid)); - complete(&ctx->ctx_restart_done); + up(&ctx->ctx_restart_sem); } else { DPRINT(("[%d] armed exit trap\n", task->pid)); @@ -5090,7 +5089,7 @@ pfm_handle_work(void) * may go through without blocking on SMP systems * if restart has been received already by the time we call down() */ - ret = wait_for_completion_interruptible(&ctx->ctx_restart_done); + ret = down_interruptible(&ctx->ctx_restart_sem); DPRINT(("after block sleeping ret=%d\n", ret)); diff --git a/trunk/arch/ia64/kernel/sal.c b/trunk/arch/ia64/kernel/sal.c index 056f7a6eedc7..acc0f132f86c 100644 --- a/trunk/arch/ia64/kernel/sal.c +++ b/trunk/arch/ia64/kernel/sal.c @@ -14,7 +14,6 @@ #include #include -#include #include #include #include @@ -215,78 +214,6 @@ chk_nointroute_opt(void) static void __init sal_desc_ap_wakeup(void *p) { } #endif -/* - * HP rx5670 firmware polls for interrupts during SAL_CACHE_FLUSH by reading - * cr.ivr, but it never writes cr.eoi. This leaves any interrupt marked as - * "in-service" and masks other interrupts of equal or lower priority. - * - * HP internal defect reports: F1859, F2775, F3031. - */ -static int sal_cache_flush_drops_interrupts; - -static void __init -check_sal_cache_flush (void) -{ - unsigned long flags, itv; - int cpu; - u64 vector; - - cpu = get_cpu(); - local_irq_save(flags); - - /* - * Schedule a timer interrupt, wait until it's reported, and see if - * SAL_CACHE_FLUSH drops it. - */ - itv = ia64_get_itv(); - BUG_ON((itv & (1 << 16)) == 0); - - ia64_set_itv(IA64_TIMER_VECTOR); - ia64_set_itm(ia64_get_itc() + 1000); - - while (!ia64_get_irr(IA64_TIMER_VECTOR)) - cpu_relax(); - - ia64_sal_cache_flush(3); - - if (ia64_get_irr(IA64_TIMER_VECTOR)) { - vector = ia64_get_ivr(); - ia64_eoi(); - WARN_ON(vector != IA64_TIMER_VECTOR); - } else { - sal_cache_flush_drops_interrupts = 1; - printk(KERN_ERR "SAL: SAL_CACHE_FLUSH drops interrupts; " - "PAL_CACHE_FLUSH will be used instead\n"); - ia64_eoi(); - } - - ia64_set_itv(itv); - local_irq_restore(flags); - put_cpu(); -} - -s64 -ia64_sal_cache_flush (u64 cache_type) -{ - struct ia64_sal_retval isrv; - - if (sal_cache_flush_drops_interrupts) { - unsigned long flags; - u64 progress; - s64 rc; - - progress = 0; - local_irq_save(flags); - rc = ia64_pal_cache_flush(cache_type, - PAL_CACHE_FLUSH_INVALIDATE, &progress, NULL); - local_irq_restore(flags); - return rc; - } - - SAL_CALL(isrv, SAL_CACHE_FLUSH, cache_type, 0, 0, 0, 0, 0, 0); - return isrv.status; -} - void __init ia64_sal_init (struct ia64_sal_systab *systab) { @@ -335,8 +262,6 @@ ia64_sal_init (struct ia64_sal_systab *systab) } p += SAL_DESC_SIZE(*p); } - - check_sal_cache_flush(); } int diff --git a/trunk/arch/ia64/kernel/setup.c b/trunk/arch/ia64/kernel/setup.c index 35f7835294a3..c0766575a3a2 100644 --- a/trunk/arch/ia64/kernel/setup.c +++ b/trunk/arch/ia64/kernel/setup.c @@ -71,8 +71,6 @@ unsigned long __per_cpu_offset[NR_CPUS]; EXPORT_SYMBOL(__per_cpu_offset); #endif -extern void ia64_setup_printk_clock(void); - DEFINE_PER_CPU(struct cpuinfo_ia64, cpu_info); DEFINE_PER_CPU(unsigned long, local_per_cpu_offset); DEFINE_PER_CPU(unsigned long, ia64_phys_stacked_size_p8); @@ -447,8 +445,6 @@ setup_arch (char **cmdline_p) /* process SAL system table: */ ia64_sal_init(efi.sal_systab); - ia64_setup_printk_clock(); - #ifdef CONFIG_SMP cpu_physical_id(0) = hard_smp_processor_id(); diff --git a/trunk/arch/ia64/kernel/time.c b/trunk/arch/ia64/kernel/time.c index a094ec49ccfa..028a2b95936c 100644 --- a/trunk/arch/ia64/kernel/time.c +++ b/trunk/arch/ia64/kernel/time.c @@ -278,30 +278,3 @@ udelay (unsigned long usecs) } } EXPORT_SYMBOL(udelay); - -static unsigned long long ia64_itc_printk_clock(void) -{ - if (ia64_get_kr(IA64_KR_PER_CPU_DATA)) - return sched_clock(); - return 0; -} - -static unsigned long long ia64_default_printk_clock(void) -{ - return (unsigned long long)(jiffies_64 - INITIAL_JIFFIES) * - (1000000000/HZ); -} - -unsigned long long (*ia64_printk_clock)(void) = &ia64_default_printk_clock; - -unsigned long long printk_clock(void) -{ - return ia64_printk_clock(); -} - -void __init -ia64_setup_printk_clock(void) -{ - if (!(sal_platform_features & IA64_SAL_PLATFORM_FEATURE_ITC_DRIFT)) - ia64_printk_clock = ia64_itc_printk_clock; -} diff --git a/trunk/arch/ia64/kernel/topology.c b/trunk/arch/ia64/kernel/topology.c index 6e5eea19fa67..706b7734e191 100644 --- a/trunk/arch/ia64/kernel/topology.c +++ b/trunk/arch/ia64/kernel/topology.c @@ -71,33 +71,31 @@ static int __init topology_init(void) int i, err = 0; #ifdef CONFIG_NUMA - sysfs_nodes = kzalloc(sizeof(struct node) * MAX_NUMNODES, GFP_KERNEL); + sysfs_nodes = kmalloc(sizeof(struct node) * MAX_NUMNODES, GFP_KERNEL); if (!sysfs_nodes) { err = -ENOMEM; goto out; } + memset(sysfs_nodes, 0, sizeof(struct node) * MAX_NUMNODES); - /* - * MCD - Do we want to register all ONLINE nodes, or all POSSIBLE nodes? - */ - for_each_online_node(i) { + /* MCD - Do we want to register all ONLINE nodes, or all POSSIBLE nodes? */ + for_each_online_node(i) if ((err = register_node(&sysfs_nodes[i], i, 0))) goto out; - } #endif - sysfs_cpus = kzalloc(sizeof(struct ia64_cpu) * NR_CPUS, GFP_KERNEL); + sysfs_cpus = kmalloc(sizeof(struct ia64_cpu) * NR_CPUS, GFP_KERNEL); if (!sysfs_cpus) { err = -ENOMEM; goto out; } + memset(sysfs_cpus, 0, sizeof(struct ia64_cpu) * NR_CPUS); - for_each_present_cpu(i) { + for_each_present_cpu(i) if((err = arch_register_cpu(i))) goto out; - } out: return err; } -subsys_initcall(topology_init); +__initcall(topology_init); diff --git a/trunk/arch/ia64/kernel/unaligned.c b/trunk/arch/ia64/kernel/unaligned.c index f9e0ae936d1a..43b45b65ee5a 100644 --- a/trunk/arch/ia64/kernel/unaligned.c +++ b/trunk/arch/ia64/kernel/unaligned.c @@ -1283,9 +1283,8 @@ within_logging_rate_limit (void) if (jiffies - last_time > 5*HZ) count = 0; - if (count < 5) { + if (++count < 5) { last_time = jiffies; - count++; return 1; } return 0; diff --git a/trunk/arch/ia64/kernel/uncached.c b/trunk/arch/ia64/kernel/uncached.c index fcd2bad0286f..b631cf86ed44 100644 --- a/trunk/arch/ia64/kernel/uncached.c +++ b/trunk/arch/ia64/kernel/uncached.c @@ -210,7 +210,6 @@ uncached_build_memmap(unsigned long start, unsigned long end, void *arg) dprintk(KERN_ERR "uncached_build_memmap(%lx %lx)\n", start, end); - touch_softlockup_watchdog(); memset((char *)start, 0, length); node = paddr_to_nid(start - __IA64_UNCACHED_OFFSET); diff --git a/trunk/arch/ia64/pci/pci.c b/trunk/arch/ia64/pci/pci.c index 0b30ca006286..d27ecdcb6fca 100644 --- a/trunk/arch/ia64/pci/pci.c +++ b/trunk/arch/ia64/pci/pci.c @@ -193,12 +193,12 @@ add_io_space (struct pci_root_info *info, struct acpi_resource_address64 *addr) goto free_resource; } - min = addr->minimum; + min = addr->min_address_range; max = min + addr->address_length - 1; - if (addr->info.io.translation_type == ACPI_SPARSE_TRANSLATION) + if (addr->attribute.io.translation_attribute == ACPI_SPARSE_TRANSLATION) sparse = 1; - space_nr = new_space(addr->translation_offset, sparse); + space_nr = new_space(addr->address_translation_offset, sparse); if (space_nr == ~0) goto free_name; @@ -285,7 +285,7 @@ static __devinit acpi_status add_window(struct acpi_resource *res, void *data) if (addr.resource_type == ACPI_MEMORY_RANGE) { flags = IORESOURCE_MEM; root = &iomem_resource; - offset = addr.translation_offset; + offset = addr.address_translation_offset; } else if (addr.resource_type == ACPI_IO_RANGE) { flags = IORESOURCE_IO; root = &ioport_resource; @@ -298,7 +298,7 @@ static __devinit acpi_status add_window(struct acpi_resource *res, void *data) window = &info->controller->window[info->controller->windows++]; window->resource.name = info->name; window->resource.flags = flags; - window->resource.start = addr.minimum + offset; + window->resource.start = addr.min_address_range + offset; window->resource.end = window->resource.start + addr.address_length - 1; window->resource.child = NULL; window->offset = offset; diff --git a/trunk/arch/ia64/sn/Makefile b/trunk/arch/ia64/sn/Makefile index 79a7df02e812..a269f6d84c29 100644 --- a/trunk/arch/ia64/sn/Makefile +++ b/trunk/arch/ia64/sn/Makefile @@ -9,4 +9,6 @@ # Makefile for the sn ia64 subplatform # +CPPFLAGS += -I$(srctree)/arch/ia64/sn/include + obj-y += kernel/ pci/ diff --git a/trunk/arch/ia64/sn/include/xtalk/hubdev.h b/trunk/arch/ia64/sn/include/xtalk/hubdev.h index 8182583c762c..7c88e9a58516 100644 --- a/trunk/arch/ia64/sn/include/xtalk/hubdev.h +++ b/trunk/arch/ia64/sn/include/xtalk/hubdev.h @@ -51,15 +51,6 @@ struct sn_flush_device_kernel { struct sn_flush_device_common *common; }; -/* 01/16/06 This struct is the old PROM/kernel struct and needs to be included - * for older official PROMs to function on the new kernel base. This struct - * will be removed when the next official PROM release occurs. */ - -struct sn_flush_device_war { - struct sn_flush_device_common common; - u32 filler; /* older PROMs expect the default size of a spinlock_t */ -}; - /* * **widget_p - Used as an array[wid_num][device] of sn_flush_device_kernel. */ diff --git a/trunk/arch/ia64/sn/kernel/Makefile b/trunk/arch/ia64/sn/kernel/Makefile index 3e9b4eea7418..4351c4ff9845 100644 --- a/trunk/arch/ia64/sn/kernel/Makefile +++ b/trunk/arch/ia64/sn/kernel/Makefile @@ -7,8 +7,6 @@ # Copyright (C) 1999,2001-2005 Silicon Graphics, Inc. All Rights Reserved. # -CPPFLAGS += -I$(srctree)/arch/ia64/sn/include - obj-y += setup.o bte.o bte_error.o irq.o mca.o idle.o \ huberror.o io_init.o iomv.o klconflib.o sn2/ obj-$(CONFIG_IA64_GENERIC) += machvec.o diff --git a/trunk/arch/ia64/sn/kernel/bte.c b/trunk/arch/ia64/sn/kernel/bte.c index 1f11db470d90..dd73c0cb754b 100644 --- a/trunk/arch/ia64/sn/kernel/bte.c +++ b/trunk/arch/ia64/sn/kernel/bte.c @@ -3,7 +3,7 @@ * License. See the file "COPYING" in the main directory of this archive * for more details. * - * Copyright (c) 2000-2006 Silicon Graphics, Inc. All Rights Reserved. + * Copyright (c) 2000-2005 Silicon Graphics, Inc. All Rights Reserved. */ #include @@ -186,13 +186,18 @@ bte_result_t bte_copy(u64 src, u64 dest, u64 len, u64 mode, void *notification) /* Initialize the notification to a known value. */ *bte->most_rcnt_na = BTE_WORD_BUSY; - notif_phys_addr = (u64)bte->most_rcnt_na; + notif_phys_addr = TO_PHYS(ia64_tpa((unsigned long)bte->most_rcnt_na)); + if (is_shub2()) { + src = SH2_TIO_PHYS_TO_DMA(src); + dest = SH2_TIO_PHYS_TO_DMA(dest); + notif_phys_addr = SH2_TIO_PHYS_TO_DMA(notif_phys_addr); + } /* Set the source and destination registers */ - BTE_PRINTKV(("IBSA = 0x%lx)\n", src)); - BTE_SRC_STORE(bte, src); - BTE_PRINTKV(("IBDA = 0x%lx)\n", dest)); - BTE_DEST_STORE(bte, dest); + BTE_PRINTKV(("IBSA = 0x%lx)\n", (TO_PHYS(src)))); + BTE_SRC_STORE(bte, TO_PHYS(src)); + BTE_PRINTKV(("IBDA = 0x%lx)\n", (TO_PHYS(dest)))); + BTE_DEST_STORE(bte, TO_PHYS(dest)); /* Set the notification register */ BTE_PRINTKV(("IBNA = 0x%lx)\n", notif_phys_addr)); diff --git a/trunk/arch/ia64/sn/kernel/io_init.c b/trunk/arch/ia64/sn/kernel/io_init.c index 3437c2390429..233d55115d33 100644 --- a/trunk/arch/ia64/sn/kernel/io_init.c +++ b/trunk/arch/ia64/sn/kernel/io_init.c @@ -10,7 +10,6 @@ #include #include #include -#include #include #include #include @@ -166,49 +165,11 @@ sn_pcidev_info_get(struct pci_dev *dev) return NULL; } -/* Older PROM flush WAR - * - * 01/16/06 -- This war will be in place until a new official PROM is released. - * Additionally note that the struct sn_flush_device_war also has to be - * removed from arch/ia64/sn/include/xtalk/hubdev.h - */ -static u8 war_implemented = 0; - -static s64 sn_device_fixup_war(u64 nasid, u64 widget, int device, - struct sn_flush_device_common *common) -{ - struct sn_flush_device_war *war_list; - struct sn_flush_device_war *dev_entry; - struct ia64_sal_retval isrv = {0,0,0,0}; - - if (!war_implemented) { - printk(KERN_WARNING "PROM version < 4.50 -- implementing old " - "PROM flush WAR\n"); - war_implemented = 1; - } - - war_list = kzalloc(DEV_PER_WIDGET * sizeof(*war_list), GFP_KERNEL); - if (!war_list) - BUG(); - - SAL_CALL_NOLOCK(isrv, SN_SAL_IOIF_GET_WIDGET_DMAFLUSH_LIST, - nasid, widget, __pa(war_list), 0, 0, 0 ,0); - if (isrv.status) - panic("sn_device_fixup_war failed: %s\n", - ia64_sal_strerror(isrv.status)); - - dev_entry = war_list + device; - memcpy(common,dev_entry, sizeof(*common)); - kfree(war_list); - - return isrv.status; -} - /* - * sn_fixup_ionodes() - This routine initializes the HUB data strcuture for + * sn_fixup_ionodes() - This routine initializes the HUB data strcuture for * each node in the system. */ -static void __init sn_fixup_ionodes(void) +static void sn_fixup_ionodes(void) { struct sn_flush_device_kernel *sn_flush_device_kernel; struct sn_flush_device_kernel *dev_entry; @@ -281,21 +242,12 @@ static void __init sn_fixup_ionodes(void) memset(dev_entry->common, 0x0, sizeof(struct sn_flush_device_common)); - if (sn_prom_feature_available( - PRF_DEVICE_FLUSH_LIST)) - status = sal_get_device_dmaflush_list( - nasid, - widget, - device, + status = sal_get_device_dmaflush_list(nasid, + widget, + device, (u64)(dev_entry->common)); - else - status = sn_device_fixup_war(nasid, - widget, - device, - dev_entry->common); - if (status != SALRET_OK) - panic("SAL call failed: %s\n", - ia64_sal_strerror(status)); + if (status) + BUG(); spin_lock_init(&dev_entry->sfdl_flush_lock); } @@ -467,13 +419,6 @@ void sn_pci_fixup_slot(struct pci_dev *dev) pcidev_info->pdi_sn_irq_info = NULL; kfree(sn_irq_info); } - - /* - * MSI currently not supported on altix. Remove this when - * the MSI abstraction patches are integrated into the kernel - * (sometime after 2.6.16 releases) - */ - dev->no_msi = 1; } /* @@ -617,15 +562,15 @@ void sn_bus_store_sysdata(struct pci_dev *dev) void sn_bus_free_sysdata(void) { struct sysdata_el *element; - struct list_head *list, *safe; + struct list_head *list; - list_for_each_safe(list, safe, &sn_sysdata_list) { +sn_sysdata_free_start: + list_for_each(list, &sn_sysdata_list) { element = list_entry(list, struct sysdata_el, entry); list_del(&element->entry); - list_del(&(((struct pcidev_info *) - (element->sysdata))->pdi_list)); kfree(element->sysdata); kfree(element); + goto sn_sysdata_free_start; } return; } diff --git a/trunk/arch/ia64/sn/kernel/irq.c b/trunk/arch/ia64/sn/kernel/irq.c index c373113d073a..ec37084bdc17 100644 --- a/trunk/arch/ia64/sn/kernel/irq.c +++ b/trunk/arch/ia64/sn/kernel/irq.c @@ -5,12 +5,11 @@ * License. See the file "COPYING" in the main directory of this archive * for more details. * - * Copyright (c) 2000-2006 Silicon Graphics, Inc. All Rights Reserved. + * Copyright (c) 2000-2005 Silicon Graphics, Inc. All Rights Reserved. */ #include #include -#include #include #include #include @@ -77,15 +76,17 @@ static void sn_enable_irq(unsigned int irq) static void sn_ack_irq(unsigned int irq) { - u64 event_occurred, mask; + u64 event_occurred, mask = 0; irq = irq & 0xff; - event_occurred = HUB_L((u64*)LOCAL_MMR_ADDR(SH_EVENT_OCCURRED)); + event_occurred = + HUB_L((u64*)LOCAL_MMR_ADDR(SH_EVENT_OCCURRED)); mask = event_occurred & SH_ALL_INT_MASK; - HUB_S((u64*)LOCAL_MMR_ADDR(SH_EVENT_OCCURRED_ALIAS), mask); + HUB_S((u64*)LOCAL_MMR_ADDR(SH_EVENT_OCCURRED_ALIAS), + mask); __set_bit(irq, (volatile void *)pda->sn_in_service_ivecs); - move_native_irq(irq); + move_irq(irq); } static void sn_end_irq(unsigned int irq) @@ -218,8 +219,9 @@ static void register_intr_pda(struct sn_irq_info *sn_irq_info) pdacpu(cpu)->sn_last_irq = irq; } - if (pdacpu(cpu)->sn_first_irq == 0 || pdacpu(cpu)->sn_first_irq > irq) + if (pdacpu(cpu)->sn_first_irq == 0 || pdacpu(cpu)->sn_first_irq > irq) { pdacpu(cpu)->sn_first_irq = irq; + } } static void unregister_intr_pda(struct sn_irq_info *sn_irq_info) @@ -287,7 +289,7 @@ void sn_irq_fixup(struct pci_dev *pci_dev, struct sn_irq_info *sn_irq_info) list_add_rcu(&sn_irq_info->list, sn_irq_lh[sn_irq_info->irq_irq]); spin_unlock(&sn_irq_info_lock); - register_intr_pda(sn_irq_info); + (void)register_intr_pda(sn_irq_info); } void sn_irq_unfixup(struct pci_dev *pci_dev) @@ -299,9 +301,7 @@ void sn_irq_unfixup(struct pci_dev *pci_dev) return; sn_irq_info = SN_PCIDEV_INFO(pci_dev)->pdi_sn_irq_info; - if (!sn_irq_info) - return; - if (!sn_irq_info->irq_irq) { + if (!sn_irq_info || !sn_irq_info->irq_irq) { kfree(sn_irq_info); return; } @@ -419,7 +419,7 @@ void sn_lb_int_war_check(void) rcu_read_unlock(); } -void __init sn_irq_lh_init(void) +void sn_irq_lh_init(void) { int i; @@ -434,4 +434,5 @@ void __init sn_irq_lh_init(void) INIT_LIST_HEAD(sn_irq_lh[i]); } + } diff --git a/trunk/arch/ia64/sn/kernel/klconflib.c b/trunk/arch/ia64/sn/kernel/klconflib.c index 87682b48ef83..0f11a3299cd2 100644 --- a/trunk/arch/ia64/sn/kernel/klconflib.c +++ b/trunk/arch/ia64/sn/kernel/klconflib.c @@ -78,30 +78,31 @@ format_module_id(char *buffer, moduleid_t m, int fmt) position = MODULE_GET_BPOS(m); if ((fmt == MODULE_FORMAT_BRIEF) || (fmt == MODULE_FORMAT_LCD)) { - /* Brief module number format, eg. 002c15 */ + /* Brief module number format, eg. 002c15 */ - /* Decompress the rack number */ - *buffer++ = '0' + RACK_GET_CLASS(rack); - *buffer++ = '0' + RACK_GET_GROUP(rack); - *buffer++ = '0' + RACK_GET_NUM(rack); + /* Decompress the rack number */ + *buffer++ = '0' + RACK_GET_CLASS(rack); + *buffer++ = '0' + RACK_GET_GROUP(rack); + *buffer++ = '0' + RACK_GET_NUM(rack); - /* Add the brick type */ - *buffer++ = brickchar; + /* Add the brick type */ + *buffer++ = brickchar; } else if (fmt == MODULE_FORMAT_LONG) { - /* Fuller hwgraph format, eg. rack/002/bay/15 */ + /* Fuller hwgraph format, eg. rack/002/bay/15 */ - strcpy(buffer, "rack" "/"); buffer += strlen(buffer); + strcpy(buffer, "rack" "/"); buffer += strlen(buffer); - *buffer++ = '0' + RACK_GET_CLASS(rack); - *buffer++ = '0' + RACK_GET_GROUP(rack); - *buffer++ = '0' + RACK_GET_NUM(rack); + *buffer++ = '0' + RACK_GET_CLASS(rack); + *buffer++ = '0' + RACK_GET_GROUP(rack); + *buffer++ = '0' + RACK_GET_NUM(rack); - strcpy(buffer, "/" "bay" "/"); buffer += strlen(buffer); + strcpy(buffer, "/" "bay" "/"); buffer += strlen(buffer); } /* Add the bay position, using at least two digits */ if (position < 10) - *buffer++ = '0'; + *buffer++ = '0'; sprintf(buffer, "%d", position); + } diff --git a/trunk/arch/ia64/sn/kernel/mca.c b/trunk/arch/ia64/sn/kernel/mca.c index 3db62f24596c..6546db6abdba 100644 --- a/trunk/arch/ia64/sn/kernel/mca.c +++ b/trunk/arch/ia64/sn/kernel/mca.c @@ -3,14 +3,13 @@ * License. See the file "COPYING" in the main directory of this archive * for more details. * - * Copyright (c) 2000-2006 Silicon Graphics, Inc. All Rights Reserved. + * Copyright (c) 2000-2004 Silicon Graphics, Inc. All Rights Reserved. */ #include #include #include #include -#include #include #include #include @@ -28,7 +27,7 @@ void sn_init_cpei_timer(void); /* Printing oemdata from mca uses data that is not passed through SAL, it is * global. Only one user at a time. */ -static DEFINE_MUTEX(sn_oemdata_mutex); +static DECLARE_MUTEX(sn_oemdata_mutex); static u8 **sn_oemdata; static u64 *sn_oemdata_size, sn_oemdata_bufsize; @@ -90,7 +89,7 @@ static int sn_platform_plat_specific_err_print(const u8 * sect_header, u8 ** oemdata, u64 * oemdata_size) { - mutex_lock(&sn_oemdata_mutex); + down(&sn_oemdata_mutex); sn_oemdata = oemdata; sn_oemdata_size = oemdata_size; sn_oemdata_bufsize = 0; @@ -108,7 +107,7 @@ sn_platform_plat_specific_err_print(const u8 * sect_header, u8 ** oemdata, *sn_oemdata_size = 0; ia64_sn_plat_specific_err_print(print_hook, (char *)sect_header); } - mutex_unlock(&sn_oemdata_mutex); + up(&sn_oemdata_mutex); return 0; } @@ -137,8 +136,7 @@ int sn_salinfo_platform_oemdata(const u8 *sect_header, u8 **oemdata, u64 *oemdat static int __init sn_salinfo_init(void) { - if (ia64_platform_is("sn2")) - salinfo_platform_oemdata = &sn_salinfo_platform_oemdata; + salinfo_platform_oemdata = &sn_salinfo_platform_oemdata; return 0; } diff --git a/trunk/arch/ia64/sn/kernel/setup.c b/trunk/arch/ia64/sn/kernel/setup.c index 48645ac120fc..e510dce9971f 100644 --- a/trunk/arch/ia64/sn/kernel/setup.c +++ b/trunk/arch/ia64/sn/kernel/setup.c @@ -67,7 +67,6 @@ extern unsigned long last_time_offset; extern void (*ia64_mark_idle) (int); extern void snidle(int); extern unsigned char acpi_kbd_controller_present; -extern unsigned long long (*ia64_printk_clock)(void); unsigned long sn_rtc_cycles_per_second; EXPORT_SYMBOL(sn_rtc_cycles_per_second); @@ -125,6 +124,20 @@ struct screen_info sn_screen_info = { .orig_video_points = 16 }; +/* + * This is here so we can use the CMOS detection in ide-probe.c to + * determine what drives are present. In theory, we don't need this + * as the auto-detection could be done via ide-probe.c:do_probe() but + * in practice that would be much slower, which is painful when + * running in the simulator. Note that passing zeroes in DRIVE_INFO + * is sufficient (the IDE driver will autodetect the drive geometry). + */ +#ifdef CONFIG_IA64_GENERIC +extern char drive_info[4 * 16]; +#else +char drive_info[4 * 16]; +#endif + /* * This routine can only be used during init, since * smp_boot_data is an init data structure. @@ -196,7 +209,7 @@ void __init early_sn_setup(void) } extern int platform_intr_list[]; -static int __initdata shub_1_1_found; +static int __initdata shub_1_1_found = 0; /* * sn_check_for_wars @@ -359,16 +372,6 @@ sn_scan_pcdp(void) } } -static unsigned long sn2_rtc_initial; - -static unsigned long long ia64_sn2_printk_clock(void) -{ - unsigned long rtc_now = rtc_time(); - - return (rtc_now - sn2_rtc_initial) * - (1000000000 / sn_rtc_cycles_per_second); -} - /** * sn_setup - SN platform setup routine * @cmdline_p: kernel command line @@ -383,7 +386,6 @@ void __init sn_setup(char **cmdline_p) u32 version = sn_sal_rev(); extern void sn_cpu_init(void); - sn2_rtc_initial = rtc_time(); ia64_sn_plat_set_error_handling_features(); // obsolete ia64_sn_set_os_feature(OSF_MCA_SLV_TO_OS_INIT_SLV); ia64_sn_set_os_feature(OSF_FEAT_LOG_SBES); @@ -435,21 +437,6 @@ void __init sn_setup(char **cmdline_p) */ build_cnode_tables(); - status = - ia64_sal_freq_base(SAL_FREQ_BASE_REALTIME_CLOCK, &ticks_per_sec, - &drift); - if (status != 0 || ticks_per_sec < 100000) { - printk(KERN_WARNING - "unable to determine platform RTC clock frequency, guessing.\n"); - /* PROM gives wrong value for clock freq. so guess */ - sn_rtc_cycles_per_second = 1000000000000UL / 30000UL; - } else - sn_rtc_cycles_per_second = ticks_per_sec; - - platform_intr_list[ACPI_INTERRUPT_CPEI] = IA64_CPE_VECTOR; - - ia64_printk_clock = ia64_sn2_printk_clock; - /* * Old PROMs do not provide an ACPI FADT. Disable legacy keyboard * support here so we don't have to listen to failed keyboard probe @@ -463,6 +450,19 @@ void __init sn_setup(char **cmdline_p) printk("SGI SAL version %x.%02x\n", version >> 8, version & 0x00FF); + status = + ia64_sal_freq_base(SAL_FREQ_BASE_REALTIME_CLOCK, &ticks_per_sec, + &drift); + if (status != 0 || ticks_per_sec < 100000) { + printk(KERN_WARNING + "unable to determine platform RTC clock frequency, guessing.\n"); + /* PROM gives wrong value for clock freq. so guess */ + sn_rtc_cycles_per_second = 1000000000000UL / 30000UL; + } else + sn_rtc_cycles_per_second = ticks_per_sec; + + platform_intr_list[ACPI_INTERRUPT_CPEI] = IA64_CPE_VECTOR; + /* * we set the default root device to /dev/hda * to make simulation easy @@ -578,17 +578,13 @@ void __init sn_cpu_init(void) sn_prom_type = 2; else sn_prom_type = 1; - printk(KERN_INFO "Running on medusa with %s PROM\n", - (sn_prom_type == 1) ? "real" : "fake"); + printk("Running on medusa with %s PROM\n", (sn_prom_type == 1) ? "real" : "fake"); } memset(pda, 0, sizeof(pda)); - if (ia64_sn_get_sn_info(0, &sn_hub_info->shub2, - &sn_hub_info->nasid_bitmask, - &sn_hub_info->nasid_shift, - &sn_system_size, &sn_sharing_domain_size, - &sn_partition_id, &sn_coherency_id, - &sn_region_size)) + if (ia64_sn_get_sn_info(0, &sn_hub_info->shub2, &sn_hub_info->nasid_bitmask, &sn_hub_info->nasid_shift, + &sn_system_size, &sn_sharing_domain_size, &sn_partition_id, + &sn_coherency_id, &sn_region_size)) BUG(); sn_hub_info->as_shift = sn_hub_info->nasid_shift - 2; @@ -720,8 +716,7 @@ void __init build_cnode_tables(void) for_each_online_node(node) { kl_config_hdr_t *klgraph_header; nasid = cnodeid_to_nasid(node); - klgraph_header = ia64_sn_get_klconfig_addr(nasid); - if (klgraph_header == NULL) + if ((klgraph_header = ia64_sn_get_klconfig_addr(nasid)) == NULL) BUG(); brd = NODE_OFFSET_TO_LBOARD(nasid, klgraph_header->ch_board_info); while (brd) { @@ -739,7 +734,7 @@ nasid_slice_to_cpuid(int nasid, int slice) { long cpu; - for (cpu = 0; cpu < NR_CPUS; cpu++) + for (cpu=0; cpu < NR_CPUS; cpu++) if (cpuid_to_nasid(cpu) == nasid && cpuid_to_slice(cpu) == slice) return cpu; diff --git a/trunk/arch/ia64/sn/kernel/sn2/Makefile b/trunk/arch/ia64/sn/kernel/sn2/Makefile index 99e177693234..170bde4549da 100644 --- a/trunk/arch/ia64/sn/kernel/sn2/Makefile +++ b/trunk/arch/ia64/sn/kernel/sn2/Makefile @@ -9,7 +9,5 @@ # sn2 specific kernel files # -CPPFLAGS += -I$(srctree)/arch/ia64/sn/include - obj-y += cache.o io.o ptc_deadlock.o sn2_smp.o sn_proc_fs.o \ prominfo_proc.o timer.o timer_interrupt.o sn_hwperf.o diff --git a/trunk/arch/ia64/sn/kernel/sn2/sn2_smp.c b/trunk/arch/ia64/sn/kernel/sn2/sn2_smp.c index f153a4c35c70..471bbaa65d1b 100644 --- a/trunk/arch/ia64/sn/kernel/sn2/sn2_smp.c +++ b/trunk/arch/ia64/sn/kernel/sn2/sn2_smp.c @@ -5,7 +5,7 @@ * License. See the file "COPYING" in the main directory of this archive * for more details. * - * Copyright (C) 2000-2006 Silicon Graphics, Inc. All rights reserved. + * Copyright (C) 2000-2005 Silicon Graphics, Inc. All rights reserved. */ #include @@ -46,28 +46,104 @@ DECLARE_PER_CPU(struct ptc_stats, ptcstats); static __cacheline_aligned DEFINE_SPINLOCK(sn2_global_ptc_lock); -void sn2_ptc_deadlock_recovery(short *, short, short, int, volatile unsigned long *, unsigned long, - volatile unsigned long *, unsigned long); +void sn2_ptc_deadlock_recovery(short *, short, int, volatile unsigned long *, unsigned long data0, + volatile unsigned long *, unsigned long data1); +#ifdef DEBUG_PTC /* - * Note: some is the following is captured here to make degugging easier - * (the macros make more sense if you see the debug patch - not posted) + * ptctest: + * + * xyz - 3 digit hex number: + * x - Force PTC purges to use shub: + * 0 - no force + * 1 - force + * y - interupt enable + * 0 - disable interrupts + * 1 - leave interuupts enabled + * z - type of lock: + * 0 - global lock + * 1 - node local lock + * 2 - no lock + * + * Note: on shub1, only ptctest == 0 is supported. Don't try other values! */ + +static unsigned int sn2_ptctest = 0; + +static int __init ptc_test(char *str) +{ + get_option(&str, &sn2_ptctest); + return 1; +} +__setup("ptctest=", ptc_test); + +static inline int ptc_lock(unsigned long *flagp) +{ + unsigned long opt = sn2_ptctest & 255; + + switch (opt) { + case 0x00: + spin_lock_irqsave(&sn2_global_ptc_lock, *flagp); + break; + case 0x01: + spin_lock_irqsave(&sn_nodepda->ptc_lock, *flagp); + break; + case 0x02: + local_irq_save(*flagp); + break; + case 0x10: + spin_lock(&sn2_global_ptc_lock); + break; + case 0x11: + spin_lock(&sn_nodepda->ptc_lock); + break; + case 0x12: + break; + default: + BUG(); + } + return opt; +} + +static inline void ptc_unlock(unsigned long flags, int opt) +{ + switch (opt) { + case 0x00: + spin_unlock_irqrestore(&sn2_global_ptc_lock, flags); + break; + case 0x01: + spin_unlock_irqrestore(&sn_nodepda->ptc_lock, flags); + break; + case 0x02: + local_irq_restore(flags); + break; + case 0x10: + spin_unlock(&sn2_global_ptc_lock); + break; + case 0x11: + spin_unlock(&sn_nodepda->ptc_lock); + break; + case 0x12: + break; + default: + BUG(); + } +} +#else + #define sn2_ptctest 0 -#define local_node_uses_ptc_ga(sh1) ((sh1) ? 1 : 0) -#define max_active_pio(sh1) ((sh1) ? 32 : 7) -#define reset_max_active_on_deadlock() 1 -#define PTC_LOCK(sh1) ((sh1) ? &sn2_global_ptc_lock : &sn_nodepda->ptc_lock) -static inline void ptc_lock(int sh1, unsigned long *flagp) +static inline int ptc_lock(unsigned long *flagp) { - spin_lock_irqsave(PTC_LOCK(sh1), *flagp); + spin_lock_irqsave(&sn2_global_ptc_lock, *flagp); + return 0; } -static inline void ptc_unlock(int sh1, unsigned long flags) +static inline void ptc_unlock(unsigned long flags, int opt) { - spin_unlock_irqrestore(PTC_LOCK(sh1), flags); + spin_unlock_irqrestore(&sn2_global_ptc_lock, flags); } +#endif struct ptc_stats { unsigned long ptc_l; @@ -75,30 +151,27 @@ struct ptc_stats { unsigned long shub_ptc_flushes; unsigned long nodes_flushed; unsigned long deadlocks; - unsigned long deadlocks2; unsigned long lock_itc_clocks; unsigned long shub_itc_clocks; unsigned long shub_itc_clocks_max; - unsigned long shub_ptc_flushes_not_my_mm; }; static inline unsigned long wait_piowc(void) { - volatile unsigned long *piows; - unsigned long zeroval, ws; + volatile unsigned long *piows, zeroval; + unsigned long ws; piows = pda->pio_write_status_addr; zeroval = pda->pio_write_status_val; do { cpu_relax(); } while (((ws = *piows) & SH_PIO_WRITE_STATUS_PENDING_WRITE_COUNT_MASK) != zeroval); - return (ws & SH_PIO_WRITE_STATUS_WRITE_DEADLOCK_MASK) != 0; + return ws; } void sn_tlb_migrate_finish(struct mm_struct *mm) { - /* flush_tlb_mm is inefficient if more than 1 users of mm */ - if (mm == current->mm && mm && atomic_read(&mm->mm_users) == 1) + if (mm == current->mm) flush_tlb_mm(mm); } @@ -128,14 +201,12 @@ void sn2_global_tlb_purge(struct mm_struct *mm, unsigned long start, unsigned long end, unsigned long nbits) { - int i, ibegin, shub1, cnode, mynasid, cpu, lcpu = 0, nasid; - int mymm = (mm == current->active_mm && mm == current->mm); - int use_cpu_ptcga; + int i, opt, shub1, cnode, mynasid, cpu, lcpu = 0, nasid, flushed = 0; + int mymm = (mm == current->active_mm && current->mm); volatile unsigned long *ptc0, *ptc1; - unsigned long itc, itc2, flags, data0 = 0, data1 = 0, rr_value, old_rr = 0; + unsigned long itc, itc2, flags, data0 = 0, data1 = 0, rr_value; short nasids[MAX_NUMNODES], nix; nodemask_t nodes_flushed; - int active, max_active, deadlock; nodes_clear(nodes_flushed); i = 0; @@ -196,56 +267,41 @@ sn2_global_tlb_purge(struct mm_struct *mm, unsigned long start, mynasid = get_nasid(); - use_cpu_ptcga = local_node_uses_ptc_ga(shub1); - max_active = max_active_pio(shub1); itc = ia64_get_itc(); - ptc_lock(shub1, &flags); + opt = ptc_lock(&flags); itc2 = ia64_get_itc(); - __get_cpu_var(ptcstats).lock_itc_clocks += itc2 - itc; __get_cpu_var(ptcstats).shub_ptc_flushes++; __get_cpu_var(ptcstats).nodes_flushed += nix; - if (!mymm) - __get_cpu_var(ptcstats).shub_ptc_flushes_not_my_mm++; - if (use_cpu_ptcga && !mymm) { - old_rr = ia64_get_rr(start); - ia64_set_rr(start, (old_rr & 0xff) | (rr_value << 8)); - ia64_srlz_d(); - } - - wait_piowc(); do { if (shub1) data1 = start | (1UL << SH1_PTC_1_START_SHFT); else data0 = (data0 & ~SH2_PTC_ADDR_MASK) | (start & SH2_PTC_ADDR_MASK); - deadlock = 0; - active = 0; - for (ibegin = 0, i = 0; i < nix; i++) { + for (i = 0; i < nix; i++) { nasid = nasids[i]; - if (use_cpu_ptcga && unlikely(nasid == mynasid)) { + if ((!(sn2_ptctest & 3)) && unlikely(nasid == mynasid && mymm)) { ia64_ptcga(start, nbits << 2); ia64_srlz_i(); } else { ptc0 = CHANGE_NASID(nasid, ptc0); if (ptc1) ptc1 = CHANGE_NASID(nasid, ptc1); - pio_atomic_phys_write_mmrs(ptc0, data0, ptc1, data1); - active++; - } - if (active >= max_active || i == (nix - 1)) { - if ((deadlock = wait_piowc())) { - sn2_ptc_deadlock_recovery(nasids, ibegin, i, mynasid, ptc0, data0, ptc1, data1); - if (reset_max_active_on_deadlock()) - max_active = 1; - } - active = 0; - ibegin = i + 1; + pio_atomic_phys_write_mmrs(ptc0, data0, ptc1, + data1); + flushed = 1; } } + if (flushed + && (wait_piowc() & + (SH_PIO_WRITE_STATUS_WRITE_DEADLOCK_MASK))) { + sn2_ptc_deadlock_recovery(nasids, nix, mynasid, ptc0, data0, ptc1, data1); + } + start += (1UL << nbits); + } while (start < end); itc2 = ia64_get_itc() - itc2; @@ -253,12 +309,7 @@ sn2_global_tlb_purge(struct mm_struct *mm, unsigned long start, if (itc2 > __get_cpu_var(ptcstats).shub_itc_clocks_max) __get_cpu_var(ptcstats).shub_itc_clocks_max = itc2; - if (old_rr) { - ia64_set_rr(start, old_rr); - ia64_srlz_d(); - } - - ptc_unlock(shub1, flags); + ptc_unlock(flags, opt); preempt_enable(); } @@ -270,30 +321,27 @@ sn2_global_tlb_purge(struct mm_struct *mm, unsigned long start, * TLB flush transaction. The recovery sequence is somewhat tricky & is * coded in assembly language. */ -void sn2_ptc_deadlock_recovery(short *nasids, short ib, short ie, int mynasid, volatile unsigned long *ptc0, unsigned long data0, +void sn2_ptc_deadlock_recovery(short *nasids, short nix, int mynasid, volatile unsigned long *ptc0, unsigned long data0, volatile unsigned long *ptc1, unsigned long data1) { - extern unsigned long sn2_ptc_deadlock_recovery_core(volatile unsigned long *, unsigned long, + extern void sn2_ptc_deadlock_recovery_core(volatile unsigned long *, unsigned long, volatile unsigned long *, unsigned long, volatile unsigned long *, unsigned long); short nasid, i; - unsigned long *piows, zeroval, n; + unsigned long *piows, zeroval; __get_cpu_var(ptcstats).deadlocks++; piows = (unsigned long *) pda->pio_write_status_addr; zeroval = pda->pio_write_status_val; - - for (i=ib; i <= ie; i++) { + for (i=0; i < nix; i++) { nasid = nasids[i]; - if (local_node_uses_ptc_ga(is_shub1()) && nasid == mynasid) + if (!(sn2_ptctest & 3) && nasid == mynasid) continue; ptc0 = CHANGE_NASID(nasid, ptc0); if (ptc1) ptc1 = CHANGE_NASID(nasid, ptc1); - - n = sn2_ptc_deadlock_recovery_core(ptc0, data0, ptc1, data1, piows, zeroval); - __get_cpu_var(ptcstats).deadlocks2 += n; + sn2_ptc_deadlock_recovery_core(ptc0, data0, ptc1, data1, piows, zeroval); } } @@ -404,22 +452,20 @@ static int sn2_ptc_seq_show(struct seq_file *file, void *data) cpu = *(loff_t *) data; if (!cpu) { - seq_printf(file, - "# cpu ptc_l newrid ptc_flushes nodes_flushed deadlocks lock_nsec shub_nsec shub_nsec_max not_my_mm deadlock2\n"); + seq_printf(file, "# ptc_l change_rid shub_ptc_flushes shub_nodes_flushed deadlocks lock_nsec shub_nsec shub_nsec_max\n"); seq_printf(file, "# ptctest %d\n", sn2_ptctest); } if (cpu < NR_CPUS && cpu_online(cpu)) { stat = &per_cpu(ptcstats, cpu); - seq_printf(file, "cpu %d %ld %ld %ld %ld %ld %ld %ld %ld %ld %ld\n", cpu, stat->ptc_l, + seq_printf(file, "cpu %d %ld %ld %ld %ld %ld %ld %ld %ld\n", cpu, stat->ptc_l, stat->change_rid, stat->shub_ptc_flushes, stat->nodes_flushed, stat->deadlocks, 1000 * stat->lock_itc_clocks / per_cpu(cpu_info, cpu).cyc_per_usec, 1000 * stat->shub_itc_clocks / per_cpu(cpu_info, cpu).cyc_per_usec, - 1000 * stat->shub_itc_clocks_max / per_cpu(cpu_info, cpu).cyc_per_usec, - stat->shub_ptc_flushes_not_my_mm, - stat->deadlocks2); + 1000 * stat->shub_itc_clocks_max / per_cpu(cpu_info, cpu).cyc_per_usec); } + return 0; } @@ -430,7 +476,7 @@ static struct seq_operations sn2_ptc_seq_ops = { .show = sn2_ptc_seq_show }; -static int sn2_ptc_proc_open(struct inode *inode, struct file *file) +int sn2_ptc_proc_open(struct inode *inode, struct file *file) { return seq_open(file, &sn2_ptc_seq_ops); } diff --git a/trunk/arch/ia64/sn/kernel/sn2/sn_hwperf.c b/trunk/arch/ia64/sn/kernel/sn2/sn_hwperf.c index 70db21f3df21..19b54fbcd7ea 100644 --- a/trunk/arch/ia64/sn/kernel/sn2/sn_hwperf.c +++ b/trunk/arch/ia64/sn/kernel/sn2/sn_hwperf.c @@ -3,7 +3,7 @@ * License. See the file "COPYING" in the main directory of this archive * for more details. * - * Copyright (C) 2004-2006 Silicon Graphics, Inc. All rights reserved. + * Copyright (C) 2004-2005 Silicon Graphics, Inc. All rights reserved. * * SGI Altix topology and hardware performance monitoring API. * Mark Goodwin . @@ -973,9 +973,6 @@ static int __devinit sn_hwperf_misc_register_init(void) { int e; - if (!ia64_platform_is("sn2")) - return 0; - sn_hwperf_init(); /* diff --git a/trunk/arch/ia64/sn/kernel/xp_main.c b/trunk/arch/ia64/sn/kernel/xp_main.c index b7ea46645e12..3be52a34c80f 100644 --- a/trunk/arch/ia64/sn/kernel/xp_main.c +++ b/trunk/arch/ia64/sn/kernel/xp_main.c @@ -19,7 +19,6 @@ #include #include #include -#include #include #include #include @@ -137,13 +136,13 @@ xpc_connect(int ch_number, xpc_channel_func func, void *key, u16 payload_size, registration = &xpc_registrations[ch_number]; - if (mutex_lock_interruptible(®istration->mutex) != 0) { + if (down_interruptible(®istration->sema) != 0) { return xpcInterrupted; } /* if XPC_CHANNEL_REGISTERED(ch_number) */ if (registration->func != NULL) { - mutex_unlock(®istration->mutex); + up(®istration->sema); return xpcAlreadyRegistered; } @@ -155,7 +154,7 @@ xpc_connect(int ch_number, xpc_channel_func func, void *key, u16 payload_size, registration->key = key; registration->func = func; - mutex_unlock(®istration->mutex); + up(®istration->sema); xpc_interface.connect(ch_number); @@ -191,11 +190,11 @@ xpc_disconnect(int ch_number) * figured XPC's users will just turn around and call xpc_disconnect() * again anyways, so we might as well wait, if need be. */ - mutex_lock(®istration->mutex); + down(®istration->sema); /* if !XPC_CHANNEL_REGISTERED(ch_number) */ if (registration->func == NULL) { - mutex_unlock(®istration->mutex); + up(®istration->sema); return; } @@ -209,7 +208,7 @@ xpc_disconnect(int ch_number) xpc_interface.disconnect(ch_number); - mutex_unlock(®istration->mutex); + up(®istration->sema); return; } @@ -251,9 +250,9 @@ xp_init(void) xp_nofault_PIOR_target = SH1_IPI_ACCESS; } - /* initialize the connection registration mutex */ + /* initialize the connection registration semaphores */ for (ch_number = 0; ch_number < XPC_NCHANNELS; ch_number++) { - mutex_init(&xpc_registrations[ch_number].mutex); + sema_init(&xpc_registrations[ch_number].sema, 1); /* mutex */ } return 0; diff --git a/trunk/arch/ia64/sn/kernel/xpc_channel.c b/trunk/arch/ia64/sn/kernel/xpc_channel.c index 36e5437a0fb6..0c0a68902409 100644 --- a/trunk/arch/ia64/sn/kernel/xpc_channel.c +++ b/trunk/arch/ia64/sn/kernel/xpc_channel.c @@ -22,8 +22,6 @@ #include #include #include -#include -#include #include #include #include @@ -58,8 +56,8 @@ xpc_initialize_channels(struct xpc_partition *part, partid_t partid) atomic_set(&ch->n_to_notify, 0); spin_lock_init(&ch->lock); - mutex_init(&ch->msg_to_pull_mutex); - init_completion(&ch->wdisconnect_wait); + sema_init(&ch->msg_to_pull_sema, 1); /* mutex */ + sema_init(&ch->wdisconnect_sema, 0); /* event wait */ atomic_set(&ch->n_on_msg_allocate_wq, 0); init_waitqueue_head(&ch->msg_allocate_wq); @@ -447,7 +445,7 @@ xpc_allocate_local_msgqueue(struct xpc_channel *ch) nbytes = nentries * ch->msg_size; ch->local_msgqueue = xpc_kmalloc_cacheline_aligned(nbytes, - GFP_KERNEL, + (GFP_KERNEL | GFP_DMA), &ch->local_msgqueue_base); if (ch->local_msgqueue == NULL) { continue; @@ -455,7 +453,7 @@ xpc_allocate_local_msgqueue(struct xpc_channel *ch) memset(ch->local_msgqueue, 0, nbytes); nbytes = nentries * sizeof(struct xpc_notify); - ch->notify_queue = kmalloc(nbytes, GFP_KERNEL); + ch->notify_queue = kmalloc(nbytes, (GFP_KERNEL | GFP_DMA)); if (ch->notify_queue == NULL) { kfree(ch->local_msgqueue_base); ch->local_msgqueue = NULL; @@ -502,7 +500,7 @@ xpc_allocate_remote_msgqueue(struct xpc_channel *ch) nbytes = nentries * ch->msg_size; ch->remote_msgqueue = xpc_kmalloc_cacheline_aligned(nbytes, - GFP_KERNEL, + (GFP_KERNEL | GFP_DMA), &ch->remote_msgqueue_base); if (ch->remote_msgqueue == NULL) { continue; @@ -536,6 +534,7 @@ static enum xpc_retval xpc_allocate_msgqueues(struct xpc_channel *ch) { unsigned long irq_flags; + int i; enum xpc_retval ret; @@ -553,6 +552,11 @@ xpc_allocate_msgqueues(struct xpc_channel *ch) return ret; } + for (i = 0; i < ch->local_nentries; i++) { + /* use a semaphore as an event wait queue */ + sema_init(&ch->notify_queue[i].sema, 0); + } + spin_lock_irqsave(&ch->lock, irq_flags); ch->flags |= XPC_C_SETUP; spin_unlock_irqrestore(&ch->lock, irq_flags); @@ -795,8 +799,10 @@ xpc_process_disconnect(struct xpc_channel *ch, unsigned long *irq_flags) } if (ch->flags & XPC_C_WDISCONNECT) { - /* we won't lose the CPU since we're holding ch->lock */ - complete(&ch->wdisconnect_wait); + spin_unlock_irqrestore(&ch->lock, *irq_flags); + up(&ch->wdisconnect_sema); + spin_lock_irqsave(&ch->lock, *irq_flags); + } else if (ch->delayed_IPI_flags) { if (part->act_state != XPC_P_DEACTIVATING) { /* time to take action on any delayed IPI flags */ @@ -1086,12 +1092,12 @@ xpc_connect_channel(struct xpc_channel *ch) struct xpc_registration *registration = &xpc_registrations[ch->number]; - if (mutex_trylock(®istration->mutex) == 0) { + if (down_trylock(®istration->sema) != 0) { return xpcRetry; } if (!XPC_CHANNEL_REGISTERED(ch->number)) { - mutex_unlock(®istration->mutex); + up(®istration->sema); return xpcUnregistered; } @@ -1102,7 +1108,7 @@ xpc_connect_channel(struct xpc_channel *ch) if (ch->flags & XPC_C_DISCONNECTING) { spin_unlock_irqrestore(&ch->lock, irq_flags); - mutex_unlock(®istration->mutex); + up(®istration->sema); return ch->reason; } @@ -1134,7 +1140,7 @@ xpc_connect_channel(struct xpc_channel *ch) * channel lock be locked and will unlock and relock * the channel lock as needed. */ - mutex_unlock(®istration->mutex); + up(®istration->sema); XPC_DISCONNECT_CHANNEL(ch, xpcUnequalMsgSizes, &irq_flags); spin_unlock_irqrestore(&ch->lock, irq_flags); @@ -1149,7 +1155,7 @@ xpc_connect_channel(struct xpc_channel *ch) atomic_inc(&xpc_partitions[ch->partid].nchannels_active); } - mutex_unlock(®istration->mutex); + up(®istration->sema); /* initiate the connection */ @@ -2083,7 +2089,7 @@ xpc_pull_remote_msg(struct xpc_channel *ch, s64 get) enum xpc_retval ret; - if (mutex_lock_interruptible(&ch->msg_to_pull_mutex) != 0) { + if (down_interruptible(&ch->msg_to_pull_sema) != 0) { /* we were interrupted by a signal */ return NULL; } @@ -2119,7 +2125,7 @@ xpc_pull_remote_msg(struct xpc_channel *ch, s64 get) XPC_DEACTIVATE_PARTITION(part, ret); - mutex_unlock(&ch->msg_to_pull_mutex); + up(&ch->msg_to_pull_sema); return NULL; } @@ -2128,7 +2134,7 @@ xpc_pull_remote_msg(struct xpc_channel *ch, s64 get) ch->next_msg_to_pull += nmsgs; } - mutex_unlock(&ch->msg_to_pull_mutex); + up(&ch->msg_to_pull_sema); /* return the message we were looking for */ msg_offset = (get % ch->remote_nentries) * ch->msg_size; diff --git a/trunk/arch/ia64/sn/kernel/xpc_main.c b/trunk/arch/ia64/sn/kernel/xpc_main.c index 9cd460dfe27e..8930586e0eb4 100644 --- a/trunk/arch/ia64/sn/kernel/xpc_main.c +++ b/trunk/arch/ia64/sn/kernel/xpc_main.c @@ -55,7 +55,6 @@ #include #include #include -#include #include #include #include @@ -178,10 +177,10 @@ static DECLARE_WAIT_QUEUE_HEAD(xpc_act_IRQ_wq); static unsigned long xpc_hb_check_timeout; /* notification that the xpc_hb_checker thread has exited */ -static DECLARE_COMPLETION(xpc_hb_checker_exited); +static DECLARE_MUTEX_LOCKED(xpc_hb_checker_exited); /* notification that the xpc_discovery thread has exited */ -static DECLARE_COMPLETION(xpc_discovery_exited); +static DECLARE_MUTEX_LOCKED(xpc_discovery_exited); static struct timer_list xpc_hb_timer; @@ -322,7 +321,7 @@ xpc_hb_checker(void *ignore) /* mark this thread as having exited */ - complete(&xpc_hb_checker_exited); + up(&xpc_hb_checker_exited); return 0; } @@ -342,7 +341,7 @@ xpc_initiate_discovery(void *ignore) dev_dbg(xpc_part, "discovery thread is exiting\n"); /* mark this thread as having exited */ - complete(&xpc_discovery_exited); + up(&xpc_discovery_exited); return 0; } @@ -575,21 +574,18 @@ xpc_activate_partition(struct xpc_partition *part) spin_lock_irqsave(&part->act_lock, irq_flags); - DBUG_ON(part->act_state != XPC_P_INACTIVE); - - part->act_state = XPC_P_ACTIVATION_REQ; - XPC_SET_REASON(part, xpcCloneKThread, __LINE__); - - spin_unlock_irqrestore(&part->act_lock, irq_flags); - pid = kernel_thread(xpc_activating, (void *) ((u64) partid), 0); - if (unlikely(pid <= 0)) { - spin_lock_irqsave(&part->act_lock, irq_flags); - part->act_state = XPC_P_INACTIVE; + DBUG_ON(part->act_state != XPC_P_INACTIVE); + + if (pid > 0) { + part->act_state = XPC_P_ACTIVATION_REQ; + XPC_SET_REASON(part, xpcCloneKThread, __LINE__); + } else { XPC_SET_REASON(part, xpcCloneKThreadFailed, __LINE__); - spin_unlock_irqrestore(&part->act_lock, irq_flags); } + + spin_unlock_irqrestore(&part->act_lock, irq_flags); } @@ -897,7 +893,7 @@ xpc_disconnect_wait(int ch_number) continue; } - wait_for_completion(&ch->wdisconnect_wait); + (void) down(&ch->wdisconnect_sema); spin_lock_irqsave(&ch->lock, irq_flags); DBUG_ON(!(ch->flags & XPC_C_DISCONNECTED)); @@ -950,10 +946,10 @@ xpc_do_exit(enum xpc_retval reason) free_irq(SGI_XPC_ACTIVATE, NULL); /* wait for the discovery thread to exit */ - wait_for_completion(&xpc_discovery_exited); + down(&xpc_discovery_exited); /* wait for the heartbeat checker thread to exit */ - wait_for_completion(&xpc_hb_checker_exited); + down(&xpc_hb_checker_exited); /* sleep for a 1/3 of a second or so */ @@ -1371,7 +1367,7 @@ xpc_init(void) dev_err(xpc_part, "failed while forking discovery thread\n"); /* mark this new thread as a non-starter */ - complete(&xpc_discovery_exited); + up(&xpc_discovery_exited); xpc_do_exit(xpcUnloading); return -EBUSY; diff --git a/trunk/arch/ia64/sn/pci/Makefile b/trunk/arch/ia64/sn/pci/Makefile index c6946784a6a8..321576b1b425 100644 --- a/trunk/arch/ia64/sn/pci/Makefile +++ b/trunk/arch/ia64/sn/pci/Makefile @@ -7,6 +7,4 @@ # # Makefile for the sn pci general routines. -CPPFLAGS += -I$(srctree)/arch/ia64/sn/include - obj-y := pci_dma.o tioca_provider.o tioce_provider.o pcibr/ diff --git a/trunk/arch/ia64/sn/pci/pci_dma.c b/trunk/arch/ia64/sn/pci/pci_dma.c index 5a36292388eb..9bf9f23b9a1f 100644 --- a/trunk/arch/ia64/sn/pci/pci_dma.c +++ b/trunk/arch/ia64/sn/pci/pci_dma.c @@ -90,14 +90,14 @@ void *sn_dma_alloc_coherent(struct device *dev, size_t size, */ node = pcibus_to_node(pdev->bus); if (likely(node >=0)) { - struct page *p = alloc_pages_node(node, flags, get_order(size)); + struct page *p = alloc_pages_node(node, GFP_ATOMIC, get_order(size)); if (likely(p)) cpuaddr = page_address(p); else return NULL; } else - cpuaddr = (void *)__get_free_pages(flags, get_order(size)); + cpuaddr = (void *)__get_free_pages(GFP_ATOMIC, get_order(size)); if (unlikely(!cpuaddr)) return NULL; diff --git a/trunk/arch/ia64/sn/pci/pcibr/Makefile b/trunk/arch/ia64/sn/pci/pcibr/Makefile index 3b403ea456f9..1850c4a94c41 100644 --- a/trunk/arch/ia64/sn/pci/pcibr/Makefile +++ b/trunk/arch/ia64/sn/pci/pcibr/Makefile @@ -7,7 +7,5 @@ # # Makefile for the sn2 io routines. -CPPFLAGS += -I$(srctree)/arch/ia64/sn/include - obj-y += pcibr_dma.o pcibr_reg.o \ pcibr_ate.o pcibr_provider.o diff --git a/trunk/arch/ia64/sn/pci/pcibr/pcibr_provider.c b/trunk/arch/ia64/sn/pci/pcibr/pcibr_provider.c index 2fac27049bf6..77a1262751d3 100644 --- a/trunk/arch/ia64/sn/pci/pcibr/pcibr_provider.c +++ b/trunk/arch/ia64/sn/pci/pcibr/pcibr_provider.c @@ -24,15 +24,13 @@ sal_pcibr_slot_enable(struct pcibus_info *soft, int device, void *resp) { struct ia64_sal_retval ret_stuff; u64 busnum; - u64 segment; ret_stuff.status = 0; ret_stuff.v0 = 0; - segment = soft->pbi_buscommon.bs_persist_segment; busnum = soft->pbi_buscommon.bs_persist_busnum; - SAL_CALL_NOLOCK(ret_stuff, (u64) SN_SAL_IOIF_SLOT_ENABLE, segment, - busnum, (u64) device, (u64) resp, 0, 0, 0); + SAL_CALL_NOLOCK(ret_stuff, (u64) SN_SAL_IOIF_SLOT_ENABLE, (u64) busnum, + (u64) device, (u64) resp, 0, 0, 0, 0); return (int)ret_stuff.v0; } @@ -43,16 +41,14 @@ sal_pcibr_slot_disable(struct pcibus_info *soft, int device, int action, { struct ia64_sal_retval ret_stuff; u64 busnum; - u64 segment; ret_stuff.status = 0; ret_stuff.v0 = 0; - segment = soft->pbi_buscommon.bs_persist_segment; busnum = soft->pbi_buscommon.bs_persist_busnum; SAL_CALL_NOLOCK(ret_stuff, (u64) SN_SAL_IOIF_SLOT_DISABLE, - segment, busnum, (u64) device, (u64) action, - (u64) resp, 0, 0); + (u64) busnum, (u64) device, (u64) action, + (u64) resp, 0, 0, 0); return (int)ret_stuff.v0; } diff --git a/trunk/arch/m32r/kernel/m32r_ksyms.c b/trunk/arch/m32r/kernel/m32r_ksyms.c index be8b711367ec..dbc8a392105f 100644 --- a/trunk/arch/m32r/kernel/m32r_ksyms.c +++ b/trunk/arch/m32r/kernel/m32r_ksyms.c @@ -18,6 +18,11 @@ #include #include +#if defined(CONFIG_BLK_DEV_IDE) || defined(CONFIG_BLK_DEV_HD) || defined(CONFIG_BLK_DEV_IDE_MODULE) || defined(CONFIG_BLK_DEV_HD_MODULE) +extern struct drive_info_struct drive_info; +EXPORT_SYMBOL(drive_info); +#endif + /* platform dependent support */ EXPORT_SYMBOL(boot_cpu_data); EXPORT_SYMBOL(dump_fpu); diff --git a/trunk/arch/m32r/kernel/setup.c b/trunk/arch/m32r/kernel/setup.c index d742037a7ccb..c2e4dccf0112 100644 --- a/trunk/arch/m32r/kernel/setup.c +++ b/trunk/arch/m32r/kernel/setup.c @@ -37,6 +37,12 @@ extern void init_mmu(void); #endif +#if defined(CONFIG_BLK_DEV_IDE) || defined(CONFIG_BLK_DEV_HD) \ + || defined(CONFIG_BLK_DEV_IDE_MODULE) \ + || defined(CONFIG_BLK_DEV_HD_MODULE) +struct drive_info_struct { char dummy[32]; } drive_info; +#endif + extern char _end[]; /* diff --git a/trunk/arch/m68k/fpsp040/bindec.S b/trunk/arch/m68k/fpsp040/bindec.S index 72f1159cb804..3ba446a99a12 100644 --- a/trunk/arch/m68k/fpsp040/bindec.S +++ b/trunk/arch/m68k/fpsp040/bindec.S @@ -131,8 +131,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |BINDEC idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/binstr.S b/trunk/arch/m68k/fpsp040/binstr.S index 8a05ba92a8a0..d53555c0a2b6 100644 --- a/trunk/arch/m68k/fpsp040/binstr.S +++ b/trunk/arch/m68k/fpsp040/binstr.S @@ -60,8 +60,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |BINSTR idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/bugfix.S b/trunk/arch/m68k/fpsp040/bugfix.S index 3bb9c84bb058..942c4f6f4fd1 100644 --- a/trunk/arch/m68k/fpsp040/bugfix.S +++ b/trunk/arch/m68k/fpsp040/bugfix.S @@ -152,8 +152,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |BUGFIX idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/decbin.S b/trunk/arch/m68k/fpsp040/decbin.S index 16ed796bad87..2160609e328d 100644 --- a/trunk/arch/m68k/fpsp040/decbin.S +++ b/trunk/arch/m68k/fpsp040/decbin.S @@ -69,8 +69,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |DECBIN idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/do_func.S b/trunk/arch/m68k/fpsp040/do_func.S index 3eff99a80413..81f6a9856dce 100644 --- a/trunk/arch/m68k/fpsp040/do_func.S +++ b/trunk/arch/m68k/fpsp040/do_func.S @@ -22,8 +22,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. DO_FUNC: |idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/fpsp.h b/trunk/arch/m68k/fpsp040/fpsp.h index 5df4cd772934..984a4eb8010a 100644 --- a/trunk/arch/m68k/fpsp040/fpsp.h +++ b/trunk/arch/m68k/fpsp040/fpsp.h @@ -5,8 +5,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. | fpsp.h --- stack frame offsets during FPSP exception handling | diff --git a/trunk/arch/m68k/fpsp040/gen_except.S b/trunk/arch/m68k/fpsp040/gen_except.S index 3642cb7e3641..401d06f39f73 100644 --- a/trunk/arch/m68k/fpsp040/gen_except.S +++ b/trunk/arch/m68k/fpsp040/gen_except.S @@ -29,8 +29,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. GEN_EXCEPT: |idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/get_op.S b/trunk/arch/m68k/fpsp040/get_op.S index 64c36d79ef83..c7c2f3727425 100644 --- a/trunk/arch/m68k/fpsp040/get_op.S +++ b/trunk/arch/m68k/fpsp040/get_op.S @@ -54,8 +54,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. GET_OP: |idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/kernel_ex.S b/trunk/arch/m68k/fpsp040/kernel_ex.S index 45bcf3455d34..476b711967ce 100644 --- a/trunk/arch/m68k/fpsp040/kernel_ex.S +++ b/trunk/arch/m68k/fpsp040/kernel_ex.S @@ -12,8 +12,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. KERNEL_EX: |idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/res_func.S b/trunk/arch/m68k/fpsp040/res_func.S index d9cdf4383545..8f6b95217865 100644 --- a/trunk/arch/m68k/fpsp040/res_func.S +++ b/trunk/arch/m68k/fpsp040/res_func.S @@ -16,8 +16,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. RES_FUNC: |idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/round.S b/trunk/arch/m68k/fpsp040/round.S index f84ae0dd4358..00f98068783f 100644 --- a/trunk/arch/m68k/fpsp040/round.S +++ b/trunk/arch/m68k/fpsp040/round.S @@ -8,8 +8,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |ROUND idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/sacos.S b/trunk/arch/m68k/fpsp040/sacos.S index 513c7cca7318..83b00ab1c48f 100644 --- a/trunk/arch/m68k/fpsp040/sacos.S +++ b/trunk/arch/m68k/fpsp040/sacos.S @@ -38,8 +38,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |SACOS idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/sasin.S b/trunk/arch/m68k/fpsp040/sasin.S index 2a269a58ceaa..5647a6043903 100644 --- a/trunk/arch/m68k/fpsp040/sasin.S +++ b/trunk/arch/m68k/fpsp040/sasin.S @@ -38,8 +38,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |SASIN idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/satan.S b/trunk/arch/m68k/fpsp040/satan.S index c8a664998f92..20dae222d51e 100644 --- a/trunk/arch/m68k/fpsp040/satan.S +++ b/trunk/arch/m68k/fpsp040/satan.S @@ -43,8 +43,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |satan idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/satanh.S b/trunk/arch/m68k/fpsp040/satanh.S index ba91f77a7571..20f07810bcda 100644 --- a/trunk/arch/m68k/fpsp040/satanh.S +++ b/trunk/arch/m68k/fpsp040/satanh.S @@ -45,8 +45,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |satanh idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/scale.S b/trunk/arch/m68k/fpsp040/scale.S index 04829dd4f1f4..5c9b805265f2 100644 --- a/trunk/arch/m68k/fpsp040/scale.S +++ b/trunk/arch/m68k/fpsp040/scale.S @@ -21,8 +21,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |SCALE idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/scosh.S b/trunk/arch/m68k/fpsp040/scosh.S index 07d3a4d7c86d..e81edbb87642 100644 --- a/trunk/arch/m68k/fpsp040/scosh.S +++ b/trunk/arch/m68k/fpsp040/scosh.S @@ -49,8 +49,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |SCOSH idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/setox.S b/trunk/arch/m68k/fpsp040/setox.S index 145af5447581..0aa75f9bf7d1 100644 --- a/trunk/arch/m68k/fpsp040/setox.S +++ b/trunk/arch/m68k/fpsp040/setox.S @@ -331,8 +331,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |setox idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/sgetem.S b/trunk/arch/m68k/fpsp040/sgetem.S index d9234f4aed57..0fcbd045ba75 100644 --- a/trunk/arch/m68k/fpsp040/sgetem.S +++ b/trunk/arch/m68k/fpsp040/sgetem.S @@ -24,8 +24,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |SGETEM idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/sint.S b/trunk/arch/m68k/fpsp040/sint.S index 0e92d4e5d231..0f9bd28e55a0 100644 --- a/trunk/arch/m68k/fpsp040/sint.S +++ b/trunk/arch/m68k/fpsp040/sint.S @@ -51,8 +51,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |SINT idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/skeleton.S b/trunk/arch/m68k/fpsp040/skeleton.S index a8f41615d94a..a1629194e3fd 100644 --- a/trunk/arch/m68k/fpsp040/skeleton.S +++ b/trunk/arch/m68k/fpsp040/skeleton.S @@ -30,8 +30,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. | | Modified for Linux-1.3.x by Jes Sorensen (jds@kom.auc.dk) diff --git a/trunk/arch/m68k/fpsp040/slog2.S b/trunk/arch/m68k/fpsp040/slog2.S index fac2c738382e..517fa4563246 100644 --- a/trunk/arch/m68k/fpsp040/slog2.S +++ b/trunk/arch/m68k/fpsp040/slog2.S @@ -96,8 +96,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |SLOG2 idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/slogn.S b/trunk/arch/m68k/fpsp040/slogn.S index d98eaf641ec4..2aaa0725c035 100644 --- a/trunk/arch/m68k/fpsp040/slogn.S +++ b/trunk/arch/m68k/fpsp040/slogn.S @@ -63,8 +63,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |slogn idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/smovecr.S b/trunk/arch/m68k/fpsp040/smovecr.S index 73c36512081b..a0127fa55e9c 100644 --- a/trunk/arch/m68k/fpsp040/smovecr.S +++ b/trunk/arch/m68k/fpsp040/smovecr.S @@ -15,8 +15,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |SMOVECR idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/srem_mod.S b/trunk/arch/m68k/fpsp040/srem_mod.S index a27e70c9a0eb..8c8d7f50cc68 100644 --- a/trunk/arch/m68k/fpsp040/srem_mod.S +++ b/trunk/arch/m68k/fpsp040/srem_mod.S @@ -66,8 +66,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. SREM_MOD: |idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/ssin.S b/trunk/arch/m68k/fpsp040/ssin.S index a1ef8e01bf06..043c91cdd657 100644 --- a/trunk/arch/m68k/fpsp040/ssin.S +++ b/trunk/arch/m68k/fpsp040/ssin.S @@ -83,8 +83,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |SSIN idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/ssinh.S b/trunk/arch/m68k/fpsp040/ssinh.S index 8a560edc7653..c8b3308bb143 100644 --- a/trunk/arch/m68k/fpsp040/ssinh.S +++ b/trunk/arch/m68k/fpsp040/ssinh.S @@ -49,8 +49,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |SSINH idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/stan.S b/trunk/arch/m68k/fpsp040/stan.S index f8553aaececb..b5c2a196e617 100644 --- a/trunk/arch/m68k/fpsp040/stan.S +++ b/trunk/arch/m68k/fpsp040/stan.S @@ -50,8 +50,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |STAN idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/stanh.S b/trunk/arch/m68k/fpsp040/stanh.S index 7e12e59ee8c7..33b009802243 100644 --- a/trunk/arch/m68k/fpsp040/stanh.S +++ b/trunk/arch/m68k/fpsp040/stanh.S @@ -49,8 +49,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |STANH idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/sto_res.S b/trunk/arch/m68k/fpsp040/sto_res.S index 484b47d4eaad..0cdca3b060ad 100644 --- a/trunk/arch/m68k/fpsp040/sto_res.S +++ b/trunk/arch/m68k/fpsp040/sto_res.S @@ -19,8 +19,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. STO_RES: |idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/stwotox.S b/trunk/arch/m68k/fpsp040/stwotox.S index 0d5e6a1436a6..4e3c1407d3df 100644 --- a/trunk/arch/m68k/fpsp040/stwotox.S +++ b/trunk/arch/m68k/fpsp040/stwotox.S @@ -76,8 +76,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |STWOTOX idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/tbldo.S b/trunk/arch/m68k/fpsp040/tbldo.S index fd5c37a5a2b9..fe60cf4d20d7 100644 --- a/trunk/arch/m68k/fpsp040/tbldo.S +++ b/trunk/arch/m68k/fpsp040/tbldo.S @@ -17,8 +17,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |TBLDO idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/util.S b/trunk/arch/m68k/fpsp040/util.S index 65b26fa88c60..452f3d65857b 100644 --- a/trunk/arch/m68k/fpsp040/util.S +++ b/trunk/arch/m68k/fpsp040/util.S @@ -16,8 +16,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. |UTIL idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/x_bsun.S b/trunk/arch/m68k/fpsp040/x_bsun.S index d5a576bfac79..039247b09c8b 100644 --- a/trunk/arch/m68k/fpsp040/x_bsun.S +++ b/trunk/arch/m68k/fpsp040/x_bsun.S @@ -13,8 +13,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. X_BSUN: |idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/x_fline.S b/trunk/arch/m68k/fpsp040/x_fline.S index 264e126d1db7..3917710b0fde 100644 --- a/trunk/arch/m68k/fpsp040/x_fline.S +++ b/trunk/arch/m68k/fpsp040/x_fline.S @@ -13,8 +13,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. X_FLINE: |idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/x_operr.S b/trunk/arch/m68k/fpsp040/x_operr.S index e2c371c3a45d..b0f54bcb49a7 100644 --- a/trunk/arch/m68k/fpsp040/x_operr.S +++ b/trunk/arch/m68k/fpsp040/x_operr.S @@ -43,8 +43,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. X_OPERR: |idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/x_ovfl.S b/trunk/arch/m68k/fpsp040/x_ovfl.S index 6fe4989ee31f..22cb8b42c7b6 100644 --- a/trunk/arch/m68k/fpsp040/x_ovfl.S +++ b/trunk/arch/m68k/fpsp040/x_ovfl.S @@ -35,8 +35,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. X_OVFL: |idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/x_snan.S b/trunk/arch/m68k/fpsp040/x_snan.S index 4ed766416378..039af573312e 100644 --- a/trunk/arch/m68k/fpsp040/x_snan.S +++ b/trunk/arch/m68k/fpsp040/x_snan.S @@ -22,8 +22,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. X_SNAN: |idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/x_store.S b/trunk/arch/m68k/fpsp040/x_store.S index 402dc0c0ebc0..4282fa67d449 100644 --- a/trunk/arch/m68k/fpsp040/x_store.S +++ b/trunk/arch/m68k/fpsp040/x_store.S @@ -11,8 +11,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. X_STORE: |idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/x_unfl.S b/trunk/arch/m68k/fpsp040/x_unfl.S index eb772ff3b812..077fcc230fcc 100644 --- a/trunk/arch/m68k/fpsp040/x_unfl.S +++ b/trunk/arch/m68k/fpsp040/x_unfl.S @@ -21,8 +21,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. X_UNFL: |idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/x_unimp.S b/trunk/arch/m68k/fpsp040/x_unimp.S index 6f382b21228b..920cb9410e9e 100644 --- a/trunk/arch/m68k/fpsp040/x_unimp.S +++ b/trunk/arch/m68k/fpsp040/x_unimp.S @@ -22,8 +22,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. X_UNIMP: |idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68k/fpsp040/x_unsupp.S b/trunk/arch/m68k/fpsp040/x_unsupp.S index d7cf46208c62..4ec57285b683 100644 --- a/trunk/arch/m68k/fpsp040/x_unsupp.S +++ b/trunk/arch/m68k/fpsp040/x_unsupp.S @@ -23,8 +23,9 @@ | Copyright (C) Motorola, Inc. 1990 | All Rights Reserved | -| For details on the license for this file, please see the -| file, README, in this same directory. +| THIS IS UNPUBLISHED PROPRIETARY SOURCE CODE OF MOTOROLA +| The copyright notice above does not evidence any +| actual or intended publication of such source code. X_UNSUPP: |idnt 2,1 | Motorola 040 Floating Point Software Package diff --git a/trunk/arch/m68knommu/kernel/process.c b/trunk/arch/m68knommu/kernel/process.c index 63c117dae0c3..99bf43824795 100644 --- a/trunk/arch/m68knommu/kernel/process.c +++ b/trunk/arch/m68knommu/kernel/process.c @@ -39,14 +39,6 @@ asmlinkage void ret_from_fork(void); -/* - * The following aren't currently used. - */ -void (*pm_idle)(void); -EXPORT_SYMBOL(pm_idle); - -void (*pm_power_off)(void); -EXPORT_SYMBOL(pm_power_off); /* * The idle loop on an m68knommu.. diff --git a/trunk/arch/mips/Kconfig b/trunk/arch/mips/Kconfig index 767de847b4ab..c3e852e9953e 100644 --- a/trunk/arch/mips/Kconfig +++ b/trunk/arch/mips/Kconfig @@ -595,7 +595,6 @@ config SGI_IP32 select SYS_HAS_CPU_R5000 select SYS_HAS_CPU_R10000 if BROKEN select SYS_HAS_CPU_RM7000 - select SYS_HAS_CPU_NEVADA select SYS_SUPPORTS_64BIT_KERNEL select SYS_SUPPORTS_BIG_ENDIAN help diff --git a/trunk/arch/mips/Makefile b/trunk/arch/mips/Makefile index 6a57407df1bc..2a9f2ef27b29 100644 --- a/trunk/arch/mips/Makefile +++ b/trunk/arch/mips/Makefile @@ -53,17 +53,14 @@ CROSS_COMPILE := $(tool-prefix) endif CHECKFLAGS-y += -D__linux__ -D__mips__ \ - -D_MIPS_SZINT=32 \ -D_ABIO32=1 \ -D_ABIN32=2 \ -D_ABI64=3 CHECKFLAGS-$(CONFIG_32BIT) += -D_MIPS_SIM=_ABIO32 \ -D_MIPS_SZLONG=32 \ - -D_MIPS_SZPTR=32 \ -D__PTRDIFF_TYPE__=int CHECKFLAGS-$(CONFIG_64BIT) += -m64 -D_MIPS_SIM=_ABI64 \ -D_MIPS_SZLONG=64 \ - -D_MIPS_SZPTR=64 \ -D__PTRDIFF_TYPE__="long int" CHECKFLAGS-$(CONFIG_CPU_BIG_ENDIAN) += -D__MIPSEB__ CHECKFLAGS-$(CONFIG_CPU_LITTLE_ENDIAN) += -D__MIPSEL__ @@ -169,97 +166,79 @@ echo $$gcc_abi $$gcc_opt$$gcc_cpu $$gcc_isa $$gas_abi $$gas_opt$$gas_cpu $$gas_i # cflags-$(CONFIG_CPU_R3000) += \ $(call set_gccflags,r3000,mips1,r3000,mips1,mips1) -CHECKFLAGS-$(CONFIG_CPU_R3000) += -D_MIPS_ISA=_MIPS_ISA_MIPS1 cflags-$(CONFIG_CPU_TX39XX) += \ $(call set_gccflags,r3900,mips1,r3000,mips1,mips1) -CHECKFLAGS-$(CONFIG_CPU_TX39XX) += -D_MIPS_ISA=_MIPS_ISA_MIPS1 cflags-$(CONFIG_CPU_R6000) += \ $(call set_gccflags,r6000,mips2,r6000,mips2,mips2) \ -Wa,--trap -CHECKFLAGS-$(CONFIG_CPU_R6000) += -D_MIPS_ISA=_MIPS_ISA_MIPS2 cflags-$(CONFIG_CPU_R4300) += \ $(call set_gccflags,r4300,mips3,r4300,mips3,mips2) \ -Wa,--trap -CHECKFLAGS-$(CONFIG_CPU_R4300) += -D_MIPS_ISA=_MIPS_ISA_MIPS3 cflags-$(CONFIG_CPU_VR41XX) += \ $(call set_gccflags,r4100,mips3,r4600,mips3,mips2) \ -Wa,--trap -CHECKFLAGS-$(CONFIG_CPU_VR41XX) += -D_MIPS_ISA=_MIPS_ISA_MIPS3 cflags-$(CONFIG_CPU_R4X00) += \ $(call set_gccflags,r4600,mips3,r4600,mips3,mips2) \ -Wa,--trap -CHECKFLAGS-$(CONFIG_CPU_R4X00) += -D_MIPS_ISA=_MIPS_ISA_MIPS3 cflags-$(CONFIG_CPU_TX49XX) += \ $(call set_gccflags,r4600,mips3,r4600,mips3,mips2) \ -Wa,--trap -CHECKFLAGS-$(CONFIG_CPU_TX49XX) += -D_MIPS_ISA=_MIPS_ISA_MIPS3 cflags-$(CONFIG_CPU_MIPS32_R1) += \ $(call set_gccflags,mips32,mips32,r4600,mips3,mips2) \ -Wa,--trap -CHECKFLAGS-$(CONFIG_CPU_MIPS32_R1) += -D_MIPS_ISA=_MIPS_ISA_MIPS32 cflags-$(CONFIG_CPU_MIPS32_R2) += \ $(call set_gccflags,mips32r2,mips32r2,r4600,mips3,mips2) \ -Wa,--trap -CHECKFLAGS-$(CONFIG_CPU_MIPS32_R2) += -D_MIPS_ISA=_MIPS_ISA_MIPS32 cflags-$(CONFIG_CPU_MIPS64_R1) += \ $(call set_gccflags,mips64,mips64,r4600,mips3,mips2) \ -Wa,--trap -CHECKFLAGS-$(CONFIG_CPU_MIPS64_R1) += -D_MIPS_ISA=_MIPS_ISA_MIPS64 cflags-$(CONFIG_CPU_MIPS64_R2) += \ $(call set_gccflags,mips64r2,mips64r2,r4600,mips3,mips2) \ -Wa,--trap -CHECKFLAGS-$(CONFIG_CPU_MIPS64_R2) += -D_MIPS_ISA=_MIPS_ISA_MIPS64 cflags-$(CONFIG_CPU_R5000) += \ $(call set_gccflags,r5000,mips4,r5000,mips4,mips2) \ -Wa,--trap -CHECKFLAGS-$(CONFIG_CPU_R5000) += -D_MIPS_ISA=_MIPS_ISA_MIPS4 cflags-$(CONFIG_CPU_R5432) += \ $(call set_gccflags,r5400,mips4,r5000,mips4,mips2) \ -Wa,--trap -CHECKFLAGS-$(CONFIG_CPU_R5432) += -D_MIPS_ISA=_MIPS_ISA_MIPS4 cflags-$(CONFIG_CPU_NEVADA) += \ $(call set_gccflags,rm5200,mips4,r5000,mips4,mips2) \ -Wa,--trap -CHECKFLAGS-$(CONFIG_CPU_NEVADA) += -D_MIPS_ISA=_MIPS_ISA_MIPS4 +# $(call cc-option,-mmad) cflags-$(CONFIG_CPU_RM7000) += \ $(call set_gccflags,rm7000,mips4,r5000,mips4,mips2) \ -Wa,--trap -CHECKFLAGS-$(CONFIG_CPU_RM7000) += -D_MIPS_ISA=_MIPS_ISA_MIPS4 cflags-$(CONFIG_CPU_RM9000) += \ $(call set_gccflags,rm9000,mips4,r5000,mips4,mips2) \ -Wa,--trap -CHECKFLAGS-$(CONFIG_CPU_RM9000) += -D_MIPS_ISA=_MIPS_ISA_MIPS4 cflags-$(CONFIG_CPU_SB1) += \ $(call set_gccflags,sb1,mips64,r5000,mips4,mips2) \ -Wa,--trap -CHECKFLAGS-$(CONFIG_CPU_SB1) += -D_MIPS_ISA=_MIPS_ISA_MIPS64 cflags-$(CONFIG_CPU_R8000) += \ $(call set_gccflags,r8000,mips4,r8000,mips4,mips2) \ -Wa,--trap -CHECKFLAGS-$(CONFIG_CPU_R8000) += -D_MIPS_ISA=_MIPS_ISA_MIPS4 cflags-$(CONFIG_CPU_R10000) += \ $(call set_gccflags,r10000,mips4,r8000,mips4,mips2) \ -Wa,--trap -CHECKFLAGS-$(CONFIG_CPU_R10000) += -D_MIPS_ISA=_MIPS_ISA_MIPS4 ifdef CONFIG_CPU_SB1 ifdef CONFIG_SB1_PASS_1_WORKAROUNDS @@ -390,7 +369,7 @@ load-$(CONFIG_MIPS_XXS1500) += 0xffffffff80100000 # Cobalt Server # core-$(CONFIG_MIPS_COBALT) += arch/mips/cobalt/ -cflags-$(CONFIG_MIPS_COBALT) += -Iinclude/asm-mips/mach-cobalt +cflags-$(CONFIG_MIPS_COBALT) += -Iinclude/asm-mips/cobalt load-$(CONFIG_MIPS_COBALT) += 0xffffffff80080000 # diff --git a/trunk/arch/mips/au1000/common/reset.c b/trunk/arch/mips/au1000/common/reset.c index 4ffccedf5967..65b84db800e4 100644 --- a/trunk/arch/mips/au1000/common/reset.c +++ b/trunk/arch/mips/au1000/common/reset.c @@ -151,7 +151,7 @@ void au1000_restart(char *command) } set_c0_status(ST0_BEV | ST0_ERL); - change_c0_config(CONF_CM_CMASK, CONF_CM_UNCACHED); + set_c0_config(CONF_CM_UNCACHED); flush_cache_all(); write_c0_wired(0); diff --git a/trunk/arch/mips/au1000/common/setup.c b/trunk/arch/mips/au1000/common/setup.c index eb155c071aa6..08c8c855cc9c 100644 --- a/trunk/arch/mips/au1000/common/setup.c +++ b/trunk/arch/mips/au1000/common/setup.c @@ -33,7 +33,6 @@ #include #include #include -#include #include #include @@ -126,7 +125,7 @@ void __init plat_setup(void) #endif _machine_restart = au1000_restart; _machine_halt = au1000_halt; - pm_power_off = au1000_power_off; + _machine_power_off = au1000_power_off; board_time_init = au1xxx_time_init; board_timer_setup = au1xxx_timer_setup; diff --git a/trunk/arch/mips/cobalt/int-handler.S b/trunk/arch/mips/cobalt/int-handler.S index e75d5e3ca868..f92608e8d84f 100644 --- a/trunk/arch/mips/cobalt/int-handler.S +++ b/trunk/arch/mips/cobalt/int-handler.S @@ -8,7 +8,7 @@ */ #include #include -#include +#include #include #include diff --git a/trunk/arch/mips/cobalt/irq.c b/trunk/arch/mips/cobalt/irq.c index f9a108820d6e..0d90851f925e 100644 --- a/trunk/arch/mips/cobalt/irq.c +++ b/trunk/arch/mips/cobalt/irq.c @@ -18,7 +18,7 @@ #include #include -#include +#include extern void cobalt_handle_int(void); diff --git a/trunk/arch/mips/cobalt/reset.c b/trunk/arch/mips/cobalt/reset.c index 753dfccae6fa..805a0e88507b 100644 --- a/trunk/arch/mips/cobalt/reset.c +++ b/trunk/arch/mips/cobalt/reset.c @@ -16,7 +16,7 @@ #include #include #include -#include +#include void cobalt_machine_halt(void) { diff --git a/trunk/arch/mips/cobalt/setup.c b/trunk/arch/mips/cobalt/setup.c index b9713a723053..d358a118fa31 100644 --- a/trunk/arch/mips/cobalt/setup.c +++ b/trunk/arch/mips/cobalt/setup.c @@ -5,7 +5,7 @@ * License. See the file "COPYING" in the main directory of this archive * for more details. * - * Copyright (C) 1996, 1997, 2004, 05 by Ralf Baechle (ralf@linux-mips.org) + * Copyright (C) 1996, 1997, 2004 by Ralf Baechle (ralf@linux-mips.org) * Copyright (C) 2001, 2002, 2003 by Liam Davies (ldavies@agile.tv) * */ @@ -13,7 +13,6 @@ #include #include #include -#include #include #include @@ -26,7 +25,7 @@ #include #include -#include +#include extern void cobalt_machine_restart(char *command); extern void cobalt_machine_halt(void); @@ -100,7 +99,7 @@ void __init plat_setup(void) _machine_restart = cobalt_machine_restart; _machine_halt = cobalt_machine_halt; - pm_power_off = cobalt_machine_power_off; + _machine_power_off = cobalt_machine_power_off; board_timer_setup = cobalt_timer_setup; @@ -140,7 +139,7 @@ void __init plat_setup(void) uart.type = PORT_UNKNOWN; uart.uartclk = 18432000; uart.irq = COBALT_SERIAL_IRQ; - uart.flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST; + uart.flags = STD_COM_FLAGS; uart.iobase = 0xc800000; uart.iotype = UPIO_PORT; diff --git a/trunk/arch/mips/configs/ip32_defconfig b/trunk/arch/mips/configs/ip32_defconfig index a34db6e82b27..967e7acd8e1f 100644 --- a/trunk/arch/mips/configs/ip32_defconfig +++ b/trunk/arch/mips/configs/ip32_defconfig @@ -102,7 +102,6 @@ CONFIG_CPU_R5000=y # CONFIG_CPU_RM9000 is not set # CONFIG_CPU_SB1 is not set CONFIG_SYS_HAS_CPU_R5000=y -CONFIG_SYS_HAS_CPU_NEVADA=y CONFIG_SYS_HAS_CPU_RM7000=y CONFIG_SYS_SUPPORTS_64BIT_KERNEL=y CONFIG_CPU_SUPPORTS_32BIT_KERNEL=y diff --git a/trunk/arch/mips/configs/qemu_defconfig b/trunk/arch/mips/configs/qemu_defconfig index c02becab850b..dee44606164c 100644 --- a/trunk/arch/mips/configs/qemu_defconfig +++ b/trunk/arch/mips/configs/qemu_defconfig @@ -1,7 +1,7 @@ # # Automatically generated make config: don't edit -# Linux kernel version: 2.6.16-rc2 -# Fri Feb 3 17:14:27 2006 +# Linux kernel version: 2.6.15-rc2 +# Thu Nov 24 01:07:00 2005 # CONFIG_MIPS=y @@ -147,27 +147,26 @@ CONFIG_LOCALVERSION_AUTO=y # CONFIG_BSD_PROCESS_ACCT is not set # CONFIG_SYSCTL is not set # CONFIG_AUDIT is not set +# CONFIG_HOTPLUG is not set +CONFIG_KOBJECT_UEVENT=y # CONFIG_IKCONFIG is not set CONFIG_INITRAMFS_SOURCE="" CONFIG_EMBEDDED=y CONFIG_KALLSYMS=y # CONFIG_KALLSYMS_EXTRA_PASS is not set -# CONFIG_HOTPLUG is not set CONFIG_PRINTK=y # CONFIG_BUG is not set -CONFIG_ELF_CORE=y # CONFIG_BASE_FULL is not set # CONFIG_FUTEX is not set # CONFIG_EPOLL is not set +# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set # CONFIG_SHMEM is not set CONFIG_CC_ALIGN_FUNCTIONS=0 CONFIG_CC_ALIGN_LABELS=0 CONFIG_CC_ALIGN_LOOPS=0 CONFIG_CC_ALIGN_JUMPS=0 -CONFIG_SLAB=y CONFIG_TINY_SHMEM=y CONFIG_BASE_SMALL=1 -# CONFIG_SLOB is not set # # Loadable module support @@ -267,7 +266,11 @@ CONFIG_TCP_CONG_BIC=y # CONFIG_HAMRADIO is not set # CONFIG_IRDA is not set # CONFIG_BT is not set -# CONFIG_IEEE80211 is not set +CONFIG_IEEE80211=y +# CONFIG_IEEE80211_DEBUG is not set +CONFIG_IEEE80211_CRYPT_WEP=y +CONFIG_IEEE80211_CRYPT_CCMP=y +CONFIG_IEEE80211_CRYPT_TKIP=y # # Device Drivers @@ -320,7 +323,7 @@ CONFIG_BLK_DEV_RAM_COUNT=16 # # SCSI device support # -# CONFIG_RAID_ATTRS is not set +CONFIG_RAID_ATTRS=y # CONFIG_SCSI is not set # @@ -363,16 +366,24 @@ CONFIG_NETDEVICES=y # # PHY device support # -# CONFIG_PHYLIB is not set +CONFIG_PHYLIB=y + +# +# MII PHY device drivers +# +CONFIG_MARVELL_PHY=y +CONFIG_DAVICOM_PHY=y +CONFIG_QSEMI_PHY=y +CONFIG_LXT_PHY=y +CONFIG_CICADA_PHY=y # # Ethernet (10 or 100Mbit) # CONFIG_NET_ETHERNET=y -# CONFIG_MII is not set +CONFIG_MII=y # CONFIG_NET_VENDOR_3COM is not set # CONFIG_NET_VENDOR_SMC is not set -# CONFIG_DM9000 is not set # CONFIG_NET_VENDOR_RACAL is not set # CONFIG_DEPCA is not set # CONFIG_HP100 is not set @@ -468,7 +479,6 @@ CONFIG_HW_CONSOLE=y CONFIG_SERIAL_8250=y CONFIG_SERIAL_8250_CONSOLE=y CONFIG_SERIAL_8250_NR_UARTS=4 -CONFIG_SERIAL_8250_RUNTIME_UARTS=4 # CONFIG_SERIAL_8250_EXTENDED is not set # @@ -507,12 +517,6 @@ CONFIG_SERIAL_CORE_CONSOLE=y # # CONFIG_I2C is not set -# -# SPI support -# -# CONFIG_SPI is not set -# CONFIG_SPI_MASTER is not set - # # Dallas's 1-wire bus # @@ -587,15 +591,12 @@ CONFIG_DUMMY_CONSOLE=y # SN Devices # -# -# EDAC - error detection and reporting (RAS) -# - # # File systems # # CONFIG_EXT2_FS is not set # CONFIG_EXT3_FS is not set +# CONFIG_JBD is not set # CONFIG_REISERFS_FS is not set # CONFIG_JFS_FS is not set # CONFIG_FS_POSIX_ACL is not set @@ -676,7 +677,6 @@ CONFIG_MSDOS_PARTITION=y # Kernel hacking # # CONFIG_PRINTK_TIME is not set -# CONFIG_MAGIC_SYSRQ is not set # CONFIG_DEBUG_KERNEL is not set CONFIG_LOG_BUF_SHIFT=14 CONFIG_CROSSCOMPILE=y @@ -690,7 +690,31 @@ CONFIG_CMDLINE="console=ttyS0 debug ip=172.20.0.2:172.20.0.1::255.255.0.0" # # Cryptographic options # -# CONFIG_CRYPTO is not set +CONFIG_CRYPTO=y +CONFIG_CRYPTO_HMAC=y +CONFIG_CRYPTO_NULL=y +CONFIG_CRYPTO_MD4=y +CONFIG_CRYPTO_MD5=y +CONFIG_CRYPTO_SHA1=y +CONFIG_CRYPTO_SHA256=y +CONFIG_CRYPTO_SHA512=y +CONFIG_CRYPTO_WP512=y +CONFIG_CRYPTO_TGR192=y +CONFIG_CRYPTO_DES=y +CONFIG_CRYPTO_BLOWFISH=y +CONFIG_CRYPTO_TWOFISH=y +CONFIG_CRYPTO_SERPENT=y +CONFIG_CRYPTO_AES=y +CONFIG_CRYPTO_CAST5=y +CONFIG_CRYPTO_CAST6=y +CONFIG_CRYPTO_TEA=y +CONFIG_CRYPTO_ARC4=y +CONFIG_CRYPTO_KHAZAD=y +CONFIG_CRYPTO_ANUBIS=y +CONFIG_CRYPTO_DEFLATE=y +CONFIG_CRYPTO_MICHAEL_MIC=y +CONFIG_CRYPTO_CRC32C=y +# CONFIG_CRYPTO_TEST is not set # # Hardware crypto devices @@ -700,6 +724,8 @@ CONFIG_CMDLINE="console=ttyS0 debug ip=172.20.0.2:172.20.0.1::255.255.0.0" # Library routines # # CONFIG_CRC_CCITT is not set -# CONFIG_CRC16 is not set +CONFIG_CRC16=y CONFIG_CRC32=y -# CONFIG_LIBCRC32C is not set +CONFIG_LIBCRC32C=y +CONFIG_ZLIB_INFLATE=y +CONFIG_ZLIB_DEFLATE=y diff --git a/trunk/arch/mips/ddb5xxx/ddb5074/setup.c b/trunk/arch/mips/ddb5xxx/ddb5074/setup.c index 91456b068c2e..11535be265b9 100644 --- a/trunk/arch/mips/ddb5xxx/ddb5074/setup.c +++ b/trunk/arch/mips/ddb5xxx/ddb5074/setup.c @@ -14,7 +14,6 @@ #include #include #include -#include #include #include @@ -96,7 +95,7 @@ void __init plat_setup(void) _machine_restart = ddb_machine_restart; _machine_halt = ddb_machine_halt; - pm_power_off = ddb_machine_power_off; + _machine_power_off = ddb_machine_power_off; ddb_out32(DDB_BAR0, 0); diff --git a/trunk/arch/mips/ddb5xxx/ddb5476/setup.c b/trunk/arch/mips/ddb5xxx/ddb5476/setup.c index c902adef5942..f4e480a74edf 100644 --- a/trunk/arch/mips/ddb5xxx/ddb5476/setup.c +++ b/trunk/arch/mips/ddb5xxx/ddb5476/setup.c @@ -11,7 +11,6 @@ #include #include #include -#include #include #include @@ -134,7 +133,7 @@ void __init plat_setup(void) _machine_restart = ddb_machine_restart; _machine_halt = ddb_machine_halt; - pm_power_off = ddb_machine_power_off; + _machine_power_off = ddb_machine_power_off; /* request io port/mem resources */ if (request_resource(&ioport_resource, &ddb5476_ioport.dma1) || diff --git a/trunk/arch/mips/ddb5xxx/ddb5477/setup.c b/trunk/arch/mips/ddb5xxx/ddb5477/setup.c index 2f566034cc44..81163353c4a8 100644 --- a/trunk/arch/mips/ddb5xxx/ddb5477/setup.c +++ b/trunk/arch/mips/ddb5xxx/ddb5477/setup.c @@ -26,7 +26,6 @@ #include #include #include -#include #include #include @@ -183,7 +182,7 @@ void __init plat_setup(void) _machine_restart = ddb_machine_restart; _machine_halt = ddb_machine_halt; - pm_power_off = ddb_machine_power_off; + _machine_power_off = ddb_machine_power_off; /* setup resource limits */ ioport_resource.end = DDB_PCI0_IO_SIZE + DDB_PCI1_IO_SIZE - 1; diff --git a/trunk/arch/mips/dec/setup.c b/trunk/arch/mips/dec/setup.c index 7c1ca8f6330e..9ef54fe1feaa 100644 --- a/trunk/arch/mips/dec/setup.c +++ b/trunk/arch/mips/dec/setup.c @@ -17,7 +17,6 @@ #include #include #include -#include #include #include @@ -159,7 +158,7 @@ void __init plat_setup(void) _machine_restart = dec_machine_restart; _machine_halt = dec_machine_halt; - pm_power_off = dec_machine_power_off; + _machine_power_off = dec_machine_power_off; ioport_resource.start = ~0UL; ioport_resource.end = 0UL; diff --git a/trunk/arch/mips/gt64120/ev64120/setup.c b/trunk/arch/mips/gt64120/ev64120/setup.c index 6d859d1e7a2d..98b5a96cc039 100644 --- a/trunk/arch/mips/gt64120/ev64120/setup.c +++ b/trunk/arch/mips/gt64120/ev64120/setup.c @@ -34,8 +34,6 @@ #include #include #include -#include - #include #include #include @@ -75,7 +73,7 @@ void __init plat_setup(void) { _machine_restart = galileo_machine_restart; _machine_halt = galileo_machine_halt; - pm_power_off = galileo_machine_power_off; + _machine_power_off = galileo_machine_power_off; board_time_init = gt64120_time_init; set_io_port_base(KSEG1); diff --git a/trunk/arch/mips/gt64120/momenco_ocelot/setup.c b/trunk/arch/mips/gt64120/momenco_ocelot/setup.c index 20b65d3d2151..0d07c33112d0 100644 --- a/trunk/arch/mips/gt64120/momenco_ocelot/setup.c +++ b/trunk/arch/mips/gt64120/momenco_ocelot/setup.c @@ -4,7 +4,7 @@ * BRIEF MODULE DESCRIPTION * Momentum Computer Ocelot (CP7000) - board dependent boot routines * - * Copyright (C) 1996, 1997, 2001, 06 Ralf Baechle (ralf@linux-mips.org) + * Copyright (C) 1996, 1997, 2001 Ralf Baechle * Copyright (C) 2000 RidgeRun, Inc. * Copyright (C) 2001 Red Hat, Inc. * Copyright (C) 2002 Momentum Computer @@ -47,8 +47,6 @@ #include #include #include -#include - #include #include #include @@ -161,7 +159,7 @@ void __init plat_setup(void) _machine_restart = momenco_ocelot_restart; _machine_halt = momenco_ocelot_halt; - pm_power_off = momenco_ocelot_power_off; + _machine_power_off = momenco_ocelot_power_off; /* * initrd_start = (ulong)ocelot_initrd_start; diff --git a/trunk/arch/mips/ite-boards/generic/it8172_setup.c b/trunk/arch/mips/ite-boards/generic/it8172_setup.c index fc73c8d69df7..062429dd7ca0 100644 --- a/trunk/arch/mips/ite-boards/generic/it8172_setup.c +++ b/trunk/arch/mips/ite-boards/generic/it8172_setup.c @@ -34,7 +34,6 @@ #include #include #include -#include #include #include @@ -126,7 +125,7 @@ void __init plat_setup(void) _machine_restart = it8172_restart; _machine_halt = it8172_halt; - pm_power_off = it8172_power_off; + _machine_power_off = it8172_power_off; /* * IO/MEM resources. diff --git a/trunk/arch/mips/jazz/setup.c b/trunk/arch/mips/jazz/setup.c index 4036dc434551..044df9d4ab7c 100644 --- a/trunk/arch/mips/jazz/setup.c +++ b/trunk/arch/mips/jazz/setup.c @@ -19,8 +19,6 @@ #include #include #include -#include - #include #include #include @@ -81,7 +79,7 @@ void __init plat_setup(void) _machine_restart = jazz_machine_restart; _machine_halt = jazz_machine_halt; - pm_power_off = jazz_machine_power_off; + _machine_power_off = jazz_machine_power_off; #warning "Somebody should check if screen_info is ok for Jazz." diff --git a/trunk/arch/mips/jmr3927/rbhma3100/setup.c b/trunk/arch/mips/jmr3927/rbhma3100/setup.c index 9359cc413494..4763957df8fc 100644 --- a/trunk/arch/mips/jmr3927/rbhma3100/setup.c +++ b/trunk/arch/mips/jmr3927/rbhma3100/setup.c @@ -44,7 +44,6 @@ #include #include /* for HZ */ #include -#include #ifdef CONFIG_SERIAL_TXX9 #include #include @@ -212,7 +211,7 @@ void __init plat_setup(void) _machine_restart = jmr3927_machine_restart; _machine_halt = jmr3927_machine_halt; - pm_power_off = jmr3927_machine_power_off; + _machine_power_off = jmr3927_machine_power_off; /* * IO/MEM resources. diff --git a/trunk/arch/mips/kernel/cpu-probe.c b/trunk/arch/mips/kernel/cpu-probe.c index 292f8b243a5e..fac48ad27b34 100644 --- a/trunk/arch/mips/kernel/cpu-probe.c +++ b/trunk/arch/mips/kernel/cpu-probe.c @@ -2,8 +2,8 @@ * Processor capabilities determination functions. * * Copyright (C) xxxx the Anonymous - * Copyright (C) 1994 - 2006 Ralf Baechle * Copyright (C) 2003, 2004 Maciej W. Rozycki + * Copyright (C) 1994 - 2003 Ralf Baechle * Copyright (C) 2001, 2004 MIPS Inc. * * This program is free software; you can redistribute it and/or @@ -641,9 +641,10 @@ static inline void cpu_probe_sibyte(struct cpuinfo_mips *c) switch (c->processor_id & 0xff00) { case PRID_IMP_SB1: c->cputype = CPU_SB1; +#ifdef CONFIG_SB1_PASS_1_WORKAROUNDS /* FPU in pass1 is known to have issues. */ - if ((c->processor_id & 0xff) < 0x20) - c->options &= ~(MIPS_CPU_FPU | MIPS_CPU_32FPR); + c->options &= ~(MIPS_CPU_FPU | MIPS_CPU_32FPR); +#endif break; case PRID_IMP_SB1A: c->cputype = CPU_SB1A; diff --git a/trunk/arch/mips/kernel/gdb-stub.c b/trunk/arch/mips/kernel/gdb-stub.c index d4f88e0af24c..96d18c43dca0 100644 --- a/trunk/arch/mips/kernel/gdb-stub.c +++ b/trunk/arch/mips/kernel/gdb-stub.c @@ -178,7 +178,7 @@ int kgdb_enabled; */ static DEFINE_SPINLOCK(kgdb_lock); static raw_spinlock_t kgdb_cpulock[NR_CPUS] = { - [0 ... NR_CPUS-1] = __RAW_SPIN_LOCK_UNLOCKED, + [0 ... NR_CPUS-1] = __RAW_SPIN_LOCK_UNLOCKED; }; /* diff --git a/trunk/arch/mips/kernel/genex.S b/trunk/arch/mips/kernel/genex.S index 13f22d1d0e8b..aa18a8b7b380 100644 --- a/trunk/arch/mips/kernel/genex.S +++ b/trunk/arch/mips/kernel/genex.S @@ -233,11 +233,11 @@ NESTED(except_vec_nmi, 0, sp) NESTED(nmi_handler, PT_SIZE, sp) .set push .set noat + .set mips3 SAVE_ALL move a0, sp jal nmi_exception_handler RESTORE_ALL - .set mips3 eret .set pop END(nmi_handler) diff --git a/trunk/arch/mips/kernel/process.c b/trunk/arch/mips/kernel/process.c index 5232fc752935..fa98f10d0132 100644 --- a/trunk/arch/mips/kernel/process.c +++ b/trunk/arch/mips/kernel/process.c @@ -4,7 +4,6 @@ * for more details. * * Copyright (C) 1994 - 1999, 2000 by Ralf Baechle and others. - * Copyright (C) 2005, 2006 by Ralf Baechle (ralf@linux-mips.org) * Copyright (C) 1999, 2000 Silicon Graphics, Inc. * Copyright (C) 2004 Thiemo Seufer */ @@ -59,8 +58,8 @@ ATTRIB_NORET void cpu_idle(void) } } -extern void do_signal(struct pt_regs *regs); -extern void do_signal32(struct pt_regs *regs); +extern int do_signal(sigset_t *oldset, struct pt_regs *regs); +extern int do_signal32(sigset_t *oldset, struct pt_regs *regs); /* * Native o32 and N64 ABI without DSP ASE diff --git a/trunk/arch/mips/kernel/ptrace32.c b/trunk/arch/mips/kernel/ptrace32.c index 0d5cf97af727..0c82b25d8c6d 100644 --- a/trunk/arch/mips/kernel/ptrace32.c +++ b/trunk/arch/mips/kernel/ptrace32.c @@ -88,7 +88,7 @@ asmlinkage int sys32_ptrace(int request, int pid, int addr, int data) ret = -EIO; if (copied != sizeof(tmp)) break; - ret = put_user(tmp, (unsigned int __user *) (unsigned long) data); + ret = put_user(tmp, (unsigned int *) (unsigned long) data); break; } @@ -174,10 +174,8 @@ asmlinkage int sys32_ptrace(int request, int pid, int addr, int data) case FPC_EIR: { /* implementation / version register */ unsigned int flags; - if (!cpu_has_fpu) { - tmp = 0; + if (!cpu_has_fpu) break; - } preempt_disable(); if (cpu_has_mipsmt) { @@ -196,18 +194,15 @@ asmlinkage int sys32_ptrace(int request, int pid, int addr, int data) preempt_enable(); break; } - case DSP_BASE ... DSP_BASE + 5: { - dspreg_t *dregs; - + case DSP_BASE ... DSP_BASE + 5: if (!cpu_has_dsp) { tmp = 0; ret = -EIO; goto out_tsk; } - dregs = __get_dsp_regs(child); + dspreg_t *dregs = __get_dsp_regs(child); tmp = (unsigned long) (dregs[addr - DSP_BASE]); break; - } case DSP_CONTROL: if (!cpu_has_dsp) { tmp = 0; @@ -221,7 +216,7 @@ asmlinkage int sys32_ptrace(int request, int pid, int addr, int data) ret = -EIO; goto out_tsk; } - ret = put_user(tmp, (unsigned __user *) (unsigned long) data); + ret = put_user(tmp, (unsigned *) (unsigned long) data); break; } @@ -309,18 +304,15 @@ asmlinkage int sys32_ptrace(int request, int pid, int addr, int data) else child->thread.fpu.soft.fcr31 = data; break; - case DSP_BASE ... DSP_BASE + 5: { - dspreg_t *dregs; - + case DSP_BASE ... DSP_BASE + 5: if (!cpu_has_dsp) { ret = -EIO; break; } - dregs = __get_dsp_regs(child); + dspreg_t *dregs = __get_dsp_regs(child); dregs[addr - DSP_BASE] = data; break; - } case DSP_CONTROL: if (!cpu_has_dsp) { ret = -EIO; diff --git a/trunk/arch/mips/kernel/reset.c b/trunk/arch/mips/kernel/reset.c index 621037db2290..5e37df3111ad 100644 --- a/trunk/arch/mips/kernel/reset.c +++ b/trunk/arch/mips/kernel/reset.c @@ -3,17 +3,18 @@ * License. See the file "COPYING" in the main directory of this archive * for more details. * - * Copyright (C) 2001, 06 by Ralf Baechle (ralf@linux-mips.org) + * Copyright (C) 2001 by Ralf Baechle * Copyright (C) 2001 MIPS Technologies, Inc. */ #include #include -#include #include #include - #include +void (*pm_power_off)(void); +EXPORT_SYMBOL(pm_power_off); + /* * Urgs ... Too many MIPS machines to handle this in a generic way. * So handle all using function pointers to machine specific @@ -21,22 +22,23 @@ */ void (*_machine_restart)(char *command); void (*_machine_halt)(void); -void (*pm_power_off)(void); +void (*_machine_power_off)(void); void machine_restart(char *command) { - if (_machine_restart) - _machine_restart(command); + _machine_restart(command); } void machine_halt(void) { - if (_machine_halt) - _machine_halt(); + _machine_halt(); } void machine_power_off(void) { if (pm_power_off) pm_power_off(); + + _machine_power_off(); } + diff --git a/trunk/arch/mips/kernel/rtlx.c b/trunk/arch/mips/kernel/rtlx.c index 986a9cf23067..1d855112bac2 100644 --- a/trunk/arch/mips/kernel/rtlx.c +++ b/trunk/arch/mips/kernel/rtlx.c @@ -1,6 +1,5 @@ /* * Copyright (C) 2005 MIPS Technologies, Inc. All rights reserved. - * Copyright (C) 2005, 06 Ralf Baechle (ralf@linux-mips.org) * * This program is free software; you can distribute it and/or modify it * under the terms of the GNU General Public License (Version 2) as @@ -21,12 +20,9 @@ #include #include #include -#include -#include #include #include #include - #include #include #include diff --git a/trunk/arch/mips/kernel/scall32-o32.S b/trunk/arch/mips/kernel/scall32-o32.S index d83e033dbc87..a42e0e8caa7b 100644 --- a/trunk/arch/mips/kernel/scall32-o32.S +++ b/trunk/arch/mips/kernel/scall32-o32.S @@ -617,23 +617,6 @@ einval: li v0, -EINVAL sys sys_inotify_init 0 sys sys_inotify_add_watch 3 /* 4285 */ sys sys_inotify_rm_watch 2 - sys sys_migrate_pages 4 - sys sys_openat 4 - sys sys_mkdirat 3 - sys sys_mknodat 4 /* 4290 */ - sys sys_fchownat 5 - sys sys_futimesat 3 - sys sys_fstatat64 4 - sys sys_unlinkat 3 - sys sys_renameat 4 /* 4295 */ - sys sys_linkat 4 - sys sys_symlinkat 3 - sys sys_readlinkat 4 - sys sys_fchmodat 3 - sys sys_faccessat 3 /* 4300 */ - sys sys_pselect6 6 - sys sys_ppoll 5 - sys sys_unshare 1 .endm /* We pre-compute the number of _instruction_ bytes needed to diff --git a/trunk/arch/mips/kernel/scall64-64.S b/trunk/arch/mips/kernel/scall64-64.S index 98bf25df56f3..47bfbd416709 100644 --- a/trunk/arch/mips/kernel/scall64-64.S +++ b/trunk/arch/mips/kernel/scall64-64.S @@ -443,20 +443,3 @@ sys_call_table: PTR sys_inotify_init PTR sys_inotify_add_watch PTR sys_inotify_rm_watch /* 5245 */ - PTR sys_migrate_pages - PTR sys_openat - PTR sys_mkdirat - PTR sys_mknodat - PTR sys_fchownat /* 5250 */ - PTR sys_futimesat - PTR sys_newfstatat - PTR sys_unlinkat - PTR sys_renameat - PTR sys_linkat /* 5255 */ - PTR sys_symlinkat - PTR sys_readlinkat - PTR sys_fchmodat - PTR sys_faccessat - PTR sys_pselect6 /* 5260 */ - PTR sys_ppoll - PTR sys_unshare diff --git a/trunk/arch/mips/kernel/scall64-n32.S b/trunk/arch/mips/kernel/scall64-n32.S index bc4980cefc8b..b465ced1758f 100644 --- a/trunk/arch/mips/kernel/scall64-n32.S +++ b/trunk/arch/mips/kernel/scall64-n32.S @@ -369,20 +369,3 @@ EXPORT(sysn32_call_table) PTR sys_inotify_init PTR sys_inotify_add_watch PTR sys_inotify_rm_watch - PTR sys_migrate_pages /* 6250 */ - PTR sys_openat - PTR sys_mkdirat - PTR sys_mknodat - PTR sys_fchownat - PTR sys_futimesat /* 6255 */ - PTR sys_newfstatat - PTR sys_unlinkat - PTR sys_renameat - PTR sys_linkat - PTR sys_symlinkat /* 6260 */ - PTR sys_readlinkat - PTR sys_fchmodat - PTR sys_faccessat - PTR sys_pselect6 - PTR sys_ppoll /* 6265 */ - PTR sys_unshare diff --git a/trunk/arch/mips/kernel/scall64-o32.S b/trunk/arch/mips/kernel/scall64-o32.S index 5b0414018c9a..3d338ca7eeeb 100644 --- a/trunk/arch/mips/kernel/scall64-o32.S +++ b/trunk/arch/mips/kernel/scall64-o32.S @@ -491,21 +491,4 @@ sys_call_table: PTR sys_inotify_init PTR sys_inotify_add_watch /* 4285 */ PTR sys_inotify_rm_watch - PTR sys_migrate_pages - PTR compat_sys_openat - PTR sys_mkdirat - PTR sys_mknodat /* 4290 */ - PTR sys_fchownat - PTR compat_sys_futimesat - PTR compat_sys_newfstatat - PTR sys_unlinkat - PTR sys_renameat /* 4295 */ - PTR sys_linkat - PTR sys_symlinkat - PTR sys_readlinkat - PTR sys_fchmodat - PTR sys_faccessat /* 4300 */ - PTR sys_pselect6 - PTR sys_ppoll - PTR sys_unshare .size sys_call_table,.-sys_call_table diff --git a/trunk/arch/mips/kernel/signal-common.h b/trunk/arch/mips/kernel/signal-common.h index 0fbc492d24b4..0f66ae5838b9 100644 --- a/trunk/arch/mips/kernel/signal-common.h +++ b/trunk/arch/mips/kernel/signal-common.h @@ -11,7 +11,7 @@ #include static inline int -setup_sigcontext(struct pt_regs *regs, struct sigcontext __user *sc) +setup_sigcontext(struct pt_regs *regs, struct sigcontext *sc) { int err = 0; @@ -82,7 +82,7 @@ setup_sigcontext(struct pt_regs *regs, struct sigcontext __user *sc) } static inline int -restore_sigcontext(struct pt_regs *regs, struct sigcontext __user *sc) +restore_sigcontext(struct pt_regs *regs, struct sigcontext *sc) { unsigned int used_math; unsigned long treg; @@ -157,7 +157,7 @@ restore_sigcontext(struct pt_regs *regs, struct sigcontext __user *sc) /* * Determine which stack to use.. */ -static inline void __user * +static inline void * get_sigframe(struct k_sigaction *ka, struct pt_regs *regs, size_t frame_size) { unsigned long sp; @@ -176,7 +176,7 @@ get_sigframe(struct k_sigaction *ka, struct pt_regs *regs, size_t frame_size) if ((ka->sa.sa_flags & SA_ONSTACK) && (sas_ss_flags (sp) == 0)) sp = current->sas_ss_sp + current->sas_ss_size; - return (void __user *)((sp - frame_size) & (ICACHE_REFILLS_WORKAROUND_WAR ? 32 : ALMASK)); + return (void *)((sp - frame_size) & (ICACHE_REFILLS_WORKAROUND_WAR ? 32 : ALMASK)); } static inline int install_sigtramp(unsigned int __user *tramp, diff --git a/trunk/arch/mips/kernel/signal.c b/trunk/arch/mips/kernel/signal.c index c974cc9b30eb..7d1800fe7038 100644 --- a/trunk/arch/mips/kernel/signal.c +++ b/trunk/arch/mips/kernel/signal.c @@ -39,6 +39,8 @@ #define _BLOCKABLE (~(sigmask(SIGKILL) | sigmask(SIGSTOP))) +int do_signal(sigset_t *oldset, struct pt_regs *regs); + /* * Atomically swap in the new signal mask, and wait for a signal. */ @@ -48,7 +50,7 @@ save_static_function(sys_sigsuspend); __attribute_used__ noinline static int _sys_sigsuspend(nabi_no_regargs struct pt_regs regs) { - sigset_t newset; + sigset_t saveset, newset; sigset_t __user *uset; uset = (sigset_t __user *) regs.regs[4]; @@ -57,15 +59,19 @@ _sys_sigsuspend(nabi_no_regargs struct pt_regs regs) sigdelsetmask(&newset, ~_BLOCKABLE); spin_lock_irq(¤t->sighand->siglock); - current->saved_sigmask = current->blocked; + saveset = current->blocked; current->blocked = newset; recalc_sigpending(); spin_unlock_irq(¤t->sighand->siglock); - current->state = TASK_INTERRUPTIBLE; - schedule(); - set_thread_flag(TIF_RESTORE_SIGMASK); - return -ERESTARTNOHAND; + regs.regs[2] = EINTR; + regs.regs[7] = 1; + while (1) { + current->state = TASK_INTERRUPTIBLE; + schedule(); + if (do_signal(&saveset, ®s)) + return -EINTR; + } } #endif @@ -73,7 +79,7 @@ save_static_function(sys_rt_sigsuspend); __attribute_used__ noinline static int _sys_rt_sigsuspend(nabi_no_regargs struct pt_regs regs) { - sigset_t newset; + sigset_t saveset, newset; sigset_t __user *unewset; size_t sigsetsize; @@ -88,15 +94,19 @@ _sys_rt_sigsuspend(nabi_no_regargs struct pt_regs regs) sigdelsetmask(&newset, ~_BLOCKABLE); spin_lock_irq(¤t->sighand->siglock); - current->saved_sigmask = current->blocked; + saveset = current->blocked; current->blocked = newset; recalc_sigpending(); spin_unlock_irq(¤t->sighand->siglock); - current->state = TASK_INTERRUPTIBLE; - schedule(); - set_thread_flag(TIF_RESTORE_SIGMASK); - return -ERESTARTNOHAND; + regs.regs[2] = EINTR; + regs.regs[7] = 1; + while (1) { + current->state = TASK_INTERRUPTIBLE; + schedule(); + if (do_signal(&saveset, ®s)) + return -EINTR; + } } #ifdef CONFIG_TRAD_SIGNALS @@ -189,10 +199,10 @@ save_static_function(sys_sigreturn); __attribute_used__ noinline static void _sys_sigreturn(nabi_no_regargs struct pt_regs regs) { - struct sigframe __user *frame; + struct sigframe *frame; sigset_t blocked; - frame = (struct sigframe __user *) regs.regs[29]; + frame = (struct sigframe *) regs.regs[29]; if (!access_ok(VERIFY_READ, frame, sizeof(*frame))) goto badframe; if (__copy_from_user(&blocked, &frame->sf_mask, sizeof(blocked))) @@ -226,11 +236,11 @@ save_static_function(sys_rt_sigreturn); __attribute_used__ noinline static void _sys_rt_sigreturn(nabi_no_regargs struct pt_regs regs) { - struct rt_sigframe __user *frame; + struct rt_sigframe *frame; sigset_t set; stack_t st; - frame = (struct rt_sigframe __user *) regs.regs[29]; + frame = (struct rt_sigframe *) regs.regs[29]; if (!access_ok(VERIFY_READ, frame, sizeof(*frame))) goto badframe; if (__copy_from_user(&set, &frame->rs_uc.uc_sigmask, sizeof(set))) @@ -249,7 +259,7 @@ _sys_rt_sigreturn(nabi_no_regargs struct pt_regs regs) goto badframe; /* It is more difficult to avoid calling this function than to call it and ignore errors. */ - do_sigaltstack((stack_t __user *)&st, NULL, regs.regs[29]); + do_sigaltstack(&st, NULL, regs.regs[29]); /* * Don't let your children do this ... @@ -269,7 +279,7 @@ _sys_rt_sigreturn(nabi_no_regargs struct pt_regs regs) int setup_frame(struct k_sigaction * ka, struct pt_regs *regs, int signr, sigset_t *set) { - struct sigframe __user *frame; + struct sigframe *frame; int err = 0; frame = get_sigframe(ka, regs, sizeof(*frame)); @@ -305,18 +315,18 @@ int setup_frame(struct k_sigaction * ka, struct pt_regs *regs, current->comm, current->pid, frame, regs->cp0_epc, frame->regs[31]); #endif - return 0; + return 1; give_sigsegv: force_sigsegv(signr, current); - return -EFAULT; + return 0; } #endif int setup_rt_frame(struct k_sigaction * ka, struct pt_regs *regs, int signr, sigset_t *set, siginfo_t *info) { - struct rt_sigframe __user *frame; + struct rt_sigframe *frame; int err = 0; frame = get_sigframe(ka, regs, sizeof(*frame)); @@ -330,7 +340,7 @@ int setup_rt_frame(struct k_sigaction * ka, struct pt_regs *regs, /* Create the ucontext. */ err |= __put_user(0, &frame->rs_uc.uc_flags); - err |= __put_user(NULL, &frame->rs_uc.uc_link); + err |= __put_user(0, &frame->rs_uc.uc_link); err |= __put_user((void *)current->sas_ss_sp, &frame->rs_uc.uc_stack.ss_sp); err |= __put_user(sas_ss_flags(regs->regs[29]), @@ -365,11 +375,11 @@ int setup_rt_frame(struct k_sigaction * ka, struct pt_regs *regs, current->comm, current->pid, frame, regs->cp0_epc, regs->regs[31]); #endif - return 0; + return 1; give_sigsegv: force_sigsegv(signr, current); - return -EFAULT; + return 0; } static inline int handle_signal(unsigned long sig, siginfo_t *info, @@ -383,7 +393,7 @@ static inline int handle_signal(unsigned long sig, siginfo_t *info, regs->regs[2] = EINTR; break; case ERESTARTSYS: - if (!(ka->sa.sa_flags & SA_RESTART)) { + if(!(ka->sa.sa_flags & SA_RESTART)) { regs->regs[2] = EINTR; break; } @@ -410,10 +420,9 @@ static inline int handle_signal(unsigned long sig, siginfo_t *info, return ret; } -void do_signal(struct pt_regs *regs) +int do_signal(sigset_t *oldset, struct pt_regs *regs) { struct k_sigaction ka; - sigset_t *oldset; siginfo_t info; int signr; @@ -423,31 +432,17 @@ void do_signal(struct pt_regs *regs) * if so. */ if (!user_mode(regs)) - return; + return 1; if (try_to_freeze()) goto no_signal; - if (test_thread_flag(TIF_RESTORE_SIGMASK)) - oldset = ¤t->saved_sigmask; - else + if (!oldset) oldset = ¤t->blocked; - signr = get_signal_to_deliver(&info, &ka, regs, NULL); - if (signr > 0) { - /* Whee! Actually deliver the signal. */ - if (handle_signal(signr, &info, &ka, oldset, regs) == 0) { - /* - * A signal was successfully delivered; the saved - * sigmask will have been stored in the signal frame, - * and will be restored by sigreturn, so we can simply - * clear the TIF_RESTORE_SIGMASK flag. - */ - if (test_thread_flag(TIF_RESTORE_SIGMASK)) - clear_thread_flag(TIF_RESTORE_SIGMASK); - } - } + if (signr > 0) + return handle_signal(signr, &info, &ka, oldset, regs); no_signal: /* @@ -468,25 +463,18 @@ void do_signal(struct pt_regs *regs) regs->cp0_epc -= 4; } } - - /* - * If there's no signal to deliver, we just put the saved sigmask - * back - */ - if (test_thread_flag(TIF_RESTORE_SIGMASK)) { - clear_thread_flag(TIF_RESTORE_SIGMASK); - sigprocmask(SIG_SETMASK, ¤t->saved_sigmask, NULL); - } + return 0; } /* * notification of userspace execution resumption - * - triggered by the TIF_WORK_MASK flags + * - triggered by current->work.notify_resume */ -asmlinkage void do_notify_resume(struct pt_regs *regs, void *unused, +asmlinkage void do_notify_resume(struct pt_regs *regs, sigset_t *oldset, __u32 thread_info_flags) { /* deal with pending signal delivery */ - if (thread_info_flags & (_TIF_SIGPENDING | _TIF_RESTORE_SIGMASK)) - current->thread.abi->do_signal(regs); + if (thread_info_flags & _TIF_SIGPENDING) { + current->thread.abi->do_signal(oldset, regs); + } } diff --git a/trunk/arch/mips/kernel/signal32.c b/trunk/arch/mips/kernel/signal32.c index da3271e1fdac..98b185bbc947 100644 --- a/trunk/arch/mips/kernel/signal32.c +++ b/trunk/arch/mips/kernel/signal32.c @@ -144,7 +144,7 @@ struct ucontext32 { extern void __put_sigset_unknown_nsig(void); extern void __get_sigset_unknown_nsig(void); -static inline int put_sigset(const sigset_t *kbuf, compat_sigset_t __user *ubuf) +static inline int put_sigset(const sigset_t *kbuf, compat_sigset_t *ubuf) { int err = 0; @@ -269,7 +269,7 @@ asmlinkage int sys32_sigaction(int sig, const struct sigaction32 *act, if (!access_ok(VERIFY_READ, act, sizeof(*act))) return -EFAULT; err |= __get_user(handler, &act->sa_handler); - new_ka.sa.sa_handler = (void __user *)(s64)handler; + new_ka.sa.sa_handler = (void*)(s64)handler; err |= __get_user(new_ka.sa.sa_flags, &act->sa_flags); err |= __get_user(mask, &act->sa_mask.sig[0]); if (err) @@ -299,8 +299,8 @@ asmlinkage int sys32_sigaction(int sig, const struct sigaction32 *act, asmlinkage int sys32_sigaltstack(nabi_no_regargs struct pt_regs regs) { - const stack32_t __user *uss = (const stack32_t __user *) regs.regs[4]; - stack32_t __user *uoss = (stack32_t __user *) regs.regs[5]; + const stack32_t *uss = (const stack32_t *) regs.regs[4]; + stack32_t *uoss = (stack32_t *) regs.regs[5]; unsigned long usp = regs.regs[29]; stack_t kss, koss; int ret, err = 0; @@ -319,8 +319,7 @@ asmlinkage int sys32_sigaltstack(nabi_no_regargs struct pt_regs regs) } set_fs (KERNEL_DS); - ret = do_sigaltstack(uss ? (stack_t __user *)&kss : NULL, - uoss ? (stack_t __user *)&koss : NULL, usp); + ret = do_sigaltstack(uss ? &kss : NULL , uoss ? &koss : NULL, usp); set_fs (old_fs); if (!ret && uoss) { @@ -336,7 +335,7 @@ asmlinkage int sys32_sigaltstack(nabi_no_regargs struct pt_regs regs) return ret; } -static int restore_sigcontext32(struct pt_regs *regs, struct sigcontext32 __user *sc) +static int restore_sigcontext32(struct pt_regs *regs, struct sigcontext32 *sc) { u32 used_math; int err = 0; @@ -421,7 +420,7 @@ struct rt_sigframe32 { #endif }; -int copy_siginfo_to_user32(compat_siginfo_t __user *to, siginfo_t *from) +int copy_siginfo_to_user32(compat_siginfo_t *to, siginfo_t *from) { int err; @@ -456,7 +455,7 @@ int copy_siginfo_to_user32(compat_siginfo_t __user *to, siginfo_t *from) err |= __put_user(from->si_uid, &to->si_uid); break; case __SI_FAULT >> 16: - err |= __put_user((unsigned long)from->si_addr, &to->si_addr); + err |= __put_user((long)from->si_addr, &to->si_addr); break; case __SI_POLL >> 16: err |= __put_user(from->si_band, &to->si_band); @@ -477,10 +476,10 @@ save_static_function(sys32_sigreturn); __attribute_used__ noinline static void _sys32_sigreturn(nabi_no_regargs struct pt_regs regs) { - struct sigframe __user *frame; + struct sigframe *frame; sigset_t blocked; - frame = (struct sigframe __user *) regs.regs[29]; + frame = (struct sigframe *) regs.regs[29]; if (!access_ok(VERIFY_READ, frame, sizeof(*frame))) goto badframe; if (__copy_from_user(&blocked, &frame->sf_mask, sizeof(blocked))) @@ -513,13 +512,13 @@ save_static_function(sys32_rt_sigreturn); __attribute_used__ noinline static void _sys32_rt_sigreturn(nabi_no_regargs struct pt_regs regs) { - struct rt_sigframe32 __user *frame; + struct rt_sigframe32 *frame; mm_segment_t old_fs; sigset_t set; stack_t st; s32 sp; - frame = (struct rt_sigframe32 __user *) regs.regs[29]; + frame = (struct rt_sigframe32 *) regs.regs[29]; if (!access_ok(VERIFY_READ, frame, sizeof(*frame))) goto badframe; if (__copy_from_user(&set, &frame->rs_uc.uc_sigmask, sizeof(set))) @@ -547,7 +546,7 @@ _sys32_rt_sigreturn(nabi_no_regargs struct pt_regs regs) call it and ignore errors. */ old_fs = get_fs(); set_fs (KERNEL_DS); - do_sigaltstack((stack_t __user *)&st, NULL, regs.regs[29]); + do_sigaltstack(&st, NULL, regs.regs[29]); set_fs (old_fs); /* @@ -565,7 +564,7 @@ _sys32_rt_sigreturn(nabi_no_regargs struct pt_regs regs) } static inline int setup_sigcontext32(struct pt_regs *regs, - struct sigcontext32 __user *sc) + struct sigcontext32 *sc) { int err = 0; @@ -624,9 +623,8 @@ static inline int setup_sigcontext32(struct pt_regs *regs, /* * Determine which stack to use.. */ -static inline void __user *get_sigframe(struct k_sigaction *ka, - struct pt_regs *regs, - size_t frame_size) +static inline void *get_sigframe(struct k_sigaction *ka, struct pt_regs *regs, + size_t frame_size) { unsigned long sp; @@ -644,13 +642,13 @@ static inline void __user *get_sigframe(struct k_sigaction *ka, if ((ka->sa.sa_flags & SA_ONSTACK) && (sas_ss_flags (sp) == 0)) sp = current->sas_ss_sp + current->sas_ss_size; - return (void __user *)((sp - frame_size) & ALMASK); + return (void *)((sp - frame_size) & ALMASK); } int setup_frame_32(struct k_sigaction * ka, struct pt_regs *regs, int signr, sigset_t *set) { - struct sigframe __user *frame; + struct sigframe *frame; int err = 0; frame = get_sigframe(ka, regs, sizeof(*frame)); @@ -694,17 +692,17 @@ int setup_frame_32(struct k_sigaction * ka, struct pt_regs *regs, current->comm, current->pid, frame, regs->cp0_epc, frame->sf_code); #endif - return 0; + return 1; give_sigsegv: force_sigsegv(signr, current); - return -EFAULT; + return 0; } int setup_rt_frame_32(struct k_sigaction * ka, struct pt_regs *regs, int signr, sigset_t *set, siginfo_t *info) { - struct rt_sigframe32 __user *frame; + struct rt_sigframe32 *frame; int err = 0; s32 sp; @@ -765,11 +763,11 @@ int setup_rt_frame_32(struct k_sigaction * ka, struct pt_regs *regs, current->comm, current->pid, frame, regs->cp0_epc, frame->rs_code); #endif - return 0; + return 1; give_sigsegv: force_sigsegv(signr, current); - return -EFAULT; + return 0; } static inline int handle_signal(unsigned long sig, siginfo_t *info, @@ -857,7 +855,7 @@ int do_signal32(sigset_t *oldset, struct pt_regs *regs) } asmlinkage int sys32_rt_sigaction(int sig, const struct sigaction32 *act, - struct sigaction32 __user *oact, + struct sigaction32 *oact, unsigned int sigsetsize) { struct k_sigaction new_sa, old_sa; @@ -874,7 +872,7 @@ asmlinkage int sys32_rt_sigaction(int sig, const struct sigaction32 *act, if (!access_ok(VERIFY_READ, act, sizeof(*act))) return -EFAULT; err |= __get_user(handler, &act->sa_handler); - new_sa.sa.sa_handler = (void __user *)(s64)handler; + new_sa.sa.sa_handler = (void*)(s64)handler; err |= __get_user(new_sa.sa.sa_flags, &act->sa_flags); err |= get_sigset(&new_sa.sa.sa_mask, &act->sa_mask); if (err) @@ -901,7 +899,7 @@ asmlinkage int sys32_rt_sigaction(int sig, const struct sigaction32 *act, } asmlinkage int sys32_rt_sigprocmask(int how, compat_sigset_t *set, - compat_sigset_t __user *oset, unsigned int sigsetsize) + compat_sigset_t *oset, unsigned int sigsetsize) { sigset_t old_set, new_set; int ret; @@ -911,9 +909,8 @@ asmlinkage int sys32_rt_sigprocmask(int how, compat_sigset_t *set, return -EFAULT; set_fs (KERNEL_DS); - ret = sys_rt_sigprocmask(how, set ? (sigset_t __user *)&new_set : NULL, - oset ? (sigset_t __user *)&old_set : NULL, - sigsetsize); + ret = sys_rt_sigprocmask(how, set ? &new_set : NULL, + oset ? &old_set : NULL, sigsetsize); set_fs (old_fs); if (!ret && oset && put_sigset(&old_set, oset)) @@ -922,7 +919,7 @@ asmlinkage int sys32_rt_sigprocmask(int how, compat_sigset_t *set, return ret; } -asmlinkage int sys32_rt_sigpending(compat_sigset_t __user *uset, +asmlinkage int sys32_rt_sigpending(compat_sigset_t *uset, unsigned int sigsetsize) { int ret; @@ -930,7 +927,7 @@ asmlinkage int sys32_rt_sigpending(compat_sigset_t __user *uset, mm_segment_t old_fs = get_fs(); set_fs (KERNEL_DS); - ret = sys_rt_sigpending((sigset_t __user *)&set, sigsetsize); + ret = sys_rt_sigpending(&set, sigsetsize); set_fs (old_fs); if (!ret && put_sigset(&set, uset)) @@ -939,7 +936,7 @@ asmlinkage int sys32_rt_sigpending(compat_sigset_t __user *uset, return ret; } -asmlinkage int sys32_rt_sigqueueinfo(int pid, int sig, compat_siginfo_t __user *uinfo) +asmlinkage int sys32_rt_sigqueueinfo(int pid, int sig, compat_siginfo_t *uinfo) { siginfo_t info; int ret; @@ -949,7 +946,7 @@ asmlinkage int sys32_rt_sigqueueinfo(int pid, int sig, compat_siginfo_t __user * copy_from_user (info._sifields._pad, uinfo->_sifields._pad, SI_PAD_SIZE)) return -EFAULT; set_fs (KERNEL_DS); - ret = sys_rt_sigqueueinfo(pid, sig, (siginfo_t __user *)&info); + ret = sys_rt_sigqueueinfo(pid, sig, &info); set_fs (old_fs); return ret; } diff --git a/trunk/arch/mips/kernel/signal_n32.c b/trunk/arch/mips/kernel/signal_n32.c index 384fc4a639a4..ec61b2670ba6 100644 --- a/trunk/arch/mips/kernel/signal_n32.c +++ b/trunk/arch/mips/kernel/signal_n32.c @@ -48,8 +48,6 @@ #define __NR_N32_rt_sigreturn 6211 #define __NR_N32_restart_syscall 6214 -#define DEBUG_SIG 0 - #define _BLOCKABLE (~(sigmask(SIGKILL) | sigmask(SIGSTOP))) /* IRIX compatible stack_t */ @@ -85,12 +83,12 @@ save_static_function(sysn32_rt_sigreturn); __attribute_used__ noinline static void _sysn32_rt_sigreturn(nabi_no_regargs struct pt_regs regs) { - struct rt_sigframe_n32 __user *frame; + struct rt_sigframe_n32 *frame; sigset_t set; stack_t st; s32 sp; - frame = (struct rt_sigframe_n32 __user *) regs.regs[29]; + frame = (struct rt_sigframe_n32 *) regs.regs[29]; if (!access_ok(VERIFY_READ, frame, sizeof(*frame))) goto badframe; if (__copy_from_user(&set, &frame->rs_uc.uc_sigmask, sizeof(set))) @@ -116,7 +114,7 @@ _sysn32_rt_sigreturn(nabi_no_regargs struct pt_regs regs) /* It is more difficult to avoid calling this function than to call it and ignore errors. */ - do_sigaltstack((stack_t __user *)&st, NULL, regs.regs[29]); + do_sigaltstack(&st, NULL, regs.regs[29]); /* * Don't let your children do this ... @@ -135,7 +133,7 @@ _sysn32_rt_sigreturn(nabi_no_regargs struct pt_regs regs) int setup_rt_frame_n32(struct k_sigaction * ka, struct pt_regs *regs, int signr, sigset_t *set, siginfo_t *info) { - struct rt_sigframe_n32 __user *frame; + struct rt_sigframe_n32 *frame; int err = 0; s32 sp; @@ -186,9 +184,9 @@ int setup_rt_frame_n32(struct k_sigaction * ka, current->comm, current->pid, frame, regs->cp0_epc, regs->regs[31]); #endif - return 0; + return 1; give_sigsegv: force_sigsegv(signr, current); - return -EFAULT; + return 0; } diff --git a/trunk/arch/mips/kernel/syscall.c b/trunk/arch/mips/kernel/syscall.c index 1da2eeb3ef9e..332358430ff5 100644 --- a/trunk/arch/mips/kernel/syscall.c +++ b/trunk/arch/mips/kernel/syscall.c @@ -212,12 +212,12 @@ asmlinkage int sys_execve(nabi_no_regargs struct pt_regs regs) int error; char * filename; - filename = getname((char __user *) (long)regs.regs[4]); + filename = getname((char *) (long)regs.regs[4]); error = PTR_ERR(filename); if (IS_ERR(filename)) goto out; - error = do_execve(filename, (char __user *__user *) (long)regs.regs[5], - (char __user *__user *) (long)regs.regs[6], ®s); + error = do_execve(filename, (char **) (long)regs.regs[5], + (char **) (long)regs.regs[6], ®s); putname(filename); out: @@ -227,7 +227,7 @@ asmlinkage int sys_execve(nabi_no_regargs struct pt_regs regs) /* * Compacrapability ... */ -asmlinkage int sys_uname(struct old_utsname __user * name) +asmlinkage int sys_uname(struct old_utsname * name) { if (name && !copy_to_user(name, &system_utsname, sizeof (*name))) return 0; @@ -237,7 +237,7 @@ asmlinkage int sys_uname(struct old_utsname __user * name) /* * Compacrapability ... */ -asmlinkage int sys_olduname(struct oldold_utsname __user * name) +asmlinkage int sys_olduname(struct oldold_utsname * name) { int error; @@ -274,7 +274,7 @@ void sys_set_thread_area(unsigned long addr) asmlinkage int _sys_sysmips(int cmd, long arg1, int arg2, int arg3) { int tmp, len; - char __user *name; + char *name; switch(cmd) { case SETNAME: { @@ -283,7 +283,7 @@ asmlinkage int _sys_sysmips(int cmd, long arg1, int arg2, int arg3) if (!capable(CAP_SYS_ADMIN)) return -EPERM; - name = (char __user *) arg1; + name = (char *) arg1; len = strncpy_from_user(nodename, name, __NEW_UTS_LEN); if (len < 0) @@ -324,7 +324,7 @@ asmlinkage int _sys_sysmips(int cmd, long arg1, int arg2, int arg3) * This is really horribly ugly. */ asmlinkage int sys_ipc (uint call, int first, int second, - unsigned long third, void __user *ptr, long fifth) + unsigned long third, void *ptr, long fifth) { int version, ret; @@ -333,25 +333,24 @@ asmlinkage int sys_ipc (uint call, int first, int second, switch (call) { case SEMOP: - return sys_semtimedop (first, (struct sembuf __user *)ptr, - second, NULL); + return sys_semtimedop (first, (struct sembuf *)ptr, second, + NULL); case SEMTIMEDOP: - return sys_semtimedop (first, (struct sembuf __user *)ptr, - second, - (const struct timespec __user *)fifth); + return sys_semtimedop (first, (struct sembuf *)ptr, second, + (const struct timespec __user *)fifth); case SEMGET: return sys_semget (first, second, third); case SEMCTL: { union semun fourth; if (!ptr) return -EINVAL; - if (get_user(fourth.__pad, (void *__user *) ptr)) + if (get_user(fourth.__pad, (void **) ptr)) return -EFAULT; return sys_semctl (first, second, third, fourth); } case MSGSND: - return sys_msgsnd (first, (struct msgbuf __user *) ptr, + return sys_msgsnd (first, (struct msgbuf *) ptr, second, third); case MSGRCV: switch (version) { @@ -361,7 +360,7 @@ asmlinkage int sys_ipc (uint call, int first, int second, return -EINVAL; if (copy_from_user(&tmp, - (struct ipc_kludge __user *) ptr, + (struct ipc_kludge *) ptr, sizeof (tmp))) return -EFAULT; return sys_msgrcv (first, tmp.msgp, second, @@ -369,38 +368,35 @@ asmlinkage int sys_ipc (uint call, int first, int second, } default: return sys_msgrcv (first, - (struct msgbuf __user *) ptr, + (struct msgbuf *) ptr, second, fifth, third); } case MSGGET: return sys_msgget ((key_t) first, second); case MSGCTL: - return sys_msgctl (first, second, - (struct msqid_ds __user *) ptr); + return sys_msgctl (first, second, (struct msqid_ds *) ptr); case SHMAT: switch (version) { default: { ulong raddr; - ret = do_shmat (first, (char __user *) ptr, second, - &raddr); + ret = do_shmat (first, (char *) ptr, second, &raddr); if (ret) return ret; - return put_user (raddr, (ulong __user *) third); + return put_user (raddr, (ulong *) third); } case 1: /* iBCS2 emulator entry point */ if (!segment_eq(get_fs(), get_ds())) return -EINVAL; - return do_shmat (first, (char __user *) ptr, second, - (ulong *) third); + return do_shmat (first, (char *) ptr, second, (ulong *) third); } case SHMDT: - return sys_shmdt ((char __user *)ptr); + return sys_shmdt ((char *)ptr); case SHMGET: return sys_shmget (first, second, third); case SHMCTL: return sys_shmctl (first, second, - (struct shmid_ds __user *) ptr); + (struct shmid_ds *) ptr); default: return -ENOSYS; } diff --git a/trunk/arch/mips/kernel/traps.c b/trunk/arch/mips/kernel/traps.c index c9d2b5147ca3..59a187956de0 100644 --- a/trunk/arch/mips/kernel/traps.c +++ b/trunk/arch/mips/kernel/traps.c @@ -1168,7 +1168,7 @@ void __init per_cpu_trap_init(void) #endif if (current_cpu_data.isa_level == MIPS_CPU_ISA_IV) status_set |= ST0_XX; - change_c0_status(ST0_CU|ST0_MX|ST0_RE|ST0_FR|ST0_BEV|ST0_TS|ST0_KX|ST0_SX|ST0_UX, + change_c0_status(ST0_CU|ST0_MX|ST0_FR|ST0_BEV|ST0_TS|ST0_KX|ST0_SX|ST0_UX, status_set); if (cpu_has_dsp) diff --git a/trunk/arch/mips/kernel/vmlinux.lds.S b/trunk/arch/mips/kernel/vmlinux.lds.S index ff699dbb99f7..25cc856d8e7e 100644 --- a/trunk/arch/mips/kernel/vmlinux.lds.S +++ b/trunk/arch/mips/kernel/vmlinux.lds.S @@ -1,5 +1,4 @@ #include -#include #include #undef mips /* CPP really sucks for this job */ @@ -65,10 +64,10 @@ SECTIONS we can shorten the on-disk segment size. */ .sdata : { *(.sdata) } - . = ALIGN(_PAGE_SIZE); + . = ALIGN(4096); __nosave_begin = .; .data_nosave : { *(.data.nosave) } - . = ALIGN(_PAGE_SIZE); + . = ALIGN(4096); __nosave_end = .; . = ALIGN(32); @@ -77,7 +76,7 @@ SECTIONS _edata = .; /* End of data section */ /* will be freed after init */ - . = ALIGN(_PAGE_SIZE); /* Init code and data */ + . = ALIGN(4096); /* Init code and data */ __init_begin = .; .init.text : { _sinittext = .; @@ -106,7 +105,7 @@ SECTIONS .con_initcall.init : { *(.con_initcall.init) } __con_initcall_end = .; SECURITY_INIT - . = ALIGN(_PAGE_SIZE); + . = ALIGN(4096); __initramfs_start = .; .init.ramfs : { *(.init.ramfs) } __initramfs_end = .; @@ -114,7 +113,7 @@ SECTIONS __per_cpu_start = .; .data.percpu : { *(.data.percpu) } __per_cpu_end = .; - . = ALIGN(_PAGE_SIZE); + . = ALIGN(4096); __init_end = .; /* freed after init ends here */ diff --git a/trunk/arch/mips/lasat/reset.c b/trunk/arch/mips/lasat/reset.c index 181bf68175fc..8d7d7a454f9a 100644 --- a/trunk/arch/mips/lasat/reset.c +++ b/trunk/arch/mips/lasat/reset.c @@ -19,12 +19,9 @@ */ #include #include -#include - #include #include #include - #include "picvue.h" #include "prom.h" @@ -66,5 +63,5 @@ void lasat_reboot_setup(void) { _machine_restart = lasat_machine_restart; _machine_halt = lasat_machine_halt; - pm_power_off = lasat_machine_halt; + _machine_power_off = lasat_machine_halt; } diff --git a/trunk/arch/mips/lasat/setup.c b/trunk/arch/mips/lasat/setup.c index 83eb08b7a072..dcd819d57dae 100644 --- a/trunk/arch/mips/lasat/setup.c +++ b/trunk/arch/mips/lasat/setup.c @@ -134,8 +134,8 @@ void __init serial_init(void) memset(&s, 0, sizeof(s)); - s.flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST; - s.iotype = UPIO_MEM; + s.flags = STD_COM_FLAGS; + s.iotype = SERIAL_IO_MEM; if (mips_machtype == MACH_LASAT_100) { s.uartclk = LASAT_BASE_BAUD_100 * 16; diff --git a/trunk/arch/mips/lib-32/dump_tlb.c b/trunk/arch/mips/lib-32/dump_tlb.c index c49a925d0169..46519f4331eb 100644 --- a/trunk/arch/mips/lib-32/dump_tlb.c +++ b/trunk/arch/mips/lib-32/dump_tlb.c @@ -158,26 +158,29 @@ void dump_list_process(struct task_struct *t, void *address) printk("task->mm == %8p\n", t->mm); //printk("tasks->mm.pgd == %08x\n", (unsigned int) t->mm->pgd); - if (addr > KSEG0) { + if (addr > KSEG0) page_dir = pgd_offset_k(0); - pgd = pgd_offset_k(addr); - } else if (t->mm) { + else if (t->mm) { page_dir = pgd_offset(t->mm, 0); - pgd = pgd_offset(t->mm, addr); - } else { + printk("page_dir == %08x\n", (unsigned int) page_dir); + } else printk("Current thread has no mm\n"); - return; - } - printk("page_dir == %08x\n", (unsigned int) page_dir); - printk("pgd == %08x, ", (unsigned int) pgd); - pud = pud_offset(pgd, addr); - printk("pud == %08x, ", (unsigned int) pud); - pmd = pmd_offset(pud, addr); - printk("pmd == %08x, ", (unsigned int) pmd); + if (addr > KSEG0) + pgd = pgd_offset_k(addr); + else if (t->mm) { + pgd = pgd_offset(t->mm, addr); + printk("pgd == %08x, ", (unsigned int) pgd); + pud = pud_offset(pgd, addr); + printk("pud == %08x, ", (unsigned int) pud); - pte = pte_offset(pmd, addr); - printk("pte == %08x, ", (unsigned int) pte); + pmd = pmd_offset(pud, addr); + printk("pmd == %08x, ", (unsigned int) pmd); + + pte = pte_offset(pmd, addr); + printk("pte == %08x, ", (unsigned int) pte); + } else + printk("Current thread has no mm\n"); page = *pte; #ifdef CONFIG_64BIT_PHYS_ADDR diff --git a/trunk/arch/mips/math-emu/dp_simple.c b/trunk/arch/mips/math-emu/dp_simple.c index 1c555e6c6a9f..495c1ac94298 100644 --- a/trunk/arch/mips/math-emu/dp_simple.c +++ b/trunk/arch/mips/math-emu/dp_simple.c @@ -48,22 +48,16 @@ ieee754dp ieee754dp_neg(ieee754dp x) CLEARCX; FLUSHXDP; - /* - * Invert the sign ALWAYS to prevent an endless recursion on - * pow() in libc. - */ - /* quick fix up */ - DPSIGN(x) ^= 1; - if (xc == IEEE754_CLASS_SNAN) { - ieee754dp y = ieee754dp_indef(); SETCX(IEEE754_INVALID_OPERATION); - DPSIGN(y) = DPSIGN(x); - return ieee754dp_nanxcpt(y, "neg"); + return ieee754dp_nanxcpt(ieee754dp_indef(), "neg"); } if (ieee754dp_isnan(x)) /* but not infinity */ return ieee754dp_nanxcpt(x, "neg", x); + + /* quick fix up */ + DPSIGN(x) ^= 1; return x; } diff --git a/trunk/arch/mips/math-emu/sp_simple.c b/trunk/arch/mips/math-emu/sp_simple.c index 770f0f4677cd..c809830dffb4 100644 --- a/trunk/arch/mips/math-emu/sp_simple.c +++ b/trunk/arch/mips/math-emu/sp_simple.c @@ -48,22 +48,16 @@ ieee754sp ieee754sp_neg(ieee754sp x) CLEARCX; FLUSHXSP; - /* - * Invert the sign ALWAYS to prevent an endless recursion on - * pow() in libc. - */ - /* quick fix up */ - SPSIGN(x) ^= 1; - if (xc == IEEE754_CLASS_SNAN) { - ieee754sp y = ieee754sp_indef(); SETCX(IEEE754_INVALID_OPERATION); - SPSIGN(y) = SPSIGN(x); - return ieee754sp_nanxcpt(y, "neg"); + return ieee754sp_nanxcpt(ieee754sp_indef(), "neg"); } if (ieee754sp_isnan(x)) /* but not infinity */ return ieee754sp_nanxcpt(x, "neg", x); + + /* quick fix up */ + SPSIGN(x) ^= 1; return x; } diff --git a/trunk/arch/mips/mips-boards/atlas/atlas_setup.c b/trunk/arch/mips/mips-boards/atlas/atlas_setup.c index 873cf3141a31..625843b30bed 100644 --- a/trunk/arch/mips/mips-boards/atlas/atlas_setup.c +++ b/trunk/arch/mips/mips-boards/atlas/atlas_setup.c @@ -82,8 +82,8 @@ static void __init serial_init(void) #endif s.irq = ATLASINT_UART; s.uartclk = ATLAS_BASE_BAUD * 16; - s.flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST | UPF_AUTO_IRQ; - s.iotype = UPIO_PORT; + s.flags = ASYNC_BOOT_AUTOCONF | ASYNC_SKIP_TEST | ASYNC_AUTO_IRQ; + s.iotype = SERIAL_IO_PORT; s.regshift = 3; if (early_serial_setup(&s) != 0) { diff --git a/trunk/arch/mips/mips-boards/generic/reset.c b/trunk/arch/mips/mips-boards/generic/reset.c index 7213c395fb6b..9fdec743bd95 100644 --- a/trunk/arch/mips/mips-boards/generic/reset.c +++ b/trunk/arch/mips/mips-boards/generic/reset.c @@ -23,7 +23,6 @@ * */ #include -#include #include #include @@ -66,9 +65,9 @@ void mips_reboot_setup(void) _machine_restart = mips_machine_restart; _machine_halt = mips_machine_halt; #if defined(CONFIG_MIPS_ATLAS) - pm_power_off = atlas_machine_power_off; + _machine_power_off = atlas_machine_power_off; #endif #if defined(CONFIG_MIPS_MALTA) || defined(CONFIG_MIPS_SEAD) - pm_power_off = mips_machine_halt; + _machine_power_off = mips_machine_halt; #endif } diff --git a/trunk/arch/mips/mips-boards/sead/sead_setup.c b/trunk/arch/mips/mips-boards/sead/sead_setup.c index 4266ce445174..f966bc161dfa 100644 --- a/trunk/arch/mips/mips-boards/sead/sead_setup.c +++ b/trunk/arch/mips/mips-boards/sead/sead_setup.c @@ -71,8 +71,8 @@ static void __init serial_init(void) #endif s.irq = MIPSCPU_INT_BASE + MIPSCPU_INT_UART0; s.uartclk = SEAD_BASE_BAUD * 16; - s.flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST | UPF_AUTO_IRQ; - s.iotype = UPIO_PORT; + s.flags = ASYNC_BOOT_AUTOCONF | ASYNC_SKIP_TEST | ASYNC_AUTO_IRQ; + s.iotype = 0; s.regshift = 3; if (early_serial_setup(&s) != 0) { diff --git a/trunk/arch/mips/mips-boards/sim/sim_setup.c b/trunk/arch/mips/mips-boards/sim/sim_setup.c index a2fd62997ca3..485d5a58d9cf 100644 --- a/trunk/arch/mips/mips-boards/sim/sim_setup.c +++ b/trunk/arch/mips/mips-boards/sim/sim_setup.c @@ -88,8 +88,8 @@ static void __init serial_init(void) but poll for now */ s.irq = 0; s.uartclk = BASE_BAUD * 16; - s.flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST; - s.iotype = UPIO_PORT; + s.flags = ASYNC_BOOT_AUTOCONF | UPF_SKIP_TEST; + s.iotype = SERIAL_IO_PORT | ASYNC_SKIP_TEST; s.regshift = 0; s.timeout = 4; diff --git a/trunk/arch/mips/mm/c-r4k.c b/trunk/arch/mips/mm/c-r4k.c index e51c38cef88e..422b55fab07a 100644 --- a/trunk/arch/mips/mm/c-r4k.c +++ b/trunk/arch/mips/mm/c-r4k.c @@ -464,8 +464,8 @@ static void r4k_flush_data_cache_page(unsigned long addr) } struct flush_icache_range_args { - unsigned long start; - unsigned long end; + unsigned long __user start; + unsigned long __user end; }; static inline void local_r4k_flush_icache_range(void *args) @@ -528,7 +528,8 @@ static inline void local_r4k_flush_icache_range(void *args) } } -static void r4k_flush_icache_range(unsigned long start, unsigned long end) +static void r4k_flush_icache_range(unsigned long __user start, + unsigned long __user end) { struct flush_icache_range_args args; diff --git a/trunk/arch/mips/mm/cache.c b/trunk/arch/mips/mm/cache.c index 591c22b080e4..314701a66b13 100644 --- a/trunk/arch/mips/mm/cache.c +++ b/trunk/arch/mips/mm/cache.c @@ -25,7 +25,8 @@ void (*flush_cache_range)(struct vm_area_struct *vma, unsigned long start, unsigned long end); void (*flush_cache_page)(struct vm_area_struct *vma, unsigned long page, unsigned long pfn); -void (*flush_icache_range)(unsigned long start, unsigned long end); +void (*flush_icache_range)(unsigned long __user start, + unsigned long __user end); void (*flush_icache_page)(struct vm_area_struct *vma, struct page *page); /* MIPS specific cache operations */ @@ -52,7 +53,7 @@ EXPORT_SYMBOL(_dma_cache_inv); * We could optimize the case where the cache argument is not BCACHE but * that seems very atypical use ... */ -asmlinkage int sys_cacheflush(unsigned long addr, +asmlinkage int sys_cacheflush(unsigned long __user addr, unsigned long bytes, unsigned int cache) { if (bytes == 0) diff --git a/trunk/arch/mips/mm/init.c b/trunk/arch/mips/mm/init.c index 0ff9a348b843..4ee91c9a556f 100644 --- a/trunk/arch/mips/mm/init.c +++ b/trunk/arch/mips/mm/init.c @@ -24,7 +24,6 @@ #include #include #include -#include #include #include @@ -201,11 +200,6 @@ static inline int page_is_ram(unsigned long pagenr) return 0; } -static struct kcore_list kcore_mem, kcore_vmalloc; -#ifdef CONFIG_64BIT -static struct kcore_list kcore_kseg0; -#endif - void __init mem_init(void) { unsigned long codesize, reservedpages, datasize, initsize; @@ -255,16 +249,6 @@ void __init mem_init(void) datasize = (unsigned long) &_edata - (unsigned long) &_etext; initsize = (unsigned long) &__init_end - (unsigned long) &__init_begin; -#ifdef CONFIG_64BIT - if ((unsigned long) &_text > (unsigned long) CKSEG0) - /* The -4 is a hack so that user tools don't have to handle - the overflow. */ - kclist_add(&kcore_kseg0, (void *) CKSEG0, 0x80000000 - 4); -#endif - kclist_add(&kcore_mem, __va(0), max_low_pfn << PAGE_SHIFT); - kclist_add(&kcore_vmalloc, (void *)VMALLOC_START, - VMALLOC_END-VMALLOC_START); - printk(KERN_INFO "Memory: %luk/%luk available (%ldk kernel code, " "%ldk reserved, %ldk data, %ldk init, %ldk highmem)\n", (unsigned long) nr_free_pages() << (PAGE_SHIFT-10), diff --git a/trunk/arch/mips/momentum/jaguar_atx/ja-console.c b/trunk/arch/mips/momentum/jaguar_atx/ja-console.c index 2292d0ec47fc..da6e1ed34db1 100644 --- a/trunk/arch/mips/momentum/jaguar_atx/ja-console.c +++ b/trunk/arch/mips/momentum/jaguar_atx/ja-console.c @@ -93,7 +93,7 @@ static void inline ja_console_probe(void) up.uartclk = JAGUAR_ATX_UART_CLK; up.regshift = 2; up.iotype = UPIO_MEM; - up.flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST; + up.flags = ASYNC_BOOT_AUTOCONF | ASYNC_SKIP_TEST; up.line = 0; if (early_serial_setup(&up)) diff --git a/trunk/arch/mips/momentum/jaguar_atx/setup.c b/trunk/arch/mips/momentum/jaguar_atx/setup.c index 301d67226d72..bab192ddc185 100644 --- a/trunk/arch/mips/momentum/jaguar_atx/setup.c +++ b/trunk/arch/mips/momentum/jaguar_atx/setup.c @@ -50,7 +50,6 @@ #include #include #include -#include #include #include #include @@ -366,7 +365,7 @@ void __init plat_setup(void) _machine_restart = momenco_jaguar_restart; _machine_halt = momenco_jaguar_halt; - pm_power_off = momenco_jaguar_power_off; + _machine_power_off = momenco_jaguar_power_off; /* * initrd_start = (ulong)jaguar_initrd_start; diff --git a/trunk/arch/mips/momentum/ocelot_3/setup.c b/trunk/arch/mips/momentum/ocelot_3/setup.c index f95677f4f06f..c9b7ff8148ec 100644 --- a/trunk/arch/mips/momentum/ocelot_3/setup.c +++ b/trunk/arch/mips/momentum/ocelot_3/setup.c @@ -57,8 +57,6 @@ #include #include #include -#include - #include #include #include @@ -323,7 +321,7 @@ void __init plat_setup(void) _machine_restart = momenco_ocelot_restart; _machine_halt = momenco_ocelot_halt; - pm_power_off = momenco_ocelot_power_off; + _machine_power_off = momenco_ocelot_power_off; /* Wired TLB entries */ setup_wired_tlb_entries(); diff --git a/trunk/arch/mips/momentum/ocelot_c/setup.c b/trunk/arch/mips/momentum/ocelot_c/setup.c index 15998d8a9341..2755c1547473 100644 --- a/trunk/arch/mips/momentum/ocelot_c/setup.c +++ b/trunk/arch/mips/momentum/ocelot_c/setup.c @@ -51,10 +51,8 @@ #include #include #include -#include #include #include - #include #include #include @@ -238,7 +236,7 @@ void __init plat_setup(void) _machine_restart = momenco_ocelot_restart; _machine_halt = momenco_ocelot_halt; - pm_power_off = momenco_ocelot_power_off; + _machine_power_off = momenco_ocelot_power_off; /* * initrd_start = (ulong)ocelot_initrd_start; diff --git a/trunk/arch/mips/momentum/ocelot_g/setup.c b/trunk/arch/mips/momentum/ocelot_g/setup.c index fed4e8eee116..6336751391c3 100644 --- a/trunk/arch/mips/momentum/ocelot_g/setup.c +++ b/trunk/arch/mips/momentum/ocelot_g/setup.c @@ -47,10 +47,8 @@ #include #include #include -#include #include #include - #include #include #include @@ -171,7 +169,7 @@ void __init plat_setup(void) _machine_restart = momenco_ocelot_restart; _machine_halt = momenco_ocelot_halt; - pm_power_off = momenco_ocelot_power_off; + _machine_power_off = momenco_ocelot_power_off; /* * initrd_start = (ulong)ocelot_initrd_start; diff --git a/trunk/arch/mips/oprofile/Makefile b/trunk/arch/mips/oprofile/Makefile index 0a50aad5bbe4..354261d37d62 100644 --- a/trunk/arch/mips/oprofile/Makefile +++ b/trunk/arch/mips/oprofile/Makefile @@ -12,5 +12,4 @@ oprofile-y := $(DRIVER_OBJS) common.o oprofile-$(CONFIG_CPU_MIPS32) += op_model_mipsxx.o oprofile-$(CONFIG_CPU_MIPS64) += op_model_mipsxx.o -oprofile-$(CONFIG_CPU_SB1) += op_model_mipsxx.o oprofile-$(CONFIG_CPU_RM9000) += op_model_rm9000.o diff --git a/trunk/arch/mips/oprofile/common.c b/trunk/arch/mips/oprofile/common.c index 935dd851f480..53f9889b30ed 100644 --- a/trunk/arch/mips/oprofile/common.c +++ b/trunk/arch/mips/oprofile/common.c @@ -79,9 +79,6 @@ int __init oprofile_arch_init(struct oprofile_operations *ops) case CPU_20KC: case CPU_24K: case CPU_25KF: - case CPU_34K: - case CPU_SB1: - case CPU_SB1A: lmodel = &op_model_mipsxx; break; diff --git a/trunk/arch/mips/oprofile/op_model_mipsxx.c b/trunk/arch/mips/oprofile/op_model_mipsxx.c index 95d488ca0754..1d1eee407faf 100644 --- a/trunk/arch/mips/oprofile/op_model_mipsxx.c +++ b/trunk/arch/mips/oprofile/op_model_mipsxx.c @@ -201,21 +201,10 @@ static int __init mipsxx_init(void) op_model_mipsxx.cpu_type = "mips/25K"; break; -#ifndef CONFIG_SMP - case CPU_34K: - op_model_mipsxx.cpu_type = "mips/34K"; - break; -#endif - case CPU_5KC: op_model_mipsxx.cpu_type = "mips/5K"; break; - case CPU_SB1: - case CPU_SB1A: - op_model_mipsxx.cpu_type = "mips/sb1"; - break; - default: printk(KERN_ERR "Profiling unsupported for this CPU\n"); diff --git a/trunk/arch/mips/pci/Makefile b/trunk/arch/mips/pci/Makefile index 16205b587338..741e67c9195a 100644 --- a/trunk/arch/mips/pci/Makefile +++ b/trunk/arch/mips/pci/Makefile @@ -46,7 +46,6 @@ obj-$(CONFIG_PMC_YOSEMITE) += fixup-yosemite.o ops-titan.o ops-titan-ht.o \ obj-$(CONFIG_SGI_IP27) += pci-ip27.o obj-$(CONFIG_SGI_IP32) += fixup-ip32.o ops-mace.o pci-ip32.o obj-$(CONFIG_SIBYTE_SB1250) += fixup-sb1250.o pci-sb1250.o -obj-$(CONFIG_SIBYTE_BCM112X) += fixup-sb1250.o pci-sb1250.o obj-$(CONFIG_SIBYTE_BCM1x80) += pci-bcm1480.o pci-bcm1480ht.o obj-$(CONFIG_SNI_RM200_PCI) += fixup-sni.o ops-sni.o obj-$(CONFIG_TANBAC_TB0219) += fixup-tb0219.o diff --git a/trunk/arch/mips/pci/fixup-cobalt.c b/trunk/arch/mips/pci/fixup-cobalt.c index 75a01e764898..909292f50d06 100644 --- a/trunk/arch/mips/pci/fixup-cobalt.c +++ b/trunk/arch/mips/pci/fixup-cobalt.c @@ -17,7 +17,7 @@ #include #include -#include +#include extern int cobalt_board_id; @@ -52,7 +52,7 @@ static void qube_raq_via_bmIDE_fixup(struct pci_dev *dev) pci_read_config_byte(dev, PCI_LATENCY_TIMER, <); if (lt < 64) pci_write_config_byte(dev, PCI_LATENCY_TIMER, 64); - pci_write_config_byte(dev, PCI_CACHE_LINE_SIZE, 8); + pci_write_config_byte(dev, PCI_CACHE_LINE_SIZE, 7); } DECLARE_PCI_FIXUP_HEADER(PCI_VENDOR_ID_VIA, PCI_DEVICE_ID_VIA_82C586_1, @@ -69,7 +69,7 @@ static void qube_raq_galileo_fixup(struct pci_dev *dev) * host bridge. */ pci_write_config_byte(dev, PCI_LATENCY_TIMER, 64); - pci_write_config_byte(dev, PCI_CACHE_LINE_SIZE, 8); + pci_write_config_byte(dev, PCI_CACHE_LINE_SIZE, 7); /* * The code described by the comment below has been removed diff --git a/trunk/arch/mips/pci/ops-gt64111.c b/trunk/arch/mips/pci/ops-gt64111.c index 13de45940b19..c1807934768d 100644 --- a/trunk/arch/mips/pci/ops-gt64111.c +++ b/trunk/arch/mips/pci/ops-gt64111.c @@ -15,7 +15,7 @@ #include #include -#include +#include /* * Device 31 on the GT64111 is used to generate PCI special diff --git a/trunk/arch/mips/pci/pci-bcm1480.c b/trunk/arch/mips/pci/pci-bcm1480.c index ca975e7d32ff..f194b4e4f86a 100644 --- a/trunk/arch/mips/pci/pci-bcm1480.c +++ b/trunk/arch/mips/pci/pci-bcm1480.c @@ -234,9 +234,11 @@ static int __init bcm1480_pcibios_init(void) /* turn on ExpMemEn */ cmdreg = READCFG32(CFGOFFSET(0, PCI_DEVFN(PCI_BRIDGE_DEVICE, 0), 0x40)); + printk("PCIFeatureCtrl = %x\n", cmdreg); WRITECFG32(CFGOFFSET(0, PCI_DEVFN(PCI_BRIDGE_DEVICE, 0), 0x40), cmdreg | 0x10); cmdreg = READCFG32(CFGOFFSET(0, PCI_DEVFN(PCI_BRIDGE_DEVICE, 0), 0x40)); + printk("PCIFeatureCtrl = %x\n", cmdreg); /* * Establish mappings in KSEG2 (kernel virtual) to PCI I/O diff --git a/trunk/arch/mips/philips/pnx8550/common/platform.c b/trunk/arch/mips/philips/pnx8550/common/platform.c index a592260fd673..8aa9bd65b45e 100644 --- a/trunk/arch/mips/philips/pnx8550/common/platform.c +++ b/trunk/arch/mips/philips/pnx8550/common/platform.c @@ -66,28 +66,28 @@ struct ip3106_port ip3106_ports[] = { [0] = { .port = { .type = PORT_IP3106, - .iotype = UPIO_MEM, + .iotype = SERIAL_IO_MEM, .membase = (void __iomem *)PNX8550_UART_PORT0, .mapbase = PNX8550_UART_PORT0, .irq = PNX8550_UART_INT(0), .uartclk = 3692300, .fifosize = 16, .ops = &ip3106_pops, - .flags = UPF_BOOT_AUTOCONF, + .flags = ASYNC_BOOT_AUTOCONF, .line = 0, }, }, [1] = { .port = { .type = PORT_IP3106, - .iotype = UPIO_MEM, + .iotype = SERIAL_IO_MEM, .membase = (void __iomem *)PNX8550_UART_PORT1, .mapbase = PNX8550_UART_PORT1, .irq = PNX8550_UART_INT(1), .uartclk = 3692300, .fifosize = 16, .ops = &ip3106_pops, - .flags = UPF_BOOT_AUTOCONF, + .flags = ASYNC_BOOT_AUTOCONF, .line = 1, }, }, diff --git a/trunk/arch/mips/philips/pnx8550/common/setup.c b/trunk/arch/mips/philips/pnx8550/common/setup.c index 0d8a77619391..ee6bf72094f6 100644 --- a/trunk/arch/mips/philips/pnx8550/common/setup.c +++ b/trunk/arch/mips/philips/pnx8550/common/setup.c @@ -25,7 +25,6 @@ #include #include #include -#include #include #include @@ -91,7 +90,7 @@ void __init plat_setup(void) _machine_restart = pnx8550_machine_restart; _machine_halt = pnx8550_machine_halt; - pm_power_off = pnx8550_machine_power_off; + _machine_power_off = pnx8550_machine_power_off; board_time_init = pnx8550_time_init; board_timer_setup = pnx8550_timer_setup; diff --git a/trunk/arch/mips/pmc-sierra/yosemite/prom.c b/trunk/arch/mips/pmc-sierra/yosemite/prom.c index 165275c00cbb..555bfacf7647 100644 --- a/trunk/arch/mips/pmc-sierra/yosemite/prom.c +++ b/trunk/arch/mips/pmc-sierra/yosemite/prom.c @@ -13,7 +13,6 @@ #include #include #include -#include #include #include @@ -93,7 +92,7 @@ void __init prom_init(void) /* Callbacks for halt, restart */ _machine_restart = (void (*)(char *)) prom_exit; _machine_halt = prom_halt; - pm_power_off = prom_halt; + _machine_power_off = prom_halt; debug_vectors = cv; arcs_cmdline[0] = '\0'; diff --git a/trunk/arch/mips/pmc-sierra/yosemite/setup.c b/trunk/arch/mips/pmc-sierra/yosemite/setup.c index 8bce711575de..059755b5ed57 100644 --- a/trunk/arch/mips/pmc-sierra/yosemite/setup.c +++ b/trunk/arch/mips/pmc-sierra/yosemite/setup.c @@ -185,7 +185,7 @@ static void __init py_uart_setup(void) up.uartclk = TITAN_UART_CLK; up.regshift = 0; up.iotype = UPIO_MEM; - up.flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST; + up.flags = ASYNC_BOOT_AUTOCONF | ASYNC_SKIP_TEST; up.line = 0; if (early_serial_setup(&up)) diff --git a/trunk/arch/mips/sgi-ip22/ip22-reset.c b/trunk/arch/mips/sgi-ip22/ip22-reset.c index 92a3b3c15ed3..214ffd2e98a3 100644 --- a/trunk/arch/mips/sgi-ip22/ip22-reset.c +++ b/trunk/arch/mips/sgi-ip22/ip22-reset.c @@ -3,9 +3,8 @@ * License. See the file "COPYING" in the main directory of this archive * for more details. * - * Copyright (C) 1997, 1998, 2001, 03, 05, 06 by Ralf Baechle + * Copyright (C) 1997, 1998, 2001, 2003 by Ralf Baechle */ -#include #include #include #include @@ -13,7 +12,6 @@ #include #include #include -#include #include #include @@ -43,10 +41,28 @@ static struct timer_list power_timer, blink_timer, debounce_timer, volume_timer; #define MACHINE_PANICED 1 #define MACHINE_SHUTTING_DOWN 2 +static int machine_state = 0; -static int machine_state; +static void sgi_machine_restart(char *command) __attribute__((noreturn)); +static void sgi_machine_halt(void) __attribute__((noreturn)); +static void sgi_machine_power_off(void) __attribute__((noreturn)); -static void ATTRIB_NORET sgi_machine_power_off(void) +static void sgi_machine_restart(char *command) +{ + if (machine_state & MACHINE_SHUTTING_DOWN) + sgi_machine_power_off(); + sgimc->cpuctrl0 |= SGIMC_CCTRL0_SYSINIT; + while (1); +} + +static void sgi_machine_halt(void) +{ + if (machine_state & MACHINE_SHUTTING_DOWN) + sgi_machine_power_off(); + ArcEnterInteractiveMode(); +} + +static void sgi_machine_power_off(void) { unsigned int tmp; @@ -68,21 +84,6 @@ static void ATTRIB_NORET sgi_machine_power_off(void) } } -static void ATTRIB_NORET sgi_machine_restart(char *command) -{ - if (machine_state & MACHINE_SHUTTING_DOWN) - sgi_machine_power_off(); - sgimc->cpuctrl0 |= SGIMC_CCTRL0_SYSINIT; - while (1); -} - -static void ATTRIB_NORET sgi_machine_halt(void) -{ - if (machine_state & MACHINE_SHUTTING_DOWN) - sgi_machine_power_off(); - ArcEnterInteractiveMode(); -} - static void power_timeout(unsigned long data) { sgi_machine_power_off(); @@ -94,7 +95,7 @@ static void blink_timeout(unsigned long data) sgi_ioc_reset ^= (SGIOC_RESET_LC0OFF|SGIOC_RESET_LC1OFF); sgioc->reset = sgi_ioc_reset; - mod_timer(&blink_timer, jiffies + data); + mod_timer(&blink_timer, jiffies+data); } static void debounce(unsigned long data) @@ -102,7 +103,7 @@ static void debounce(unsigned long data) del_timer(&debounce_timer); if (sgint->istat1 & SGINT_ISTAT1_PWR) { /* Interrupt still being sent. */ - debounce_timer.expires = jiffies + (HZ / 20); /* 0.05s */ + debounce_timer.expires = jiffies + 5; /* 0.05s */ add_timer(&debounce_timer); sgioc->panel = SGIOC_PANEL_POWERON | SGIOC_PANEL_POWERINTR | @@ -150,7 +151,7 @@ static inline void volume_up_button(unsigned long data) indy_volume_button(1); if (sgint->istat1 & SGINT_ISTAT1_PWR) { - volume_timer.expires = jiffies + (HZ / 100); + volume_timer.expires = jiffies + 1; add_timer(&volume_timer); } } @@ -163,7 +164,7 @@ static inline void volume_down_button(unsigned long data) indy_volume_button(-1); if (sgint->istat1 & SGINT_ISTAT1_PWR) { - volume_timer.expires = jiffies + (HZ / 100); + volume_timer.expires = jiffies + 1; add_timer(&volume_timer); } } @@ -198,14 +199,14 @@ static irqreturn_t panel_int(int irq, void *dev_id, struct pt_regs *regs) if (!(buttons & SGIOC_PANEL_VOLUPINTR)) { init_timer(&volume_timer); volume_timer.function = volume_up_button; - volume_timer.expires = jiffies + (HZ / 100); + volume_timer.expires = jiffies + 1; add_timer(&volume_timer); } /* Volume down button was pressed */ if (!(buttons & SGIOC_PANEL_VOLDNINTR)) { init_timer(&volume_timer); volume_timer.function = volume_down_button; - volume_timer.expires = jiffies + (HZ / 100); + volume_timer.expires = jiffies + 1; add_timer(&volume_timer); } @@ -233,7 +234,7 @@ static int __init reboot_setup(void) { _machine_restart = sgi_machine_restart; _machine_halt = sgi_machine_halt; - pm_power_off = sgi_machine_power_off; + _machine_power_off = sgi_machine_power_off; request_irq(SGI_PANEL_IRQ, panel_int, 0, "Front Panel", NULL); init_timer(&blink_timer); diff --git a/trunk/arch/mips/sgi-ip22/ip22-setup.c b/trunk/arch/mips/sgi-ip22/ip22-setup.c index 7018e1833e85..5e59b4c8876b 100644 --- a/trunk/arch/mips/sgi-ip22/ip22-setup.c +++ b/trunk/arch/mips/sgi-ip22/ip22-setup.c @@ -56,7 +56,6 @@ extern void ip22_time_init(void) __init; void __init plat_setup(void) { char *ctype; - char *cserial; board_be_init = ip22_be_init; ip22_time_init(); @@ -82,14 +81,9 @@ void __init plat_setup(void) /* ARCS console environment variable is set to "g?" for * graphics console, it is set to "d" for the first serial * line and "d2" for the second serial line. - * - * Need to check if the case is 'g' but no keyboard: - * (ConsoleIn/Out = serial) */ ctype = ArcGetEnvironmentVariable("console"); - cserial = ArcGetEnvironmentVariable("ConsoleOut"); - - if ((ctype && *ctype == 'd') || (cserial && *cserial == 's')) { + if (ctype && *ctype == 'd') { static char options[8]; char *baud = ArcGetEnvironmentVariable("dbaud"); if (baud) @@ -97,7 +91,7 @@ void __init plat_setup(void) add_preferred_console("ttyS", *(ctype + 1) == '2' ? 1 : 0, baud ? options : NULL); } else if (!ctype || *ctype != 'g') { - /* Use ARC if we don't want serial ('d') or graphics ('g'). */ + /* Use ARC if we don't want serial ('d') or Newport ('g'). */ prom_flags |= PROM_FLAG_USE_AS_CONSOLE; add_preferred_console("arc", 0, NULL); } diff --git a/trunk/arch/mips/sgi-ip27/ip27-reset.c b/trunk/arch/mips/sgi-ip27/ip27-reset.c index 4322db57d3c1..2e16be94c78b 100644 --- a/trunk/arch/mips/sgi-ip27/ip27-reset.c +++ b/trunk/arch/mips/sgi-ip27/ip27-reset.c @@ -5,7 +5,7 @@ * * Reset an IP27. * - * Copyright (C) 1997, 1998, 1999, 2000, 06 by Ralf Baechle + * Copyright (C) 1997, 1998, 1999, 2000 by Ralf Baechle * Copyright (C) 1999, 2000 Silicon Graphics, Inc. */ #include @@ -15,7 +15,6 @@ #include #include #include -#include #include #include @@ -78,5 +77,5 @@ void ip27_reboot_setup(void) { _machine_restart = ip27_machine_restart; _machine_halt = ip27_machine_halt; - pm_power_off = ip27_machine_power_off; + _machine_power_off = ip27_machine_power_off; } diff --git a/trunk/arch/mips/sgi-ip32/ip32-reset.c b/trunk/arch/mips/sgi-ip32/ip32-reset.c index 0c948008b023..88e1f52059ff 100644 --- a/trunk/arch/mips/sgi-ip32/ip32-reset.c +++ b/trunk/arch/mips/sgi-ip32/ip32-reset.c @@ -15,7 +15,6 @@ #include #include #include -#include #include #include @@ -189,7 +188,7 @@ static __init int ip32_reboot_setup(void) _machine_restart = ip32_machine_restart; _machine_halt = ip32_machine_halt; - pm_power_off = ip32_machine_power_off; + _machine_power_off = ip32_machine_power_off; init_timer(&blink_timer); blink_timer.function = blink_timeout; diff --git a/trunk/arch/mips/sgi-ip32/ip32-setup.c b/trunk/arch/mips/sgi-ip32/ip32-setup.c index 2c38770b1e1b..d10a269aeae1 100644 --- a/trunk/arch/mips/sgi-ip32/ip32-setup.c +++ b/trunk/arch/mips/sgi-ip32/ip32-setup.c @@ -66,6 +66,11 @@ static inline void str2eaddr(unsigned char *ea, unsigned char *str) #include #include #include +extern int early_serial_setup(struct uart_port *port); + +#define STD_COM_FLAGS (ASYNC_SKIP_TEST) +#define BASE_BAUD (1843200 / 16) + #endif /* CONFIG_SERIAL_8250 */ /* An arbitrary time; this can be decreased if reliability looks good */ @@ -105,8 +110,8 @@ void __init plat_setup(void) o2_serial[0].type = PORT_16550A; o2_serial[0].line = 0; o2_serial[0].irq = MACEISA_SERIAL1_IRQ; - o2_serial[0].flags = UPF_SKIP_TEST; - o2_serial[0].uartclk = 1843200; + o2_serial[0].flags = STD_COM_FLAGS; + o2_serial[0].uartclk = BASE_BAUD * 16; o2_serial[0].iotype = UPIO_MEM; o2_serial[0].membase = (char *)&mace->isa.serial1; o2_serial[0].fifosize = 14; @@ -116,8 +121,8 @@ void __init plat_setup(void) o2_serial[1].type = PORT_16550A; o2_serial[1].line = 1; o2_serial[1].irq = MACEISA_SERIAL2_IRQ; - o2_serial[1].flags = UPF_SKIP_TEST; - o2_serial[1].uartclk = 1843200; + o2_serial[1].flags = STD_COM_FLAGS; + o2_serial[1].uartclk = BASE_BAUD * 16; o2_serial[1].iotype = UPIO_MEM; o2_serial[1].membase = (char *)&mace->isa.serial2; o2_serial[1].fifosize = 14; diff --git a/trunk/arch/mips/sibyte/cfe/setup.c b/trunk/arch/mips/sibyte/cfe/setup.c index ea308029450e..7a2c7a8510d4 100644 --- a/trunk/arch/mips/sibyte/cfe/setup.c +++ b/trunk/arch/mips/sibyte/cfe/setup.c @@ -23,7 +23,6 @@ #include #include #include -#include #include #include @@ -249,7 +248,7 @@ void __init prom_init(void) _machine_restart = cfe_linux_restart; _machine_halt = cfe_linux_halt; - pm_power_off = cfe_linux_halt; + _machine_power_off = cfe_linux_halt; /* * Check if a loader was used; if NOT, the 4 arguments are diff --git a/trunk/arch/mips/sibyte/sb1250/prom.c b/trunk/arch/mips/sibyte/sb1250/prom.c index 742043f8d755..de62ab0f55a2 100644 --- a/trunk/arch/mips/sibyte/sb1250/prom.c +++ b/trunk/arch/mips/sibyte/sb1250/prom.c @@ -24,7 +24,6 @@ #include #include #include -#include #include #include @@ -80,7 +79,7 @@ void __init prom_init(void) { _machine_restart = (void (*)(char *))prom_linux_exit; _machine_halt = prom_linux_exit; - pm_power_off = prom_linux_exit; + _machine_power_off = prom_linux_exit; strcpy(arcs_cmdline, "root=/dev/ram0 "); diff --git a/trunk/arch/mips/sibyte/sb1250/setup.c b/trunk/arch/mips/sibyte/sb1250/setup.c index fde4751c84fe..df2e266c700c 100644 --- a/trunk/arch/mips/sibyte/sb1250/setup.c +++ b/trunk/arch/mips/sibyte/sb1250/setup.c @@ -16,7 +16,6 @@ * Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */ #include -#include #include #include #include @@ -43,7 +42,7 @@ static inline int setup_bcm112x(void); /* Setup code likely to be common to all SiByte platforms */ -static int __init sys_rev_decode(void) +static inline int sys_rev_decode(void) { int ret = 0; @@ -75,7 +74,7 @@ static int __init sys_rev_decode(void) return ret; } -static int __init setup_bcm1250(void) +static inline int setup_bcm1250(void) { int ret = 0; @@ -121,7 +120,7 @@ static int __init setup_bcm1250(void) return ret; } -static int __init setup_bcm112x(void) +static inline int setup_bcm112x(void) { int ret = 0; @@ -147,7 +146,7 @@ static int __init setup_bcm112x(void) return ret; } -void __init sb1250_setup(void) +void sb1250_setup(void) { uint64_t sys_rev; int plldiv; @@ -170,42 +169,31 @@ void __init sb1250_setup(void) soc_str, pass_str, zbbus_mhz * 2, sb1_pass); prom_printf("Board type: %s\n", get_system_type()); - switch (war_pass) { + switch(war_pass) { case K_SYS_REVISION_BCM1250_PASS1: #ifndef CONFIG_SB1_PASS_1_WORKAROUNDS - prom_printf("@@@@ This is a BCM1250 A0-A2 (Pass 1) board, " - "and the kernel doesn't have the proper " - "workarounds compiled in. @@@@\n"); + prom_printf("@@@@ This is a BCM1250 A0-A2 (Pass 1) board, and the kernel doesn't have the proper workarounds compiled in. @@@@\n"); bad_config = 1; #endif break; case K_SYS_REVISION_BCM1250_PASS2: /* Pass 2 - easiest as default for now - so many numbers */ -#if !defined(CONFIG_SB1_PASS_2_WORKAROUNDS) || \ - !defined(CONFIG_SB1_PASS_2_1_WORKAROUNDS) - prom_printf("@@@@ This is a BCM1250 A3-A10 board, and the " - "kernel doesn't have the proper workarounds " - "compiled in. @@@@\n"); +#if !defined(CONFIG_SB1_PASS_2_WORKAROUNDS) || !defined(CONFIG_SB1_PASS_2_1_WORKAROUNDS) + prom_printf("@@@@ This is a BCM1250 A3-A10 board, and the kernel doesn't have the proper workarounds compiled in. @@@@\n"); bad_config = 1; #endif #ifdef CONFIG_CPU_HAS_PREFETCH - prom_printf("@@@@ Prefetches may be enabled in this kernel, " - "but are buggy on this board. @@@@\n"); + prom_printf("@@@@ Prefetches may be enabled in this kernel, but are buggy on this board. @@@@\n"); bad_config = 1; #endif break; case K_SYS_REVISION_BCM1250_PASS2_2: #ifndef CONFIG_SB1_PASS_2_WORKAROUNDS - prom_printf("@@@@ This is a BCM1250 B1/B2. board, and the " - "kernel doesn't have the proper workarounds " - "compiled in. @@@@\n"); + prom_printf("@@@@ This is a BCM1250 B1/B2. board, and the kernel doesn't have the proper workarounds compiled in. @@@@\n"); bad_config = 1; #endif -#if defined(CONFIG_SB1_PASS_2_1_WORKAROUNDS) || \ - !defined(CONFIG_CPU_HAS_PREFETCH) - prom_printf("@@@@ This is a BCM1250 B1/B2, but the kernel is " - "conservatively configured for an 'A' stepping. " - "@@@@\n"); +#if defined(CONFIG_SB1_PASS_2_1_WORKAROUNDS) || !defined(CONFIG_CPU_HAS_PREFETCH) + prom_printf("@@@@ This is a BCM1250 B1/B2, but the kernel is conservatively configured for an 'A' stepping. @@@@\n"); #endif break; default: diff --git a/trunk/arch/mips/sni/setup.c b/trunk/arch/mips/sni/setup.c index 1141fcd13a59..262c85680709 100644 --- a/trunk/arch/mips/sni/setup.c +++ b/trunk/arch/mips/sni/setup.c @@ -5,7 +5,7 @@ * License. See the file "COPYING" in the main directory of this archive * for more details. * - * Copyright (C) 1996, 97, 98, 2000, 03, 04, 06 Ralf Baechle (ralf@linux-mips.org) + * Copyright (C) 1996, 97, 98, 2000, 03, 04 Ralf Baechle (ralf@linux-mips.org) */ #include #include @@ -15,7 +15,6 @@ #include #include #include -#include #include #include #include @@ -190,7 +189,7 @@ void __init plat_setup(void) _machine_restart = sni_machine_restart; _machine_halt = sni_machine_halt; - pm_power_off = sni_machine_power_off; + _machine_power_off = sni_machine_power_off; sni_display_setup(); diff --git a/trunk/arch/mips/tx4927/toshiba_rbtx4927/toshiba_rbtx4927_prom.c b/trunk/arch/mips/tx4927/toshiba_rbtx4927/toshiba_rbtx4927_prom.c index e19e2be70f76..e4d095d3e192 100644 --- a/trunk/arch/mips/tx4927/toshiba_rbtx4927/toshiba_rbtx4927_prom.c +++ b/trunk/arch/mips/tx4927/toshiba_rbtx4927/toshiba_rbtx4927_prom.c @@ -60,6 +60,7 @@ void __init prom_init_cmdline(void) void __init prom_init(void) { + const char* toshiba_name_list[] = GROUP_TOSHIBA_NAMES; extern int tx4927_get_mem_size(void); extern char* toshiba_name; int msize; @@ -68,13 +69,12 @@ void __init prom_init(void) mips_machgroup = MACH_GROUP_TOSHIBA; - if ((read_c0_prid() & 0xff) == PRID_REV_TX4927) { + if ((read_c0_prid() & 0xff) == PRID_REV_TX4927) mips_machtype = MACH_TOSHIBA_RBTX4927; - toshiba_name = "TX4927"; - } else { + else mips_machtype = MACH_TOSHIBA_RBTX4937; - toshiba_name = "TX4937"; - } + + toshiba_name = toshiba_name_list[mips_machtype]; msize = tx4927_get_mem_size(); add_memory_region(0, msize << 20, BOOT_MEM_RAM); diff --git a/trunk/arch/mips/tx4927/toshiba_rbtx4927/toshiba_rbtx4927_setup.c b/trunk/arch/mips/tx4927/toshiba_rbtx4927/toshiba_rbtx4927_setup.c index 2ad6401d2af4..990fcb294bab 100644 --- a/trunk/arch/mips/tx4927/toshiba_rbtx4927/toshiba_rbtx4927_setup.c +++ b/trunk/arch/mips/tx4927/toshiba_rbtx4927/toshiba_rbtx4927_setup.c @@ -53,8 +53,6 @@ #include #include #include -#include - #include #include #include @@ -539,10 +537,19 @@ void tx4927_pci_setup(void) TOSHIBA_RBTX4927_SETUP_DPRINTK(TOSHIBA_RBTX4927_SETUP_PCI2, "0x%08lx=mips_io_port_base", mips_io_port_base); + + TOSHIBA_RBTX4927_SETUP_DPRINTK(TOSHIBA_RBTX4927_SETUP_PCI2, + "setup pci_io_resource to 0x%08lx 0x%08lx\n", + pci_io_resource.start, + pci_io_resource.end); + TOSHIBA_RBTX4927_SETUP_DPRINTK(TOSHIBA_RBTX4927_SETUP_PCI2, + "setup pci_mem_resource to 0x%08lx 0x%08lx\n", + pci_mem_resource.start, + pci_mem_resource.end); + if (!called) { printk - ("%s PCIC -- DID:%04x VID:%04x RID:%02x Arbiter:%s\n", - toshiba_name, + ("TX4927 PCIC -- DID:%04x VID:%04x RID:%02x Arbiter:%s\n", (unsigned short) (tx4927_pcicptr->pciid >> 16), (unsigned short) (tx4927_pcicptr->pciid & 0xffff), (unsigned short) (tx4927_pcicptr->pciccrev & 0xff), @@ -555,52 +562,21 @@ void tx4927_pci_setup(void) (tx4927_ccfgptr->ccfg & TX4927_CCFG_PCI66) ? " PCI66" : ""); if (tx4927_ccfgptr->pcfg & TX4927_PCFG_PCICLKEN_ALL) { int pciclk = 0; - if (mips_machtype == MACH_TOSHIBA_RBTX4937) - switch ((unsigned long) tx4927_ccfgptr-> - ccfg & TX4937_CCFG_PCIDIVMODE_MASK) { - case TX4937_CCFG_PCIDIVMODE_4: - pciclk = tx4927_cpu_clock / 4; - break; - case TX4937_CCFG_PCIDIVMODE_4_5: - pciclk = tx4927_cpu_clock * 2 / 9; - break; - case TX4937_CCFG_PCIDIVMODE_5: - pciclk = tx4927_cpu_clock / 5; - break; - case TX4937_CCFG_PCIDIVMODE_5_5: - pciclk = tx4927_cpu_clock * 2 / 11; - break; - case TX4937_CCFG_PCIDIVMODE_8: - pciclk = tx4927_cpu_clock / 8; - break; - case TX4937_CCFG_PCIDIVMODE_9: - pciclk = tx4927_cpu_clock / 9; - break; - case TX4937_CCFG_PCIDIVMODE_10: - pciclk = tx4927_cpu_clock / 10; - break; - case TX4937_CCFG_PCIDIVMODE_11: - pciclk = tx4927_cpu_clock / 11; - break; - } - - else - switch ((unsigned long) tx4927_ccfgptr-> - ccfg & TX4927_CCFG_PCIDIVMODE_MASK) { - case TX4927_CCFG_PCIDIVMODE_2_5: - pciclk = tx4927_cpu_clock * 2 / 5; - break; - case TX4927_CCFG_PCIDIVMODE_3: - pciclk = tx4927_cpu_clock / 3; - break; - case TX4927_CCFG_PCIDIVMODE_5: - pciclk = tx4927_cpu_clock / 5; - break; - case TX4927_CCFG_PCIDIVMODE_6: - pciclk = tx4927_cpu_clock / 6; - break; - } - + switch ((unsigned long) tx4927_ccfgptr-> + ccfg & TX4927_CCFG_PCIDIVMODE_MASK) { + case TX4927_CCFG_PCIDIVMODE_2_5: + pciclk = tx4927_cpu_clock * 2 / 5; + break; + case TX4927_CCFG_PCIDIVMODE_3: + pciclk = tx4927_cpu_clock / 3; + break; + case TX4927_CCFG_PCIDIVMODE_5: + pciclk = tx4927_cpu_clock / 5; + break; + case TX4927_CCFG_PCIDIVMODE_6: + pciclk = tx4927_cpu_clock / 6; + break; + } printk("Internal(%dMHz)", pciclk / 1000000); } else { int pciclk = 0; @@ -838,40 +814,24 @@ void __init toshiba_rbtx4927_setup(void) ":ResetRoutines\n"); _machine_restart = toshiba_rbtx4927_restart; _machine_halt = toshiba_rbtx4927_halt; - pm_power_off = toshiba_rbtx4927_power_off; + _machine_power_off = toshiba_rbtx4927_power_off; #ifdef CONFIG_PCI /* PCIC */ /* * ASSUMPTION: PCIDIVMODE is configured for PCI 33MHz or 66MHz. - * - * For TX4927: - * PCIDIVMODE[12:11]'s initial value is given by S9[4:3] (ON:0, OFF:1). + * PCIDIVMODE[12:11]'s initial value are given by S9[4:3] (ON:0, OFF:1). * CPU 166MHz: PCI 66MHz : PCIDIVMODE: 00 (1/2.5) * CPU 200MHz: PCI 66MHz : PCIDIVMODE: 01 (1/3) * CPU 166MHz: PCI 33MHz : PCIDIVMODE: 10 (1/5) * CPU 200MHz: PCI 33MHz : PCIDIVMODE: 11 (1/6) * i.e. S9[3]: ON (83MHz), OFF (100MHz) - * - * For TX4937: - * PCIDIVMODE[12:11]'s initial value is given by S1[5:4] (ON:0, OFF:1) - * PCIDIVMODE[10] is 0. - * CPU 266MHz: PCI 33MHz : PCIDIVMODE: 000 (1/8) - * CPU 266MHz: PCI 66MHz : PCIDIVMODE: 001 (1/4) - * CPU 300MHz: PCI 33MHz : PCIDIVMODE: 010 (1/9) - * CPU 300MHz: PCI 66MHz : PCIDIVMODE: 011 (1/4.5) - * CPU 333MHz: PCI 33MHz : PCIDIVMODE: 100 (1/10) - * CPU 333MHz: PCI 66MHz : PCIDIVMODE: 101 (1/5) - * */ TOSHIBA_RBTX4927_SETUP_DPRINTK(TOSHIBA_RBTX4927_SETUP_PCI1, - "ccfg is %lx, PCIDIVMODE is %x\n", - (unsigned long) tx4927_ccfgptr->ccfg, - (unsigned long) tx4927_ccfgptr->ccfg & - (mips_machtype == MACH_TOSHIBA_RBTX4937 ? - TX4937_CCFG_PCIDIVMODE_MASK : - TX4927_CCFG_PCIDIVMODE_MASK)); + "ccfg is %lx, DIV is %x\n", + (unsigned long) tx4927_ccfgptr-> + ccfg, TX4927_CCFG_PCIDIVMODE_MASK); TOSHIBA_RBTX4927_SETUP_DPRINTK(TOSHIBA_RBTX4927_SETUP_PCI1, "PCI66 mode is %lx, PCI mode is %lx, pci arb is %lx\n", @@ -882,30 +842,20 @@ void __init toshiba_rbtx4927_setup(void) (unsigned long) tx4927_ccfgptr-> ccfg & TX4927_CCFG_PCIXARB); - if (mips_machtype == MACH_TOSHIBA_RBTX4937) - switch ((unsigned long)tx4927_ccfgptr-> - ccfg & TX4937_CCFG_PCIDIVMODE_MASK) { - case TX4937_CCFG_PCIDIVMODE_8: - case TX4937_CCFG_PCIDIVMODE_4: - tx4927_cpu_clock = 266666666; /* 266MHz */ - break; - case TX4937_CCFG_PCIDIVMODE_9: - case TX4937_CCFG_PCIDIVMODE_4_5: - tx4927_cpu_clock = 300000000; /* 300MHz */ - break; - default: - tx4927_cpu_clock = 333333333; /* 333MHz */ - } - else - switch ((unsigned long)tx4927_ccfgptr-> - ccfg & TX4927_CCFG_PCIDIVMODE_MASK) { - case TX4927_CCFG_PCIDIVMODE_2_5: - case TX4927_CCFG_PCIDIVMODE_5: - tx4927_cpu_clock = 166666666; /* 166MHz */ - break; - default: - tx4927_cpu_clock = 200000000; /* 200MHz */ - } + TOSHIBA_RBTX4927_SETUP_DPRINTK(TOSHIBA_RBTX4927_SETUP_PCI1, + "PCIDIVMODE is %lx\n", + (unsigned long) tx4927_ccfgptr-> + ccfg & TX4927_CCFG_PCIDIVMODE_MASK); + + switch ((unsigned long) tx4927_ccfgptr-> + ccfg & TX4927_CCFG_PCIDIVMODE_MASK) { + case TX4927_CCFG_PCIDIVMODE_2_5: + case TX4927_CCFG_PCIDIVMODE_5: + tx4927_cpu_clock = 166000000; /* 166MHz */ + break; + default: + tx4927_cpu_clock = 200000000; /* 200MHz */ + } /* CCFG */ /* enable Timeout BusError */ diff --git a/trunk/arch/mips/tx4938/toshiba_rbtx4938/setup.c b/trunk/arch/mips/tx4938/toshiba_rbtx4938/setup.c index 5c7ace982a49..9f1dcc8ca5a3 100644 --- a/trunk/arch/mips/tx4938/toshiba_rbtx4938/setup.c +++ b/trunk/arch/mips/tx4938/toshiba_rbtx4938/setup.c @@ -20,8 +20,6 @@ #include #include #include -#include - #include #include #include @@ -1005,7 +1003,7 @@ void __init toshiba_rbtx4938_setup(void) _machine_restart = rbtx4938_machine_restart; _machine_halt = rbtx4938_machine_halt; - pm_power_off = rbtx4938_machine_power_off; + _machine_power_off = rbtx4938_machine_power_off; *rbtx4938_led_ptr = 0xff; printk("RBTX4938 --- FPGA(Rev %02x)", *rbtx4938_fpga_rev_ptr); diff --git a/trunk/arch/mips/vr41xx/common/pmu.c b/trunk/arch/mips/vr41xx/common/pmu.c index 5e469796413f..02bf4f7d06ba 100644 --- a/trunk/arch/mips/vr41xx/common/pmu.c +++ b/trunk/arch/mips/vr41xx/common/pmu.c @@ -21,7 +21,6 @@ #include #include #include -#include #include #include @@ -115,7 +114,7 @@ static int __init vr41xx_pmu_init(void) _machine_restart = vr41xx_restart; _machine_halt = vr41xx_halt; - pm_power_off = vr41xx_power_off; + _machine_power_off = vr41xx_power_off; return 0; } diff --git a/trunk/arch/parisc/Kconfig b/trunk/arch/parisc/Kconfig index 7c914a4c67c3..e77a06e9621e 100644 --- a/trunk/arch/parisc/Kconfig +++ b/trunk/arch/parisc/Kconfig @@ -149,20 +149,14 @@ config HOTPLUG_CPU default y if SMP select HOTPLUG -config ARCH_SELECT_MEMORY_MODEL - def_bool y - depends on 64BIT - config ARCH_DISCONTIGMEM_ENABLE - def_bool y - depends on 64BIT - -config ARCH_FLATMEM_ENABLE - def_bool y - -config ARCH_DISCONTIGMEM_DEFAULT - def_bool y - depends on ARCH_DISCONTIGMEM_ENABLE + bool "Discontiguous memory support (EXPERIMENTAL)" + depends on 64BIT && EXPERIMENTAL + help + Say Y to support efficient handling of discontiguous physical memory, + for architectures which are either NUMA (Non-Uniform Memory Access) + or have huge holes in the physical address space for other reasons. + See for more. source "kernel/Kconfig.hz" source "mm/Kconfig" diff --git a/trunk/arch/parisc/Kconfig.debug b/trunk/arch/parisc/Kconfig.debug index 9166bd117267..8caaed187a1f 100644 --- a/trunk/arch/parisc/Kconfig.debug +++ b/trunk/arch/parisc/Kconfig.debug @@ -11,14 +11,4 @@ config DEBUG_RWLOCK too many attempts. If you suspect a rwlock problem or a kernel hacker asks for this option then say Y. Otherwise say N. -config DEBUG_RODATA - bool "Write protect kernel read-only data structures" - depends on DEBUG_KERNEL - help - Mark the kernel read-only data as write-protected in the pagetables, - in order to catch accidental (and incorrect) writes to such const - data. This option may have a slight performance impact because a - portion of the kernel code won't be covered by a TLB anymore. - If in doubt, say "N". - endmenu diff --git a/trunk/arch/parisc/configs/a500_defconfig b/trunk/arch/parisc/configs/a500_defconfig index 959ad3c4e372..955ef5084f3e 100644 --- a/trunk/arch/parisc/configs/a500_defconfig +++ b/trunk/arch/parisc/configs/a500_defconfig @@ -602,7 +602,6 @@ CONFIG_ACENIC_OMIT_TIGON_I=y # CONFIG_DL2K is not set CONFIG_E1000=m CONFIG_E1000_NAPI=y -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/parisc/configs/b180_defconfig b/trunk/arch/parisc/configs/b180_defconfig index 37e98241ce4b..8819e7e6ae3f 100644 --- a/trunk/arch/parisc/configs/b180_defconfig +++ b/trunk/arch/parisc/configs/b180_defconfig @@ -1,7 +1,7 @@ # # Automatically generated make config: don't edit -# Linux kernel version: 2.6.16-rc1-pa0 -# Tue Jan 17 08:21:01 2006 +# Linux kernel version: 2.6.14-rc5-pa1 +# Fri Oct 21 23:06:10 2005 # CONFIG_PARISC=y CONFIG_MMU=y @@ -29,6 +29,8 @@ CONFIG_SYSVIPC=y # CONFIG_BSD_PROCESS_ACCT is not set CONFIG_SYSCTL=y # CONFIG_AUDIT is not set +# CONFIG_HOTPLUG is not set +CONFIG_KOBJECT_UEVENT=y CONFIG_IKCONFIG=y CONFIG_IKCONFIG_PROC=y CONFIG_INITRAMFS_SOURCE="" @@ -36,10 +38,8 @@ CONFIG_INITRAMFS_SOURCE="" CONFIG_KALLSYMS=y # CONFIG_KALLSYMS_ALL is not set # CONFIG_KALLSYMS_EXTRA_PASS is not set -CONFIG_HOTPLUG=y CONFIG_PRINTK=y CONFIG_BUG=y -CONFIG_ELF_CORE=y CONFIG_BASE_FULL=y CONFIG_FUTEX=y CONFIG_EPOLL=y @@ -48,10 +48,8 @@ CONFIG_CC_ALIGN_FUNCTIONS=0 CONFIG_CC_ALIGN_LABELS=0 CONFIG_CC_ALIGN_LOOPS=0 CONFIG_CC_ALIGN_JUMPS=0 -CONFIG_SLAB=y # CONFIG_TINY_SHMEM is not set CONFIG_BASE_SMALL=0 -# CONFIG_SLOB is not set # # Loadable module support @@ -59,27 +57,9 @@ CONFIG_BASE_SMALL=0 CONFIG_MODULES=y # CONFIG_MODULE_UNLOAD is not set CONFIG_OBSOLETE_MODPARM=y -CONFIG_MODVERSIONS=y # CONFIG_MODULE_SRCVERSION_ALL is not set # CONFIG_KMOD is not set -# -# Block layer -# - -# -# IO Schedulers -# -CONFIG_IOSCHED_NOOP=y -CONFIG_IOSCHED_AS=y -CONFIG_IOSCHED_DEADLINE=y -CONFIG_IOSCHED_CFQ=y -# CONFIG_DEFAULT_AS is not set -# CONFIG_DEFAULT_DEADLINE is not set -CONFIG_DEFAULT_CFQ=y -# CONFIG_DEFAULT_NOOP is not set -CONFIG_DEFAULT_IOSCHED="cfq" - # # Processor type and features # @@ -97,7 +77,6 @@ CONFIG_HZ=250 CONFIG_FLATMEM=y CONFIG_FLAT_NODE_MEM_MAP=y # CONFIG_SPARSEMEM_STATIC is not set -CONFIG_SPLIT_PTLOCK_CPUS=4096 # CONFIG_PREEMPT is not set # CONFIG_HPUX is not set @@ -105,8 +84,8 @@ CONFIG_SPLIT_PTLOCK_CPUS=4096 # Bus options (PCI, PCMCIA, EISA, GSC, ISA) # CONFIG_GSC=y -CONFIG_HPPB=y -CONFIG_IOMMU_CCIO=y +# CONFIG_HPPB is not set +# CONFIG_IOMMU_CCIO is not set CONFIG_GSC_LASI=y CONFIG_GSC_WAX=y CONFIG_EISA=y @@ -186,11 +165,8 @@ CONFIG_IPV6=y # CONFIG_LLC2 is not set # CONFIG_IPX is not set # CONFIG_ATALK is not set - -# -# QoS and/or fair queueing -# # CONFIG_NET_SCHED is not set +# CONFIG_NET_CLS_ROUTE is not set # # Network testing @@ -229,7 +205,6 @@ CONFIG_STANDALONE=y CONFIG_PARPORT=y CONFIG_PARPORT_PC=y # CONFIG_PARPORT_SERIAL is not set -CONFIG_PARPORT_NOT_PC=y CONFIG_PARPORT_GSC=y # CONFIG_PARPORT_1284 is not set @@ -255,6 +230,14 @@ CONFIG_BLK_DEV_RAM_COUNT=16 CONFIG_CDROM_PKTCDVD=m CONFIG_CDROM_PKTCDVD_BUFFERS=8 # CONFIG_CDROM_PKTCDVD_WCACHE is not set + +# +# IO Schedulers +# +CONFIG_IOSCHED_NOOP=y +CONFIG_IOSCHED_AS=y +CONFIG_IOSCHED_DEADLINE=y +CONFIG_IOSCHED_CFQ=y CONFIG_ATA_OVER_ETH=y # @@ -298,7 +281,6 @@ CONFIG_SCSI_SPI_ATTRS=y # # SCSI low-level drivers # -# CONFIG_ISCSI_TCP is not set # CONFIG_BLK_DEV_3W_XXXX_RAID is not set # CONFIG_SCSI_3W_9XXX is not set # CONFIG_SCSI_ACARD is not set @@ -331,19 +313,21 @@ CONFIG_SCSI_SYM53C8XX_2=y CONFIG_SCSI_SYM53C8XX_DMA_ADDRESSING_MODE=0 CONFIG_SCSI_SYM53C8XX_DEFAULT_TAGS=16 CONFIG_SCSI_SYM53C8XX_MAX_TAGS=64 -CONFIG_SCSI_SYM53C8XX_MMIO=y +# CONFIG_SCSI_SYM53C8XX_IOMAPPED is not set # CONFIG_SCSI_IPR is not set -CONFIG_SCSI_ZALON=y -CONFIG_SCSI_NCR53C8XX_DEFAULT_TAGS=8 -CONFIG_SCSI_NCR53C8XX_MAX_TAGS=32 -CONFIG_SCSI_NCR53C8XX_SYNC=40 -# CONFIG_SCSI_NCR53C8XX_PROFILE is not set +# CONFIG_SCSI_ZALON is not set # CONFIG_SCSI_PAS16 is not set # CONFIG_SCSI_PSI240I is not set # CONFIG_SCSI_QLOGIC_FAS is not set # CONFIG_SCSI_QLOGIC_FC is not set # CONFIG_SCSI_QLOGIC_1280 is not set -# CONFIG_SCSI_QLA_FC is not set +CONFIG_SCSI_QLA2XXX=y +# CONFIG_SCSI_QLA21XX is not set +# CONFIG_SCSI_QLA22XX is not set +# CONFIG_SCSI_QLA2300 is not set +# CONFIG_SCSI_QLA2322 is not set +# CONFIG_SCSI_QLA6312 is not set +# CONFIG_SCSI_QLA24XX is not set # CONFIG_SCSI_LPFC is not set # CONFIG_SCSI_SIM710 is not set # CONFIG_SCSI_SYM53C416 is not set @@ -413,7 +397,7 @@ CONFIG_NETDEVICES=y # CONFIG_NET_ETHERNET=y # CONFIG_MII is not set -CONFIG_LASI_82596=y +# CONFIG_LASI_82596 is not set # CONFIG_HAPPYMEAL is not set # CONFIG_SUNGEM is not set # CONFIG_CASSINI is not set @@ -480,7 +464,6 @@ CONFIG_NET_RADIO=y # Wireless 802.11b ISA/PCI cards support # # CONFIG_HERMES is not set -# CONFIG_ATMEL is not set # # Prism GT/Duette 802.11(a/b/g) PCI/Cardbus support @@ -544,7 +527,7 @@ CONFIG_KEYBOARD_ATKBD_HP_KEYCODES=y # CONFIG_KEYBOARD_XTKBD is not set # CONFIG_KEYBOARD_NEWTON is not set # CONFIG_KEYBOARD_HIL_OLD is not set -CONFIG_KEYBOARD_HIL=y +# CONFIG_KEYBOARD_HIL is not set CONFIG_INPUT_MOUSE=y CONFIG_MOUSE_PS2=y # CONFIG_MOUSE_SERIAL is not set @@ -552,7 +535,7 @@ CONFIG_MOUSE_PS2=y # CONFIG_MOUSE_LOGIBM is not set # CONFIG_MOUSE_PC110PAD is not set # CONFIG_MOUSE_VSXXXAA is not set -CONFIG_MOUSE_HIL=y +# CONFIG_MOUSE_HIL is not set # CONFIG_INPUT_JOYSTICK is not set # CONFIG_INPUT_TOUCHSCREEN is not set CONFIG_INPUT_MISC=y @@ -566,8 +549,7 @@ CONFIG_SERIO=y # CONFIG_SERIO_SERPORT is not set # CONFIG_SERIO_PARKBD is not set CONFIG_SERIO_GSCPS2=y -CONFIG_HP_SDC=y -CONFIG_HIL_MLC=y +# CONFIG_HP_SDC is not set # CONFIG_SERIO_PCIPS2 is not set CONFIG_SERIO_LIBPS2=y # CONFIG_SERIO_RAW is not set @@ -587,7 +569,6 @@ CONFIG_HW_CONSOLE=y CONFIG_SERIAL_8250=y CONFIG_SERIAL_8250_CONSOLE=y CONFIG_SERIAL_8250_NR_UARTS=13 -CONFIG_SERIAL_8250_RUNTIME_UARTS=4 CONFIG_SERIAL_8250_EXTENDED=y CONFIG_SERIAL_8250_MANY_PORTS=y CONFIG_SERIAL_8250_SHARE_IRQ=y @@ -601,10 +582,11 @@ CONFIG_SERIAL_8250_SHARE_IRQ=y # # Non-8250 serial port support # -CONFIG_SERIAL_MUX=y -CONFIG_SERIAL_MUX_CONSOLE=y +# CONFIG_SERIAL_MUX is not set +# CONFIG_PDC_CONSOLE is not set CONFIG_SERIAL_CORE=y CONFIG_SERIAL_CORE_CONSOLE=y +# CONFIG_SERIAL_JSM is not set CONFIG_UNIX98_PTYS=y CONFIG_LEGACY_PTYS=y CONFIG_LEGACY_PTY_COUNT=256 @@ -643,12 +625,6 @@ CONFIG_GEN_RTC=y # # CONFIG_I2C is not set -# -# SPI support -# -# CONFIG_SPI is not set -# CONFIG_SPI_MASTER is not set - # # Dallas's 1-wire bus # @@ -685,6 +661,7 @@ CONFIG_FB=y CONFIG_FB_CFB_FILLRECT=y CONFIG_FB_CFB_COPYAREA=y CONFIG_FB_CFB_IMAGEBLIT=y +CONFIG_FB_SOFT_CURSOR=y # CONFIG_FB_MACMODES is not set # CONFIG_FB_MODE_HELPERS is not set # CONFIG_FB_TILEBLITTING is not set @@ -694,7 +671,6 @@ CONFIG_FB_CFB_IMAGEBLIT=y # CONFIG_FB_ASILIANT is not set # CONFIG_FB_IMSTT is not set CONFIG_FB_STI=y -# CONFIG_FB_S1D13XXX is not set # CONFIG_FB_NVIDIA is not set # CONFIG_FB_RIVA is not set # CONFIG_FB_MATROX is not set @@ -707,7 +683,9 @@ CONFIG_FB_STI=y # CONFIG_FB_KYRO is not set # CONFIG_FB_3DFX is not set # CONFIG_FB_VOODOO1 is not set +# CONFIG_FB_CYBLA is not set # CONFIG_FB_TRIDENT is not set +# CONFIG_FB_S1D13XXX is not set # CONFIG_FB_VIRTUAL is not set # @@ -717,7 +695,6 @@ CONFIG_DUMMY_CONSOLE=y CONFIG_DUMMY_CONSOLE_COLUMNS=160 CONFIG_DUMMY_CONSOLE_ROWS=64 CONFIG_FRAMEBUFFER_CONSOLE=y -# CONFIG_FRAMEBUFFER_CONSOLE_ROTATION is not set CONFIG_STI_CONSOLE=y # CONFIG_FONTS is not set CONFIG_FONT_8x8=y @@ -736,85 +713,7 @@ CONFIG_LOGO_PARISC_CLUT224=y # # Sound # -CONFIG_SOUND=y - -# -# Advanced Linux Sound Architecture -# -CONFIG_SND=y -CONFIG_SND_TIMER=y -CONFIG_SND_PCM=y -CONFIG_SND_SEQUENCER=y -# CONFIG_SND_SEQ_DUMMY is not set -CONFIG_SND_OSSEMUL=y -CONFIG_SND_MIXER_OSS=y -CONFIG_SND_PCM_OSS=y -CONFIG_SND_SEQUENCER_OSS=y -CONFIG_SND_SUPPORT_OLD_API=y -# CONFIG_SND_VERBOSE_PRINTK is not set -# CONFIG_SND_DEBUG is not set - -# -# Generic devices -# -# CONFIG_SND_DUMMY is not set -# CONFIG_SND_VIRMIDI is not set -# CONFIG_SND_MTPAV is not set -# CONFIG_SND_SERIAL_U16550 is not set -# CONFIG_SND_MPU401 is not set - -# -# PCI devices -# -# CONFIG_SND_AD1889 is not set -# CONFIG_SND_ALI5451 is not set -# CONFIG_SND_ATIIXP is not set -# CONFIG_SND_ATIIXP_MODEM is not set -# CONFIG_SND_AU8810 is not set -# CONFIG_SND_AU8820 is not set -# CONFIG_SND_AU8830 is not set -# CONFIG_SND_BT87X is not set -# CONFIG_SND_CA0106 is not set -# CONFIG_SND_CMIPCI is not set -# CONFIG_SND_CS4281 is not set -# CONFIG_SND_CS46XX is not set -# CONFIG_SND_EMU10K1 is not set -# CONFIG_SND_EMU10K1X is not set -# CONFIG_SND_ENS1370 is not set -# CONFIG_SND_ENS1371 is not set -# CONFIG_SND_ES1938 is not set -# CONFIG_SND_ES1968 is not set -# CONFIG_SND_FM801 is not set -# CONFIG_SND_HDA_INTEL is not set -# CONFIG_SND_HDSP is not set -# CONFIG_SND_HDSPM is not set -# CONFIG_SND_ICE1712 is not set -# CONFIG_SND_ICE1724 is not set -# CONFIG_SND_INTEL8X0 is not set -# CONFIG_SND_KORG1212 is not set -# CONFIG_SND_MAESTRO3 is not set -# CONFIG_SND_MIXART is not set -# CONFIG_SND_NM256 is not set -# CONFIG_SND_PCXHR is not set -# CONFIG_SND_RME32 is not set -# CONFIG_SND_RME96 is not set -# CONFIG_SND_RME9652 is not set -# CONFIG_SND_SONICVIBES is not set -# CONFIG_SND_TRIDENT is not set -# CONFIG_SND_VIA82XX is not set -# CONFIG_SND_VIA82XX_MODEM is not set -# CONFIG_SND_VX222 is not set -# CONFIG_SND_YMFPCI is not set - -# -# GSC devices -# -CONFIG_SND_HARMONY=y - -# -# Open Sound System -# -# CONFIG_SOUND_PRIME is not set +# CONFIG_SOUND is not set # # USB support @@ -823,10 +722,6 @@ CONFIG_USB_ARCH_HAS_HCD=y CONFIG_USB_ARCH_HAS_OHCI=y # CONFIG_USB is not set -# -# NOTE: USB_STORAGE enables SCSI, and 'SCSI disk support' -# - # # USB Gadget Support # @@ -982,23 +877,18 @@ CONFIG_NLS_DEFAULT="iso8859-1" # Kernel hacking # # CONFIG_PRINTK_TIME is not set -CONFIG_MAGIC_SYSRQ=y CONFIG_DEBUG_KERNEL=y +CONFIG_MAGIC_SYSRQ=y CONFIG_LOG_BUF_SHIFT=16 CONFIG_DETECT_SOFTLOCKUP=y # CONFIG_SCHEDSTATS is not set # CONFIG_DEBUG_SLAB is not set -# CONFIG_DEBUG_MUTEXES is not set # CONFIG_DEBUG_SPINLOCK is not set # CONFIG_DEBUG_SPINLOCK_SLEEP is not set # CONFIG_DEBUG_KOBJECT is not set # CONFIG_DEBUG_INFO is not set # CONFIG_DEBUG_IOREMAP is not set # CONFIG_DEBUG_FS is not set -# CONFIG_DEBUG_VM is not set -CONFIG_FORCED_INLINING=y -# CONFIG_RCU_TORTURE_TEST is not set -# CONFIG_DEBUG_RODATA is not set # # Security options diff --git a/trunk/arch/parisc/configs/c3000_defconfig b/trunk/arch/parisc/configs/c3000_defconfig index 0b1c8c1fa8a3..9d86b6b1ebd1 100644 --- a/trunk/arch/parisc/configs/c3000_defconfig +++ b/trunk/arch/parisc/configs/c3000_defconfig @@ -626,7 +626,6 @@ CONFIG_ACENIC=m # CONFIG_DL2K is not set CONFIG_E1000=m # CONFIG_E1000_NAPI is not set -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/parisc/hpux/entry_hpux.S b/trunk/arch/parisc/hpux/entry_hpux.S index 31c8cccfba31..fa9bf38787e7 100644 --- a/trunk/arch/parisc/hpux/entry_hpux.S +++ b/trunk/arch/parisc/hpux/entry_hpux.S @@ -22,9 +22,10 @@ #include #include + .text + #define ENTRY_NAME(_name_) .word _name_ - .section .rodata,"a" .align 4 .export hpux_call_table .import hpux_unimplemented_wrapper diff --git a/trunk/arch/parisc/hpux/sys_hpux.c b/trunk/arch/parisc/hpux/sys_hpux.c index 05273ccced0e..29b4d61898f2 100644 --- a/trunk/arch/parisc/hpux/sys_hpux.c +++ b/trunk/arch/parisc/hpux/sys_hpux.c @@ -468,23 +468,19 @@ int hpux_sysfs(int opcode, unsigned long arg1, unsigned long arg2) if ( opcode == 1 ) { /* GETFSIND */ len = strlen_user((char *)arg1); printk(KERN_DEBUG "len of arg1 = %d\n", len); - if (len == 0) - return 0; - fsname = (char *) kmalloc(len, GFP_KERNEL); + + fsname = (char *) kmalloc(len+1, GFP_KERNEL); if ( !fsname ) { printk(KERN_DEBUG "failed to kmalloc fsname\n"); return 0; } - if ( copy_from_user(fsname, (char *)arg1, len) ) { + if ( copy_from_user(fsname, (char *)arg1, len+1) ) { printk(KERN_DEBUG "failed to copy_from_user fsname\n"); kfree(fsname); return 0; } - /* String could be altered by userspace after strlen_user() */ - fsname[len] = '\0'; - printk(KERN_DEBUG "that is '%s' as (char *)\n", fsname); if ( !strcmp(fsname, "hfs") ) { fstype = 0; diff --git a/trunk/arch/parisc/kernel/drivers.c b/trunk/arch/parisc/kernel/drivers.c index 3d569a485a1a..2d804e2d16d1 100644 --- a/trunk/arch/parisc/kernel/drivers.c +++ b/trunk/arch/parisc/kernel/drivers.c @@ -408,10 +408,11 @@ static void setup_bus_id(struct parisc_device *padev) struct parisc_device * create_tree_node(char id, struct device *parent) { - struct parisc_device *dev = kzalloc(sizeof(*dev), GFP_KERNEL); + struct parisc_device *dev = kmalloc(sizeof(*dev), GFP_KERNEL); if (!dev) return NULL; + memset(dev, 0, sizeof(*dev)); dev->hw_path = id; dev->id.hw_type = HPHW_FAULTY; diff --git a/trunk/arch/parisc/kernel/parisc_ksyms.c b/trunk/arch/parisc/kernel/parisc_ksyms.c index 1d00c365f2b1..f40a777dd388 100644 --- a/trunk/arch/parisc/kernel/parisc_ksyms.c +++ b/trunk/arch/parisc/kernel/parisc_ksyms.c @@ -48,6 +48,9 @@ EXPORT_SYMBOL(strrchr); EXPORT_SYMBOL(strstr); EXPORT_SYMBOL(strpbrk); +#include +EXPORT_SYMBOL(pm_power_off); + #include EXPORT_SYMBOL(__xchg8); EXPORT_SYMBOL(__xchg32); diff --git a/trunk/arch/parisc/kernel/pci.c b/trunk/arch/parisc/kernel/pci.c index 79c7db2705fd..88cba49c5301 100644 --- a/trunk/arch/parisc/kernel/pci.c +++ b/trunk/arch/parisc/kernel/pci.c @@ -47,17 +47,18 @@ * this makes the boot time much longer than necessary. * 20ms seems to work for all the HP PCI implementations to date. * - * #define pci_post_reset_delay 50 + * XXX: turn into a #defined constant in ? */ +int pci_post_reset_delay = 50; -struct pci_port_ops *pci_port __read_mostly; -struct pci_bios_ops *pci_bios __read_mostly; +struct pci_port_ops *pci_port; +struct pci_bios_ops *pci_bios; -static int pci_hba_count __read_mostly; +int pci_hba_count = 0; /* parisc_pci_hba used by pci_port->in/out() ops to lookup bus data. */ #define PCI_HBA_MAX 32 -static struct pci_hba_data *parisc_pci_hba[PCI_HBA_MAX] __read_mostly; +struct pci_hba_data *parisc_pci_hba[PCI_HBA_MAX]; /******************************************************************** @@ -258,10 +259,8 @@ void __devinit pcibios_resource_to_bus(struct pci_dev *dev, void pcibios_bus_to_resource(struct pci_dev *dev, struct resource *res, struct pci_bus_region *region) { -#ifdef CONFIG_64BIT struct pci_bus *bus = dev->bus; struct pci_hba_data *hba = HBA_DATA(bus->bridge->platform_data); -#endif if (res->flags & IORESOURCE_MEM) { res->start = PCI_HOST_ADDR(hba, region->start); diff --git a/trunk/arch/parisc/kernel/perf.c b/trunk/arch/parisc/kernel/perf.c index 53f861c82f93..11d406cd0b3e 100644 --- a/trunk/arch/parisc/kernel/perf.c +++ b/trunk/arch/parisc/kernel/perf.c @@ -68,20 +68,20 @@ struct rdr_tbl_ent { }; static int perf_processor_interface __read_mostly = UNKNOWN_INTF; -static int perf_enabled __read_mostly; +static int perf_enabled __read_mostly = 0; static spinlock_t perf_lock; -struct parisc_device *cpu_device __read_mostly; +struct parisc_device *cpu_device __read_mostly = NULL; /* RDRs to write for PCX-W */ -static const int perf_rdrs_W[] = +static int perf_rdrs_W[] = { 0, 1, 4, 5, 6, 15, 16, 17, 18, 20, 21, 22, 23, 24, 25, -1 }; /* RDRs to write for PCX-U */ -static const int perf_rdrs_U[] = +static int perf_rdrs_U[] = { 0, 1, 4, 5, 6, 7, 16, 17, 18, 20, 21, 22, 23, 24, 25, -1 }; /* RDR register descriptions for PCX-W */ -static const struct rdr_tbl_ent perf_rdr_tbl_W[] = { +static struct rdr_tbl_ent perf_rdr_tbl_W[] = { { 19, 1, 8 }, /* RDR 0 */ { 16, 1, 16 }, /* RDR 1 */ { 72, 2, 0 }, /* RDR 2 */ @@ -117,7 +117,7 @@ static const struct rdr_tbl_ent perf_rdr_tbl_W[] = { }; /* RDR register descriptions for PCX-U */ -static const struct rdr_tbl_ent perf_rdr_tbl_U[] = { +static struct rdr_tbl_ent perf_rdr_tbl_U[] = { { 19, 1, 8 }, /* RDR 0 */ { 32, 1, 16 }, /* RDR 1 */ { 20, 1, 0 }, /* RDR 2 */ @@ -156,7 +156,7 @@ static const struct rdr_tbl_ent perf_rdr_tbl_U[] = { * A non-zero write_control in the above tables is a byte offset into * this array. */ -static const uint64_t perf_bitmasks[] = { +static uint64_t perf_bitmasks[] = { 0x0000000000000000ul, /* first dbl word must be zero */ 0xfdffe00000000000ul, /* RDR0 bitmask */ 0x003f000000000000ul, /* RDR1 bitmask */ @@ -173,7 +173,7 @@ static const uint64_t perf_bitmasks[] = { * Write control bitmasks for Pa-8700 processor given * somethings have changed slightly. */ -static const uint64_t perf_bitmasks_piranha[] = { +static uint64_t perf_bitmasks_piranha[] = { 0x0000000000000000ul, /* first dbl word must be zero */ 0xfdffe00000000000ul, /* RDR0 bitmask */ 0x003f000000000000ul, /* RDR1 bitmask */ @@ -186,7 +186,7 @@ static const uint64_t perf_bitmasks_piranha[] = { 0xfffc000000000000ul }; -static const uint64_t *bitmask_array; /* array of bitmasks to use */ +static uint64_t *bitmask_array; /* array of bitmasks to use */ /****************************************************************************** * Function Prototypes @@ -200,7 +200,7 @@ static ssize_t perf_write(struct file *file, const char __user *buf, size_t coun static long perf_ioctl(struct file *file, unsigned int cmd, unsigned long arg); static void perf_start_counters(void); static int perf_stop_counters(uint32_t *raddr); -static const struct rdr_tbl_ent * perf_rdr_get_entry(uint32_t rdr_num); +static struct rdr_tbl_ent * perf_rdr_get_entry(uint32_t rdr_num); static int perf_rdr_read_ubuf(uint32_t rdr_num, uint64_t *buffer); static int perf_rdr_clear(uint32_t rdr_num); static int perf_write_image(uint64_t *memaddr); @@ -444,6 +444,7 @@ static long perf_ioctl(struct file *file, unsigned int cmd, unsigned long arg) uint32_t raddr[4]; int error = 0; + lock_kernel(); switch (cmd) { case PA_PERF_ON: @@ -476,6 +477,8 @@ static long perf_ioctl(struct file *file, unsigned int cmd, unsigned long arg) error = -ENOTTY; } + unlock_kernel(); + return error; } @@ -652,7 +655,7 @@ static int perf_stop_counters(uint32_t *raddr) * Retrieve a pointer to the description of what this * RDR contains. */ -static const struct rdr_tbl_ent * perf_rdr_get_entry(uint32_t rdr_num) +static struct rdr_tbl_ent * perf_rdr_get_entry(uint32_t rdr_num) { if (perf_processor_interface == ONYX_INTF) { return &perf_rdr_tbl_U[rdr_num]; @@ -670,7 +673,7 @@ static int perf_rdr_read_ubuf(uint32_t rdr_num, uint64_t *buffer) { uint64_t data, data_mask = 0; uint32_t width, xbits, i; - const struct rdr_tbl_ent *tentry; + struct rdr_tbl_ent *tentry; tentry = perf_rdr_get_entry(rdr_num); if ((width = tentry->width) == 0) @@ -718,7 +721,7 @@ static int perf_rdr_read_ubuf(uint32_t rdr_num, uint64_t *buffer) */ static int perf_rdr_clear(uint32_t rdr_num) { - const struct rdr_tbl_ent *tentry; + struct rdr_tbl_ent *tentry; int32_t i; tentry = perf_rdr_get_entry(rdr_num); @@ -750,11 +753,10 @@ static int perf_write_image(uint64_t *memaddr) uint64_t buffer[MAX_RDR_WORDS]; uint64_t *bptr; uint32_t dwords; - const uint32_t *intrigue_rdr; - const uint64_t *intrigue_bitmask; - uint64_t tmp64; + uint32_t *intrigue_rdr; + uint64_t *intrigue_bitmask, tmp64; void __iomem *runway; - const struct rdr_tbl_ent *tentry; + struct rdr_tbl_ent *tentry; int i; /* Clear out counters */ @@ -828,7 +830,7 @@ static int perf_write_image(uint64_t *memaddr) */ static void perf_rdr_write(uint32_t rdr_num, uint64_t *buffer) { - const struct rdr_tbl_ent *tentry; + struct rdr_tbl_ent *tentry; int32_t i; printk("perf_rdr_write\n"); diff --git a/trunk/arch/parisc/kernel/perf_images.h b/trunk/arch/parisc/kernel/perf_images.h index 7fef9644df47..d9562fe3f75c 100644 --- a/trunk/arch/parisc/kernel/perf_images.h +++ b/trunk/arch/parisc/kernel/perf_images.h @@ -25,7 +25,7 @@ #define PCXU_IMAGE_SIZE 584 -static uint32_t onyx_images[][PCXU_IMAGE_SIZE/sizeof(uint32_t)] __read_mostly = { +static uint32_t onyx_images[][PCXU_IMAGE_SIZE/sizeof(uint32_t)] = { /* * CPI: * @@ -2093,7 +2093,7 @@ static uint32_t onyx_images[][PCXU_IMAGE_SIZE/sizeof(uint32_t)] __read_mostly = }; #define PCXW_IMAGE_SIZE 576 -static uint32_t cuda_images[][PCXW_IMAGE_SIZE/sizeof(uint32_t)] __read_mostly = { +static uint32_t cuda_images[][PCXW_IMAGE_SIZE/sizeof(uint32_t)] = { /* * CPI: FROM CPI.IDF (Image 0) * diff --git a/trunk/arch/parisc/kernel/process.c b/trunk/arch/parisc/kernel/process.c index e8dea4177113..5da41677e70b 100644 --- a/trunk/arch/parisc/kernel/process.c +++ b/trunk/arch/parisc/kernel/process.c @@ -54,6 +54,27 @@ #include #include +static int hlt_counter __read_mostly; + +/* + * Power off function, if any + */ +void (*pm_power_off)(void); + +void disable_hlt(void) +{ + hlt_counter++; +} + +EXPORT_SYMBOL(disable_hlt); + +void enable_hlt(void) +{ + hlt_counter--; +} + +EXPORT_SYMBOL(enable_hlt); + void default_idle(void) { barrier(); @@ -81,7 +102,12 @@ void cpu_idle(void) } -#define COMMAND_GLOBAL F_EXTEND(0xfffe0030) +#ifdef __LP64__ +#define COMMAND_GLOBAL 0xfffffffffffe0030UL +#else +#define COMMAND_GLOBAL 0xfffe0030 +#endif + #define CMD_RESET 5 /* reset any module */ /* @@ -136,7 +162,6 @@ void machine_halt(void) */ } -void (*chassis_power_off)(void); /* * This routine is called from sys_reboot to actually turn off the @@ -145,8 +170,8 @@ void (*chassis_power_off)(void); void machine_power_off(void) { /* If there is a registered power off handler, call it. */ - if (chassis_power_off) - chassis_power_off(); + if(pm_power_off) + pm_power_off(); /* Put the soft power button back under hardware control. * If the user had already pressed the power button, the @@ -162,8 +187,6 @@ void machine_power_off(void) KERN_EMERG "Please power this system off now."); } -void (*pm_power_off)(void) = machine_power_off; -EXPORT_SYMBOL(pm_power_off); /* * Create a kernel thread diff --git a/trunk/arch/parisc/kernel/ptrace.c b/trunk/arch/parisc/kernel/ptrace.c index 413292f1a4a3..27160e8bf15b 100644 --- a/trunk/arch/parisc/kernel/ptrace.c +++ b/trunk/arch/parisc/kernel/ptrace.c @@ -91,7 +91,7 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) int copied; #ifdef __LP64__ - if (personality(child->personality) == PER_LINUX32) { + if (is_compat_task(child)) { unsigned int tmp; addr &= 0xffffffffL; @@ -123,7 +123,7 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) case PTRACE_POKEDATA: ret = 0; #ifdef __LP64__ - if (personality(child->personality) == PER_LINUX32) { + if (is_compat_task(child)) { unsigned int tmp = (unsigned int)data; DBG("sys_ptrace(POKE%s, %d, %lx, %lx)\n", request == PTRACE_POKETEXT ? "TEXT" : "DATA", @@ -146,7 +146,7 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) case PTRACE_PEEKUSR: { ret = -EIO; #ifdef __LP64__ - if (personality(child->personality) == PER_LINUX32) { + if (is_compat_task(child)) { unsigned int tmp; if (addr & (sizeof(int)-1)) @@ -205,7 +205,7 @@ long arch_ptrace(struct task_struct *child, long request, long addr, long data) goto out_tsk; } #ifdef __LP64__ - if (personality(child->personality) == PER_LINUX32) { + if (is_compat_task(child)) { if (addr & (sizeof(int)-1)) goto out_tsk; if ((addr = translate_usr_offset(addr)) < 0) diff --git a/trunk/arch/parisc/kernel/signal.c b/trunk/arch/parisc/kernel/signal.c index 05767e83cf2d..3a25a7bd673e 100644 --- a/trunk/arch/parisc/kernel/signal.c +++ b/trunk/arch/parisc/kernel/signal.c @@ -317,7 +317,7 @@ setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info, if(personality(current->personality) == PER_LINUX32) { DBG(1,"setup_rt_frame: frame->info = 0x%p\n", &compat_frame->info); - err |= copy_siginfo_to_user32(&compat_frame->info, info); + err |= compat_copy_siginfo_to_user(&compat_frame->info, info); DBG(1,"SETUP_RT_FRAME: 1\n"); compat_val = (compat_int_t)current->sas_ss_sp; err |= __put_user(compat_val, &compat_frame->uc.uc_stack.ss_sp); diff --git a/trunk/arch/parisc/kernel/signal32.c b/trunk/arch/parisc/kernel/signal32.c index a6b4231cafa1..0792e20efef3 100644 --- a/trunk/arch/parisc/kernel/signal32.c +++ b/trunk/arch/parisc/kernel/signal32.c @@ -31,6 +31,7 @@ #include #include +#include #include #include "signal32.h" @@ -397,104 +398,3 @@ setup_sigcontext32(struct compat_sigcontext __user *sc, struct compat_regfile __ return err; } - -int -copy_siginfo_from_user32 (siginfo_t *to, compat_siginfo_t __user *from) -{ - unsigned long tmp; - int err; - - if (!access_ok(VERIFY_READ, from, sizeof(compat_siginfo_t))) - return -EFAULT; - - err = __get_user(to->si_signo, &from->si_signo); - err |= __get_user(to->si_errno, &from->si_errno); - err |= __get_user(to->si_code, &from->si_code); - - if (to->si_code < 0) - err |= __copy_from_user(&to->_sifields._pad, &from->_sifields._pad, SI_PAD_SIZE); - else { - switch (to->si_code >> 16) { - case __SI_CHLD >> 16: - err |= __get_user(to->si_utime, &from->si_utime); - err |= __get_user(to->si_stime, &from->si_stime); - err |= __get_user(to->si_status, &from->si_status); - default: - err |= __get_user(to->si_pid, &from->si_pid); - err |= __get_user(to->si_uid, &from->si_uid); - break; - case __SI_FAULT >> 16: - err |= __get_user(tmp, &from->si_addr); - to->si_addr = (void __user *) tmp; - break; - case __SI_POLL >> 16: - err |= __get_user(to->si_band, &from->si_band); - err |= __get_user(to->si_fd, &from->si_fd); - break; - case __SI_RT >> 16: /* This is not generated by the kernel as of now. */ - case __SI_MESGQ >> 16: - err |= __get_user(to->si_pid, &from->si_pid); - err |= __get_user(to->si_uid, &from->si_uid); - err |= __get_user(to->si_int, &from->si_int); - break; - } - } - return err; -} - -int -copy_siginfo_to_user32 (compat_siginfo_t __user *to, siginfo_t *from) -{ - unsigned int addr; - int err; - - if (!access_ok(VERIFY_WRITE, to, sizeof(compat_siginfo_t))) - return -EFAULT; - - /* If you change siginfo_t structure, please be sure - this code is fixed accordingly. - It should never copy any pad contained in the structure - to avoid security leaks, but must copy the generic - 3 ints plus the relevant union member. - This routine must convert siginfo from 64bit to 32bit as well - at the same time. */ - err = __put_user(from->si_signo, &to->si_signo); - err |= __put_user(from->si_errno, &to->si_errno); - err |= __put_user((short)from->si_code, &to->si_code); - if (from->si_code < 0) - err |= __copy_to_user(&to->_sifields._pad, &from->_sifields._pad, SI_PAD_SIZE); - else { - switch (from->si_code >> 16) { - case __SI_CHLD >> 16: - err |= __put_user(from->si_utime, &to->si_utime); - err |= __put_user(from->si_stime, &to->si_stime); - err |= __put_user(from->si_status, &to->si_status); - default: - err |= __put_user(from->si_pid, &to->si_pid); - err |= __put_user(from->si_uid, &to->si_uid); - break; - case __SI_FAULT >> 16: - /* avoid type-checking warnings by copying _pad[0] in lieu of si_addr... */ - err |= __put_user(from->_sifields._pad[0], &to->si_addr); - break; - case __SI_POLL >> 16: - err |= __put_user(from->si_band, &to->si_band); - err |= __put_user(from->si_fd, &to->si_fd); - break; - case __SI_TIMER >> 16: - err |= __put_user(from->si_tid, &to->si_tid); - err |= __put_user(from->si_overrun, &to->si_overrun); - addr = (unsigned long) from->si_ptr; - err |= __put_user(addr, &to->si_ptr); - break; - case __SI_RT >> 16: /* Not generated by the kernel as of now. */ - case __SI_MESGQ >> 16: - err |= __put_user(from->si_uid, &to->si_uid); - err |= __put_user(from->si_pid, &to->si_pid); - addr = (unsigned long) from->si_ptr; - err |= __put_user(addr, &to->si_ptr); - break; - } - } - return err; -} diff --git a/trunk/arch/parisc/kernel/signal32.h b/trunk/arch/parisc/kernel/signal32.h index e39b38a67a87..4d1569e717cc 100644 --- a/trunk/arch/parisc/kernel/signal32.h +++ b/trunk/arch/parisc/kernel/signal32.h @@ -20,34 +20,8 @@ #define _PARISC64_KERNEL_SIGNAL32_H #include - -typedef compat_uptr_t compat_sighandler_t; - -typedef struct compat_sigaltstack { - compat_uptr_t ss_sp; - compat_int_t ss_flags; - compat_size_t ss_size; -} compat_stack_t; - -/* Most things should be clean enough to redefine this at will, if care - is taken to make libc match. */ - -struct compat_sigaction { - compat_sighandler_t sa_handler; - compat_uint_t sa_flags; - compat_sigset_t sa_mask; /* mask last for extensibility */ -}; - -/* 32-bit ucontext as seen from an 64-bit kernel */ -struct compat_ucontext { - compat_uint_t uc_flags; - compat_uptr_t uc_link; - compat_stack_t uc_stack; /* struct compat_sigaltstack (12 bytes)*/ - /* FIXME: Pad out to get uc_mcontext to start at an 8-byte aligned boundary */ - compat_uint_t pad[1]; - struct compat_sigcontext uc_mcontext; - compat_sigset_t uc_sigmask; /* mask last for extensibility */ -}; +#include +#include /* ELF32 signal handling */ @@ -55,103 +29,6 @@ struct k_sigaction32 { struct compat_sigaction sa; }; -typedef struct compat_siginfo { - int si_signo; - int si_errno; - int si_code; - - union { - int _pad[((128/sizeof(int)) - 3)]; - - /* kill() */ - struct { - unsigned int _pid; /* sender's pid */ - unsigned int _uid; /* sender's uid */ - } _kill; - - /* POSIX.1b timers */ - struct { - compat_timer_t _tid; /* timer id */ - int _overrun; /* overrun count */ - char _pad[sizeof(unsigned int) - sizeof(int)]; - compat_sigval_t _sigval; /* same as below */ - int _sys_private; /* not to be passed to user */ - } _timer; - - /* POSIX.1b signals */ - struct { - unsigned int _pid; /* sender's pid */ - unsigned int _uid; /* sender's uid */ - compat_sigval_t _sigval; - } _rt; - - /* SIGCHLD */ - struct { - unsigned int _pid; /* which child */ - unsigned int _uid; /* sender's uid */ - int _status; /* exit code */ - compat_clock_t _utime; - compat_clock_t _stime; - } _sigchld; - - /* SIGILL, SIGFPE, SIGSEGV, SIGBUS */ - struct { - unsigned int _addr; /* faulting insn/memory ref. */ - } _sigfault; - - /* SIGPOLL */ - struct { - int _band; /* POLL_IN, POLL_OUT, POLL_MSG */ - int _fd; - } _sigpoll; - } _sifields; -} compat_siginfo_t; - -int copy_siginfo_to_user32 (compat_siginfo_t __user *to, siginfo_t *from); -int copy_siginfo_from_user32 (siginfo_t *to, compat_siginfo_t __user *from); - -/* In a deft move of uber-hackery, we decide to carry the top half of all - * 64-bit registers in a non-portable, non-ABI, hidden structure. - * Userspace can read the hidden structure if it *wants* but is never - * guaranteed to be in the same place. Infact the uc_sigmask from the - * ucontext_t structure may push the hidden register file downards - */ -struct compat_regfile { - /* Upper half of all the 64-bit registers that were truncated - on a copy to a 32-bit userspace */ - compat_int_t rf_gr[32]; - compat_int_t rf_iasq[2]; - compat_int_t rf_iaoq[2]; - compat_int_t rf_sar; -}; - -#define COMPAT_SIGRETURN_TRAMP 4 -#define COMPAT_SIGRESTARTBLOCK_TRAMP 5 -#define COMPAT_TRAMP_SIZE (COMPAT_SIGRETURN_TRAMP + \ - COMPAT_SIGRESTARTBLOCK_TRAMP) - -struct compat_rt_sigframe { - /* XXX: Must match trampoline size in arch/parisc/kernel/signal.c - Secondary to that it must protect the ERESTART_RESTARTBLOCK - trampoline we left on the stack (we were bad and didn't - change sp so we could run really fast.) */ - compat_uint_t tramp[COMPAT_TRAMP_SIZE]; - compat_siginfo_t info; - struct compat_ucontext uc; - /* Hidden location of truncated registers, *must* be last. */ - struct compat_regfile regs; -}; - -/* - * The 32-bit ABI wants at least 48 bytes for a function call frame: - * 16 bytes for arg0-arg3, and 32 bytes for magic (the only part of - * which Linux/parisc uses is sp-20 for the saved return pointer...) - * Then, the stack pointer must be rounded to a cache line (64 bytes). - */ -#define SIGFRAME32 64 -#define FUNCTIONCALLFRAME32 48 -#define PARISC_RT_SIGFRAME_SIZE32 (((sizeof(struct compat_rt_sigframe) + FUNCTIONCALLFRAME32) + SIGFRAME32) & -SIGFRAME32) - void sigset_32to64(sigset_t *s64, compat_sigset_t *s32); void sigset_64to32(compat_sigset_t *s32, sigset_t *s64); int do_sigaltstack32 (const compat_stack_t __user *uss32, diff --git a/trunk/arch/parisc/kernel/syscall.S b/trunk/arch/parisc/kernel/syscall.S index af88afef41bd..d66163492890 100644 --- a/trunk/arch/parisc/kernel/syscall.S +++ b/trunk/arch/parisc/kernel/syscall.S @@ -650,8 +650,6 @@ end_linux_gateway_page: #define LWS_ENTRY(_name_) .word (lws_##_name_ - linux_gateway_page) #endif - .section .rodata,"a" - .align 4096 /* Light-weight-syscall table */ /* Start of lws table. */ diff --git a/trunk/arch/parisc/kernel/syscall_table.S b/trunk/arch/parisc/kernel/syscall_table.S index 51d2480627d1..32cbc0489324 100644 --- a/trunk/arch/parisc/kernel/syscall_table.S +++ b/trunk/arch/parisc/kernel/syscall_table.S @@ -374,24 +374,5 @@ ENTRY_SAME(keyctl) ENTRY_SAME(ioprio_set) ENTRY_SAME(ioprio_get) - ENTRY_SAME(inotify_init) - ENTRY_SAME(inotify_add_watch) /* 270 */ - ENTRY_SAME(inotify_rm_watch) - ENTRY_COMP(pselect6) - ENTRY_COMP(ppoll) - ENTRY_SAME(migrate_pages) - ENTRY_COMP(openat) /* 275 */ - ENTRY_SAME(mkdirat) - ENTRY_SAME(mknodat) - ENTRY_SAME(fchownat) - ENTRY_COMP(futimesat) - ENTRY_COMP(newfstatat) /* 280 */ - ENTRY_SAME(unlinkat) - ENTRY_SAME(renameat) - ENTRY_SAME(linkat) - ENTRY_SAME(symlinkat) - ENTRY_SAME(readlinkat) /* 285 */ - ENTRY_SAME(fchmodat) - ENTRY_SAME(faccessat) /* Nothing yet */ diff --git a/trunk/arch/parisc/kernel/traps.c b/trunk/arch/parisc/kernel/traps.c index ff200608c851..15914f0235a0 100644 --- a/trunk/arch/parisc/kernel/traps.c +++ b/trunk/arch/parisc/kernel/traps.c @@ -193,9 +193,10 @@ void show_stack(struct task_struct *task, unsigned long *s) HERE: asm volatile ("copy %%r30, %0" : "=r"(sp)); - r = kzalloc(sizeof(struct pt_regs), GFP_KERNEL); + r = (struct pt_regs *)kmalloc(sizeof(struct pt_regs), GFP_KERNEL); if (!r) return; + memset(r, 0, sizeof(struct pt_regs)); r->iaoq[0] = (unsigned long)&&HERE; r->gr[2] = (unsigned long)__builtin_return_address(0); r->gr[30] = sp; diff --git a/trunk/arch/parisc/math-emu/decode_exc.c b/trunk/arch/parisc/math-emu/decode_exc.c index 66c8a9f6a27e..f84f2586672b 100644 --- a/trunk/arch/parisc/math-emu/decode_exc.c +++ b/trunk/arch/parisc/math-emu/decode_exc.c @@ -337,7 +337,6 @@ decode_fpu(unsigned int Fpu_register[], unsigned int trap_counts[]) } break; case INVALIDEXCEPTION: - case OPC_2E_INVALIDEXCEPTION: update_trap_counts(Fpu_register, aflags, bflags, trap_counts); return SIGNALCODE(SIGFPE, FPE_FLTINV); case DIVISIONBYZEROEXCEPTION: diff --git a/trunk/arch/parisc/mm/init.c b/trunk/arch/parisc/mm/init.c index 7847ca13d6c2..720287d46e55 100644 --- a/trunk/arch/parisc/mm/init.c +++ b/trunk/arch/parisc/mm/init.c @@ -371,11 +371,17 @@ static void __init setup_bootmem(void) void free_initmem(void) { + /* FIXME: */ +#if 0 + printk(KERN_INFO "NOT FREEING INITMEM (%dk)\n", + (&__init_end - &__init_begin) >> 10); + return; +#else unsigned long addr; printk(KERN_INFO "Freeing unused kernel memory: "); -#ifdef CONFIG_DEBUG_KERNEL +#if 1 /* Attempt to catch anyone trying to execute code here * by filling the page with BRK insns. * @@ -408,20 +414,8 @@ void free_initmem(void) pdc_chassis_send_status(PDC_CHASSIS_DIRECT_BCOMPLETE); printk("%luk freed\n", (unsigned long)(&__init_end - &__init_begin) >> 10); -} - - -#ifdef CONFIG_DEBUG_RODATA -void mark_rodata_ro(void) -{ - extern char __start_rodata, __end_rodata; - /* rodata memory was already mapped with KERNEL_RO access rights by - pagetable_init() and map_pages(). No need to do additional stuff here */ - printk (KERN_INFO "Write protecting the kernel read-only data: %luk\n", - (unsigned long)(&__end_rodata - &__start_rodata) >> 10); -} #endif - +} /* * Just an arbitrary offset to serve as a "hole" between mapping areas @@ -483,6 +477,11 @@ void __init mem_init(void) } +int do_check_pgt_cache(int low, int high) +{ + return 0; +} + unsigned long *empty_zero_page __read_mostly; void show_mem(void) @@ -691,7 +690,7 @@ static void __init pagetable_init(void) #ifdef CONFIG_BLK_DEV_INITRD if (initrd_end && initrd_end > mem_limit) { - printk(KERN_INFO "initrd: mapping %08lx-%08lx\n", initrd_start, initrd_end); + printk("initrd: mapping %08lx-%08lx\n", initrd_start, initrd_end); map_pages(initrd_start, __pa(initrd_start), initrd_end - initrd_start, PAGE_KERNEL); } @@ -793,6 +792,8 @@ map_hpux_gateway_page(struct task_struct *tsk, struct mm_struct *mm) EXPORT_SYMBOL(map_hpux_gateway_page); #endif +extern void flush_tlb_all_local(void); + void __init paging_init(void) { int i; @@ -801,7 +802,7 @@ void __init paging_init(void) pagetable_init(); gateway_init(); flush_cache_all_local(); /* start with known state */ - flush_tlb_all_local(NULL); + flush_tlb_all_local(); for (i = 0; i < npmem_ranges; i++) { unsigned long zones_size[MAX_NR_ZONES] = { 0, 0, 0 }; @@ -992,7 +993,7 @@ void flush_tlb_all(void) do_recycle++; } spin_unlock(&sid_lock); - on_each_cpu(flush_tlb_all_local, NULL, 1, 1); + on_each_cpu((void (*)(void *))flush_tlb_all_local, NULL, 1, 1); if (do_recycle) { spin_lock(&sid_lock); recycle_sids(recycle_ndirty,recycle_dirty_array); diff --git a/trunk/arch/powerpc/Kconfig b/trunk/arch/powerpc/Kconfig index 80d114a3a837..df338c5cc910 100644 --- a/trunk/arch/powerpc/Kconfig +++ b/trunk/arch/powerpc/Kconfig @@ -83,12 +83,6 @@ config GENERIC_TBSYNC default y if PPC32 && SMP default n -config DEFAULT_UIMAGE - bool - help - Used to allow a board to specify it wants a uImage built by default - default n - menu "Processor support" choice prompt "Processor Type" diff --git a/trunk/arch/powerpc/Makefile b/trunk/arch/powerpc/Makefile index 5500ab55d042..44dd82b791d1 100644 --- a/trunk/arch/powerpc/Makefile +++ b/trunk/arch/powerpc/Makefile @@ -142,7 +142,6 @@ drivers-$(CONFIG_OPROFILE) += arch/powerpc/oprofile/ # Default to zImage, override when needed defaultimage-y := zImage defaultimage-$(CONFIG_PPC_ISERIES) := vmlinux -defaultimage-$(CONFIG_DEFAULT_UIMAGE) := uImage KBUILD_IMAGE := $(defaultimage-y) all: $(KBUILD_IMAGE) @@ -168,8 +167,6 @@ endef archclean: $(Q)$(MAKE) $(clean)=$(boot) - -archmrproper: $(Q)rm -rf arch/$(ARCH)/include archprepare: checkbin diff --git a/trunk/arch/powerpc/configs/cell_defconfig b/trunk/arch/powerpc/configs/cell_defconfig index 063b84f2cbea..b657f7e44762 100644 --- a/trunk/arch/powerpc/configs/cell_defconfig +++ b/trunk/arch/powerpc/configs/cell_defconfig @@ -533,7 +533,6 @@ CONFIG_MII=y # CONFIG_DL2K is not set CONFIG_E1000=m # CONFIG_E1000_NAPI is not set -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/powerpc/configs/g5_defconfig b/trunk/arch/powerpc/configs/g5_defconfig index d6fed3f56580..3c22ccb18519 100644 --- a/trunk/arch/powerpc/configs/g5_defconfig +++ b/trunk/arch/powerpc/configs/g5_defconfig @@ -675,7 +675,6 @@ CONFIG_ACENIC_OMIT_TIGON_I=y # CONFIG_DL2K is not set CONFIG_E1000=y # CONFIG_E1000_NAPI is not set -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/powerpc/configs/iseries_defconfig b/trunk/arch/powerpc/configs/iseries_defconfig index c775027947f9..751a622fb7a7 100644 --- a/trunk/arch/powerpc/configs/iseries_defconfig +++ b/trunk/arch/powerpc/configs/iseries_defconfig @@ -567,7 +567,6 @@ CONFIG_ACENIC=m # CONFIG_DL2K is not set CONFIG_E1000=m # CONFIG_E1000_NAPI is not set -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/powerpc/configs/maple_defconfig b/trunk/arch/powerpc/configs/maple_defconfig index 68194c03f6d1..07b6d3d23360 100644 --- a/trunk/arch/powerpc/configs/maple_defconfig +++ b/trunk/arch/powerpc/configs/maple_defconfig @@ -454,7 +454,6 @@ CONFIG_AMD8111_ETH=y # CONFIG_DL2K is not set CONFIG_E1000=y # CONFIG_E1000_NAPI is not set -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/powerpc/configs/ppc64_defconfig b/trunk/arch/powerpc/configs/ppc64_defconfig index 6f6c6bed1aa5..0b2b55a79c3c 100644 --- a/trunk/arch/powerpc/configs/ppc64_defconfig +++ b/trunk/arch/powerpc/configs/ppc64_defconfig @@ -724,7 +724,6 @@ CONFIG_ACENIC_OMIT_TIGON_I=y # CONFIG_DL2K is not set CONFIG_E1000=y # CONFIG_E1000_NAPI is not set -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/powerpc/configs/pseries_defconfig b/trunk/arch/powerpc/configs/pseries_defconfig index aa9893a1f6e8..a50ce0fa9243 100644 --- a/trunk/arch/powerpc/configs/pseries_defconfig +++ b/trunk/arch/powerpc/configs/pseries_defconfig @@ -671,7 +671,6 @@ CONFIG_ACENIC_OMIT_TIGON_I=y # CONFIG_DL2K is not set CONFIG_E1000=y # CONFIG_E1000_NAPI is not set -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/powerpc/kernel/Makefile b/trunk/arch/powerpc/kernel/Makefile index 80e9fe2632b8..c287980b7e65 100644 --- a/trunk/arch/powerpc/kernel/Makefile +++ b/trunk/arch/powerpc/kernel/Makefile @@ -12,10 +12,10 @@ endif obj-y := semaphore.o cputable.o ptrace.o syscalls.o \ irq.o align.o signal_32.o pmc.o vdso.o \ - init_task.o process.o systbl.o + init_task.o process.o obj-y += vdso32/ obj-$(CONFIG_PPC64) += setup_64.o binfmt_elf32.o sys_ppc32.o \ - signal_64.o ptrace32.o \ + signal_64.o ptrace32.o systbl.o \ paca.o cpu_setup_power4.o \ firmware.o sysfs.o idle_64.o obj-$(CONFIG_PPC64) += vdso64/ @@ -46,7 +46,7 @@ extra-$(CONFIG_8xx) := head_8xx.o extra-y += vmlinux.lds obj-y += time.o prom.o traps.o setup-common.o udbg.o -obj-$(CONFIG_PPC32) += entry_32.o setup_32.o misc_32.o +obj-$(CONFIG_PPC32) += entry_32.o setup_32.o misc_32.o systbl.o obj-$(CONFIG_PPC64) += misc_64.o dma_64.o iommu.o obj-$(CONFIG_PPC_MULTIPLATFORM) += prom_init.o obj-$(CONFIG_MODULES) += ppc_ksyms.o diff --git a/trunk/arch/powerpc/kernel/entry_32.S b/trunk/arch/powerpc/kernel/entry_32.S index f20a67261ec7..d8da2a35c0a4 100644 --- a/trunk/arch/powerpc/kernel/entry_32.S +++ b/trunk/arch/powerpc/kernel/entry_32.S @@ -227,7 +227,7 @@ ret_from_syscall: MTMSRD(r10) lwz r9,TI_FLAGS(r12) li r8,-_LAST_ERRNO - andi. r0,r9,(_TIF_SYSCALL_T_OR_A|_TIF_SIGPENDING|_TIF_NEED_RESCHED|_TIF_RESTOREALL|_TIF_RESTORE_SIGMASK) + andi. r0,r9,(_TIF_SYSCALL_T_OR_A|_TIF_SIGPENDING|_TIF_NEED_RESCHED|_TIF_RESTOREALL) bne- syscall_exit_work cmplw 0,r3,r8 blt+ syscall_exit_cont @@ -357,7 +357,7 @@ save_user_nvgprs_cont: lwz r5,_MSR(r1) andi. r5,r5,MSR_PR beq ret_from_except - andi. r0,r9,_TIF_SIGPENDING|_TIF_RESTORE_SIGMASK + andi. r0,r9,_TIF_SIGPENDING beq ret_from_except b do_user_signal 8: @@ -683,7 +683,7 @@ user_exc_return: /* r10 contains MSR_KERNEL here */ /* Check current_thread_info()->flags */ rlwinm r9,r1,0,0,(31-THREAD_SHIFT) lwz r9,TI_FLAGS(r9) - andi. r0,r9,(_TIF_SIGPENDING|_TIF_NEED_RESCHED|_TIF_RESTOREALL|_TIF_RESTORE_SIGMASK) + andi. r0,r9,(_TIF_SIGPENDING|_TIF_NEED_RESCHED|_TIF_RESTOREALL) bne do_work restore_user: @@ -917,7 +917,7 @@ recheck: lwz r9,TI_FLAGS(r9) andi. r0,r9,_TIF_NEED_RESCHED bne- do_resched - andi. r0,r9,_TIF_SIGPENDING|_TIF_RESTORE_SIGMASK + andi. r0,r9,_TIF_SIGPENDING beq restore_user do_user_signal: /* r10 contains MSR_KERNEL here */ ori r10,r10,MSR_EE diff --git a/trunk/arch/powerpc/kernel/entry_64.S b/trunk/arch/powerpc/kernel/entry_64.S index 388f861b8ed1..542036318866 100644 --- a/trunk/arch/powerpc/kernel/entry_64.S +++ b/trunk/arch/powerpc/kernel/entry_64.S @@ -160,7 +160,7 @@ syscall_exit: mtmsrd r10,1 ld r9,TI_FLAGS(r12) li r11,-_LAST_ERRNO - andi. r0,r9,(_TIF_SYSCALL_T_OR_A|_TIF_SINGLESTEP|_TIF_SIGPENDING|_TIF_NEED_RESCHED|_TIF_RESTOREALL|_TIF_SAVE_NVGPRS|_TIF_NOERROR|_TIF_RESTORE_SIGMASK) + andi. r0,r9,(_TIF_SYSCALL_T_OR_A|_TIF_SINGLESTEP|_TIF_SIGPENDING|_TIF_NEED_RESCHED|_TIF_RESTOREALL|_TIF_SAVE_NVGPRS|_TIF_NOERROR) bne- syscall_exit_work cmpld r3,r11 ld r5,_CCR(r1) diff --git a/trunk/arch/powerpc/kernel/fpu.S b/trunk/arch/powerpc/kernel/fpu.S index 340730fb8c91..e4362dfa37fb 100644 --- a/trunk/arch/powerpc/kernel/fpu.S +++ b/trunk/arch/powerpc/kernel/fpu.S @@ -66,7 +66,7 @@ _GLOBAL(load_up_fpu) #else ld r4,PACACURRENT(r13) addi r5,r4,THREAD /* Get THREAD */ - lwz r4,THREAD_FPEXC_MODE(r5) + ld r4,THREAD_FPEXC_MODE(r5) ori r12,r12,MSR_FP or r12,r12,r4 std r12,_MSR(r1) diff --git a/trunk/arch/powerpc/kernel/head_64.S b/trunk/arch/powerpc/kernel/head_64.S index 415659629394..308268466342 100644 --- a/trunk/arch/powerpc/kernel/head_64.S +++ b/trunk/arch/powerpc/kernel/head_64.S @@ -749,12 +749,11 @@ iSeries_secondary_smp_loop: .globl decrementer_iSeries_masked decrementer_iSeries_masked: - /* We may not have a valid TOC pointer in here. */ li r11,1 ld r12,PACALPPACAPTR(r13) stb r11,LPPACADECRINT(r12) - LOAD_REG_IMMEDIATE(r12, tb_ticks_per_jiffy) - lwz r12,0(r12) + LOAD_REG_ADDRBASE(r12,tb_ticks_per_jiffy) + lwz r12,ADDROFF(tb_ticks_per_jiffy)(r12) mtspr SPRN_DEC,r12 /* fall through */ diff --git a/trunk/arch/powerpc/kernel/iommu.c b/trunk/arch/powerpc/kernel/iommu.c index 946f3219fd29..4d9b4388918b 100644 --- a/trunk/arch/powerpc/kernel/iommu.c +++ b/trunk/arch/powerpc/kernel/iommu.c @@ -334,6 +334,9 @@ int iommu_map_sg(struct device *dev, struct iommu_table *tbl, spin_unlock_irqrestore(&(tbl->it_lock), flags); + /* Make sure updates are seen by hardware */ + mb(); + DBG("mapped %d elements:\n", outcount); /* For the sake of iommu_unmap_sg, we clear out the length in the @@ -344,10 +347,6 @@ int iommu_map_sg(struct device *dev, struct iommu_table *tbl, outs->dma_address = DMA_ERROR_CODE; outs->dma_length = 0; } - - /* Make sure updates are seen by hardware */ - mb(); - return outcount; failure: @@ -359,8 +358,6 @@ int iommu_map_sg(struct device *dev, struct iommu_table *tbl, npages = (PAGE_ALIGN(s->dma_address + s->dma_length) - vaddr) >> PAGE_SHIFT; __iommu_free(tbl, vaddr, npages); - s->dma_address = DMA_ERROR_CODE; - s->dma_length = 0; } } spin_unlock_irqrestore(&(tbl->it_lock), flags); diff --git a/trunk/arch/powerpc/kernel/legacy_serial.c b/trunk/arch/powerpc/kernel/legacy_serial.c index c7a799a09516..f970ace208d3 100644 --- a/trunk/arch/powerpc/kernel/legacy_serial.c +++ b/trunk/arch/powerpc/kernel/legacy_serial.c @@ -134,6 +134,7 @@ static int __init add_legacy_soc_port(struct device_node *np, return add_legacy_port(np, -1, UPIO_MEM, addr, addr, NO_IRQ, flags); } +#ifdef CONFIG_ISA static int __init add_legacy_isa_port(struct device_node *np, struct device_node *isa_brg) { @@ -167,6 +168,7 @@ static int __init add_legacy_isa_port(struct device_node *np, return add_legacy_port(np, index, UPIO_PORT, reg[1], taddr, NO_IRQ, UPF_BOOT_AUTOCONF); } +#endif #ifdef CONFIG_PCI static int __init add_legacy_pci_port(struct device_node *np, @@ -274,6 +276,7 @@ void __init find_legacy_serial_ports(void) of_node_put(soc); } +#ifdef CONFIG_ISA /* First fill our array with ISA ports */ for (np = NULL; (np = of_find_node_by_type(np, "serial"));) { struct device_node *isa = of_get_parent(np); @@ -284,6 +287,7 @@ void __init find_legacy_serial_ports(void) } of_node_put(isa); } +#endif #ifdef CONFIG_PCI /* Next, try to locate PCI ports */ diff --git a/trunk/arch/powerpc/kernel/prom.c b/trunk/arch/powerpc/kernel/prom.c index 294832a7e0a6..d50c8df0183e 100644 --- a/trunk/arch/powerpc/kernel/prom.c +++ b/trunk/arch/powerpc/kernel/prom.c @@ -491,12 +491,7 @@ void __init finish_device_tree(void) size = 16; finish_node(allnodes, &size, 1); size -= 16; - - if (0 == size) - end = start = 0; - else - end = start = (unsigned long)__va(lmb_alloc(size, 128)); - + end = start = (unsigned long) __va(lmb_alloc(size, 128)); finish_node(allnodes, &end, 0); BUG_ON(end != start + size); @@ -1403,8 +1398,8 @@ struct device_node *of_find_node_by_name(struct device_node *from, read_lock(&devtree_lock); np = from ? from->allnext : allnodes; - for (; np != NULL; np = np->allnext) - if (np->name != NULL && strcasecmp(np->name, name) == 0 + for (; np != 0; np = np->allnext) + if (np->name != 0 && strcasecmp(np->name, name) == 0 && of_node_get(np)) break; if (from) @@ -1922,30 +1917,3 @@ int prom_update_property(struct device_node *np, return 0; } - -#ifdef CONFIG_KEXEC -/* We may have allocated the flat device tree inside the crash kernel region - * in prom_init. If so we need to move it out into regular memory. */ -void kdump_move_device_tree(void) -{ - unsigned long start, end; - struct boot_param_header *new; - - start = __pa((unsigned long)initial_boot_params); - end = start + initial_boot_params->totalsize; - - if (end < crashk_res.start || start > crashk_res.end) - return; - - new = (struct boot_param_header*) - __va(lmb_alloc(initial_boot_params->totalsize, PAGE_SIZE)); - - memcpy(new, initial_boot_params, initial_boot_params->totalsize); - - initial_boot_params = new; - - DBG("Flat device tree blob moved to %p\n", initial_boot_params); - - /* XXX should we unreserve the old DT? */ -} -#endif /* CONFIG_KEXEC */ diff --git a/trunk/arch/powerpc/kernel/prom_init.c b/trunk/arch/powerpc/kernel/prom_init.c index ec7153f4d47c..7881ec96ef11 100644 --- a/trunk/arch/powerpc/kernel/prom_init.c +++ b/trunk/arch/powerpc/kernel/prom_init.c @@ -2098,10 +2098,6 @@ unsigned long __init prom_init(unsigned long r3, unsigned long r4, */ prom_init_stdout(); - /* Bail if this is a kdump kernel. */ - if (PHYSICAL_START > 0) - prom_panic("Error: You can't boot a kdump kernel from OF!\n"); - /* * Check for an initrd */ diff --git a/trunk/arch/powerpc/kernel/prom_parse.c b/trunk/arch/powerpc/kernel/prom_parse.c index 3934c227549b..a8099c806150 100644 --- a/trunk/arch/powerpc/kernel/prom_parse.c +++ b/trunk/arch/powerpc/kernel/prom_parse.c @@ -465,10 +465,8 @@ u32 *of_get_pci_address(struct device_node *dev, int bar_no, u64 *size, if (parent == NULL) return NULL; bus = of_match_bus(parent); - if (strcmp(bus->name, "pci")) { - of_node_put(parent); + if (strcmp(bus->name, "pci")) return NULL; - } bus->count_cells(dev, &na, &ns); of_node_put(parent); if (!OF_CHECK_COUNTS(na, ns)) diff --git a/trunk/arch/powerpc/kernel/rtas.c b/trunk/arch/powerpc/kernel/rtas.c index b5b2add7ad1e..7fe4a5c944c9 100644 --- a/trunk/arch/powerpc/kernel/rtas.c +++ b/trunk/arch/powerpc/kernel/rtas.c @@ -22,7 +22,6 @@ #include #include -#include #include #include #include @@ -566,7 +565,6 @@ static int ibm_suspend_me_token = RTAS_UNKNOWN_SERVICE; #ifdef CONFIG_PPC_PSERIES static void rtas_percpu_suspend_me(void *info) { - int i; long rc; long flags; struct rtas_suspend_me_data *data = @@ -589,16 +587,18 @@ static void rtas_percpu_suspend_me(void *info) if (rc == H_Continue) { data->waiting = 0; - data->args->args[data->args->nargs] = - rtas_call(ibm_suspend_me_token, 0, 1, NULL); - for_each_cpu(i) - plpar_hcall_norets(H_PROD,i); + rtas_call(ibm_suspend_me_token, 0, 1, + data->args->args); } else { data->waiting = -EBUSY; printk(KERN_ERR "Error on H_Join hypervisor call\n"); } out: + /* before we restore interrupts, make sure we don't + * generate a spurious soft lockup errors + */ + touch_softlockup_watchdog(); local_irq_restore(flags); return; } diff --git a/trunk/arch/powerpc/kernel/rtas_flash.c b/trunk/arch/powerpc/kernel/rtas_flash.c index aaf384c3f04a..50500093c97f 100644 --- a/trunk/arch/powerpc/kernel/rtas_flash.c +++ b/trunk/arch/powerpc/kernel/rtas_flash.c @@ -672,7 +672,8 @@ static void rtas_flash_firmware(int reboot_type) static void remove_flash_pde(struct proc_dir_entry *dp) { if (dp) { - kfree(dp->data); + if (dp->data != NULL) + kfree(dp->data); dp->owner = NULL; remove_proc_entry(dp->name, dp->parent); } diff --git a/trunk/arch/powerpc/kernel/setup_64.c b/trunk/arch/powerpc/kernel/setup_64.c index a717dff695ef..e29b275e09e0 100644 --- a/trunk/arch/powerpc/kernel/setup_64.c +++ b/trunk/arch/powerpc/kernel/setup_64.c @@ -398,9 +398,6 @@ void __init setup_system(void) { DBG(" -> setup_system()\n"); -#ifdef CONFIG_KEXEC - kdump_move_device_tree(); -#endif /* * Unflatten the device-tree passed by prom_init or kexec */ diff --git a/trunk/arch/powerpc/kernel/signal_32.c b/trunk/arch/powerpc/kernel/signal_32.c index bd837b5dbf06..177bba78fb0b 100644 --- a/trunk/arch/powerpc/kernel/signal_32.c +++ b/trunk/arch/powerpc/kernel/signal_32.c @@ -142,7 +142,11 @@ static inline int get_old_sigaction(struct k_sigaction *new_ka, return 0; } -#define to_user_ptr(p) ptr_to_compat(p) +static inline compat_uptr_t to_user_ptr(void *kp) +{ + return (compat_uptr_t)(u64)kp; +} + #define from_user_ptr(p) compat_ptr(p) static inline int save_general_regs(struct pt_regs *regs, @@ -209,8 +213,8 @@ static inline int get_old_sigaction(struct k_sigaction *new_ka, return 0; } -#define to_user_ptr(p) ((unsigned long)(p)) -#define from_user_ptr(p) ((void __user *)(p)) +#define to_user_ptr(p) (p) +#define from_user_ptr(p) (p) static inline int save_general_regs(struct pt_regs *regs, struct mcontext __user *frame) @@ -248,19 +252,67 @@ int do_signal(sigset_t *oldset, struct pt_regs *regs); /* * Atomically swap in the new signal mask, and wait for a signal. */ -long sys_sigsuspend(old_sigset_t mask) +long sys_sigsuspend(old_sigset_t mask, int p2, int p3, int p4, int p6, int p7, + struct pt_regs *regs) { + sigset_t saveset; + mask &= _BLOCKABLE; spin_lock_irq(¤t->sighand->siglock); - current->saved_sigmask = current->blocked; + saveset = current->blocked; siginitset(¤t->blocked, mask); recalc_sigpending(); spin_unlock_irq(¤t->sighand->siglock); - current->state = TASK_INTERRUPTIBLE; - schedule(); - set_thread_flag(TIF_RESTORE_SIGMASK); - return -ERESTARTNOHAND; + regs->result = -EINTR; + regs->gpr[3] = EINTR; + regs->ccr |= 0x10000000; + while (1) { + current->state = TASK_INTERRUPTIBLE; + schedule(); + if (do_signal(&saveset, regs)) { + set_thread_flag(TIF_RESTOREALL); + return 0; + } + } +} + +long sys_rt_sigsuspend( +#ifdef CONFIG_PPC64 + compat_sigset_t __user *unewset, +#else + sigset_t __user *unewset, +#endif + size_t sigsetsize, int p3, int p4, + int p6, int p7, struct pt_regs *regs) +{ + sigset_t saveset, newset; + + /* XXX: Don't preclude handling different sized sigset_t's. */ + if (sigsetsize != sizeof(sigset_t)) + return -EINVAL; + + if (get_sigset_t(&newset, unewset)) + return -EFAULT; + sigdelsetmask(&newset, ~_BLOCKABLE); + + spin_lock_irq(¤t->sighand->siglock); + saveset = current->blocked; + current->blocked = newset; + recalc_sigpending(); + spin_unlock_irq(¤t->sighand->siglock); + + regs->result = -EINTR; + regs->gpr[3] = EINTR; + regs->ccr |= 0x10000000; + while (1) { + current->state = TASK_INTERRUPTIBLE; + schedule(); + if (do_signal(&saveset, regs)) { + set_thread_flag(TIF_RESTOREALL); + return 0; + } + } } #ifdef CONFIG_PPC32 @@ -522,7 +574,7 @@ long compat_sys_rt_sigaction(int sig, const struct sigaction32 __user *act, ret = do_sigaction(sig, act ? &new_ka : NULL, oact ? &old_ka : NULL); if (!ret && oact) { - ret = put_user(to_user_ptr(old_ka.sa.sa_handler), &oact->sa_handler); + ret = put_user((long)old_ka.sa.sa_handler, &oact->sa_handler); ret |= put_sigset_t(&oact->sa_mask, &old_ka.sa.sa_mask); ret |= __put_user(old_ka.sa.sa_flags, &oact->sa_flags); } @@ -671,8 +723,8 @@ long compat_sys_rt_sigqueueinfo(u32 pid, u32 sig, compat_siginfo_t __user *uinfo int compat_sys_sigaltstack(u32 __new, u32 __old, int r5, int r6, int r7, int r8, struct pt_regs *regs) { - stack_32_t __user * newstack = compat_ptr(__new); - stack_32_t __user * oldstack = compat_ptr(__old); + stack_32_t __user * newstack = (stack_32_t __user *)(long) __new; + stack_32_t __user * oldstack = (stack_32_t __user *)(long) __old; stack_t uss, uoss; int ret; mm_segment_t old_fs; @@ -704,7 +756,7 @@ int compat_sys_sigaltstack(u32 __new, u32 __old, int r5, set_fs(old_fs); /* Copy the stack information to the user output buffer */ if (!ret && oldstack && - (put_user(ptr_to_compat(uoss.ss_sp), &oldstack->ss_sp) || + (put_user((long)uoss.ss_sp, &oldstack->ss_sp) || __put_user(uoss.ss_flags, &oldstack->ss_flags) || __put_user(uoss.ss_size, &oldstack->ss_size))) return -EFAULT; @@ -1122,7 +1174,7 @@ int do_signal(sigset_t *oldset, struct pt_regs *regs) { siginfo_t info; struct k_sigaction ka; - unsigned int newsp; + unsigned int frame, newsp; int signr, ret; #ifdef CONFIG_PPC32 @@ -1133,11 +1185,11 @@ int do_signal(sigset_t *oldset, struct pt_regs *regs) } #endif - if (test_thread_flag(TIF_RESTORE_SIGMASK)) - oldset = ¤t->saved_sigmask; - else if (!oldset) + if (!oldset) oldset = ¤t->blocked; + newsp = frame = 0; + signr = get_signal_to_deliver(&info, &ka, regs, NULL); #ifdef CONFIG_PPC32 no_signal: @@ -1167,14 +1219,8 @@ int do_signal(sigset_t *oldset, struct pt_regs *regs) } } - if (signr == 0) { - /* No signal to deliver -- put the saved sigmask back */ - if (test_thread_flag(TIF_RESTORE_SIGMASK)) { - clear_thread_flag(TIF_RESTORE_SIGMASK); - sigprocmask(SIG_SETMASK, ¤t->saved_sigmask, NULL); - } + if (signr == 0) return 0; /* no signals delivered */ - } if ((ka.sa.sa_flags & SA_ONSTACK) && current->sas_ss_size && !on_sig_stack(regs->gpr[1])) @@ -1207,10 +1253,6 @@ int do_signal(sigset_t *oldset, struct pt_regs *regs) sigaddset(¤t->blocked, signr); recalc_sigpending(); spin_unlock_irq(¤t->sighand->siglock); - /* A signal was successfully delivered; the saved sigmask is in - its frame, and we can clear the TIF_RESTORE_SIGMASK flag */ - if (test_thread_flag(TIF_RESTORE_SIGMASK)) - clear_thread_flag(TIF_RESTORE_SIGMASK); } return ret; diff --git a/trunk/arch/powerpc/kernel/signal_64.c b/trunk/arch/powerpc/kernel/signal_64.c index 497a5d3df359..7b9d999e2115 100644 --- a/trunk/arch/powerpc/kernel/signal_64.c +++ b/trunk/arch/powerpc/kernel/signal_64.c @@ -60,13 +60,49 @@ struct rt_sigframe { struct ucontext uc; unsigned long _unused[2]; unsigned int tramp[TRAMP_SIZE]; - struct siginfo __user *pinfo; - void __user *puc; + struct siginfo *pinfo; + void *puc; struct siginfo info; /* 64 bit ABI allows for 288 bytes below sp before decrementing it. */ char abigap[288]; } __attribute__ ((aligned (16))); + +/* + * Atomically swap in the new signal mask, and wait for a signal. + */ +long sys_rt_sigsuspend(sigset_t __user *unewset, size_t sigsetsize, int p3, int p4, + int p6, int p7, struct pt_regs *regs) +{ + sigset_t saveset, newset; + + /* XXX: Don't preclude handling different sized sigset_t's. */ + if (sigsetsize != sizeof(sigset_t)) + return -EINVAL; + + if (copy_from_user(&newset, unewset, sizeof(newset))) + return -EFAULT; + sigdelsetmask(&newset, ~_BLOCKABLE); + + spin_lock_irq(¤t->sighand->siglock); + saveset = current->blocked; + current->blocked = newset; + recalc_sigpending(); + spin_unlock_irq(¤t->sighand->siglock); + + regs->result = -EINTR; + regs->gpr[3] = EINTR; + regs->ccr |= 0x10000000; + while (1) { + current->state = TASK_INTERRUPTIBLE; + schedule(); + if (do_signal(&saveset, regs)) { + set_thread_flag(TIF_RESTOREALL); + return 0; + } + } +} + long sys_sigaltstack(const stack_t __user *uss, stack_t __user *uoss, unsigned long r5, unsigned long r6, unsigned long r7, unsigned long r8, struct pt_regs *regs) @@ -520,15 +556,11 @@ int do_signal(sigset_t *oldset, struct pt_regs *regs) if (test_thread_flag(TIF_32BIT)) return do_signal32(oldset, regs); - if (test_thread_flag(TIF_RESTORE_SIGMASK)) - oldset = ¤t->saved_sigmask; - else if (!oldset) + if (!oldset) oldset = ¤t->blocked; signr = get_signal_to_deliver(&info, &ka, regs, NULL); if (signr > 0) { - int ret; - /* Whee! Actually deliver the signal. */ if (TRAP(regs) == 0x0C00) syscall_restart(regs, &ka); @@ -541,14 +573,7 @@ int do_signal(sigset_t *oldset, struct pt_regs *regs) if (current->thread.dabr) set_dabr(current->thread.dabr); - ret = handle_signal(signr, &ka, &info, oldset, regs); - - /* If a signal was successfully delivered, the saved sigmask is in - its frame, and we can clear the TIF_RESTORE_SIGMASK flag */ - if (ret && test_thread_flag(TIF_RESTORE_SIGMASK)) - clear_thread_flag(TIF_RESTORE_SIGMASK); - - return ret; + return handle_signal(signr, &ka, &info, oldset, regs); } if (TRAP(regs) == 0x0C00) { /* System Call! */ @@ -564,11 +589,6 @@ int do_signal(sigset_t *oldset, struct pt_regs *regs) regs->result = 0; } } - /* No signal to deliver -- put the saved sigmask back */ - if (test_thread_flag(TIF_RESTORE_SIGMASK)) { - clear_thread_flag(TIF_RESTORE_SIGMASK); - sigprocmask(SIG_SETMASK, ¤t->saved_sigmask, NULL); - } return 0; } diff --git a/trunk/arch/powerpc/kernel/smp.c b/trunk/arch/powerpc/kernel/smp.c index 13595a64f013..c8458c531b25 100644 --- a/trunk/arch/powerpc/kernel/smp.c +++ b/trunk/arch/powerpc/kernel/smp.c @@ -540,9 +540,6 @@ int __devinit start_secondary(void *unused) if (smp_ops->take_timebase) smp_ops->take_timebase(); - if (system_state > SYSTEM_BOOTING) - per_cpu(last_jiffy, cpu) = get_tb(); - spin_lock(&call_lock); cpu_set(cpu, cpu_online_map); spin_unlock(&call_lock); diff --git a/trunk/arch/powerpc/kernel/systbl.S b/trunk/arch/powerpc/kernel/systbl.S index 8a9f994ed917..68013179a503 100644 --- a/trunk/arch/powerpc/kernel/systbl.S +++ b/trunk/arch/powerpc/kernel/systbl.S @@ -36,6 +36,8 @@ #ifdef CONFIG_PPC64 #define sys_sigpending sys_ni_syscall #define sys_old_getrlimit sys_ni_syscall +#else +#define ppc_rtas sys_ni_syscall #endif _GLOBAL(sys_call_table) @@ -319,6 +321,3 @@ SYSCALL(inotify_add_watch) SYSCALL(inotify_rm_watch) SYSCALL(spu_run) SYSCALL(spu_create) -COMPAT_SYS(pselect6) -COMPAT_SYS(ppoll) -SYSCALL(unshare) diff --git a/trunk/arch/powerpc/kernel/time.c b/trunk/arch/powerpc/kernel/time.c index 1886045a2fd8..c4a294d657b9 100644 --- a/trunk/arch/powerpc/kernel/time.c +++ b/trunk/arch/powerpc/kernel/time.c @@ -612,10 +612,10 @@ void __init generic_calibrate_decr(void) ppc_tb_freq = DEFAULT_TB_FREQ; /* hardcoded default */ node_found = 0; - if (cpu) { + if (cpu != 0) { fp = (unsigned int *)get_property(cpu, "timebase-frequency", NULL); - if (fp) { + if (fp != 0) { node_found = 1; ppc_tb_freq = *fp; } @@ -626,10 +626,10 @@ void __init generic_calibrate_decr(void) ppc_proc_freq = DEFAULT_PROC_FREQ; node_found = 0; - if (cpu) { + if (cpu != 0) { fp = (unsigned int *)get_property(cpu, "clock-frequency", NULL); - if (fp) { + if (fp != 0) { node_found = 1; ppc_proc_freq = *fp; } diff --git a/trunk/arch/powerpc/kernel/udbg_16550.c b/trunk/arch/powerpc/kernel/udbg_16550.c index 5d29dcca523c..2da65a9c93f6 100644 --- a/trunk/arch/powerpc/kernel/udbg_16550.c +++ b/trunk/arch/powerpc/kernel/udbg_16550.c @@ -144,7 +144,7 @@ unsigned int udbg_probe_uart_speed(void __iomem *comport, unsigned int clock) } #ifdef CONFIG_PPC_MAPLE -void udbg_maple_real_putc(char c) +void udbg_maple_real_putc(unsigned char c) { if (udbg_comport) { while ((real_readb(&udbg_comport->lsr) & LSR_THRE) == 0) diff --git a/trunk/arch/powerpc/mm/lmb.c b/trunk/arch/powerpc/mm/lmb.c index bbe3eac918e8..9584608fd768 100644 --- a/trunk/arch/powerpc/mm/lmb.c +++ b/trunk/arch/powerpc/mm/lmb.c @@ -197,8 +197,6 @@ long __init lmb_reserve(unsigned long base, unsigned long size) { struct lmb_region *_rgn = &(lmb.reserved); - BUG_ON(0 == size); - return lmb_add_region(_rgn, base, size); } @@ -229,8 +227,6 @@ unsigned long __init lmb_alloc_base(unsigned long size, unsigned long align, long i, j; unsigned long base = 0; - BUG_ON(0 == size); - #ifdef CONFIG_PPC32 /* On 32-bit, make sure we allocate lowmem */ if (max_addr == LMB_ALLOC_ANYWHERE) diff --git a/trunk/arch/powerpc/mm/mem.c b/trunk/arch/powerpc/mm/mem.c index 550517c2dd42..15aac0d78dfa 100644 --- a/trunk/arch/powerpc/mm/mem.c +++ b/trunk/arch/powerpc/mm/mem.c @@ -435,12 +435,17 @@ void clear_user_page(void *page, unsigned long vaddr, struct page *pg) { clear_page(page); + if (cpu_has_feature(CPU_FTR_COHERENT_ICACHE)) + return; /* * We shouldnt have to do this, but some versions of glibc * require it (ld.so assumes zero filled pages are icache clean) * - Anton */ - flush_dcache_page(pg); + + /* avoid an atomic op if possible */ + if (test_bit(PG_arch_1, &pg->flags)) + clear_bit(PG_arch_1, &pg->flags); } EXPORT_SYMBOL(clear_user_page); @@ -464,7 +469,12 @@ void copy_user_page(void *vto, void *vfrom, unsigned long vaddr, return; #endif - flush_dcache_page(pg); + if (cpu_has_feature(CPU_FTR_COHERENT_ICACHE)) + return; + + /* avoid an atomic op if possible */ + if (test_bit(PG_arch_1, &pg->flags)) + clear_bit(PG_arch_1, &pg->flags); } void flush_icache_user_range(struct vm_area_struct *vma, struct page *page, diff --git a/trunk/arch/powerpc/platforms/cell/Makefile b/trunk/arch/powerpc/platforms/cell/Makefile index 3b998a393e3f..16031b565be4 100644 --- a/trunk/arch/powerpc/platforms/cell/Makefile +++ b/trunk/arch/powerpc/platforms/cell/Makefile @@ -2,7 +2,7 @@ obj-y += interrupt.o iommu.o setup.o spider-pic.o obj-y += pervasive.o obj-$(CONFIG_SMP) += smp.o -obj-$(CONFIG_SPU_FS) += spu-base.o spufs/ +obj-$(CONFIG_SPU_FS) += spufs/ spu-base.o spu-base-y += spu_base.o spu_priv1.o diff --git a/trunk/arch/powerpc/platforms/chrp/chrp.h b/trunk/arch/powerpc/platforms/chrp/chrp.h index 814f54742e0f..3a2057fa314a 100644 --- a/trunk/arch/powerpc/platforms/chrp/chrp.h +++ b/trunk/arch/powerpc/platforms/chrp/chrp.h @@ -5,6 +5,7 @@ extern void chrp_nvram_init(void); extern void chrp_get_rtc_time(struct rtc_time *); extern int chrp_set_rtc_time(struct rtc_time *); +extern void chrp_calibrate_decr(void); extern long chrp_time_init(void); extern void chrp_find_bridges(void); diff --git a/trunk/arch/powerpc/platforms/chrp/pci.c b/trunk/arch/powerpc/platforms/chrp/pci.c index 8ef279ad36ad..00c52f27ef4f 100644 --- a/trunk/arch/powerpc/platforms/chrp/pci.c +++ b/trunk/arch/powerpc/platforms/chrp/pci.c @@ -204,11 +204,9 @@ static void __init setup_peg2(struct pci_controller *hose, struct device_node *d struct device_node *root = find_path_device("/"); struct device_node *rtas; - of_node_get(root); rtas = of_find_node_by_name (root, "rtas"); if (rtas) { hose->ops = &rtas_pci_ops; - of_node_put(rtas); } else { printk ("RTAS supporting Pegasos OF not found, please upgrade" " your firmware\n"); diff --git a/trunk/arch/powerpc/platforms/chrp/setup.c b/trunk/arch/powerpc/platforms/chrp/setup.c index e1fadbf49150..2dc87aa5962f 100644 --- a/trunk/arch/powerpc/platforms/chrp/setup.c +++ b/trunk/arch/powerpc/platforms/chrp/setup.c @@ -506,7 +506,7 @@ void __init chrp_init(void) ppc_md.halt = rtas_halt; ppc_md.time_init = chrp_time_init; - ppc_md.calibrate_decr = generic_calibrate_decr; + ppc_md.calibrate_decr = chrp_calibrate_decr; /* this may get overridden with rtas routines later... */ ppc_md.set_rtc_time = chrp_set_rtc_time; diff --git a/trunk/arch/powerpc/platforms/chrp/time.c b/trunk/arch/powerpc/platforms/chrp/time.c index 78df2e7ca88a..36a0f97bb7b1 100644 --- a/trunk/arch/powerpc/platforms/chrp/time.c +++ b/trunk/arch/powerpc/platforms/chrp/time.c @@ -167,3 +167,24 @@ void chrp_get_rtc_time(struct rtc_time *tm) tm->tm_mon = mon; tm->tm_year = year; } + + +void __init chrp_calibrate_decr(void) +{ + struct device_node *cpu; + unsigned int freq, *fp; + + /* + * The cpu node should have a timebase-frequency property + * to tell us the rate at which the decrementer counts. + */ + freq = 16666000; /* hardcoded default */ + cpu = find_type_devices("cpu"); + if (cpu != 0) { + fp = (unsigned int *) + get_property(cpu, "timebase-frequency", NULL); + if (fp != 0) + freq = *fp; + } + ppc_tb_freq = freq; +} diff --git a/trunk/arch/powerpc/platforms/powermac/low_i2c.c b/trunk/arch/powerpc/platforms/powermac/low_i2c.c index 87eb6bb7f0e7..535c802b369f 100644 --- a/trunk/arch/powerpc/platforms/powermac/low_i2c.c +++ b/trunk/arch/powerpc/platforms/powermac/low_i2c.c @@ -1052,7 +1052,8 @@ struct pmac_i2c_bus *pmac_i2c_adapter_to_bus(struct i2c_adapter *adapter) } EXPORT_SYMBOL_GPL(pmac_i2c_adapter_to_bus); -int pmac_i2c_match_adapter(struct device_node *dev, struct i2c_adapter *adapter) +extern int pmac_i2c_match_adapter(struct device_node *dev, + struct i2c_adapter *adapter) { struct pmac_i2c_bus *bus = pmac_i2c_find_bus(dev); diff --git a/trunk/arch/powerpc/platforms/powermac/pci.c b/trunk/arch/powerpc/platforms/powermac/pci.c index de3f30e6b333..f671ed253901 100644 --- a/trunk/arch/powerpc/platforms/powermac/pci.c +++ b/trunk/arch/powerpc/platforms/powermac/pci.c @@ -136,14 +136,14 @@ static void __init fixup_bus_range(struct device_node *bridge) |(((unsigned int)(off)) & 0xFCUL) \ |1UL) -static volatile void __iomem *macrisc_cfg_access(struct pci_controller* hose, +static unsigned long macrisc_cfg_access(struct pci_controller* hose, u8 bus, u8 dev_fn, u8 offset) { unsigned int caddr; if (bus == hose->first_busno) { if (dev_fn < (11 << 3)) - return NULL; + return 0; caddr = MACRISC_CFA0(dev_fn, offset); } else caddr = MACRISC_CFA1(bus, dev_fn, offset); @@ -154,14 +154,14 @@ static volatile void __iomem *macrisc_cfg_access(struct pci_controller* hose, } while (in_le32(hose->cfg_addr) != caddr); offset &= has_uninorth ? 0x07 : 0x03; - return hose->cfg_data + offset; + return ((unsigned long)hose->cfg_data) + offset; } static int macrisc_read_config(struct pci_bus *bus, unsigned int devfn, int offset, int len, u32 *val) { struct pci_controller *hose; - volatile void __iomem *addr; + unsigned long addr; hose = pci_bus_to_host(bus); if (hose == NULL) @@ -177,13 +177,13 @@ static int macrisc_read_config(struct pci_bus *bus, unsigned int devfn, */ switch (len) { case 1: - *val = in_8(addr); + *val = in_8((u8 *)addr); break; case 2: - *val = in_le16(addr); + *val = in_le16((u16 *)addr); break; default: - *val = in_le32(addr); + *val = in_le32((u32 *)addr); break; } return PCIBIOS_SUCCESSFUL; @@ -193,7 +193,7 @@ static int macrisc_write_config(struct pci_bus *bus, unsigned int devfn, int offset, int len, u32 val) { struct pci_controller *hose; - volatile void __iomem *addr; + unsigned long addr; hose = pci_bus_to_host(bus); if (hose == NULL) @@ -209,16 +209,16 @@ static int macrisc_write_config(struct pci_bus *bus, unsigned int devfn, */ switch (len) { case 1: - out_8(addr, val); - (void) in_8(addr); + out_8((u8 *)addr, val); + (void) in_8((u8 *)addr); break; case 2: - out_le16(addr, val); - (void) in_le16(addr); + out_le16((u16 *)addr, val); + (void) in_le16((u16 *)addr); break; default: - out_le32(addr, val); - (void) in_le32(addr); + out_le32((u32 *)addr, val); + (void) in_le32((u32 *)addr); break; } return PCIBIOS_SUCCESSFUL; @@ -348,23 +348,25 @@ static int u3_ht_skip_device(struct pci_controller *hose, + (((unsigned int)bus) << 16) \ + 0x01000000UL) -static volatile void __iomem *u3_ht_cfg_access(struct pci_controller* hose, +static unsigned long u3_ht_cfg_access(struct pci_controller* hose, u8 bus, u8 devfn, u8 offset) { if (bus == hose->first_busno) { /* For now, we don't self probe U3 HT bridge */ if (PCI_SLOT(devfn) == 0) - return NULL; - return hose->cfg_data + U3_HT_CFA0(devfn, offset); + return 0; + return ((unsigned long)hose->cfg_data) + + U3_HT_CFA0(devfn, offset); } else - return hose->cfg_data + U3_HT_CFA1(bus, devfn, offset); + return ((unsigned long)hose->cfg_data) + + U3_HT_CFA1(bus, devfn, offset); } static int u3_ht_read_config(struct pci_bus *bus, unsigned int devfn, int offset, int len, u32 *val) { struct pci_controller *hose; - volatile void __iomem *addr; + unsigned long addr; hose = pci_bus_to_host(bus); if (hose == NULL) @@ -398,13 +400,13 @@ static int u3_ht_read_config(struct pci_bus *bus, unsigned int devfn, */ switch (len) { case 1: - *val = in_8(addr); + *val = in_8((u8 *)addr); break; case 2: - *val = in_le16(addr); + *val = in_le16((u16 *)addr); break; default: - *val = in_le32(addr); + *val = in_le32((u32 *)addr); break; } return PCIBIOS_SUCCESSFUL; @@ -414,7 +416,7 @@ static int u3_ht_write_config(struct pci_bus *bus, unsigned int devfn, int offset, int len, u32 val) { struct pci_controller *hose; - volatile void __iomem *addr; + unsigned long addr; hose = pci_bus_to_host(bus); if (hose == NULL) @@ -440,16 +442,16 @@ static int u3_ht_write_config(struct pci_bus *bus, unsigned int devfn, */ switch (len) { case 1: - out_8(addr, val); - (void) in_8(addr); + out_8((u8 *)addr, val); + (void) in_8((u8 *)addr); break; case 2: - out_le16(addr, val); - (void) in_le16(addr); + out_le16((u16 *)addr, val); + (void) in_le16((u16 *)addr); break; default: - out_le32((u32 __iomem *)addr, val); - (void) in_le32(addr); + out_le32((u32 *)addr, val); + (void) in_le32((u32 *)addr); break; } return PCIBIOS_SUCCESSFUL; @@ -474,7 +476,7 @@ static struct pci_ops u3_ht_pci_ops = |(((unsigned int)(off)) & 0xfcU) \ |1UL) -static volatile void __iomem *u4_pcie_cfg_access(struct pci_controller* hose, +static unsigned long u4_pcie_cfg_access(struct pci_controller* hose, u8 bus, u8 dev_fn, int offset) { unsigned int caddr; @@ -490,14 +492,14 @@ static volatile void __iomem *u4_pcie_cfg_access(struct pci_controller* hose, } while (in_le32(hose->cfg_addr) != caddr); offset &= 0x03; - return hose->cfg_data + offset; + return ((unsigned long)hose->cfg_data) + offset; } static int u4_pcie_read_config(struct pci_bus *bus, unsigned int devfn, int offset, int len, u32 *val) { struct pci_controller *hose; - volatile void __iomem *addr; + unsigned long addr; hose = pci_bus_to_host(bus); if (hose == NULL) @@ -513,13 +515,13 @@ static int u4_pcie_read_config(struct pci_bus *bus, unsigned int devfn, */ switch (len) { case 1: - *val = in_8(addr); + *val = in_8((u8 *)addr); break; case 2: - *val = in_le16(addr); + *val = in_le16((u16 *)addr); break; default: - *val = in_le32(addr); + *val = in_le32((u32 *)addr); break; } return PCIBIOS_SUCCESSFUL; @@ -529,7 +531,7 @@ static int u4_pcie_write_config(struct pci_bus *bus, unsigned int devfn, int offset, int len, u32 val) { struct pci_controller *hose; - volatile void __iomem *addr; + unsigned long addr; hose = pci_bus_to_host(bus); if (hose == NULL) @@ -545,16 +547,16 @@ static int u4_pcie_write_config(struct pci_bus *bus, unsigned int devfn, */ switch (len) { case 1: - out_8(addr, val); - (void) in_8(addr); + out_8((u8 *)addr, val); + (void) in_8((u8 *)addr); break; case 2: - out_le16(addr, val); - (void) in_le16(addr); + out_le16((u16 *)addr, val); + (void) in_le16((u16 *)addr); break; default: - out_le32(addr, val); - (void) in_le32(addr); + out_le32((u32 *)addr, val); + (void) in_le32((u32 *)addr); break; } return PCIBIOS_SUCCESSFUL; @@ -771,7 +773,8 @@ static void __init setup_u3_ht(struct pci_controller* hose) * the reg address cell, we shall fix that by killing struct * reg_property and using some accessor functions instead */ - hose->cfg_data = ioremap(0xf2000000, 0x02000000); + hose->cfg_data = (volatile unsigned char *)ioremap(0xf2000000, + 0x02000000); /* * /ht node doesn't expose a "ranges" property, so we "remove" diff --git a/trunk/arch/powerpc/platforms/powermac/pfunc_core.c b/trunk/arch/powerpc/platforms/powermac/pfunc_core.c index 356a739e52b2..c32c623001dc 100644 --- a/trunk/arch/powerpc/platforms/powermac/pfunc_core.c +++ b/trunk/arch/powerpc/platforms/powermac/pfunc_core.c @@ -862,28 +862,21 @@ int pmf_register_irq_client(struct device_node *target, spin_unlock_irqrestore(&pmf_lock, flags); return -ENODEV; } - if (list_empty(&func->irq_clients)) - func->dev->handlers->irq_enable(func); list_add(&client->link, &func->irq_clients); - client->func = func; spin_unlock_irqrestore(&pmf_lock, flags); return 0; } EXPORT_SYMBOL_GPL(pmf_register_irq_client); -void pmf_unregister_irq_client(struct pmf_irq_client *client) +void pmf_unregister_irq_client(struct device_node *np, + const char *name, + struct pmf_irq_client *client) { - struct pmf_function *func = client->func; unsigned long flags; - BUG_ON(func == NULL); - spin_lock_irqsave(&pmf_lock, flags); - client->func = NULL; list_del(&client->link); - if (list_empty(&func->irq_clients)) - func->dev->handlers->irq_disable(func); spin_unlock_irqrestore(&pmf_lock, flags); } EXPORT_SYMBOL_GPL(pmf_unregister_irq_client); diff --git a/trunk/arch/powerpc/platforms/powermac/setup.c b/trunk/arch/powerpc/platforms/powermac/setup.c index 1955462f4082..89c4c3636161 100644 --- a/trunk/arch/powerpc/platforms/powermac/setup.c +++ b/trunk/arch/powerpc/platforms/powermac/setup.c @@ -82,6 +82,8 @@ #undef SHOW_GATWICK_IRQS +unsigned char drive_info; + int ppc_override_l2cr = 0; int ppc_override_l2cr_value; int has_l2cache = 0; diff --git a/trunk/arch/powerpc/platforms/pseries/eeh_driver.c b/trunk/arch/powerpc/platforms/pseries/eeh_driver.c index e3cbba49fd6e..6373372932ba 100644 --- a/trunk/arch/powerpc/platforms/pseries/eeh_driver.c +++ b/trunk/arch/powerpc/platforms/pseries/eeh_driver.c @@ -333,7 +333,7 @@ void handle_eeh_events (struct eeh_event *event) rc = eeh_reset_device(frozen_pdn, NULL); if (rc) goto hard_fail; - pci_walk_bus(frozen_bus, eeh_report_reset, NULL); + pci_walk_bus(frozen_bus, eeh_report_reset, 0); } /* If all devices reported they can proceed, the re-enable PIO */ @@ -342,11 +342,11 @@ void handle_eeh_events (struct eeh_event *event) rc = eeh_reset_device(frozen_pdn, NULL); if (rc) goto hard_fail; - pci_walk_bus(frozen_bus, eeh_report_reset, NULL); + pci_walk_bus(frozen_bus, eeh_report_reset, 0); } /* Tell all device drivers that they can resume operations */ - pci_walk_bus(frozen_bus, eeh_report_resume, NULL); + pci_walk_bus(frozen_bus, eeh_report_resume, 0); return; @@ -367,7 +367,7 @@ void handle_eeh_events (struct eeh_event *event) eeh_slot_error_detail(frozen_pdn, 2 /* Permanent Error */); /* Notify all devices that they're about to go down. */ - pci_walk_bus(frozen_bus, eeh_report_failure, NULL); + pci_walk_bus(frozen_bus, eeh_report_failure, 0); /* Shut down the device drivers for good. */ pcibios_remove_pci_devices(frozen_bus); diff --git a/trunk/arch/powerpc/platforms/pseries/pci_dlpar.c b/trunk/arch/powerpc/platforms/pseries/pci_dlpar.c index bdaa8aabdaa6..21934784f936 100644 --- a/trunk/arch/powerpc/platforms/pseries/pci_dlpar.c +++ b/trunk/arch/powerpc/platforms/pseries/pci_dlpar.c @@ -58,7 +58,6 @@ pcibios_find_pci_bus(struct device_node *dn) return find_bus_among_children(pdn->phb->bus, dn); } -EXPORT_SYMBOL_GPL(pcibios_find_pci_bus); /** * pcibios_remove_pci_devices - remove all devices under this bus @@ -107,7 +106,6 @@ pcibios_fixup_new_pci_devices(struct pci_bus *bus, int fix_bus) } } } -EXPORT_SYMBOL_GPL(pcibios_fixup_new_pci_devices); static int pcibios_pci_config_bridge(struct pci_dev *dev) @@ -174,4 +172,3 @@ pcibios_add_pci_devices(struct pci_bus * bus) pcibios_pci_config_bridge(dev); } } -EXPORT_SYMBOL_GPL(pcibios_add_pci_devices); diff --git a/trunk/arch/powerpc/platforms/pseries/setup.c b/trunk/arch/powerpc/platforms/pseries/setup.c index 9edeca83f434..da6cebaf72cd 100644 --- a/trunk/arch/powerpc/platforms/pseries/setup.c +++ b/trunk/arch/powerpc/platforms/pseries/setup.c @@ -585,7 +585,7 @@ static int pSeries_pci_probe_mode(struct pci_bus *bus) static void pseries_kexec_cpu_down(int crash_shutdown, int secondary) { /* Don't risk a hypervisor call if we're crashing */ - if (firmware_has_feature(FW_FEATURE_SPLPAR) && !crash_shutdown) { + if (!crash_shutdown) { unsigned long vpa = __pa(get_lppaca()); if (unregister_vpa(hard_smp_processor_id(), vpa)) { diff --git a/trunk/arch/powerpc/sysdev/dart_iommu.c b/trunk/arch/powerpc/sysdev/dart_iommu.c index 6298264efe36..977de9db8754 100644 --- a/trunk/arch/powerpc/sysdev/dart_iommu.c +++ b/trunk/arch/powerpc/sysdev/dart_iommu.c @@ -59,7 +59,7 @@ static unsigned long dart_tablesize; static u32 *dart_vbase; /* Mapped base address for the dart */ -static unsigned int __iomem *dart; +static unsigned int *__iomem dart; /* Dummy val that entries are set to when unused */ static unsigned int dart_emptyval; diff --git a/trunk/arch/ppc/configs/bamboo_defconfig b/trunk/arch/ppc/configs/bamboo_defconfig index 41fd3938fa5c..0ba4e70d50b6 100644 --- a/trunk/arch/ppc/configs/bamboo_defconfig +++ b/trunk/arch/ppc/configs/bamboo_defconfig @@ -499,7 +499,6 @@ CONFIG_NATSEMI=y # CONFIG_DL2K is not set CONFIG_E1000=y # CONFIG_E1000_NAPI is not set -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/ppc/configs/katana_defconfig b/trunk/arch/ppc/configs/katana_defconfig index 7311fe6b42de..0f3bb9af9c22 100644 --- a/trunk/arch/ppc/configs/katana_defconfig +++ b/trunk/arch/ppc/configs/katana_defconfig @@ -488,7 +488,6 @@ CONFIG_E100=y # CONFIG_DL2K is not set CONFIG_E1000=y # CONFIG_E1000_NAPI is not set -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/ppc/configs/mpc834x_sys_defconfig b/trunk/arch/ppc/configs/mpc834x_sys_defconfig index b96a6d6dad0e..673dc64ebcb1 100644 --- a/trunk/arch/ppc/configs/mpc834x_sys_defconfig +++ b/trunk/arch/ppc/configs/mpc834x_sys_defconfig @@ -402,7 +402,6 @@ CONFIG_E100=y # CONFIG_DL2K is not set CONFIG_E1000=y # CONFIG_E1000_NAPI is not set -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/ppc/configs/power3_defconfig b/trunk/arch/ppc/configs/power3_defconfig index a1ef929bca59..93da595a4738 100644 --- a/trunk/arch/ppc/configs/power3_defconfig +++ b/trunk/arch/ppc/configs/power3_defconfig @@ -442,7 +442,6 @@ CONFIG_E100=y # CONFIG_DL2K is not set CONFIG_E1000=y # CONFIG_E1000_NAPI is not set -# CONFIG_E1000_DISABLE_PACKET_SPLIT is not set # CONFIG_NS83820 is not set # CONFIG_HAMACHI is not set # CONFIG_YELLOWFIN is not set diff --git a/trunk/arch/ppc/kernel/head_8xx.S b/trunk/arch/ppc/kernel/head_8xx.S index c1e89ad0684d..3e6ca7f5843f 100644 --- a/trunk/arch/ppc/kernel/head_8xx.S +++ b/trunk/arch/ppc/kernel/head_8xx.S @@ -810,16 +810,13 @@ initial_mmu: mtspr SPRN_MD_TWC, r9 li r11, MI_BOOTINIT /* Create RPN for address 0 */ addis r11, r11, 0x0080 /* Add 8M */ - mtspr SPRN_MD_RPN, r11 - - addi r10, r10, 0x0100 - mtspr SPRN_MD_CTR, r10 + mtspr SPRN_MD_RPN, r8 addis r8, r8, 0x0080 /* Add 8M */ mtspr SPRN_MD_EPN, r8 mtspr SPRN_MD_TWC, r9 addis r11, r11, 0x0080 /* Add 8M */ - mtspr SPRN_MD_RPN, r11 + mtspr SPRN_MD_RPN, r8 #endif /* Since the cache is enabled according to the information we diff --git a/trunk/arch/ppc/kernel/misc.S b/trunk/arch/ppc/kernel/misc.S index 5a936566fd61..c3427eed8345 100644 --- a/trunk/arch/ppc/kernel/misc.S +++ b/trunk/arch/ppc/kernel/misc.S @@ -1048,3 +1048,286 @@ _GLOBAL(name) \ blr SYSCALL(execve) + +/* Why isn't this a) automatic, b) written in 'C'? */ + .data + .align 4 +_GLOBAL(sys_call_table) + .long sys_restart_syscall /* 0 */ + .long sys_exit + .long ppc_fork + .long sys_read + .long sys_write + .long sys_open /* 5 */ + .long sys_close + .long sys_waitpid + .long sys_creat + .long sys_link + .long sys_unlink /* 10 */ + .long sys_execve + .long sys_chdir + .long sys_time + .long sys_mknod + .long sys_chmod /* 15 */ + .long sys_lchown + .long sys_ni_syscall /* old break syscall holder */ + .long sys_stat + .long sys_lseek + .long sys_getpid /* 20 */ + .long sys_mount + .long sys_oldumount + .long sys_setuid + .long sys_getuid + .long sys_stime /* 25 */ + .long sys_ptrace + .long sys_alarm + .long sys_fstat + .long sys_pause + .long sys_utime /* 30 */ + .long sys_ni_syscall /* old stty syscall holder */ + .long sys_ni_syscall /* old gtty syscall holder */ + .long sys_access + .long sys_nice + .long sys_ni_syscall /* 35 */ /* old ftime syscall holder */ + .long sys_sync + .long sys_kill + .long sys_rename + .long sys_mkdir + .long sys_rmdir /* 40 */ + .long sys_dup + .long sys_pipe + .long sys_times + .long sys_ni_syscall /* old prof syscall holder */ + .long sys_brk /* 45 */ + .long sys_setgid + .long sys_getgid + .long sys_signal + .long sys_geteuid + .long sys_getegid /* 50 */ + .long sys_acct + .long sys_umount /* recycled never used phys() */ + .long sys_ni_syscall /* old lock syscall holder */ + .long sys_ioctl + .long sys_fcntl /* 55 */ + .long sys_ni_syscall /* old mpx syscall holder */ + .long sys_setpgid + .long sys_ni_syscall /* old ulimit syscall holder */ + .long sys_olduname + .long sys_umask /* 60 */ + .long sys_chroot + .long sys_ustat + .long sys_dup2 + .long sys_getppid + .long sys_getpgrp /* 65 */ + .long sys_setsid + .long sys_sigaction + .long sys_sgetmask + .long sys_ssetmask + .long sys_setreuid /* 70 */ + .long sys_setregid + .long sys_sigsuspend + .long sys_sigpending + .long sys_sethostname + .long sys_setrlimit /* 75 */ + .long sys_old_getrlimit + .long sys_getrusage + .long sys_gettimeofday + .long sys_settimeofday + .long sys_getgroups /* 80 */ + .long sys_setgroups + .long ppc_select + .long sys_symlink + .long sys_lstat + .long sys_readlink /* 85 */ + .long sys_uselib + .long sys_swapon + .long sys_reboot + .long old_readdir + .long sys_mmap /* 90 */ + .long sys_munmap + .long sys_truncate + .long sys_ftruncate + .long sys_fchmod + .long sys_fchown /* 95 */ + .long sys_getpriority + .long sys_setpriority + .long sys_ni_syscall /* old profil syscall holder */ + .long sys_statfs + .long sys_fstatfs /* 100 */ + .long sys_ni_syscall + .long sys_socketcall + .long sys_syslog + .long sys_setitimer + .long sys_getitimer /* 105 */ + .long sys_newstat + .long sys_newlstat + .long sys_newfstat + .long sys_uname + .long sys_ni_syscall /* 110 */ + .long sys_vhangup + .long sys_ni_syscall /* old 'idle' syscall */ + .long sys_ni_syscall + .long sys_wait4 + .long sys_swapoff /* 115 */ + .long sys_sysinfo + .long sys_ipc + .long sys_fsync + .long sys_sigreturn + .long ppc_clone /* 120 */ + .long sys_setdomainname + .long sys_newuname + .long sys_ni_syscall + .long sys_adjtimex + .long sys_mprotect /* 125 */ + .long sys_sigprocmask + .long sys_ni_syscall /* old sys_create_module */ + .long sys_init_module + .long sys_delete_module + .long sys_ni_syscall /* old sys_get_kernel_syms */ /* 130 */ + .long sys_quotactl + .long sys_getpgid + .long sys_fchdir + .long sys_bdflush + .long sys_sysfs /* 135 */ + .long sys_personality + .long sys_ni_syscall /* for afs_syscall */ + .long sys_setfsuid + .long sys_setfsgid + .long sys_llseek /* 140 */ + .long sys_getdents + .long ppc_select + .long sys_flock + .long sys_msync + .long sys_readv /* 145 */ + .long sys_writev + .long sys_getsid + .long sys_fdatasync + .long sys_sysctl + .long sys_mlock /* 150 */ + .long sys_munlock + .long sys_mlockall + .long sys_munlockall + .long sys_sched_setparam + .long sys_sched_getparam /* 155 */ + .long sys_sched_setscheduler + .long sys_sched_getscheduler + .long sys_sched_yield + .long sys_sched_get_priority_max + .long sys_sched_get_priority_min /* 160 */ + .long sys_sched_rr_get_interval + .long sys_nanosleep + .long sys_mremap + .long sys_setresuid + .long sys_getresuid /* 165 */ + .long sys_ni_syscall /* old sys_query_module */ + .long sys_poll + .long sys_nfsservctl + .long sys_setresgid + .long sys_getresgid /* 170 */ + .long sys_prctl + .long sys_rt_sigreturn + .long sys_rt_sigaction + .long sys_rt_sigprocmask + .long sys_rt_sigpending /* 175 */ + .long sys_rt_sigtimedwait + .long sys_rt_sigqueueinfo + .long sys_rt_sigsuspend + .long sys_pread64 + .long sys_pwrite64 /* 180 */ + .long sys_chown + .long sys_getcwd + .long sys_capget + .long sys_capset + .long sys_sigaltstack /* 185 */ + .long sys_sendfile + .long sys_ni_syscall /* streams1 */ + .long sys_ni_syscall /* streams2 */ + .long ppc_vfork + .long sys_getrlimit /* 190 */ + .long sys_readahead + .long sys_mmap2 + .long sys_truncate64 + .long sys_ftruncate64 + .long sys_stat64 /* 195 */ + .long sys_lstat64 + .long sys_fstat64 + .long sys_pciconfig_read + .long sys_pciconfig_write + .long sys_pciconfig_iobase /* 200 */ + .long sys_ni_syscall /* 201 - reserved - MacOnLinux - new */ + .long sys_getdents64 + .long sys_pivot_root + .long sys_fcntl64 + .long sys_madvise /* 205 */ + .long sys_mincore + .long sys_gettid + .long sys_tkill + .long sys_setxattr + .long sys_lsetxattr /* 210 */ + .long sys_fsetxattr + .long sys_getxattr + .long sys_lgetxattr + .long sys_fgetxattr + .long sys_listxattr /* 215 */ + .long sys_llistxattr + .long sys_flistxattr + .long sys_removexattr + .long sys_lremovexattr + .long sys_fremovexattr /* 220 */ + .long sys_futex + .long sys_sched_setaffinity + .long sys_sched_getaffinity + .long sys_ni_syscall + .long sys_ni_syscall /* 225 - reserved for Tux */ + .long sys_sendfile64 + .long sys_io_setup + .long sys_io_destroy + .long sys_io_getevents + .long sys_io_submit /* 230 */ + .long sys_io_cancel + .long sys_set_tid_address + .long sys_fadvise64 + .long sys_exit_group + .long sys_lookup_dcookie /* 235 */ + .long sys_epoll_create + .long sys_epoll_ctl + .long sys_epoll_wait + .long sys_remap_file_pages + .long sys_timer_create /* 240 */ + .long sys_timer_settime + .long sys_timer_gettime + .long sys_timer_getoverrun + .long sys_timer_delete + .long sys_clock_settime /* 245 */ + .long sys_clock_gettime + .long sys_clock_getres + .long sys_clock_nanosleep + .long sys_swapcontext + .long sys_tgkill /* 250 */ + .long sys_utimes + .long sys_statfs64 + .long sys_fstatfs64 + .long ppc_fadvise64_64 + .long sys_ni_syscall /* 255 - rtas (used on ppc64) */ + .long sys_debug_setcontext + .long sys_ni_syscall /* 257 reserved for vserver */ + .long sys_ni_syscall /* 258 reserved for new sys_remap_file_pages */ + .long sys_ni_syscall /* 259 reserved for new sys_mbind */ + .long sys_ni_syscall /* 260 reserved for new sys_get_mempolicy */ + .long sys_ni_syscall /* 261 reserved for new sys_set_mempolicy */ + .long sys_mq_open + .long sys_mq_unlink + .long sys_mq_timedsend + .long sys_mq_timedreceive /* 265 */ + .long sys_mq_notify + .long sys_mq_getsetattr + .long sys_kexec_load + .long sys_add_key + .long sys_request_key /* 270 */ + .long sys_keyctl + .long sys_waitid + .long sys_ioprio_set + .long sys_ioprio_get + .long sys_inotify_init /* 275 */ + .long sys_inotify_add_watch + .long sys_inotify_rm_watch diff --git a/trunk/arch/ppc/kernel/ppc_ksyms.c b/trunk/arch/ppc/kernel/ppc_ksyms.c index 15bd9b448a48..3a6e4bcb3c53 100644 --- a/trunk/arch/ppc/kernel/ppc_ksyms.c +++ b/trunk/arch/ppc/kernel/ppc_ksyms.c @@ -186,15 +186,11 @@ EXPORT_SYMBOL(flush_tlb_kernel_range); EXPORT_SYMBOL(flush_tlb_page); EXPORT_SYMBOL(_tlbie); #ifdef CONFIG_ALTIVEC -#ifndef CONFIG_SMP EXPORT_SYMBOL(last_task_used_altivec); -#endif EXPORT_SYMBOL(giveup_altivec); #endif /* CONFIG_ALTIVEC */ #ifdef CONFIG_SPE -#ifndef CONFIG_SMP EXPORT_SYMBOL(last_task_used_spe); -#endif EXPORT_SYMBOL(giveup_spe); #endif /* CONFIG_SPE */ #ifdef CONFIG_SMP diff --git a/trunk/arch/ppc/platforms/4xx/bamboo.c b/trunk/arch/ppc/platforms/4xx/bamboo.c index 0ec53f049338..159b228eca1e 100644 --- a/trunk/arch/ppc/platforms/4xx/bamboo.c +++ b/trunk/arch/ppc/platforms/4xx/bamboo.c @@ -332,8 +332,8 @@ bamboo_early_serial_map(void) port.irq = 0; port.uartclk = clocks.uart0; port.regshift = 0; - port.iotype = UPIO_MEM; - port.flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST; + port.iotype = SERIAL_IO_MEM; + port.flags = ASYNC_BOOT_AUTOCONF | ASYNC_SKIP_TEST; port.line = 0; if (early_serial_setup(&port) != 0) { diff --git a/trunk/arch/ppc/platforms/4xx/bubinga.c b/trunk/arch/ppc/platforms/4xx/bubinga.c index ce48a4f08cbb..8110f55668c5 100644 --- a/trunk/arch/ppc/platforms/4xx/bubinga.c +++ b/trunk/arch/ppc/platforms/4xx/bubinga.c @@ -97,8 +97,8 @@ bubinga_early_serial_map(void) port.irq = ACTING_UART0_INT; port.uartclk = uart_clock; port.regshift = 0; - port.iotype = UPIO_MEM; - port.flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST; + port.iotype = SERIAL_IO_MEM; + port.flags = ASYNC_BOOT_AUTOCONF | ASYNC_SKIP_TEST; port.line = 0; if (early_serial_setup(&port) != 0) { diff --git a/trunk/arch/ppc/platforms/4xx/ebony.c b/trunk/arch/ppc/platforms/4xx/ebony.c index 9a828b623417..64ebae19cdbb 100644 --- a/trunk/arch/ppc/platforms/4xx/ebony.c +++ b/trunk/arch/ppc/platforms/4xx/ebony.c @@ -225,8 +225,8 @@ ebony_early_serial_map(void) port.irq = 0; port.uartclk = clocks.uart0; port.regshift = 0; - port.iotype = UPIO_MEM; - port.flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST; + port.iotype = SERIAL_IO_MEM; + port.flags = ASYNC_BOOT_AUTOCONF | ASYNC_SKIP_TEST; port.line = 0; if (early_serial_setup(&port) != 0) { diff --git a/trunk/arch/ppc/platforms/4xx/luan.c b/trunk/arch/ppc/platforms/4xx/luan.c index 21d29132aebd..d810b736d9bf 100644 --- a/trunk/arch/ppc/platforms/4xx/luan.c +++ b/trunk/arch/ppc/platforms/4xx/luan.c @@ -279,8 +279,8 @@ luan_early_serial_map(void) port.irq = UART0_INT; port.uartclk = clocks.uart0; port.regshift = 0; - port.iotype = UPIO_MEM; - port.flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST; + port.iotype = SERIAL_IO_MEM; + port.flags = ASYNC_BOOT_AUTOCONF | ASYNC_SKIP_TEST; port.line = 0; if (early_serial_setup(&port) != 0) { diff --git a/trunk/arch/ppc/platforms/4xx/ocotea.c b/trunk/arch/ppc/platforms/4xx/ocotea.c index 4f355b6acab2..73b2c98158f6 100644 --- a/trunk/arch/ppc/platforms/4xx/ocotea.c +++ b/trunk/arch/ppc/platforms/4xx/ocotea.c @@ -248,8 +248,8 @@ ocotea_early_serial_map(void) port.irq = UART0_INT; port.uartclk = clocks.uart0; port.regshift = 0; - port.iotype = UPIO_MEM; - port.flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST; + port.iotype = SERIAL_IO_MEM; + port.flags = ASYNC_BOOT_AUTOCONF | ASYNC_SKIP_TEST; port.line = 0; if (early_serial_setup(&port) != 0) { diff --git a/trunk/arch/ppc/platforms/4xx/xilinx_ml300.c b/trunk/arch/ppc/platforms/4xx/xilinx_ml300.c index e90d97f64f76..0b1b77d986bf 100644 --- a/trunk/arch/ppc/platforms/4xx/xilinx_ml300.c +++ b/trunk/arch/ppc/platforms/4xx/xilinx_ml300.c @@ -95,8 +95,8 @@ ml300_early_serial_map(void) port.irq = old_ports[i].irq; port.uartclk = old_ports[i].baud_base * 16; port.regshift = old_ports[i].iomem_reg_shift; - port.iotype = UPIO_MEM; - port.flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST; + port.iotype = SERIAL_IO_MEM; + port.flags = ASYNC_BOOT_AUTOCONF | ASYNC_SKIP_TEST; port.line = i; if (early_serial_setup(&port) != 0) { diff --git a/trunk/arch/ppc/platforms/4xx/yucca.c b/trunk/arch/ppc/platforms/4xx/yucca.c index b065b8babcd3..e60f4bd437ec 100644 --- a/trunk/arch/ppc/platforms/4xx/yucca.c +++ b/trunk/arch/ppc/platforms/4xx/yucca.c @@ -305,8 +305,8 @@ yucca_early_serial_map(void) port.irq = UART0_INT; port.uartclk = clocks.uart0; port.regshift = 0; - port.iotype = UPIO_MEM; - port.flags = UPF_BOOT_AUTOCONF | UPF_SKIP_TEST; + port.iotype = SERIAL_IO_MEM; + port.flags = ASYNC_BOOT_AUTOCONF | ASYNC_SKIP_TEST; port.line = 0; if (early_serial_setup(&port) != 0) { diff --git a/trunk/arch/ppc/platforms/83xx/mpc834x_sys.c b/trunk/arch/ppc/platforms/83xx/mpc834x_sys.c index 1a659bbc1860..012e1e652c03 100644 --- a/trunk/arch/ppc/platforms/83xx/mpc834x_sys.c +++ b/trunk/arch/ppc/platforms/83xx/mpc834x_sys.c @@ -301,14 +301,14 @@ platform_init(unsigned long r3, unsigned long r4, unsigned long r5, struct uart_port p; memset(&p, 0, sizeof (p)); - p.iotype = UPIO_MEM; + p.iotype = SERIAL_IO_MEM; p.membase = (unsigned char __iomem *)(VIRT_IMMRBAR + 0x4500); p.uartclk = binfo->bi_busfreq; gen550_init(0, &p); memset(&p, 0, sizeof (p)); - p.iotype = UPIO_MEM; + p.iotype = SERIAL_IO_MEM; p.membase = (unsigned char __iomem *)(VIRT_IMMRBAR + 0x4600); p.uartclk = binfo->bi_busfreq; diff --git a/trunk/arch/ppc/platforms/85xx/mpc8540_ads.c b/trunk/arch/ppc/platforms/85xx/mpc8540_ads.c index 408d64f18e1a..2eceb1e6f4eb 100644 --- a/trunk/arch/ppc/platforms/85xx/mpc8540_ads.c +++ b/trunk/arch/ppc/platforms/85xx/mpc8540_ads.c @@ -162,14 +162,14 @@ platform_init(unsigned long r3, unsigned long r4, unsigned long r5, binfo->bi_immr_base, MPC85xx_CCSRBAR_SIZE, _PAGE_IO, 0); memset(&p, 0, sizeof (p)); - p.iotype = UPIO_MEM; + p.iotype = SERIAL_IO_MEM; p.membase = (void *) binfo->bi_immr_base + MPC85xx_UART0_OFFSET; p.uartclk = binfo->bi_busfreq; gen550_init(0, &p); memset(&p, 0, sizeof (p)); - p.iotype = UPIO_MEM; + p.iotype = SERIAL_IO_MEM; p.membase = (void *) binfo->bi_immr_base + MPC85xx_UART1_OFFSET; p.uartclk = binfo->bi_busfreq; diff --git a/trunk/arch/ppc/platforms/85xx/mpc85xx_cds_common.c b/trunk/arch/ppc/platforms/85xx/mpc85xx_cds_common.c index 1801ab392e22..b332ebae6bd3 100644 --- a/trunk/arch/ppc/platforms/85xx/mpc85xx_cds_common.c +++ b/trunk/arch/ppc/platforms/85xx/mpc85xx_cds_common.c @@ -534,14 +534,14 @@ platform_init(unsigned long r3, unsigned long r4, unsigned long r5, binfo->bi_immr_base, MPC85xx_CCSRBAR_SIZE, _PAGE_IO, 0); memset(&p, 0, sizeof (p)); - p.iotype = UPIO_MEM; + p.iotype = SERIAL_IO_MEM; p.membase = (void *) binfo->bi_immr_base + MPC85xx_UART0_OFFSET; p.uartclk = binfo->bi_busfreq; gen550_init(0, &p); memset(&p, 0, sizeof (p)); - p.iotype = UPIO_MEM; + p.iotype = SERIAL_IO_MEM; p.membase = (void *) binfo->bi_immr_base + MPC85xx_UART1_OFFSET; p.uartclk = binfo->bi_busfreq; diff --git a/trunk/arch/ppc/platforms/85xx/sbc8560.c b/trunk/arch/ppc/platforms/85xx/sbc8560.c index 8a72221f816c..e777ba824aa9 100644 --- a/trunk/arch/ppc/platforms/85xx/sbc8560.c +++ b/trunk/arch/ppc/platforms/85xx/sbc8560.c @@ -64,7 +64,7 @@ sbc8560_early_serial_map(void) uart_req.irq = MPC85xx_IRQ_EXT9; uart_req.flags = STD_COM_FLAGS; uart_req.uartclk = BASE_BAUD * 16; - uart_req.iotype = UPIO_MEM; + uart_req.iotype = SERIAL_IO_MEM; uart_req.mapbase = UARTA_ADDR; uart_req.membase = ioremap(uart_req.mapbase, MPC85xx_UART0_SIZE); uart_req.type = PORT_16650; diff --git a/trunk/arch/ppc/platforms/85xx/tqm85xx.c b/trunk/arch/ppc/platforms/85xx/tqm85xx.c index a5e38ba62732..b436f4d0a3fa 100644 --- a/trunk/arch/ppc/platforms/85xx/tqm85xx.c +++ b/trunk/arch/ppc/platforms/85xx/tqm85xx.c @@ -346,14 +346,14 @@ platform_init(unsigned long r3, unsigned long r4, unsigned long r5, binfo->bi_immr_base, MPC85xx_CCSRBAR_SIZE, _PAGE_IO, 0); memset(&p, 0, sizeof (p)); - p.iotype = UPIO_MEM; + p.iotype = SERIAL_IO_MEM; p.membase = (void *) binfo->bi_immr_base + MPC85xx_UART0_OFFSET; p.uartclk = binfo->bi_busfreq; gen550_init(0, &p); memset(&p, 0, sizeof (p)); - p.iotype = UPIO_MEM; + p.iotype = SERIAL_IO_MEM; p.membase = (void *) binfo->bi_immr_base + MPC85xx_UART1_OFFSET; p.uartclk = binfo->bi_busfreq; diff --git a/trunk/arch/ppc/platforms/chestnut.c b/trunk/arch/ppc/platforms/chestnut.c index aefcc0e7be57..48a4a510d598 100644 --- a/trunk/arch/ppc/platforms/chestnut.c +++ b/trunk/arch/ppc/platforms/chestnut.c @@ -116,7 +116,7 @@ chestnut_early_serial_map(void) port.uartclk = BASE_BAUD * 16; port.irq = UART0_INT; port.flags = STD_COM_FLAGS | UPF_IOREMAP; - port.iotype = UPIO_MEM; + port.iotype = SERIAL_IO_MEM; port.mapbase = CHESTNUT_UART0_IO_BASE; port.regshift = 0; diff --git a/trunk/arch/ppc/platforms/ev64260.c b/trunk/arch/ppc/platforms/ev64260.c index ffde8f6f6302..32358b3fb236 100644 --- a/trunk/arch/ppc/platforms/ev64260.c +++ b/trunk/arch/ppc/platforms/ev64260.c @@ -330,7 +330,7 @@ ev64260_early_serial_map(void) port.irq = EV64260_UART_0_IRQ; port.uartclk = BASE_BAUD * 16; port.regshift = 2; - port.iotype = UPIO_MEM; + port.iotype = SERIAL_IO_MEM; port.flags = STD_COM_FLAGS; #if defined(CONFIG_SERIAL_TEXT_DEBUG) || defined(CONFIG_KGDB) diff --git a/trunk/arch/ppc/platforms/radstone_ppc7d.c b/trunk/arch/ppc/platforms/radstone_ppc7d.c index 872c0a3ba3c7..708b8739ecdd 100644 --- a/trunk/arch/ppc/platforms/radstone_ppc7d.c +++ b/trunk/arch/ppc/platforms/radstone_ppc7d.c @@ -100,7 +100,7 @@ static void __init ppc7d_early_serial_map(void) serial_req.uartclk = UART_CLK; serial_req.irq = 4; serial_req.flags = STD_COM_FLAGS; - serial_req.iotype = UPIO_MEM; + serial_req.iotype = SERIAL_IO_MEM; serial_req.membase = (u_char *) PPC7D_SERIAL_0; gen550_init(0, &serial_req); diff --git a/trunk/arch/ppc/platforms/spruce.c b/trunk/arch/ppc/platforms/spruce.c index 69e1de7971f2..5ad70d357cb9 100644 --- a/trunk/arch/ppc/platforms/spruce.c +++ b/trunk/arch/ppc/platforms/spruce.c @@ -176,8 +176,8 @@ spruce_early_serial_map(void) memset(&serial_req, 0, sizeof(serial_req)); serial_req.uartclk = uart_clk; serial_req.irq = UART0_INT; - serial_req.flags = UPF_BOOT_AUTOCONF; - serial_req.iotype = UPIO_MEM; + serial_req.flags = ASYNC_BOOT_AUTOCONF; + serial_req.iotype = SERIAL_IO_MEM; serial_req.membase = (u_char *)UART0_IO_BASE; serial_req.regshift = 0; diff --git a/trunk/arch/ppc/syslib/mv64x60.c b/trunk/arch/ppc/syslib/mv64x60.c index 1f01b7e2376b..94ea346b7b4b 100644 --- a/trunk/arch/ppc/syslib/mv64x60.c +++ b/trunk/arch/ppc/syslib/mv64x60.c @@ -313,7 +313,7 @@ static struct platform_device mpsc1_device = { }; #endif -#if defined(CONFIG_MV643XX_ETH) || defined(CONFIG_MV643XX_ETH_MODULE) +#ifdef CONFIG_MV643XX_ETH static struct resource mv64x60_eth_shared_resources[] = { [0] = { .name = "ethernet shared base", @@ -456,7 +456,7 @@ static struct platform_device *mv64x60_pd_devs[] __initdata = { &mpsc0_device, &mpsc1_device, #endif -#if defined(CONFIG_MV643XX_ETH) || defined(CONFIG_MV643XX_ETH_MODULE) +#ifdef CONFIG_MV643XX_ETH &mv64x60_eth_shared_device, #endif #ifdef CONFIG_MV643XX_ETH_0 diff --git a/trunk/arch/ppc/syslib/ocp.c b/trunk/arch/ppc/syslib/ocp.c index 2fe28ded2c60..ab34b1d6072f 100644 --- a/trunk/arch/ppc/syslib/ocp.c +++ b/trunk/arch/ppc/syslib/ocp.c @@ -189,8 +189,8 @@ ocp_device_resume(struct device *dev) struct bus_type ocp_bus_type = { .name = "ocp", .match = ocp_device_match, - .probe = ocp_device_probe, - .remove = ocp_device_remove, + .probe = ocp_driver_probe, + .remove = ocp_driver_remove, .suspend = ocp_device_suspend, .resume = ocp_device_resume, }; diff --git a/trunk/arch/ppc/syslib/ppc83xx_setup.c b/trunk/arch/ppc/syslib/ppc83xx_setup.c index 7bada82527a8..1b5fe9e398d4 100644 --- a/trunk/arch/ppc/syslib/ppc83xx_setup.c +++ b/trunk/arch/ppc/syslib/ppc83xx_setup.c @@ -108,7 +108,7 @@ mpc83xx_early_serial_map(void) #if defined(CONFIG_SERIAL_TEXT_DEBUG) || defined(CONFIG_KGDB) memset(&serial_req, 0, sizeof (serial_req)); - serial_req.iotype = UPIO_MEM; + serial_req.iotype = SERIAL_IO_MEM; serial_req.mapbase = pdata[0].mapbase; serial_req.membase = pdata[0].membase; serial_req.regshift = 0; diff --git a/trunk/arch/ppc/syslib/ppc85xx_setup.c b/trunk/arch/ppc/syslib/ppc85xx_setup.c index e4dda43fdaa7..1a47ff4b831d 100644 --- a/trunk/arch/ppc/syslib/ppc85xx_setup.c +++ b/trunk/arch/ppc/syslib/ppc85xx_setup.c @@ -90,7 +90,7 @@ mpc85xx_early_serial_map(void) #if defined(CONFIG_SERIAL_TEXT_DEBUG) || defined(CONFIG_KGDB) memset(&serial_req, 0, sizeof (serial_req)); - serial_req.iotype = UPIO_MEM; + serial_req.iotype = SERIAL_IO_MEM; serial_req.mapbase = pdata[0].mapbase; serial_req.membase = pdata[0].membase; serial_req.regshift = 0; diff --git a/trunk/arch/s390/defconfig b/trunk/arch/s390/defconfig index f8d0cd540a06..7d23edc6facb 100644 --- a/trunk/arch/s390/defconfig +++ b/trunk/arch/s390/defconfig @@ -1,17 +1,19 @@ # # Automatically generated make config: don't edit -# Linux kernel version: 2.6.16-rc2 -# Wed Feb 8 10:44:39 2006 +# Linux kernel version: 2.6.15-rc2 +# Mon Nov 21 13:51:30 2005 # CONFIG_MMU=y CONFIG_RWSEM_XCHGADD_ALGORITHM=y CONFIG_GENERIC_CALIBRATE_DELAY=y CONFIG_S390=y +CONFIG_UID16=y # # Code maturity level options # CONFIG_EXPERIMENTAL=y +CONFIG_CLEAN_COMPILE=y CONFIG_LOCK_KERNEL=y CONFIG_INIT_ENV_ARG_LIMIT=32 @@ -27,20 +29,18 @@ CONFIG_POSIX_MQUEUE=y CONFIG_SYSCTL=y CONFIG_AUDIT=y # CONFIG_AUDITSYSCALL is not set +CONFIG_HOTPLUG=y +CONFIG_KOBJECT_UEVENT=y CONFIG_IKCONFIG=y CONFIG_IKCONFIG_PROC=y # CONFIG_CPUSETS is not set CONFIG_INITRAMFS_SOURCE="" -CONFIG_UID16=y -# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set # CONFIG_EMBEDDED is not set CONFIG_KALLSYMS=y # CONFIG_KALLSYMS_ALL is not set # CONFIG_KALLSYMS_EXTRA_PASS is not set -CONFIG_HOTPLUG=y CONFIG_PRINTK=y CONFIG_BUG=y -CONFIG_ELF_CORE=y CONFIG_BASE_FULL=y CONFIG_FUTEX=y CONFIG_EPOLL=y @@ -49,10 +49,8 @@ CONFIG_CC_ALIGN_FUNCTIONS=0 CONFIG_CC_ALIGN_LABELS=0 CONFIG_CC_ALIGN_LOOPS=0 CONFIG_CC_ALIGN_JUMPS=0 -CONFIG_SLAB=y # CONFIG_TINY_SHMEM is not set CONFIG_BASE_SMALL=0 -# CONFIG_SLOB is not set # # Loadable module support @@ -78,11 +76,11 @@ CONFIG_IOSCHED_NOOP=y CONFIG_IOSCHED_AS=y CONFIG_IOSCHED_DEADLINE=y CONFIG_IOSCHED_CFQ=y -# CONFIG_DEFAULT_AS is not set -CONFIG_DEFAULT_DEADLINE=y +CONFIG_DEFAULT_AS=y +# CONFIG_DEFAULT_DEADLINE is not set # CONFIG_DEFAULT_CFQ is not set # CONFIG_DEFAULT_NOOP is not set -CONFIG_DEFAULT_IOSCHED="deadline" +CONFIG_DEFAULT_IOSCHED="anticipatory" # # Base setup @@ -153,7 +151,6 @@ CONFIG_NET=y # # Networking options # -# CONFIG_NETDEBUG is not set CONFIG_PACKET=y # CONFIG_PACKET_MMAP is not set CONFIG_UNIX=y @@ -196,11 +193,6 @@ CONFIG_IPV6=y # SCTP Configuration (EXPERIMENTAL) # # CONFIG_IP_SCTP is not set - -# -# TIPC Configuration (EXPERIMENTAL) -# -# CONFIG_TIPC is not set # CONFIG_ATM is not set # CONFIG_BRIDGE is not set # CONFIG_VLAN_8021Q is not set @@ -370,7 +362,6 @@ CONFIG_DM_MULTIPATH=y # CONFIG_UNIX98_PTYS=y CONFIG_UNIX98_PTY_COUNT=2048 -# CONFIG_HANGCHECK_TIMER is not set # # Watchdog Cards @@ -497,7 +488,6 @@ CONFIG_FS_MBCACHE=y # CONFIG_JFS_FS is not set # CONFIG_FS_POSIX_ACL is not set # CONFIG_XFS_FS is not set -# CONFIG_OCFS2_FS is not set # CONFIG_MINIX_FS is not set # CONFIG_ROMFS_FS is not set CONFIG_INOTIFY=y @@ -530,7 +520,6 @@ CONFIG_TMPFS=y # CONFIG_HUGETLB_PAGE is not set CONFIG_RAMFS=y # CONFIG_RELAYFS_FS is not set -# CONFIG_CONFIGFS_FS is not set # # Miscellaneous filesystems @@ -595,7 +584,6 @@ CONFIG_MSDOS_PARTITION=y # CONFIG_SGI_PARTITION is not set # CONFIG_ULTRIX_PARTITION is not set # CONFIG_SUN_PARTITION is not set -# CONFIG_KARMA_PARTITION is not set # CONFIG_EFI_PARTITION is not set # @@ -604,30 +592,27 @@ CONFIG_MSDOS_PARTITION=y # CONFIG_NLS is not set # -# Instrumentation Support +# Profiling support # # CONFIG_PROFILING is not set -# CONFIG_STATISTICS is not set # # Kernel hacking # # CONFIG_PRINTK_TIME is not set -CONFIG_MAGIC_SYSRQ=y CONFIG_DEBUG_KERNEL=y +CONFIG_MAGIC_SYSRQ=y CONFIG_LOG_BUF_SHIFT=17 -# CONFIG_DETECT_SOFTLOCKUP is not set +CONFIG_DETECT_SOFTLOCKUP=y # CONFIG_SCHEDSTATS is not set # CONFIG_DEBUG_SLAB is not set -# CONFIG_DEBUG_PREEMPT is not set -CONFIG_DEBUG_MUTEXES=y +CONFIG_DEBUG_PREEMPT=y # CONFIG_DEBUG_SPINLOCK is not set # CONFIG_DEBUG_SPINLOCK_SLEEP is not set # CONFIG_DEBUG_KOBJECT is not set # CONFIG_DEBUG_INFO is not set CONFIG_DEBUG_FS=y # CONFIG_DEBUG_VM is not set -CONFIG_FORCED_INLINING=y # CONFIG_RCU_TORTURE_TEST is not set # diff --git a/trunk/arch/s390/kernel/compat_linux.c b/trunk/arch/s390/kernel/compat_linux.c index 2d021626c1a6..bf9a7a361b34 100644 --- a/trunk/arch/s390/kernel/compat_linux.c +++ b/trunk/arch/s390/kernel/compat_linux.c @@ -100,12 +100,12 @@ #define SET_STAT_UID(stat, uid) (stat).st_uid = high2lowuid(uid) #define SET_STAT_GID(stat, gid) (stat).st_gid = high2lowgid(gid) -asmlinkage long sys32_chown16(const char __user * filename, u16 user, u16 group) +asmlinkage long sys32_chown16(const char * filename, u16 user, u16 group) { return sys_chown(filename, low2highuid(user), low2highgid(group)); } -asmlinkage long sys32_lchown16(const char __user * filename, u16 user, u16 group) +asmlinkage long sys32_lchown16(const char * filename, u16 user, u16 group) { return sys_lchown(filename, low2highuid(user), low2highgid(group)); } @@ -141,7 +141,7 @@ asmlinkage long sys32_setresuid16(u16 ruid, u16 euid, u16 suid) low2highuid(suid)); } -asmlinkage long sys32_getresuid16(u16 __user *ruid, u16 __user *euid, u16 __user *suid) +asmlinkage long sys32_getresuid16(u16 *ruid, u16 *euid, u16 *suid) { int retval; @@ -158,7 +158,7 @@ asmlinkage long sys32_setresgid16(u16 rgid, u16 egid, u16 sgid) low2highgid(sgid)); } -asmlinkage long sys32_getresgid16(u16 __user *rgid, u16 __user *egid, u16 __user *sgid) +asmlinkage long sys32_getresgid16(u16 *rgid, u16 *egid, u16 *sgid) { int retval; @@ -179,7 +179,7 @@ asmlinkage long sys32_setfsgid16(u16 gid) return sys_setfsgid((gid_t)gid); } -static int groups16_to_user(u16 __user *grouplist, struct group_info *group_info) +static int groups16_to_user(u16 *grouplist, struct group_info *group_info) { int i; u16 group; @@ -193,7 +193,7 @@ static int groups16_to_user(u16 __user *grouplist, struct group_info *group_info return 0; } -static int groups16_from_user(struct group_info *group_info, u16 __user *grouplist) +static int groups16_from_user(struct group_info *group_info, u16 *grouplist) { int i; u16 group; @@ -207,7 +207,7 @@ static int groups16_from_user(struct group_info *group_info, u16 __user *groupli return 0; } -asmlinkage long sys32_getgroups16(int gidsetsize, u16 __user *grouplist) +asmlinkage long sys32_getgroups16(int gidsetsize, u16 *grouplist) { int i; @@ -231,7 +231,7 @@ asmlinkage long sys32_getgroups16(int gidsetsize, u16 __user *grouplist) return i; } -asmlinkage long sys32_setgroups16(int gidsetsize, u16 __user *grouplist) +asmlinkage long sys32_setgroups16(int gidsetsize, u16 *grouplist) { struct group_info *group_info; int retval; @@ -278,14 +278,14 @@ asmlinkage long sys32_getegid16(void) /* 32-bit timeval and related flotsam. */ -static inline long get_tv32(struct timeval *o, struct compat_timeval __user *i) +static inline long get_tv32(struct timeval *o, struct compat_timeval *i) { return (!access_ok(VERIFY_READ, o, sizeof(*o)) || (__get_user(o->tv_sec, &i->tv_sec) || __get_user(o->tv_usec, &i->tv_usec))); } -static inline long put_tv32(struct compat_timeval __user *o, struct timeval *i) +static inline long put_tv32(struct compat_timeval *o, struct timeval *i) { return (!access_ok(VERIFY_WRITE, o, sizeof(*o)) || (__put_user(i->tv_sec, &o->tv_sec) || @@ -341,7 +341,7 @@ asmlinkage long sys32_ipc(u32 call, int first, int second, int third, u32 ptr) return -ENOSYS; } -asmlinkage long sys32_truncate64(const char __user * path, unsigned long high, unsigned long low) +asmlinkage long sys32_truncate64(const char * path, unsigned long high, unsigned long low) { if ((int)high < 0) return -EINVAL; @@ -357,7 +357,7 @@ asmlinkage long sys32_ftruncate64(unsigned int fd, unsigned long high, unsigned return sys_ftruncate(fd, (high << 32) | low); } -int cp_compat_stat(struct kstat *stat, struct compat_stat __user *statbuf) +int cp_compat_stat(struct kstat *stat, struct compat_stat *statbuf) { int err; @@ -591,7 +591,7 @@ sys32_delete_module(const char __user *name_user, unsigned int flags) extern struct timezone sys_tz; -asmlinkage long sys32_gettimeofday(struct compat_timeval __user *tv, struct timezone __user *tz) +asmlinkage long sys32_gettimeofday(struct compat_timeval *tv, struct timezone *tz) { if (tv) { struct timeval ktv; @@ -606,7 +606,7 @@ asmlinkage long sys32_gettimeofday(struct compat_timeval __user *tv, struct time return 0; } -static inline long get_ts32(struct timespec *o, struct compat_timeval __user *i) +static inline long get_ts32(struct timespec *o, struct compat_timeval *i) { long usec; @@ -620,7 +620,7 @@ static inline long get_ts32(struct timespec *o, struct compat_timeval __user *i) return 0; } -asmlinkage long sys32_settimeofday(struct compat_timeval __user *tv, struct timezone __user *tz) +asmlinkage long sys32_settimeofday(struct compat_timeval *tv, struct timezone *tz) { struct timespec kts; struct timezone ktz; @@ -645,7 +645,7 @@ asmlinkage long sys32_pause(void) return -ERESTARTNOHAND; } -asmlinkage long sys32_pread64(unsigned int fd, char __user *ubuf, +asmlinkage long sys32_pread64(unsigned int fd, char *ubuf, size_t count, u32 poshi, u32 poslo) { if ((compat_ssize_t) count < 0) @@ -653,7 +653,7 @@ asmlinkage long sys32_pread64(unsigned int fd, char __user *ubuf, return sys_pread64(fd, ubuf, count, ((loff_t)AA(poshi) << 32) | AA(poslo)); } -asmlinkage long sys32_pwrite64(unsigned int fd, const char __user *ubuf, +asmlinkage long sys32_pwrite64(unsigned int fd, const char *ubuf, size_t count, u32 poshi, u32 poslo) { if ((compat_ssize_t) count < 0) @@ -666,7 +666,7 @@ asmlinkage compat_ssize_t sys32_readahead(int fd, u32 offhi, u32 offlo, s32 coun return sys_readahead(fd, ((loff_t)AA(offhi) << 32) | AA(offlo), count); } -asmlinkage long sys32_sendfile(int out_fd, int in_fd, compat_off_t __user *offset, size_t count) +asmlinkage long sys32_sendfile(int out_fd, int in_fd, compat_off_t *offset, size_t count) { mm_segment_t old_fs = get_fs(); int ret; @@ -686,7 +686,7 @@ asmlinkage long sys32_sendfile(int out_fd, int in_fd, compat_off_t __user *offse } asmlinkage long sys32_sendfile64(int out_fd, int in_fd, - compat_loff_t __user *offset, s32 count) + compat_loff_t *offset, s32 count) { mm_segment_t old_fs = get_fs(); int ret; @@ -722,7 +722,7 @@ struct timex32 { extern int do_adjtimex(struct timex *); -asmlinkage long sys32_adjtimex(struct timex32 __user *utp) +asmlinkage long sys32_adjtimex(struct timex32 *utp) { struct timex txc; int ret; @@ -789,13 +789,12 @@ struct __sysctl_args32 { u32 __unused[4]; }; -asmlinkage long sys32_sysctl(struct __sysctl_args32 __user *args) +asmlinkage long sys32_sysctl(struct __sysctl_args32 *args) { struct __sysctl_args32 tmp; int error; - size_t oldlen; - size_t __user *oldlenp = NULL; - unsigned long addr = (((unsigned long)&args->__unused[0]) + 7) & ~7; + size_t oldlen, *oldlenp = NULL; + unsigned long addr = (((long)&args->__unused[0]) + 7) & ~7; if (copy_from_user(&tmp, args, sizeof(tmp))) return -EFAULT; @@ -807,20 +806,20 @@ asmlinkage long sys32_sysctl(struct __sysctl_args32 __user *args) basically copy the whole sysctl.c here, and glibc's __sysctl uses rw memory for the structure anyway. */ - if (get_user(oldlen, (u32 __user *)compat_ptr(tmp.oldlenp)) || - put_user(oldlen, (size_t __user *)addr)) + if (get_user(oldlen, (u32 *)A(tmp.oldlenp)) || + put_user(oldlen, (size_t *)addr)) return -EFAULT; - oldlenp = (size_t __user *)addr; + oldlenp = (size_t *)addr; } lock_kernel(); - error = do_sysctl(compat_ptr(tmp.name), tmp.nlen, compat_ptr(tmp.oldval), - oldlenp, compat_ptr(tmp.newval), tmp.newlen); + error = do_sysctl((int *)A(tmp.name), tmp.nlen, (void *)A(tmp.oldval), + oldlenp, (void *)A(tmp.newval), tmp.newlen); unlock_kernel(); if (oldlenp) { if (!error) { - if (get_user(oldlen, (size_t __user *)addr) || - put_user(oldlen, (u32 __user *)compat_ptr(tmp.oldlenp))) + if (get_user(oldlen, (size_t *)addr) || + put_user(oldlen, (u32 *)A(tmp.oldlenp))) error = -EFAULT; } copy_to_user(args->__unused, tmp.__unused, sizeof(tmp.__unused)); @@ -854,7 +853,7 @@ struct stat64_emu31 { unsigned long st_ino; }; -static int cp_stat64(struct stat64_emu31 __user *ubuf, struct kstat *stat) +static int cp_stat64(struct stat64_emu31 *ubuf, struct kstat *stat) { struct stat64_emu31 tmp; @@ -878,7 +877,7 @@ static int cp_stat64(struct stat64_emu31 __user *ubuf, struct kstat *stat) return copy_to_user(ubuf,&tmp,sizeof(tmp)) ? -EFAULT : 0; } -asmlinkage long sys32_stat64(char __user * filename, struct stat64_emu31 __user * statbuf) +asmlinkage long sys32_stat64(char * filename, struct stat64_emu31 * statbuf) { struct kstat stat; int ret = vfs_stat(filename, &stat); @@ -887,7 +886,7 @@ asmlinkage long sys32_stat64(char __user * filename, struct stat64_emu31 __user return ret; } -asmlinkage long sys32_lstat64(char __user * filename, struct stat64_emu31 __user * statbuf) +asmlinkage long sys32_lstat64(char * filename, struct stat64_emu31 * statbuf) { struct kstat stat; int ret = vfs_lstat(filename, &stat); @@ -896,7 +895,7 @@ asmlinkage long sys32_lstat64(char __user * filename, struct stat64_emu31 __user return ret; } -asmlinkage long sys32_fstat64(unsigned long fd, struct stat64_emu31 __user * statbuf) +asmlinkage long sys32_fstat64(unsigned long fd, struct stat64_emu31 * statbuf) { struct kstat stat; int ret = vfs_fstat(fd, &stat); @@ -905,26 +904,6 @@ asmlinkage long sys32_fstat64(unsigned long fd, struct stat64_emu31 __user * sta return ret; } -asmlinkage long sys32_fstatat(unsigned int dfd, char __user *filename, - struct stat64_emu31 __user* statbuf, int flag) -{ - struct kstat stat; - int error = -EINVAL; - - if ((flag & ~AT_SYMLINK_NOFOLLOW) != 0) - goto out; - - if (flag & AT_SYMLINK_NOFOLLOW) - error = vfs_lstat_fd(dfd, filename, &stat); - else - error = vfs_stat_fd(dfd, filename, &stat); - - if (!error) - error = cp_stat64(statbuf, &stat); -out: - return error; -} - /* * Linux/i386 didn't use to be able to handle more than * 4 system call parameters, so these system calls used a memory @@ -973,7 +952,7 @@ static inline long do_mmap2( asmlinkage unsigned long -old32_mmap(struct mmap_arg_struct_emu31 __user *arg) +old32_mmap(struct mmap_arg_struct_emu31 *arg) { struct mmap_arg_struct_emu31 a; int error = -EFAULT; @@ -991,7 +970,7 @@ old32_mmap(struct mmap_arg_struct_emu31 __user *arg) } asmlinkage long -sys32_mmap2(struct mmap_arg_struct_emu31 __user *arg) +sys32_mmap2(struct mmap_arg_struct_emu31 *arg) { struct mmap_arg_struct_emu31 a; int error = -EFAULT; @@ -1003,7 +982,7 @@ sys32_mmap2(struct mmap_arg_struct_emu31 __user *arg) return error; } -asmlinkage long sys32_read(unsigned int fd, char __user * buf, size_t count) +asmlinkage long sys32_read(unsigned int fd, char * buf, size_t count) { if ((compat_ssize_t) count < 0) return -EINVAL; @@ -1011,7 +990,7 @@ asmlinkage long sys32_read(unsigned int fd, char __user * buf, size_t count) return sys_read(fd, buf, count); } -asmlinkage long sys32_write(unsigned int fd, char __user * buf, size_t count) +asmlinkage long sys32_write(unsigned int fd, char * buf, size_t count) { if ((compat_ssize_t) count < 0) return -EINVAL; @@ -1023,12 +1002,12 @@ asmlinkage long sys32_clone(struct pt_regs regs) { unsigned long clone_flags; unsigned long newsp; - int __user *parent_tidptr, *child_tidptr; + int *parent_tidptr, *child_tidptr; clone_flags = regs.gprs[3] & 0xffffffffUL; newsp = regs.orig_gpr2 & 0x7fffffffUL; - parent_tidptr = compat_ptr(regs.gprs[4]); - child_tidptr = compat_ptr(regs.gprs[5]); + parent_tidptr = (int *) (regs.gprs[4] & 0x7fffffffUL); + child_tidptr = (int *) (regs.gprs[5] & 0x7fffffffUL); if (!newsp) newsp = regs.gprs[15]; return do_fork(clone_flags, newsp, ®s, 0, diff --git a/trunk/arch/s390/kernel/compat_signal.c b/trunk/arch/s390/kernel/compat_signal.c index 5291b5f8788d..fa2b3bc22f20 100644 --- a/trunk/arch/s390/kernel/compat_signal.c +++ b/trunk/arch/s390/kernel/compat_signal.c @@ -1,7 +1,8 @@ /* - * arch/s390/kernel/compat_signal.c + * arch/s390/kernel/signal32.c * - * Copyright (C) IBM Corp. 2000,2006 + * S390 version + * Copyright (C) 2000 IBM Deutschland Entwicklung GmbH, IBM Corporation * Author(s): Denis Joseph Barrow (djbarrow@de.ibm.com,barrow_dj@yahoo.com) * Gerhard Tonn (ton@de.ibm.com) * @@ -51,6 +52,8 @@ typedef struct struct ucontext32 uc; } rt_sigframe32; +asmlinkage int FASTCALL(do_signal(struct pt_regs *regs, sigset_t *oldset)); + int copy_siginfo_to_user32(compat_siginfo_t __user *to, siginfo_t *from) { int err; @@ -158,6 +161,66 @@ int copy_siginfo_from_user32(siginfo_t *to, compat_siginfo_t __user *from) return err; } +/* + * Atomically swap in the new signal mask, and wait for a signal. + */ +asmlinkage int +sys32_sigsuspend(struct pt_regs * regs,int history0, int history1, old_sigset_t mask) +{ + sigset_t saveset; + + mask &= _BLOCKABLE; + spin_lock_irq(¤t->sighand->siglock); + saveset = current->blocked; + siginitset(¤t->blocked, mask); + recalc_sigpending(); + spin_unlock_irq(¤t->sighand->siglock); + regs->gprs[2] = -EINTR; + + while (1) { + set_current_state(TASK_INTERRUPTIBLE); + schedule(); + if (do_signal(regs, &saveset)) + return -EINTR; + } +} + +asmlinkage int +sys32_rt_sigsuspend(struct pt_regs * regs, compat_sigset_t __user *unewset, + size_t sigsetsize) +{ + sigset_t saveset, newset; + compat_sigset_t set32; + + /* XXX: Don't preclude handling different sized sigset_t's. */ + if (sigsetsize != sizeof(sigset_t)) + return -EINVAL; + + if (copy_from_user(&set32, unewset, sizeof(set32))) + return -EFAULT; + switch (_NSIG_WORDS) { + case 4: newset.sig[3] = set32.sig[6] + (((long)set32.sig[7]) << 32); + case 3: newset.sig[2] = set32.sig[4] + (((long)set32.sig[5]) << 32); + case 2: newset.sig[1] = set32.sig[2] + (((long)set32.sig[3]) << 32); + case 1: newset.sig[0] = set32.sig[0] + (((long)set32.sig[1]) << 32); + } + sigdelsetmask(&newset, ~_BLOCKABLE); + + spin_lock_irq(¤t->sighand->siglock); + saveset = current->blocked; + current->blocked = newset; + recalc_sigpending(); + spin_unlock_irq(¤t->sighand->siglock); + regs->gprs[2] = -EINTR; + + while (1) { + set_current_state(TASK_INTERRUPTIBLE); + schedule(); + if (do_signal(regs, &saveset)) + return -EINTR; + } +} + asmlinkage long sys32_sigaction(int sig, const struct old_sigaction32 __user *act, struct old_sigaction32 __user *oact) @@ -195,6 +258,9 @@ sys32_sigaction(int sig, const struct old_sigaction32 __user *act, return ret; } +int +do_sigaction(int sig, const struct k_sigaction *act, struct k_sigaction *oact); + asmlinkage long sys32_rt_sigaction(int sig, const struct sigaction32 __user *act, struct sigaction32 __user *oact, size_t sigsetsize) @@ -454,7 +520,7 @@ static inline int map_signal(int sig) return sig; } -static int setup_frame32(int sig, struct k_sigaction *ka, +static void setup_frame32(int sig, struct k_sigaction *ka, sigset_t *set, struct pt_regs * regs) { sigframe32 __user *frame = get_sigframe(ka, regs, sizeof(sigframe32)); @@ -499,14 +565,13 @@ static int setup_frame32(int sig, struct k_sigaction *ka, /* Place signal number on stack to allow backtrace from handler. */ if (__put_user(regs->gprs[2], (int __user *) &frame->signo)) goto give_sigsegv; - return 0; + return; give_sigsegv: force_sigsegv(sig, current); - return -EFAULT; } -static int setup_rt_frame32(int sig, struct k_sigaction *ka, siginfo_t *info, +static void setup_rt_frame32(int sig, struct k_sigaction *ka, siginfo_t *info, sigset_t *set, struct pt_regs * regs) { int err = 0; @@ -550,37 +615,31 @@ static int setup_rt_frame32(int sig, struct k_sigaction *ka, siginfo_t *info, regs->gprs[2] = map_signal(sig); regs->gprs[3] = (__u64) &frame->info; regs->gprs[4] = (__u64) &frame->uc; - return 0; + return; give_sigsegv: force_sigsegv(sig, current); - return -EFAULT; } /* * OK, we're invoking a handler */ -int +void handle_signal32(unsigned long sig, struct k_sigaction *ka, siginfo_t *info, sigset_t *oldset, struct pt_regs * regs) { - int ret; - /* Set up the stack frame */ if (ka->sa.sa_flags & SA_SIGINFO) - ret = setup_rt_frame32(sig, ka, info, oldset, regs); + setup_rt_frame32(sig, ka, info, oldset, regs); else - ret = setup_frame32(sig, ka, oldset, regs); - - if (ret == 0) { - spin_lock_irq(¤t->sighand->siglock); - sigorsets(¤t->blocked,¤t->blocked,&ka->sa.sa_mask); - if (!(ka->sa.sa_flags & SA_NODEFER)) - sigaddset(¤t->blocked,sig); - recalc_sigpending(); - spin_unlock_irq(¤t->sighand->siglock); - } - return ret; + setup_frame32(sig, ka, oldset, regs); + + spin_lock_irq(¤t->sighand->siglock); + sigorsets(¤t->blocked,¤t->blocked,&ka->sa.sa_mask); + if (!(ka->sa.sa_flags & SA_NODEFER)) + sigaddset(¤t->blocked,sig); + recalc_sigpending(); + spin_unlock_irq(¤t->sighand->siglock); } diff --git a/trunk/arch/s390/kernel/compat_wrapper.S b/trunk/arch/s390/kernel/compat_wrapper.S index dd2d6c3e8df8..cfde1905d07d 100644 --- a/trunk/arch/s390/kernel/compat_wrapper.S +++ b/trunk/arch/s390/kernel/compat_wrapper.S @@ -1,8 +1,9 @@ /* -* arch/s390/kernel/compat_wrapper.S +* arch/s390/kernel/sys_wrapper31.S * wrapper for 31 bit compatible system calls. * -* Copyright (C) IBM Corp. 2000,2006 +* S390 version +* Copyright (C) 2000 IBM Deutschland Entwicklung GmbH, IBM Corporation * Author(s): Gerhard Tonn (ton@de.ibm.com), * Thomas Spatzier (tspat@de.ibm.com) */ @@ -287,12 +288,7 @@ sys32_setregid16_wrapper: llgfr %r3,%r3 # __kernel_old_gid_emu31_t jg sys32_setregid16 # branch to system call - .globl sys_sigsuspend_wrapper -sys_sigsuspend_wrapper: - lgfr %r2,%r2 # int - lgfr %r3,%r3 # int - llgfr %r4,%r4 # old_sigset_t - jg sys_sigsuspend +#sys32_sigsuspend_wrapper # done in sigsuspend_glue .globl compat_sys_sigpending_wrapper compat_sys_sigpending_wrapper: @@ -859,11 +855,7 @@ sys32_rt_sigqueueinfo_wrapper: llgtr %r4,%r4 # siginfo_emu31_t * jg sys32_rt_sigqueueinfo # branch to system call - .globl compat_sys_rt_sigsuspend_wrapper -compat_sys_rt_sigsuspend_wrapper: - llgtr %r2,%r2 # compat_sigset_t * - llgfr %r3,%r3 # compat_size_t - jg compat_sys_rt_sigsuspend +#sys32_rt_sigsuspend_wrapper # done in rt_sigsuspend_glue .globl sys32_pread64_wrapper sys32_pread64_wrapper: @@ -1483,127 +1475,3 @@ sys_inotify_rm_watch_wrapper: lgfr %r2,%r2 # int llgfr %r3,%r3 # u32 jg sys_inotify_rm_watch - - .globl compat_sys_openat_wrapper -compat_sys_openat_wrapper: - llgfr %r2,%r2 # unsigned int - llgtr %r3,%r3 # const char * - lgfr %r4,%r4 # int - lgfr %r5,%r5 # int - jg compat_sys_openat - - .globl sys_mkdirat_wrapper -sys_mkdirat_wrapper: - lgfr %r2,%r2 # int - llgtr %r3,%r3 # const char * - lgfr %r4,%r4 # int - jg sys_mkdirat - - .globl sys_mknodat_wrapper -sys_mknodat_wrapper: - lgfr %r2,%r2 # int - llgtr %r3,%r3 # const char * - lgfr %r4,%r4 # int - llgfr %r5,%r5 # unsigned int - jg sys_mknodat - - .globl sys_fchownat_wrapper -sys_fchownat_wrapper: - lgfr %r2,%r2 # int - llgtr %r3,%r3 # const char * - llgfr %r4,%r4 # uid_t - llgfr %r5,%r5 # gid_t - lgfr %r6,%r6 # int - jg sys_fchownat - - .globl compat_sys_futimesat_wrapper -compat_sys_futimesat_wrapper: - llgfr %r2,%r2 # unsigned int - llgtr %r3,%r3 # char * - llgtr %r4,%r4 # struct timeval * - jg compat_sys_futimesat - - .globl sys32_fstatat_wrapper -sys32_fstatat_wrapper: - llgfr %r2,%r2 # unsigned int - llgtr %r3,%r3 # char * - llgtr %r4,%r4 # struct stat64 * - lgfr %r5,%r5 # int - jg sys32_fstatat - - .globl sys_unlinkat_wrapper -sys_unlinkat_wrapper: - lgfr %r2,%r2 # int - llgtr %r3,%r3 # const char * - lgfr %r4,%r4 # int - jg sys_unlinkat - - .globl sys_renameat_wrapper -sys_renameat_wrapper: - lgfr %r2,%r2 # int - llgtr %r3,%r3 # const char * - lgfr %r4,%r4 # int - llgtr %r5,%r5 # const char * - jg sys_renameat - - .globl sys_linkat_wrapper -sys_linkat_wrapper: - lgfr %r2,%r2 # int - llgtr %r3,%r3 # const char * - lgfr %r4,%r4 # int - llgtr %r5,%r5 # const char * - jg sys_linkat - - .globl sys_symlinkat_wrapper -sys_symlinkat_wrapper: - llgtr %r2,%r2 # const char * - lgfr %r3,%r3 # int - llgtr %r4,%r4 # const char * - jg sys_symlinkat - - .globl sys_readlinkat_wrapper -sys_readlinkat_wrapper: - lgfr %r2,%r2 # int - llgtr %r3,%r3 # const char * - llgtr %r4,%r4 # char * - lgfr %r5,%r5 # int - jg sys_readlinkat - - .globl sys_fchmodat_wrapper -sys_fchmodat_wrapper: - lgfr %r2,%r2 # int - llgtr %r3,%r3 # const char * - llgfr %r4,%r4 # mode_t - jg sys_fchmodat - - .globl sys_faccessat_wrapper -sys_faccessat_wrapper: - lgfr %r2,%r2 # int - llgtr %r3,%r3 # const char * - lgfr %r4,%r4 # int - jg sys_faccessat - - .globl compat_sys_pselect6_wrapper -compat_sys_pselect6_wrapper: - lgfr %r2,%r2 # int - llgtr %r3,%r3 # fd_set * - llgtr %r4,%r4 # fd_set * - llgtr %r5,%r5 # fd_set * - llgtr %r6,%r6 # struct timespec * - llgt %r0,164(%r15) # void * - stg %r0,160(%r15) - jg compat_sys_pselect6 - - .globl compat_sys_ppoll_wrapper -compat_sys_ppoll_wrapper: - llgtr %r2,%r2 # struct pollfd * - llgfr %r3,%r3 # unsigned int - llgtr %r4,%r4 # struct timespec * - llgtr %r5,%r5 # const sigset_t * - llgfr %r6,%r6 # size_t - jg compat_sys_ppoll - - .globl sys_unshare_wrapper -sys_unshare_wrapper: - llgfr %r2,%r2 # unsigned long - jg sys_unshare diff --git a/trunk/arch/s390/kernel/entry.S b/trunk/arch/s390/kernel/entry.S index b2448487854c..27b07730b7b8 100644 --- a/trunk/arch/s390/kernel/entry.S +++ b/trunk/arch/s390/kernel/entry.S @@ -2,7 +2,8 @@ * arch/s390/kernel/entry.S * S390 low-level entry points. * - * Copyright (C) IBM Corp. 1999,2006 + * S390 version + * Copyright (C) 1999,2000 IBM Deutschland Entwicklung GmbH, IBM Corporation * Author(s): Martin Schwidefsky (schwidefsky@de.ibm.com), * Hartmut Penner (hp@de.ibm.com), * Denis Joseph Barrow (djbarrow@de.ibm.com,barrow_dj@yahoo.com), @@ -49,10 +50,9 @@ SP_ILC = STACK_FRAME_OVERHEAD + __PT_ILC SP_TRAP = STACK_FRAME_OVERHEAD + __PT_TRAP SP_SIZE = STACK_FRAME_OVERHEAD + __PT_SIZE -_TIF_WORK_SVC = (_TIF_SIGPENDING | _TIF_RESTORE_SIGMASK | _TIF_NEED_RESCHED | \ - _TIF_MCCK_PENDING | _TIF_RESTART_SVC | _TIF_SINGLE_STEP ) -_TIF_WORK_INT = (_TIF_SIGPENDING | _TIF_RESTORE_SIGMASK | _TIF_NEED_RESCHED | \ - _TIF_MCCK_PENDING) +_TIF_WORK_SVC = (_TIF_SIGPENDING | _TIF_NEED_RESCHED | _TIF_MCCK_PENDING | \ + _TIF_RESTART_SVC | _TIF_SINGLE_STEP ) +_TIF_WORK_INT = (_TIF_SIGPENDING | _TIF_NEED_RESCHED | _TIF_MCCK_PENDING) STACK_SHIFT = PAGE_SHIFT + THREAD_ORDER STACK_SIZE = 1 << STACK_SHIFT @@ -251,8 +251,8 @@ sysc_work: bo BASED(sysc_mcck_pending) tm __TI_flags+3(%r9),_TIF_NEED_RESCHED bo BASED(sysc_reschedule) - tm __TI_flags+3(%r9),(_TIF_SIGPENDING | _TIF_RESTORE_SIGMASK) - bnz BASED(sysc_sigpending) + tm __TI_flags+3(%r9),_TIF_SIGPENDING + bo BASED(sysc_sigpending) tm __TI_flags+3(%r9),_TIF_RESTART_SVC bo BASED(sysc_restart) tm __TI_flags+3(%r9),_TIF_SINGLE_STEP @@ -276,11 +276,12 @@ sysc_mcck_pending: br %r1 # TIF bit will be cleared by handler # -# _TIF_SIGPENDING or _TIF_RESTORE_SIGMASK is set, call do_signal +# _TIF_SIGPENDING is set, call do_signal # sysc_sigpending: ni __TI_flags+3(%r9),255-_TIF_SINGLE_STEP # clear TIF_SINGLE_STEP la %r2,SP_PTREGS(%r15) # load pt_regs + sr %r3,%r3 # clear *oldset l %r1,BASED(.Ldo_signal) basr %r14,%r1 # call do_signal tm __TI_flags+3(%r9),_TIF_RESTART_SVC @@ -396,6 +397,30 @@ sys_rt_sigreturn_glue: l %r1,BASED(.Lrt_sigreturn) br %r1 # branch to sys_sigreturn +# +# sigsuspend and rt_sigsuspend need pt_regs as an additional +# parameter and they have to skip the store of %r2 into the +# user register %r2 because the return value was set in +# sigsuspend and rt_sigsuspend already and must not be overwritten! +# + +sys_sigsuspend_glue: + lr %r5,%r4 # move mask back + lr %r4,%r3 # move history1 parameter + lr %r3,%r2 # move history0 parameter + la %r2,SP_PTREGS(%r15) # load pt_regs as first parameter + l %r1,BASED(.Lsigsuspend) + la %r14,4(%r14) # skip store of return value + br %r1 # branch to sys_sigsuspend + +sys_rt_sigsuspend_glue: + lr %r4,%r3 # move sigsetsize parameter + lr %r3,%r2 # move unewset parameter + la %r2,SP_PTREGS(%r15) # load pt_regs as first parameter + l %r1,BASED(.Lrt_sigsuspend) + la %r14,4(%r14) # skip store of return value + br %r1 # branch to sys_rt_sigsuspend + sys_sigaltstack_glue: la %r4,SP_PTREGS(%r15) # load pt_regs as parameter l %r1,BASED(.Lsigaltstack) @@ -579,16 +604,15 @@ io_work: lr %r15,%r1 # # One of the work bits is on. Find out which one. -# Checked are: _TIF_SIGPENDING, _TIF_RESTORE_SIGMASK, _TIF_NEED_RESCHED -# and _TIF_MCCK_PENDING +# Checked are: _TIF_SIGPENDING, _TIF_NEED_RESCHED and _TIF_MCCK_PENDING # io_work_loop: tm __TI_flags+3(%r9),_TIF_MCCK_PENDING bo BASED(io_mcck_pending) tm __TI_flags+3(%r9),_TIF_NEED_RESCHED bo BASED(io_reschedule) - tm __TI_flags+3(%r9),(_TIF_SIGPENDING | _TIF_RESTORE_SIGMASK) - bnz BASED(io_sigpending) + tm __TI_flags+3(%r9),_TIF_SIGPENDING + bo BASED(io_sigpending) b BASED(io_leave) # @@ -612,11 +636,12 @@ io_reschedule: b BASED(io_work_loop) # -# _TIF_SIGPENDING or _TIF_RESTORE_SIGMASK is set, call do_signal +# _TIF_SIGPENDING is set, call do_signal # io_sigpending: stosm __SF_EMPTY(%r15),0x03 # reenable interrupts la %r2,SP_PTREGS(%r15) # load pt_regs + sr %r3,%r3 # clear *oldset l %r1,BASED(.Ldo_signal) basr %r14,%r1 # call do_signal stnsm __SF_EMPTY(%r15),0xfc # disable I/O and ext. interrupts diff --git a/trunk/arch/s390/kernel/entry64.S b/trunk/arch/s390/kernel/entry64.S index 2ac095bc0e25..369ab4413ec7 100644 --- a/trunk/arch/s390/kernel/entry64.S +++ b/trunk/arch/s390/kernel/entry64.S @@ -1,8 +1,9 @@ /* - * arch/s390/kernel/entry64.S + * arch/s390/kernel/entry.S * S390 low-level entry points. * - * Copyright (C) IBM Corp. 1999,2006 + * S390 version + * Copyright (C) 1999,2000 IBM Deutschland Entwicklung GmbH, IBM Corporation * Author(s): Martin Schwidefsky (schwidefsky@de.ibm.com), * Hartmut Penner (hp@de.ibm.com), * Denis Joseph Barrow (djbarrow@de.ibm.com,barrow_dj@yahoo.com), @@ -52,10 +53,9 @@ SP_SIZE = STACK_FRAME_OVERHEAD + __PT_SIZE STACK_SHIFT = PAGE_SHIFT + THREAD_ORDER STACK_SIZE = 1 << STACK_SHIFT -_TIF_WORK_SVC = (_TIF_SIGPENDING | _TIF_RESTORE_SIGMASK | _TIF_NEED_RESCHED | \ - _TIF_MCCK_PENDING | _TIF_RESTART_SVC | _TIF_SINGLE_STEP ) -_TIF_WORK_INT = (_TIF_SIGPENDING | _TIF_RESTORE_SIGMASK | _TIF_NEED_RESCHED | \ - _TIF_MCCK_PENDING) +_TIF_WORK_SVC = (_TIF_SIGPENDING | _TIF_NEED_RESCHED | _TIF_MCCK_PENDING | \ + _TIF_RESTART_SVC | _TIF_SINGLE_STEP ) +_TIF_WORK_INT = (_TIF_SIGPENDING | _TIF_NEED_RESCHED | _TIF_MCCK_PENDING) #define BASED(name) name-system_call(%r13) @@ -249,8 +249,8 @@ sysc_work: jo sysc_mcck_pending tm __TI_flags+7(%r9),_TIF_NEED_RESCHED jo sysc_reschedule - tm __TI_flags+7(%r9),(_TIF_SIGPENDING | _TIF_RESTORE_SIGMASK) - jnz sysc_sigpending + tm __TI_flags+7(%r9),_TIF_SIGPENDING + jo sysc_sigpending tm __TI_flags+7(%r9),_TIF_RESTART_SVC jo sysc_restart tm __TI_flags+7(%r9),_TIF_SINGLE_STEP @@ -272,11 +272,12 @@ sysc_mcck_pending: jg s390_handle_mcck # TIF bit will be cleared by handler # -# _TIF_SIGPENDING or _TIF_RESTORE_SIGMASK is set, call do_signal +# _TIF_SIGPENDING is set, call do_signal # sysc_sigpending: ni __TI_flags+7(%r9),255-_TIF_SINGLE_STEP # clear TIF_SINGLE_STEP la %r2,SP_PTREGS(%r15) # load pt_regs + sgr %r3,%r3 # clear *oldset brasl %r14,do_signal # call do_signal tm __TI_flags+7(%r9),_TIF_RESTART_SVC jo sysc_restart @@ -413,6 +414,52 @@ sys32_rt_sigreturn_glue: jg sys32_rt_sigreturn # branch to sys32_sigreturn #endif +# +# sigsuspend and rt_sigsuspend need pt_regs as an additional +# parameter and they have to skip the store of %r2 into the +# user register %r2 because the return value was set in +# sigsuspend and rt_sigsuspend already and must not be overwritten! +# + +sys_sigsuspend_glue: + lgr %r5,%r4 # move mask back + lgr %r4,%r3 # move history1 parameter + lgr %r3,%r2 # move history0 parameter + la %r2,SP_PTREGS(%r15) # load pt_regs as first parameter + la %r14,6(%r14) # skip store of return value + jg sys_sigsuspend # branch to sys_sigsuspend + +#ifdef CONFIG_COMPAT +sys32_sigsuspend_glue: + llgfr %r4,%r4 # unsigned long + lgr %r5,%r4 # move mask back + lgfr %r3,%r3 # int + lgr %r4,%r3 # move history1 parameter + lgfr %r2,%r2 # int + lgr %r3,%r2 # move history0 parameter + la %r2,SP_PTREGS(%r15) # load pt_regs as first parameter + la %r14,6(%r14) # skip store of return value + jg sys32_sigsuspend # branch to sys32_sigsuspend +#endif + +sys_rt_sigsuspend_glue: + lgr %r4,%r3 # move sigsetsize parameter + lgr %r3,%r2 # move unewset parameter + la %r2,SP_PTREGS(%r15) # load pt_regs as first parameter + la %r14,6(%r14) # skip store of return value + jg sys_rt_sigsuspend # branch to sys_rt_sigsuspend + +#ifdef CONFIG_COMPAT +sys32_rt_sigsuspend_glue: + llgfr %r3,%r3 # size_t + lgr %r4,%r3 # move sigsetsize parameter + llgtr %r2,%r2 # sigset_emu31_t * + lgr %r3,%r2 # move unewset parameter + la %r2,SP_PTREGS(%r15) # load pt_regs as first parameter + la %r14,6(%r14) # skip store of return value + jg sys32_rt_sigsuspend # branch to sys32_rt_sigsuspend +#endif + sys_sigaltstack_glue: la %r4,SP_PTREGS(%r15) # load pt_regs as parameter jg sys_sigaltstack # branch to sys_sigreturn @@ -599,16 +646,15 @@ io_work: lgr %r15,%r1 # # One of the work bits is on. Find out which one. -# Checked are: _TIF_SIGPENDING, _TIF_RESTORE_SIGPENDING, _TIF_NEED_RESCHED -# and _TIF_MCCK_PENDING +# Checked are: _TIF_SIGPENDING, _TIF_NEED_RESCHED and _TIF_MCCK_PENDING # io_work_loop: tm __TI_flags+7(%r9),_TIF_MCCK_PENDING jo io_mcck_pending tm __TI_flags+7(%r9),_TIF_NEED_RESCHED jo io_reschedule - tm __TI_flags+7(%r9),(_TIF_SIGPENDING | _TIF_RESTORE_SIGMASK) - jnz io_sigpending + tm __TI_flags+7(%r9),_TIF_SIGPENDING + jo io_sigpending j io_leave # @@ -630,11 +676,12 @@ io_reschedule: j io_work_loop # -# _TIF_SIGPENDING or _TIF_RESTORE_SIGMASK is set, call do_signal +# _TIF_SIGPENDING is set, call do_signal # io_sigpending: stosm __SF_EMPTY(%r15),0x03 # reenable interrupts la %r2,SP_PTREGS(%r15) # load pt_regs + slgr %r3,%r3 # clear *oldset brasl %r14,do_signal # call do_signal stnsm __SF_EMPTY(%r15),0xfc # disable I/O and ext. interrupts j io_work_loop diff --git a/trunk/arch/s390/kernel/machine_kexec.c b/trunk/arch/s390/kernel/machine_kexec.c index bad81b5832db..f0ed5c642c74 100644 --- a/trunk/arch/s390/kernel/machine_kexec.c +++ b/trunk/arch/s390/kernel/machine_kexec.c @@ -12,16 +12,15 @@ * on the S390 architecture. */ +#include +#include #include #include #include #include -#include -#include #include #include #include -#include static void kexec_halt_all_cpus(void *); diff --git a/trunk/arch/s390/kernel/signal.c b/trunk/arch/s390/kernel/signal.c index ae1927e48cfb..6ae4a77270b5 100644 --- a/trunk/arch/s390/kernel/signal.c +++ b/trunk/arch/s390/kernel/signal.c @@ -1,7 +1,8 @@ /* * arch/s390/kernel/signal.c * - * Copyright (C) IBM Corp. 1999,2006 + * S390 version + * Copyright (C) 1999,2000 IBM Deutschland Entwicklung GmbH, IBM Corporation * Author(s): Denis Joseph Barrow (djbarrow@de.ibm.com,barrow_dj@yahoo.com) * * Based on Intel version @@ -50,24 +51,60 @@ typedef struct struct ucontext uc; } rt_sigframe; +int do_signal(struct pt_regs *regs, sigset_t *oldset); + /* * Atomically swap in the new signal mask, and wait for a signal. */ asmlinkage int -sys_sigsuspend(int history0, int history1, old_sigset_t mask) +sys_sigsuspend(struct pt_regs * regs, int history0, int history1, + old_sigset_t mask) { + sigset_t saveset; + mask &= _BLOCKABLE; spin_lock_irq(¤t->sighand->siglock); - current->saved_sigmask = current->blocked; + saveset = current->blocked; siginitset(¤t->blocked, mask); recalc_sigpending(); spin_unlock_irq(¤t->sighand->siglock); + regs->gprs[2] = -EINTR; + + while (1) { + set_current_state(TASK_INTERRUPTIBLE); + schedule(); + if (do_signal(regs, &saveset)) + return -EINTR; + } +} + +asmlinkage long +sys_rt_sigsuspend(struct pt_regs *regs, sigset_t __user *unewset, + size_t sigsetsize) +{ + sigset_t saveset, newset; - current->state = TASK_INTERRUPTIBLE; - schedule(); - set_thread_flag(TIF_RESTORE_SIGMASK); + /* XXX: Don't preclude handling different sized sigset_t's. */ + if (sigsetsize != sizeof(sigset_t)) + return -EINVAL; - return -ERESTARTNOHAND; + if (copy_from_user(&newset, unewset, sizeof(newset))) + return -EFAULT; + sigdelsetmask(&newset, ~_BLOCKABLE); + + spin_lock_irq(¤t->sighand->siglock); + saveset = current->blocked; + current->blocked = newset; + recalc_sigpending(); + spin_unlock_irq(¤t->sighand->siglock); + regs->gprs[2] = -EINTR; + + while (1) { + set_current_state(TASK_INTERRUPTIBLE); + schedule(); + if (do_signal(regs, &saveset)) + return -EINTR; + } } asmlinkage long @@ -269,8 +306,8 @@ static inline int map_signal(int sig) return sig; } -static int setup_frame(int sig, struct k_sigaction *ka, - sigset_t *set, struct pt_regs * regs) +static void setup_frame(int sig, struct k_sigaction *ka, + sigset_t *set, struct pt_regs * regs) { sigframe __user *frame; @@ -318,14 +355,13 @@ static int setup_frame(int sig, struct k_sigaction *ka, /* Place signal number on stack to allow backtrace from handler. */ if (__put_user(regs->gprs[2], (int __user *) &frame->signo)) goto give_sigsegv; - return 0; + return; give_sigsegv: force_sigsegv(sig, current); - return -EFAULT; } -static int setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info, +static void setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info, sigset_t *set, struct pt_regs * regs) { int err = 0; @@ -373,39 +409,32 @@ static int setup_rt_frame(int sig, struct k_sigaction *ka, siginfo_t *info, regs->gprs[2] = map_signal(sig); regs->gprs[3] = (unsigned long) &frame->info; regs->gprs[4] = (unsigned long) &frame->uc; - return 0; + return; give_sigsegv: force_sigsegv(sig, current); - return -EFAULT; } /* * OK, we're invoking a handler */ -static int +static void handle_signal(unsigned long sig, struct k_sigaction *ka, siginfo_t *info, sigset_t *oldset, struct pt_regs * regs) { - int ret; - /* Set up the stack frame */ if (ka->sa.sa_flags & SA_SIGINFO) - ret = setup_rt_frame(sig, ka, info, oldset, regs); + setup_rt_frame(sig, ka, info, oldset, regs); else - ret = setup_frame(sig, ka, oldset, regs); - - if (ret == 0) { - spin_lock_irq(¤t->sighand->siglock); - sigorsets(¤t->blocked,¤t->blocked,&ka->sa.sa_mask); - if (!(ka->sa.sa_flags & SA_NODEFER)) - sigaddset(¤t->blocked,sig); - recalc_sigpending(); - spin_unlock_irq(¤t->sighand->siglock); - } + setup_frame(sig, ka, oldset, regs); - return ret; + spin_lock_irq(¤t->sighand->siglock); + sigorsets(¤t->blocked,¤t->blocked,&ka->sa.sa_mask); + if (!(ka->sa.sa_flags & SA_NODEFER)) + sigaddset(¤t->blocked,sig); + recalc_sigpending(); + spin_unlock_irq(¤t->sighand->siglock); } /* @@ -417,13 +446,12 @@ handle_signal(unsigned long sig, struct k_sigaction *ka, * the kernel can handle, and then we build all the user-level signal handling * stack-frames in one go after that. */ -void do_signal(struct pt_regs *regs) +int do_signal(struct pt_regs *regs, sigset_t *oldset) { unsigned long retval = 0, continue_addr = 0, restart_addr = 0; siginfo_t info; int signr; struct k_sigaction ka; - sigset_t *oldset; /* * We want the common case to go fast, which @@ -432,11 +460,9 @@ void do_signal(struct pt_regs *regs) * if so. */ if (!user_mode(regs)) - return; + return 1; - if (test_thread_flag(TIF_RESTORE_SIGMASK)) - oldset = ¤t->saved_sigmask; - else + if (!oldset) oldset = ¤t->blocked; /* Are we from a system call? */ @@ -447,14 +473,12 @@ void do_signal(struct pt_regs *regs) /* Prepare for system call restart. We do this here so that a debugger will see the already changed PSW. */ - switch (retval) { - case -ERESTARTNOHAND: - case -ERESTARTSYS: - case -ERESTARTNOINTR: + if (retval == -ERESTARTNOHAND || + retval == -ERESTARTSYS || + retval == -ERESTARTNOINTR) { regs->gprs[2] = regs->orig_gpr2; regs->psw.addr = restart_addr; - break; - case -ERESTART_RESTARTBLOCK: + } else if (retval == -ERESTART_RESTARTBLOCK) { regs->gprs[2] = -EINTR; } } @@ -479,38 +503,17 @@ void do_signal(struct pt_regs *regs) /* Whee! Actually deliver the signal. */ #ifdef CONFIG_COMPAT if (test_thread_flag(TIF_31BIT)) { - extern int handle_signal32(unsigned long sig, - struct k_sigaction *ka, - siginfo_t *info, - sigset_t *oldset, - struct pt_regs *regs); - if (handle_signal32( - signr, &ka, &info, oldset, regs) == 0) { - if (test_thread_flag(TIF_RESTORE_SIGMASK)) - clear_thread_flag(TIF_RESTORE_SIGMASK); - } - return; + extern void handle_signal32(unsigned long sig, + struct k_sigaction *ka, + siginfo_t *info, + sigset_t *oldset, + struct pt_regs *regs); + handle_signal32(signr, &ka, &info, oldset, regs); + return 1; } #endif - if (handle_signal(signr, &ka, &info, oldset, regs) == 0) { - /* - * A signal was successfully delivered; the saved - * sigmask will have been stored in the signal frame, - * and will be restored by sigreturn, so we can simply - * clear the TIF_RESTORE_SIGMASK flag. - */ - if (test_thread_flag(TIF_RESTORE_SIGMASK)) - clear_thread_flag(TIF_RESTORE_SIGMASK); - } - return; - } - - /* - * If there's no signal to deliver, we just put the saved sigmask back. - */ - if (test_thread_flag(TIF_RESTORE_SIGMASK)) { - clear_thread_flag(TIF_RESTORE_SIGMASK); - sigprocmask(SIG_SETMASK, ¤t->saved_sigmask, NULL); + handle_signal(signr, &ka, &info, oldset, regs); + return 1; } /* Restart a different system call. */ @@ -519,4 +522,5 @@ void do_signal(struct pt_regs *regs) regs->gprs[2] = __NR_restart_syscall; set_thread_flag(TIF_RESTART_SVC); } + return 0; } diff --git a/trunk/arch/s390/kernel/smp.c b/trunk/arch/s390/kernel/smp.c index 0d1ad5dbe2b1..cbfcfd02a43a 100644 --- a/trunk/arch/s390/kernel/smp.c +++ b/trunk/arch/s390/kernel/smp.c @@ -52,7 +52,7 @@ extern volatile int __cpu_logical_map[]; struct _lowcore *lowcore_ptr[NR_CPUS]; cpumask_t cpu_online_map; -cpumask_t cpu_possible_map = CPU_MASK_ALL; +cpumask_t cpu_possible_map; static struct task_struct *current_set[NR_CPUS]; @@ -514,6 +514,9 @@ __init smp_check_cpus(unsigned int max_cpus) num_cpus++; } + for (cpu = 1; cpu < max_cpus; cpu++) + cpu_set(cpu, cpu_possible_map); + printk("Detected %d CPU's\n",(int) num_cpus); printk("Boot cpu address %2X\n", boot_cpu_addr); } @@ -807,6 +810,7 @@ void __devinit smp_prepare_boot_cpu(void) cpu_set(0, cpu_online_map); cpu_set(0, cpu_present_map); + cpu_set(0, cpu_possible_map); S390_lowcore.percpu_offset = __per_cpu_offset[0]; current_set[0] = current; } diff --git a/trunk/arch/s390/kernel/sys_s390.c b/trunk/arch/s390/kernel/sys_s390.c index e351780bb660..6a63553493c5 100644 --- a/trunk/arch/s390/kernel/sys_s390.c +++ b/trunk/arch/s390/kernel/sys_s390.c @@ -122,8 +122,8 @@ asmlinkage long old_mmap(struct mmap_arg_struct __user *arg) #ifndef CONFIG_64BIT struct sel_arg_struct { unsigned long n; - fd_set __user *inp, *outp, *exp; - struct timeval __user *tvp; + fd_set *inp, *outp, *exp; + struct timeval *tvp; }; asmlinkage long old_select(struct sel_arg_struct __user *arg) diff --git a/trunk/arch/s390/kernel/syscalls.S b/trunk/arch/s390/kernel/syscalls.S index 84921fe8d266..426d7cafdab3 100644 --- a/trunk/arch/s390/kernel/syscalls.S +++ b/trunk/arch/s390/kernel/syscalls.S @@ -80,7 +80,7 @@ NI_SYSCALL /* old sgetmask syscall*/ NI_SYSCALL /* old ssetmask syscall*/ SYSCALL(sys_setreuid16,sys_ni_syscall,sys32_setreuid16_wrapper) /* old setreuid16 syscall */ SYSCALL(sys_setregid16,sys_ni_syscall,sys32_setregid16_wrapper) /* old setregid16 syscall */ -SYSCALL(sys_sigsuspend,sys_sigsuspend,sys_sigsuspend_wrapper) +SYSCALL(sys_sigsuspend_glue,sys_sigsuspend_glue,sys32_sigsuspend_glue) SYSCALL(sys_sigpending,sys_sigpending,compat_sys_sigpending_wrapper) SYSCALL(sys_sethostname,sys_sethostname,sys32_sethostname_wrapper) SYSCALL(sys_setrlimit,sys_setrlimit,compat_sys_setrlimit_wrapper) /* 75 */ @@ -187,7 +187,7 @@ SYSCALL(sys_rt_sigprocmask,sys_rt_sigprocmask,sys32_rt_sigprocmask_wrapper) /* 1 SYSCALL(sys_rt_sigpending,sys_rt_sigpending,sys32_rt_sigpending_wrapper) SYSCALL(sys_rt_sigtimedwait,sys_rt_sigtimedwait,compat_sys_rt_sigtimedwait_wrapper) SYSCALL(sys_rt_sigqueueinfo,sys_rt_sigqueueinfo,sys32_rt_sigqueueinfo_wrapper) -SYSCALL(sys_rt_sigsuspend,sys_rt_sigsuspend,compat_sys_rt_sigsuspend_wrapper) +SYSCALL(sys_rt_sigsuspend_glue,sys_rt_sigsuspend_glue,sys32_rt_sigsuspend_glue) SYSCALL(sys_pread64,sys_pread64,sys32_pread64_wrapper) /* 180 */ SYSCALL(sys_pwrite64,sys_pwrite64,sys32_pwrite64_wrapper) SYSCALL(sys_chown16,sys_ni_syscall,sys32_chown16_wrapper) /* old chown16 syscall */ @@ -293,22 +293,5 @@ SYSCALL(sys_waitid,sys_waitid,compat_sys_waitid_wrapper) SYSCALL(sys_ioprio_set,sys_ioprio_set,sys_ioprio_set_wrapper) SYSCALL(sys_ioprio_get,sys_ioprio_get,sys_ioprio_get_wrapper) SYSCALL(sys_inotify_init,sys_inotify_init,sys_inotify_init) -SYSCALL(sys_inotify_add_watch,sys_inotify_add_watch,sys_inotify_add_watch_wrapper) /* 285 */ +SYSCALL(sys_inotify_add_watch,sys_inotify_add_watch,sys_inotify_add_watch_wrapper) SYSCALL(sys_inotify_rm_watch,sys_inotify_rm_watch,sys_inotify_rm_watch_wrapper) -NI_SYSCALL /* 287 sys_migrate_pages */ -SYSCALL(sys_openat,sys_openat,compat_sys_openat_wrapper) -SYSCALL(sys_mkdirat,sys_mkdirat,sys_mkdirat_wrapper) -SYSCALL(sys_mknodat,sys_mknodat,sys_mknodat_wrapper) /* 290 */ -SYSCALL(sys_fchownat,sys_fchownat,sys_fchownat_wrapper) -SYSCALL(sys_futimesat,sys_futimesat,compat_sys_futimesat_wrapper) -SYSCALL(sys_fstatat64,sys_newfstatat,sys32_fstatat_wrapper) -SYSCALL(sys_unlinkat,sys_unlinkat,sys_unlinkat_wrapper) -SYSCALL(sys_renameat,sys_renameat,sys_renameat_wrapper) /* 295 */ -SYSCALL(sys_linkat,sys_linkat,sys_linkat_wrapper) -SYSCALL(sys_symlinkat,sys_symlinkat,sys_symlinkat_wrapper) -SYSCALL(sys_readlinkat,sys_readlinkat,sys_readlinkat_wrapper) -SYSCALL(sys_fchmodat,sys_fchmodat,sys_fchmodat_wrapper) -SYSCALL(sys_faccessat,sys_faccessat,sys_faccessat_wrapper) /* 300 */ -SYSCALL(sys_pselect6,sys_pselect6,compat_sys_pselect6_wrapper) -SYSCALL(sys_ppoll,sys_ppoll,compat_sys_ppoll_wrapper) -SYSCALL(sys_unshare,sys_unshare,sys_unshare_wrapper) diff --git a/trunk/arch/s390/kernel/time.c b/trunk/arch/s390/kernel/time.c index fea043b69b91..7c0fe152a111 100644 --- a/trunk/arch/s390/kernel/time.c +++ b/trunk/arch/s390/kernel/time.c @@ -61,18 +61,9 @@ extern unsigned long wall_jiffies; */ unsigned long long sched_clock(void) { - return ((get_clock() - jiffies_timer_cc) * 125) >> 9; + return ((get_clock() - jiffies_timer_cc) * 1000) >> 12; } -/* - * Monotonic_clock - returns # of nanoseconds passed since time_init() - */ -unsigned long long monotonic_clock(void) -{ - return sched_clock(); -} -EXPORT_SYMBOL(monotonic_clock); - void tod_to_timeval(__u64 todval, struct timespec *xtime) { unsigned long long sec; diff --git a/trunk/arch/s390/kernel/traps.c b/trunk/arch/s390/kernel/traps.c index a46793beeddd..5d21e9e6e7b4 100644 --- a/trunk/arch/s390/kernel/traps.c +++ b/trunk/arch/s390/kernel/traps.c @@ -486,7 +486,7 @@ asmlinkage void illegal_op(struct pt_regs * regs, long interruption_code) info.si_signo = signal; info.si_errno = 0; info.si_code = ILL_ILLOPC; - info.si_addr = (void __user *) location; + info.si_addr = (void *) location; do_trap(interruption_code, signal, "illegal operation", regs, &info); } diff --git a/trunk/arch/s390/lib/Makefile b/trunk/arch/s390/lib/Makefile index e05d087a6eae..f20b51ff1d86 100644 --- a/trunk/arch/s390/lib/Makefile +++ b/trunk/arch/s390/lib/Makefile @@ -6,4 +6,4 @@ EXTRA_AFLAGS := -traditional lib-y += delay.o string.o lib-y += $(if $(CONFIG_64BIT),uaccess64.o,uaccess.o) -lib-$(CONFIG_SMP) += spinlock.o +lib-$(CONFIG_SMP) += spinlock.o \ No newline at end of file diff --git a/trunk/arch/s390/mm/cmm.c b/trunk/arch/s390/mm/cmm.c index b075ab499d05..2d5cb1385753 100644 --- a/trunk/arch/s390/mm/cmm.c +++ b/trunk/arch/s390/mm/cmm.c @@ -42,8 +42,8 @@ static volatile long cmm_timed_pages_target = 0; static long cmm_timeout_pages = 0; static long cmm_timeout_seconds = 0; -static struct cmm_page_array *cmm_page_list = NULL; -static struct cmm_page_array *cmm_timed_page_list = NULL; +static struct cmm_page_array *cmm_page_list = 0; +static struct cmm_page_array *cmm_timed_page_list = 0; static unsigned long cmm_thread_active = 0; static struct work_struct cmm_thread_starter; @@ -259,7 +259,7 @@ static struct ctl_table cmm_table[]; static int cmm_pages_handler(ctl_table *ctl, int write, struct file *filp, - void __user *buffer, size_t *lenp, loff_t *ppos) + void *buffer, size_t *lenp, loff_t *ppos) { char buf[16], *p; long pages; @@ -300,7 +300,7 @@ cmm_pages_handler(ctl_table *ctl, int write, struct file *filp, static int cmm_timeout_handler(ctl_table *ctl, int write, struct file *filp, - void __user *buffer, size_t *lenp, loff_t *ppos) + void *buffer, size_t *lenp, loff_t *ppos) { char buf[64], *p; long pages, seconds; @@ -419,7 +419,7 @@ cmm_init (void) #ifdef CONFIG_CMM_IUCV smsg_register_callback(SMSG_PREFIX, cmm_smsg_target); #endif - INIT_WORK(&cmm_thread_starter, (void *) cmm_start_thread, NULL); + INIT_WORK(&cmm_thread_starter, (void *) cmm_start_thread, 0); init_waitqueue_head(&cmm_thread_wait); init_timer(&cmm_timer); return 0; diff --git a/trunk/arch/sh/Kconfig b/trunk/arch/sh/Kconfig index 504d56f8ca7f..01bc7d589afe 100644 --- a/trunk/arch/sh/Kconfig +++ b/trunk/arch/sh/Kconfig @@ -396,8 +396,14 @@ source "arch/sh/boards/renesas/hs7751rvoip/Kconfig" source "arch/sh/boards/renesas/rts7751r2d/Kconfig" +config SH_PCLK_FREQ_BOOL + bool "Set default pclk frequency" + default y if !SH_RTC + default n + config SH_PCLK_FREQ int "Peripheral clock frequency (in Hz)" + depends on SH_PCLK_FREQ_BOOL default "50000000" if CPU_SUBTYPE_SH7750 || CPU_SUBTYPE_SH7780 default "60000000" if CPU_SUBTYPE_SH7751 default "33333333" if CPU_SUBTYPE_SH7300 || CPU_SUBTYPE_SH7770 || CPU_SUBTYPE_SH7760 diff --git a/trunk/arch/sh/boards/renesas/rts7751r2d/io.c b/trunk/arch/sh/boards/renesas/rts7751r2d/io.c index 123abbbc91e0..c46f9154cfd5 100644 --- a/trunk/arch/sh/boards/renesas/rts7751r2d/io.c +++ b/trunk/arch/sh/boards/renesas/rts7751r2d/io.c @@ -216,26 +216,24 @@ void rts7751r2d_insb(unsigned long port, void *addr, unsigned long count) { volatile __u8 *bp; volatile __u16 *p; - unsigned char *s = addr; if (CHECK_AX88796L_PORT(port)) { p = (volatile unsigned short *)port88796l(port, 0); - while (count--) *s++ = *p & 0xff; + while (count--) *((unsigned char *) addr)++ = *p & 0xff; } else if (PXSEG(port)) - while (count--) *s++ = *(volatile unsigned char *)port; + while (count--) *((unsigned char *) addr)++ = *(volatile unsigned char *)port; else if (CHECK_SH7751_PCIIO(port) || shifted_port(port)) { bp = (__u8 *)PCI_IOMAP(port); - while (count--) *s++ = *bp; + while (count--) *((volatile unsigned char *) addr)++ = *bp; } else { p = (volatile unsigned short *)port2adr(port); - while (count--) *s++ = *p & 0xff; + while (count--) *((unsigned char *) addr)++ = *p & 0xff; } } void rts7751r2d_insw(unsigned long port, void *addr, unsigned long count) { volatile __u16 *p; - __u16 *s = addr; if (CHECK_AX88796L_PORT(port)) p = (volatile unsigned short *)port88796l(port, 1); @@ -245,7 +243,7 @@ void rts7751r2d_insw(unsigned long port, void *addr, unsigned long count) p = (volatile unsigned short *)PCI_IOMAP(port); else p = (volatile unsigned short *)port2adr(port); - while (count--) *s++ = *p; + while (count--) *((__u16 *) addr)++ = *p; } void rts7751r2d_insl(unsigned long port, void *addr, unsigned long count) @@ -254,9 +252,8 @@ void rts7751r2d_insl(unsigned long port, void *addr, unsigned long count) maybebadio(insl, port); else if (CHECK_SH7751_PCIIO(port) || shifted_port(port)) { volatile __u32 *p = (__u32 *)PCI_IOMAP(port); - __u32 *s = addr; - while (count--) *s++ = *p; + while (count--) *((__u32 *) addr)++ = *p; } else maybebadio(insl, port); } @@ -265,26 +262,24 @@ void rts7751r2d_outsb(unsigned long port, const void *addr, unsigned long count) { volatile __u8 *bp; volatile __u16 *p; - const __u8 *s = addr; if (CHECK_AX88796L_PORT(port)) { p = (volatile unsigned short *)port88796l(port, 0); - while (count--) *p = *s++; + while (count--) *p = *((unsigned char *) addr)++; } else if (PXSEG(port)) - while (count--) *(volatile unsigned char *)port = *s++; + while (count--) *(volatile unsigned char *)port = *((unsigned char *) addr)++; else if (CHECK_SH7751_PCIIO(port) || shifted_port(port)) { bp = (__u8 *)PCI_IOMAP(port); - while (count--) *bp = *s++; + while (count--) *bp = *((volatile unsigned char *) addr)++; } else { p = (volatile unsigned short *)port2adr(port); - while (count--) *p = *s++; + while (count--) *p = *((unsigned char *) addr)++; } } void rts7751r2d_outsw(unsigned long port, const void *addr, unsigned long count) { volatile __u16 *p; - const __u16 *s = addr; if (CHECK_AX88796L_PORT(port)) p = (volatile unsigned short *)port88796l(port, 1); @@ -294,7 +289,7 @@ void rts7751r2d_outsw(unsigned long port, const void *addr, unsigned long count) p = (volatile unsigned short *)PCI_IOMAP(port); else p = (volatile unsigned short *)port2adr(port); - while (count--) *p = *s++; + while (count--) *p = *((__u16 *) addr)++; } void rts7751r2d_outsl(unsigned long port, const void *addr, unsigned long count) @@ -303,9 +298,8 @@ void rts7751r2d_outsl(unsigned long port, const void *addr, unsigned long count) maybebadio(outsl, port); else if (CHECK_SH7751_PCIIO(port) || shifted_port(port)) { volatile __u32 *p = (__u32 *)PCI_IOMAP(port); - const __u32 *s = addr; - while (count--) *p = *s++; + while (count--) *p = *((__u32 *) addr)++; } else maybebadio(outsl, port); } diff --git a/trunk/arch/sh/boards/superh/microdev/io.c b/trunk/arch/sh/boards/superh/microdev/io.c index 1ed7f880b8c7..fe83b2c03076 100644 --- a/trunk/arch/sh/boards/superh/microdev/io.c +++ b/trunk/arch/sh/boards/superh/microdev/io.c @@ -16,7 +16,7 @@ #include #include #include -#include +#include /* * we need to have a 'safe' address to re-direct all I/O requests @@ -52,91 +52,9 @@ #define IO_ISP1161_PHYS 0xa7700000ul /* Physical address of Philips ISP1161x USB chip */ #define IO_SUPERIO_PHYS 0xa7800000ul /* Physical address of SMSC FDC37C93xAPM SuperIO chip */ -/* - * map I/O ports to memory-mapped addresses - */ -static unsigned long microdev_isa_port2addr(unsigned long offset) -{ - unsigned long result; - - if ((offset >= IO_LAN91C111_BASE) && - (offset < IO_LAN91C111_BASE + IO_LAN91C111_EXTENT)) { - /* - * SMSC LAN91C111 Ethernet chip - */ - result = IO_LAN91C111_PHYS + offset - IO_LAN91C111_BASE; - } else if ((offset >= IO_SUPERIO_BASE) && - (offset < IO_SUPERIO_BASE + IO_SUPERIO_EXTENT)) { - /* - * SMSC FDC37C93xAPM SuperIO chip - * - * Configuration Registers - */ - result = IO_SUPERIO_PHYS + (offset << 1); -#if 0 - } else if (offset == KBD_DATA_REG || offset == KBD_CNTL_REG || - offset == KBD_STATUS_REG) { - /* - * SMSC FDC37C93xAPM SuperIO chip - * - * PS/2 Keyboard + Mouse (ports 0x60 and 0x64). - */ - result = IO_SUPERIO_PHYS + (offset << 1); -#endif - } else if (((offset >= IO_IDE1_BASE) && - (offset < IO_IDE1_BASE + IO_IDE_EXTENT)) || - (offset == IO_IDE1_MISC)) { - /* - * SMSC FDC37C93xAPM SuperIO chip - * - * IDE #1 - */ - result = IO_SUPERIO_PHYS + (offset << 1); - } else if (((offset >= IO_IDE2_BASE) && - (offset < IO_IDE2_BASE + IO_IDE_EXTENT)) || - (offset == IO_IDE2_MISC)) { - /* - * SMSC FDC37C93xAPM SuperIO chip - * - * IDE #2 - */ - result = IO_SUPERIO_PHYS + (offset << 1); - } else if ((offset >= IO_SERIAL1_BASE) && - (offset < IO_SERIAL1_BASE + IO_SERIAL_EXTENT)) { - /* - * SMSC FDC37C93xAPM SuperIO chip - * - * Serial #1 - */ - result = IO_SUPERIO_PHYS + (offset << 1); - } else if ((offset >= IO_SERIAL2_BASE) && - (offset < IO_SERIAL2_BASE + IO_SERIAL_EXTENT)) { - /* - * SMSC FDC37C93xAPM SuperIO chip - * - * Serial #2 - */ - result = IO_SUPERIO_PHYS + (offset << 1); - } else if ((offset >= IO_ISP1161_BASE) && - (offset < IO_ISP1161_BASE + IO_ISP1161_EXTENT)) { - /* - * Philips USB ISP1161x chip - */ - result = IO_ISP1161_PHYS + offset - IO_ISP1161_BASE; - } else { - /* - * safe default. - */ - printk("Warning: unexpected port in %s( offset = 0x%lx )\n", - __FUNCTION__, offset); - result = PVR; - } - - return result; -} - #define PORT2ADDR(x) (microdev_isa_port2addr(x)) + static inline void delay(void) { #if defined(CONFIG_PCI) @@ -176,17 +94,6 @@ unsigned int microdev_inl(unsigned long port) return *(volatile unsigned int*)PORT2ADDR(port); } -void microdev_outw(unsigned short b, unsigned long port) -{ -#ifdef CONFIG_PCI - if (port >= PCIBIOS_MIN_IO) { - microdev_pci_outw(b, port); - return; - } -#endif - *(volatile unsigned short*)PORT2ADDR(port) = b; -} - void microdev_outb(unsigned char b, unsigned long port) { #ifdef CONFIG_PCI @@ -251,6 +158,17 @@ void microdev_outb(unsigned char b, unsigned long port) } } +void microdev_outw(unsigned short b, unsigned long port) +{ +#ifdef CONFIG_PCI + if (port >= PCIBIOS_MIN_IO) { + microdev_pci_outw(b, port); + return; + } +#endif + *(volatile unsigned short*)PORT2ADDR(port) = b; +} + void microdev_outl(unsigned int b, unsigned long port) { #ifdef CONFIG_PCI @@ -366,3 +284,87 @@ void microdev_outsl(unsigned long port, const void *buffer, unsigned long count) while (count--) *port_addr = *buf++; } + +/* + * map I/O ports to memory-mapped addresses + */ +unsigned long microdev_isa_port2addr(unsigned long offset) +{ + unsigned long result; + + if ((offset >= IO_LAN91C111_BASE) && + (offset < IO_LAN91C111_BASE + IO_LAN91C111_EXTENT)) { + /* + * SMSC LAN91C111 Ethernet chip + */ + result = IO_LAN91C111_PHYS + offset - IO_LAN91C111_BASE; + } else if ((offset >= IO_SUPERIO_BASE) && + (offset < IO_SUPERIO_BASE + IO_SUPERIO_EXTENT)) { + /* + * SMSC FDC37C93xAPM SuperIO chip + * + * Configuration Registers + */ + result = IO_SUPERIO_PHYS + (offset << 1); +#if 0 + } else if (offset == KBD_DATA_REG || offset == KBD_CNTL_REG || + offset == KBD_STATUS_REG) { + /* + * SMSC FDC37C93xAPM SuperIO chip + * + * PS/2 Keyboard + Mouse (ports 0x60 and 0x64). + */ + result = IO_SUPERIO_PHYS + (offset << 1); +#endif + } else if (((offset >= IO_IDE1_BASE) && + (offset < IO_IDE1_BASE + IO_IDE_EXTENT)) || + (offset == IO_IDE1_MISC)) { + /* + * SMSC FDC37C93xAPM SuperIO chip + * + * IDE #1 + */ + result = IO_SUPERIO_PHYS + (offset << 1); + } else if (((offset >= IO_IDE2_BASE) && + (offset < IO_IDE2_BASE + IO_IDE_EXTENT)) || + (offset == IO_IDE2_MISC)) { + /* + * SMSC FDC37C93xAPM SuperIO chip + * + * IDE #2 + */ + result = IO_SUPERIO_PHYS + (offset << 1); + } else if ((offset >= IO_SERIAL1_BASE) && + (offset < IO_SERIAL1_BASE + IO_SERIAL_EXTENT)) { + /* + * SMSC FDC37C93xAPM SuperIO chip + * + * Serial #1 + */ + result = IO_SUPERIO_PHYS + (offset << 1); + } else if ((offset >= IO_SERIAL2_BASE) && + (offset < IO_SERIAL2_BASE + IO_SERIAL_EXTENT)) { + /* + * SMSC FDC37C93xAPM SuperIO chip + * + * Serial #2 + */ + result = IO_SUPERIO_PHYS + (offset << 1); + } else if ((offset >= IO_ISP1161_BASE) && + (offset < IO_ISP1161_BASE + IO_ISP1161_EXTENT)) { + /* + * Philips USB ISP1161x chip + */ + result = IO_ISP1161_PHYS + offset - IO_ISP1161_BASE; + } else { + /* + * safe default. + */ + printk("Warning: unexpected port in %s( offset = 0x%lx )\n", + __FUNCTION__, offset); + result = PVR; + } + + return result; +} + diff --git a/trunk/arch/sh/boards/superh/microdev/irq.c b/trunk/arch/sh/boards/superh/microdev/irq.c index efcbd86b7cd2..1395c1e65da4 100644 --- a/trunk/arch/sh/boards/superh/microdev/irq.c +++ b/trunk/arch/sh/boards/superh/microdev/irq.c @@ -15,7 +15,7 @@ #include #include -#include +#include #define NUM_EXTERNAL_IRQS 16 /* IRL0 .. IRL15 */ diff --git a/trunk/arch/sh/boards/superh/microdev/setup.c b/trunk/arch/sh/boards/superh/microdev/setup.c index 892b14d31405..1c1d65fb12df 100644 --- a/trunk/arch/sh/boards/superh/microdev/setup.c +++ b/trunk/arch/sh/boards/superh/microdev/setup.c @@ -3,7 +3,7 @@ * * Copyright (C) 2003 Sean McGoogan (Sean.McGoogan@superh.com) * Copyright (C) 2003, 2004 SuperH, Inc. - * Copyright (C) 2004, 2005 Paul Mundt + * Copyright (C) 2004 Paul Mundt * * SuperH SH4-202 MicroDev board support. * @@ -15,10 +15,11 @@ #include #include #include -#include