From 09dc63aa6b56f3ef57572f35e4ec46a0cc6f109d Mon Sep 17 00:00:00 2001 From: Herbert Xu Date: Sun, 26 Mar 2006 17:37:54 -0800 Subject: [PATCH] --- yaml --- r: 24435 b: refs/heads/master c: 6abaaaae6d5ed52422c8caf65f3cdbb95579bb58 h: refs/heads/master i: 24433: 0c4778b5cd839b9740d17358c2ea3988088a4d9d 24431: f5ecc2c95cc9b166b12330f241d2dbfd68ea7b8b v: v3 --- [refs] | 2 +- trunk/CREDITS | 5 +- trunk/Documentation/block/biodoc.txt | 14 +- trunk/Documentation/pnp.txt | 3 - trunk/Documentation/robust-futex-ABI.txt | 182 - trunk/Documentation/robust-futexes.txt | 218 - trunk/Documentation/rpc-cache.txt | 121 +- trunk/MAINTAINERS | 6 - trunk/arch/alpha/kernel/setup.c | 14 +- trunk/arch/alpha/mm/numa.c | 4 +- trunk/arch/arm/Kconfig | 3 - trunk/arch/arm/common/rtctime.c | 108 +- trunk/arch/arm/mach-integrator/time.c | 16 +- trunk/arch/arm/mach-omap1/board-netstar.c | 2 +- trunk/arch/arm/mach-omap1/board-voiceblue.c | 2 +- trunk/arch/arm/mach-pxa/generic.c | 6 - trunk/arch/arm/mach-sa1100/generic.c | 6 - trunk/arch/arm26/mm/init.c | 7 +- trunk/arch/cris/kernel/setup.c | 5 +- trunk/arch/i386/Kconfig | 9 - trunk/arch/i386/boot/video.S | 2 - trunk/arch/i386/kernel/cpu/common.c | 10 +- trunk/arch/i386/kernel/cpu/intel_cacheinfo.c | 77 +- trunk/arch/i386/kernel/setup.c | 1 - trunk/arch/i386/kernel/smpboot.c | 24 - trunk/arch/i386/kernel/syscall_table.S | 2 - trunk/arch/i386/kernel/timers/timer_pm.c | 104 +- trunk/arch/i386/kernel/traps.c | 17 +- trunk/arch/i386/mm/discontig.c | 12 +- trunk/arch/i386/mm/pgtable.c | 2 +- trunk/arch/ia64/kernel/traps.c | 6 +- trunk/arch/ia64/mm/discontig.c | 33 +- trunk/arch/ia64/mm/init.c | 2 +- trunk/arch/m32r/kernel/setup.c | 1 - trunk/arch/m32r/mm/discontig.c | 7 +- trunk/arch/m32r/mm/init.c | 3 +- trunk/arch/mips/ddb5xxx/common/rtc_ds1386.c | 4 +- trunk/arch/mips/dec/time.c | 4 +- trunk/arch/mips/ite-boards/generic/time.c | 4 +- trunk/arch/mips/ite-boards/ivr/init.c | 3 + trunk/arch/mips/ite-boards/qed-4n-s01b/init.c | 3 + trunk/arch/mips/jmr3927/common/rtc_ds1742.c | 4 +- trunk/arch/mips/kernel/setup.c | 9 +- trunk/arch/mips/kernel/time.c | 22 +- trunk/arch/mips/lasat/setup.c | 7 +- .../arch/mips/mips-boards/atlas/atlas_setup.c | 2 +- trunk/arch/mips/mips-boards/generic/memory.c | 7 +- .../arch/mips/mips-boards/malta/malta_setup.c | 2 +- trunk/arch/mips/mips-boards/sim/sim_mem.c | 7 +- trunk/arch/mips/mm/init.c | 4 +- trunk/arch/mips/momentum/jaguar_atx/setup.c | 4 +- trunk/arch/mips/momentum/ocelot_3/setup.c | 4 +- trunk/arch/mips/momentum/ocelot_c/setup.c | 4 +- trunk/arch/mips/pmc-sierra/yosemite/setup.c | 4 +- trunk/arch/mips/sgi-ip22/ip22-reset.c | 2 +- trunk/arch/mips/sgi-ip22/ip22-time.c | 4 +- trunk/arch/mips/sgi-ip27/ip27-memory.c | 3 +- trunk/arch/mips/sgi-ip32/ip32-reset.c | 2 +- trunk/arch/mips/sgi-ip32/ip32-setup.c | 4 +- trunk/arch/mips/sibyte/swarm/setup.c | 8 +- trunk/arch/mips/sni/setup.c | 4 +- .../toshiba_rbtx4927/toshiba_rbtx4927_setup.c | 4 +- trunk/arch/mips/tx4938/common/rtc_rx5c348.c | 4 +- trunk/arch/parisc/kernel/pdc_chassis.c | 3 +- trunk/arch/powerpc/kernel/setup_64.c | 3 +- trunk/arch/powerpc/kernel/traps.c | 16 +- trunk/arch/powerpc/mm/mem.c | 4 +- .../arch/powerpc/platforms/pseries/reconfig.c | 10 +- trunk/arch/ppc/platforms/prep_setup.c | 2 +- trunk/arch/s390/kernel/process.c | 11 +- trunk/arch/sh/kernel/setup.c | 5 +- trunk/arch/sh64/kernel/setup.c | 1 - trunk/arch/sparc64/defconfig | 39 +- trunk/arch/sparc64/kernel/sparc64_ksyms.c | 10 + trunk/arch/sparc64/kernel/traps.c | 17 +- trunk/arch/um/drivers/mconsole_kern.c | 3 +- trunk/arch/um/drivers/ubd_kern.c | 76 +- trunk/arch/um/include/irq_user.h | 15 +- trunk/arch/um/include/kern.h | 2 +- trunk/arch/um/include/misc_constants.h | 6 - trunk/arch/um/include/os.h | 36 - trunk/arch/um/include/sigio.h | 3 + trunk/arch/um/include/skas/mode-skas.h | 1 + trunk/arch/um/include/skas/skas.h | 1 + trunk/arch/um/include/user_util.h | 1 + trunk/arch/um/kernel/Makefile | 9 +- trunk/arch/um/kernel/exec_kern.c | 2 + trunk/arch/um/kernel/irq.c | 294 -- trunk/arch/um/kernel/irq_user.c | 412 ++ trunk/arch/um/kernel/physmem.c | 3 +- trunk/arch/um/kernel/sigio_kern.c | 10 +- .../{os-Linux/sigio.c => kernel/sigio_user.c} | 233 +- trunk/arch/um/kernel/smp.c | 14 +- trunk/arch/um/{os-Linux => kernel}/tty_log.c | 18 +- trunk/arch/um/kernel/um_arch.c | 12 +- trunk/arch/um/os-Linux/Makefile | 13 +- trunk/arch/um/os-Linux/irq.c | 162 - trunk/arch/um/os-Linux/start_up.c | 128 - trunk/arch/um/os-Linux/tt.c | 10 - trunk/arch/um/os-Linux/umid.c | 33 +- trunk/arch/um/sys-i386/ptrace.c | 15 +- trunk/arch/um/sys-i386/signal.c | 59 +- trunk/arch/um/sys-i386/user-offsets.c | 10 +- trunk/arch/um/sys-x86_64/ptrace.c | 22 +- trunk/arch/um/sys-x86_64/signal.c | 56 +- trunk/arch/um/sys-x86_64/user-offsets.c | 6 - trunk/arch/x86_64/Kconfig | 13 - trunk/arch/x86_64/ia32/ia32entry.S | 2 - trunk/arch/x86_64/kernel/process.c | 17 +- trunk/arch/x86_64/kernel/setup.c | 3 +- trunk/arch/x86_64/kernel/smpboot.c | 24 - trunk/arch/x86_64/kernel/traps.c | 18 +- trunk/arch/x86_64/mm/init.c | 2 +- trunk/arch/x86_64/mm/numa.c | 15 + trunk/arch/xtensa/platform-iss/setup.c | 2 +- trunk/block/Kconfig | 1 - trunk/block/genhd.c | 6 +- trunk/block/ll_rw_blk.c | 16 +- trunk/drivers/Kconfig | 2 - trunk/drivers/Makefile | 1 - trunk/drivers/base/memory.c | 8 +- trunk/drivers/block/DAC960.c | 7 +- trunk/drivers/block/cciss.c | 12 +- trunk/drivers/block/cciss_scsi.c | 3 +- trunk/drivers/block/paride/bpck6.c | 3 +- trunk/drivers/char/Kconfig | 2 +- trunk/drivers/char/ipmi/ipmi_msghandler.c | 4 +- trunk/drivers/char/ipmi/ipmi_si_intf.c | 7 +- trunk/drivers/char/ipmi/ipmi_watchdog.c | 6 +- trunk/drivers/cpufreq/cpufreq.c | 61 +- trunk/drivers/firmware/dcdbas.c | 19 +- trunk/drivers/i2c/chips/Kconfig | 18 + trunk/drivers/i2c/chips/Makefile | 2 + trunk/drivers/i2c/chips/rtc8564.c | 385 ++ trunk/drivers/i2c/chips/rtc8564.h | 78 + .../{rtc/rtc-x1205.c => i2c/chips/x1205.c} | 453 +- trunk/drivers/ide/ide-cd.c | 1 - trunk/drivers/macintosh/adb.c | 11 +- trunk/drivers/macintosh/adbhid.c | 3 +- trunk/drivers/macintosh/via-pmu.c | 2 +- trunk/drivers/macintosh/via-pmu68k.c | 7 +- trunk/drivers/macintosh/windfarm_core.c | 8 +- trunk/drivers/md/Kconfig | 26 - trunk/drivers/md/dm-crypt.c | 11 +- trunk/drivers/md/dm-ioctl.c | 100 +- trunk/drivers/md/dm-linear.c | 8 +- trunk/drivers/md/dm-raid1.c | 29 +- trunk/drivers/md/dm-snap.c | 409 +- trunk/drivers/md/dm-stripe.c | 13 +- trunk/drivers/md/dm-table.c | 53 +- trunk/drivers/md/dm.c | 88 +- trunk/drivers/md/dm.h | 23 +- trunk/drivers/md/kcopyd.c | 28 +- trunk/drivers/md/md.c | 235 +- trunk/drivers/md/raid1.c | 27 +- trunk/drivers/md/raid5.c | 719 +-- trunk/drivers/md/raid6main.c | 14 +- trunk/drivers/misc/ibmasm/heartbeat.c | 5 +- trunk/drivers/net/bonding/bond_main.c | 2 +- trunk/drivers/net/irda/nsc-ircc.c | 2 +- trunk/drivers/parisc/led.c | 14 +- trunk/drivers/parisc/power.c | 6 +- trunk/drivers/parport/parport_pc.c | 31 +- trunk/drivers/pnp/card.c | 16 +- trunk/drivers/pnp/driver.c | 19 +- trunk/drivers/rtc/Kconfig | 165 - trunk/drivers/rtc/Makefile | 21 - trunk/drivers/rtc/class.c | 145 - trunk/drivers/rtc/hctosys.c | 69 - trunk/drivers/rtc/interface.c | 277 -- trunk/drivers/rtc/rtc-dev.c | 382 -- trunk/drivers/rtc/rtc-ds1672.c | 233 - trunk/drivers/rtc/rtc-ep93xx.c | 162 - trunk/drivers/rtc/rtc-lib.c | 101 - trunk/drivers/rtc/rtc-m48t86.c | 209 - trunk/drivers/rtc/rtc-pcf8563.c | 353 -- trunk/drivers/rtc/rtc-proc.c | 162 - trunk/drivers/rtc/rtc-rs5c372.c | 294 -- trunk/drivers/rtc/rtc-sa1100.c | 388 -- trunk/drivers/rtc/rtc-sysfs.c | 124 - trunk/drivers/rtc/rtc-test.c | 204 - trunk/drivers/scsi/gdth.c | 9 +- trunk/drivers/usb/core/notify.c | 65 +- trunk/drivers/video/Kconfig | 27 - trunk/drivers/video/Makefile | 1 - trunk/drivers/video/acornfb.c | 8 +- trunk/drivers/video/asiliantfb.c | 14 +- trunk/drivers/video/aty/aty128fb.c | 4 +- trunk/drivers/video/aty/atyfb_base.c | 16 +- trunk/drivers/video/aty/mach64_gx.c | 3 +- trunk/drivers/video/aty/radeon_base.c | 6 +- trunk/drivers/video/au1200fb.c | 3844 ----------------- trunk/drivers/video/au1200fb.h | 572 --- trunk/drivers/video/chipsfb.c | 14 +- trunk/drivers/video/console/Kconfig | 24 - trunk/drivers/video/console/fonts.c | 2 +- trunk/drivers/video/console/newport_con.c | 4 +- trunk/drivers/video/console/vgacon.c | 271 +- trunk/drivers/video/fbcmap.c | 4 +- trunk/drivers/video/fbmem.c | 31 +- trunk/drivers/video/fbmon.c | 6 +- trunk/drivers/video/fbsysfs.c | 4 +- trunk/drivers/video/geode/Kconfig | 17 +- trunk/drivers/video/geode/Makefile | 4 +- trunk/drivers/video/geode/display_gx.c | 156 - trunk/drivers/video/geode/display_gx.h | 96 - trunk/drivers/video/geode/gxfb_core.c | 423 -- trunk/drivers/video/geode/video_gx.c | 262 -- trunk/drivers/video/geode/video_gx.h | 47 - trunk/drivers/video/i810/i810-i2c.c | 3 +- trunk/drivers/video/imsttfb.c | 32 +- trunk/drivers/video/macmodes.c | 2 +- trunk/drivers/video/matrox/matroxfb_g450.c | 2 +- trunk/drivers/video/matrox/matroxfb_maven.c | 78 +- trunk/drivers/video/modedb.c | 6 +- trunk/drivers/video/neofb.c | 8 +- trunk/drivers/video/nvidia/nv_accel.c | 12 - trunk/drivers/video/nvidia/nv_i2c.c | 3 +- trunk/drivers/video/nvidia/nv_type.h | 1 - trunk/drivers/video/nvidia/nvidia.c | 119 +- trunk/drivers/video/pmagb-b-fb.c | 2 +- trunk/drivers/video/radeonfb.c | 2 +- trunk/drivers/video/riva/fbdev.c | 2 + trunk/drivers/video/savage/savagefb-i2c.c | 3 +- trunk/drivers/video/sis/init301.c | 11 +- trunk/drivers/video/sstfb.c | 11 +- trunk/drivers/video/virgefb.c | 3 +- trunk/fs/autofs/dirhash.c | 2 +- trunk/fs/autofs4/autofs_i.h | 47 +- trunk/fs/autofs4/expire.c | 292 +- trunk/fs/autofs4/inode.c | 104 +- trunk/fs/autofs4/root.c | 324 +- trunk/fs/autofs4/waitq.c | 111 +- trunk/fs/block_dev.c | 297 -- trunk/fs/buffer.c | 2 +- trunk/fs/hostfs/hostfs_user.c | 1 + trunk/fs/namei.c | 39 +- trunk/fs/namespace.c | 8 +- trunk/fs/nfsd/export.c | 368 +- trunk/fs/nfsd/nfs4idmap.c | 146 +- trunk/fs/nfsd/nfsfh.c | 2 +- trunk/fs/partitions/check.c | 27 - trunk/include/asm-alpha/mmzone.h | 19 +- trunk/include/asm-alpha/page.h | 4 +- trunk/include/asm-arm/memory.h | 15 +- trunk/include/asm-arm/rtc.h | 3 + trunk/include/asm-arm26/memory.h | 4 +- trunk/include/asm-cris/page.h | 4 +- trunk/include/asm-frv/futex.h | 6 - trunk/include/asm-frv/page.h | 7 +- trunk/include/asm-generic/futex.h | 6 - trunk/include/asm-generic/memory_model.h | 77 - trunk/include/asm-h8300/page.h | 4 +- trunk/include/asm-i386/futex.h | 27 - trunk/include/asm-i386/kdebug.h | 10 +- trunk/include/asm-i386/mmzone.h | 17 + trunk/include/asm-i386/page.h | 3 +- trunk/include/asm-i386/processor.h | 5 - trunk/include/asm-i386/setup.h | 4 +- trunk/include/asm-i386/topology.h | 2 - trunk/include/asm-i386/unistd.h | 4 +- trunk/include/asm-ia64/compat.h | 6 - trunk/include/asm-ia64/kdebug.h | 4 +- trunk/include/asm-ia64/page.h | 18 +- trunk/include/asm-m32r/mmzone.h | 14 + trunk/include/asm-m32r/page.h | 5 +- trunk/include/asm-m32r/setup.h | 4 + trunk/include/asm-mips/compat.h | 5 - trunk/include/asm-mips/futex.h | 6 - trunk/include/asm-mips/mmzone.h | 14 + trunk/include/asm-mips/page.h | 3 +- trunk/include/asm-mips/time.h | 12 +- trunk/include/asm-parisc/compat.h | 5 - trunk/include/asm-parisc/mmzone.h | 17 + trunk/include/asm-parisc/page.h | 3 +- trunk/include/asm-powerpc/futex.h | 6 - trunk/include/asm-powerpc/kdebug.h | 12 +- trunk/include/asm-powerpc/page.h | 3 +- trunk/include/asm-ppc/page.h | 4 +- trunk/include/asm-s390/compat.h | 5 - trunk/include/asm-s390/page.h | 3 +- trunk/include/asm-sh/page.h | 5 +- trunk/include/asm-sh64/page.h | 5 +- trunk/include/asm-sh64/platform.h | 5 + trunk/include/asm-sparc/page.h | 4 +- trunk/include/asm-sparc64/futex.h | 6 - trunk/include/asm-sparc64/kdebug.h | 11 +- trunk/include/asm-sparc64/page.h | 2 - trunk/include/asm-um/page.h | 4 +- trunk/include/asm-um/uaccess.h | 31 +- trunk/include/asm-v850/page.h | 4 +- trunk/include/asm-x86_64/futex.h | 27 - trunk/include/asm-x86_64/kdebug.h | 23 +- trunk/include/asm-x86_64/mmzone.h | 4 + trunk/include/asm-x86_64/page.h | 3 +- trunk/include/asm-x86_64/processor.h | 4 - trunk/include/asm-x86_64/smp.h | 1 - trunk/include/asm-x86_64/topology.h | 2 - trunk/include/asm-x86_64/unistd.h | 6 +- trunk/include/asm-xtensa/page.h | 6 +- trunk/include/linux/adb.h | 2 +- trunk/include/linux/auto_fs4.h | 51 +- trunk/include/linux/bootmem.h | 1 - trunk/include/linux/compat.h | 18 - trunk/include/linux/compat_ioctl.h | 2 - trunk/include/linux/device-mapper.h | 1 - trunk/include/linux/dm-ioctl.h | 17 +- trunk/include/linux/fs.h | 10 - trunk/include/linux/futex.h | 89 - trunk/include/linux/genhd.h | 15 +- trunk/include/linux/i2c-id.h | 4 - trunk/include/linux/kernel.h | 2 +- trunk/include/linux/m48t86.h | 16 - trunk/include/linux/memory.h | 1 + trunk/include/linux/mmzone.h | 91 +- .../linux/netfilter_ipv4/ip_conntrack.h | 17 +- trunk/include/linux/nfsd/export.h | 29 +- trunk/include/linux/nodemask.h | 4 - trunk/include/linux/notifier.h | 96 +- trunk/include/linux/pci_ids.h | 1 - trunk/include/linux/pfn.h | 9 - trunk/include/linux/raid/md.h | 3 - trunk/include/linux/raid/md_k.h | 21 +- trunk/include/linux/raid/md_p.h | 32 +- trunk/include/linux/raid/raid5.h | 25 +- trunk/include/linux/rtc.h | 92 - trunk/include/linux/sched.h | 6 - trunk/include/linux/sunrpc/cache.h | 145 +- trunk/include/linux/sunrpc/svcauth.h | 12 +- trunk/include/linux/threads.h | 3 +- trunk/include/linux/topology.h | 9 - trunk/include/linux/x1205.h | 31 + trunk/include/net/netfilter/nf_conntrack.h | 17 +- trunk/kernel/Makefile | 3 - trunk/kernel/compat.c | 23 + trunk/kernel/cpu.c | 29 +- trunk/kernel/exit.c | 8 - trunk/kernel/fork.c | 5 +- trunk/kernel/futex.c | 170 - trunk/kernel/futex_compat.c | 141 - trunk/kernel/module.c | 20 +- trunk/kernel/panic.c | 4 +- trunk/kernel/profile.c | 53 +- trunk/kernel/sched.c | 146 +- trunk/kernel/softlockup.c | 2 +- trunk/kernel/sys.c | 327 +- trunk/kernel/sys_ni.c | 4 - trunk/lib/Kconfig.debug | 2 +- trunk/mm/Makefile | 2 +- trunk/mm/bootmem.c | 39 +- trunk/mm/mmzone.c | 50 - trunk/mm/page_alloc.c | 56 +- trunk/mm/vmscan.c | 6 +- trunk/net/bluetooth/hci_core.c | 8 +- trunk/net/core/dev.c | 42 +- trunk/net/decnet/dn_dev.c | 10 +- trunk/net/ipv4/devinet.c | 16 +- trunk/net/ipv4/netfilter/ip_conntrack_core.c | 6 +- trunk/net/ipv6/addrconf.c | 10 +- trunk/net/ipv6/ipcomp6.c | 5 + trunk/net/netfilter/nf_conntrack_core.c | 6 +- trunk/net/netlink/af_netlink.c | 9 +- trunk/net/sunrpc/auth_gss/svcauth_gss.c | 182 +- trunk/net/sunrpc/cache.c | 163 +- trunk/net/sunrpc/sunrpc_syms.c | 6 +- trunk/net/sunrpc/svcauth.c | 122 +- trunk/net/sunrpc/svcauth_unix.c | 229 +- trunk/sound/drivers/mpu401/mpu401.c | 16 +- trunk/sound/isa/ad1816a/ad1816a.c | 12 +- trunk/sound/isa/als100.c | 14 +- trunk/sound/isa/azt2320.c | 12 +- trunk/sound/isa/cmi8330.c | 15 +- trunk/sound/isa/cs423x/cs4236.c | 25 +- trunk/sound/isa/dt019x.c | 12 +- trunk/sound/isa/es18xx.c | 13 +- trunk/sound/isa/gus/interwave.c | 12 +- trunk/sound/isa/opl3sa2.c | 17 +- trunk/sound/isa/sb/es968.c | 12 +- trunk/sound/isa/sb/sb16.c | 14 +- trunk/sound/isa/sscape.c | 4 +- trunk/sound/isa/wavefront/wavefront.c | 10 +- trunk/sound/oss/cs4232.c | 15 +- trunk/sound/oss/sb_card.c | 29 +- 383 files changed, 4411 insertions(+), 16468 deletions(-) delete mode 100644 trunk/Documentation/robust-futex-ABI.txt delete mode 100644 trunk/Documentation/robust-futexes.txt delete mode 100644 trunk/arch/um/include/misc_constants.h create mode 100644 trunk/arch/um/kernel/irq_user.c rename trunk/arch/um/{os-Linux/sigio.c => kernel/sigio_user.c} (60%) rename trunk/arch/um/{os-Linux => kernel}/tty_log.c (91%) delete mode 100644 trunk/arch/um/os-Linux/irq.c create mode 100644 trunk/drivers/i2c/chips/rtc8564.c create mode 100644 trunk/drivers/i2c/chips/rtc8564.h rename trunk/drivers/{rtc/rtc-x1205.c => i2c/chips/x1205.c} (60%) delete mode 100644 trunk/drivers/rtc/Kconfig delete mode 100644 trunk/drivers/rtc/Makefile delete mode 100644 trunk/drivers/rtc/class.c delete mode 100644 trunk/drivers/rtc/hctosys.c delete mode 100644 trunk/drivers/rtc/interface.c delete mode 100644 trunk/drivers/rtc/rtc-dev.c delete mode 100644 trunk/drivers/rtc/rtc-ds1672.c delete mode 100644 trunk/drivers/rtc/rtc-ep93xx.c delete mode 100644 trunk/drivers/rtc/rtc-lib.c delete mode 100644 trunk/drivers/rtc/rtc-m48t86.c delete mode 100644 trunk/drivers/rtc/rtc-pcf8563.c delete mode 100644 trunk/drivers/rtc/rtc-proc.c delete mode 100644 trunk/drivers/rtc/rtc-rs5c372.c delete mode 100644 trunk/drivers/rtc/rtc-sa1100.c delete mode 100644 trunk/drivers/rtc/rtc-sysfs.c delete mode 100644 trunk/drivers/rtc/rtc-test.c delete mode 100644 trunk/drivers/video/au1200fb.c delete mode 100644 trunk/drivers/video/au1200fb.h delete mode 100644 trunk/drivers/video/geode/display_gx.c delete mode 100644 trunk/drivers/video/geode/display_gx.h delete mode 100644 trunk/drivers/video/geode/gxfb_core.c delete mode 100644 trunk/drivers/video/geode/video_gx.c delete mode 100644 trunk/drivers/video/geode/video_gx.h delete mode 100644 trunk/include/asm-generic/memory_model.h delete mode 100644 trunk/include/linux/m48t86.h delete mode 100644 trunk/include/linux/pfn.h create mode 100644 trunk/include/linux/x1205.h delete mode 100644 trunk/kernel/futex_compat.c delete mode 100644 trunk/mm/mmzone.c diff --git a/[refs] b/[refs] index ccde00aefa2c..5098c8b2d25f 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 4fa639123d9e6e8dfaa3d116368f4b2478da31af +refs/heads/master: 6abaaaae6d5ed52422c8caf65f3cdbb95579bb58 diff --git a/trunk/CREDITS b/trunk/CREDITS index 35850d882c34..c6d69bf10e15 100644 --- a/trunk/CREDITS +++ b/trunk/CREDITS @@ -3741,11 +3741,10 @@ D: Mylex DAC960 PCI RAID driver D: Miscellaneous kernel fixes N: Alessandro Zummo -E: a.zummo@towertech.it +E: azummo@ita.flashnet.it +W: http://freepage.logicom.it/azummo/ D: CMI8330 support is sb_card.c D: ISAPnP fixes in sb_card.c -D: ZyXEL omni.net lcd plus driver -D: RTC subsystem S: Italy N: Marc Zyngier diff --git a/trunk/Documentation/block/biodoc.txt b/trunk/Documentation/block/biodoc.txt index f989a9e839b4..8e63831971d5 100644 --- a/trunk/Documentation/block/biodoc.txt +++ b/trunk/Documentation/block/biodoc.txt @@ -132,18 +132,8 @@ Some new queue property settings: limit. No highmem default. blk_queue_max_sectors(q, max_sectors) - Sets two variables that limit the size of the request. - - - The request queue's max_sectors, which is a soft size in - in units of 512 byte sectors, and could be dynamically varied - by the core kernel. - - - The request queue's max_hw_sectors, which is a hard limit - and reflects the maximum size request a driver can handle - in units of 512 byte sectors. - - The default for both max_sectors and max_hw_sectors is - 255. The upper limit of max_sectors is 1024. + Maximum size request you can handle in units of 512 byte + sectors. 255 default. blk_queue_max_phys_segments(q, max_segments) Maximum physical segments you can handle in a request. 128 diff --git a/trunk/Documentation/pnp.txt b/trunk/Documentation/pnp.txt index 9529c9c9fd59..af0f6eabfa1c 100644 --- a/trunk/Documentation/pnp.txt +++ b/trunk/Documentation/pnp.txt @@ -115,9 +115,6 @@ pnp_unregister_protocol pnp_register_driver - adds a PnP driver to the Plug and Play Layer - this includes driver model integration -- returns zero for success or a negative error number for failure; count - calls to the .add() method if you need to know how many devices bind to - the driver pnp_unregister_driver - removes a PnP driver from the Plug and Play Layer diff --git a/trunk/Documentation/robust-futex-ABI.txt b/trunk/Documentation/robust-futex-ABI.txt deleted file mode 100644 index 8529a17ffaa1..000000000000 --- a/trunk/Documentation/robust-futex-ABI.txt +++ /dev/null @@ -1,182 +0,0 @@ -Started by Paul Jackson - -The robust futex ABI --------------------- - -Robust_futexes provide a mechanism that is used in addition to normal -futexes, for kernel assist of cleanup of held locks on task exit. - -The interesting data as to what futexes a thread is holding is kept on a -linked list in user space, where it can be updated efficiently as locks -are taken and dropped, without kernel intervention. The only additional -kernel intervention required for robust_futexes above and beyond what is -required for futexes is: - - 1) a one time call, per thread, to tell the kernel where its list of - held robust_futexes begins, and - 2) internal kernel code at exit, to handle any listed locks held - by the exiting thread. - -The existing normal futexes already provide a "Fast Userspace Locking" -mechanism, which handles uncontested locking without needing a system -call, and handles contested locking by maintaining a list of waiting -threads in the kernel. Options on the sys_futex(2) system call support -waiting on a particular futex, and waking up the next waiter on a -particular futex. - -For robust_futexes to work, the user code (typically in a library such -as glibc linked with the application) has to manage and place the -necessary list elements exactly as the kernel expects them. If it fails -to do so, then improperly listed locks will not be cleaned up on exit, -probably causing deadlock or other such failure of the other threads -waiting on the same locks. - -A thread that anticipates possibly using robust_futexes should first -issue the system call: - - asmlinkage long - sys_set_robust_list(struct robust_list_head __user *head, size_t len); - -The pointer 'head' points to a structure in the threads address space -consisting of three words. Each word is 32 bits on 32 bit arch's, or 64 -bits on 64 bit arch's, and local byte order. Each thread should have -its own thread private 'head'. - -If a thread is running in 32 bit compatibility mode on a 64 native arch -kernel, then it can actually have two such structures - one using 32 bit -words for 32 bit compatibility mode, and one using 64 bit words for 64 -bit native mode. The kernel, if it is a 64 bit kernel supporting 32 bit -compatibility mode, will attempt to process both lists on each task -exit, if the corresponding sys_set_robust_list() call has been made to -setup that list. - - The first word in the memory structure at 'head' contains a - pointer to a single linked list of 'lock entries', one per lock, - as described below. If the list is empty, the pointer will point - to itself, 'head'. The last 'lock entry' points back to the 'head'. - - The second word, called 'offset', specifies the offset from the - address of the associated 'lock entry', plus or minus, of what will - be called the 'lock word', from that 'lock entry'. The 'lock word' - is always a 32 bit word, unlike the other words above. The 'lock - word' holds 3 flag bits in the upper 3 bits, and the thread id (TID) - of the thread holding the lock in the bottom 29 bits. See further - below for a description of the flag bits. - - The third word, called 'list_op_pending', contains transient copy of - the address of the 'lock entry', during list insertion and removal, - and is needed to correctly resolve races should a thread exit while - in the middle of a locking or unlocking operation. - -Each 'lock entry' on the single linked list starting at 'head' consists -of just a single word, pointing to the next 'lock entry', or back to -'head' if there are no more entries. In addition, nearby to each 'lock -entry', at an offset from the 'lock entry' specified by the 'offset' -word, is one 'lock word'. - -The 'lock word' is always 32 bits, and is intended to be the same 32 bit -lock variable used by the futex mechanism, in conjunction with -robust_futexes. The kernel will only be able to wakeup the next thread -waiting for a lock on a threads exit if that next thread used the futex -mechanism to register the address of that 'lock word' with the kernel. - -For each futex lock currently held by a thread, if it wants this -robust_futex support for exit cleanup of that lock, it should have one -'lock entry' on this list, with its associated 'lock word' at the -specified 'offset'. Should a thread die while holding any such locks, -the kernel will walk this list, mark any such locks with a bit -indicating their holder died, and wakeup the next thread waiting for -that lock using the futex mechanism. - -When a thread has invoked the above system call to indicate it -anticipates using robust_futexes, the kernel stores the passed in 'head' -pointer for that task. The task may retrieve that value later on by -using the system call: - - asmlinkage long - sys_get_robust_list(int pid, struct robust_list_head __user **head_ptr, - size_t __user *len_ptr); - -It is anticipated that threads will use robust_futexes embedded in -larger, user level locking structures, one per lock. The kernel -robust_futex mechanism doesn't care what else is in that structure, so -long as the 'offset' to the 'lock word' is the same for all -robust_futexes used by that thread. The thread should link those locks -it currently holds using the 'lock entry' pointers. It may also have -other links between the locks, such as the reverse side of a double -linked list, but that doesn't matter to the kernel. - -By keeping its locks linked this way, on a list starting with a 'head' -pointer known to the kernel, the kernel can provide to a thread the -essential service available for robust_futexes, which is to help clean -up locks held at the time of (a perhaps unexpectedly) exit. - -Actual locking and unlocking, during normal operations, is handled -entirely by user level code in the contending threads, and by the -existing futex mechanism to wait for, and wakeup, locks. The kernels -only essential involvement in robust_futexes is to remember where the -list 'head' is, and to walk the list on thread exit, handling locks -still held by the departing thread, as described below. - -There may exist thousands of futex lock structures in a threads shared -memory, on various data structures, at a given point in time. Only those -lock structures for locks currently held by that thread should be on -that thread's robust_futex linked lock list a given time. - -A given futex lock structure in a user shared memory region may be held -at different times by any of the threads with access to that region. The -thread currently holding such a lock, if any, is marked with the threads -TID in the lower 29 bits of the 'lock word'. - -When adding or removing a lock from its list of held locks, in order for -the kernel to correctly handle lock cleanup regardless of when the task -exits (perhaps it gets an unexpected signal 9 in the middle of -manipulating this list), the user code must observe the following -protocol on 'lock entry' insertion and removal: - -On insertion: - 1) set the 'list_op_pending' word to the address of the 'lock word' - to be inserted, - 2) acquire the futex lock, - 3) add the lock entry, with its thread id (TID) in the bottom 29 bits - of the 'lock word', to the linked list starting at 'head', and - 4) clear the 'list_op_pending' word. - -On removal: - 1) set the 'list_op_pending' word to the address of the 'lock word' - to be removed, - 2) remove the lock entry for this lock from the 'head' list, - 2) release the futex lock, and - 2) clear the 'lock_op_pending' word. - -On exit, the kernel will consider the address stored in -'list_op_pending' and the address of each 'lock word' found by walking -the list starting at 'head'. For each such address, if the bottom 29 -bits of the 'lock word' at offset 'offset' from that address equals the -exiting threads TID, then the kernel will do two things: - - 1) if bit 31 (0x80000000) is set in that word, then attempt a futex - wakeup on that address, which will waken the next thread that has - used to the futex mechanism to wait on that address, and - 2) atomically set bit 30 (0x40000000) in the 'lock word'. - -In the above, bit 31 was set by futex waiters on that lock to indicate -they were waiting, and bit 30 is set by the kernel to indicate that the -lock owner died holding the lock. - -The kernel exit code will silently stop scanning the list further if at -any point: - - 1) the 'head' pointer or an subsequent linked list pointer - is not a valid address of a user space word - 2) the calculated location of the 'lock word' (address plus - 'offset') is not the valud address of a 32 bit user space - word - 3) if the list contains more than 1 million (subject to - future kernel configuration changes) elements. - -When the kernel sees a list entry whose 'lock word' doesn't have the -current threads TID in the lower 29 bits, it does nothing with that -entry, and goes on to the next entry. - -Bit 29 (0x20000000) of the 'lock word' is reserved for future use. diff --git a/trunk/Documentation/robust-futexes.txt b/trunk/Documentation/robust-futexes.txt deleted file mode 100644 index df82d75245a0..000000000000 --- a/trunk/Documentation/robust-futexes.txt +++ /dev/null @@ -1,218 +0,0 @@ -Started by: Ingo Molnar - -Background ----------- - -what are robust futexes? To answer that, we first need to understand -what futexes are: normal futexes are special types of locks that in the -noncontended case can be acquired/released from userspace without having -to enter the kernel. - -A futex is in essence a user-space address, e.g. a 32-bit lock variable -field. If userspace notices contention (the lock is already owned and -someone else wants to grab it too) then the lock is marked with a value -that says "there's a waiter pending", and the sys_futex(FUTEX_WAIT) -syscall is used to wait for the other guy to release it. The kernel -creates a 'futex queue' internally, so that it can later on match up the -waiter with the waker - without them having to know about each other. -When the owner thread releases the futex, it notices (via the variable -value) that there were waiter(s) pending, and does the -sys_futex(FUTEX_WAKE) syscall to wake them up. Once all waiters have -taken and released the lock, the futex is again back to 'uncontended' -state, and there's no in-kernel state associated with it. The kernel -completely forgets that there ever was a futex at that address. This -method makes futexes very lightweight and scalable. - -"Robustness" is about dealing with crashes while holding a lock: if a -process exits prematurely while holding a pthread_mutex_t lock that is -also shared with some other process (e.g. yum segfaults while holding a -pthread_mutex_t, or yum is kill -9-ed), then waiters for that lock need -to be notified that the last owner of the lock exited in some irregular -way. - -To solve such types of problems, "robust mutex" userspace APIs were -created: pthread_mutex_lock() returns an error value if the owner exits -prematurely - and the new owner can decide whether the data protected by -the lock can be recovered safely. - -There is a big conceptual problem with futex based mutexes though: it is -the kernel that destroys the owner task (e.g. due to a SEGFAULT), but -the kernel cannot help with the cleanup: if there is no 'futex queue' -(and in most cases there is none, futexes being fast lightweight locks) -then the kernel has no information to clean up after the held lock! -Userspace has no chance to clean up after the lock either - userspace is -the one that crashes, so it has no opportunity to clean up. Catch-22. - -In practice, when e.g. yum is kill -9-ed (or segfaults), a system reboot -is needed to release that futex based lock. This is one of the leading -bugreports against yum. - -To solve this problem, the traditional approach was to extend the vma -(virtual memory area descriptor) concept to have a notion of 'pending -robust futexes attached to this area'. This approach requires 3 new -syscall variants to sys_futex(): FUTEX_REGISTER, FUTEX_DEREGISTER and -FUTEX_RECOVER. At do_exit() time, all vmas are searched to see whether -they have a robust_head set. This approach has two fundamental problems -left: - - - it has quite complex locking and race scenarios. The vma-based - approach had been pending for years, but they are still not completely - reliable. - - - they have to scan _every_ vma at sys_exit() time, per thread! - -The second disadvantage is a real killer: pthread_exit() takes around 1 -microsecond on Linux, but with thousands (or tens of thousands) of vmas -every pthread_exit() takes a millisecond or more, also totally -destroying the CPU's L1 and L2 caches! - -This is very much noticeable even for normal process sys_exit_group() -calls: the kernel has to do the vma scanning unconditionally! (this is -because the kernel has no knowledge about how many robust futexes there -are to be cleaned up, because a robust futex might have been registered -in another task, and the futex variable might have been simply mmap()-ed -into this process's address space). - -This huge overhead forced the creation of CONFIG_FUTEX_ROBUST so that -normal kernels can turn it off, but worse than that: the overhead makes -robust futexes impractical for any type of generic Linux distribution. - -So something had to be done. - -New approach to robust futexes ------------------------------- - -At the heart of this new approach there is a per-thread private list of -robust locks that userspace is holding (maintained by glibc) - which -userspace list is registered with the kernel via a new syscall [this -registration happens at most once per thread lifetime]. At do_exit() -time, the kernel checks this user-space list: are there any robust futex -locks to be cleaned up? - -In the common case, at do_exit() time, there is no list registered, so -the cost of robust futexes is just a simple current->robust_list != NULL -comparison. If the thread has registered a list, then normally the list -is empty. If the thread/process crashed or terminated in some incorrect -way then the list might be non-empty: in this case the kernel carefully -walks the list [not trusting it], and marks all locks that are owned by -this thread with the FUTEX_OWNER_DEAD bit, and wakes up one waiter (if -any). - -The list is guaranteed to be private and per-thread at do_exit() time, -so it can be accessed by the kernel in a lockless way. - -There is one race possible though: since adding to and removing from the -list is done after the futex is acquired by glibc, there is a few -instructions window for the thread (or process) to die there, leaving -the futex hung. To protect against this possibility, userspace (glibc) -also maintains a simple per-thread 'list_op_pending' field, to allow the -kernel to clean up if the thread dies after acquiring the lock, but just -before it could have added itself to the list. Glibc sets this -list_op_pending field before it tries to acquire the futex, and clears -it after the list-add (or list-remove) has finished. - -That's all that is needed - all the rest of robust-futex cleanup is done -in userspace [just like with the previous patches]. - -Ulrich Drepper has implemented the necessary glibc support for this new -mechanism, which fully enables robust mutexes. - -Key differences of this userspace-list based approach, compared to the -vma based method: - - - it's much, much faster: at thread exit time, there's no need to loop - over every vma (!), which the VM-based method has to do. Only a very - simple 'is the list empty' op is done. - - - no VM changes are needed - 'struct address_space' is left alone. - - - no registration of individual locks is needed: robust mutexes dont - need any extra per-lock syscalls. Robust mutexes thus become a very - lightweight primitive - so they dont force the application designer - to do a hard choice between performance and robustness - robust - mutexes are just as fast. - - - no per-lock kernel allocation happens. - - - no resource limits are needed. - - - no kernel-space recovery call (FUTEX_RECOVER) is needed. - - - the implementation and the locking is "obvious", and there are no - interactions with the VM. - -Performance ------------ - -I have benchmarked the time needed for the kernel to process a list of 1 -million (!) held locks, using the new method [on a 2GHz CPU]: - - - with FUTEX_WAIT set [contended mutex]: 130 msecs - - without FUTEX_WAIT set [uncontended mutex]: 30 msecs - -I have also measured an approach where glibc does the lock notification -[which it currently does for !pshared robust mutexes], and that took 256 -msecs - clearly slower, due to the 1 million FUTEX_WAKE syscalls -userspace had to do. - -(1 million held locks are unheard of - we expect at most a handful of -locks to be held at a time. Nevertheless it's nice to know that this -approach scales nicely.) - -Implementation details ----------------------- - -The patch adds two new syscalls: one to register the userspace list, and -one to query the registered list pointer: - - asmlinkage long - sys_set_robust_list(struct robust_list_head __user *head, - size_t len); - - asmlinkage long - sys_get_robust_list(int pid, struct robust_list_head __user **head_ptr, - size_t __user *len_ptr); - -List registration is very fast: the pointer is simply stored in -current->robust_list. [Note that in the future, if robust futexes become -widespread, we could extend sys_clone() to register a robust-list head -for new threads, without the need of another syscall.] - -So there is virtually zero overhead for tasks not using robust futexes, -and even for robust futex users, there is only one extra syscall per -thread lifetime, and the cleanup operation, if it happens, is fast and -straightforward. The kernel doesnt have any internal distinction between -robust and normal futexes. - -If a futex is found to be held at exit time, the kernel sets the -following bit of the futex word: - - #define FUTEX_OWNER_DIED 0x40000000 - -and wakes up the next futex waiter (if any). User-space does the rest of -the cleanup. - -Otherwise, robust futexes are acquired by glibc by putting the TID into -the futex field atomically. Waiters set the FUTEX_WAITERS bit: - - #define FUTEX_WAITERS 0x80000000 - -and the remaining bits are for the TID. - -Testing, architecture support ------------------------------ - -i've tested the new syscalls on x86 and x86_64, and have made sure the -parsing of the userspace list is robust [ ;-) ] even if the list is -deliberately corrupted. - -i386 and x86_64 syscalls are wired up at the moment, and Ulrich has -tested the new glibc code (on x86_64 and i386), and it works for his -robust-mutex testcases. - -All other architectures should build just fine too - but they wont have -the new syscalls yet. - -Architectures need to implement the new futex_atomic_cmpxchg_inatomic() -inline function before writing up the syscalls (that function returns --ENOSYS right now). diff --git a/trunk/Documentation/rpc-cache.txt b/trunk/Documentation/rpc-cache.txt index 5f757c8cf979..2b5d4434fa5a 100644 --- a/trunk/Documentation/rpc-cache.txt +++ b/trunk/Documentation/rpc-cache.txt @@ -1,4 +1,4 @@ - This document gives a brief introduction to the caching +This document gives a brief introduction to the caching mechanisms in the sunrpc layer that is used, in particular, for NFS authentication. @@ -25,17 +25,25 @@ The common code handles such things as: - supporting 'NEGATIVE' as well as positive entries - allowing an EXPIRED time on cache items, and removing items after they expire, and are no longe in-use. + + Future code extensions are expect to handle - making requests to user-space to fill in cache entries - allowing user-space to directly set entries in the cache - delaying RPC requests that depend on as-yet incomplete cache entries, and replaying those requests when the cache entry is complete. - - clean out old entries as they expire. + - maintaining last-access times on cache entries + - clean out old entries when the caches become full + +The code for performing a cache lookup is also common, but in the form +of a template. i.e. a #define. +Each cache defines a lookup function by using the DefineCacheLookup +macro, or the simpler DefineSimpleCacheLookup macro Creating a Cache ---------------- -1/ A cache needs a datum to store. This is in the form of a +1/ A cache needs a datum to cache. This is in the form of a structure definition that must contain a struct cache_head as an element, usually the first. @@ -43,69 +51,35 @@ Creating a Cache Each cache element is reference counted and contains expiry and update times for use in cache management. 2/ A cache needs a "cache_detail" structure that - describes the cache. This stores the hash table, some - parameters for cache management, and some operations detailing how - to work with particular cache items. - The operations requires are: - struct cache_head *alloc(void) - This simply allocates appropriate memory and returns - a pointer to the cache_detail embedded within the - structure - void cache_put(struct kref *) - This is called when the last reference to an item is - is dropped. The pointer passed is to the 'ref' field - in the cache_head. cache_put should release any - references create by 'cache_init' and, if CACHE_VALID - is set, any references created by cache_update. - It should then release the memory allocated by - 'alloc'. - int match(struct cache_head *orig, struct cache_head *new) - test if the keys in the two structures match. Return - 1 if they do, 0 if they don't. - void init(struct cache_head *orig, struct cache_head *new) - Set the 'key' fields in 'new' from 'orig'. This may - include taking references to shared objects. - void update(struct cache_head *orig, struct cache_head *new) - Set the 'content' fileds in 'new' from 'orig'. - int cache_show(struct seq_file *m, struct cache_detail *cd, - struct cache_head *h) - Optional. Used to provide a /proc file that lists the - contents of a cache. This should show one item, - usually on just one line. - int cache_request(struct cache_detail *cd, struct cache_head *h, - char **bpp, int *blen) - Format a request to be send to user-space for an item - to be instantiated. *bpp is a buffer of size *blen. - bpp should be moved forward over the encoded message, - and *blen should be reduced to show how much free - space remains. Return 0 on success or <0 if not - enough room or other problem. - int cache_parse(struct cache_detail *cd, char *buf, int len) - A message from user space has arrived to fill out a - cache entry. It is in 'buf' of length 'len'. - cache_parse should parse this, find the item in the - cache with sunrpc_cache_lookup, and update the item - with sunrpc_cache_update. - - -3/ A cache needs to be registered using cache_register(). This - includes it on a list of caches that will be regularly - cleaned to discard old data. - + describes the cache. This stores the hash table, and some + parameters for cache management. +3/ A cache needs a lookup function. This is created using + the DefineCacheLookup macro. This lookup function is used both + to find entries and to update entries. The normal mode for + updating an entry is to replace the old entry with a new + entry. However it is possible to allow update-in-place + for those caches where it makes sense (no atomicity issues + or indirect reference counting issue) +4/ A cache needs to be registered using cache_register(). This + includes in on a list of caches that will be regularly + cleaned to discard old data. For this to work, some + thread must periodically call cache_clean + Using a cache ------------- -To find a value in a cache, call sunrpc_cache_lookup passing a pointer -to the cache_head in a sample item with the 'key' fields filled in. -This will be passed to ->match to identify the target entry. If no -entry is found, a new entry will be create, added to the cache, and -marked as not containing valid data. +To find a value in a cache, call the lookup function passing it a the +datum which contains key, and possibly content, and a flag saying +whether to update the cache with new data from the datum. Depending +on how the cache lookup function was defined, it may take an extra +argument to identify the particular cache in question. -The item returned is typically passed to cache_check which will check -if the data is valid, and may initiate an up-call to get fresh data. -cache_check will return -ENOENT in the entry is negative or if an up -call is needed but not possible, -EAGAIN if an upcall is pending, -or 0 if the data is valid; +Except in cases of kmalloc failure, the lookup function +will return a new datum which will store the key and +may contain valid content, or may not. +This datum is typically passed to cache_check which determines the +validity of the datum and may later initiate an upcall to fill +in the data. cache_check can be passed a "struct cache_req *". This structure is typically embedded in the actual request and can be used to create a @@ -116,13 +90,6 @@ item does become valid, the deferred copy of the request will be revisited (->revisit). It is expected that this method will reschedule the request for processing. -The value returned by sunrpc_cache_lookup can also be passed to -sunrpc_cache_update to set the content for the item. A second item is -passed which should hold the content. If the item found by _lookup -has valid data, then it is discarded and a new item is created. This -saves any user of an item from worrying about content changing while -it is being inspected. If the item found by _lookup does not contain -valid data, then the content is copied across and CACHE_VALID is set. Populating a cache ------------------ @@ -147,8 +114,8 @@ should be create or updated to have the given content, and the expiry time should be set on that item. Reading from a channel is a bit more interesting. When a cache -lookup fails, or when it succeeds but finds an entry that may soon -expire, a request is lodged for that cache item to be updated by +lookup fail, or when it suceeds but finds an entry that may soon +expiry, a request is lodged for that cache item to be updated by user-space. These requests appear in the channel file. Successive reads will return successive requests. @@ -163,7 +130,7 @@ Thus a user-space helper is likely to: write a response loop. -If it dies and needs to be restarted, any requests that have not been +If it dies and needs to be restarted, any requests that have not be answered will still appear in the file and will be read by the new instance of the helper. @@ -175,9 +142,10 @@ Each cache should also define a "cache_request" method which takes a cache item and encodes a request into the buffer provided. + Note: If a cache has no active readers on the channel, and has had not active readers for more than 60 seconds, further requests will not be -added to the channel but instead all lookups that do not find a valid +added to the channel but instead all looks that do not find a valid entry will fail. This is partly for backward compatibility: The previous nfs exports table was deemed to be authoritative and a failed lookup meant a definite 'no'. @@ -186,17 +154,18 @@ request/response format ----------------------- While each cache is free to use it's own format for requests -and responses over channel, the following is recommended as +and responses over channel, the following is recommended are appropriate and support routines are available to help: Each request or response record should be printable ASCII with precisely one newline character which should be at the end. Fields within the record should be separated by spaces, normally one. If spaces, newlines, or nul characters are needed in a field they -much be quoted. two mechanisms are available: +much be quotes. two mechanisms are available: 1/ If a field begins '\x' then it must contain an even number of hex digits, and pairs of these digits provide the bytes in the field. 2/ otherwise a \ in the field must be followed by 3 octal digits which give the code for a byte. Other characters are treated - as them selves. At the very least, space, newline, nul, and + as them selves. At the very least, space, newlines nul, and '\' must be quoted in this way. + diff --git a/trunk/MAINTAINERS b/trunk/MAINTAINERS index e5b051f0e27e..f27846734b06 100644 --- a/trunk/MAINTAINERS +++ b/trunk/MAINTAINERS @@ -2233,12 +2233,6 @@ M: p_gortmaker@yahoo.com L: linux-kernel@vger.kernel.org S: Maintained -REAL TIME CLOCK (RTC) SUBSYSTEM -P: Alessandro Zummo -M: a.zummo@towertech.it -L: linux-kernel@vger.kernel.org -S: Maintained - REISERFS FILE SYSTEM P: Hans Reiser M: reiserfs-dev@namesys.com diff --git a/trunk/arch/alpha/kernel/setup.c b/trunk/arch/alpha/kernel/setup.c index dd8769670596..b4e5f8ff2b25 100644 --- a/trunk/arch/alpha/kernel/setup.c +++ b/trunk/arch/alpha/kernel/setup.c @@ -34,7 +34,6 @@ #include #include #include -#include #ifdef CONFIG_MAGIC_SYSRQ #include #include @@ -43,7 +42,7 @@ #include #include -extern struct atomic_notifier_head panic_notifier_list; +extern struct notifier_block *panic_notifier_list; static int alpha_panic_event(struct notifier_block *, unsigned long, void *); static struct notifier_block alpha_panic_block = { alpha_panic_event, @@ -242,6 +241,9 @@ reserve_std_resources(void) request_resource(io, standard_io_resources+i); } +#define PFN_UP(x) (((x) + PAGE_SIZE-1) >> PAGE_SHIFT) +#define PFN_DOWN(x) ((x) >> PAGE_SHIFT) +#define PFN_PHYS(x) ((x) << PAGE_SHIFT) #define PFN_MAX PFN_DOWN(0x80000000) #define for_each_mem_cluster(memdesc, cluster, i) \ for ((cluster) = (memdesc)->cluster, (i) = 0; \ @@ -470,6 +472,11 @@ page_is_ram(unsigned long pfn) return 0; } +#undef PFN_UP +#undef PFN_DOWN +#undef PFN_PHYS +#undef PFN_MAX + void __init setup_arch(char **cmdline_p) { @@ -500,8 +507,7 @@ setup_arch(char **cmdline_p) } /* Register a call for panic conditions. */ - atomic_notifier_chain_register(&panic_notifier_list, - &alpha_panic_block); + notifier_chain_register(&panic_notifier_list, &alpha_panic_block); #ifdef CONFIG_ALPHA_GENERIC /* Assume that we've booted from SRM if we haven't booted from MILO. diff --git a/trunk/arch/alpha/mm/numa.c b/trunk/arch/alpha/mm/numa.c index bf6b65c81bef..6d5251254f68 100644 --- a/trunk/arch/alpha/mm/numa.c +++ b/trunk/arch/alpha/mm/numa.c @@ -13,7 +13,6 @@ #include #include #include -#include #include #include @@ -28,6 +27,9 @@ bootmem_data_t node_bdata[MAX_NUMNODES]; #define DBGDCONT(args...) #endif +#define PFN_UP(x) (((x) + PAGE_SIZE-1) >> PAGE_SHIFT) +#define PFN_DOWN(x) ((x) >> PAGE_SHIFT) +#define PFN_PHYS(x) ((x) << PAGE_SHIFT) #define for_each_mem_cluster(memdesc, cluster, i) \ for ((cluster) = (memdesc)->cluster, (i) = 0; \ (i) < (memdesc)->numclusters; (i)++, (cluster)++) diff --git a/trunk/arch/arm/Kconfig b/trunk/arch/arm/Kconfig index 9731b3f826ab..bf2e72698d02 100644 --- a/trunk/arch/arm/Kconfig +++ b/trunk/arch/arm/Kconfig @@ -8,7 +8,6 @@ mainmenu "Linux Kernel Configuration" config ARM bool default y - select RTC_LIB help The ARM series is a line of low-power-consumption RISC chip designs licensed by ARM Ltd and targeted at embedded applications and @@ -840,8 +839,6 @@ source "drivers/usb/Kconfig" source "drivers/mmc/Kconfig" -source "drivers/rtc/Kconfig" - endmenu source "fs/Kconfig" diff --git a/trunk/arch/arm/common/rtctime.c b/trunk/arch/arm/common/rtctime.c index 35c9a64ac14c..e851d86c212c 100644 --- a/trunk/arch/arm/common/rtctime.c +++ b/trunk/arch/arm/common/rtctime.c @@ -20,7 +20,6 @@ #include #include #include -#include #include #include @@ -43,6 +42,89 @@ static struct rtc_ops *rtc_ops; #define rtc_epoch 1900UL +static const unsigned char days_in_month[] = { + 31, 28, 31, 30, 31, 30, 31, 31, 30, 31, 30, 31 +}; + +#define LEAPS_THRU_END_OF(y) ((y)/4 - (y)/100 + (y)/400) +#define LEAP_YEAR(year) ((!(year % 4) && (year % 100)) || !(year % 400)) + +static int month_days(unsigned int month, unsigned int year) +{ + return days_in_month[month] + (LEAP_YEAR(year) && month == 1); +} + +/* + * Convert seconds since 01-01-1970 00:00:00 to Gregorian date. + */ +void rtc_time_to_tm(unsigned long time, struct rtc_time *tm) +{ + int days, month, year; + + days = time / 86400; + time -= days * 86400; + + tm->tm_wday = (days + 4) % 7; + + year = 1970 + days / 365; + days -= (year - 1970) * 365 + + LEAPS_THRU_END_OF(year - 1) + - LEAPS_THRU_END_OF(1970 - 1); + if (days < 0) { + year -= 1; + days += 365 + LEAP_YEAR(year); + } + tm->tm_year = year - 1900; + tm->tm_yday = days + 1; + + for (month = 0; month < 11; month++) { + int newdays; + + newdays = days - month_days(month, year); + if (newdays < 0) + break; + days = newdays; + } + tm->tm_mon = month; + tm->tm_mday = days + 1; + + tm->tm_hour = time / 3600; + time -= tm->tm_hour * 3600; + tm->tm_min = time / 60; + tm->tm_sec = time - tm->tm_min * 60; +} +EXPORT_SYMBOL(rtc_time_to_tm); + +/* + * Does the rtc_time represent a valid date/time? + */ +int rtc_valid_tm(struct rtc_time *tm) +{ + if (tm->tm_year < 70 || + tm->tm_mon >= 12 || + tm->tm_mday < 1 || + tm->tm_mday > month_days(tm->tm_mon, tm->tm_year + 1900) || + tm->tm_hour >= 24 || + tm->tm_min >= 60 || + tm->tm_sec >= 60) + return -EINVAL; + + return 0; +} +EXPORT_SYMBOL(rtc_valid_tm); + +/* + * Convert Gregorian date to seconds since 01-01-1970 00:00:00. + */ +int rtc_tm_to_time(struct rtc_time *tm, unsigned long *time) +{ + *time = mktime(tm->tm_year + 1900, tm->tm_mon + 1, tm->tm_mday, + tm->tm_hour, tm->tm_min, tm->tm_sec); + + return 0; +} +EXPORT_SYMBOL(rtc_tm_to_time); + /* * Calculate the next alarm time given the requested alarm time mask * and the current time. @@ -69,13 +151,13 @@ void rtc_next_alarm_time(struct rtc_time *next, struct rtc_time *now, struct rtc } } -static inline int rtc_arm_read_time(struct rtc_ops *ops, struct rtc_time *tm) +static inline int rtc_read_time(struct rtc_ops *ops, struct rtc_time *tm) { memset(tm, 0, sizeof(struct rtc_time)); return ops->read_time(tm); } -static inline int rtc_arm_set_time(struct rtc_ops *ops, struct rtc_time *tm) +static inline int rtc_set_time(struct rtc_ops *ops, struct rtc_time *tm) { int ret; @@ -86,7 +168,7 @@ static inline int rtc_arm_set_time(struct rtc_ops *ops, struct rtc_time *tm) return ret; } -static inline int rtc_arm_read_alarm(struct rtc_ops *ops, struct rtc_wkalrm *alrm) +static inline int rtc_read_alarm(struct rtc_ops *ops, struct rtc_wkalrm *alrm) { int ret = -EINVAL; if (ops->read_alarm) { @@ -96,7 +178,7 @@ static inline int rtc_arm_read_alarm(struct rtc_ops *ops, struct rtc_wkalrm *alr return ret; } -static inline int rtc_arm_set_alarm(struct rtc_ops *ops, struct rtc_wkalrm *alrm) +static inline int rtc_set_alarm(struct rtc_ops *ops, struct rtc_wkalrm *alrm) { int ret = -EINVAL; if (ops->set_alarm) @@ -184,7 +266,7 @@ static int rtc_ioctl(struct inode *inode, struct file *file, unsigned int cmd, switch (cmd) { case RTC_ALM_READ: - ret = rtc_arm_read_alarm(ops, &alrm); + ret = rtc_read_alarm(ops, &alrm); if (ret) break; ret = copy_to_user(uarg, &alrm.time, sizeof(tm)); @@ -206,11 +288,11 @@ static int rtc_ioctl(struct inode *inode, struct file *file, unsigned int cmd, alrm.time.tm_wday = -1; alrm.time.tm_yday = -1; alrm.time.tm_isdst = -1; - ret = rtc_arm_set_alarm(ops, &alrm); + ret = rtc_set_alarm(ops, &alrm); break; case RTC_RD_TIME: - ret = rtc_arm_read_time(ops, &tm); + ret = rtc_read_time(ops, &tm); if (ret) break; ret = copy_to_user(uarg, &tm, sizeof(tm)); @@ -228,7 +310,7 @@ static int rtc_ioctl(struct inode *inode, struct file *file, unsigned int cmd, ret = -EFAULT; break; } - ret = rtc_arm_set_time(ops, &tm); + ret = rtc_set_time(ops, &tm); break; case RTC_EPOCH_SET: @@ -259,11 +341,11 @@ static int rtc_ioctl(struct inode *inode, struct file *file, unsigned int cmd, ret = -EFAULT; break; } - ret = rtc_arm_set_alarm(ops, &alrm); + ret = rtc_set_alarm(ops, &alrm); break; case RTC_WKALM_RD: - ret = rtc_arm_read_alarm(ops, &alrm); + ret = rtc_read_alarm(ops, &alrm); if (ret) break; ret = copy_to_user(uarg, &alrm, sizeof(alrm)); @@ -353,7 +435,7 @@ static int rtc_read_proc(char *page, char **start, off_t off, int count, int *eo struct rtc_time tm; char *p = page; - if (rtc_arm_read_time(ops, &tm) == 0) { + if (rtc_read_time(ops, &tm) == 0) { p += sprintf(p, "rtc_time\t: %02d:%02d:%02d\n" "rtc_date\t: %04d-%02d-%02d\n" @@ -363,7 +445,7 @@ static int rtc_read_proc(char *page, char **start, off_t off, int count, int *eo rtc_epoch); } - if (rtc_arm_read_alarm(ops, &alrm) == 0) { + if (rtc_read_alarm(ops, &alrm) == 0) { p += sprintf(p, "alrm_time\t: "); if ((unsigned int)alrm.time.tm_hour <= 24) p += sprintf(p, "%02d:", alrm.time.tm_hour); diff --git a/trunk/arch/arm/mach-integrator/time.c b/trunk/arch/arm/mach-integrator/time.c index bc07f52a6fd7..3c22c16b38bf 100644 --- a/trunk/arch/arm/mach-integrator/time.c +++ b/trunk/arch/arm/mach-integrator/time.c @@ -40,13 +40,13 @@ static int integrator_set_rtc(void) return 1; } -static int integrator_rtc_read_alarm(struct rtc_wkalrm *alrm) +static int rtc_read_alarm(struct rtc_wkalrm *alrm) { rtc_time_to_tm(readl(rtc_base + RTC_MR), &alrm->time); return 0; } -static inline int integrator_rtc_set_alarm(struct rtc_wkalrm *alrm) +static inline int rtc_set_alarm(struct rtc_wkalrm *alrm) { unsigned long time; int ret; @@ -62,7 +62,7 @@ static inline int integrator_rtc_set_alarm(struct rtc_wkalrm *alrm) return ret; } -static int integrator_rtc_read_time(struct rtc_time *tm) +static int rtc_read_time(struct rtc_time *tm) { rtc_time_to_tm(readl(rtc_base + RTC_DR), tm); return 0; @@ -76,7 +76,7 @@ static int integrator_rtc_read_time(struct rtc_time *tm) * edge of the 1Hz clock, we must write the time one second * in advance. */ -static inline int integrator_rtc_set_time(struct rtc_time *tm) +static inline int rtc_set_time(struct rtc_time *tm) { unsigned long time; int ret; @@ -90,10 +90,10 @@ static inline int integrator_rtc_set_time(struct rtc_time *tm) static struct rtc_ops rtc_ops = { .owner = THIS_MODULE, - .read_time = integrator_rtc_read_time, - .set_time = integrator_rtc_set_time, - .read_alarm = integrator_rtc_read_alarm, - .set_alarm = integrator_rtc_set_alarm, + .read_time = rtc_read_time, + .set_time = rtc_set_time, + .read_alarm = rtc_read_alarm, + .set_alarm = rtc_set_alarm, }; static irqreturn_t arm_rtc_interrupt(int irq, void *dev_id, diff --git a/trunk/arch/arm/mach-omap1/board-netstar.c b/trunk/arch/arm/mach-omap1/board-netstar.c index 7520e602d7a2..60d5f8a3339c 100644 --- a/trunk/arch/arm/mach-omap1/board-netstar.c +++ b/trunk/arch/arm/mach-omap1/board-netstar.c @@ -141,7 +141,7 @@ static int __init netstar_late_init(void) /* TODO: Setup front panel switch here */ /* Setup panic notifier */ - atomic_notifier_chain_register(&panic_notifier_list, &panic_block); + notifier_chain_register(&panic_notifier_list, &panic_block); return 0; } diff --git a/trunk/arch/arm/mach-omap1/board-voiceblue.c b/trunk/arch/arm/mach-omap1/board-voiceblue.c index 52e4a9d69642..bfd5fdd1a875 100644 --- a/trunk/arch/arm/mach-omap1/board-voiceblue.c +++ b/trunk/arch/arm/mach-omap1/board-voiceblue.c @@ -235,7 +235,7 @@ static struct notifier_block panic_block = { static int __init voiceblue_setup(void) { /* Setup panic notifier */ - atomic_notifier_chain_register(&panic_notifier_list, &panic_block); + notifier_chain_register(&panic_notifier_list, &panic_block); return 0; } diff --git a/trunk/arch/arm/mach-pxa/generic.c b/trunk/arch/arm/mach-pxa/generic.c index 5efa84749f37..9b48a90aefce 100644 --- a/trunk/arch/arm/mach-pxa/generic.c +++ b/trunk/arch/arm/mach-pxa/generic.c @@ -319,11 +319,6 @@ void __init pxa_set_ficp_info(struct pxaficp_platform_data *info) pxaficp_device.dev.platform_data = info; } -static struct platform_device pxartc_device = { - .name = "sa1100-rtc", - .id = -1, -}; - static struct platform_device *devices[] __initdata = { &pxamci_device, &udc_device, @@ -334,7 +329,6 @@ static struct platform_device *devices[] __initdata = { &pxaficp_device, &i2c_device, &i2s_device, - &pxartc_device, }; static int __init pxa_init(void) diff --git a/trunk/arch/arm/mach-sa1100/generic.c b/trunk/arch/arm/mach-sa1100/generic.c index 9ea71551fc04..2abdc419e984 100644 --- a/trunk/arch/arm/mach-sa1100/generic.c +++ b/trunk/arch/arm/mach-sa1100/generic.c @@ -324,11 +324,6 @@ void sa11x0_set_irda_data(struct irda_platform_data *irda) sa11x0ir_device.dev.platform_data = irda; } -static struct platform_device sa11x0rtc_device = { - .name = "sa1100-rtc", - .id = -1, -}; - static struct platform_device *sa11x0_devices[] __initdata = { &sa11x0udc_device, &sa11x0uart1_device, @@ -338,7 +333,6 @@ static struct platform_device *sa11x0_devices[] __initdata = { &sa11x0pcmcia_device, &sa11x0fb_device, &sa11x0mtd_device, - &sa11x0rtc_device, }; static int __init sa1100_init(void) diff --git a/trunk/arch/arm26/mm/init.c b/trunk/arch/arm26/mm/init.c index 7da8a5205678..e3ecaa453747 100644 --- a/trunk/arch/arm26/mm/init.c +++ b/trunk/arch/arm26/mm/init.c @@ -23,7 +23,6 @@ #include #include #include -#include #include #include @@ -102,6 +101,12 @@ struct node_info { int bootmap_pages; }; +#define PFN_DOWN(x) ((x) >> PAGE_SHIFT) +#define PFN_UP(x) (PAGE_ALIGN(x) >> PAGE_SHIFT) +#define PFN_SIZE(x) ((x) >> PAGE_SHIFT) +#define PFN_RANGE(s,e) PFN_SIZE(PAGE_ALIGN((unsigned long)(e)) - \ + (((unsigned long)(s)) & PAGE_MASK)) + /* * FIXME: We really want to avoid allocating the bootmap bitmap * over the top of the initrd. Hopefully, this is located towards diff --git a/trunk/arch/cris/kernel/setup.c b/trunk/arch/cris/kernel/setup.c index 619a6eefd893..1ba57efff60d 100644 --- a/trunk/arch/cris/kernel/setup.c +++ b/trunk/arch/cris/kernel/setup.c @@ -18,7 +18,6 @@ #include #include #include -#include #include @@ -89,6 +88,10 @@ setup_arch(char **cmdline_p) init_mm.end_data = (unsigned long) &_edata; init_mm.brk = (unsigned long) &_end; +#define PFN_UP(x) (((x) + PAGE_SIZE-1) >> PAGE_SHIFT) +#define PFN_DOWN(x) ((x) >> PAGE_SHIFT) +#define PFN_PHYS(x) ((x) << PAGE_SHIFT) + /* min_low_pfn points to the start of DRAM, start_pfn points * to the first DRAM pages after the kernel, and max_low_pfn * to the end of DRAM. diff --git a/trunk/arch/i386/Kconfig b/trunk/arch/i386/Kconfig index f17bd1d2707e..f7db71d0b913 100644 --- a/trunk/arch/i386/Kconfig +++ b/trunk/arch/i386/Kconfig @@ -231,15 +231,6 @@ config SCHED_SMT cost of slightly increased overhead in some places. If unsure say N here. -config SCHED_MC - bool "Multi-core scheduler support" - depends on SMP - default y - help - Multi-core scheduler support improves the CPU scheduler's decision - making when dealing with multi-core CPU chips at a cost of slightly - increased overhead in some places. If unsure say N here. - source "kernel/Kconfig.preempt" config X86_UP_APIC diff --git a/trunk/arch/i386/boot/video.S b/trunk/arch/i386/boot/video.S index 0000a2674537..2ac40c8244c4 100644 --- a/trunk/arch/i386/boot/video.S +++ b/trunk/arch/i386/boot/video.S @@ -1924,7 +1924,6 @@ skip10: movb %ah, %al ret store_edid: -#ifdef CONFIG_FB_FIRMWARE_EDID pushw %es # just save all registers pushw %ax pushw %bx @@ -1955,7 +1954,6 @@ store_edid: popw %bx popw %ax popw %es -#endif ret # VIDEO_SELECT-only variables diff --git a/trunk/arch/i386/kernel/cpu/common.c b/trunk/arch/i386/kernel/cpu/common.c index a06a49075f10..7e3d6b6a4e96 100644 --- a/trunk/arch/i386/kernel/cpu/common.c +++ b/trunk/arch/i386/kernel/cpu/common.c @@ -266,7 +266,7 @@ static void __init early_cpu_detect(void) void __cpuinit generic_identify(struct cpuinfo_x86 * c) { u32 tfms, xlvl; - int ebx; + int junk; if (have_cpuid_p()) { /* Get vendor name */ @@ -282,7 +282,7 @@ void __cpuinit generic_identify(struct cpuinfo_x86 * c) /* Intel-defined flags: level 0x00000001 */ if ( c->cpuid_level >= 0x00000001 ) { u32 capability, excap; - cpuid(0x00000001, &tfms, &ebx, &excap, &capability); + cpuid(0x00000001, &tfms, &junk, &excap, &capability); c->x86_capability[0] = capability; c->x86_capability[4] = excap; c->x86 = (tfms >> 8) & 15; @@ -292,11 +292,6 @@ void __cpuinit generic_identify(struct cpuinfo_x86 * c) if (c->x86 >= 0x6) c->x86_model += ((tfms >> 16) & 0xF) << 4; c->x86_mask = tfms & 15; -#ifdef CONFIG_SMP - c->apicid = phys_pkg_id((ebx >> 24) & 0xFF, 0); -#else - c->apicid = (ebx >> 24) & 0xFF; -#endif } else { /* Have CPUID level 0 only - unheard of */ c->x86 = 4; @@ -479,6 +474,7 @@ void __cpuinit detect_ht(struct cpuinfo_x86 *c) cpuid(1, &eax, &ebx, &ecx, &edx); + c->apicid = phys_pkg_id((ebx >> 24) & 0xFF, 0); if (!cpu_has(c, X86_FEATURE_HT) || cpu_has(c, X86_FEATURE_CMP_LEGACY)) return; diff --git a/trunk/arch/i386/kernel/cpu/intel_cacheinfo.c b/trunk/arch/i386/kernel/cpu/intel_cacheinfo.c index 9df87b03612c..ce61921369e5 100644 --- a/trunk/arch/i386/kernel/cpu/intel_cacheinfo.c +++ b/trunk/arch/i386/kernel/cpu/intel_cacheinfo.c @@ -173,10 +173,6 @@ unsigned int __cpuinit init_intel_cacheinfo(struct cpuinfo_x86 *c) unsigned int trace = 0, l1i = 0, l1d = 0, l2 = 0, l3 = 0; /* Cache sizes */ unsigned int new_l1d = 0, new_l1i = 0; /* Cache sizes from cpuid(4) */ unsigned int new_l2 = 0, new_l3 = 0, i; /* Cache sizes from cpuid(4) */ - unsigned int l2_id = 0, l3_id = 0, num_threads_sharing, index_msb; -#ifdef CONFIG_SMP - unsigned int cpu = (c == &boot_cpu_data) ? 0 : (c - cpu_data); -#endif if (c->cpuid_level > 3) { static int is_initialized; @@ -209,15 +205,9 @@ unsigned int __cpuinit init_intel_cacheinfo(struct cpuinfo_x86 *c) break; case 2: new_l2 = this_leaf.size/1024; - num_threads_sharing = 1 + this_leaf.eax.split.num_threads_sharing; - index_msb = get_count_order(num_threads_sharing); - l2_id = c->apicid >> index_msb; break; case 3: new_l3 = this_leaf.size/1024; - num_threads_sharing = 1 + this_leaf.eax.split.num_threads_sharing; - index_msb = get_count_order(num_threads_sharing); - l3_id = c->apicid >> index_msb; break; default: break; @@ -225,19 +215,11 @@ unsigned int __cpuinit init_intel_cacheinfo(struct cpuinfo_x86 *c) } } } - /* - * Don't use cpuid2 if cpuid4 is supported. For P4, we use cpuid2 for - * trace cache - */ - if ((num_cache_leaves == 0 || c->x86 == 15) && c->cpuid_level > 1) { + if (c->cpuid_level > 1) { /* supports eax=2 call */ int i, j, n; int regs[4]; unsigned char *dp = (unsigned char *)regs; - int only_trace = 0; - - if (num_cache_leaves != 0 && c->x86 == 15) - only_trace = 1; /* Number of times to iterate */ n = cpuid_eax(2) & 0xFF; @@ -259,8 +241,6 @@ unsigned int __cpuinit init_intel_cacheinfo(struct cpuinfo_x86 *c) while (cache_table[k].descriptor != 0) { if (cache_table[k].descriptor == des) { - if (only_trace && cache_table[k].cache_type != LVL_TRACE) - break; switch (cache_table[k].cache_type) { case LVL_1_INST: l1i += cache_table[k].size; @@ -286,45 +266,34 @@ unsigned int __cpuinit init_intel_cacheinfo(struct cpuinfo_x86 *c) } } } - } - if (new_l1d) - l1d = new_l1d; + if (new_l1d) + l1d = new_l1d; - if (new_l1i) - l1i = new_l1i; + if (new_l1i) + l1i = new_l1i; - if (new_l2) { - l2 = new_l2; -#ifdef CONFIG_SMP - cpu_llc_id[cpu] = l2_id; -#endif - } + if (new_l2) + l2 = new_l2; - if (new_l3) { - l3 = new_l3; -#ifdef CONFIG_SMP - cpu_llc_id[cpu] = l3_id; -#endif - } - - if (trace) - printk (KERN_INFO "CPU: Trace cache: %dK uops", trace); - else if ( l1i ) - printk (KERN_INFO "CPU: L1 I cache: %dK", l1i); + if (new_l3) + l3 = new_l3; - if (l1d) - printk(", L1 D cache: %dK\n", l1d); - else - printk("\n"); + if ( trace ) + printk (KERN_INFO "CPU: Trace cache: %dK uops", trace); + else if ( l1i ) + printk (KERN_INFO "CPU: L1 I cache: %dK", l1i); + if ( l1d ) + printk(", L1 D cache: %dK\n", l1d); + else + printk("\n"); + if ( l2 ) + printk(KERN_INFO "CPU: L2 cache: %dK\n", l2); + if ( l3 ) + printk(KERN_INFO "CPU: L3 cache: %dK\n", l3); - if (l2) - printk(KERN_INFO "CPU: L2 cache: %dK\n", l2); - - if (l3) - printk(KERN_INFO "CPU: L3 cache: %dK\n", l3); - - c->x86_cache_size = l3 ? l3 : (l2 ? l2 : (l1i+l1d)); + c->x86_cache_size = l3 ? l3 : (l2 ? l2 : (l1i+l1d)); + } return l2; } diff --git a/trunk/arch/i386/kernel/setup.c b/trunk/arch/i386/kernel/setup.c index 8c08660b4e5d..6917daa159ab 100644 --- a/trunk/arch/i386/kernel/setup.c +++ b/trunk/arch/i386/kernel/setup.c @@ -46,7 +46,6 @@ #include #include #include -#include #include