1. 02 Oct, 2006 40 commits
    • Linus Torvalds's avatar
      Merge master.kernel.org:/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog · b65d04a7
      Linus Torvalds authored
      * master.kernel.org:/pub/scm/linux/kernel/git/wim/linux-2.6-watchdog:
        [WATCHDOG] improve machzwd detection
        [WATCHDOG] use ENOTTY instead of ENOIOCTLCMD in ioctl()
        [WATCHDOG] s3c24XX nowayout
        [WATCHDOG] pnx4008: add cpu_relax()
        [WATCHDOG] pnx4008_wdt.c - spinlock fixes.
        [WATCHDOG] pnx4008_wdt.c - remove patch
        [WATCHDOG] pnx4008_wdt.c - nowayout patch
        [WATCHDOG] pnx4008: add watchdog support
        [WATCHDOG] i8xx_tco remove pci_find_device.
        [WATCHDOG] alim remove pci_find_device
      b65d04a7
    • Dave Jones's avatar
      [WATCHDOG] improve machzwd detection · 11dc1019
      Dave Jones authored
      On a machine with no machzwd, loading the module prints out..
      
      machzwd: MachZ ZF-Logic Watchdog driver initializing.
      0xffff
      machzwd: Watchdog using action = RESET
      
      - the 0xffff printk is unnecessary
      - 0xffff seems to be 'hardware not present'
      - fix CodingStyle. (This driver could use some more work here)
      Signed-off-by: default avatarDave Jones <davej@redhat.com>
      Signed-off-by: default avatarWim Van Sebroeck <wim@iguana.be>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      11dc1019
    • Samuel Tardieu's avatar
      [WATCHDOG] use ENOTTY instead of ENOIOCTLCMD in ioctl() · 795b89d2
      Samuel Tardieu authored
      Return ENOTTY instead of ENOIOCTLCMD in user-visible ioctl() results
      
      The watchdog drivers used to return ENOIOCTLCMD for bad ioctl() commands.
      ENOIOCTLCMD should not be visible by the user, so use ENOTTY instead.
      Signed-off-by: default avatarSamuel Tardieu <sam@rfc1149.net>
      Signed-off-by: default avatarWim Van Sebroeck <wim@iguana.be>
      Acked-by: default avatarAlan Cox <alan@redhat.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      795b89d2
    • Ben Dooks's avatar
      [WATCHDOG] s3c24XX nowayout · 25ff3780
      Ben Dooks authored
      If the driver is not configured for `no way out`,
      then the open method should not automatically allow
      the setting of allow_close to CLOSE_STATE_ALLOW.
      
      The setting of allow_close nullifies the use of
      the magic close via the write path. It means that
      in the default state, the watchdog will shut-down
      even if the magic close has not been issued.
      Signed-off-by: default avatarBen Dooks <ben-linux@fluff.org>
      25ff3780
    • Vitaly Wool's avatar
      [WATCHDOG] pnx4008: add cpu_relax() · 65a64ec3
      Vitaly Wool authored
      Added cpu_relax as suggested by Alan Cox.
      Signed-off-by: default avatarVitaly Wool <vitalywool@gmail.com>
      Signed-off-by: default avatarWim Van Sebroeck <wim@iguana.be>
      65a64ec3
    • Wim Van Sebroeck's avatar
      [WATCHDOG] pnx4008_wdt.c - spinlock fixes. · 99d2853a
      Wim Van Sebroeck authored
      Add io spinlocks to prevent possible race
      conditions between start and stop operations
      that are issued from different child processes
      where the master process opened /dev/watchdog.
      Signed-off-by: default avatarWim Van Sebroeck <wim@iguana.be>
      99d2853a
    • Linus Torvalds's avatar
      Add prototype for sigset_from_compat() · 0235497f
      Linus Torvalds authored
      Duh.  I screwed up editing David Howells patch in commit
      3f2e05e9, and the actual declaration for
      the sigset_from_compat() function went missing. My bad.
      
      Olaf Hering saved the day and noticed that I'm a moron.
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      0235497f
    • Wim Van Sebroeck's avatar
      [WATCHDOG] pnx4008_wdt.c - remove patch · f6764497
      Wim Van Sebroeck authored
      Change remove code so that we first detach
      the driver from userspace, then clean up the
      clock and then clean up the memory we allocated.
      Signed-off-by: default avatarWim Van Sebroeck <wim@iguana.be>
      f6764497
    • Wim Van Sebroeck's avatar
      [WATCHDOG] pnx4008_wdt.c - nowayout patch · 28981727
      Wim Van Sebroeck authored
      Change nowayout to: WATCHDOG_NOWAYOUT as defined
      in include/linux/watchdog.h .
      Signed-off-by: default avatarWim Van Sebroeck <wim@iguana.be>
      28981727
    • Vitaly Wool's avatar
      [WATCHDOG] pnx4008: add watchdog support · 9325fa36
      Vitaly Wool authored
      Add watchdog support for Philips PNX4008 ARM board inlined.
      Signed-off-by: default avatarVitaly Wool <vitalywool@gmail.com>
      Signed-off-by: default avatarWim Van Sebroeck <wim@iguana.be>
      9325fa36
    • Jiri Slaby's avatar
      [WATCHDOG] i8xx_tco remove pci_find_device. · 92dd9994
      Jiri Slaby authored
      Use refcounting for pci device obtaining.
      Use PCI_DEVICE macro.
      Signed-off-by: default avatarJiri Slaby <jirislaby@gmail.com>
      Signed-off-by: default avatarWim Van Sebroeck <wim@iguana.be>
      Cc: Andrew Morton <akpm@osdl.org>
      92dd9994
    • Jiri Slaby's avatar
      [WATCHDOG] alim remove pci_find_device · 02be2ee9
      Jiri Slaby authored
      Convert pci_find_device to pci_get_device + pci_dev_put
      in alim watchdog cards' drivers (refcounting).
      Signed-off-by: default avatarJiri Slaby <jirislaby@gmail.com>
      Signed-off-by: default avatarWim Van Sebroeck <wim@iguana.be>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      02be2ee9
    • Linus Torvalds's avatar
      Merge branch 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6 · 95f3eff6
      Linus Torvalds authored
      * 'upstream-linus' of master.kernel.org:/pub/scm/linux/kernel/git/jgarzik/netdev-2.6: (37 commits)
        [netdrvr] hp100: encapsulate all non-module code
        drivers/net/wireless/{airo,ipw2100}: fix error handling bugs
        [netdrvr] phy: Fix bugs in error handling
        [PATCH] spidernet: Use pci_dma_mapping_error()
        [PATCH] sky2: version 1.9
        [PATCH] sky2: fragmented receive for large MTU
        [PATCH] sky2: use netif_tx_lock instead of LLTX
        [PATCH] sky2: incremental transmit completion
        [PATCH] sky2: name irq after eth for irqbalance
        [PATCH] sky2: workarounds for some 88e806x chips
        [PATCH] sky2: use standard pci register capabilties for error register
        [PATCH] sky2: gigabit full duplex negotiation
        e100, e1000, ixgb: increment version numbers
        ixgb: convert to netdev_priv(netdev)
        ixgb: combine more rx descriptors to improve performance
        e1000: possible memory leak in e1000_set_ringparam
        e1000: Janitor: Use #defined values for literals
        e1000: don't strip vlan ID if 8021q claims it
        e1000: rework polarity, NVM, eeprom code and fixes.
        e1000: driver state fixes (race fix)
        ...
      95f3eff6
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/shaggy/jfs-2.6 · 44f54921
      Linus Torvalds authored
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/shaggy/jfs-2.6:
        JFS: White space cleanup
        [PATCH] JFS: return correct error when i-node allocation failed
        JFS: Remove shadow variable from fs/jfs/jfs_txnmgr.c:xtLog()
      44f54921
    • Linus Torvalds's avatar
      Merge git://git.infradead.org/mtd-2.6 · 3e04767a
      Linus Torvalds authored
      * git://git.infradead.org/mtd-2.6:
        [MTD] Cleanup of 'ioremap balanced with iounmap for drivers/mtd subsystem'
        [MTD] fix nftl_write warning
        [MTD] fix printk warning
        [MTD ONENAND] Check OneNAND lock scheme & all block unlock command support
        [MTD ONENAND] Remove unused MTD_ONENAND_SYNC_READ configuration
        [MTD ONENAND] Fix OneNAND probe
        [MTD NAND] Provide prototype for newly-exported nand_wait_ready()
        [MTD] Remove #ifndef __KERNEL__ hack in <mtd/mtd-abi.h>
        [MTD NAND] Allow override of page read and write functions.
        [MTD NAND] Allocate chip->buffers separately to allow it to be overridden
        [MTD NAND] Split nand_scan() into two parts; allow board driver to intervene
        [MTD NAND] Export nand_wait_ready() for use by board drivers
      3e04767a
    • Linus Torvalds's avatar
      Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input · a12f66fc
      Linus Torvalds authored
      * 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/dtor/input: (35 commits)
        Input: wistron - add support for Acer TravelMate 2424NWXCi
        Input: wistron - fix setting up special buttons
        Input: add KEY_BLUETOOTH and KEY_WLAN definitions
        Input: add new BUS_VIRTUAL bus type
        Input: add driver for stowaway serial keyboards
        Input: make input_register_handler() return error codes
        Input: remove cruft that was needed for transition to sysfs
        Input: fix input module refcounting
        Input: constify input core
        Input: libps2 - rearrange exports
        Input: atkbd - support Microsoft Natural Elite Pro keyboards
        Input: i8042 - disable MUX mode on Toshiba Equium A110
        Input: i8042 - get rid of polling timer
        Input: send key up events at disconnect
        Input: constify psmouse driver
        Input: i8042 - add Amoi to the MUX blacklist
        Input: logips2pp - add sugnature 56 (Cordless MouseMan Wheel), cleanup
        Input: add driver for Touchwin serial touchscreens
        Input: add driver for Touchright serial touchscreens
        Input: add driver for Penmount serial touchscreens
        ...
      a12f66fc
    • Linus Torvalds's avatar
      Merge branch 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus · 12dce626
      Linus Torvalds authored
      * 'upstream' of git://ftp.linux-mips.org/pub/scm/upstream-linus:
        [MIPS] Remove unused galileo-boars header files
        [MIPS] Rename SERIAL_PORT_DEFNS for EV64120
        [MIPS] Add UART IRQ number for EV64120
        [MIPS] Remove excite_flash.c
        [MIPS] Update i8259 resources.
        [MIPS] Make unwind_stack() can dig into interrupted context
        [MIPS] Stacktrace build-fix and improvement
        [MIPS] QEMU: Add support for little endian mips
        [MIPS] Remove __flush_icache_page
        [MIPS] lockdep: update defconfigs
        [MIPS] lockdep: Add STACKTRACE_SUPPORT and enable LOCKDEP_SUPPORT
        [MIPS] lockdep: fix TRACE_IRQFLAGS_SUPPORT
      12dce626
    • David Howells's avatar
      [PATCH] BLOCK: Revert patch to hack around undeclared sigset_t in linux/compat.h · 3f2e05e9
      David Howells authored
      Revert Andrew Morton's patch to temporarily hack around the lack of a
      declaration of sigset_t in linux/compat.h to make the block-disablement
      patches build on IA64.  This got accidentally pushed to Linus and should
      be fixed in a different manner.
      
      Also make linux/compat.h #include asm/signal.h to gain a definition of
      sigset_t so that it can externally declare sigset_from_compat().
      
      This has been compile-tested for i386, x86_64, ia64, mips, mips64, frv, ppc and
      ppc64 and run-tested on frv.
      Signed-off-by: default avatarDavid Howells <dhowells@redhat.com>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      3f2e05e9
    • Cedric Le Goater's avatar
      [PATCH] replace cad_pid by a struct pid · 9ec52099
      Cedric Le Goater authored
      There are a few places in the kernel where the init task is signaled.  The
      ctrl+alt+del sequence is one them.  It kills a task, usually init, using a
      cached pid (cad_pid).
      
      This patch replaces the pid_t by a struct pid to avoid pid wrap around
      problem.  The struct pid is initialized at boot time in init() and can be
      modified through systctl with
      
      	/proc/sys/kernel/cad_pid
      
      [ I haven't found any distro using it ? ]
      
      It also introduces a small helper routine kill_cad_pid() which is used
      where it seemed ok to use cad_pid instead of pid 1.
      
      [akpm@osdl.org: cleanups, build fix]
      Signed-off-by: default avatarCedric Le Goater <clg@fr.ibm.com>
      Cc: Eric W. Biederman <ebiederm@xmission.com>
      Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
      Cc: Paul Mackerras <paulus@samba.org>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      9ec52099
    • Oleg Nesterov's avatar
      [PATCH] introduce get_task_pid() to fix unsafe get_pid() · 1a657f78
      Oleg Nesterov authored
      proc_pid_make_inode:
      
      	ei->pid = get_pid(task_pid(task));
      
      I think this is not safe.  get_pid() can be preempted after checking "pid
      != NULL".  Then the task exits, does detach_pid(), and RCU frees the pid.
      Signed-off-by: default avatarOleg Nesterov <oleg@tv-sign.ru>
      Cc: "Eric W. Biederman" <ebiederm@xmission.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      1a657f78
    • Eric W. Biederman's avatar
      [PATCH] proc: comment what proc_fill_cache does · 1c0d04c9
      Eric W. Biederman authored
      Signed-off-by: default avatarEric W. Biederman <ebiederm@xmission.com>
      Cc: Oleg Nesterov <oleg@tv-sign.ru>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      1c0d04c9
    • Eric W. Biederman's avatar
      [PATCH] proc: remove the useless SMP-safe comments from /proc · 5e61feaf
      Eric W. Biederman authored
      Signed-off-by: default avatarEric W. Biederman <ebiederm@xmission.com>
      Cc: Oleg Nesterov <oleg@tv-sign.ru>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      5e61feaf
    • Eric W. Biederman's avatar
      [PATCH] proc: remove trailing blank entry from pid_entry arrays · 7bcd6b0e
      Eric W. Biederman authored
      It was pointed out that since I am taking ARRAY_SIZE anyway the trailing empty
      entry is silly and just wastes space.
      Signed-off-by: default avatarEric W. Biederman <ebiederm@xmission.com>
      Cc: Oleg Nesterov <oleg@tv-sign.ru>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      7bcd6b0e
    • Eric W. Biederman's avatar
      [PATCH] proc: properly compute TGID_OFFSET · 8e95bd93
      Eric W. Biederman authored
      The value doesn't change but this ensures I will have the proper value when
      other files are added to proc_base_stuff.
      Signed-off-by: default avatarEric W. Biederman <ebiederm@xmission.com>
      Cc: Oleg Nesterov <oleg@tv-sign.ru>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      8e95bd93
    • Oleg Nesterov's avatar
      [PATCH] proc: drop tasklist lock in task_state() · b0fa9db6
      Oleg Nesterov authored
      task_state() needs tasklist_lock to protect ->parent/->real_parent.  However
      task->parent points to nowhere only when the actions below happen in order
      
      	1) release_task(task)
      	2) release_task(task->parent)
      	3) a grace period passed
      
      But 3) implies that the memory ops from 1) should be finished, so pid_alive()
      can't be true in such a case.
      
      Otherwise, we don't care if ->parent/->real_parent changes under us.
      Signed-off-by: default avatarOleg Nesterov <oleg@tv-sign.ru>
      Cc: "Eric W. Biederman" <ebiederm@xmission.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      b0fa9db6
    • Oleg Nesterov's avatar
      [PATCH] proc: convert do_task_stat() to use lock_task_sighand() · a593d6ed
      Oleg Nesterov authored
      Drop tasklist_lock. ->siglock protects almost all interesting data
      (including sub-threads traversal) except:
      
      	->signal->tty
      		protected by tty_mutex
      
      	->real_parent
      		the task can't be unhashed while we are holding
      		->siglock, so ->real_parent can change from under us
      		but we can safely dereference it under rcu_read_lock()
      
      	->pgrp/->session
      		we can get inconsistent numbers if the task does
      		sys_setsid/daemonize at the same time. I hope this
      		is acceptable.
      Signed-off-by: default avatarOleg Nesterov <oleg@tv-sign.ru>
      Cc: "Eric W. Biederman" <ebiederm@xmission.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      a593d6ed
    • Oleg Nesterov's avatar
      [PATCH] proc: convert task_sig() to use lock_task_sighand() · 5e6b3f42
      Oleg Nesterov authored
      lock_task_sighand() can take ->siglock without holding tasklist_lock.
      Signed-off-by: default avatarOleg Nesterov <oleg@tv-sign.ru>
      Cc: "Eric W. Biederman" <ebiederm@xmission.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      5e6b3f42
    • Eric W. Biederman's avatar
    • Eric W. Biederman's avatar
      [PATCH] proc: Merge proc_tid_attr and proc_tgid_attr · 72d9dcfc
      Eric W. Biederman authored
      The implementation is exactly the same and there is currently nothing to
      distinguish proc_tid_attr, and proc_tgid_attr.  So it is pointless to have two
      separate implementations.
      Signed-off-by: default avatarEric W. Biederman <ebiederm@xmission.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      72d9dcfc
    • Eric W. Biederman's avatar
      [PATCH] proc: Remove the hard coded inode numbers · 61a28784
      Eric W. Biederman authored
      The hard coded inode numbers in proc currently limit its maintainability,
      its flexibility, and what can be done with the rest of system.  /proc limits
      pid-max to 32768 on 32 bit systems it limits fd-max to 32768 on all systems,
      and placing the pid in the inode number really gets in the way of implementing
      subdirectories of per process information.
      
      Ever since people started adding to the middle of the file type enumeration we
      haven't been maintaing the historical inode numbers, all we have really
      succeeded in doing is keeping the pid in the proc inode number.  The pid is
      already available in the directory name so no information is lost removing it
      from the inode number.
      
      So if something in user space cares if we remove the inode number from the
      /proc inode it is almost certainly broken.
      Signed-off-by: default avatarEric W. Biederman <ebiederm@xmission.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      61a28784
    • Eric W. Biederman's avatar
      [PATCH] proc: Factor out an instantiate method from every lookup method · 444ceed8
      Eric W. Biederman authored
      To remove the hard coded proc inode numbers it is necessary to be able to
      create the proc inodes during readdir.  The instantiate methods are the subset
      of lookup that is needed to accomplish that.
      
      This first step just splits the lookup methods into 2 functions.
      Signed-off-by: default avatarEric W. Biederman <ebiederm@xmission.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      444ceed8
    • Eric W. Biederman's avatar
      [PATCH] proc: Make the generation of the self symlink table driven · 801199ce
      Eric W. Biederman authored
      This patch generalizes the concept of files in /proc that are related to
      processes but live in the root directory of /proc
      
      Ideally this would reuse infrastructure from the rest of the process specific
      parts of proc but unfortunately security_task_to_inode must not be called on
      files that are not strictly per process.  security_task_to_inode really needs
      to be reexamined as the security label can change in important places that we
      are not currently catching, but I'm not certain that simplifies this problem.
      
      By at least matching the structure of the rest of proc we get more idiom reuse
      and it becomes easier to spot problems in the way things are put together.
      
      Later things like /proc/mounts are likely to be moved into proc_base as well.
      If union mounts are ever supported we may be able to make /proc a union mount,
      and properly split it into 2 filesystems.
      Signed-off-by: default avatarEric W. Biederman <ebiederm@xmission.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      801199ce
    • Haavard Skinnemoen's avatar
      [PATCH] AVR32: Implement kernel_execve · c5f2420a
      Haavard Skinnemoen authored
      Move execve() into arch/avr32/kernel/sys_avr32.c, rename it to
      kernel_execve() and return the syscall return value directly without
      setting errno.
      
      This also gets rid of the __KERNEL_SYSCALLS__ stuff from unistd.h and
      expands #ifdef __KERNEL__ to cover everything in unistd.h except the
      __NR_foo definitions.
      Signed-off-by: default avatarHaavard Skinnemoen <hskinnemoen@atmel.com>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      c5f2420a
    • Arnd Bergmann's avatar
      [PATCH] remove remaining errno and __KERNEL_SYSCALLS__ references · 135ab6ec
      Arnd Bergmann authored
      The last in-kernel user of errno is gone, so we should remove the definition
      and everything referring to it.  This also removes the now-unused lib/execve.c
      file that was introduced earlier.
      
      Also remove every trace of __KERNEL_SYSCALLS__ that still remained in the
      kernel.
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Cc: Andi Kleen <ak@muc.de>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Richard Henderson <rth@twiddle.net>
      Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
      Cc: Russell King <rmk@arm.linux.org.uk>
      Cc: Ian Molton <spyro@f2s.com>
      Cc: Mikael Starvik <starvik@axis.com>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
      Cc: Hirokazu Takata <takata.hirokazu@renesas.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Kyle McMartin <kyle@mcmartin.ca>
      Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
      Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
      Cc: Paul Mundt <lethal@linux-sh.org>
      Cc: Kazumoto Kojima <kkojima@rr.iij4u.or.jp>
      Cc: Richard Curnow <rc@rc0.org.uk>
      Cc: William Lee Irwin III <wli@holomorphy.com>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Jeff Dike <jdike@addtoit.com>
      Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
      Cc: Miles Bader <uclinux-v850@lsi.nec.co.jp>
      Cc: Chris Zankel <chris@zankel.net>
      Cc: "Luck, Tony" <tony.luck@intel.com>
      Cc: Geert Uytterhoeven <geert@linux-m68k.org>
      Cc: Roman Zippel <zippel@linux-m68k.org>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      135ab6ec
    • Arnd Bergmann's avatar
      [PATCH] sh64: remove the use of kernel syscalls · 821278a7
      Arnd Bergmann authored
      sh64 is using system call macros to call some functions from the kernel.
      
      The old debug code can simply be removed, since we don't really have that much
      of a need for it anymore, it was mostly something that was handy during the
      initial bringup.  This also brings us closer to something that looks like
      readable code again..
      
      I also added a sane kernel_thread() implementation that gets away from this,
      so that should take care of sh64 at least.
      Signed-off-by: default avatarPaul Mundt <lethal@linux-sh.org>
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Cc: Andi Kleen <ak@muc.de>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Richard Henderson <rth@twiddle.net>
      Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
      Cc: Russell King <rmk@arm.linux.org.uk>
      Cc: Ian Molton <spyro@f2s.com>
      Cc: Mikael Starvik <starvik@axis.com>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
      Cc: Hirokazu Takata <takata.hirokazu@renesas.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Kyle McMartin <kyle@mcmartin.ca>
      Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
      Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
      Cc: Kazumoto Kojima <kkojima@rr.iij4u.or.jp>
      Cc: Richard Curnow <rc@rc0.org.uk>
      Cc: William Lee Irwin III <wli@holomorphy.com>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Jeff Dike <jdike@addtoit.com>
      Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
      Cc: Miles Bader <uclinux-v850@lsi.nec.co.jp>
      Cc: Chris Zankel <chris@zankel.net>
      Cc: "Luck, Tony" <tony.luck@intel.com>
      Cc: Geert Uytterhoeven <geert@linux-m68k.org>
      Cc: Roman Zippel <zippel@linux-m68k.org>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      821278a7
    • Arnd Bergmann's avatar
      [PATCH] Remove the use of _syscallX macros in UML · 5f4c6bc1
      Arnd Bergmann authored
      User mode linux uses _syscallX() to call into the host kernel.  The
      recommended way to do this is to use the syscall() function from libc.
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Cc: Andi Kleen <ak@muc.de>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Richard Henderson <rth@twiddle.net>
      Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
      Cc: Russell King <rmk@arm.linux.org.uk>
      Cc: Ian Molton <spyro@f2s.com>
      Cc: Mikael Starvik <starvik@axis.com>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
      Cc: Hirokazu Takata <takata.hirokazu@renesas.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Kyle McMartin <kyle@mcmartin.ca>
      Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
      Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
      Cc: Paul Mundt <lethal@linux-sh.org>
      Cc: Kazumoto Kojima <kkojima@rr.iij4u.or.jp>
      Cc: Richard Curnow <rc@rc0.org.uk>
      Cc: William Lee Irwin III <wli@holomorphy.com>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Jeff Dike <jdike@addtoit.com>
      Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
      Cc: Miles Bader <uclinux-v850@lsi.nec.co.jp>
      Cc: Chris Zankel <chris@zankel.net>
      Cc: "Luck, Tony" <tony.luck@intel.com>
      Cc: Geert Uytterhoeven <geert@linux-m68k.org>
      Cc: Roman Zippel <zippel@linux-m68k.org>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      5f4c6bc1
    • Arnd Bergmann's avatar
      [PATCH] provide kernel_execve on all architectures · fe74290d
      Arnd Bergmann authored
      This adds the new kernel_execve function on all architectures that were using
      _syscall3() to implement execve.
      
      The implementation uses code from the _syscall3 macros provided in the
      unistd.h header file.  I don't have cross-compilers for any of these
      architectures, so the patch is untested with the exception of i386.
      
      Most architectures can probably implement this in a nicer way in assembly or
      by combining it with the sys_execve implementation itself, but this should do
      it for now.
      
      [bunk@stusta.de: m68knommu build fix]
      [markh@osdl.org: build fix]
      [bero@arklinux.org: build fix]
      [ralf@linux-mips.org: mips fix]
      [schwidefsky@de.ibm.com: s390 fix]
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Cc: Andi Kleen <ak@muc.de>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Richard Henderson <rth@twiddle.net>
      Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
      Cc: Russell King <rmk@arm.linux.org.uk>
      Cc: Ian Molton <spyro@f2s.com>
      Cc: Mikael Starvik <starvik@axis.com>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
      Cc: Hirokazu Takata <takata.hirokazu@renesas.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Kyle McMartin <kyle@mcmartin.ca>
      Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
      Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
      Cc: Paul Mundt <lethal@linux-sh.org>
      Cc: Kazumoto Kojima <kkojima@rr.iij4u.or.jp>
      Cc: Richard Curnow <rc@rc0.org.uk>
      Cc: William Lee Irwin III <wli@holomorphy.com>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Jeff Dike <jdike@addtoit.com>
      Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
      Cc: Miles Bader <uclinux-v850@lsi.nec.co.jp>
      Cc: Chris Zankel <chris@zankel.net>
      Cc: "Luck, Tony" <tony.luck@intel.com>
      Cc: Geert Uytterhoeven <geert@linux-m68k.org>
      Cc: Roman Zippel <zippel@linux-m68k.org>
      Signed-off-by: default avatarRalf Baechle <ralf@linux-mips.org>
      Signed-off-by: default avatarBernhard Rosenkraenzer <bero@arklinux.org>
      Signed-off-by: default avatarMark Haverkamp <markh@osdl.org>
      Signed-off-by: default avatarAdrian Bunk <bunk@stusta.de>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      fe74290d
    • Arnd Bergmann's avatar
      [PATCH] rename the provided execve functions to kernel_execve · 3db03b4a
      Arnd Bergmann authored
      Some architectures provide an execve function that does not set errno, but
      instead returns the result code directly.  Rename these to kernel_execve to
      get the right semantics there.  Moreover, there is no reasone for any of these
      architectures to still provide __KERNEL_SYSCALLS__ or _syscallN macros, so
      remove these right away.
      
      [akpm@osdl.org: build fix]
      [bunk@stusta.de: build fix]
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Cc: Andi Kleen <ak@muc.de>
      Acked-by: default avatarPaul Mackerras <paulus@samba.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Richard Henderson <rth@twiddle.net>
      Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
      Cc: Russell King <rmk@arm.linux.org.uk>
      Cc: Ian Molton <spyro@f2s.com>
      Cc: Mikael Starvik <starvik@axis.com>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
      Cc: Hirokazu Takata <takata.hirokazu@renesas.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Kyle McMartin <kyle@mcmartin.ca>
      Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
      Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
      Cc: Paul Mundt <lethal@linux-sh.org>
      Cc: Kazumoto Kojima <kkojima@rr.iij4u.or.jp>
      Cc: Richard Curnow <rc@rc0.org.uk>
      Cc: William Lee Irwin III <wli@holomorphy.com>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Jeff Dike <jdike@addtoit.com>
      Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
      Cc: Miles Bader <uclinux-v850@lsi.nec.co.jp>
      Cc: Chris Zankel <chris@zankel.net>
      Cc: "Luck, Tony" <tony.luck@intel.com>
      Cc: Geert Uytterhoeven <geert@linux-m68k.org>
      Cc: Roman Zippel <zippel@linux-m68k.org>
      Signed-off-by: default avatarAdrian Bunk <bunk@stusta.de>
      Cc: Arnd Bergmann <arnd@arndb.de>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      3db03b4a
    • Arnd Bergmann's avatar
      [PATCH] introduce kernel_execve · 67608567
      Arnd Bergmann authored
      The use of execve() in the kernel is dubious, since it relies on the
      __KERNEL_SYSCALLS__ mechanism that stores the result in a global errno
      variable.  As a first step of getting rid of this, change all users to a
      global kernel_execve function that returns a proper error code.
      
      This function is a terrible hack, and a later patch removes it again after the
      kernel syscalls are gone.
      Signed-off-by: default avatarArnd Bergmann <arnd@arndb.de>
      Cc: Andi Kleen <ak@muc.de>
      Cc: Paul Mackerras <paulus@samba.org>
      Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org>
      Cc: Richard Henderson <rth@twiddle.net>
      Cc: Ivan Kokshaysky <ink@jurassic.park.msu.ru>
      Cc: Russell King <rmk@arm.linux.org.uk>
      Cc: Ian Molton <spyro@f2s.com>
      Cc: Mikael Starvik <starvik@axis.com>
      Cc: David Howells <dhowells@redhat.com>
      Cc: Yoshinori Sato <ysato@users.sourceforge.jp>
      Cc: Hirokazu Takata <takata.hirokazu@renesas.com>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Kyle McMartin <kyle@mcmartin.ca>
      Cc: Heiko Carstens <heiko.carstens@de.ibm.com>
      Cc: Martin Schwidefsky <schwidefsky@de.ibm.com>
      Cc: Paul Mundt <lethal@linux-sh.org>
      Cc: Kazumoto Kojima <kkojima@rr.iij4u.or.jp>
      Cc: Richard Curnow <rc@rc0.org.uk>
      Cc: William Lee Irwin III <wli@holomorphy.com>
      Cc: "David S. Miller" <davem@davemloft.net>
      Cc: Jeff Dike <jdike@addtoit.com>
      Cc: Paolo 'Blaisorblade' Giarrusso <blaisorblade@yahoo.it>
      Cc: Miles Bader <uclinux-v850@lsi.nec.co.jp>
      Cc: Chris Zankel <chris@zankel.net>
      Cc: "Luck, Tony" <tony.luck@intel.com>
      Cc: Geert Uytterhoeven <geert@linux-m68k.org>
      Cc: Roman Zippel <zippel@linux-m68k.org>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      67608567
    • Matt Helsley's avatar
      [PATCH] ipc: replace kmalloc and memset in get_undo_list with kzalloc · 2453a306
      Matt Helsley authored
      Simplify get_undo_list() by dropping the unnecessary cast, removing the
      size variable, and switching to kzalloc() instead of a kmalloc() followed
      by a memset().
      
      This cleanup was split then modified from Jes Sorenson's Task Notifiers
      patches.
      Signed-off-by: default avatarMatt Helsley <matthltc@us.ibm.com>
      Cc: Jes Sorensen <jes@sgi.com>
      Signed-off-by: default avatarAndrew Morton <akpm@osdl.org>
      Signed-off-by: default avatarLinus Torvalds <torvalds@osdl.org>
      2453a306