09 Dec, 2006

40 commits

  • Replace kmalloc+memset with kcalloc and simplify

    Signed-off-by: Yan Burman
    Cc: Neil Brown
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Yan Burman
     
  • NFS3: Calculate 'w' a bit later in nfs3svc_encode_getaclres()
    This is a small performance optimization since we can return before
    needing 'w'. It also saves a few bytes of .text :
    Before:
    text data bss dec hex filename
    1632 140 0 1772 6ec fs/nfsd/nfs3acl.o
    After:
    text data bss dec hex filename
    1624 140 0 1764 6e4 fs/nfsd/nfs3acl.o

    Signed-off-by: Jesper Juhl
    Cc: Neil Brown
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jesper Juhl
     
  • NFS2: Calculate 'w' a bit later in nfsaclsvc_encode_getaclres()
    This is a small performance optimization since we can return before
    needing 'w'. It also saves a few bytes of .text :
    Before:
    text data bss dec hex filename
    2406 212 0 2618 a3a fs/nfsd/nfs2acl.o
    After:
    text data bss dec hex filename
    2400 212 0 2612 a34 fs/nfsd/nfs2acl.o

    Signed-off-by: Jesper Juhl
    Cc: Neil Brown
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jesper Juhl
     
  • > =============================================
    > [ INFO: possible recursive locking detected ]
    > 2.6.18-1.2724.lockdepPAE #1
    > ---------------------------------------------
    > nfsd/6884 is trying to acquire lock:
    > (&inode->i_mutex){--..}, at: [] vfs_rmdir+0x73/0xf4
    >
    > but task is already holding lock:
    > (&inode->i_mutex){--..}, at: []
    > nfsd4_clear_clid_dir+0x1f/0x3d [nfsd]
    >
    > other info that might help us debug this:
    > 3 locks held by nfsd/6884:
    > #0: (hash_sem){----}, at: [] nfsd+0x181/0x2ea [nfsd]
    > #1: (client_mutex){--..}, at: []
    > nfsd4_setclientid_confirm+0x3b/0x2cf [nfsd]
    > #2: (&inode->i_mutex){--..}, at: []
    > nfsd4_clear_clid_dir+0x1f/0x3d [nfsd]
    >
    > stack backtrace:
    > [] dump_trace+0x69/0x1af
    > [] show_trace_log_lvl+0x18/0x2c
    > [] show_trace+0xf/0x11
    > [] dump_stack+0x15/0x17
    > [] __lock_acquire+0x110/0x9b6
    > [] lock_acquire+0x5c/0x7a
    > [] __mutex_lock_slowpath+0xde/0x234
    > [] vfs_rmdir+0x73/0xf4
    > [] nfsd4_clear_clid_dir+0x29/0x3d [nfsd]
    > [] nfsd4_remove_clid_dir+0xb8/0xf8 [nfsd]
    > [] nfsd4_setclientid_confirm+0x1b2/0x2cf [nfsd]
    > [] nfsd4_proc_compound+0x137a/0x166c [nfsd]
    > [] nfsd_dispatch+0xc5/0x180 [nfsd]
    > [] svc_process+0x3bd/0x631 [sunrpc]
    > [] nfsd+0x19a/0x2ea [nfsd]
    > [] kernel_thread_helper+0x7/0x10
    > DWARF2 unwinder stuck at kernel_thread_helper+0x7/0x10
    > Leftover inexact backtrace:
    > =======================

    Some nesting annotation to the nfsd4 recovery code.
    The vfs operations called will take dentry->d_inode->i_mutex.

    Signed-off-by: Peter Zijlstra
    Cc: Neil Brown
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Peter Zijlstra
     
  • * diva, sedlbauer: the 'ready' label is only used in certain configurations
    * hfc_pci:
    - cast 'arg' to proper size for testing and printing
    - print out 'void __iomem *' variables with %p,
    rather than using incorrect casts that throw warnings

    Signed-off-by: Jeff Garzik
    Acked-by: Karsten Keil
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jeff Garzik
     
  • HISAX_AMD7930 was never anywhere near to being working, and this doesn't
    seem to change in the forseeable future.

    Signed-off-by: Adrian Bunk
    Acked-by: Karsten Keil
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Adrian Bunk
     
  • Acked-by: Karsten Keil
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Burman Yan
     
  • Signed-off-by: Alexey Dobriyan
    Acked-by: Alan Cox
    Cc: Karsten Keil
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alexey Dobriyan
     
  • There's a potential problem in isdn_ppp.c::isdn_ppp_decompress().
    dev_alloc_skb() may fail and return NULL. If it does we will be passing a
    NULL skb_out to ipc->decompress() and may also end up
    dereferencing a NULL pointer at

    *proto = isdn_ppp_strip_proto(skb_out);

    Correct this by testing 'skb_out' against NULL early and bail out.

    Signed-off-by: Jesper Juhl
    Cc: Karsten Keil
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jesper Juhl
     
  • unregister_capi_driver() needs to be called in module cleanup.
    (It fixes data corruption by reloading t1isa driver)

    Cc: Kai Germaschewski
    Acked-by: Karsten Keil
    Signed-off-by: Akinobu Mita
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Akinobu Mita
     
  • Cleanups done to use min/max macros from kernel.h. Handcrafted MIN/MAX
    macros are changed to use macros in kernel.h

    [akpm@osdl.org: warning fix]
    Signed-off-by: Amol Lad
    Cc: Karsten Keil
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Amol Lad
     
  • fix gcc signed/unsigned warnings

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • - remove cvs rcsid and alter code that uses it.
    - allow a semicolon after use of macro to not confuse parsers (e.g. indent)
    by do {} while (0)
    - JIFFIES_DIFF is simple subtraction, subtract directly
    - returns cleanup -- do not put values in parenthesis and do not return nothing
    at the end of void functions
    - comments are /* */ in C (not //)

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • make the code indented by tabs.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Save 3 indent levels in interrupt routine by moving the code to a separate
    function. This needs to be done to allow Lindent do its work, since only 4
    columns are used for indenting now and hence Lindent makes a big mess in the
    code, when moves it 4*5 columns to the right.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Do not set expires by hand, use kernel helper, which also calls add_timer.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • register tty device dynamically according to the count of board ports.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Reorganizate module init and exit and implement logic, when something fails in
    these functions. The former is needed for proper handling dynamic
    tty_register_device.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Let's have these function at the end of the driver and expand stli_init
    directly into module_init fucntion, since there is nothing other to have
    there.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Enable ISA cards before pci_register_driver and then, enable each PCI card in
    probe function.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Check more retvals and react somehow.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Only ISA cards should be freed in module exit. Pci probed are freed in
    pci_remove. Define a flag, where we store this info a what to check against.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Kill possible race when getting brdnr by locking.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Disable compiling eisa stuff if STLI_EISAPROBE == 0.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • - wipe gcc -W warnings by int -> uint conversion
    - move 2 global variables into their local place

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Use only struct instead of defining a new type .

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • - remove unneeded license text
    - remove functions, that are implemented in kernel -- call them (strtoul,
    min, tolower)
    - do not cast NULL
    - there is no static table, throw away code, which takes care of it --
    find module param cards in that place instead.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Use probing for pci devices. Change some __inits to __devinits to use these
    functions in probe function. Create stli_cleanup_ports and move there cleanup
    code from module_exit() code to not have duplicite cleanup code.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Use dynamic tty device registering depending on board's port count. (i ->
    retval change is relevant, since gcc complains about signedness of i)

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • - fix `gcc -W' un/signed warnings by converting some ints -> uints.
    - move 3 global variables into functions, where are they used.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Remove useless parenthesis and brackets.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Since assigning of stl_brds[brdnr] is racy, add locking to this critical
    section.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Release everything what was allocated and check return value of isa probing.
    Release only ISA boards in module exit, since pci have their own
    pci-probing-remove.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Delete macros and functions, that are implemented in kernel yet (strtoul, min,
    tolower). Expand one function body in place, where it is called from.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Some functions are now called from pci probing functiuon which is __devinit,
    not __init, correct this to not free functions after init if hotplug enabled.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • This driver expect everything to work. Implement fail paths logic to release
    regions, irq hangler, memory... if something is in bad state.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Too many information is printed out (they may be easily obtained through
    sysfs), wipe them out in probe function. Convert rest of them to dev_
    variants.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Convert stallion driver to pci probing instead of pci_dev_get iteration.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Check regions if they are free before we touch them. Release them in
    failpaths.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby
     
  • Use pci_ friends for memory remapping of pci devices.

    Signed-off-by: Jiri Slaby
    Cc: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Jiri Slaby