# This is a BitKeeper generated diff -Nru style patch. # # ChangeSet # 2004/02/02 17:24:16-05:00 len.brown@intel.com # [ACPI] proposed fix for AML parameter passing from Bob Moore # http://bugzilla.kernel.org/show_bug.cgi?id=1766 # # drivers/acpi/dispatcher/dsmthdat.c # 2004/02/02 12:14:13-05:00 len.brown@intel.com +3 -2 # proposed fix for AML parameter passing from Bob Moore # http://bugzilla.kernel.org/show_bug.cgi?id=1766 # # ChangeSet # 2004/02/01 18:17:14-08:00 B.Zolnierkiewicz@elka.pw.edu.pl # [PATCH] fix/improve modular IDE # # This has been in -mm since 2.6.1-mm5 # # - IDE can be used as module again (compiles and works), # this fixes bugzilla bugs #576 and #1700 # - separate module for probing is no longer required # - generic/default host driver is available as ide_generic module # # This contains the build fixes by Adrian Bunk and Andrew Morton. # # include/linux/ide.h # 2004/02/01 10:09:12-08:00 B.Zolnierkiewicz@elka.pw.edu.pl +0 -1 # fix/improve modular IDE # # drivers/ide/pci/Makefile # 2004/02/01 10:09:12-08:00 B.Zolnierkiewicz@elka.pw.edu.pl +0 -1 # fix/improve modular IDE # # drivers/ide/legacy/Makefile # 2004/02/01 10:19:06-08:00 B.Zolnierkiewicz@elka.pw.edu.pl +0 -7 # fix/improve modular IDE # # drivers/ide/ide.c # 2004/02/01 10:09:12-08:00 B.Zolnierkiewicz@elka.pw.edu.pl +6 -43 # fix/improve modular IDE # # drivers/ide/ide-probe.c # 2004/02/01 10:09:12-08:00 B.Zolnierkiewicz@elka.pw.edu.pl +2 -23 # fix/improve modular IDE # # drivers/ide/ide-generic.c # 2004/02/01 18:17:09-08:00 B.Zolnierkiewicz@elka.pw.edu.pl +34 -0 # # drivers/ide/Makefile # 2004/02/01 10:18:30-08:00 B.Zolnierkiewicz@elka.pw.edu.pl +27 -11 # fix/improve modular IDE # # drivers/ide/Kconfig # 2004/02/01 10:09:12-08:00 B.Zolnierkiewicz@elka.pw.edu.pl +6 -0 # fix/improve modular IDE # # drivers/block/ll_rw_blk.c # 2004/02/01 10:09:12-08:00 B.Zolnierkiewicz@elka.pw.edu.pl +2 -0 # fix/improve modular IDE # # drivers/ide/ide-generic.c # 2004/02/01 18:17:09-08:00 B.Zolnierkiewicz@elka.pw.edu.pl +0 -0 # BitKeeper file /home/torvalds/v2.5/linux/drivers/ide/ide-generic.c # # BitKeeper/deleted/.del-Makefile~4e47de18b7a73660 # 2004/02/01 18:17:09-08:00 B.Zolnierkiewicz@elka.pw.edu.pl +0 -0 # Delete: drivers/ide/ppc/Makefile # # ChangeSet # 2004/02/01 16:17:10-08:00 davem@nuts.davemloft.net # [COMPAT]: Fix TUNSETIFF ioctl compat, it takes an ifreq ptr not an int. # Thanks to Eric Brower for spotting this. # # include/linux/compat_ioctl.h # 2004/02/01 16:14:24-08:00 davem@nuts.davemloft.net +0 -1 # [COMPAT]: Fix TUNSETIFF ioctl compat, it takes an ifreq ptr not an int. # # Thanks to Eric Brower for spotting this. # # fs/compat_ioctl.c # 2004/02/01 16:14:24-08:00 davem@nuts.davemloft.net +1 -0 # [COMPAT]: Fix TUNSETIFF ioctl compat, it takes an ifreq ptr not an int. # # Thanks to Eric Brower for spotting this. # # ChangeSet # 2004/02/01 12:50:52-08:00 B.Zolnierkiewicz@elka.pw.edu.pl # [PATCH] fix issues with loading PCI IDE drivers as modules # # From: Davin McCall # # Set hwif->chipset to ide_forced if it was forced by kernel parameters. # # Set hwif->chipset to ide_generic for hwifs controlled by generic IDE # code, so they wont be taken by setup_pci.c:ide_match_hwif(). # # Patch also fixes /proc/ide/ideX/model to report "generic" instead of # "(none)" for default hwifs. # # This has been in -mm since 2.6.1-mm1. # # include/linux/ide.h # 2004/02/01 10:06:55-08:00 B.Zolnierkiewicz@elka.pw.edu.pl +1 -1 # fix issues with loading PCI IDE drivers as modules # # drivers/ide/setup-pci.c # 2004/02/01 10:06:55-08:00 B.Zolnierkiewicz@elka.pw.edu.pl +1 -1 # fix issues with loading PCI IDE drivers as modules # # drivers/ide/pci/cmd640.c # 2004/02/01 10:06:55-08:00 B.Zolnierkiewicz@elka.pw.edu.pl +1 -1 # fix issues with loading PCI IDE drivers as modules # # drivers/ide/ide.c # 2004/02/01 10:06:55-08:00 B.Zolnierkiewicz@elka.pw.edu.pl +1 -1 # fix issues with loading PCI IDE drivers as modules # # drivers/ide/ide-proc.c # 2004/02/01 10:06:55-08:00 B.Zolnierkiewicz@elka.pw.edu.pl +3 -1 # fix issues with loading PCI IDE drivers as modules # # drivers/ide/ide-probe.c # 2004/02/01 10:06:55-08:00 B.Zolnierkiewicz@elka.pw.edu.pl +2 -0 # fix issues with loading PCI IDE drivers as modules # # ChangeSet # 2004/02/01 12:49:23-08:00 akpm@osdl.org # [PATCH] fix the build for NR_CPUS > 4*BITS_PER_LONG # # You can't just cast cpumasks. It doesn't compile if NR_CPUS is greater than # 4 * BITS_PER_LONG. # # drivers/pci/probe.c # 2004/02/01 12:13:22-08:00 akpm@osdl.org +5 -1 # fix the build for NR_CPUS > 4*BITS_PER_LONG # # ChangeSet # 2004/02/01 08:58:02-05:00 bcollins@debian.org # IEEE1394(r1116): Make sure to unregister addr space when a driver is removed. # # drivers/ieee1394/highlevel.c # 2004/02/01 08:57:10-05:00 bcollins@debian.org +33 -36 # (r1116): Make sure to unregister addr space when a driver is removed. # # ChangeSet # 2004/02/01 08:56:12-05:00 bcollins@debian.org # IEEE1394(r1112): Adds a "ieee1394_guid" attribute to the scsi device for sbp2. # # drivers/ieee1394/sbp2.h # 2004/02/01 08:55:17-05:00 bcollins@debian.org +3 -0 # (r1112): Adds a "ieee1394_guid" attribute to the scsi device for sbp2. # # drivers/ieee1394/sbp2.c # 2004/02/01 08:55:17-05:00 bcollins@debian.org +29 -7 # (r1112): Adds a "ieee1394_guid" attribute to the scsi device for sbp2. # # ChangeSet # 2004/01/31 13:33:13-08:00 torvalds@home.osdl.org # Make EHCI have a 20ms power-on to power-good timeout. # # This should fix some picky USB devices. # # drivers/usb/host/ehci-hub.c # 2004/01/31 13:33:09-08:00 torvalds@home.osdl.org +1 -1 # Make EHCI have a 20ms power-on to power-good timeout. # # This should fix some picky USB devices. # # ChangeSet # 2004/01/31 12:22:51-08:00 akpm@osdl.org # [PATCH] ppc32: MBX MAC address fix # # From Tom Rini # # On the MBX the kernel made an assumption about where the MAC address would # be in the VPD (Vital Product Data). However, the documentation for the # firmware (EPPC-Bug) describes the format of the VPD and makes no # guarrantees about the location of any VPD record. It does however describe # the format of each record type and the MAC address record will be of type # '08' and of size 6. This changes the code so that instead of assuming a # position, it searches for the record, which I assume is also what EPPC-Bug # does. # # arch/ppc/boot/simple/embed_config.c # 2004/01/31 00:15:24-08:00 akpm@osdl.org +13 -3 # ppc32: MBX MAC address fix # # ChangeSet # 2004/01/31 11:46:20-08:00 torvalds@home.osdl.org # Upgrade x86 defconfig to something less ancient. # # arch/i386/defconfig # 2004/01/31 11:46:16-08:00 torvalds@home.osdl.org +250 -174 # Upgrade x86 defconfig to something less ancient. # # ChangeSet # 2004/01/31 10:06:29-08:00 akpm@osdl.org # [PATCH] RAID-6: x86-64 crash workaround # # From: "H. Peter Anvin" # # Apparently, on x86-64, the stack isn't always aligned properly (16 bytes) # in the kernel at the moment. This causes the RAID-6 code to crash the # system. This patch is a workaround for that; the right thing is to muck # with the assembly entrypoints to enforce proper stack alignment. However, # that's not anything I feel comfortable doing in an evening, especially # since I don't have a machine on which I can test the resulting kernels. # # drivers/md/raid6x86.h # 2004/01/31 00:15:37-08:00 akpm@osdl.org +8 -5 # RAID-6: x86-64 crash workaround # # ChangeSet # 2004/01/31 10:05:21-08:00 akpm@osdl.org # [PATCH] s390: sclp bug fixes. # # From: Martin Schwidefsky # # SCLP console/tty fixes: # # - Fix incorrect state change of SCLP_RUNNING flag in interrupt handler # # - Suppress emission of empty buffers to prevent stack overflow # # - Fix off by one error in sclp_write (used to return # of chars written + 1) # # - Prevent sclp_tty_write_string from waiting in interrupt (during flush) # # - Fix deadlock after TIOCSCLPSNL ioctl # # - Fix sclp_tty_chars_in_buffer calculation # # drivers/s390/char/sclp_tty.c # 2004/01/31 00:15:35-08:00 akpm@osdl.org +18 -6 # s390: sclp bug fixes. # # drivers/s390/char/sclp_rw.c # 2004/01/31 00:15:35-08:00 akpm@osdl.org +1 -1 # s390: sclp bug fixes. # # drivers/s390/char/sclp_con.c # 2004/01/31 00:15:35-08:00 akpm@osdl.org +2 -1 # s390: sclp bug fixes. # # drivers/s390/char/sclp.c # 2004/01/31 00:15:35-08:00 akpm@osdl.org +3 -2 # s390: sclp bug fixes. # # ChangeSet # 2004/01/31 10:04:17-08:00 akpm@osdl.org # [PATCH] s390: inline assembly constraints. # # From: Martin Schwidefsky # # s390 inline assembly bug-fixes: # # - Add memory barriers to spinlocks, atomic variable functions and to # test_and_{set,clear,change}_bit. # # - Add "=m" and "m" contraints to tell gcc that the content of a variable # is in fact used. # # - Replace "+m" constraints by "=m" on the output and "m" on the input list. # # - Use c-implemtation for ffz and __ffs. # # - Use generic c-implemtation for ffs and fls. # # include/asm-s390/uaccess.h # 2004/01/31 00:15:34-08:00 akpm@osdl.org +2 -2 # s390: inline assembly constraints. # # include/asm-s390/tlbflush.h # 2004/01/31 00:15:34-08:00 akpm@osdl.org +1 -1 # s390: inline assembly constraints. # # include/asm-s390/timex.h # 2004/01/31 00:15:34-08:00 akpm@osdl.org +2 -2 # s390: inline assembly constraints. # # include/asm-s390/system.h # 2004/01/31 00:15:34-08:00 akpm@osdl.org +50 -47 # s390: inline assembly constraints. # # include/asm-s390/spinlock.h # 2004/01/31 00:15:34-08:00 akpm@osdl.org +34 -30 # s390: inline assembly constraints. # # include/asm-s390/semaphore.h # 2004/01/31 00:15:34-08:00 akpm@osdl.org +3 -3 # s390: inline assembly constraints. # # include/asm-s390/rwsem.h # 2004/01/31 00:15:34-08:00 akpm@osdl.org +74 -73 # s390: inline assembly constraints. # # include/asm-s390/processor.h # 2004/01/31 00:15:34-08:00 akpm@osdl.org +23 -18 # s390: inline assembly constraints. # # include/asm-s390/pgtable.h # 2004/01/31 00:15:34-08:00 akpm@osdl.org +6 -2 # s390: inline assembly constraints. # # include/asm-s390/div64.h # 2004/01/31 00:15:34-08:00 akpm@osdl.org +2 -2 # s390: inline assembly constraints. # # include/asm-s390/checksum.h # 2004/01/31 00:15:34-08:00 akpm@osdl.org +2 -2 # s390: inline assembly constraints. # # include/asm-s390/byteorder.h # 2004/01/31 00:15:34-08:00 akpm@osdl.org +3 -3 # s390: inline assembly constraints. # # include/asm-s390/bitops.h # 2004/01/31 00:15:34-08:00 akpm@osdl.org +55 -164 # s390: inline assembly constraints. # # include/asm-s390/atomic.h # 2004/01/31 00:15:34-08:00 akpm@osdl.org +13 -8 # s390: inline assembly constraints. # # ChangeSet # 2004/01/31 10:03:17-08:00 akpm@osdl.org # [PATCH] s390: general update. # # From: Martin Schwidefsky # # s390 general update: # # - Add archhelp for "make image". # # - 32-bit execve fix. # # - Export some symbols: sys_ioctl, put_files_struct & ccw_device_work. # # - Minor cleanups in arch/s390/mm/init.c & drivers/s390/net/ctctty.c. # # kernel/exit.c # 2004/01/31 00:15:34-08:00 akpm@osdl.org +2 -0 # s390: general update. # # drivers/s390/net/ctctty.c # 2004/01/31 00:15:34-08:00 akpm@osdl.org +2 -4 # s390: general update. # # drivers/s390/cio/device.c # 2004/01/31 00:15:34-08:00 akpm@osdl.org +1 -0 # s390: general update. # # arch/s390/mm/init.c # 2004/01/31 00:15:34-08:00 akpm@osdl.org +0 -2 # s390: general update. # # arch/s390/kernel/s390_ksyms.c # 2004/01/31 00:15:34-08:00 akpm@osdl.org +2 -0 # s390: general update. # # arch/s390/kernel/compat_linux.c # 2004/01/31 00:15:34-08:00 akpm@osdl.org +2 -1 # s390: general update. # # arch/s390/defconfig # 2004/01/31 00:15:34-08:00 akpm@osdl.org +1 -0 # s390: general update. # # arch/s390/Makefile # 2004/01/31 00:15:34-08:00 akpm@osdl.org +5 -0 # s390: general update. # # ChangeSet # 2004/01/31 10:02:26-08:00 akpm@osdl.org # [PATCH] Trivial cleanups to hugepage support # # From: David Gibson # # These are some trivial cleanups to the hugepage ppc64 support # # arch/ppc64/mm/hugetlbpage.c # 2004/01/31 00:15:33-08:00 akpm@osdl.org +4 -4 # Trivial cleanups to hugepage support # # ChangeSet # 2004/01/31 10:01:33-08:00 akpm@osdl.org # [PATCH] ppc64: use CONFIG_MAGIC_SYSRQ around xmon sysrq code # # From: Anton Blanchard # # arch/ppc64/xmon/start.c # 2004/01/31 00:15:33-08:00 akpm@osdl.org +8 -0 # ppc64: use CONFIG_MAGIC_SYSRQ around xmon sysrq code # # ChangeSet # 2004/01/31 10:00:40-08:00 akpm@osdl.org # [PATCH] ppc64: SLB rewrite # # From: Anton Blanchard # # The current SLB handling code has a number of problems: # # - We loop trying to find an empty SLB entry before deciding to cast one # out. On large working sets this really hurts since the SLB is always full # and we end up looping through all 64 entries unnecessarily. # # - During castout we currently invalidate the entry we are replacing. This # is to avoid a nasty race where the entry is in the ERAT but not the SLB and # another cpu does a tlbie that removes the ERAT at a critical point. If # this race is fixed the SLB can be removed. # # - The SLB prefault code doesnt work properly # # The following patch addresses all the above concerns and adds some more # optimisations: # # - feature nop out some segment table only code # # - slb invalidate the kernel segment on context switch (avoids us having to # slb invalidate at each cast out) # # - optimise flush on context switch, the lazy tlb stuff avoids it being # called when going from userspace to kernel thread, but it gets called when # going to kernel thread to userspace. In many cases we are returning to the # same userspace task, we now check for this and avoid the flush # # - use the optimised POWER4 mtcrf where possible # # include/asm-ppc64/paca.h # 2004/01/31 00:15:32-08:00 akpm@osdl.org +9 -14 # ppc64: SLB rewrite # # include/asm-ppc64/mmu_context.h # 2004/01/31 00:15:32-08:00 akpm@osdl.org +10 -1 # ppc64: SLB rewrite # # include/asm-ppc64/mmu.h # 2004/01/31 00:15:32-08:00 akpm@osdl.org +0 -8 # ppc64: SLB rewrite # # include/asm-ppc64/cputable.h # 2004/01/31 00:15:32-08:00 akpm@osdl.org +8 -1 # ppc64: SLB rewrite # # arch/ppc64/kernel/stab.c # 2004/01/31 00:15:32-08:00 akpm@osdl.org +243 -189 # ppc64: SLB rewrite # # arch/ppc64/kernel/process.c # 2004/01/31 00:15:32-08:00 akpm@osdl.org +24 -0 # ppc64: SLB rewrite # # arch/ppc64/kernel/pacaData.c # 2004/01/31 00:15:32-08:00 akpm@osdl.org +0 -1 # ppc64: SLB rewrite # # arch/ppc64/kernel/head.S # 2004/01/31 00:15:32-08:00 akpm@osdl.org +90 -67 # ppc64: SLB rewrite # # ChangeSet # 2004/01/31 09:59:52-08:00 akpm@osdl.org # [PATCH] ppc64: fix && vs & bugs in lparcfg, from Julie DeWandel # # From: Anton Blanchard # # arch/ppc64/kernel/lparcfg.c # 2004/01/31 00:15:31-08:00 akpm@osdl.org +5 -5 # ppc64: fix && vs & bugs in lparcfg, from Julie DeWandel # # ChangeSet # 2004/01/31 09:59:07-08:00 akpm@osdl.org # [PATCH] ppc64: export memchr and csum_partial # # From: Anton Blanchard # # arch/ppc64/kernel/ppc_ksyms.c # 2004/01/31 00:15:30-08:00 akpm@osdl.org +2 -2 # ppc64: export memchr and csum_partial # # ChangeSet # 2004/01/31 09:58:34-08:00 akpm@osdl.org # [PATCH] ppc64: add/remove config.h # # From: Anton Blanchard # # include/asm-ppc64/processor.h # 2004/01/31 00:15:29-08:00 akpm@osdl.org +1 -0 # ppc64: add/remove config.h # # include/asm-ppc64/pgtable.h # 2004/01/31 00:15:29-08:00 akpm@osdl.org +1 -0 # ppc64: add/remove config.h # # include/asm-ppc64/mmu_context.h # 2004/01/31 00:15:29-08:00 akpm@osdl.org +1 -0 # ppc64: add/remove config.h # # include/asm-ppc64/mmu.h # 2004/01/31 00:15:29-08:00 akpm@osdl.org +1 -0 # ppc64: add/remove config.h # # include/asm-ppc64/cputable.h # 2004/01/31 00:15:29-08:00 akpm@osdl.org +2 -0 # ppc64: add/remove config.h # # arch/ppc64/xmon/start.c # 2004/01/31 00:15:29-08:00 akpm@osdl.org +1 -0 # ppc64: add/remove config.h # # arch/ppc64/mm/hugetlbpage.c # 2004/01/31 00:15:29-08:00 akpm@osdl.org +0 -1 # ppc64: add/remove config.h # # arch/ppc64/mm/hash_low.S # 2004/01/31 00:15:29-08:00 akpm@osdl.org +0 -1 # ppc64: add/remove config.h # # arch/ppc64/kernel/viopath.c # 2004/01/31 00:15:29-08:00 akpm@osdl.org +0 -1 # ppc64: add/remove config.h # # arch/ppc64/kernel/sys_ppc32.c # 2004/01/31 00:15:29-08:00 akpm@osdl.org +1 -0 # ppc64: add/remove config.h # # arch/ppc64/kernel/signal32.c # 2004/01/31 00:15:29-08:00 akpm@osdl.org +1 -0 # ppc64: add/remove config.h # # arch/ppc64/kernel/signal.c # 2004/01/31 00:15:29-08:00 akpm@osdl.org +1 -0 # ppc64: add/remove config.h # # arch/ppc64/kernel/rtas_flash.c # 2004/01/31 00:15:29-08:00 akpm@osdl.org +0 -2 # ppc64: add/remove config.h # # arch/ppc64/kernel/proc_ppc64.c # 2004/01/31 00:15:29-08:00 akpm@osdl.org +1 -0 # ppc64: add/remove config.h # # arch/ppc64/kernel/lparcfg.c # 2004/01/31 00:15:29-08:00 akpm@osdl.org +1 -0 # ppc64: add/remove config.h # # arch/ppc64/kernel/iSeries_VpdInfo.c # 2004/01/31 00:15:29-08:00 akpm@osdl.org +1 -0 # ppc64: add/remove config.h # # arch/ppc64/kernel/asm-offsets.c # 2004/01/31 00:15:29-08:00 akpm@osdl.org +1 -0 # ppc64: add/remove config.h # # ChangeSet # 2004/01/31 09:57:58-08:00 akpm@osdl.org # [PATCH] ppc64: Use preferred_console to select a reasonable default console # # From: Anton Blanchard # # Lets make a decent attempt to find out where your console is. The new # preferred_console stuff is pretty nice. # # arch/ppc64/kernel/setup.c # 2004/01/31 00:15:28-08:00 akpm@osdl.org +52 -1 # ppc64: Use preferred_console to select a reasonable default console # # ChangeSet # 2004/01/31 09:57:29-08:00 akpm@osdl.org # [PATCH] ppc64: defconfig update # # From: Anton Blanchard # # arch/ppc64/defconfig # 2004/01/31 00:15:27-08:00 akpm@osdl.org +106 -96 # ppc64: defconfig update # # ChangeSet # 2004/01/31 09:57:06-08:00 akpm@osdl.org # [PATCH] ppc64: missing set_fs(KERNEL_DS) in ppc32_timer_create, from Marcus Meissner # # From: Anton Blanchard # # Small obvious fix to ppc32_timer_create. Since sys_timer_create access # structures we pass on the stack, we need set_fs(KERNEL_DS). # # arch/ppc64/kernel/sys_ppc32.c # 2004/01/31 00:15:27-08:00 akpm@osdl.org +1 -0 # ppc64: missing set_fs(KERNEL_DS) in ppc32_timer_create, from Marcus Meissner # # ChangeSet # 2004/01/31 09:56:46-08:00 akpm@osdl.org # [PATCH] ppc64: fixes for compile with CONFIG_PROC_DEVICETREE=n, from Nathan Lynch # # From: Anton Blanchard # # - nop out proc_device_tree_add_node if CONFIG_PROC_DEVICETREE=n # # - stubs for procfs-related functions when CONFIG_PROC_DEVICETREE=n # # include/linux/proc_fs.h # 2004/01/31 00:15:26-08:00 akpm@osdl.org +7 -1 # ppc64: fixes for compile with CONFIG_PROC_DEVICETREE=n, from Nathan Lynch # # arch/ppc64/kernel/prom.c # 2004/01/31 00:15:26-08:00 akpm@osdl.org +12 -0 # ppc64: fixes for compile with CONFIG_PROC_DEVICETREE=n, from Nathan Lynch # # ChangeSet # 2004/01/31 09:56:28-08:00 akpm@osdl.org # [PATCH] ppc64: lparcfg_write # # From: Anton Blanchard # # Add lparcfg_write() for changing SPLPAR system parameters # # include/asm-ppc64/hvcall.h # 2004/01/31 00:15:26-08:00 akpm@osdl.org +1 -0 # ppc64: lparcfg_write # # arch/ppc64/kernel/lparcfg.c # 2004/01/31 00:15:26-08:00 akpm@osdl.org +106 -1 # ppc64: lparcfg_write # # ChangeSet # 2004/01/31 09:56:15-08:00 akpm@osdl.org # [PATCH] ppc64: add missing include guards, from Nathan Lynch # # From: Anton Blanchard # # add missing include guards, from Nathan Lynch # # include/asm-ppc64/serial.h # 2004/01/31 00:15:25-08:00 akpm@osdl.org +5 -1 # ppc64: add missing include guards, from Nathan Lynch # # include/asm-ppc64/ptrace-common.h # 2004/01/31 00:15:25-08:00 akpm@osdl.org +4 -0 # ppc64: add missing include guards, from Nathan Lynch # # include/asm-ppc64/ppc_asm.h # 2004/01/31 00:15:25-08:00 akpm@osdl.org +4 -0 # ppc64: add missing include guards, from Nathan Lynch # # include/asm-ppc64/percpu.h # 2004/01/31 00:15:25-08:00 akpm@osdl.org +3 -3 # ppc64: add missing include guards, from Nathan Lynch # # include/asm-ppc64/hvcall.h # 2004/01/31 00:15:25-08:00 akpm@osdl.org +3 -0 # ppc64: add missing include guards, from Nathan Lynch # # include/asm-ppc64/bugs.h # 2004/01/31 00:15:25-08:00 akpm@osdl.org +4 -0 # ppc64: add missing include guards, from Nathan Lynch # # ChangeSet # 2004/01/31 09:56:03-08:00 akpm@osdl.org # [PATCH] ppc32: watchdog definition fixes # # From: Tom Rini # # Correct the defines for MC146818 RTCs, reg c is interrupts, reg d is not # watchdog (it's valid time & nvram). # # include/asm-ppc/todc.h # 2004/01/31 00:15:25-08:00 akpm@osdl.org +2 -2 # ppc32: watchdog definition fixes # # ChangeSet # 2004/01/31 01:11:03-05:00 mlindner@syskonnect.de # [PATCH] sk98lin: Reset Xmac when stopping the port # # * Clear the Xmac fifo before stopping the port # # drivers/net/sk98lin/skge.c # 2004/01/30 05:25:30-05:00 mlindner@syskonnect.de +7 -2 # sk98lin: Reset Xmac when stopping the port # # drivers/net/sk98lin/h/skversion.h # 2004/01/30 05:25:27-05:00 mlindner@syskonnect.de +5 -5 # sk98lin: Reset Xmac when stopping the port # # ChangeSet # 2004/01/30 11:21:01-08:00 davem@nuts.davemloft.net # [SPARC64]: Fix wakeup races in power.c, with help from Andrew Morton. # # arch/sparc64/kernel/power.c # 2004/01/30 11:18:34-08:00 davem@nuts.davemloft.net +2 -2 # [SPARC64]: Fix wakeup races in power.c, with help from Andrew Morton. # diff -Nru a/arch/i386/defconfig b/arch/i386/defconfig --- a/arch/i386/defconfig Mon Feb 2 22:02:19 2004 +++ b/arch/i386/defconfig Mon Feb 2 22:02:19 2004 @@ -10,7 +10,8 @@ # Code maturity level options # CONFIG_EXPERIMENTAL=y -# CONFIG_BROKEN is not set +CONFIG_CLEAN_COMPILE=y +CONFIG_STANDALONE=y # # General setup @@ -20,6 +21,7 @@ # CONFIG_BSD_PROCESS_ACCT is not set CONFIG_SYSCTL=y CONFIG_LOG_BUF_SHIFT=15 +# CONFIG_IKCONFIG is not set # CONFIG_EMBEDDED is not set CONFIG_KALLSYMS=y CONFIG_FUTEX=y @@ -27,6 +29,7 @@ CONFIG_IOSCHED_NOOP=y CONFIG_IOSCHED_AS=y CONFIG_IOSCHED_DEADLINE=y +# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set # # Loadable module support @@ -79,7 +82,8 @@ CONFIG_X86_GOOD_APIC=y CONFIG_X86_INTEL_USERCOPY=y CONFIG_X86_USE_PPRO_CHECKSUM=y -# CONFIG_HUGETLB_PAGE is not set +# CONFIG_HPET_TIMER is not set +# CONFIG_HPET_EMULATE_RTC is not set CONFIG_SMP=y CONFIG_NR_CPUS=8 CONFIG_PREEMPT=y @@ -100,20 +104,22 @@ # CONFIG_HIGHMEM64G is not set # CONFIG_MATH_EMULATION is not set CONFIG_MTRR=y +# CONFIG_EFI is not set CONFIG_HAVE_DEC_LOCK=y # # Power management options (ACPI, APM) # CONFIG_PM=y -# CONFIG_SOFTWARE_SUSPEND is not set +CONFIG_SOFTWARE_SUSPEND=y +# CONFIG_PM_DISK is not set # # ACPI (Advanced Configuration and Power Interface) Support # -CONFIG_ACPI_HT=y CONFIG_ACPI=y CONFIG_ACPI_BOOT=y +CONFIG_ACPI_INTERPRETER=y CONFIG_ACPI_SLEEP=y CONFIG_ACPI_SLEEP_PROC_FS=y CONFIG_ACPI_AC=y @@ -126,11 +132,11 @@ # CONFIG_ACPI_TOSHIBA is not set # CONFIG_ACPI_DEBUG is not set CONFIG_ACPI_BUS=y -CONFIG_ACPI_INTERPRETER=y CONFIG_ACPI_EC=y CONFIG_ACPI_POWER=y CONFIG_ACPI_PCI=y CONFIG_ACPI_SYSTEM=y +# CONFIG_ACPI_RELAXED_AML is not set # # APM (Advanced Power Management) BIOS Support @@ -151,6 +157,7 @@ CONFIG_PCI_GOANY=y CONFIG_PCI_BIOS=y CONFIG_PCI_DIRECT=y +# CONFIG_PCI_USE_VECTOR is not set CONFIG_PCI_LEGACY_PROC=y CONFIG_PCI_NAMES=y CONFIG_ISA=y @@ -173,13 +180,15 @@ # # Executable file formats # -CONFIG_KCORE_ELF=y -# CONFIG_KCORE_AOUT is not set CONFIG_BINFMT_ELF=y CONFIG_BINFMT_AOUT=y CONFIG_BINFMT_MISC=y # +# Device Drivers +# + +# # Generic Driver Options # # CONFIG_FW_LOADER is not set @@ -262,7 +271,6 @@ # CONFIG_BLK_DEV_OPTI621 is not set CONFIG_BLK_DEV_RZ1000=y CONFIG_BLK_DEV_IDEDMA_PCI=y -# CONFIG_BLK_DEV_IDE_TCQ is not set # CONFIG_BLK_DEV_IDEDMA_FORCED is not set CONFIG_IDEDMA_PCI_AUTO=y # CONFIG_IDEDMA_ONLYDISK is not set @@ -300,6 +308,7 @@ # SCSI device support # CONFIG_SCSI=y +CONFIG_SCSI_PROC_FS=y # # SCSI support type (disk, tape, CD-ROM) @@ -330,11 +339,14 @@ # CONFIG_SCSI_AIC7XXX is not set # CONFIG_SCSI_AIC7XXX_OLD is not set # CONFIG_SCSI_AIC79XX is not set -# CONFIG_SCSI_DPT_I2O is not set # CONFIG_SCSI_ADVANSYS is not set # CONFIG_SCSI_IN2000 is not set -# CONFIG_SCSI_AM53C974 is not set # CONFIG_SCSI_MEGARAID is not set +CONFIG_SCSI_SATA=y +# CONFIG_SCSI_SATA_SVW is not set +CONFIG_SCSI_ATA_PIIX=y +# CONFIG_SCSI_SATA_PROMISE is not set +# CONFIG_SCSI_SATA_VIA is not set # CONFIG_SCSI_BUSLOGIC is not set # CONFIG_SCSI_CPQFCTS is not set # CONFIG_SCSI_DMX3191D is not set @@ -346,22 +358,21 @@ # CONFIG_SCSI_GENERIC_NCR5380 is not set # CONFIG_SCSI_GENERIC_NCR5380_MMIO is not set # CONFIG_SCSI_IPS is not set -# CONFIG_SCSI_INITIO is not set # CONFIG_SCSI_INIA100 is not set # CONFIG_SCSI_PPA is not set # CONFIG_SCSI_IMM is not set # CONFIG_SCSI_NCR53C406A is not set # CONFIG_SCSI_SYM53C8XX_2 is not set -# CONFIG_SCSI_SYM53C8XX is not set # CONFIG_SCSI_PAS16 is not set -# CONFIG_SCSI_PCI2000 is not set -# CONFIG_SCSI_PCI2220I is not set # CONFIG_SCSI_PSI240I is not set # CONFIG_SCSI_QLOGIC_FAS is not set # CONFIG_SCSI_QLOGIC_ISP is not set # CONFIG_SCSI_QLOGIC_FC is not set # CONFIG_SCSI_QLOGIC_1280 is not set -# CONFIG_SCSI_SEAGATE is not set +CONFIG_SCSI_QLA2XXX_CONFIG=y +# CONFIG_SCSI_QLA21XX is not set +# CONFIG_SCSI_QLA22XX is not set +# CONFIG_SCSI_QLA23XX is not set # CONFIG_SCSI_SYM53C416 is not set # CONFIG_SCSI_DC395x is not set # CONFIG_SCSI_DC390T is not set @@ -402,7 +413,7 @@ # # -# Texas Instruments PCILynx requires I2C bit-banging +# Texas Instruments PCILynx requires I2C # CONFIG_IEEE1394_OHCI1394=y @@ -447,10 +458,67 @@ # CONFIG_INET_AH is not set # CONFIG_INET_ESP is not set # CONFIG_INET_IPCOMP is not set + +# +# IP: Virtual Server Configuration +# +# CONFIG_IP_VS is not set # CONFIG_IPV6 is not set # CONFIG_DECNET is not set # CONFIG_BRIDGE is not set -# CONFIG_NETFILTER is not set +CONFIG_NETFILTER=y +# CONFIG_NETFILTER_DEBUG is not set + +# +# IP: Netfilter Configuration +# +CONFIG_IP_NF_CONNTRACK=y +# CONFIG_IP_NF_FTP is not set +# CONFIG_IP_NF_IRC is not set +# CONFIG_IP_NF_TFTP is not set +# CONFIG_IP_NF_AMANDA is not set +CONFIG_IP_NF_QUEUE=y +CONFIG_IP_NF_IPTABLES=y +CONFIG_IP_NF_MATCH_LIMIT=y +CONFIG_IP_NF_MATCH_IPRANGE=y +CONFIG_IP_NF_MATCH_MAC=y +CONFIG_IP_NF_MATCH_PKTTYPE=y +CONFIG_IP_NF_MATCH_MARK=y +CONFIG_IP_NF_MATCH_MULTIPORT=y +CONFIG_IP_NF_MATCH_TOS=y +CONFIG_IP_NF_MATCH_RECENT=y +CONFIG_IP_NF_MATCH_ECN=y +CONFIG_IP_NF_MATCH_DSCP=y +CONFIG_IP_NF_MATCH_AH_ESP=y +CONFIG_IP_NF_MATCH_LENGTH=y +CONFIG_IP_NF_MATCH_TTL=y +CONFIG_IP_NF_MATCH_TCPMSS=y +CONFIG_IP_NF_MATCH_HELPER=y +CONFIG_IP_NF_MATCH_STATE=y +CONFIG_IP_NF_MATCH_CONNTRACK=y +CONFIG_IP_NF_MATCH_OWNER=y +CONFIG_IP_NF_FILTER=y +CONFIG_IP_NF_TARGET_REJECT=y +CONFIG_IP_NF_NAT=y +CONFIG_IP_NF_NAT_NEEDED=y +CONFIG_IP_NF_TARGET_MASQUERADE=y +CONFIG_IP_NF_TARGET_REDIRECT=y +CONFIG_IP_NF_TARGET_NETMAP=y +CONFIG_IP_NF_TARGET_SAME=y +# CONFIG_IP_NF_NAT_LOCAL is not set +# CONFIG_IP_NF_NAT_SNMP_BASIC is not set +CONFIG_IP_NF_MANGLE=y +CONFIG_IP_NF_TARGET_TOS=y +CONFIG_IP_NF_TARGET_ECN=y +CONFIG_IP_NF_TARGET_DSCP=y +CONFIG_IP_NF_TARGET_MARK=y +CONFIG_IP_NF_TARGET_CLASSIFY=y +CONFIG_IP_NF_TARGET_LOG=y +CONFIG_IP_NF_TARGET_ULOG=y +CONFIG_IP_NF_TARGET_TCPMSS=y +CONFIG_IP_NF_ARPTABLES=y +CONFIG_IP_NF_ARPFILTER=y +CONFIG_IP_NF_ARP_MANGLE=y # # SCTP Configuration (EXPERIMENTAL) @@ -459,7 +527,9 @@ # CONFIG_IP_SCTP is not set # CONFIG_ATM is not set # CONFIG_VLAN_8021Q is not set -# CONFIG_LLC is not set +# CONFIG_LLC2 is not set +# CONFIG_IPX is not set +# CONFIG_ATALK is not set # CONFIG_X25 is not set # CONFIG_LAPB is not set # CONFIG_NET_DIVERT is not set @@ -487,14 +557,13 @@ # CONFIG_BONDING is not set # CONFIG_EQUALIZER is not set # CONFIG_TUN is not set -# CONFIG_ETHERTAP is not set # CONFIG_NET_SB1000 is not set # # Ethernet (10 or 100Mbit) # CONFIG_NET_ETHERNET=y -# CONFIG_MII is not set +CONFIG_MII=y # CONFIG_HAPPYMEAL is not set # CONFIG_SUNGEM is not set # CONFIG_NET_VENDOR_3COM is not set @@ -517,6 +586,7 @@ # CONFIG_AC3200 is not set # CONFIG_APRICOT is not set # CONFIG_B44 is not set +# CONFIG_FORCEDETH is not set # CONFIG_CS89x0 is not set # CONFIG_DGRS is not set # CONFIG_EEPRO100 is not set @@ -567,8 +637,9 @@ # CONFIG_NET_RADIO is not set # -# Token Ring devices (depends on LLC=y) +# Token Ring devices # +# CONFIG_TR is not set # CONFIG_NET_FC is not set # CONFIG_RCPCI is not set # CONFIG_SHAPER is not set @@ -589,6 +660,11 @@ # CONFIG_IRDA is not set # +# Bluetooth support +# +# CONFIG_BT is not set + +# # ISDN subsystem # # CONFIG_ISDN_BOOL is not set @@ -659,6 +735,7 @@ CONFIG_SERIAL_8250=y # CONFIG_SERIAL_8250_CONSOLE is not set # CONFIG_SERIAL_8250_ACPI is not set +CONFIG_SERIAL_8250_NR_UARTS=4 # CONFIG_SERIAL_8250_EXTENDED is not set # @@ -673,20 +750,6 @@ # CONFIG_TIPAR is not set # -# I2C support -# -# CONFIG_I2C is not set - -# -# I2C Hardware Sensors Mainboard support -# - -# -# I2C Hardware Sensors Chip support -# -# CONFIG_I2C_SENSOR is not set - -# # Mice # # CONFIG_BUSMOUSE is not set @@ -713,7 +776,6 @@ # # Ftape, the floppy tape device driver # -# CONFIG_FTAPE is not set CONFIG_AGP=y # CONFIG_AGP_ALI is not set # CONFIG_AGP_ATI is not set @@ -732,11 +794,17 @@ # CONFIG_DRM_I810 is not set CONFIG_DRM_I830=y # CONFIG_DRM_MGA is not set +# CONFIG_DRM_SIS is not set # CONFIG_MWAVE is not set # CONFIG_RAW_DRIVER is not set # CONFIG_HANGCHECK_TIMER is not set # +# I2C support +# +# CONFIG_I2C is not set + +# # Multimedia devices # # CONFIG_VIDEO_DEV is not set @@ -747,138 +815,6 @@ # CONFIG_DVB is not set # -# File systems -# -CONFIG_EXT2_FS=y -# CONFIG_EXT2_FS_XATTR is not set -CONFIG_EXT3_FS=y -CONFIG_EXT3_FS_XATTR=y -# CONFIG_EXT3_FS_POSIX_ACL is not set -# CONFIG_EXT3_FS_SECURITY is not set -CONFIG_JBD=y -# CONFIG_JBD_DEBUG is not set -CONFIG_FS_MBCACHE=y -# CONFIG_REISERFS_FS is not set -# CONFIG_JFS_FS is not set -# CONFIG_XFS_FS is not set -# CONFIG_MINIX_FS is not set -# CONFIG_ROMFS_FS is not set -# CONFIG_QUOTA is not set -# CONFIG_AUTOFS_FS is not set -CONFIG_AUTOFS4_FS=y - -# -# CD-ROM/DVD Filesystems -# -CONFIG_ISO9660_FS=y -CONFIG_JOLIET=y -# CONFIG_ZISOFS is not set -CONFIG_UDF_FS=y - -# -# DOS/FAT/NT Filesystems -# -CONFIG_FAT_FS=y -CONFIG_MSDOS_FS=y -CONFIG_VFAT_FS=y -# CONFIG_NTFS_FS is not set - -# -# Pseudo filesystems -# -CONFIG_PROC_FS=y -# CONFIG_DEVFS_FS is not set -CONFIG_DEVPTS_FS=y -# CONFIG_DEVPTS_FS_XATTR is not set -CONFIG_TMPFS=y -CONFIG_RAMFS=y - -# -# Miscellaneous filesystems -# -# CONFIG_ADFS_FS is not set -# CONFIG_AFFS_FS is not set -# CONFIG_HFS_FS is not set -# CONFIG_BEFS_FS is not set -# CONFIG_BFS_FS is not set -# CONFIG_EFS_FS is not set -# CONFIG_CRAMFS is not set -# CONFIG_VXFS_FS is not set -# CONFIG_HPFS_FS is not set -# CONFIG_QNX4FS_FS is not set -# CONFIG_SYSV_FS is not set -# CONFIG_UFS_FS is not set - -# -# Network File Systems -# -CONFIG_NFS_FS=y -# CONFIG_NFS_V3 is not set -# CONFIG_NFS_V4 is not set -CONFIG_NFSD=y -# CONFIG_NFSD_V3 is not set -# CONFIG_NFSD_TCP is not set -CONFIG_LOCKD=y -CONFIG_EXPORTFS=y -CONFIG_SUNRPC=y -# CONFIG_SUNRPC_GSS is not set -# CONFIG_SMB_FS is not set -# CONFIG_CIFS is not set -# CONFIG_NCP_FS is not set -# CONFIG_CODA_FS is not set -# CONFIG_INTERMEZZO_FS is not set -# CONFIG_AFS_FS is not set - -# -# Partition Types -# -# CONFIG_PARTITION_ADVANCED is not set -CONFIG_MSDOS_PARTITION=y -CONFIG_NLS=y - -# -# Native Language Support -# -CONFIG_NLS_DEFAULT="iso8859-1" -CONFIG_NLS_CODEPAGE_437=y -# CONFIG_NLS_CODEPAGE_737 is not set -# CONFIG_NLS_CODEPAGE_775 is not set -# CONFIG_NLS_CODEPAGE_850 is not set -# CONFIG_NLS_CODEPAGE_852 is not set -# CONFIG_NLS_CODEPAGE_855 is not set -# CONFIG_NLS_CODEPAGE_857 is not set -# CONFIG_NLS_CODEPAGE_860 is not set -# CONFIG_NLS_CODEPAGE_861 is not set -# CONFIG_NLS_CODEPAGE_862 is not set -# CONFIG_NLS_CODEPAGE_863 is not set -# CONFIG_NLS_CODEPAGE_864 is not set -# CONFIG_NLS_CODEPAGE_865 is not set -# CONFIG_NLS_CODEPAGE_866 is not set -# CONFIG_NLS_CODEPAGE_869 is not set -# CONFIG_NLS_CODEPAGE_936 is not set -# CONFIG_NLS_CODEPAGE_950 is not set -# CONFIG_NLS_CODEPAGE_932 is not set -# CONFIG_NLS_CODEPAGE_949 is not set -# CONFIG_NLS_CODEPAGE_874 is not set -# CONFIG_NLS_ISO8859_8 is not set -# CONFIG_NLS_CODEPAGE_1250 is not set -# CONFIG_NLS_CODEPAGE_1251 is not set -CONFIG_NLS_ISO8859_1=y -# CONFIG_NLS_ISO8859_2 is not set -# CONFIG_NLS_ISO8859_3 is not set -# CONFIG_NLS_ISO8859_4 is not set -# CONFIG_NLS_ISO8859_5 is not set -# CONFIG_NLS_ISO8859_6 is not set -# CONFIG_NLS_ISO8859_7 is not set -# CONFIG_NLS_ISO8859_9 is not set -# CONFIG_NLS_ISO8859_13 is not set -# CONFIG_NLS_ISO8859_14 is not set -# CONFIG_NLS_ISO8859_15 is not set -# CONFIG_NLS_KOI8_R is not set -# CONFIG_NLS_KOI8_U is not set -# CONFIG_NLS_UTF8 is not set - -# # Graphics support # # CONFIG_FB is not set @@ -1057,7 +993,6 @@ # # USB Network adaptors # -# CONFIG_USB_AX8817X is not set # CONFIG_USB_CATC is not set # CONFIG_USB_KAWETH is not set # CONFIG_USB_PEGASUS is not set @@ -1077,30 +1012,170 @@ # # USB Miscellaneous drivers # +# CONFIG_USB_EMI62 is not set +# CONFIG_USB_EMI26 is not set # CONFIG_USB_TIGL is not set # CONFIG_USB_AUERSWALD is not set # CONFIG_USB_RIO500 is not set +# CONFIG_USB_LEGOTOWER is not set # CONFIG_USB_BRLVGER is not set # CONFIG_USB_LCD is not set +# CONFIG_USB_LED is not set # CONFIG_USB_TEST is not set + +# +# USB Gadget Support +# # CONFIG_USB_GADGET is not set # -# Bluetooth support +# File systems # -# CONFIG_BT is not set +CONFIG_EXT2_FS=y +# CONFIG_EXT2_FS_XATTR is not set +CONFIG_EXT3_FS=y +CONFIG_EXT3_FS_XATTR=y +# CONFIG_EXT3_FS_POSIX_ACL is not set +# CONFIG_EXT3_FS_SECURITY is not set +CONFIG_JBD=y +# CONFIG_JBD_DEBUG is not set +CONFIG_FS_MBCACHE=y +# CONFIG_REISERFS_FS is not set +# CONFIG_JFS_FS is not set +# CONFIG_XFS_FS is not set +# CONFIG_MINIX_FS is not set +# CONFIG_ROMFS_FS is not set +# CONFIG_QUOTA is not set +# CONFIG_AUTOFS_FS is not set +CONFIG_AUTOFS4_FS=y + +# +# CD-ROM/DVD Filesystems +# +CONFIG_ISO9660_FS=y +CONFIG_JOLIET=y +# CONFIG_ZISOFS is not set +CONFIG_UDF_FS=y + +# +# DOS/FAT/NT Filesystems +# +CONFIG_FAT_FS=y +CONFIG_MSDOS_FS=y +CONFIG_VFAT_FS=y +# CONFIG_NTFS_FS is not set + +# +# Pseudo filesystems +# +CONFIG_PROC_FS=y +CONFIG_PROC_KCORE=y +# CONFIG_DEVFS_FS is not set +CONFIG_DEVPTS_FS=y +# CONFIG_DEVPTS_FS_XATTR is not set +CONFIG_TMPFS=y +# CONFIG_HUGETLBFS is not set +# CONFIG_HUGETLB_PAGE is not set +CONFIG_RAMFS=y + +# +# Miscellaneous filesystems +# +# CONFIG_ADFS_FS is not set +# CONFIG_AFFS_FS is not set +# CONFIG_HFS_FS is not set +# CONFIG_BEFS_FS is not set +# CONFIG_BFS_FS is not set +# CONFIG_EFS_FS is not set +# CONFIG_CRAMFS is not set +# CONFIG_VXFS_FS is not set +# CONFIG_HPFS_FS is not set +# CONFIG_QNX4FS_FS is not set +# CONFIG_SYSV_FS is not set +# CONFIG_UFS_FS is not set + +# +# Network File Systems +# +CONFIG_NFS_FS=y +# CONFIG_NFS_V3 is not set +# CONFIG_NFS_V4 is not set +# CONFIG_NFS_DIRECTIO is not set +CONFIG_NFSD=y +# CONFIG_NFSD_V3 is not set +# CONFIG_NFSD_TCP is not set +CONFIG_LOCKD=y +CONFIG_EXPORTFS=y +CONFIG_SUNRPC=y +# CONFIG_SUNRPC_GSS is not set +# CONFIG_SMB_FS is not set +# CONFIG_CIFS is not set +# CONFIG_NCP_FS is not set +# CONFIG_CODA_FS is not set +# CONFIG_INTERMEZZO_FS is not set +# CONFIG_AFS_FS is not set + +# +# Partition Types +# +# CONFIG_PARTITION_ADVANCED is not set +CONFIG_MSDOS_PARTITION=y + +# +# Native Language Support +# +CONFIG_NLS=y +CONFIG_NLS_DEFAULT="iso8859-1" +CONFIG_NLS_CODEPAGE_437=y +# CONFIG_NLS_CODEPAGE_737 is not set +# CONFIG_NLS_CODEPAGE_775 is not set +# CONFIG_NLS_CODEPAGE_850 is not set +# CONFIG_NLS_CODEPAGE_852 is not set +# CONFIG_NLS_CODEPAGE_855 is not set +# CONFIG_NLS_CODEPAGE_857 is not set +# CONFIG_NLS_CODEPAGE_860 is not set +# CONFIG_NLS_CODEPAGE_861 is not set +# CONFIG_NLS_CODEPAGE_862 is not set +# CONFIG_NLS_CODEPAGE_863 is not set +# CONFIG_NLS_CODEPAGE_864 is not set +# CONFIG_NLS_CODEPAGE_865 is not set +# CONFIG_NLS_CODEPAGE_866 is not set +# CONFIG_NLS_CODEPAGE_869 is not set +# CONFIG_NLS_CODEPAGE_936 is not set +# CONFIG_NLS_CODEPAGE_950 is not set +# CONFIG_NLS_CODEPAGE_932 is not set +# CONFIG_NLS_CODEPAGE_949 is not set +# CONFIG_NLS_CODEPAGE_874 is not set +# CONFIG_NLS_ISO8859_8 is not set +# CONFIG_NLS_CODEPAGE_1250 is not set +# CONFIG_NLS_CODEPAGE_1251 is not set +CONFIG_NLS_ISO8859_1=y +# CONFIG_NLS_ISO8859_2 is not set +# CONFIG_NLS_ISO8859_3 is not set +# CONFIG_NLS_ISO8859_4 is not set +# CONFIG_NLS_ISO8859_5 is not set +# CONFIG_NLS_ISO8859_6 is not set +# CONFIG_NLS_ISO8859_7 is not set +# CONFIG_NLS_ISO8859_9 is not set +# CONFIG_NLS_ISO8859_13 is not set +# CONFIG_NLS_ISO8859_14 is not set +# CONFIG_NLS_ISO8859_15 is not set +# CONFIG_NLS_KOI8_R is not set +# CONFIG_NLS_KOI8_U is not set +# CONFIG_NLS_UTF8 is not set # # Profiling support # -# CONFIG_PROFILING is not set +CONFIG_PROFILING=y +CONFIG_OPROFILE=y # # Kernel hacking # # CONFIG_DEBUG_KERNEL is not set CONFIG_DEBUG_SPINLOCK_SLEEP=y -CONFIG_FRAME_POINTER=y +# CONFIG_FRAME_POINTER is not set CONFIG_X86_FIND_SMP_CONFIG=y CONFIG_X86_MPPARSE=y @@ -1117,8 +1192,9 @@ # # Library routines # -# CONFIG_CRC32 is not set +CONFIG_CRC32=y CONFIG_X86_SMP=y CONFIG_X86_HT=y CONFIG_X86_BIOS_REBOOT=y CONFIG_X86_TRAMPOLINE=y +CONFIG_PC=y diff -Nru a/arch/ppc/boot/simple/embed_config.c b/arch/ppc/boot/simple/embed_config.c --- a/arch/ppc/boot/simple/embed_config.c Mon Feb 2 22:02:18 2004 +++ b/arch/ppc/boot/simple/embed_config.c Mon Feb 2 22:02:18 2004 @@ -50,7 +50,7 @@ { u_char *mp; u_char eebuf[128]; - int i; + int i = 8; bd_t *bd; bd = *bdp; @@ -62,11 +62,21 @@ /* All we are looking for is the Ethernet MAC address. The * first 8 bytes are 'MOTOROLA', so check for part of that. + * Next, the VPD describes a MAC 'packet' as being of type 08 + * and size 06. So we look for that and the MAC must follow. + * If there are more than one, we still only care about the first. * If it's there, assume we have a valid MAC address. If not, * grab our default one. */ - if ((*(uint *)eebuf) == 0x4d4f544f) - mp = &eebuf[0x4c]; + if ((*(uint *)eebuf) == 0x4d4f544f) { + while (i < 127 && !(eebuf[i] == 0x08 && eebuf[i + 1] == 0x06)) + i += eebuf[i + 1] + 2; /* skip this packet */ + + if (i == 127) /* Couldn't find. */ + mp = (u_char *)def_enet_addr; + else + mp = &eebuf[i + 2]; + } else mp = (u_char *)def_enet_addr; diff -Nru a/arch/ppc64/defconfig b/arch/ppc64/defconfig --- a/arch/ppc64/defconfig Mon Feb 2 22:02:19 2004 +++ b/arch/ppc64/defconfig Mon Feb 2 22:02:19 2004 @@ -1,6 +1,7 @@ # # Automatically generated make config: don't edit # +CONFIG_64BIT=y CONFIG_MMU=y CONFIG_RWSEM_XCHGADD_ALGORITHM=y CONFIG_GENERIC_ISA_DMA=y @@ -14,7 +15,8 @@ # Code maturity level options # CONFIG_EXPERIMENTAL=y -# CONFIG_BROKEN is not set +CONFIG_CLEAN_COMPILE=y +CONFIG_STANDALONE=y # # General setup @@ -33,6 +35,7 @@ CONFIG_IOSCHED_NOOP=y CONFIG_IOSCHED_AS=y CONFIG_IOSCHED_DEADLINE=y +# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set # # Loadable module support @@ -51,21 +54,23 @@ CONFIG_PPC_PSERIES=y CONFIG_PPC=y CONFIG_PPC64=y +CONFIG_ALTIVEC=y +# CONFIG_POWER4_ONLY is not set CONFIG_SMP=y CONFIG_IRQ_ALL_CPUS=y CONFIG_NR_CPUS=32 # CONFIG_HMT is not set # CONFIG_DISCONTIGMEM is not set -# CONFIG_RTAS_FLASH is not set -CONFIG_SCANLOG=y CONFIG_PPC_RTAS=y +CONFIG_RTAS_FLASH=m +CONFIG_SCANLOG=m +CONFIG_LPARCFG=y # # General setup # CONFIG_PCI=y CONFIG_PCI_DOMAINS=y -CONFIG_KCORE_ELF=y CONFIG_BINFMT_ELF=y # CONFIG_BINFMT_MISC is not set CONFIG_PCI_LEGACY_PROC=y @@ -75,6 +80,10 @@ # CONFIG_CMDLINE_BOOL is not set # +# Device Drivers +# + +# # Generic Driver Options # @@ -117,6 +126,7 @@ # SCSI device support # CONFIG_SCSI=y +CONFIG_SCSI_PROC_FS=y # # SCSI support type (disk, tape, CD-ROM) @@ -145,9 +155,9 @@ # CONFIG_SCSI_AIC7XXX is not set # CONFIG_SCSI_AIC7XXX_OLD is not set # CONFIG_SCSI_AIC79XX is not set -# CONFIG_SCSI_DPT_I2O is not set # CONFIG_SCSI_ADVANSYS is not set # CONFIG_SCSI_MEGARAID is not set +# CONFIG_SCSI_SATA is not set # CONFIG_SCSI_BUSLOGIC is not set # CONFIG_SCSI_CPQFCTS is not set # CONFIG_SCSI_DMX3191D is not set @@ -155,18 +165,21 @@ # CONFIG_SCSI_EATA_PIO is not set # CONFIG_SCSI_FUTURE_DOMAIN is not set # CONFIG_SCSI_GDTH is not set -# CONFIG_SCSI_INITIO is not set +# CONFIG_SCSI_IPS is not set # CONFIG_SCSI_INIA100 is not set 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_IOMAPPED is not set -# CONFIG_SCSI_PCI2000 is not set -# CONFIG_SCSI_PCI2220I is not set # CONFIG_SCSI_QLOGIC_ISP is not set # CONFIG_SCSI_QLOGIC_FC is not set # CONFIG_SCSI_QLOGIC_1280 is not set +CONFIG_SCSI_QLA2XXX_CONFIG=y +CONFIG_SCSI_QLA2XXX=y +CONFIG_SCSI_QLA21XX=y +CONFIG_SCSI_QLA22XX=y +CONFIG_SCSI_QLA23XX=y # CONFIG_SCSI_DC395x is not set # CONFIG_SCSI_DC390T is not set # CONFIG_SCSI_NSP32 is not set @@ -181,6 +194,7 @@ CONFIG_MD_RAID0=y CONFIG_MD_RAID1=y CONFIG_MD_RAID5=y +# CONFIG_MD_RAID6 is not set # CONFIG_MD_MULTIPATH is not set CONFIG_BLK_DEV_DM=y CONFIG_DM_IOCTL_V4=y @@ -240,7 +254,9 @@ # CONFIG_IP_SCTP is not set # CONFIG_ATM is not set # CONFIG_VLAN_8021Q is not set -# CONFIG_LLC is not set +# CONFIG_LLC2 is not set +# CONFIG_IPX is not set +# CONFIG_ATALK is not set # CONFIG_X25 is not set # CONFIG_LAPB is not set # CONFIG_NET_DIVERT is not set @@ -268,7 +284,6 @@ CONFIG_BONDING=m # CONFIG_EQUALIZER is not set CONFIG_TUN=m -# CONFIG_ETHERTAP is not set # # Ethernet (10 or 100Mbit) @@ -292,6 +307,7 @@ # CONFIG_AMD8111_ETH is not set # CONFIG_ADAPTEC_STARFIRE is not set # CONFIG_B44 is not set +# CONFIG_FORCEDETH is not set # CONFIG_DGRS is not set # CONFIG_EEPRO100 is not set CONFIG_E100=y @@ -303,7 +319,6 @@ # CONFIG_SIS900 is not set # CONFIG_EPIC100 is not set # CONFIG_SUNDANCE is not set -# CONFIG_TLAN is not set # CONFIG_VIA_RHINE is not set # @@ -344,10 +359,10 @@ # CONFIG_NET_RADIO is not set # -# Token Ring devices (depends on LLC=y) +# Token Ring devices # +# CONFIG_TR is not set # CONFIG_NET_FC is not set -# CONFIG_RCPCI is not set # CONFIG_SHAPER is not set # @@ -366,6 +381,11 @@ # CONFIG_IRDA is not set # +# Bluetooth support +# +# CONFIG_BT is not set + +# # ISDN subsystem # # CONFIG_ISDN_BOOL is not set @@ -433,6 +453,7 @@ # CONFIG_SERIAL_8250=y CONFIG_SERIAL_8250_CONSOLE=y +CONFIG_SERIAL_8250_NR_UARTS=4 # CONFIG_SERIAL_8250_EXTENDED is not set # @@ -445,20 +466,6 @@ CONFIG_HVC_CONSOLE=y # -# I2C support -# -# CONFIG_I2C is not set - -# -# I2C Hardware Sensors Mainboard support -# - -# -# I2C Hardware Sensors Chip support -# -# CONFIG_I2C_SENSOR is not set - -# # Mice # # CONFIG_BUSMOUSE is not set @@ -483,11 +490,15 @@ # # Ftape, the floppy tape device driver # -# CONFIG_FTAPE is not set # CONFIG_AGP is not set # CONFIG_DRM is not set CONFIG_RAW_DRIVER=y -# CONFIG_HANGCHECK_TIMER is not set +CONFIG_MAX_RAW_DEVS=256 + +# +# I2C support +# +# CONFIG_I2C is not set # # Multimedia devices @@ -500,6 +511,67 @@ # CONFIG_DVB is not set # +# Graphics support +# +CONFIG_FB=y +# CONFIG_FB_CYBER2000 is not set +CONFIG_FB_OF=y +# CONFIG_FB_CT65550 is not set +# CONFIG_FB_IMSTT is not set +# CONFIG_FB_S3TRIO is not set +# CONFIG_FB_VGA16 is not set +# CONFIG_FB_RIVA is not set +CONFIG_FB_MATROX=y +CONFIG_FB_MATROX_MILLENIUM=y +CONFIG_FB_MATROX_MYSTIQUE=y +CONFIG_FB_MATROX_G450=y +CONFIG_FB_MATROX_G100=y +CONFIG_FB_MATROX_MULTIHEAD=y +# CONFIG_FB_RADEON is not set +# CONFIG_FB_ATY128 is not set +# CONFIG_FB_ATY is not set +# CONFIG_FB_SIS is not set +# CONFIG_FB_NEOMAGIC is not set +# CONFIG_FB_KYRO is not set +# CONFIG_FB_3DFX is not set +# CONFIG_FB_VOODOO1 is not set +# CONFIG_FB_TRIDENT is not set +# CONFIG_FB_VIRTUAL is not set + +# +# Console display driver support +# +# CONFIG_VGA_CONSOLE is not set +# CONFIG_MDA_CONSOLE is not set +CONFIG_DUMMY_CONSOLE=y +CONFIG_FRAMEBUFFER_CONSOLE=y +CONFIG_PCI_CONSOLE=y +# CONFIG_FONTS is not set +CONFIG_FONT_8x8=y +CONFIG_FONT_8x16=y + +# +# Logo configuration +# +CONFIG_LOGO=y +CONFIG_LOGO_LINUX_MONO=y +CONFIG_LOGO_LINUX_VGA16=y +CONFIG_LOGO_LINUX_CLUT224=y + +# +# Sound +# +# CONFIG_SOUND is not set + +# +# USB support +# +# CONFIG_USB is not set +# CONFIG_USB_EMI62 is not set +# CONFIG_USB_EMI26 is not set +# CONFIG_USB_GADGET is not set + +# # File systems # CONFIG_EXT2_FS=y @@ -551,11 +623,14 @@ # Pseudo filesystems # CONFIG_PROC_FS=y +CONFIG_PROC_KCORE=y # CONFIG_DEVFS_FS is not set CONFIG_DEVPTS_FS=y CONFIG_DEVPTS_FS_XATTR=y # CONFIG_DEVPTS_FS_SECURITY is not set CONFIG_TMPFS=y +CONFIG_HUGETLBFS=y +CONFIG_HUGETLB_PAGE=y CONFIG_RAMFS=y # @@ -580,6 +655,7 @@ CONFIG_NFS_FS=y CONFIG_NFS_V3=y CONFIG_NFS_V4=y +# CONFIG_NFS_DIRECTIO is not set CONFIG_NFSD=y CONFIG_NFSD_V3=y CONFIG_NFSD_V4=y @@ -602,11 +678,11 @@ # # CONFIG_PARTITION_ADVANCED is not set CONFIG_MSDOS_PARTITION=y -CONFIG_NLS=y # # Native Language Support # +CONFIG_NLS=y CONFIG_NLS_DEFAULT="iso8859-1" # CONFIG_NLS_CODEPAGE_437 is not set # CONFIG_NLS_CODEPAGE_737 is not set @@ -645,72 +721,6 @@ # CONFIG_NLS_KOI8_R is not set # CONFIG_NLS_KOI8_U is not set # CONFIG_NLS_UTF8 is not set - -# -# Graphics support -# -CONFIG_FB=y -# CONFIG_FB_CIRRUS is not set -# CONFIG_FB_PM2 is not set -# CONFIG_FB_CYBER2000 is not set -CONFIG_FB_OF=y -# CONFIG_FB_CT65550 is not set -# CONFIG_FB_IMSTT is not set -# CONFIG_FB_S3TRIO is not set -# CONFIG_FB_VGA16 is not set -# CONFIG_FB_RIVA is not set -CONFIG_FB_MATROX=y -CONFIG_FB_MATROX_MILLENIUM=y -CONFIG_FB_MATROX_MYSTIQUE=y -CONFIG_FB_MATROX_G450=y -CONFIG_FB_MATROX_G100=y -CONFIG_FB_MATROX_MULTIHEAD=y -# CONFIG_FB_RADEON is not set -# CONFIG_FB_ATY128 is not set -# CONFIG_FB_ATY is not set -# CONFIG_FB_SIS is not set -# CONFIG_FB_NEOMAGIC is not set -# CONFIG_FB_3DFX is not set -# CONFIG_FB_VOODOO1 is not set -# CONFIG_FB_TRIDENT is not set -# CONFIG_FB_PM3 is not set -# CONFIG_FB_VIRTUAL is not set - -# -# Console display driver support -# -# CONFIG_VGA_CONSOLE is not set -# CONFIG_MDA_CONSOLE is not set -CONFIG_DUMMY_CONSOLE=y -CONFIG_FRAMEBUFFER_CONSOLE=y -CONFIG_PCI_CONSOLE=y -# CONFIG_FONTS is not set -CONFIG_FONT_8x8=y -CONFIG_FONT_8x16=y - -# -# Logo configuration -# -CONFIG_LOGO=y -CONFIG_LOGO_LINUX_MONO=y -CONFIG_LOGO_LINUX_VGA16=y -CONFIG_LOGO_LINUX_CLUT224=y - -# -# Sound -# -# CONFIG_SOUND is not set - -# -# USB support -# -# CONFIG_USB is not set -# CONFIG_USB_GADGET is not set - -# -# Bluetooth support -# -# CONFIG_BT is not set # # Profiling support diff -Nru a/arch/ppc64/kernel/asm-offsets.c b/arch/ppc64/kernel/asm-offsets.c --- a/arch/ppc64/kernel/asm-offsets.c Mon Feb 2 22:02:19 2004 +++ b/arch/ppc64/kernel/asm-offsets.c Mon Feb 2 22:02:19 2004 @@ -13,6 +13,7 @@ * 2 of the License, or (at your option) any later version. */ +#include #include #include #include diff -Nru a/arch/ppc64/kernel/head.S b/arch/ppc64/kernel/head.S --- a/arch/ppc64/kernel/head.S Mon Feb 2 22:02:19 2004 +++ b/arch/ppc64/kernel/head.S Mon Feb 2 22:02:19 2004 @@ -646,12 +646,14 @@ */ .globl DataAccess_common DataAccess_common: +BEGIN_FTR_SECTION mfspr r22,DAR srdi r22,r22,60 cmpi 0,r22,0xc /* Segment fault on a bolted segment. Go off and map that segment. */ beq- .do_stab_bolted +END_FTR_SECTION_IFCLR(CPU_FTR_SLB) stab_bolted_user_return: EXCEPTION_PROLOG_COMMON ld r3,_DSISR(r1) @@ -661,10 +663,12 @@ rlwinm r4,r3,32-23,29,29 /* DSISR_STORE -> _PAGE_RW */ ld r3,_DAR(r1) /* into the hash table */ +BEGIN_FTR_SECTION beq+ 2f /* If so handle it */ li r4,0x300 /* Trap number */ bl .do_stab_SI b 1f +END_FTR_SECTION_IFCLR(CPU_FTR_SLB) 2: li r5,0x300 bl .do_hash_page_DSI /* Try to handle as hpte fault */ @@ -690,7 +694,7 @@ EXCEPTION_PROLOG_COMMON ld r3,_DAR(r1) li r4,0x380 /* Exception vector */ - bl .ste_allocate + bl .slb_allocate or. r3,r3,r3 /* Check return code */ beq fast_exception_return /* Return if we succeeded */ addi r3,r1,STACK_FRAME_OVERHEAD @@ -705,12 +709,14 @@ InstructionAccess_common: EXCEPTION_PROLOG_COMMON +BEGIN_FTR_SECTION andis. r0,r23,0x0020 /* no ste found? */ beq+ 2f mr r3,r22 /* SRR0 at interrupt */ li r4,0x400 /* Trap number */ bl .do_stab_SI b 1f +END_FTR_SECTION_IFCLR(CPU_FTR_SLB) 2: mr r3,r22 li r5,0x400 @@ -730,7 +736,7 @@ EXCEPTION_PROLOG_COMMON mr r3,r22 /* SRR0 = NIA */ li r4,0x480 /* Exception vector */ - bl .ste_allocate + bl .slb_allocate or. r3,r3,r3 /* Check return code */ beq+ fast_exception_return /* Return if we succeeded */ @@ -1006,48 +1012,27 @@ * r20 - r23, SRR0 and SRR1 are saved in the exception frame. * We assume we aren't going to take any exceptions during this procedure. */ +/* XXX note fix masking in get_kernel_vsid to match */ _GLOBAL(do_slb_bolted) - stw r23,EX_CCR(r21) /* save CR in exc. frame */ + stw r23,EX_CCR(r21) /* save CR in exc. frame */ - /* (((ea >> 28) & 0x1fff) << 15) | (ea >> 60) */ - mfspr r21,DAR - rldicl r20,r21,36,32 /* Permits a full 32b of ESID */ - rldicr r20,r20,15,48 - rldicl r21,r21,4,60 - or r20,r20,r21 - - li r21,9 /* VSID_RANDOMIZER */ - sldi r21,r21,32 - oris r21,r21,58231 - ori r21,r21,39831 - - mulld r20,r20,r21 - clrldi r20,r20,28 /* r20 = vsid */ - - /* Search the SLB for a free entry */ - li r22,1 -1: - slbmfee r23,r22 - rldicl r23,r23,37,63 - cmpwi r23,0 - beq 4f /* Found an invalid entry */ - - addi r22,r22,1 - cmpldi r22,64 - blt 1b + /* + * We take the next entry, round robin. Previously we tried + * to find a free slot first but that took too long. Unfortunately + * we dont have any LRU information to help us choose a slot. + */ - /* No free entry - just take the next entry, round-robin */ - /* XXX we should get the number of SLB entries from the naca */ + /* r20 = paca */ + /* use a cpu feature mask if we ever change our slb size */ SLB_NUM_ENTRIES = 64 -2: mfspr r21,SPRG3 - ld r22,PACASTABRR(r21) - addi r23,r22,1 - cmpdi r23,SLB_NUM_ENTRIES - blt 3f - li r23,1 -3: std r23,PACASTABRR(r21) +1: ld r22,PACASTABRR(r20) + addi r21,r22,1 + cmpdi r21,SLB_NUM_ENTRIES + blt+ 2f + li r21,1 /* dont touch bolted slot 0 */ +2: std r21,PACASTABRR(r20) - /* r20 = vsid, r22 = entry */ + /* r20 = paca, r22 = entry */ /* * Never cast out the segment for our kernel stack. Since we @@ -1056,48 +1041,86 @@ * which gets invalidated due to a tlbie from another cpu at a * non recoverable point (after setting srr0/1) - Anton */ - slbmfee r23,r22 - srdi r23,r23,28 + slbmfee r21,r22 + srdi r21,r21,27 /* * This is incorrect (r1 is not the kernel stack) if we entered * from userspace but there is no critical window from userspace * so this should be OK. Also if we cast out the userspace stack * segment while in userspace we will fault it straight back in. */ - srdi r21,r1,28 - cmpd r21,r23 - beq- 2b - - /* Put together the vsid portion of the entry. */ -4: li r21,0 - rldimi r21,r20,12,0 - ori r20,r21,1024 - ori r20,r20,128 /* set class bit for kernel region */ -#ifndef CONFIG_PPC_ISERIES - ori r20,r20,256 /* map kernel region with large ptes */ -#endif + srdi r23,r1,27 + ori r23,r23,1 + cmpd r23,r21 + beq- 1b + + /* r20 = paca, r22 = entry */ + + /* (((ea >> 28) & 0x1fff) << 15) | (ea >> 60) */ + mfspr r21,DAR + rldicl r23,r21,36,51 + sldi r23,r23,15 + srdi r21,r21,60 + or r23,r23,r21 + + /* VSID_RANDOMIZER */ + li r21,9 + sldi r21,r21,32 + oris r21,r21,58231 + ori r21,r21,39831 + + /* vsid = (ordinal * VSID_RANDOMIZER) & VSID_MASK */ + mulld r23,r23,r21 + clrldi r23,r23,28 + + /* r20 = paca, r22 = entry, r23 = vsid */ + + /* Put together slb word1 */ + sldi r23,r23,12 + +BEGIN_FTR_SECTION + /* set kp and c bits */ + ori r23,r23,0x480 +END_FTR_SECTION_IFCLR(CPU_FTR_16M_PAGE) +BEGIN_FTR_SECTION + /* set kp, l and c bits */ + ori r23,r23,0x580 +END_FTR_SECTION_IFSET(CPU_FTR_16M_PAGE) - /* Put together the esid portion of the entry. */ - mfspr r21,DAR /* Get the new esid */ - rldicl r21,r21,36,28 /* Permits a full 36b of ESID */ - li r23,0 - rldimi r23,r21,28,0 /* Insert esid */ - oris r21,r23,2048 /* valid bit */ - rldimi r21,r22,0,52 /* Insert entry */ + /* r20 = paca, r22 = entry, r23 = slb word1 */ + + /* Put together slb word0 */ + mfspr r21,DAR + rldicr r21,r21,0,35 /* get the new esid */ + oris r21,r21,2048 /* set valid bit */ + rldimi r21,r22,0,52 /* insert entry */ + + /* r20 = paca, r21 = slb word0, r23 = slb word1 */ /* * No need for an isync before or after this slbmte. The exception * we enter with and the rfid we exit with are context synchronizing . */ - slbmte r20,r21 + slbmte r23,r21 /* All done -- return from exception. */ - mfsprg r20,3 /* Load the PACA pointer */ - ld r21,PACAEXCSP(r20) /* Get the exception frame pointer */ - addi r21,r21,EXC_FRAME_SIZE + ld r21,PACAEXCSP(r20) /* Get the exception frame pointer */ + addi r21,r21,EXC_FRAME_SIZE lwz r23,EX_CCR(r21) /* get saved CR */ /* note that this is almost identical to maskable_exception_exit */ - mtcr r23 /* restore CR */ + + /* + * Until everyone updates binutils hardwire the POWER4 optimised + * single field mtcrf + */ +#if 0 + .machine push + .machine "power4" + mtcrf 0x80,r23 + .machine pop +#else + .long 0x7ef80120 +#endif mfmsr r22 li r23, MSR_RI @@ -1107,10 +1130,10 @@ ld r22,EX_SRR0(r21) /* Get SRR0 from exc. frame */ ld r23,EX_SRR1(r21) /* Get SRR1 from exc. frame */ mtspr SRR0,r22 - mtspr SRR1,r23 + mtspr SRR1,r23 ld r22,EX_R22(r21) /* restore r22 and r23 */ ld r23,EX_R23(r21) - mfspr r20,SPRG2 + ld r20,EX_R20(r21) mfspr r21,SPRG1 rfid diff -Nru a/arch/ppc64/kernel/iSeries_VpdInfo.c b/arch/ppc64/kernel/iSeries_VpdInfo.c --- a/arch/ppc64/kernel/iSeries_VpdInfo.c Mon Feb 2 22:02:18 2004 +++ b/arch/ppc64/kernel/iSeries_VpdInfo.c Mon Feb 2 22:02:18 2004 @@ -25,6 +25,7 @@ /* Ported to ppc64, August 20, 2001 */ /* End Change Activity */ /************************************************************************/ +#include #include #include #include diff -Nru a/arch/ppc64/kernel/lparcfg.c b/arch/ppc64/kernel/lparcfg.c --- a/arch/ppc64/kernel/lparcfg.c Mon Feb 2 22:02:19 2004 +++ b/arch/ppc64/kernel/lparcfg.c Mon Feb 2 22:02:19 2004 @@ -5,6 +5,8 @@ * Copyright (c) 2003 Dave Engebretsen * Will Schmidt willschm@us.ibm.com * SPLPAR updates, Copyright (c) 2003 Will Schmidt IBM Corporation. + * Nathan Lynch nathanl@austin.ibm.com + * Added lparcfg_write, Copyright (C) 2004 Nathan Lynch IBM Corporation. * * This program is free software; you can redistribute it and/or * modify it under the terms of the GNU General Public License @@ -15,6 +17,7 @@ * keyword - value pairs that specify the configuration of the partition. */ +#include #include #include #include @@ -33,6 +36,9 @@ #define LPARCFG_BUFF_SIZE 4096 #ifdef CONFIG_PPC_ISERIES + +#define lparcfg_write NULL + static unsigned char e2a(unsigned char x) { switch (x) { @@ -326,7 +332,7 @@ system_potential_processors = get_splpar_potential_characteristics(); n += snprintf(buf+n, LPARCFG_BUFF_SIZE - n, "system_active_processors=%d\n", - (h_resource >> 2*8) && 0xffff); + (h_resource >> 2*8) & 0xffff); n += snprintf(buf+n, LPARCFG_BUFF_SIZE - n, "system_potential_processors=%d\n", system_potential_processors); @@ -367,22 +373,115 @@ if (cur_cpu_spec->firmware_features & FW_FEATURE_SPLPAR) { n += snprintf(buf+n, LPARCFG_BUFF_SIZE - n, - "pool=%d\n", (h_aggregation >> 0*8)&&0xffff); + "pool=%d\n", (h_aggregation >> 0*8)&0xffff); n += snprintf(buf+n, LPARCFG_BUFF_SIZE - n, - "pool_capacity=%d\n", (h_resource >> 3*8) &&0xffff); + "pool_capacity=%d\n", (h_resource >> 3*8) &0xffff); n += snprintf(buf+n, LPARCFG_BUFF_SIZE - n, - "group=%d\n", (h_aggregation >> 2*8)&&0xffff); + "group=%d\n", (h_aggregation >> 2*8)&0xffff); n += snprintf(buf+n, LPARCFG_BUFF_SIZE - n, - "capped=%d\n", (h_resource >> 6*8)&&0x40); + "capped=%d\n", (h_resource >> 6*8)&0x40); n += snprintf(buf+n, LPARCFG_BUFF_SIZE - n, "capacity_weight=%d\n", (int)(h_resource>>5*8)&0xFF); } return 0; } + +/* + * Interface for changing system parameters (variable capacity weight + * and entitled capacity). Format of input is "param_name=value"; + * anything after value is ignored. Valid parameters at this time are + * "partition_entitled_capacity" and "capacity_weight". We use + * H_SET_PPP to alter parameters. + * + * This function should be invoked only on systems with + * FW_FEATURE_SPLPAR. + */ +static ssize_t lparcfg_write(struct file *file, const char __user *buf, size_t count, loff_t *off) +{ + char *kbuf; + char *tmp; + u64 new_entitled, *new_entitled_ptr = &new_entitled; + u8 new_weight, *new_weight_ptr = &new_weight; + + unsigned long current_entitled; /* parameters for h_get_ppp */ + unsigned long dummy; + unsigned long resource; + u8 current_weight; + + ssize_t retval = -ENOMEM; + + kbuf = kmalloc(count, GFP_KERNEL); + if (!kbuf) + goto out; + + retval = -EFAULT; + if (copy_from_user(kbuf, buf, count)) + goto out; + + retval = -EINVAL; + kbuf[count - 1] = '\0'; + tmp = strchr(kbuf, '='); + if (!tmp) + goto out; + + *tmp++ = '\0'; + + if (!strcmp(kbuf, "partition_entitled_capacity")) { + char *endp; + *new_entitled_ptr = (u64)simple_strtoul(tmp, &endp, 10); + if (endp == tmp) + goto out; + new_weight_ptr = ¤t_weight; + } else if (!strcmp(kbuf, "capacity_weight")) { + char *endp; + *new_weight_ptr = (u8)simple_strtoul(tmp, &endp, 10); + if (endp == tmp) + goto out; + new_entitled_ptr = ¤t_entitled; + } else + goto out; + + /* Get our current parameters */ + retval = h_get_ppp(¤t_entitled, &dummy, &dummy, &resource); + if (retval) { + retval = -EIO; + goto out; + } + + current_weight = (resource>>5*8)&0xFF; + + pr_debug("%s: current_entitled = %lu, current_weight = %lu\n", + __FUNCTION__, current_entitled, current_weight); + + pr_debug("%s: new_entitled = %lu, new_weight = %lu\n", + __FUNCTION__, *new_entitled_ptr, *new_weight_ptr); + + retval = plpar_hcall_norets(H_SET_PPP, *new_entitled_ptr, + *new_weight_ptr); + + if (retval == H_Success || retval == H_Constrained) { + retval = count; + } else if (retval == H_Busy) { + retval = -EBUSY; + } else if (retval == H_Hardware) { + retval = -EIO; + } else if (retval == H_Parameter) { + retval = -EINVAL; + } else { + printk(KERN_WARNING "%s: received unknown hv return code %ld", + __FUNCTION__, retval); + retval = -EIO; + } + +out: + kfree(kbuf); + return retval; +} + #endif /* CONFIG_PPC_PSERIES */ @@ -442,8 +541,15 @@ int __init lparcfg_init(void) { struct proc_dir_entry *ent; + mode_t mode = S_IRUSR; + + /* Allow writing if we have FW_FEATURE_SPLPAR */ + if (cur_cpu_spec->firmware_features & FW_FEATURE_SPLPAR) { + lparcfg_fops.write = lparcfg_write; + mode |= S_IWUSR; + } - ent = create_proc_entry("ppc64/lparcfg", S_IRUSR, NULL); + ent = create_proc_entry("ppc64/lparcfg", mode, NULL); if (ent) { ent->proc_fops = &lparcfg_fops; ent->data = kmalloc(LPARCFG_BUFF_SIZE, GFP_KERNEL); diff -Nru a/arch/ppc64/kernel/pacaData.c b/arch/ppc64/kernel/pacaData.c --- a/arch/ppc64/kernel/pacaData.c Mon Feb 2 22:02:19 2004 +++ b/arch/ppc64/kernel/pacaData.c Mon Feb 2 22:02:19 2004 @@ -41,7 +41,6 @@ .xStab_data = { \ .real = (asrr), /* Real pointer to segment table */ \ .virt = (asrv), /* Virt pointer to segment table */ \ - .next_round_robin = 1 /* Round robin index */ \ }, \ .lpQueuePtr = (lpq), /* &xItLpQueue, */ \ /* .xRtas = { \ diff -Nru a/arch/ppc64/kernel/ppc_ksyms.c b/arch/ppc64/kernel/ppc_ksyms.c --- a/arch/ppc64/kernel/ppc_ksyms.c Mon Feb 2 22:02:19 2004 +++ b/arch/ppc64/kernel/ppc_ksyms.c Mon Feb 2 22:02:19 2004 @@ -83,7 +83,7 @@ EXPORT_SYMBOL(naca); EXPORT_SYMBOL(__down); -/* EXPORT_SYMBOL(csum_partial); already in net/netsyms.c */ +EXPORT_SYMBOL(csum_partial); EXPORT_SYMBOL(csum_partial_copy_generic); EXPORT_SYMBOL(ip_fast_csum); EXPORT_SYMBOL(csum_tcpudp_magic); @@ -191,12 +191,12 @@ EXPORT_SYMBOL(get_property); #endif - EXPORT_SYMBOL_NOVERS(memcpy); EXPORT_SYMBOL_NOVERS(memset); EXPORT_SYMBOL_NOVERS(memmove); EXPORT_SYMBOL_NOVERS(memscan); EXPORT_SYMBOL_NOVERS(memcmp); +EXPORT_SYMBOL_NOVERS(memchr); EXPORT_SYMBOL(abs); diff -Nru a/arch/ppc64/kernel/proc_ppc64.c b/arch/ppc64/kernel/proc_ppc64.c --- a/arch/ppc64/kernel/proc_ppc64.c Mon Feb 2 22:02:19 2004 +++ b/arch/ppc64/kernel/proc_ppc64.c Mon Feb 2 22:02:19 2004 @@ -27,6 +27,7 @@ * End Change Activity */ +#include #include #include #include diff -Nru a/arch/ppc64/kernel/process.c b/arch/ppc64/kernel/process.c --- a/arch/ppc64/kernel/process.c Mon Feb 2 22:02:19 2004 +++ b/arch/ppc64/kernel/process.c Mon Feb 2 22:02:19 2004 @@ -151,7 +151,31 @@ local_irq_save(flags); last = _switch(old_thread, new_thread); + + /* + * force our kernel stack out of the ERAT and SLB, this is to + * avoid the race where we it hangs around in the ERAT but not the + * SLB and the ERAT gets invalidated at just the wrong moment by + * another CPU doing a tlbie. + * + * We definitely dont want to flush our bolted segment, so check + * for that first. + */ + if ((cur_cpu_spec->cpu_features & CPU_FTR_SLB) && + GET_ESID((unsigned long)_get_SP()) != GET_ESID(PAGE_OFFSET)) { + union { + unsigned long word0; + slb_dword0 data; + } esid_data; + + esid_data.word0 = 0; + /* class bit is in valid field for slbie instruction */ + esid_data.data.v = 1; + esid_data.data.esid = GET_ESID((unsigned long)_get_SP()); + asm volatile("isync; slbie %0; isync" : : "r" (esid_data)); + } local_irq_restore(flags); + return last; } diff -Nru a/arch/ppc64/kernel/prom.c b/arch/ppc64/kernel/prom.c --- a/arch/ppc64/kernel/prom.c Mon Feb 2 22:02:19 2004 +++ b/arch/ppc64/kernel/prom.c Mon Feb 2 22:02:19 2004 @@ -2560,6 +2560,7 @@ return 0; } +#ifdef CONFIG_PROC_DEVICETREE /* * Add a node to /proc/device-tree. */ @@ -2592,6 +2593,17 @@ if (np->pde) remove_proc_entry(np->pde->name, parent->pde); } +#else /* !CONFIG_PROC_DEVICETREE */ +static void add_node_proc_entries(struct device_node *np) +{ + return; +} + +static void remove_node_proc_entries(struct device_node *np) +{ + return; +} +#endif /* CONFIG_PROC_DEVICETREE */ /* * Fix up the uninitialized fields in a new device node: diff -Nru a/arch/ppc64/kernel/rtas_flash.c b/arch/ppc64/kernel/rtas_flash.c --- a/arch/ppc64/kernel/rtas_flash.c Mon Feb 2 22:02:19 2004 +++ b/arch/ppc64/kernel/rtas_flash.c Mon Feb 2 22:02:19 2004 @@ -14,8 +14,6 @@ */ #include - -#include #include #include #include diff -Nru a/arch/ppc64/kernel/setup.c b/arch/ppc64/kernel/setup.c --- a/arch/ppc64/kernel/setup.c Mon Feb 2 22:02:19 2004 +++ b/arch/ppc64/kernel/setup.c Mon Feb 2 22:02:19 2004 @@ -38,6 +38,7 @@ #include #include #include +#include #include extern unsigned long klimit; @@ -430,8 +431,58 @@ } } - #ifdef CONFIG_PPC_PSERIES +static int __init set_preferred_console(void) +{ + struct device_node *prom_stdout; + char *name; + + /* The user has requested a console so this is already set up. */ + if (strstr(cmd_line, "console=")) + return -EBUSY; + + prom_stdout = find_path_device(of_stdout_device); + if (!prom_stdout) + return -ENODEV; + + name = (char *)get_property(prom_stdout, "name", NULL); + if (!name) + return -ENODEV; + + if (strcmp(name, "serial") == 0) { + int i; + u32 *reg = (u32 *)get_property(prom_stdout, "reg", &i); + if (i > 8) { + int offset; + switch (reg[1]) { + case 0x3f8: + offset = 0; + break; + case 0x2f8: + offset = 1; + break; + case 0x898: + offset = 2; + break; + case 0x890: + offset = 3; + break; + default: + /* We dont recognise the serial port */ + return -ENODEV; + } + + return add_preferred_console("ttyS", offset, NULL); + } + } else if (strcmp(name, "vty") == 0) { + /* pSeries LPAR virtual console */ + return add_preferred_console("hvc", 0, NULL); + } + + return -ENODEV; +} +console_initcall(set_preferred_console); + int parse_bootinfo(void) { struct bi_record *rec; diff -Nru a/arch/ppc64/kernel/signal.c b/arch/ppc64/kernel/signal.c --- a/arch/ppc64/kernel/signal.c Mon Feb 2 22:02:18 2004 +++ b/arch/ppc64/kernel/signal.c Mon Feb 2 22:02:18 2004 @@ -14,6 +14,7 @@ * 2 of the License, or (at your option) any later version. */ +#include #include #include #include diff -Nru a/arch/ppc64/kernel/signal32.c b/arch/ppc64/kernel/signal32.c --- a/arch/ppc64/kernel/signal32.c Mon Feb 2 22:02:19 2004 +++ b/arch/ppc64/kernel/signal32.c Mon Feb 2 22:02:19 2004 @@ -14,6 +14,7 @@ * 2 of the License, or (at your option) any later version. */ +#include #include #include #include diff -Nru a/arch/ppc64/kernel/stab.c b/arch/ppc64/kernel/stab.c --- a/arch/ppc64/kernel/stab.c Mon Feb 2 22:02:19 2004 +++ b/arch/ppc64/kernel/stab.c Mon Feb 2 22:02:19 2004 @@ -12,8 +12,6 @@ * 2 of the License, or (at your option) any later version. */ -/* XXX Note: Changes for bolted region have not been merged - Anton */ - #include #include #include @@ -59,6 +57,15 @@ } } +/* Both the segment table and SLB code uses the following cache */ +#define NR_STAB_CACHE_ENTRIES 8 +DEFINE_PER_CPU(long, stab_cache_ptr); +DEFINE_PER_CPU(long, stab_cache[NR_STAB_CACHE_ENTRIES]); + +/* + * Segment table stuff + */ + /* * Create a segment table entry for the given esid/vsid pair. */ @@ -91,14 +98,8 @@ /* * Could not find empty entry, pick one with a round robin selection. - * Search all entries in the two groups. Note that the first time - * we get here, we start with entry 1 so the initializer - * can be common with the SLB castout code. + * Search all entries in the two groups. */ - - /* This assumes we never castout when initializing the stab. */ - PMC_SW_PROCESSOR(stab_capacity_castouts); - castout_entry = get_paca()->xStab_data.next_round_robin; for (i = 0; i < 16; i++) { if (castout_entry < 8) { @@ -123,23 +124,169 @@ /* Modify the old entry to the new value. */ /* Force previous translations to complete. DRENG */ - asm volatile("isync" : : : "memory" ); + asm volatile("isync" : : : "memory"); castout_ste->dw0.dw0.v = 0; - asm volatile("sync" : : : "memory" ); /* Order update */ + asm volatile("sync" : : : "memory"); /* Order update */ castout_ste->dw1.dw1.vsid = vsid; old_esid = castout_ste->dw0.dw0.esid; castout_ste->dw0.dw0.esid = esid; castout_ste->dw0.dw0.kp = 1; - asm volatile("eieio" : : : "memory" ); /* Order update */ + asm volatile("eieio" : : : "memory"); /* Order update */ castout_ste->dw0.dw0.v = 1; asm volatile("slbie %0" : : "r" (old_esid << SID_SHIFT)); /* Ensure completion of slbie */ - asm volatile("sync" : : : "memory" ); + asm volatile("sync" : : : "memory"); return (global_entry | (castout_entry & 0x7)); } +static inline void __ste_allocate(unsigned long esid, unsigned long vsid, + mm_context_t context) +{ + unsigned char stab_entry; + unsigned long *offset; + int region_id = REGION_ID(esid << SID_SHIFT); + + stab_entry = make_ste(get_paca()->xStab_data.virt, esid, vsid); + + if (region_id != USER_REGION_ID) + return; + + offset = &__get_cpu_var(stab_cache_ptr); + if (*offset < NR_STAB_CACHE_ENTRIES) { + __get_cpu_var(stab_cache[*offset]) = stab_entry; + } + (*offset)++; +} + +/* + * Allocate a segment table entry for the given ea. + */ +int ste_allocate(unsigned long ea) +{ + unsigned long vsid, esid; + mm_context_t context; + + /* Check for invalid effective addresses. */ + if (!IS_VALID_EA(ea)) + return 1; + + /* Kernel or user address? */ + if (REGION_ID(ea) >= KERNEL_REGION_ID) { + vsid = get_kernel_vsid(ea); + context = REGION_ID(ea); + } else { + if (!current->mm) + return 1; + + context = current->mm->context; + vsid = get_vsid(context, ea); + } + + esid = GET_ESID(ea); + __ste_allocate(esid, vsid, context); + /* Order update */ + asm volatile("sync":::"memory"); + + return 0; +} + +/* + * preload some userspace segments into the segment table. + */ +static void preload_stab(struct task_struct *tsk, struct mm_struct *mm) +{ + unsigned long pc = KSTK_EIP(tsk); + unsigned long stack = KSTK_ESP(tsk); + unsigned long unmapped_base; + unsigned long pc_esid = GET_ESID(pc); + unsigned long stack_esid = GET_ESID(stack); + unsigned long unmapped_base_esid; + unsigned long vsid; + + if (test_tsk_thread_flag(tsk, TIF_32BIT)) + unmapped_base = TASK_UNMAPPED_BASE_USER32; + else + unmapped_base = TASK_UNMAPPED_BASE_USER64; + + unmapped_base_esid = GET_ESID(unmapped_base); + + if (!IS_VALID_EA(pc) || (REGION_ID(pc) >= KERNEL_REGION_ID)) + return; + vsid = get_vsid(mm->context, pc); + __ste_allocate(pc_esid, vsid, mm->context); + + if (pc_esid == stack_esid) + return; + + if (!IS_VALID_EA(stack) || (REGION_ID(stack) >= KERNEL_REGION_ID)) + return; + vsid = get_vsid(mm->context, stack); + __ste_allocate(stack_esid, vsid, mm->context); + + if (pc_esid == unmapped_base_esid || stack_esid == unmapped_base_esid) + return; + + if (!IS_VALID_EA(unmapped_base) || + (REGION_ID(unmapped_base) >= KERNEL_REGION_ID)) + return; + vsid = get_vsid(mm->context, unmapped_base); + __ste_allocate(unmapped_base_esid, vsid, mm->context); + + /* Order update */ + asm volatile("sync" : : : "memory"); +} + +/* Flush all user entries from the segment table of the current processor. */ +void flush_stab(struct task_struct *tsk, struct mm_struct *mm) +{ + STE *stab = (STE *) get_paca()->xStab_data.virt; + STE *ste; + unsigned long *offset = &__get_cpu_var(stab_cache_ptr); + + /* Force previous translations to complete. DRENG */ + asm volatile("isync" : : : "memory"); + + if (*offset <= NR_STAB_CACHE_ENTRIES) { + int i; + + for (i = 0; i < *offset; i++) { + ste = stab + __get_cpu_var(stab_cache[i]); + ste->dw0.dw0.v = 0; + } + + asm volatile("sync; slbia; sync":::"memory"); + } else { + unsigned long entry; + + /* Invalidate all entries. */ + ste = stab; + + /* Never flush the first entry. */ + ste += 1; + for (entry = 1; + entry < (PAGE_SIZE / sizeof(STE)); + entry++, ste++) { + unsigned long ea; + ea = ste->dw0.dw0.esid << SID_SHIFT; + if (ea < KERNELBASE) { + ste->dw0.dw0.v = 0; + } + } + + asm volatile("sync; slbia; sync":::"memory"); + } + + *offset = 0; + + preload_stab(tsk, mm); +} + +/* + * SLB stuff + */ + /* * Create a segment buffer entry for the given esid/vsid pair. * @@ -160,22 +307,11 @@ } vsid_data; /* - * Find an empty entry, if one exists. Must start at 0 because - * we use this code to load SLB entry 0 at boot. - */ - for (entry = 0; entry < naca->slb_size; entry++) { - asm volatile("slbmfee %0,%1" - : "=r" (esid_data) : "r" (entry)); - if (!esid_data.data.v) - goto write_entry; - } - - /* - * Could not find empty entry, pick one with a round robin selection. + * We take the next entry, round robin. Previously we tried + * to find a free slot first but that took too long. Unfortunately + * we dont have any LRU information to help us choose a slot. */ - PMC_SW_PROCESSOR(stab_capacity_castouts); - /* * Never cast out the segment for our kernel stack. Since we * dont invalidate the ERAT we could have a valid translation @@ -190,13 +326,13 @@ if (castout_entry >= naca->slb_size) castout_entry = 1; asm volatile("slbmfee %0,%1" : "=r" (esid_data) : "r" (entry)); - } while (esid_data.data.esid == GET_ESID((unsigned long)_get_SP())); + } while (esid_data.data.v && + esid_data.data.esid == GET_ESID((unsigned long)_get_SP())); get_paca()->xStab_data.next_round_robin = castout_entry; /* slbie not needed as the previous mapping is still valid. */ -write_entry: /* * Write the new SLB entry. */ @@ -220,211 +356,129 @@ asm volatile("slbmte %0,%1" : : "r" (vsid_data), "r" (esid_data)); } -static inline void __ste_allocate(unsigned long esid, unsigned long vsid, - int kernel_segment, mm_context_t context) +static inline void __slb_allocate(unsigned long esid, unsigned long vsid, + mm_context_t context) { - if (cur_cpu_spec->cpu_features & CPU_FTR_SLB) { - int large = 0; + int large = 0; + int region_id = REGION_ID(esid << SID_SHIFT); + unsigned long *offset; -#ifndef CONFIG_PPC_ISERIES - if (REGION_ID(esid << SID_SHIFT) == KERNEL_REGION_ID) + if (cur_cpu_spec->cpu_features & CPU_FTR_16M_PAGE) { + if (region_id == KERNEL_REGION_ID) large = 1; - else if (REGION_ID(esid << SID_SHIFT) == USER_REGION_ID) + else if (region_id == USER_REGION_ID) large = in_hugepage_area(context, esid << SID_SHIFT); -#endif - make_slbe(esid, vsid, large, kernel_segment); - } else { - unsigned char top_entry, stab_entry, *segments; + } - stab_entry = make_ste(get_paca()->xStab_data.virt, esid, vsid); - PMC_SW_PROCESSOR_A(stab_entry_use, stab_entry & 0xf); + make_slbe(esid, vsid, large, region_id != USER_REGION_ID); - segments = get_paca()->xSegments; - top_entry = get_paca()->stab_cache_pointer; - if (!kernel_segment && top_entry < STAB_CACHE_SIZE) { - segments[top_entry] = stab_entry; - if (top_entry == STAB_CACHE_SIZE) - top_entry = 0xff; - top_entry++; - get_paca()->stab_cache_pointer = top_entry; - } + if (region_id != USER_REGION_ID) + return; + + offset = &__get_cpu_var(stab_cache_ptr); + if (*offset < NR_STAB_CACHE_ENTRIES) { + __get_cpu_var(stab_cache[*offset]) = esid; } + (*offset)++; } /* * Allocate a segment table entry for the given ea. */ -int ste_allocate(unsigned long ea) +int slb_allocate(unsigned long ea) { unsigned long vsid, esid; - int kernel_segment = 0; mm_context_t context; - PMC_SW_PROCESSOR(stab_faults); - /* Check for invalid effective addresses. */ - if (!IS_VALID_EA(ea)) + if (unlikely(!IS_VALID_EA(ea))) return 1; /* Kernel or user address? */ if (REGION_ID(ea) >= KERNEL_REGION_ID) { - kernel_segment = 1; - vsid = get_kernel_vsid(ea); context = REGION_ID(ea); + vsid = get_kernel_vsid(ea); } else { - if (! current->mm) + if (unlikely(!current->mm)) return 1; context = current->mm->context; - vsid = get_vsid(context, ea); } esid = GET_ESID(ea); - __ste_allocate(esid, vsid, kernel_segment, context); - if (!(cur_cpu_spec->cpu_features & CPU_FTR_SLB)) { - /* Order update */ - asm volatile("sync":::"memory"); - } + __slb_allocate(esid, vsid, context); return 0; } -unsigned long ppc64_preload_all_segments; -unsigned long ppc64_stab_preload = 1; -#define STAB_PRESSURE 0 -#define USE_SLBIE_ON_STAB 0 - /* - * preload all 16 segments for a 32 bit process and the PC and SP segments - * for a 64 bit process. + * preload some userspace segments into the SLB. */ -static void preload_stab(struct task_struct *tsk, struct mm_struct *mm) +static void preload_slb(struct task_struct *tsk, struct mm_struct *mm) { - if (ppc64_preload_all_segments && - test_tsk_thread_flag(tsk, TIF_32BIT)) { - unsigned long esid, vsid; - - for (esid = 0; esid < 16; esid++) { - unsigned long ea = esid << SID_SHIFT; - vsid = get_vsid(mm->context, ea); - __ste_allocate(esid, vsid, 0, mm->context); - } - } else { - unsigned long pc = KSTK_EIP(tsk); - unsigned long stack = KSTK_ESP(tsk); - unsigned long pc_segment = pc & ~SID_MASK; - unsigned long stack_segment = stack & ~SID_MASK; - unsigned long vsid; - - if (pc) { - if (!IS_VALID_EA(pc) || - (REGION_ID(pc) >= KERNEL_REGION_ID)) - return; - vsid = get_vsid(mm->context, pc); - __ste_allocate(GET_ESID(pc), vsid, 0, mm->context); - } - - if (stack && (pc_segment != stack_segment)) { - if (!IS_VALID_EA(stack) || - (REGION_ID(stack) >= KERNEL_REGION_ID)) - return; - vsid = get_vsid(mm->context, stack); - __ste_allocate(GET_ESID(stack), vsid, 0, mm->context); - } - } - - if (!(cur_cpu_spec->cpu_features & CPU_FTR_SLB)) { - /* Order update */ - asm volatile("sync" : : : "memory"); - } + unsigned long pc = KSTK_EIP(tsk); + unsigned long stack = KSTK_ESP(tsk); + unsigned long unmapped_base; + unsigned long pc_esid = GET_ESID(pc); + unsigned long stack_esid = GET_ESID(stack); + unsigned long unmapped_base_esid; + unsigned long vsid; + + if (test_tsk_thread_flag(tsk, TIF_32BIT)) + unmapped_base = TASK_UNMAPPED_BASE_USER32; + else + unmapped_base = TASK_UNMAPPED_BASE_USER64; + + unmapped_base_esid = GET_ESID(unmapped_base); + + if (!IS_VALID_EA(pc) || (REGION_ID(pc) >= KERNEL_REGION_ID)) + return; + vsid = get_vsid(mm->context, pc); + __slb_allocate(pc_esid, vsid, mm->context); + + if (pc_esid == stack_esid) + return; + + if (!IS_VALID_EA(stack) || (REGION_ID(stack) >= KERNEL_REGION_ID)) + return; + vsid = get_vsid(mm->context, stack); + __slb_allocate(stack_esid, vsid, mm->context); + + if (pc_esid == unmapped_base_esid || stack_esid == unmapped_base_esid) + return; + + if (!IS_VALID_EA(unmapped_base) || + (REGION_ID(unmapped_base) >= KERNEL_REGION_ID)) + return; + vsid = get_vsid(mm->context, unmapped_base); + __slb_allocate(unmapped_base_esid, vsid, mm->context); } /* Flush all user entries from the segment table of the current processor. */ -void flush_stab(struct task_struct *tsk, struct mm_struct *mm) +void flush_slb(struct task_struct *tsk, struct mm_struct *mm) { - if (cur_cpu_spec->cpu_features & CPU_FTR_SLB) { - /* - * XXX disable 32bit slb invalidate optimisation until we fix - * the issue where a 32bit app execed out of a 64bit app can - * cause segments above 4GB not to be flushed - Anton - */ - if (0 && !STAB_PRESSURE && test_thread_flag(TIF_32BIT)) { - union { - unsigned long word0; - slb_dword0 data; - } esid_data; - unsigned long esid; - - asm volatile("isync" : : : "memory"); - for (esid = 0; esid < 16; esid++) { - esid_data.word0 = 0; - esid_data.data.esid = esid; - asm volatile("slbie %0" : : "r" (esid_data)); - } - asm volatile("isync" : : : "memory"); - } else { - asm volatile("isync; slbia; isync":::"memory"); - } + unsigned long *offset = &__get_cpu_var(stab_cache_ptr); - PMC_SW_PROCESSOR(stab_invalidations); - } else { - STE *stab = (STE *) get_paca()->xStab_data.virt; - STE *ste; - unsigned long flags; + if (*offset <= NR_STAB_CACHE_ENTRIES) { + int i; + union { + unsigned long word0; + slb_dword0 data; + } esid_data; - /* Force previous translations to complete. DRENG */ asm volatile("isync" : : : "memory"); - - local_irq_save(flags); - if (get_paca()->stab_cache_pointer != 0xff && !STAB_PRESSURE) { - int i; - unsigned char *segments = get_paca()->xSegments; - - for (i = 0; i < get_paca()->stab_cache_pointer; i++) { - ste = stab + segments[i]; - ste->dw0.dw0.v = 0; - PMC_SW_PROCESSOR(stab_invalidations); - } - -#if USE_SLBIE_ON_STAB - asm volatile("sync":::"memory"); - for (i = 0; i < get_paca()->stab_cache_pointer; i++) { - ste = stab + segments[i]; - asm volatile("slbie %0" : : - "r" (ste->dw0.dw0.esid << SID_SHIFT)); - } - asm volatile("sync":::"memory"); -#else - asm volatile("sync; slbia; sync":::"memory"); -#endif - - } else { - unsigned long entry; - - /* Invalidate all entries. */ - ste = stab; - - /* Never flush the first entry. */ - ste += 1; - for (entry = 1; - entry < (PAGE_SIZE / sizeof(STE)); - entry++, ste++) { - unsigned long ea; - ea = ste->dw0.dw0.esid << SID_SHIFT; - if (STAB_PRESSURE || ea < KERNELBASE) { - ste->dw0.dw0.v = 0; - PMC_SW_PROCESSOR(stab_invalidations); - } - } - - asm volatile("sync; slbia; sync":::"memory"); + for (i = 0; i < *offset; i++) { + esid_data.word0 = 0; + esid_data.data.esid = __get_cpu_var(stab_cache[i]); + asm volatile("slbie %0" : : "r" (esid_data)); } - - get_paca()->stab_cache_pointer = 0; - local_irq_restore(flags); + asm volatile("isync" : : : "memory"); + } else { + asm volatile("isync; slbia; isync" : : : "memory"); } - if (ppc64_stab_preload) - preload_stab(tsk, mm); + *offset = 0; + + preload_slb(tsk, mm); } diff -Nru a/arch/ppc64/kernel/sys_ppc32.c b/arch/ppc64/kernel/sys_ppc32.c --- a/arch/ppc64/kernel/sys_ppc32.c Mon Feb 2 22:02:19 2004 +++ b/arch/ppc64/kernel/sys_ppc32.c Mon Feb 2 22:02:19 2004 @@ -14,6 +14,7 @@ * 2 of the License, or (at your option) any later version. */ +#include #include #include #include @@ -2845,6 +2846,7 @@ return -EFAULT; savefs = get_fs(); + set_fs(KERNEL_DS); err = sys_timer_create(clock, &event, &t); set_fs(savefs); diff -Nru a/arch/ppc64/kernel/viopath.c b/arch/ppc64/kernel/viopath.c --- a/arch/ppc64/kernel/viopath.c Mon Feb 2 22:02:18 2004 +++ b/arch/ppc64/kernel/viopath.c Mon Feb 2 22:02:18 2004 @@ -28,7 +28,6 @@ * Inc., 59 Temple Place, Suite 330, Boston, MA 02111-1307 USA * */ -#include #include #include #include diff -Nru a/arch/ppc64/mm/hash_low.S b/arch/ppc64/mm/hash_low.S --- a/arch/ppc64/mm/hash_low.S Mon Feb 2 22:02:19 2004 +++ b/arch/ppc64/mm/hash_low.S Mon Feb 2 22:02:19 2004 @@ -10,7 +10,6 @@ * described in the kernel's COPYING file. */ -#include #include #include #include diff -Nru a/arch/ppc64/mm/hugetlbpage.c b/arch/ppc64/mm/hugetlbpage.c --- a/arch/ppc64/mm/hugetlbpage.c Mon Feb 2 22:02:19 2004 +++ b/arch/ppc64/mm/hugetlbpage.c Mon Feb 2 22:02:19 2004 @@ -7,7 +7,6 @@ * Copyright (C) 2002, Rohit Seth */ -#include #include #include #include @@ -655,10 +654,9 @@ unsigned long hpteflags, prpn, flags; long slot; - ea &= ~(HPAGE_SIZE-1); - /* We have to find the first hugepte in the batch, since * that's the one that will store the HPTE flags */ + ea &= HPAGE_MASK; ptep = hugepte_offset(mm, ea); /* Search the Linux page table for a match with va */ @@ -886,10 +884,11 @@ spin_unlock(&htlbpage_lock); } htlbpage_max = htlbpage_free = htlbpage_total = i; - printk("Total HugeTLB memory allocated, %d\n", htlbpage_free); + printk(KERN_INFO "Total HugeTLB memory allocated, %d\n", + htlbpage_free); } else { htlbpage_max = 0; - printk("CPU does not support HugeTLB\n"); + printk(KERN_INFO "CPU does not support HugeTLB\n"); } return 0; diff -Nru a/arch/ppc64/xmon/start.c b/arch/ppc64/xmon/start.c --- a/arch/ppc64/xmon/start.c Mon Feb 2 22:02:19 2004 +++ b/arch/ppc64/xmon/start.c Mon Feb 2 22:02:19 2004 @@ -6,8 +6,10 @@ * as published by the Free Software Foundation; either version * 2 of the License, or (at your option) any later version. */ +#include #include #include +#include #include #include #include @@ -28,11 +30,14 @@ return ret; } +#ifdef CONFIG_MAGIC_SYSRQ + static void sysrq_handle_xmon(int key, struct pt_regs *pt_regs, struct tty_struct *tty) { xmon(pt_regs); } + static struct sysrq_key_op sysrq_xmon_op = { .handler = sysrq_handle_xmon, @@ -40,11 +45,15 @@ .action_msg = "Entering xmon\n", }; +#endif /* CONFIG_MAGIC_SYSRQ */ + void xmon_map_scc(void) { +#ifdef CONFIG_MAGIC_SYSRQ /* This maybe isn't the best place to register sysrq 'x' */ __sysrq_put_key_op('x', &sysrq_xmon_op); +#endif /* CONFIG_MAGIC_SYSRQ */ } int diff -Nru a/arch/s390/Makefile b/arch/s390/Makefile --- a/arch/s390/Makefile Mon Feb 2 22:02:19 2004 +++ b/arch/s390/Makefile Mon Feb 2 22:02:19 2004 @@ -70,3 +70,8 @@ $(call filechk,gen-asm-offsets) CLEAN_FILES += include/asm-$(ARCH)/offsets.h + +# Don't use tabs in echo arguments +define archhelp + echo '* image - Kernel image for IPL ($(boot)/image)' +endef diff -Nru a/arch/s390/defconfig b/arch/s390/defconfig --- a/arch/s390/defconfig Mon Feb 2 22:02:19 2004 +++ b/arch/s390/defconfig Mon Feb 2 22:02:19 2004 @@ -147,6 +147,7 @@ CONFIG_MD_RAID0=m CONFIG_MD_RAID1=m CONFIG_MD_RAID5=m +# CONFIG_MD_RAID6 is not set CONFIG_MD_MULTIPATH=m # CONFIG_BLK_DEV_DM is not set diff -Nru a/arch/s390/kernel/compat_linux.c b/arch/s390/kernel/compat_linux.c --- a/arch/s390/kernel/compat_linux.c Mon Feb 2 22:02:19 2004 +++ b/arch/s390/kernel/compat_linux.c Mon Feb 2 22:02:19 2004 @@ -1912,7 +1912,8 @@ security_bprm_free(&bprm); out_mm: - mmdrop(bprm.mm); + if (bprm.mm) + mmdrop(bprm.mm); out_file: if (bprm.file) { diff -Nru a/arch/s390/kernel/s390_ksyms.c b/arch/s390/kernel/s390_ksyms.c --- a/arch/s390/kernel/s390_ksyms.c Mon Feb 2 22:02:19 2004 +++ b/arch/s390/kernel/s390_ksyms.c Mon Feb 2 22:02:19 2004 @@ -9,6 +9,7 @@ #include #include #include +#include #include #include #include @@ -74,4 +75,5 @@ EXPORT_SYMBOL_NOVERS(do_call_softirq); EXPORT_SYMBOL(sys_wait4); EXPORT_SYMBOL(cpcmd); +EXPORT_SYMBOL(sys_ioctl); diff -Nru a/arch/s390/mm/init.c b/arch/s390/mm/init.c --- a/arch/s390/mm/init.c Mon Feb 2 22:02:19 2004 +++ b/arch/s390/mm/init.c Mon Feb 2 22:02:19 2004 @@ -79,8 +79,6 @@ * paging_init() sets up the page tables */ -unsigned long last_valid_pfn; - #ifndef CONFIG_ARCH_S390X void __init paging_init(void) { diff -Nru a/arch/sparc64/kernel/power.c b/arch/sparc64/kernel/power.c --- a/arch/sparc64/kernel/power.c Mon Feb 2 22:02:19 2004 +++ b/arch/sparc64/kernel/power.c Mon Feb 2 22:02:19 2004 @@ -29,8 +29,8 @@ static irqreturn_t power_handler(int irq, void *dev_id, struct pt_regs *regs) { if (button_pressed == 0) { - wake_up(&powerd_wait); button_pressed = 1; + wake_up(&powerd_wait); } /* FIXME: Check registers for status... */ @@ -86,10 +86,10 @@ remove_wait_queue(&powerd_wait, &wait); /* Ok, down we go... */ + button_pressed = 0; if (execve("/sbin/shutdown", argv, envp) < 0) { printk("powerd: shutdown execution failed\n"); add_wait_queue(&powerd_wait, &wait); - button_pressed = 0; goto again; } return 0; diff -Nru a/drivers/acpi/dispatcher/dsmthdat.c b/drivers/acpi/dispatcher/dsmthdat.c --- a/drivers/acpi/dispatcher/dsmthdat.c Mon Feb 2 22:02:19 2004 +++ b/drivers/acpi/dispatcher/dsmthdat.c Mon Feb 2 22:02:19 2004 @@ -203,9 +203,10 @@ while ((index < ACPI_METHOD_NUM_ARGS) && (index < max_param_count) && params[index]) { /* * A valid parameter. - * Store the argument in the method/walk descriptor + * Store the argument in the method/walk descriptor. + * Do not copy the arg in order to implement call by reference */ - status = acpi_ds_store_object_to_local (AML_ARG_OP, index, params[index], + status = acpi_ds_method_data_set_value (AML_ARG_OP, index, params[index], walk_state); if (ACPI_FAILURE (status)) { return_ACPI_STATUS (status); diff -Nru a/drivers/block/ll_rw_blk.c b/drivers/block/ll_rw_blk.c --- a/drivers/block/ll_rw_blk.c Mon Feb 2 22:02:18 2004 +++ b/drivers/block/ll_rw_blk.c Mon Feb 2 22:02:18 2004 @@ -145,6 +145,8 @@ q->activity_data = data; } +EXPORT_SYMBOL(blk_queue_activity_fn); + /** * blk_queue_prep_rq - set a prepare_request function for queue * @q: queue diff -Nru a/drivers/ide/Kconfig b/drivers/ide/Kconfig --- a/drivers/ide/Kconfig Mon Feb 2 22:02:19 2004 +++ b/drivers/ide/Kconfig Mon Feb 2 22:02:19 2004 @@ -296,6 +296,12 @@ comment "IDE chipset support/bugfixes" +config IDE_GENERIC + tristate "generic/default IDE chipset support" + default y + help + If unsure, say Y. + config BLK_DEV_CMD640 bool "CMD640 chipset bugfix/support" depends on X86 diff -Nru a/drivers/ide/Makefile b/drivers/ide/Makefile --- a/drivers/ide/Makefile Mon Feb 2 22:02:19 2004 +++ b/drivers/ide/Makefile Mon Feb 2 22:02:19 2004 @@ -13,22 +13,38 @@ obj-$(CONFIG_BLK_DEV_IDE) += pci/ +ide-core-y += ide.o ide-default.o ide-io.o ide-iops.o ide-lib.o ide-probe.o \ + ide-taskfile.o + +ide-core-$(CONFIG_BLK_DEV_CMD640) += pci/cmd640.o + # Core IDE code - must come before legacy +ide-core-$(CONFIG_BLK_DEV_IDEPCI) += setup-pci.o +ide-core-$(CONFIG_BLK_DEV_IDEDMA_PCI) += ide-dma.o +ide-core-$(CONFIG_BLK_DEV_IDE_TCQ) += ide-tcq.o +ide-core-$(CONFIG_PROC_FS) += ide-proc.o +ide-core-$(CONFIG_BLK_DEV_IDEPNP) += ide-pnp.o + +# built-in only drivers from legacy/ +ide-core-$(CONFIG_BLK_DEV_IDE_PC9800) += legacy/pc9800.o +ide-core-$(CONFIG_BLK_DEV_BUDDHA) += legacy/buddha.o +ide-core-$(CONFIG_BLK_DEV_FALCON_IDE) += legacy/falconide.o +ide-core-$(CONFIG_BLK_DEV_GAYLE) += legacy/gayle.o +ide-core-$(CONFIG_BLK_DEV_MAC_IDE) += legacy/macide.o +ide-core-$(CONFIG_BLK_DEV_Q40IDE) += legacy/q40ide.o + +# built-in only drivers from ppc/ +ide-core-$(CONFIG_BLK_DEV_MPC8xx_IDE) += ppc/mpc8xx.o +ide-core-$(CONFIG_BLK_DEV_IDE_PMAC) += ppc/pmac.o +ide-core-$(CONFIG_BLK_DEV_IDE_SWARM) += ppc/swarm.o + +obj-$(CONFIG_BLK_DEV_IDE) += ide-core.o +obj-$(CONFIG_IDE_GENERIC) += ide-generic.o -obj-$(CONFIG_BLK_DEV_IDE) += ide-io.o ide-probe.o ide-iops.o ide-taskfile.o ide.o ide-lib.o ide-default.o obj-$(CONFIG_BLK_DEV_IDEDISK) += ide-disk.o obj-$(CONFIG_BLK_DEV_IDECD) += ide-cd.o obj-$(CONFIG_BLK_DEV_IDETAPE) += ide-tape.o obj-$(CONFIG_BLK_DEV_IDEFLOPPY) += ide-floppy.o -obj-$(CONFIG_BLK_DEV_IDEPCI) += setup-pci.o -obj-$(CONFIG_BLK_DEV_IDEDMA_PCI) += ide-dma.o -obj-$(CONFIG_BLK_DEV_IDE_TCQ) += ide-tcq.o -obj-$(CONFIG_BLK_DEV_IDEPNP) += ide-pnp.o - -ifeq ($(CONFIG_BLK_DEV_IDE),y) -obj-$(CONFIG_PROC_FS) += ide-proc.o -endif - -obj-$(CONFIG_BLK_DEV_IDE) += legacy/ ppc/ arm/ +obj-$(CONFIG_BLK_DEV_IDE) += legacy/ arm/ obj-$(CONFIG_BLK_DEV_HD) += legacy/ diff -Nru a/drivers/ide/ide-generic.c b/drivers/ide/ide-generic.c --- /dev/null Wed Dec 31 16:00:00 1969 +++ b/drivers/ide/ide-generic.c Mon Feb 2 22:02:19 2004 @@ -0,0 +1,34 @@ +/* + * generic/default IDE host driver + * + * Copyright (C) 2004 Bartlomiej Zolnierkiewicz + * This code was split off from ide.c. See it for original copyrights. + * + * May be copied or modified under the terms of the GNU General Public License. + */ + +#include +#include +#include +#include + +static int __init ide_generic_init(void) +{ + MOD_INC_USE_COUNT; + if (ide_hwifs[0].io_ports[IDE_DATA_OFFSET]) + ide_get_lock(NULL, NULL); /* for atari only */ + + (void)ideprobe_init(); + + if (ide_hwifs[0].io_ports[IDE_DATA_OFFSET]) + ide_release_lock(); /* for atari only */ + +#ifdef CONFIG_PROC_FS + create_proc_ide_interfaces(); +#endif + return 0; +} + +module_init(ide_generic_init); + +MODULE_LICENSE("GPL"); diff -Nru a/drivers/ide/ide-probe.c b/drivers/ide/ide-probe.c --- a/drivers/ide/ide-probe.c Mon Feb 2 22:02:19 2004 +++ b/drivers/ide/ide-probe.c Mon Feb 2 22:02:19 2004 @@ -1322,8 +1322,7 @@ { unsigned int index; int probe[MAX_HWIFS]; - - MOD_INC_USE_COUNT; + memset(probe, 0, MAX_HWIFS * sizeof(int)); for (index = 0; index < MAX_HWIFS; ++index) probe[index] = !ide_hwifs[index].present; @@ -1343,32 +1342,14 @@ int unit; if (!hwif->present) continue; + if (hwif->chipset == ide_unknown || hwif->chipset == ide_forced) + hwif->chipset = ide_generic; for (unit = 0; unit < MAX_DRIVES; ++unit) if (hwif->drives[unit].present) ata_attach(&hwif->drives[unit]); } } - if (!ide_probe) - ide_probe = &ideprobe_init; - MOD_DEC_USE_COUNT; - return 0; -} - -#ifdef MODULE -int init_module (void) -{ - unsigned int index; - - for (index = 0; index < MAX_HWIFS; ++index) - ide_unregister(index); - ideprobe_init(); - create_proc_ide_interfaces(); return 0; } -void cleanup_module (void) -{ - ide_probe = NULL; -} -MODULE_LICENSE("GPL"); -#endif /* MODULE */ +EXPORT_SYMBOL_GPL(ideprobe_init); diff -Nru a/drivers/ide/ide-proc.c b/drivers/ide/ide-proc.c --- a/drivers/ide/ide-proc.c Mon Feb 2 22:02:19 2004 +++ b/drivers/ide/ide-proc.c Mon Feb 2 22:02:19 2004 @@ -348,8 +348,10 @@ int len; const char *name; + /* + * Neither ide_unknown nor ide_forced should be set at this point. + */ switch (hwif->chipset) { - case ide_unknown: name = "(none)"; break; case ide_generic: name = "generic"; break; case ide_pci: name = "pci"; break; case ide_cmd640: name = "cmd640"; break; diff -Nru a/drivers/ide/ide.c b/drivers/ide/ide.c --- a/drivers/ide/ide.c Mon Feb 2 22:02:19 2004 +++ b/drivers/ide/ide.c Mon Feb 2 22:02:19 2004 @@ -153,7 +153,6 @@ #include #include #include -#include #include #include @@ -191,8 +190,6 @@ EXPORT_SYMBOL(noautodma); EXPORT_SYMBOL(ide_bus_type); -int (*ide_probe)(void); - /* * This is declared extern in ide.h, for access by other IDE modules: */ @@ -443,21 +440,6 @@ EXPORT_SYMBOL(ide_dump_status); - - -void ide_probe_module (void) -{ - if (!ide_probe) { -#if defined(CONFIG_KMOD) && defined(CONFIG_BLK_DEV_IDE_MODULE) - (void) request_module("ide-probe-mod"); -#endif /* (CONFIG_KMOD) && (CONFIG_BLK_DEV_IDE_MODULE) */ - } else { - (void)ide_probe(); - } -} - -EXPORT_SYMBOL(ide_probe_module); - static int ide_open (struct inode * inode, struct file * filp) { return -ENXIO; @@ -1033,7 +1015,7 @@ hwif->chipset = hw->chipset; if (!initializing) { - ide_probe_module(); + probe_hwif_init(hwif); #ifdef CONFIG_PROC_FS create_proc_ide_interfaces(); #endif @@ -2179,7 +2161,7 @@ memcpy(hwif->io_ports, hwif->hw.io_ports, sizeof(hwif->io_ports)); hwif->irq = vals[2]; hwif->noprobe = 0; - hwif->chipset = ide_generic; + hwif->chipset = ide_forced; goto done; case 0: goto bad_option; @@ -2276,28 +2258,6 @@ #endif /* CONFIG_BLK_DEV_IDEPNP */ } -void __init ide_init_builtin_drivers (void) -{ - /* - * Probe for special PCI and other "known" interface chipsets - */ - probe_for_hwifs (); - -#ifdef CONFIG_BLK_DEV_IDE - if (ide_hwifs[0].io_ports[IDE_DATA_OFFSET]) - ide_get_lock(NULL, NULL); /* for atari only */ - - (void) ideprobe_init(); - - if (ide_hwifs[0].io_ports[IDE_DATA_OFFSET]) - ide_release_lock(); /* for atari only */ -#endif /* CONFIG_BLK_DEV_IDE */ - -#ifdef CONFIG_PROC_FS - proc_ide_create(); -#endif -} - /* * Actually unregister the subdriver. Called with the * request lock dropped. @@ -2558,7 +2518,6 @@ */ EXPORT_SYMBOL(ide_lock); -EXPORT_SYMBOL(ide_probe); struct bus_type ide_bus_type = { .name = "ide", @@ -2601,9 +2560,13 @@ #endif initializing = 1; - ide_init_builtin_drivers(); + /* Probe for special PCI and other "known" interface chipsets. */ + probe_for_hwifs(); initializing = 0; +#ifdef CONFIG_PROC_FS + proc_ide_create(); +#endif return 0; } diff -Nru a/drivers/ide/legacy/Makefile b/drivers/ide/legacy/Makefile --- a/drivers/ide/legacy/Makefile Mon Feb 2 22:02:19 2004 +++ b/drivers/ide/legacy/Makefile Mon Feb 2 22:02:19 2004 @@ -2,16 +2,9 @@ obj-$(CONFIG_BLK_DEV_ALI14XX) += ali14xx.o obj-$(CONFIG_BLK_DEV_DTC2278) += dtc2278.o obj-$(CONFIG_BLK_DEV_HT6560B) += ht6560b.o -obj-$(CONFIG_BLK_DEV_IDE_PC9800) += pc9800.o obj-$(CONFIG_BLK_DEV_PDC4030) += pdc4030.o obj-$(CONFIG_BLK_DEV_QD65XX) += qd65xx.o obj-$(CONFIG_BLK_DEV_UMC8672) += umc8672.o - -obj-$(CONFIG_BLK_DEV_BUDDHA) += buddha.o -obj-$(CONFIG_BLK_DEV_FALCON_IDE) += falconide.o -obj-$(CONFIG_BLK_DEV_GAYLE) += gayle.o -obj-$(CONFIG_BLK_DEV_MAC_IDE) += macide.o -obj-$(CONFIG_BLK_DEV_Q40IDE) += q40ide.o obj-$(CONFIG_BLK_DEV_IDECS) += ide-cs.o diff -Nru a/drivers/ide/pci/Makefile b/drivers/ide/pci/Makefile --- a/drivers/ide/pci/Makefile Mon Feb 2 22:02:19 2004 +++ b/drivers/ide/pci/Makefile Mon Feb 2 22:02:19 2004 @@ -3,7 +3,6 @@ obj-$(CONFIG_BLK_DEV_AEC62XX) += aec62xx.o obj-$(CONFIG_BLK_DEV_ALI15X3) += alim15x3.o obj-$(CONFIG_BLK_DEV_AMD74XX) += amd74xx.o -obj-$(CONFIG_BLK_DEV_CMD640) += cmd640.o obj-$(CONFIG_BLK_DEV_CMD64X) += cmd64x.o obj-$(CONFIG_BLK_DEV_CS5520) += cs5520.o obj-$(CONFIG_BLK_DEV_CS5530) += cs5530.o diff -Nru a/drivers/ide/pci/cmd640.c b/drivers/ide/pci/cmd640.c --- a/drivers/ide/pci/cmd640.c Mon Feb 2 22:02:19 2004 +++ b/drivers/ide/pci/cmd640.c Mon Feb 2 22:02:19 2004 @@ -419,7 +419,7 @@ cmd_hwif1 = &ide_hwifs[1]; /* default, if not found below */ for (i = 0; i < MAX_HWIFS; i++) { ide_hwif_t *hwif = &ide_hwifs[i]; - if (hwif->chipset == ide_unknown || hwif->chipset == ide_generic) { + if (hwif->chipset == ide_unknown || hwif->chipset == ide_forced) { if (hwif->io_ports[IDE_DATA_OFFSET] == 0x1f0) cmd_hwif0 = hwif; else if (hwif->io_ports[IDE_DATA_OFFSET] == 0x170) diff -Nru a/drivers/ide/ppc/Makefile b/drivers/ide/ppc/Makefile --- a/drivers/ide/ppc/Makefile Mon Feb 2 22:02:19 2004 +++ /dev/null Wed Dec 31 16:00:00 1969 @@ -1,6 +0,0 @@ - -obj-$(CONFIG_BLK_DEV_MPC8xx_IDE) += mpc8xx.o -obj-$(CONFIG_BLK_DEV_IDE_PMAC) += pmac.o -obj-$(CONFIG_BLK_DEV_IDE_SWARM) += swarm.o - -EXTRA_CFLAGS := -Idrivers/ide diff -Nru a/drivers/ide/setup-pci.c b/drivers/ide/setup-pci.c --- a/drivers/ide/setup-pci.c Mon Feb 2 22:02:19 2004 +++ b/drivers/ide/setup-pci.c Mon Feb 2 22:02:19 2004 @@ -59,7 +59,7 @@ for (h = 0; h < MAX_HWIFS; ++h) { hwif = &ide_hwifs[h]; if (hwif->io_ports[IDE_DATA_OFFSET] == io_base) { - if (hwif->chipset == ide_generic) + if (hwif->chipset == ide_forced) return hwif; /* a perfect match */ } } diff -Nru a/drivers/ieee1394/highlevel.c b/drivers/ieee1394/highlevel.c --- a/drivers/ieee1394/highlevel.c Mon Feb 2 22:02:19 2004 +++ b/drivers/ieee1394/highlevel.c Mon Feb 2 22:02:19 2004 @@ -261,30 +261,46 @@ return; } +static void __unregister_host(struct hpsb_highlevel *hl, struct hpsb_host *host) +{ + unsigned long flags; + struct list_head *lh, *next; + struct hpsb_address_serve *as; + + if (hl->remove_host) + hl->remove_host(host); + + /* Remove any addresses that are matched for this highlevel driver + * and this particular host. */ + write_lock_irqsave(&addr_space_lock, flags); + list_for_each_safe (lh, next, &hl->addr_list) { + as = list_entry(lh, struct hpsb_address_serve, addr_list); + + if (as->host != host) + continue; + + if (!list_empty(&as->addr_list)) { + list_del(&as->as_list); + list_del(&as->addr_list); + kfree(as); + } + } + write_unlock_irqrestore(&addr_space_lock, flags); + + hpsb_destroy_hostinfo(hl, host); +} + static int highlevel_for_each_host_unreg(struct hpsb_host *host, void *__data) { struct hpsb_highlevel *hl = __data; - hl->remove_host(host); - hpsb_destroy_hostinfo(hl, host); + __unregister_host(hl, host); return 0; } void hpsb_unregister_highlevel(struct hpsb_highlevel *hl) { - struct list_head *lh, *next; - struct hpsb_address_serve *as; - unsigned long flags; - - write_lock_irqsave(&addr_space_lock, flags); - list_for_each_safe (lh, next, &hl->addr_list) { - as = list_entry(lh, struct hpsb_address_serve, addr_list); - list_del(&as->as_list); - kfree(as); - } - write_unlock_irqrestore(&addr_space_lock, flags); - write_lock(&hl_irqs_lock); list_del(&hl->irq_list); write_unlock(&hl_irqs_lock); @@ -293,8 +309,7 @@ list_del(&hl->hl_list); up_write(&hl_drivers_sem); - if (hl->remove_host) - nodemgr_for_each_host(hl, highlevel_for_each_host_unreg); + nodemgr_for_each_host(hl, highlevel_for_each_host_unreg); } int hpsb_register_addrspace(struct hpsb_highlevel *hl, struct hpsb_host *host, @@ -435,29 +450,11 @@ void highlevel_remove_host(struct hpsb_host *host) { struct hpsb_highlevel *hl; - struct list_head *lh, *next; - struct hpsb_address_serve *as; - unsigned long flags; down_read(&hl_drivers_sem); - list_for_each_entry(hl, &hl_drivers, hl_list) { - if (hl->remove_host) { - hl->remove_host(host); - hpsb_destroy_hostinfo(hl, host); - } - } + list_for_each_entry(hl, &hl_drivers, hl_list) + __unregister_host(hl, host); up_read(&hl_drivers_sem); - - /* Free up 1394 address space left behind by high level drivers. */ - write_lock_irqsave(&addr_space_lock, flags); - list_for_each_safe (lh, next, &host->addr_space) { - as = list_entry(lh, struct hpsb_address_serve, as_list); - if (!list_empty(&as->addr_list)) { - list_del(&as->addr_list); - kfree(as); - } - } - write_unlock_irqrestore(&addr_space_lock, flags); } void highlevel_host_reset(struct hpsb_host *host) diff -Nru a/drivers/ieee1394/sbp2.c b/drivers/ieee1394/sbp2.c --- a/drivers/ieee1394/sbp2.c Mon Feb 2 22:02:18 2004 +++ b/drivers/ieee1394/sbp2.c Mon Feb 2 22:02:19 2004 @@ -745,6 +745,7 @@ SBP2_ERR("failed to add scsi host"); scsi_host_put(hi->scsi_host); hpsb_destroy_hostinfo(&sbp2_highlevel, host); + return NULL; } return hi; @@ -990,6 +991,9 @@ return PTR_ERR(sdev); } + sdev->hostdata = scsi_id; + scsi_id->sdev = sdev; + return 0; } @@ -999,7 +1003,6 @@ static void sbp2_remove_device(struct scsi_id_instance_data *scsi_id) { struct sbp2scsi_host_info *hi = scsi_id->hi; - struct scsi_device *sdev; SBP2_DEBUG("sbp2_remove_device"); @@ -1007,12 +1010,9 @@ sbp2scsi_complete_all_commands(scsi_id, DID_NO_CONNECT); /* Remove it from the scsi layer now */ - /* XXX(hch): why can't we simply cache the scsi_device - in struct scsi_id_instance_data? */ - sdev = scsi_device_lookup(hi->scsi_host, 0, scsi_id->id, 0); - if (sdev) { - scsi_remove_device(sdev); - scsi_device_put(sdev); + if (scsi_id->sdev) { + scsi_remove_device(scsi_id->sdev); + scsi_device_put(scsi_id->sdev); } sbp2util_remove_command_orb_pool(scsi_id); @@ -2849,6 +2849,27 @@ return "SCSI emulation for IEEE-1394 SBP-2 Devices"; } +static ssize_t sbp2_sysfs_ieee1394_guid_show(struct device *dev, char *buf) +{ + struct scsi_device *sdev; + struct scsi_id_instance_data *scsi_id; + + if (!(sdev = to_scsi_device(dev))) + return 0; + + if (!(scsi_id = sdev->hostdata)) + return 0; + + return sprintf(buf, "%016Lx\n", (unsigned long long)scsi_id->ne->guid); +} + +static DEVICE_ATTR(ieee1394_guid, S_IRUGO, sbp2_sysfs_ieee1394_guid_show, NULL); + +static struct device_attribute *sbp2_sysfs_sdev_attrs[] = { + &dev_attr_ieee1394_guid, + NULL +}; + MODULE_AUTHOR("Ben Collins "); MODULE_DESCRIPTION("IEEE-1394 SBP-2 protocol driver"); MODULE_SUPPORTED_DEVICE(SBP2_DEVICE_NAME); @@ -2871,6 +2892,7 @@ .cmd_per_lun = SBP2_MAX_CMDS_PER_LUN, .can_queue = SBP2_MAX_SCSI_QUEUE, .emulated = 1, + .sdev_attrs = sbp2_sysfs_sdev_attrs, }; static int sbp2_module_init(void) diff -Nru a/drivers/ieee1394/sbp2.h b/drivers/ieee1394/sbp2.h --- a/drivers/ieee1394/sbp2.h Mon Feb 2 22:02:19 2004 +++ b/drivers/ieee1394/sbp2.h Mon Feb 2 22:02:19 2004 @@ -410,6 +410,9 @@ /* A backlink to our host_info */ struct sbp2scsi_host_info *hi; + /* The scsi_device associated with this scsi_id */ + struct scsi_device *sdev; + /* Device specific workarounds/brokeness */ u32 workarounds; }; diff -Nru a/drivers/md/raid6x86.h b/drivers/md/raid6x86.h --- a/drivers/md/raid6x86.h Mon Feb 2 22:02:19 2004 +++ b/drivers/md/raid6x86.h Mon Feb 2 22:02:19 2004 @@ -32,18 +32,20 @@ /* N.B.: For SSE we only save %xmm0-%xmm7 even for x86-64, since the code doesn't know about the additional x86-64 registers */ typedef struct { - unsigned int sarea[8*4]; - unsigned int cr0; + unsigned int sarea[8*4+2]; + unsigned long cr0; } raid6_sse_save_t __attribute__((aligned(16))); /* This is for x86-64-specific code which uses all 16 XMM registers */ typedef struct { - unsigned int sarea[16*4]; + unsigned int sarea[16*4+2]; unsigned long cr0; } raid6_sse16_save_t __attribute__((aligned(16))); -/* On x86-64 the stack is 16-byte aligned */ -#define SAREA(x) (x->sarea) +/* On x86-64 the stack *SHOULD* be 16-byte aligned, but currently this + is buggy in the kernel and it's only 8-byte aligned in places, so + we need to do this anyway. Sigh. */ +#define SAREA(x) ((unsigned int *)((((unsigned long)&(x)->sarea)+15) & ~15)) #else /* __i386__ */ @@ -60,6 +62,7 @@ unsigned long cr0; } raid6_sse_save_t; +/* Find the 16-byte aligned save area */ #define SAREA(x) ((unsigned int *)((((unsigned long)&(x)->sarea)+15) & ~15)) #endif diff -Nru a/drivers/net/sk98lin/h/skversion.h b/drivers/net/sk98lin/h/skversion.h --- a/drivers/net/sk98lin/h/skversion.h Mon Feb 2 22:02:19 2004 +++ b/drivers/net/sk98lin/h/skversion.h Mon Feb 2 22:02:19 2004 @@ -61,14 +61,14 @@ #ifdef lint static const char SysKonnectFileId[] = "@(#) (C) SysKonnect GmbH."; static const char SysKonnectBuildNumber[] = - "@(#)SK-BUILD: 6.21 PL: 01"; + "@(#)SK-BUILD: 6.22 PL: 01"; #endif /* !defined(lint) */ -#define BOOT_STRING "sk98lin: Network Device Driver v6.21\n" \ - "(C)Copyright 1999-2003 Marvell(R)." +#define BOOT_STRING "sk98lin: Network Device Driver v6.22\n" \ + "(C)Copyright 1999-2004 Marvell(R)." -#define VER_STRING "6.21" +#define VER_STRING "6.22" #define DRIVER_FILE_NAME "sk98lin" -#define DRIVER_REL_DATE "Dec-15-2003" +#define DRIVER_REL_DATE "Jan-30-2004" diff -Nru a/drivers/net/sk98lin/skge.c b/drivers/net/sk98lin/skge.c --- a/drivers/net/sk98lin/skge.c Mon Feb 2 22:02:19 2004 +++ b/drivers/net/sk98lin/skge.c Mon Feb 2 22:02:19 2004 @@ -2,8 +2,8 @@ * * Name: skge.c * Project: GEnesis, PCI Gigabit Ethernet Adapter - * Version: $Revision: 1.42 $ - * Date: $Date: 2003/12/12 10:05:43 $ + * Version: $Revision: 1.43 $ + * Date: $Date: 2004/01/29 15:47:07 $ * Purpose: The main driver source module * ******************************************************************************/ @@ -41,6 +41,9 @@ * History: * * $Log: skge.c,v $ + * Revision 1.43 2004/01/29 15:47:07 mlindner + * Fix: Reset Xmac when stopping the port + * * Revision 1.42 2003/12/12 10:05:43 mlindner * Fix: Format of error message corrected * @@ -2154,6 +2157,7 @@ EvPara.Para32[0] = pNet->NetNr; EvPara.Para32[1] = -1; SkEventQueue(pAC, SKGE_RLMT, SK_RLMT_STOP, EvPara); + SkPnmiEvent(pAC, pAC->IoBase, SK_PNMI_EVT_XMAC_RESET, EvPara); SkEventDispatcher(pAC, pAC->IoBase); spin_unlock_irqrestore(&pAC->SlowPathLock, Flags); @@ -5002,6 +5006,7 @@ spin_lock_irqsave( &pAC->TxPort[FromPort][TX_PRIO_LOW].TxDesRingLock, Flags); + SkGeStopPort(pAC, IoC, FromPort, SK_STOP_ALL, SK_HARD_RST); pAC->dev[Param.Para32[0]]->flags &= ~IFF_RUNNING; spin_unlock_irqrestore( diff -Nru a/drivers/pci/probe.c b/drivers/pci/probe.c --- a/drivers/pci/probe.c Mon Feb 2 22:02:19 2004 +++ b/drivers/pci/probe.c Mon Feb 2 22:02:19 2004 @@ -53,8 +53,12 @@ static ssize_t pci_bus_show_cpuaffinity(struct class_device *class_dev, char *buf) { cpumask_t cpumask = pcibus_to_cpumask((to_pci_bus(class_dev))->number); + int ret; - return sprintf(buf, "%lx\n", (unsigned long)cpumask); + ret = cpumask_snprintf(buf, PAGE_SIZE, cpumask); + if (ret < PAGE_SIZE) + buf[ret++] = '\n'; + return ret; } static CLASS_DEVICE_ATTR(cpuaffinity, S_IRUGO, pci_bus_show_cpuaffinity, NULL); diff -Nru a/drivers/s390/char/sclp.c b/drivers/s390/char/sclp.c --- a/drivers/s390/char/sclp.c Mon Feb 2 22:02:19 2004 +++ b/drivers/s390/char/sclp.c Mon Feb 2 22:02:19 2004 @@ -315,8 +315,9 @@ /* Head queue a read sccb if an event buffer is pending */ if (evbuf_pending) __sclp_unconditional_read(); - /* Now clear the running bit */ - clear_bit(SCLP_RUNNING, &sclp_status); + /* Now clear the running bit if SCLP indicated a finished SCCB */ + if (finished_sccb != 0U) + clear_bit(SCLP_RUNNING, &sclp_status); spin_unlock(&sclp_lock); /* and start next request on the queue */ sclp_start_request(); diff -Nru a/drivers/s390/char/sclp_con.c b/drivers/s390/char/sclp_con.c --- a/drivers/s390/char/sclp_con.c Mon Feb 2 22:02:19 2004 +++ b/drivers/s390/char/sclp_con.c Mon Feb 2 22:02:19 2004 @@ -149,7 +149,8 @@ count -= written; } while (count > 0); /* Setup timer to output current console buffer after 1/10 second */ - if (sclp_conbuf != NULL && !timer_pending(&sclp_con_timer)) { + if (sclp_conbuf != NULL && sclp_chars_in_buffer(sclp_conbuf) != 0 && + !timer_pending(&sclp_con_timer)) { init_timer(&sclp_con_timer); sclp_con_timer.function = sclp_console_timeout; sclp_con_timer.data = 0UL; diff -Nru a/drivers/s390/char/sclp_rw.c b/drivers/s390/char/sclp_rw.c --- a/drivers/s390/char/sclp_rw.c Mon Feb 2 22:02:19 2004 +++ b/drivers/s390/char/sclp_rw.c Mon Feb 2 22:02:19 2004 @@ -274,7 +274,7 @@ if (buffer->current_line != NULL) sclp_finalize_mto(buffer); /* skip the rest of the message including the 0 byte */ - i_msg = count; + i_msg = count - 1; break; default: /* no escape character */ /* do not output unprintable characters */ diff -Nru a/drivers/s390/char/sclp_tty.c b/drivers/s390/char/sclp_tty.c --- a/drivers/s390/char/sclp_tty.c Mon Feb 2 22:02:19 2004 +++ b/drivers/s390/char/sclp_tty.c Mon Feb 2 22:02:19 2004 @@ -18,6 +18,7 @@ #include #include #include +#include #include #include "ctrlchar.h" @@ -337,8 +338,11 @@ if (sclp_ttybuf == NULL) { while (list_empty(&sclp_tty_pages)) { spin_unlock_irqrestore(&sclp_tty_lock, flags); - wait_event(sclp_tty_waitq, - !list_empty(&sclp_tty_pages)); + if (in_interrupt()) + sclp_sync_wait(); + else + wait_event(sclp_tty_waitq, + !list_empty(&sclp_tty_pages)); spin_lock_irqsave(&sclp_tty_lock, flags); } page = sclp_tty_pages.next; @@ -366,7 +370,9 @@ } while (count > 0); /* Setup timer to output current console buffer after 1/10 second */ if (sclp_ioctls.final_nl) { - if (sclp_ttybuf != NULL && !timer_pending(&sclp_tty_timer)) { + if (sclp_ttybuf != NULL && + sclp_chars_in_buffer(sclp_ttybuf) != 0 && + !timer_pending(&sclp_tty_timer)) { init_timer(&sclp_tty_timer); sclp_tty_timer.function = sclp_tty_timeout; sclp_tty_timer.data = 0UL; @@ -374,8 +380,14 @@ add_timer(&sclp_tty_timer); } } else { - __sclp_ttybuf_emit(sclp_ttybuf); - sclp_ttybuf = NULL; + if (sclp_ttybuf != NULL && + sclp_chars_in_buffer(sclp_ttybuf) != 0) { + buf = sclp_ttybuf; + sclp_ttybuf = NULL; + spin_unlock_irqrestore(&sclp_tty_lock, flags); + __sclp_ttybuf_emit(buf); + spin_lock_irqsave(&sclp_tty_lock, flags); + } } spin_unlock_irqrestore(&sclp_tty_lock, flags); } @@ -471,7 +483,7 @@ count = sclp_chars_in_buffer(sclp_ttybuf); list_for_each(l, &sclp_tty_outqueue) { t = list_entry(l, struct sclp_buffer, list); - count += sclp_chars_in_buffer(sclp_ttybuf); + count += sclp_chars_in_buffer(t); } spin_unlock_irqrestore(&sclp_tty_lock, flags); return count; diff -Nru a/drivers/s390/cio/device.c b/drivers/s390/cio/device.c --- a/drivers/s390/cio/device.c Mon Feb 2 22:02:19 2004 +++ b/drivers/s390/cio/device.c Mon Feb 2 22:02:19 2004 @@ -908,3 +908,4 @@ EXPORT_SYMBOL(ccw_driver_unregister); EXPORT_SYMBOL(get_ccwdev_by_busid); EXPORT_SYMBOL(ccw_bus_type); +EXPORT_SYMBOL(ccw_device_work); diff -Nru a/drivers/s390/net/ctctty.c b/drivers/s390/net/ctctty.c --- a/drivers/s390/net/ctctty.c Mon Feb 2 22:02:19 2004 +++ b/drivers/s390/net/ctctty.c Mon Feb 2 22:02:19 2004 @@ -1,5 +1,5 @@ /* - * $Id: ctctty.c,v 1.14 2003/10/06 11:33:33 mschwide Exp $ + * $Id: ctctty.c,v 1.15 2004/01/26 10:21:01 mschwide Exp $ * * CTC / ESCON network driver, tty interface. * @@ -759,9 +759,7 @@ info->line); #endif error = put_user(C_CLOCAL(tty) ? 1 : 0, (ulong *) arg); - if (error) - return error; - return 0; + return error; case TIOCSSOFTCAR: #ifdef CTC_DEBUG_MODEM_IOCTL printk(KERN_DEBUG "%s%d ioctl TIOCSSOFTCAR\n", CTC_TTY_NAME, diff -Nru a/drivers/usb/host/ehci-hub.c b/drivers/usb/host/ehci-hub.c --- a/drivers/usb/host/ehci-hub.c Mon Feb 2 22:02:19 2004 +++ b/drivers/usb/host/ehci-hub.c Mon Feb 2 22:02:19 2004 @@ -113,7 +113,7 @@ u16 temp; desc->bDescriptorType = 0x29; - desc->bPwrOn2PwrGood = 0; /* FIXME: f(system power) */ + desc->bPwrOn2PwrGood = 10; /* FIXME: f(system power) */ desc->bHubContrCurrent = 0; desc->bNbrPorts = ports; diff -Nru a/fs/compat_ioctl.c b/fs/compat_ioctl.c --- a/fs/compat_ioctl.c Mon Feb 2 22:02:19 2004 +++ b/fs/compat_ioctl.c Mon Feb 2 22:02:19 2004 @@ -3093,6 +3093,7 @@ HANDLE_IOCTL(SIOCGIFPFLAGS, dev_ifsioc) HANDLE_IOCTL(SIOCGIFTXQLEN, dev_ifsioc) HANDLE_IOCTL(SIOCSIFTXQLEN, dev_ifsioc) +HANDLE_IOCTL(TUNSETIFF, dev_ifsioc) HANDLE_IOCTL(SIOCETHTOOL, ethtool_ioctl) HANDLE_IOCTL(SIOCBONDENSLAVE, bond_ioctl) HANDLE_IOCTL(SIOCBONDRELEASE, bond_ioctl) diff -Nru a/include/asm-ppc/todc.h b/include/asm-ppc/todc.h --- a/include/asm-ppc/todc.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-ppc/todc.h Mon Feb 2 22:02:19 2004 @@ -290,8 +290,8 @@ #define TODC_TYPE_MC146818_SECONDS 0x00 #define TODC_TYPE_MC146818_CNTL_B 0x0a #define TODC_TYPE_MC146818_CNTL_A 0x0b /* control_a R/W regs */ -#define TODC_TYPE_MC146818_WATCHDOG 0x0c -#define TODC_TYPE_MC146818_INTERRUPTS 0x0d +#define TODC_TYPE_MC146818_WATCHDOG 0 +#define TODC_TYPE_MC146818_INTERRUPTS 0x0c #define TODC_TYPE_MC146818_ALARM_DATE 0xff #define TODC_TYPE_MC146818_ALARM_HOUR 0x05 #define TODC_TYPE_MC146818_ALARM_MINUTES 0x03 diff -Nru a/include/asm-ppc64/bugs.h b/include/asm-ppc64/bugs.h --- a/include/asm-ppc64/bugs.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-ppc64/bugs.h Mon Feb 2 22:02:19 2004 @@ -3,6 +3,10 @@ * bugs. * */ +#ifndef _ASM_PPC64_BUGS_H +#define _ASM_PPC64_BUGS_H static void check_bugs(void) { } + +#endif /* _ASM_PPC64_BUGS_H */ diff -Nru a/include/asm-ppc64/cputable.h b/include/asm-ppc64/cputable.h --- a/include/asm-ppc64/cputable.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-ppc64/cputable.h Mon Feb 2 22:02:19 2004 @@ -15,6 +15,8 @@ #ifndef __ASM_PPC_CPUTABLE_H #define __ASM_PPC_CPUTABLE_H +#include + /* Exposed to userland CPU features - Must match ppc32 definitions */ #define PPC_FEATURE_32 0x80000000 #define PPC_FEATURE_64 0x40000000 @@ -133,9 +135,16 @@ #define COMMON_USER_PPC64 (PPC_FEATURE_32 | PPC_FEATURE_64 | \ PPC_FEATURE_HAS_FPU | PPC_FEATURE_HAS_MMU) -#define CPU_FTR_PPCAS_ARCH_V2 (CPU_FTR_SLB | CPU_FTR_16M_PAGE | \ +#define CPU_FTR_PPCAS_ARCH_V2_BASE (CPU_FTR_SLB | \ CPU_FTR_TLBIEL | CPU_FTR_NOEXECUTE | \ CPU_FTR_NODSISRALIGN) + +/* iSeries doesn't support large pages */ +#ifdef CONFIG_PPC_ISERIES +#define CPU_FTR_PPCAS_ARCH_V2 (CPU_FTR_PPCAS_ARCH_V2_BASE) +#else +#define CPU_FTR_PPCAS_ARCH_V2 (CPU_FTR_PPCAS_ARCH_V2_BASE | CPU_FTR_16M_PAGE) +#endif #define COMMON_PPC64_FW (0) #endif diff -Nru a/include/asm-ppc64/hvcall.h b/include/asm-ppc64/hvcall.h --- a/include/asm-ppc64/hvcall.h Mon Feb 2 22:02:18 2004 +++ b/include/asm-ppc64/hvcall.h Mon Feb 2 22:02:18 2004 @@ -1,6 +1,9 @@ +#ifndef _PPC64_HVCALL_H +#define _PPC64_HVCALL_H #define H_Success 0 #define H_Busy 1 /* Hardware busy -- retry later */ +#define H_Constrained 4 /* Resource request constrained to max allowed */ #define H_Hardware -1 /* Hardware error */ #define H_Function -2 /* Function not supported */ #define H_Privilege -3 /* Caller not privileged */ @@ -138,3 +141,4 @@ unsigned long *out3, unsigned long *out4); +#endif /* _PPC64_HVCALL_H */ diff -Nru a/include/asm-ppc64/mmu.h b/include/asm-ppc64/mmu.h --- a/include/asm-ppc64/mmu.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-ppc64/mmu.h Mon Feb 2 22:02:19 2004 @@ -13,6 +13,7 @@ #ifndef _PPC64_MMU_H_ #define _PPC64_MMU_H_ +#include #include #ifndef __ASSEMBLY__ @@ -25,14 +26,6 @@ #else #define CONTEXT_LOW_HPAGES 0 #endif - -/* - * Define the size of the cache used for segment table entries. The first - * entry is used as a cache pointer, therefore the actual number of entries - * stored is one less than defined here. Do not change this value without - * considering the impact it will have on the layout of the paca in paca.h. - */ -#define STAB_CACHE_SIZE 16 /* * Hardware Segment Lookaside Buffer Entry diff -Nru a/include/asm-ppc64/mmu_context.h b/include/asm-ppc64/mmu_context.h --- a/include/asm-ppc64/mmu_context.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-ppc64/mmu_context.h Mon Feb 2 22:02:19 2004 @@ -1,6 +1,7 @@ #ifndef __PPC64_MMU_CONTEXT_H #define __PPC64_MMU_CONTEXT_H +#include #include #include #include @@ -138,6 +139,7 @@ } extern void flush_stab(struct task_struct *tsk, struct mm_struct *mm); +extern void flush_slb(struct task_struct *tsk, struct mm_struct *mm); /* * switch_mm is the entry point called from the architecture independent @@ -153,7 +155,15 @@ END_FTR_SECTION_IFSET(CPU_FTR_ALTIVEC) : : ); #endif /* CONFIG_ALTIVEC */ - flush_stab(tsk, next); + + /* No need to flush userspace segments if the mm doesnt change */ + if (prev == next) + return; + + if (cur_cpu_spec->cpu_features & CPU_FTR_SLB) + flush_slb(tsk, next); + else + flush_stab(tsk, next); cpu_set(smp_processor_id(), next->cpu_vm_mask); } diff -Nru a/include/asm-ppc64/paca.h b/include/asm-ppc64/paca.h --- a/include/asm-ppc64/paca.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-ppc64/paca.h Mon Feb 2 22:02:19 2004 @@ -63,20 +63,15 @@ u16 xPacaIndex; /* Logical processor number 0x18 */ u16 xHwProcNum; /* Physical processor number 0x1A */ u32 default_decr; /* Default decrementer value 0x1c */ - u64 unused1; - u64 xKsave; /* Saved Kernel stack addr or zero 0x28 */ - u64 pvr; /* Processor version register 0x30 */ - u8 *exception_sp; /* 0x38 */ - - struct ItLpQueue *lpQueuePtr; /* LpQueue handled by this processor 0x40 */ - u64 xTOC; /* Kernel TOC address 0x48 */ - STAB xStab_data; /* Segment table information 0x50,0x58,0x60 */ - u8 xSegments[STAB_CACHE_SIZE]; /* Cache of used stab entries 0x68,0x70 */ - u8 xProcEnabled; /* 1=soft enabled 0x78 */ - u8 unused2; - u8 prof_enabled; /* 1=iSeries profiling enabled 0x7A */ - u8 stab_cache_pointer; - u8 resv1[4]; /* 0x7B-0x7F */ + u64 xKsave; /* Saved Kernel stack addr or zero 0x20 */ + u64 pvr; /* Processor version register 0x28 */ + struct ItLpQueue *lpQueuePtr; /* LpQueue handled by this processor 0x30 */ + u64 xTOC; /* Kernel TOC address 0x38 */ + STAB xStab_data; /* Segment table information 0x40,0x48,0x50 */ + u8 *exception_sp; /* 0x58 */ + u8 xProcEnabled; /* 0x59 */ + u8 prof_enabled; /* 1=iSeries profiling enabled 0x60 */ + u8 resv1[30]; /* 0x61-0x7F */ /*===================================================================================== * CACHE_LINE_2 0x0080 - 0x00FF diff -Nru a/include/asm-ppc64/percpu.h b/include/asm-ppc64/percpu.h --- a/include/asm-ppc64/percpu.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-ppc64/percpu.h Mon Feb 2 22:02:19 2004 @@ -1,6 +1,6 @@ -#ifndef __ARCH_I386_PERCPU__ -#define __ARCH_I386_PERCPU__ +#ifndef __ARCH_PPC64_PERCPU__ +#define __ARCH_PPC64_PERCPU__ #include -#endif /* __ARCH_I386_PERCPU__ */ +#endif /* __ARCH_PPC64_PERCPU__ */ diff -Nru a/include/asm-ppc64/pgtable.h b/include/asm-ppc64/pgtable.h --- a/include/asm-ppc64/pgtable.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-ppc64/pgtable.h Mon Feb 2 22:02:19 2004 @@ -7,6 +7,7 @@ */ #ifndef __ASSEMBLY__ +#include #include #include /* For TASK_SIZE */ #include diff -Nru a/include/asm-ppc64/ppc_asm.h b/include/asm-ppc64/ppc_asm.h --- a/include/asm-ppc64/ppc_asm.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-ppc64/ppc_asm.h Mon Feb 2 22:02:19 2004 @@ -11,6 +11,8 @@ * 2 of the License, or (at your option) any later version. */ +#ifndef _PPC64_PPC_ASM_H +#define _PPC64_PPC_ASM_H /* * Macros for storing registers into and loading registers from * exception frames. @@ -238,3 +240,5 @@ #define vr29 29 #define vr30 30 #define vr31 31 + +#endif /* _PPC64_PPC_ASM_H */ diff -Nru a/include/asm-ppc64/processor.h b/include/asm-ppc64/processor.h --- a/include/asm-ppc64/processor.h Mon Feb 2 22:02:18 2004 +++ b/include/asm-ppc64/processor.h Mon Feb 2 22:02:18 2004 @@ -12,6 +12,7 @@ #include #ifndef __ASSEMBLY__ +#include #include #include #include diff -Nru a/include/asm-ppc64/ptrace-common.h b/include/asm-ppc64/ptrace-common.h --- a/include/asm-ppc64/ptrace-common.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-ppc64/ptrace-common.h Mon Feb 2 22:02:19 2004 @@ -9,6 +9,8 @@ * this archive for more details. */ +#ifndef _PPC64_PTRACE_COMMON_H +#define _PPC64_PTRACE_COMMON_H /* * Set of msr bits that gdb can change on behalf of a process. */ @@ -64,3 +66,5 @@ if (regs != NULL) regs->msr &= ~MSR_SE; } + +#endif /* _PPC64_PTRACE_COMMON_H */ diff -Nru a/include/asm-ppc64/serial.h b/include/asm-ppc64/serial.h --- a/include/asm-ppc64/serial.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-ppc64/serial.h Mon Feb 2 22:02:19 2004 @@ -1,6 +1,8 @@ /* - * include/asm-ppc/serial.h + * include/asm-ppc64/serial.h */ +#ifndef _PPC64_SERIAL_H +#define _PPC64_SERIAL_H #include @@ -124,3 +126,5 @@ EXTRA_SERIAL_PORT_DEFNS \ HUB6_SERIAL_PORT_DFNS \ MCA_SERIAL_PORT_DFNS + +#endif /* _PPC64_SERIAL_H */ diff -Nru a/include/asm-s390/atomic.h b/include/asm-s390/atomic.h --- a/include/asm-s390/atomic.h Mon Feb 2 22:02:18 2004 +++ b/include/asm-s390/atomic.h Mon Feb 2 22:02:18 2004 @@ -1,7 +1,6 @@ #ifndef __ARCH_S390_ATOMIC__ #define __ARCH_S390_ATOMIC__ -#ifdef __KERNEL__ /* * include/asm-s390/atomic.h * @@ -27,6 +26,8 @@ } __attribute__ ((aligned (4))) atomic_t; #define ATOMIC_INIT(i) { (i) } +#ifdef __KERNEL__ + #define __CS_LOOP(ptr, op_val, op_string) ({ \ typeof(ptr->counter) old_val, new_val; \ __asm__ __volatile__(" l %0,0(%3)\n" \ @@ -35,8 +36,10 @@ " cs %0,%1,0(%3)\n" \ " jl 0b" \ : "=&d" (old_val), "=&d" (new_val), \ - "+m" (((atomic_t *)(ptr))->counter) \ - : "a" (ptr), "d" (op_val) : "cc" ); \ + "=m" (((atomic_t *)(ptr))->counter) \ + : "a" (ptr), "d" (op_val), \ + "m" (((atomic_t *)(ptr))->counter) \ + : "cc", "memory" ); \ new_val; \ }) #define atomic_read(v) ((v)->counter) @@ -106,8 +109,10 @@ " csg %0,%1,0(%3)\n" \ " jl 0b" \ : "=&d" (old_val), "=&d" (new_val), \ - "+m" (((atomic_t *)(ptr))->counter) \ - : "a" (ptr), "d" (op_val) : "cc" ); \ + "=m" (((atomic_t *)(ptr))->counter) \ + : "a" (ptr), "d" (op_val), \ + "m" (((atomic_t *)(ptr))->counter) \ + : "cc", "memory" ); \ new_val; \ }) #define atomic64_read(v) ((v)->counter) @@ -182,9 +187,9 @@ " ipm %0\n" " srl %0,28\n" "0:" - : "=&d" (retval), "+m" (v->counter) - : "a" (v), "d" (expected_oldval) , "d" (new_val) - : "cc" ); + : "=&d" (retval), "=m" (v->counter) + : "a" (v), "d" (expected_oldval) , "d" (new_val), + "m" (v->counter) : "cc", "memory" ); return retval; } diff -Nru a/include/asm-s390/bitops.h b/include/asm-s390/bitops.h --- a/include/asm-s390/bitops.h Mon Feb 2 22:02:18 2004 +++ b/include/asm-s390/bitops.h Mon Feb 2 22:02:18 2004 @@ -13,6 +13,7 @@ * */ #include +#include /* * 32 bit bitops format: @@ -109,6 +110,8 @@ #endif /* __s390x__ */ +#define __BITOPS_BARRIER() __asm__ __volatile__ ( "" : : : "memory" ) + #ifdef CONFIG_SMP /* * SMP safe set_bit routine based on compare and swap (CS) @@ -189,6 +192,7 @@ mask = 1UL << (nr & (__BITOPS_WORDSIZE - 1)); /* Do the atomic update. */ __BITOPS_LOOP(old, new, addr, mask, __BITOPS_OR); + __BITOPS_BARRIER(); return (old & mask) != 0; } @@ -211,6 +215,7 @@ mask = ~(1UL << (nr & (__BITOPS_WORDSIZE - 1))); /* Do the atomic update. */ __BITOPS_LOOP(old, new, addr, mask, __BITOPS_AND); + __BITOPS_BARRIER(); return (old ^ new) != 0; } @@ -233,6 +238,7 @@ mask = 1UL << (nr & (__BITOPS_WORDSIZE - 1)); /* Do the atomic update. */ __BITOPS_LOOP(old, new, addr, mask, __BITOPS_XOR); + __BITOPS_BARRIER(); return (old & mask) != 0; } #endif /* CONFIG_SMP */ @@ -435,7 +441,7 @@ asm volatile("oc 0(1,%1),0(%2)" : "=m" (*(char *) addr) : "a" (addr), "a" (_oi_bitmap + (nr & 7)), - "m" (*(char *) addr) : "cc" ); + "m" (*(char *) addr) : "cc", "memory" ); return (ch >> (nr & 7)) & 1; } #define __test_and_set_bit(X,Y) test_and_set_bit_simple(X,Y) @@ -454,7 +460,7 @@ asm volatile("nc 0(1,%1),0(%2)" : "=m" (*(char *) addr) : "a" (addr), "a" (_ni_bitmap + (nr & 7)), - "m" (*(char *) addr) : "cc" ); + "m" (*(char *) addr) : "cc", "memory" ); return (ch >> (nr & 7)) & 1; } #define __test_and_clear_bit(X,Y) test_and_clear_bit_simple(X,Y) @@ -473,7 +479,7 @@ asm volatile("xc 0(1,%1),0(%2)" : "=m" (*(char *) addr) : "a" (addr), "a" (_oi_bitmap + (nr & 7)), - "m" (*(char *) addr) : "cc" ); + "m" (*(char *) addr) : "cc", "memory" ); return (ch >> (nr & 7)) & 1; } #define __test_and_change_bit(X,Y) test_and_change_bit_simple(X,Y) @@ -681,59 +687,6 @@ return (offset + res); } -/* - * ffz = Find First Zero in word. Undefined if no zero exists, - * so code should check against ~0UL first.. - */ -static inline unsigned long ffz(unsigned long word) -{ - unsigned long reg; - int result; - - __asm__(" slr %0,%0\n" - " lhi %2,0xff\n" - " tml %1,0xffff\n" - " jno 0f\n" - " ahi %0,16\n" - " srl %1,16\n" - "0: tml %1,0x00ff\n" - " jno 1f\n" - " ahi %0,8\n" - " srl %1,8\n" - "1: nr %1,%2\n" - " ic %1,0(%1,%3)\n" - " alr %0,%1" - : "=&d" (result), "+a" (word), "=&d" (reg) - : "a" (&_zb_findmap) : "cc" ); - return result; -} - -/* - * __ffs = find first bit in word. Undefined if no bit exists, - * so code should check against 0UL first.. - */ -static inline unsigned long __ffs (unsigned long word) -{ - unsigned long reg, result; - - __asm__(" slr %0,%0\n" - " lhi %2,0xff\n" - " tml %1,0xffff\n" - " jnz 0f\n" - " ahi %0,16\n" - " srl %1,16\n" - "0: tml %1,0x00ff\n" - " jnz 1f\n" - " ahi %0,8\n" - " srl %1,8\n" - "1: nr %1,%2\n" - " ic %1,0(%1,%3)\n" - " alr %0,%1" - : "=&d" (result), "+a" (word), "=&d" (reg) - : "a" (&_sb_findmap) : "cc" ); - return result; -} - #else /* __s390x__ */ /* @@ -910,35 +863,31 @@ return (offset + res); } +#endif /* __s390x__ */ + /* * ffz = Find First Zero in word. Undefined if no zero exists, * so code should check against ~0UL first.. */ static inline unsigned long ffz(unsigned long word) { - unsigned long reg, result; + unsigned long bit = 0; - __asm__(" lhi %2,-1\n" - " slgr %0,%0\n" - " clr %1,%2\n" - " jne 0f\n" - " aghi %0,32\n" - " srlg %1,%1,32\n" - "0: lghi %2,0xff\n" - " tmll %1,0xffff\n" - " jno 1f\n" - " aghi %0,16\n" - " srlg %1,%1,16\n" - "1: tmll %1,0x00ff\n" - " jno 2f\n" - " aghi %0,8\n" - " srlg %1,%1,8\n" - "2: ngr %1,%2\n" - " ic %1,0(%1,%3)\n" - " algr %0,%1" - : "=&d" (result), "+a" (word), "=&d" (reg) - : "a" (&_zb_findmap) : "cc" ); - return result; +#ifdef __s390x__ + if (likely((word & 0xffffffff) == 0xffffffff)) { + word >>= 32; + bit += 32; + } +#endif + if (likely((word & 0xffff) == 0xffff)) { + word >>= 16; + bit += 16; + } + if (likely((word & 0xff) == 0xff)) { + word >>= 8; + bit += 8; + } + return bit + _zb_findmap[word & 0xff]; } /* @@ -947,32 +896,25 @@ */ static inline unsigned long __ffs (unsigned long word) { - unsigned long reg, result; + unsigned long bit = 0; - __asm__(" slgr %0,%0\n" - " ltr %1,%1\n" - " jnz 0f\n" - " aghi %0,32\n" - " srlg %1,%1,32\n" - "0: lghi %2,0xff\n" - " tmll %1,0xffff\n" - " jnz 1f\n" - " aghi %0,16\n" - " srlg %1,%1,16\n" - "1: tmll %1,0x00ff\n" - " jnz 2f\n" - " aghi %0,8\n" - " srlg %1,%1,8\n" - "2: ngr %1,%2\n" - " ic %1,0(%1,%3)\n" - " algr %0,%1" - : "=&d" (result), "+a" (word), "=&d" (reg) - : "a" (&_sb_findmap) : "cc" ); - return result; +#ifdef __s390x__ + if (likely((word & 0xffffffff) == 0)) { + word >>= 32; + bit += 32; + } +#endif + if (likely((word & 0xffff) == 0)) { + word >>= 16; + bit += 16; + } + if (likely((word & 0xff) == 0)) { + word >>= 8; + bit += 8; + } + return bit + _sb_findmap[word & 0xff]; } -#endif /* __s390x__ */ - /* * Every architecture must define this function. It's the fastest * way of searching a 140-bit bitmap where the first 100 bits are @@ -989,68 +931,12 @@ * the libc and compiler builtin ffs routines, therefore * differs in spirit from the above ffz (man ffs). */ -extern inline int ffs (int x) -{ - int r = 1; - - if (x == 0) - return 0; - __asm__(" tml %1,0xffff\n" - " jnz 0f\n" - " srl %1,16\n" - " ahi %0,16\n" - "0: tml %1,0x00ff\n" - " jnz 1f\n" - " srl %1,8\n" - " ahi %0,8\n" - "1: tml %1,0x000f\n" - " jnz 2f\n" - " srl %1,4\n" - " ahi %0,4\n" - "2: tml %1,0x0003\n" - " jnz 3f\n" - " srl %1,2\n" - " ahi %0,2\n" - "3: tml %1,0x0001\n" - " jnz 4f\n" - " ahi %0,1\n" - "4:" - : "=&d" (r), "+d" (x) : : "cc" ); - return r; -} +#define ffs(x) generic_ffs(x) /* * fls: find last bit set. */ -static __inline__ int fls(int x) -{ - int r = 32; - - if (x == 0) - return 0; - __asm__(" tmh %1,0xffff\n" - " jz 0f\n" - " sll %1,16\n" - " ahi %0,-16\n" - "0: tmh %1,0xff00\n" - " jz 1f\n" - " sll %1,8\n" - " ahi %0,-8\n" - "1: tmh %1,0xf000\n" - " jz 2f\n" - " sll %1,4\n" - " ahi %0,-4\n" - "2: tmh %1,0xc000\n" - " jz 3f\n" - " sll %1,2\n" - " ahi %0,-2\n" - "3: tmh %1,0x8000\n" - " jz 4f\n" - " ahi %0,-1\n" - "4:" - : "+d" (r), "+d" (x) : : "cc" ); - return r; -} +#define fls(x) generic_fls(x) /* * hweightN: returns the hamming weight (i.e. the number @@ -1273,11 +1159,16 @@ /* Bitmap functions for the minix filesystem. */ /* FIXME !!! */ -#define minix_test_and_set_bit(nr,addr) test_and_set_bit(nr,addr) -#define minix_set_bit(nr,addr) set_bit(nr,addr) -#define minix_test_and_clear_bit(nr,addr) test_and_clear_bit(nr,addr) -#define minix_test_bit(nr,addr) test_bit(nr,addr) -#define minix_find_first_zero_bit(addr,size) find_first_zero_bit(addr,size) +#define minix_test_and_set_bit(nr,addr) \ + test_and_set_bit(nr,(unsigned long *)addr) +#define minix_set_bit(nr,addr) \ + set_bit(nr,(unsigned long *)addr) +#define minix_test_and_clear_bit(nr,addr) \ + test_and_clear_bit(nr,(unsigned long *)addr) +#define minix_test_bit(nr,addr) \ + test_bit(nr,(unsigned long *)addr) +#define minix_find_first_zero_bit(addr,size) \ + find_first_zero_bit(addr,size) #endif /* __KERNEL__ */ diff -Nru a/include/asm-s390/byteorder.h b/include/asm-s390/byteorder.h --- a/include/asm-s390/byteorder.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-s390/byteorder.h Mon Feb 2 22:02:19 2004 @@ -50,7 +50,7 @@ " icm %0,4,2(%1)\n" " icm %0,2,1(%1)\n" " ic %0,0(%1)" - : "=&d" (result) : "a" (x) : "cc" ); + : "=&d" (result) : "a" (x), "m" (*x) : "cc" ); #else /* __s390x__ */ " lrv %0,%1" : "=d" (result) : "m" (*x) ); @@ -67,7 +67,7 @@ __asm__ __volatile__ ( " lrvr %0,%1" - : "=d" (result) : "d" (x) ); + : "=d" (result) : "d" (x), "m" (x) ); return result; #endif /* __s390x__ */ } @@ -85,7 +85,7 @@ #ifndef __s390x__ " icm %0,2,1(%1)\n" " ic %0,0(%1)\n" - : "=&d" (result) : "a" (x) : "cc" ); + : "=&d" (result) : "a" (x), "m" (*x) : "cc" ); #else /* __s390x__ */ " lrvh %0,%1" : "=d" (result) : "m" (*x) ); diff -Nru a/include/asm-s390/checksum.h b/include/asm-s390/checksum.h --- a/include/asm-s390/checksum.h Mon Feb 2 22:02:18 2004 +++ b/include/asm-s390/checksum.h Mon Feb 2 22:02:18 2004 @@ -42,7 +42,7 @@ __asm__ __volatile__ ( "0: cksm %0,%1\n" /* do checksum on longs */ " jo 0b\n" - : "+&d" (sum), "+&a" (rp) : : "cc" ); + : "+&d" (sum), "+&a" (rp) : : "cc", "memory" ); #else /* __s390x__ */ __asm__ __volatile__ ( " lgr 2,%1\n" /* address in gpr 2 */ @@ -51,7 +51,7 @@ " jo 0b\n" : "+&d" (sum) : "d" (buff), "d" (len) - : "cc", "2", "3" ); + : "cc", "memory", "2", "3" ); #endif /* __s390x__ */ return sum; } diff -Nru a/include/asm-s390/div64.h b/include/asm-s390/div64.h --- a/include/asm-s390/div64.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-s390/div64.h Mon Feb 2 22:02:19 2004 @@ -36,8 +36,8 @@ " ahi 1,1\n" \ "1: st 1,4+%1\n" \ " lr %0,0" \ - : "=d" (__r), "+m" (__n) \ - : "d" (base) : "0", "1", "2", "cc" ); \ + : "=d" (__r), "=m" (__n) \ + : "d" (base), "m" (__n) : "0", "1", "2", "cc" ); \ (n) = (__n); \ __r; \ }) diff -Nru a/include/asm-s390/pgtable.h b/include/asm-s390/pgtable.h --- a/include/asm-s390/pgtable.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-s390/pgtable.h Mon Feb 2 22:02:19 2004 @@ -553,11 +553,15 @@ if (!(pte_val(pte) & _PAGE_INVALID)) { /* S390 has 1mb segments, we are emulating 4MB segments */ pte_t *pto = (pte_t *) (((unsigned long) ptep) & 0x7ffffc00); - __asm__ __volatile__ ("ipte %0,%1" : : "a" (pto), "a" (address)); + __asm__ __volatile__ ("ipte %2,%3" + : "=m" (*ptep) : "m" (*ptep), + "a" (pto), "a" (address) ); } #else /* __s390x__ */ if (!(pte_val(pte) & _PAGE_INVALID)) - __asm__ __volatile__ ("ipte %0,%1" : : "a" (ptep), "a" (address)); + __asm__ __volatile__ ("ipte %2,%3" + : "=m" (*ptep) : "m" (*ptep), + "a" (ptep), "a" (address) ); #endif /* __s390x__ */ pte_clear(ptep); return pte; diff -Nru a/include/asm-s390/processor.h b/include/asm-s390/processor.h --- a/include/asm-s390/processor.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-s390/processor.h Mon Feb 2 22:02:19 2004 @@ -66,7 +66,7 @@ #else /* __s390x__ */ -# define TASK_SIZE (0x20000000000UL) +# define TASK_SIZE (0x40000000000UL) # define TASK31_SIZE (0x80000000UL) # define TASK_UNMAPPED_BASE (test_thread_flag(TIF_31BIT) ? \ (TASK31_SIZE / 2) : (TASK_SIZE / 2)) @@ -200,14 +200,14 @@ " st %0,4(%1)\n" " lpsw 0(%1)\n" "1:" - : "=&d" (addr) : "a" (&psw) : "memory", "cc" ); + : "=&d" (addr) : "a" (&psw), "m" (psw) : "memory", "cc" ); #else /* __s390x__ */ asm volatile ( " larl %0,1f\n" " stg %0,8(%1)\n" " lpswe 0(%1)\n" "1:" - : "=&d" (addr) : "a" (&psw) : "memory", "cc" ); + : "=&d" (addr) : "a" (&psw), "m" (psw) : "memory", "cc" ); #endif /* __s390x__ */ } @@ -229,14 +229,16 @@ " oi 4(%1),0x80\n" " lpsw 0(%1)\n" "1:" - : "=&a" (reg) : "a" (&wait_psw) : "memory", "cc" ); + : "=&a" (reg) : "a" (&wait_psw), "m" (wait_psw) + : "memory", "cc" ); #else /* __s390x__ */ asm volatile ( " larl %0,0f\n" " stg %0,8(%1)\n" " lpswe 0(%1)\n" "0:" - : "=&a" (reg) : "a" (&wait_psw) : "memory", "cc" ); + : "=&a" (reg) : "a" (&wait_psw), "m" (wait_psw) + : "memory", "cc" ); #endif /* __s390x__ */ } @@ -247,7 +249,7 @@ static inline void disabled_wait(unsigned long code) { char psw_buffer[2*sizeof(psw_t)]; - char ctl_buf[4]; + unsigned long ctl_buf; psw_t *dw_psw = (psw_t *)(((unsigned long) &psw_buffer+sizeof(psw_t)-1) & -sizeof(psw_t)); @@ -258,9 +260,9 @@ * the processor is dead afterwards */ #ifndef __s390x__ - asm volatile (" stctl 0,0,0(%1)\n" - " ni 0(%1),0xef\n" /* switch off protection */ - " lctl 0,0,0(%1)\n" + asm volatile (" stctl 0,0,0(%2)\n" + " ni 0(%2),0xef\n" /* switch off protection */ + " lctl 0,0,0(%2)\n" " stpt 0xd8\n" /* store timer */ " stckc 0xe0\n" /* store clock comparator */ " stpx 0x108\n" /* store prefix register */ @@ -271,13 +273,14 @@ " std 6,0x178\n" /* store f6 */ " stm 0,15,0x180\n" /* store general registers */ " stctl 0,15,0x1c0\n" /* store control registers */ - " oi 0(%1),0x10\n" /* fake protection bit */ - " lpsw 0(%0)" - : : "a" (dw_psw), "a" (&ctl_buf) : "cc" ); -#else /* __s390x__ */ - asm volatile (" stctg 0,0,0(%1)\n" - " ni 4(%1),0xef\n" /* switch off protection */ - " lctlg 0,0,0(%1)\n" + " oi 0x1c0,0x10\n" /* fake protection bit */ + " lpsw 0(%1)" + : "=m" (ctl_buf) + : "a" (dw_psw), "a" (&ctl_buf), "m" (dw_psw) : "cc" ); +#else /* __s390x__ */ + asm volatile (" stctg 0,0,0(%2)\n" + " ni 4(%2),0xef\n" /* switch off protection */ + " lctlg 0,0,0(%2)\n" " lghi 1,0x1000\n" " stpt 0x328(1)\n" /* store timer */ " stckc 0x330(1)\n" /* store clock comparator */ @@ -303,8 +306,10 @@ " stmg 0,15,0x280(1)\n" /* store general registers */ " stctg 0,15,0x380(1)\n" /* store control registers */ " oi 0x384(1),0x10\n" /* fake protection bit */ - " lpswe 0(%0)" - : : "a" (dw_psw), "a" (&ctl_buf) : "cc", "0", "1"); + " lpswe 0(%1)" + : "=m" (ctl_buf) + : "a" (dw_psw), "a" (&ctl_buf), + "m" (dw_psw) : "cc", "0", "1"); #endif /* __s390x__ */ } diff -Nru a/include/asm-s390/rwsem.h b/include/asm-s390/rwsem.h --- a/include/asm-s390/rwsem.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-s390/rwsem.h Mon Feb 2 22:02:19 2004 @@ -102,21 +102,21 @@ __asm__ __volatile__( #ifndef __s390x__ - " l %0,0(%2)\n" + " l %0,0(%3)\n" "0: lr %1,%0\n" - " ahi %1,%3\n" - " cs %0,%1,0(%2)\n" + " ahi %1,%5\n" + " cs %0,%1,0(%3)\n" " jl 0b" #else /* __s390x__ */ - " lg %0,0(%2)\n" + " lg %0,0(%3)\n" "0: lgr %1,%0\n" - " aghi %1,%3\n" - " csg %0,%1,0(%2)\n" + " aghi %1,%5\n" + " csg %0,%1,0(%3)\n" " jl 0b" #endif /* __s390x__ */ - : "=&d" (old), "=&d" (new) - : "a" (&sem->count), "i" (RWSEM_ACTIVE_READ_BIAS) - : "cc", "memory" ); + : "=&d" (old), "=&d" (new), "=m" (sem->count) + : "a" (&sem->count), "m" (sem->count), + "i" (RWSEM_ACTIVE_READ_BIAS) : "cc", "memory" ); if (old < 0) rwsem_down_read_failed(sem); } @@ -130,25 +130,25 @@ __asm__ __volatile__( #ifndef __s390x__ - " l %0,0(%2)\n" + " l %0,0(%3)\n" "0: ltr %1,%0\n" " jm 1f\n" - " ahi %1,%3\n" - " cs %0,%1,0(%2)\n" + " ahi %1,%5\n" + " cs %0,%1,0(%3)\n" " jl 0b\n" "1:" #else /* __s390x__ */ - " lg %0,0(%2)\n" + " lg %0,0(%3)\n" "0: ltgr %1,%0\n" " jm 1f\n" - " aghi %1,%3\n" - " csg %0,%1,0(%2)\n" + " aghi %1,%5\n" + " csg %0,%1,0(%3)\n" " jl 0b\n" "1:" #endif /* __s390x__ */ - : "=&d" (old), "=&d" (new) - : "a" (&sem->count), "i" (RWSEM_ACTIVE_READ_BIAS) - : "cc", "memory" ); + : "=&d" (old), "=&d" (new), "=m" (sem->count) + : "a" (&sem->count), "m" (sem->count), + "i" (RWSEM_ACTIVE_READ_BIAS) : "cc", "memory" ); return old >= 0 ? 1 : 0; } @@ -162,20 +162,20 @@ tmp = RWSEM_ACTIVE_WRITE_BIAS; __asm__ __volatile__( #ifndef __s390x__ - " l %0,0(%2)\n" + " l %0,0(%3)\n" "0: lr %1,%0\n" - " a %1,%3\n" - " cs %0,%1,0(%2)\n" + " a %1,%5\n" + " cs %0,%1,0(%3)\n" " jl 0b" #else /* __s390x__ */ - " lg %0,0(%2)\n" + " lg %0,0(%3)\n" "0: lgr %1,%0\n" - " ag %1,%3\n" - " csg %0,%1,0(%2)\n" + " ag %1,%5\n" + " csg %0,%1,0(%3)\n" " jl 0b" #endif /* __s390x__ */ - : "=&d" (old), "=&d" (new) - : "a" (&sem->count), "m" (tmp) + : "=&d" (old), "=&d" (new), "=m" (sem->count) + : "a" (&sem->count), "m" (sem->count), "m" (tmp) : "cc", "memory" ); if (old != 0) rwsem_down_write_failed(sem); @@ -190,22 +190,22 @@ __asm__ __volatile__( #ifndef __s390x__ - " l %0,0(%1)\n" + " l %0,0(%2)\n" "0: ltr %0,%0\n" " jnz 1f\n" - " cs %0,%2,0(%1)\n" + " cs %0,%4,0(%2)\n" " jl 0b\n" #else /* __s390x__ */ - " lg %0,0(%1)\n" + " lg %0,0(%2)\n" "0: ltgr %0,%0\n" " jnz 1f\n" - " csg %0,%2,0(%1)\n" + " csg %0,%4,0(%2)\n" " jl 0b\n" #endif /* __s390x__ */ "1:" - : "=&d" (old) - : "a" (&sem->count), "d" (RWSEM_ACTIVE_WRITE_BIAS) - : "cc", "memory" ); + : "=&d" (old), "=m" (sem->count) + : "a" (&sem->count), "m" (sem->count), + "d" (RWSEM_ACTIVE_WRITE_BIAS) : "cc", "memory" ); return (old == RWSEM_UNLOCKED_VALUE) ? 1 : 0; } @@ -218,20 +218,21 @@ __asm__ __volatile__( #ifndef __s390x__ - " l %0,0(%2)\n" + " l %0,0(%3)\n" "0: lr %1,%0\n" - " ahi %1,%3\n" - " cs %0,%1,0(%2)\n" + " ahi %1,%5\n" + " cs %0,%1,0(%3)\n" " jl 0b" #else /* __s390x__ */ - " lg %0,0(%2)\n" + " lg %0,0(%3)\n" "0: lgr %1,%0\n" - " aghi %1,%3\n" - " csg %0,%1,0(%2)\n" + " aghi %1,%5\n" + " csg %0,%1,0(%3)\n" " jl 0b" #endif /* __s390x__ */ - : "=&d" (old), "=&d" (new) - : "a" (&sem->count), "i" (-RWSEM_ACTIVE_READ_BIAS) + : "=&d" (old), "=&d" (new), "=m" (sem->count) + : "a" (&sem->count), "m" (sem->count), + "i" (-RWSEM_ACTIVE_READ_BIAS) : "cc", "memory" ); if (new < 0) if ((new & RWSEM_ACTIVE_MASK) == 0) @@ -248,20 +249,20 @@ tmp = -RWSEM_ACTIVE_WRITE_BIAS; __asm__ __volatile__( #ifndef __s390x__ - " l %0,0(%2)\n" + " l %0,0(%3)\n" "0: lr %1,%0\n" - " a %1,%3\n" - " cs %0,%1,0(%2)\n" + " a %1,%5\n" + " cs %0,%1,0(%3)\n" " jl 0b" #else /* __s390x__ */ - " lg %0,0(%2)\n" + " lg %0,0(%3)\n" "0: lgr %1,%0\n" - " ag %1,%3\n" - " csg %0,%1,0(%2)\n" + " ag %1,%5\n" + " csg %0,%1,0(%3)\n" " jl 0b" #endif /* __s390x__ */ - : "=&d" (old), "=&d" (new) - : "a" (&sem->count), "m" (tmp) + : "=&d" (old), "=&d" (new), "=m" (sem->count) + : "a" (&sem->count), "m" (sem->count), "m" (tmp) : "cc", "memory" ); if (new < 0) if ((new & RWSEM_ACTIVE_MASK) == 0) @@ -278,20 +279,20 @@ tmp = -RWSEM_WAITING_BIAS; __asm__ __volatile__( #ifndef __s390x__ - " l %0,0(%2)\n" + " l %0,0(%3)\n" "0: lr %1,%0\n" - " a %1,%3\n" - " cs %0,%1,0(%2)\n" + " a %1,%5\n" + " cs %0,%1,0(%3)\n" " jl 0b" #else /* __s390x__ */ - " lg %0,0(%2)\n" + " lg %0,0(%3)\n" "0: lgr %1,%0\n" - " ag %1,%3\n" - " csg %0,%1,0(%2)\n" + " ag %1,%5\n" + " csg %0,%1,0(%3)\n" " jl 0b" #endif /* __s390x__ */ - : "=&d" (old), "=&d" (new) - : "a" (&sem->count), "m" (tmp) + : "=&d" (old), "=&d" (new), "=m" (sem->count) + : "a" (&sem->count), "m" (sem->count), "m" (tmp) : "cc", "memory" ); if (new > 1) rwsem_downgrade_wake(sem); @@ -306,20 +307,20 @@ __asm__ __volatile__( #ifndef __s390x__ - " l %0,0(%2)\n" + " l %0,0(%3)\n" "0: lr %1,%0\n" - " ar %1,%3\n" - " cs %0,%1,0(%2)\n" + " ar %1,%5\n" + " cs %0,%1,0(%3)\n" " jl 0b" #else /* __s390x__ */ - " lg %0,0(%2)\n" + " lg %0,0(%3)\n" "0: lgr %1,%0\n" - " agr %1,%3\n" - " csg %0,%1,0(%2)\n" + " agr %1,%5\n" + " csg %0,%1,0(%3)\n" " jl 0b" #endif /* __s390x__ */ - : "=&d" (old), "=&d" (new) - : "a" (&sem->count), "d" (delta) + : "=&d" (old), "=&d" (new), "=m" (sem->count) + : "a" (&sem->count), "m" (sem->count), "d" (delta) : "cc", "memory" ); } @@ -332,20 +333,20 @@ __asm__ __volatile__( #ifndef __s390x__ - " l %0,0(%2)\n" + " l %0,0(%3)\n" "0: lr %1,%0\n" - " ar %1,%3\n" - " cs %0,%1,0(%2)\n" + " ar %1,%5\n" + " cs %0,%1,0(%3)\n" " jl 0b" #else /* __s390x__ */ - " lg %0,0(%2)\n" + " lg %0,0(%3)\n" "0: lgr %1,%0\n" - " agr %1,%3\n" - " csg %0,%1,0(%2)\n" + " agr %1,%5\n" + " csg %0,%1,0(%3)\n" " jl 0b" #endif /* __s390x__ */ - : "=&d" (old), "=&d" (new) - : "a" (&sem->count), "d" (delta) + : "=&d" (old), "=&d" (new), "=m" (sem->count) + : "a" (&sem->count), "m" (sem->count), "d" (delta) : "cc", "memory" ); return new; } diff -Nru a/include/asm-s390/semaphore.h b/include/asm-s390/semaphore.h --- a/include/asm-s390/semaphore.h Mon Feb 2 22:02:18 2004 +++ b/include/asm-s390/semaphore.h Mon Feb 2 22:02:18 2004 @@ -95,9 +95,9 @@ " cs %0,%1,0(%3)\n" " jl 0b\n" "1:" - : "=&d" (old_val), "=&d" (new_val), - "+m" (sem->count.counter) - : "a" (&sem->count.counter) : "cc" ); + : "=&d" (old_val), "=&d" (new_val), "=m" (sem->count.counter) + : "a" (&sem->count.counter), "m" (sem->count.counter) + : "cc", "memory" ); return old_val <= 0; } diff -Nru a/include/asm-s390/spinlock.h b/include/asm-s390/spinlock.h --- a/include/asm-s390/spinlock.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-s390/spinlock.h Mon Feb 2 22:02:19 2004 @@ -57,8 +57,9 @@ "1: slr %1,%1\n" " cs %1,%0,0(%3)\n" " jl 0b\n" - : "=&d" (reg1), "=&d" (reg2), "+m" (lp->lock) - : "a" (&lp->lock) : "cc" ); + : "=&d" (reg1), "=&d" (reg2), "=m" (lp->lock) + : "a" (&lp->lock), "m" (lp->lock) + : "cc", "memory" ); #else /* __s390x__ */ unsigned long reg1, reg2; __asm__ __volatile(" bras %1,1f\n" @@ -66,9 +67,9 @@ "1: slr %0,%0\n" " cs %0,%1,0(%3)\n" " jl 0b\n" - : "=&d" (reg1), "=&d" (reg2), "+m" (lp->lock) - : "a" (&lp->lock), "i" (__DIAG44_OPERAND) - : "cc" ); + : "=&d" (reg1), "=&d" (reg2), "=m" (lp->lock) + : "a" (&lp->lock), "i" (__DIAG44_OPERAND), + "m" (lp->lock) : "cc", "memory" ); #endif /* __s390x__ */ } @@ -82,8 +83,9 @@ __asm__ __volatile(" slr %0,%0\n" " basr %1,0\n" "0: cs %0,%1,0(%3)" - : "=&d" (result), "=&d" (reg), "+m" (lp->lock) - : "a" (&lp->lock) : "cc" ); + : "=&d" (result), "=&d" (reg), "=m" (lp->lock) + : "a" (&lp->lock), "m" (lp->lock) + : "cc", "memory" ); return !result; } @@ -93,7 +95,8 @@ __asm__ __volatile("cs %0,%3,0(%4)" : "=d" (old), "=m" (lp->lock) - : "0" (lp->lock), "d" (0), "a" (lp) : "cc" ); + : "0" (lp->lock), "d" (0), "a" (lp) + : "cc", "memory" ); } /* @@ -126,8 +129,8 @@ " la 3,1(2)\n" /* one more reader */ \ " cs 2,3,0(%1)\n" /* try to write new value */ \ " jl 0b" \ - : "+m" ((rw)->lock) : "a" (&(rw)->lock) \ - : "2", "3", "cc" ) + : "=m" ((rw)->lock) : "a" (&(rw)->lock), \ + "m" ((rw)->lock) : "2", "3", "cc", "memory" ) #else /* __s390x__ */ #define _raw_read_lock(rw) \ asm volatile(" lg 2,0(%1)\n" \ @@ -137,9 +140,9 @@ " la 3,1(2)\n" /* one more reader */ \ " csg 2,3,0(%1)\n" /* try to write new value */ \ " jl 0b" \ - : "+m" ((rw)->lock) \ - : "a" (&(rw)->lock), "i" (__DIAG44_OPERAND) \ - : "2", "3", "cc" ) + : "=m" ((rw)->lock) \ + : "a" (&(rw)->lock), "i" (__DIAG44_OPERAND), \ + "m" ((rw)->lock) : "2", "3", "cc", "memory" ) #endif /* __s390x__ */ #ifndef __s390x__ @@ -151,8 +154,8 @@ " ahi 3,-1\n" /* one less reader */ \ " cs 2,3,0(%1)\n" \ " jl 0b" \ - : "+m" ((rw)->lock) : "a" (&(rw)->lock) \ - : "2", "3", "cc" ) + : "=m" ((rw)->lock) : "a" (&(rw)->lock), \ + "m" ((rw)->lock) : "2", "3", "cc", "memory" ) #else /* __s390x__ */ #define _raw_read_unlock(rw) \ asm volatile(" lg 2,0(%1)\n" \ @@ -162,9 +165,9 @@ " bctgr 3,0\n" /* one less reader */ \ " csg 2,3,0(%1)\n" \ " jl 0b" \ - : "+m" ((rw)->lock) \ - : "a" (&(rw)->lock), "i" (__DIAG44_OPERAND) \ - : "2", "3", "cc" ) + : "=m" ((rw)->lock) \ + : "a" (&(rw)->lock), "i" (__DIAG44_OPERAND), \ + "m" ((rw)->lock) : "2", "3", "cc", "memory" ) #endif /* __s390x__ */ #ifndef __s390x__ @@ -176,8 +179,8 @@ "1: slr 2,2\n" /* old lock value must be 0 */ \ " cs 2,3,0(%1)\n" \ " jl 0b" \ - : "+m" ((rw)->lock) : "a" (&(rw)->lock) \ - : "2", "3", "cc" ) + : "=m" ((rw)->lock) : "a" (&(rw)->lock), \ + "m" ((rw)->lock) : "2", "3", "cc", "memory" ) #else /* __s390x__ */ #define _raw_write_lock(rw) \ asm volatile(" llihh 3,0x8000\n" /* new lock value = 0x80...0 */ \ @@ -186,9 +189,9 @@ "1: slgr 2,2\n" /* old lock value must be 0 */ \ " csg 2,3,0(%1)\n" \ " jl 0b" \ - : "+m" ((rw)->lock) \ - : "a" (&(rw)->lock), "i" (__DIAG44_OPERAND) \ - : "2", "3", "cc" ) + : "=m" ((rw)->lock) \ + : "a" (&(rw)->lock), "i" (__DIAG44_OPERAND), \ + "m" ((rw)->lock) : "2", "3", "cc", "memory" ) #endif /* __s390x__ */ #ifndef __s390x__ @@ -200,8 +203,8 @@ " sll 2,31\n" /* old lock value must be 0x80000000 */ \ " cs 2,3,0(%1)\n" \ " jl 0b" \ - : "+m" ((rw)->lock) : "a" (&(rw)->lock) \ - : "2", "3", "cc" ) + : "=m" ((rw)->lock) : "a" (&(rw)->lock), \ + "m" ((rw)->lock) : "2", "3", "cc", "memory" ) #else /* __s390x__ */ #define _raw_write_unlock(rw) \ asm volatile(" slgr 3,3\n" /* new lock value = 0 */ \ @@ -210,9 +213,9 @@ "1: llihh 2,0x8000\n" /* old lock value must be 0x8..0 */\ " csg 2,3,0(%1)\n" \ " jl 0b" \ - : "+m" ((rw)->lock) \ - : "a" (&(rw)->lock), "i" (__DIAG44_OPERAND) \ - : "2", "3", "cc" ) + : "=m" ((rw)->lock) \ + : "a" (&(rw)->lock), "i" (__DIAG44_OPERAND), \ + "m" ((rw)->lock) : "2", "3", "cc", "memory" ) #endif /* __s390x__ */ extern inline int _raw_write_trylock(rwlock_t *rw) @@ -230,8 +233,9 @@ " llihh %1,0x8000\n" "0: csg %0,%1,0(%3)\n" #endif /* __s390x__ */ - : "=&d" (result), "=&d" (reg), "+m" (rw->lock) - : "a" (&rw->lock) : "cc" ); + : "=&d" (result), "=&d" (reg), "=m" (rw->lock) + : "a" (&rw->lock), "m" (rw->lock) + : "cc", "memory" ); return result == 0; } diff -Nru a/include/asm-s390/system.h b/include/asm-s390/system.h --- a/include/asm-s390/system.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-s390/system.h Mon Feb 2 22:02:19 2004 @@ -32,28 +32,28 @@ static inline void save_fp_regs(s390_fp_regs *fpregs) { asm volatile ( - " std 0,8(%0)\n" - " std 2,24(%0)\n" - " std 4,40(%0)\n" - " std 6,56(%0)" - : : "a" (fpregs) : "memory" ); + " std 0,8(%1)\n" + " std 2,24(%1)\n" + " std 4,40(%1)\n" + " std 6,56(%1)" + : "=m" (*fpregs) : "a" (fpregs), "m" (*fpregs) : "memory" ); if (!MACHINE_HAS_IEEE) return; asm volatile( - " stfpc 0(%0)\n" - " std 1,16(%0)\n" - " std 3,32(%0)\n" - " std 5,48(%0)\n" - " std 7,64(%0)\n" - " std 8,72(%0)\n" - " std 9,80(%0)\n" - " std 10,88(%0)\n" - " std 11,96(%0)\n" - " std 12,104(%0)\n" - " std 13,112(%0)\n" - " std 14,120(%0)\n" - " std 15,128(%0)\n" - : : "a" (fpregs) : "memory" ); + " stfpc 0(%1)\n" + " std 1,16(%1)\n" + " std 3,32(%1)\n" + " std 5,48(%1)\n" + " std 7,64(%1)\n" + " std 8,72(%1)\n" + " std 9,80(%1)\n" + " std 10,88(%1)\n" + " std 11,96(%1)\n" + " std 12,104(%1)\n" + " std 13,112(%1)\n" + " std 14,120(%1)\n" + " std 15,128(%1)\n" + : "=m" (*fpregs) : "a" (fpregs), "m" (*fpregs) : "memory" ); } static inline void restore_fp_regs(s390_fp_regs *fpregs) @@ -63,7 +63,7 @@ " ld 2,24(%0)\n" " ld 4,40(%0)\n" " ld 6,56(%0)" - : : "a" (fpregs)); + : : "a" (fpregs), "m" (*fpregs) ); if (!MACHINE_HAS_IEEE) return; asm volatile( @@ -80,7 +80,7 @@ " ld 13,112(%0)\n" " ld 14,120(%0)\n" " ld 15,128(%0)\n" - : : "a" (fpregs)); + : : "a" (fpregs), "m" (*fpregs) ); } #define switch_to(prev,next,last) do { \ @@ -107,15 +107,15 @@ shift = (3 ^ (addr & 3)) << 3; addr ^= addr & 3; asm volatile( - " l %0,0(%3)\n" + " l %0,0(%4)\n" "0: lr 0,%0\n" - " nr 0,%2\n" - " or 0,%1\n" - " cs %0,0,0(%3)\n" + " nr 0,%3\n" + " or 0,%2\n" + " cs %0,0,0(%4)\n" " jl 0b\n" - : "=&d" (old) - : "d" (x << shift), "d" (~(255 << shift)), "a" (addr) - : "memory", "cc", "0" ); + : "=&d" (old), "=m" (*(int *) addr) + : "d" (x << shift), "d" (~(255 << shift)), "a" (addr), + "m" (*(int *) addr) : "memory", "cc", "0" ); x = old >> shift; break; case 2: @@ -123,34 +123,36 @@ shift = (2 ^ (addr & 2)) << 3; addr ^= addr & 2; asm volatile( - " l %0,0(%3)\n" + " l %0,0(%4)\n" "0: lr 0,%0\n" - " nr 0,%2\n" - " or 0,%1\n" - " cs %0,0,0(%3)\n" + " nr 0,%3\n" + " or 0,%2\n" + " cs %0,0,0(%4)\n" " jl 0b\n" - : "=&d" (old) - : "d" (x << shift), "d" (~(65535 << shift)), "a" (addr) - : "memory", "cc", "0" ); + : "=&d" (old), "=m" (*(int *) addr) + : "d" (x << shift), "d" (~(65535 << shift)), "a" (addr), + "m" (*(int *) addr) : "memory", "cc", "0" ); x = old >> shift; break; case 4: asm volatile ( - " l %0,0(%2)\n" - "0: cs %0,%1,0(%2)\n" + " l %0,0(%3)\n" + "0: cs %0,%2,0(%3)\n" " jl 0b\n" - : "=&d" (old) : "d" (x), "a" (ptr) - : "memory", "cc", "0" ); + : "=&d" (old), "=m" (*(int *) ptr) + : "d" (x), "a" (ptr), "m" (*(int *) ptr) + : "memory", "cc" ); x = old; break; #ifdef __s390x__ case 8: asm volatile ( - " lg %0,0(%2)\n" - "0: csg %0,%1,0(%2)\n" + " lg %0,0(%3)\n" + "0: csg %0,%2,0(%3)\n" " jl 0b\n" - : "=&d" (old) : "d" (x), "a" (ptr) - : "memory", "cc", "0" ); + : "=&d" (old), "=m" (*(long *) ptr) + : "d" (x), "a" (ptr), "m" (*(long *) ptr) + : "memory", "cc" ); x = old; break; #endif /* __s390x__ */ @@ -268,7 +270,8 @@ #define local_irq_enable() ({ \ unsigned long __dummy; \ __asm__ __volatile__ ( \ - "stosm 0(%1),0x03" : "=m" (__dummy) : "a" (&__dummy) ); \ + "stosm 0(%1),0x03" \ + : "=m" (__dummy) : "a" (&__dummy) : "memory" ); \ }) #define local_irq_disable() ({ \ @@ -279,10 +282,10 @@ }) #define local_save_flags(x) \ - __asm__ __volatile__("stosm 0(%1),0" : "=m" (x) : "a" (&x) ) + __asm__ __volatile__("stosm 0(%1),0" : "=m" (x) : "a" (&x), "m" (x) ) #define local_irq_restore(x) \ - __asm__ __volatile__("ssm 0(%0)" : : "a" (&x) : "memory") + __asm__ __volatile__("ssm 0(%0)" : : "a" (&x), "m" (x) : "memory") #define irqs_disabled() \ ({ \ @@ -294,7 +297,7 @@ #ifdef __s390x__ #define __load_psw(psw) \ - __asm__ __volatile__("lpswe 0(%0)" : : "a" (&psw) : "cc" ); + __asm__ __volatile__("lpswe 0(%0)" : : "a" (&psw), "m" (psw) : "cc" ); #define __ctl_load(array, low, high) ({ \ __asm__ __volatile__ ( \ diff -Nru a/include/asm-s390/timex.h b/include/asm-s390/timex.h --- a/include/asm-s390/timex.h Mon Feb 2 22:02:18 2004 +++ b/include/asm-s390/timex.h Mon Feb 2 22:02:18 2004 @@ -25,7 +25,7 @@ { cycles_t cycles; - __asm__("stck 0(%0)" : : "a" (&(cycles)) : "memory", "cc"); + __asm__("stck 0(%1)" : "=m" (cycles) : "a" (&cycles) : "cc"); return cycles >> 2; } @@ -33,7 +33,7 @@ { unsigned long long clk; - __asm__("stck 0(%0)" : : "a" (&(clk)) : "memory", "cc"); + __asm__("stck 0(%1)" : "=m" (clk) : "a" (&clk) : "cc"); return clk; } diff -Nru a/include/asm-s390/tlbflush.h b/include/asm-s390/tlbflush.h --- a/include/asm-s390/tlbflush.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-s390/tlbflush.h Mon Feb 2 22:02:19 2004 @@ -85,7 +85,7 @@ " slr 2,2\n" " slr 3,3\n" " csp 2,%0" - : : "a" (addr) : "cc", "2", "3" ); + : : "a" (addr), "m" (dummy) : "cc", "2", "3" ); } } diff -Nru a/include/asm-s390/uaccess.h b/include/asm-s390/uaccess.h --- a/include/asm-s390/uaccess.h Mon Feb 2 22:02:19 2004 +++ b/include/asm-s390/uaccess.h Mon Feb 2 22:02:19 2004 @@ -124,8 +124,8 @@ "1:\n" \ __uaccess_fixup \ : "=&d" (err) \ - : "a" (__to),"a" (__from),"K" (-EFAULT),"0" (0) \ - : "cc" ); \ + : "a" (__to),"a" (__from),"K" (-EFAULT),"0" (0),\ + "m" (x) : "cc" ); \ }) #else /* __s390x__ */ diff -Nru a/include/linux/compat_ioctl.h b/include/linux/compat_ioctl.h --- a/include/linux/compat_ioctl.h Mon Feb 2 22:02:19 2004 +++ b/include/linux/compat_ioctl.h Mon Feb 2 22:02:19 2004 @@ -192,7 +192,6 @@ /* Big T */ COMPATIBLE_IOCTL(TUNSETNOCSUM) COMPATIBLE_IOCTL(TUNSETDEBUG) -COMPATIBLE_IOCTL(TUNSETIFF) COMPATIBLE_IOCTL(TUNSETPERSIST) COMPATIBLE_IOCTL(TUNSETOWNER) /* Big V */ diff -Nru a/include/linux/ide.h b/include/linux/ide.h --- a/include/linux/ide.h Mon Feb 2 22:02:19 2004 +++ b/include/linux/ide.h Mon Feb 2 22:02:19 2004 @@ -279,7 +279,7 @@ ide_pdc4030, ide_rz1000, ide_trm290, ide_cmd646, ide_cy82c693, ide_4drives, ide_pmac, ide_etrax100, ide_acorn, - ide_pc9800 + ide_pc9800, ide_forced } hwif_chipset_t; /* @@ -1231,7 +1231,6 @@ */ #ifndef _IDE_C extern ide_hwif_t ide_hwifs[]; /* master data repository */ -extern int (*ide_probe)(void); extern ide_devices_t *idedisk; extern ide_devices_t *idecd; diff -Nru a/include/linux/proc_fs.h b/include/linux/proc_fs.h --- a/include/linux/proc_fs.h Mon Feb 2 22:02:19 2004 +++ b/include/linux/proc_fs.h Mon Feb 2 22:02:19 2004 @@ -133,8 +133,14 @@ */ struct device_node; extern void proc_device_tree_init(void); +#ifdef CONFIG_PROC_DEVICETREE extern void proc_device_tree_add_node(struct device_node *, struct proc_dir_entry *); - +#else /* !CONFIG_PROC_DEVICETREE */ +static inline void proc_device_tree_add_node(struct device_node *np, struct proc_dir_entry *pde) +{ + return; +} +#endif /* CONFIG_PROC_DEVICETREE */ /* * proc_rtas.c */ diff -Nru a/kernel/exit.c b/kernel/exit.c --- a/kernel/exit.c Mon Feb 2 22:02:19 2004 +++ b/kernel/exit.c Mon Feb 2 22:02:19 2004 @@ -403,6 +403,8 @@ } } +EXPORT_SYMBOL(put_files_struct); + static inline void __exit_files(struct task_struct *tsk) { struct files_struct * files = tsk->files;