09 Feb, 2008

36 commits

  • We bought cheap notebooks to control our custom data acquisition system, which
    requires EPP mode (read/write, data/addr). The bios does not offer EPP mode,
    and indeed hardware EPP mode appears not to work, although the parport driver
    tries to use it. EPPSWE mode does work for data r/w and addr write, but addr
    read requires this patch.

    (stephan)rshgse3: lspci

    00:00.0 Host bridge: Intel Corporation Mobile 945GM/PM/GMS/940GML and 945GT Express Memory Controller Hub (rev 03)
    00:02.0 VGA compatible controller: Intel Corporation Mobile 945GM/GMS/940GML Express Integrated Graphics Controller (rev 03)
    00:02.1 Display controller: Intel Corporation Mobile 945GM/GMS/940GML Express Integrated Graphics Controller (rev 03)
    00:1b.0 Audio device: Intel Corporation 82801G (ICH7 Family) High Definition Audio Controller (rev 02)
    00:1c.0 PCI bridge: Intel Corporation 82801G (ICH7 Family) PCI Express Port 1 (rev 02)
    00:1c.1 PCI bridge: Intel Corporation 82801G (ICH7 Family) PCI Express Port 2 (rev 02)
    00:1c.2 PCI bridge: Intel Corporation 82801G (ICH7 Family) PCI Express Port 3 (rev 02)
    00:1d.0 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI #1 (rev 02)
    00:1d.1 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI #2 (rev 02)
    00:1d.2 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI #3 (rev 02)
    00:1d.3 USB Controller: Intel Corporation 82801G (ICH7 Family) USB UHCI #4 (rev 02)
    00:1d.7 USB Controller: Intel Corporation 82801G (ICH7 Family) USB2 EHCI Controller (rev 02)
    00:1e.0 PCI bridge: Intel Corporation 82801 Mobile PCI Bridge (rev e2)
    00:1f.0 ISA bridge: Intel Corporation 82801GBM (ICH7-M) LPC Interface Bridge (rev 02)
    00:1f.1 IDE interface: Intel Corporation 82801G (ICH7 Family) IDE Controller (rev 02)
    00:1f.2 SATA controller: Intel Corporation 82801GBM/GHM (ICH7 Family) Serial ATA Storage Controller AHCI (rev 02)
    00:1f.3 SMBus: Intel Corporation 82801G (ICH7 Family) SMBus Controller (rev 02)
    02:00.0 Ethernet controller: Marvell Technology Group Ltd. 88E8055 PCI-E Gigabit Ethernet Controller (rev 12)
    05:00.0 Network controller: Intel Corporation PRO/Wireless 3945ABG Network Connection (rev 02)
    08:03.0 CardBus bridge: Ricoh Co Ltd RL5c476 II (rev b3)
    08:03.1 FireWire (IEEE 1394): Ricoh Co Ltd R5C552 IEEE 1394 Controller (rev 08)
    08:03.2 Generic system peripheral [0805]: Ricoh Co Ltd R5C822 SD/SDIO/MMC/MS/MSPro Host Adapter (rev 17)

    (stephan)rshgse3: grep . /proc/sys/dev/parport/parport0/*

    /proc/sys/dev/parport/parport0/base-addr:888 1912
    /proc/sys/dev/parport/parport0/dma:-1
    /proc/sys/dev/parport/parport0/irq:7
    /proc/sys/dev/parport/parport0/modes:PCSPP,TRISTATE,EPP
    /proc/sys/dev/parport/parport0/spintime:500

    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Stephan Boettcher
     
  • Using "attr" twice is not OK, because it effectively prohibits such
    container_of() on variables not named "attr".

    Signed-off-by: Alexey Dobriyan
    Acked-by: Rusty Russell
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alexey Dobriyan
     
  • I guess aoedev_init() can go away now.

    Cc: Greg KH
    Cc: "Ed L. Cashin"
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Andrew Morton
     
  • Update the year in the copyright notices.

    Signed-off-by: Ed L. Cashin
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ed L. Cashin
     
  • Andrew Morton pointed out that the "too many targets" message in patch 2 could
    be printed for failing GFP_ATOMIC allocations. This patch makes the messages
    more specific.

    Signed-off-by: Ed L. Cashin
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ed L. Cashin
     
  • The aoedev aoeminor member doesn't need a long format.

    Signed-off-by: Ed L. Cashin
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ed L. Cashin
     
  • An AoE target provides an estimate of the number of outstanding commands that
    the AoE initiator can send before getting a response. The aoe_maxout
    parameter provides a way to set an even lower limit. It will not allow a user
    to use more outstanding commands than the target permits. If a user discovers
    a problem with a large setting, this parameter provides a way for us to work
    with them to debug the problem. We expect to improve the dynamic window
    sizing algorithm and drop this parameter. For the time being, it is a
    debugging aid.

    Signed-off-by: Ed L. Cashin
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ed L. Cashin
     
  • An aoe driver user who had about 70 AoE targets found that he was hitting a
    BUG in sysfs_create_file because the aoe driver was trying to tell the kernel
    about an AoE device more than once. Each AoE device was reachable by several
    local network interfaces, and multiple ATA device indentify responses were
    returning from that single device.

    This patch eliminates a race condition so that aoe always informs the block
    layer of a new AoE device once in the presence of multiple incoming ATA device
    identify responses.

    Signed-off-by: Ed L. Cashin
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ed L. Cashin
     
  • What this Patch Does

    Even before this recent series of 12 patches to 2.6.22-rc4, the aoe
    driver was reusing a small set of skbs that were allocated once and
    were only used for outbound AoE commands.

    The network layer cannot be allowed to put_page on the data that is
    still associated with a bio we haven't returned to the block layer,
    so the aoe driver (even before the patch under discussion) is still
    the owner of skbs that have been handed to the network layer for
    transmission. We need to keep track of these skbs so that we can
    free them, but by tracking them, we can also easily re-use them.

    The new patch was a response to the behavior of certain network
    drivers. We cannot reuse an skb that the network driver still has
    in its transmit ring. Network drivers can defer transmit ring
    cleanup and then use the state in the skb to determine how many data
    segments to clean up in its transmit ring. The tg3 driver is one
    driver that behaves in this way.

    When the network driver defers cleanup of its transmit ring, the aoe
    driver can find itself in a situation where it would like to send an
    AoE command, and the AoE target is ready for more work, but the
    network driver still has all of the pre-allocated skbs. In that
    case, the new patch just calls alloc_skb, as you'd expect.

    We don't want to get carried away, though. We try not to do
    excessive allocation in the write path, so we cap the number of skbs
    we dynamically allocate.

    Probably calling it a "dynamic pool" is misleading. We were already
    trying to use a small fixed-size set of pre-allocated skbs before
    this patch, and this patch just provides a little headroom (with a
    ceiling, though) to accomodate network drivers that hang onto skbs,
    by allocating when needed. The d->skbpool_hd list of allocated skbs
    is necessary so that we can free them later.

    We didn't notice the need for this headroom until AoE targets got
    fast enough.

    Alternatives

    If the network layer never did a put_page on the pages in the bio's
    we get from the block layer, then it would be possible for us to
    hand skbs to the network layer and forget about them, allowing the
    network layer to free skbs itself (and thereby calling our own
    skb->destructor callback function if we needed that). In that case
    we could get rid of the pre-allocated skbs and also the
    d->skbpool_hd, instead just calling alloc_skb every time we wanted
    to transmit a packet. The slab allocator would effectively maintain
    the list of skbs.

    Besides a loss of CPU cache locality, the main concern with that
    approach the danger that it would increase the likelihood of
    deadlock when VM is trying to free pages by writing dirty data from
    the page cache through the aoe driver out to persistent storage on
    an AoE device. Right now we have a situation where we have
    pre-allocation that corresponds to how much we use, which seems
    ideal.

    Of course, there's still the separate issue of receiving the packets
    that tell us that a write has successfully completed on the AoE
    target. When memory is low and VM is using AoE to flush dirty data
    to free up pages, it would be perfect if there were a way for us to
    register a fast callback that could recognize write command
    completion responses. But I don't think the current problems with
    the receive side of the situation are a justification for
    exacerbating the problem on the transmit side.

    Signed-off-by: Ed L. Cashin
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ed L. Cashin
     
  • When an AoE device is detected, the kernel is informed, and a new block device
    is created. If the device is unused, the block device corresponding to remote
    device that is no longer available may be removed from the system by telling
    the aoe driver to "flush" its list of devices.

    Without this patch, software like GPFS and LVM may attempt to read from AoE
    devices that were discovered earlier but are no longer present, blocking until
    the I/O attempt times out.

    Signed-off-by: Ed L. Cashin
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ed L. Cashin
     
  • Adam Richter suggested eliminating this goto.

    Signed-off-by: Ed L. Cashin
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ed L. Cashin
     
  • By returning unsigned long long, mac_addr does not generate compiler warnings
    on 64-bit architectures.

    Signed-off-by: Ed L. Cashin
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ed L. Cashin
     
  • A remote AoE device is something can process ATA commands and is identified by
    an AoE shelf number and an AoE slot number. Such a device might have more
    than one network interface, and it might be reachable by more than one local
    network interface. This patch tracks the available network paths available to
    each AoE device, allowing them to be used more efficiently.

    Andrew Morton asked about the call to msleep_interruptible in the revalidate
    function. Yes, if a signal is pending, then msleep_interruptible will not
    return 0. That means we will not loop but will call aoenet_xmit with a NULL
    skb, which is a noop. If the system is too low on memory or the aoe driver is
    too low on frames, then the user can hit control-C to interrupt the attempt to
    do a revalidate. I have added a comment to the code summarizing that.

    Andrew Morton asked whether the allocation performed inside addtgt could use a
    more relaxed allocation like GFP_KERNEL, but addtgt is called when the aoedev
    lock has been locked with spin_lock_irqsave. It would be nice to allocate the
    memory under fewer restrictions, but targets are only added when the device is
    being discovered, and if the target can't be added right now, we can try again
    in a minute when then next AoE config query broadcast goes out.

    Andrew Morton pointed out that the "too many targets" message could be printed
    for failing GFP_ATOMIC allocations. The last patch in this series makes the
    messages more specific.

    Signed-off-by: Ed L. Cashin
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ed L. Cashin
     
  • Signed-off-by: Ed L. Cashin
    Cc: Greg KH
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Ed L. Cashin
     
  • Support direct_access XIP method with brd.

    Signed-off-by: Nick Piggin
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Nick Piggin
     
  • This is a rewrite of the ramdisk block device driver.

    The old one is really difficult because it effectively implements a block
    device which serves data out of its own buffer cache. It relies on the dirty
    bit being set, to pin its backing store in cache, however there are non
    trivial paths which can clear the dirty bit (eg. try_to_free_buffers()),
    which had recently lead to data corruption. And in general it is completely
    wrong for a block device driver to do this.

    The new one is more like a regular block device driver. It has no idea about
    vm/vfs stuff. It's backing store is similar to the buffer cache (a simple
    radix-tree of pages), but it doesn't know anything about page cache (the pages
    in the radix tree are not pagecache pages).

    There is one slight downside -- direct block device access and filesystem
    metadata access goes through an extra copy and gets stored in RAM twice.
    However, this downside is only slight, because the real buffercache of the
    device is now reclaimable (because we're not playing crazy games with it), so
    under memory intensive situations, footprint should effectively be the same --
    maybe even a slight advantage to the new driver because it can also reclaim
    buffer heads.

    The fact that it now goes through all the regular vm/fs paths makes it
    much more useful for testing, too.

    text data bss dec hex filename
    2837 849 384 4070 fe6 drivers/block/rd.o
    3528 371 12 3911 f47 drivers/block/brd.o

    Text is larger, but data and bss are smaller, making total size smaller.

    A few other nice things about it:
    - Similar structure and layout to the new loop device handlinag.
    - Dynamic ramdisk creation.
    - Runtime flexible buffer head size (because it is no longer part of the
    ramdisk code).
    - Boot / load time flexible ramdisk size, which could easily be extended
    to a per-ramdisk runtime changeable size (eg. with an ioctl).
    - Can use highmem for the backing store.

    [akpm@linux-foundation.org: fix build]
    [byron.bbradley@gmail.com: make rd_size non-static]
    Signed-off-by: Nick Piggin
    Signed-off-by: Byron Bradley
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Nick Piggin
     
  • Add architecture support for the MN10300/AM33 CPUs produced by MEI to the
    kernel.

    This patch also adds board support for the ASB2303 with the ASB2308 daughter
    board, and the ASB2305. The only processor supported is the MN103E010, which
    is an AM33v2 core plus on-chip devices.

    [akpm@linux-foundation.org: nuke cvs control strings]
    Signed-off-by: Masakazu Urade
    Signed-off-by: Koichi Yasutake
    Signed-off-by: David Howells
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Howells
     
  • net2280 can't have a function called show_registers() because this can produce
    a namespace clash with an arch function of the same name.

    All this driver's functions and variables should really be prefixed with
    "net2280_" to avoid such a problem in future.

    Signed-off-by: David Howells
    Cc: Greg KH
    Cc: David Brownell
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Howells
     
  • Remove now unnecessary inclusions of {asm,linux}/a.out.h.

    [akpm@linux-foundation.org: fix alpha build]
    Signed-off-by: David Howells
    Cc:
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    David Howells
     
  • Signed-off-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alan Cox
     
  • Signed-off-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alan Cox
     
  • Signed-off-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alan Cox
     
  • Signed-off-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alan Cox
     
  • Signed-off-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alan Cox
     
  • Signed-off-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alan Cox
     
  • Signed-off-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alan Cox
     
  • Signed-off-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alan Cox
     
  • Signed-off-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alan Cox
     
  • Signed-off-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alan Cox
     
  • Signed-off-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alan Cox
     
  • Signed-off-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alan Cox
     
  • Also removes a cflag comparison that caused some mode changes to get wrongly
    ignored

    Signed-off-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Alan Cox
     
  • Signed-off-by: Alan Cox
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

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

    Alan Cox
     
  • Fix an off by one bug in the fault reason string reporting function, and
    clean up some of the code around this buglet.

    [akpm@linux-foundation.org: cleanup]
    Signed-off-by: mark gross
    Cc: Ingo Molnar
    Cc: Thomas Gleixner
    Cc: Andi Kleen
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    mark gross
     
  • Add support for protected memory enable bits by clearing them if they are
    set at startup time. Some future boot loaders or firmware could have this
    bit set after it loads the kernel, and it needs to be cleared if DMA's are
    going to happen effectively.

    Signed-off-by: mark gross
    Acked-by: Muli Ben-Yehuda
    Cc: Ingo Molnar
    Cc: Thomas Gleixner
    Cc: Andi Kleen
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    mark gross
     

08 Feb, 2008

4 commits

  • * git://git.kernel.org/pub/scm/linux/kernel/git/agk/linux-2.6-dm: (44 commits)
    dm raid1: report fault status
    dm raid1: handle read failures
    dm raid1: fix EIO after log failure
    dm raid1: handle recovery failures
    dm raid1: handle write failures
    dm snapshot: combine consecutive exceptions in memory
    dm: stripe enhanced status return
    dm: stripe trigger event on failure
    dm log: auto load modules
    dm: move deferred bio flushing to workqueue
    dm crypt: use async crypto
    dm crypt: prepare async callback fn
    dm crypt: add completion for async
    dm crypt: add async request mempool
    dm crypt: extract scatterlist processing
    dm crypt: tidy io ref counting
    dm crypt: introduce crypt_write_io_loop
    dm crypt: abstract crypt_write_done
    dm crypt: store sector mapping in dm_crypt_io
    dm crypt: move queue functions
    ...

    Linus Torvalds
     
  • * 'release' of git://lm-sensors.org/kernel/mhoffman/hwmon-2.6: (59 commits)
    hwmon: (lm80) Add individual alarm files
    hwmon: (lm80) De-macro the sysfs callbacks
    hwmon: (lm80) Various cleanups
    hwmon: (w83627hf) Refactor beep enable handling
    hwmon: (w83627hf) Add individual alarm and beep files
    hwmon: (w83627hf) Enable VBAT monitoring
    hwmon: (w83627ehf) The W83627DHG has 8 VID pins
    hwmon: (asb100) Add individual alarm files
    hwmon: (asb100) De-macro the sysfs callbacks
    hwmon: (asb100) Various cleanups
    hwmon: VRM is not written to registers
    hwmon: (dme1737) fix Super-IO device ID override
    hwmon: (dme1737) fix divide-by-0
    hwmon: (abituguru3) Add AUX4 fan input for Abit IP35 Pro
    hwmon: Add support for Texas Instruments/Burr-Brown ADS7828
    hwmon: (adm9240) Add individual alarm files
    hwmon: (lm77) Add individual alarm files
    hwmon: Discard useless I2C driver IDs
    hwmon: (lm85) Make the pwmN_enable files writable
    hwmon: (lm85) Return standard values in pwmN_enable
    ...

    Linus Torvalds
     
  • Signed-off-by: Nick Piggin
    Cc: Douglas Gilbert
    Cc: James Bottomley
    Signed-off-by: Andrew Morton
    Signed-off-by: Linus Torvalds

    Nick Piggin
     
  • This patch adds extra information to the mirror status output, so that
    it can be determined which device(s) have failed. For each mirror device,
    a character is printed indicating the most severe error encountered. The
    characters are:
    * A => Alive - No failures
    * D => Dead - A write failure occurred leaving mirror out-of-sync
    * S => Sync - A sychronization failure occurred, mirror out-of-sync
    * R => Read - A read failure occurred, mirror data unaffected
    This allows userspace to properly reconfigure the mirror set.

    Signed-off-by: Jonathan Brassow
    Signed-off-by: Alasdair G Kergon

    Jonathan Brassow