08 Aug, 2010

25 commits

  • Architectures don't need to define ISA_DMA_THRESHOLD anymore.

    Signed-off-by: FUJITA Tomonori
    Acked-by: James Bottomley
    Acked-by: David Howells
    Signed-off-by: Jens Axboe

    FUJITA Tomonori
     
  • block uses ISA_DMA_THRESHOLD for BLK_BOUNCE_ISA. Only SCSI uses
    ISA_DMA_THRESHOLD for ancient drivers with non-zero
    unchecked_isa_dma. Nowadays drivers (and subsystems) use dma_mask
    properly instead of ISA_DMA_THRESHOLD.

    Documentation/scsi/scsi_mid_low_api.txt says:

    unchecked_isa_dma - 1=>only use bottom 16 MB of ram (ISA DMA addressing
    restriction), 0=>can use full 32 bit (or better) DMA
    address space

    So block simply uses DMA_BIT_MASK(24) for BLK_BOUNCE_ISA for SCSI.

    Signed-off-by: FUJITA Tomonori
    Acked-by: James Bottomley
    Signed-off-by: Jens Axboe

    FUJITA Tomonori
     
  • We can safely remove ISA_DMA_THRESHOLD usage in aha1542. aha1542 uses
    ISA_DMA_THRESHOLD to see if:

    - the buffers in scatter/list are below 16MB.
    - scsi_host is below 16MB.

    Both checkings were added in the ancient times but aren't necessary
    nowadays since we properly bounce the buffers and allocate scsi_host
    below 16MB with non-zero unchecked_isa_dma.

    Signed-off-by: FUJITA Tomonori
    Acked-by: James Bottomley
    Signed-off-by: Jens Axboe

    FUJITA Tomonori
     
  • A barrier request should by defintion have priority in get_request
    and let the queue be unplugged immediately as it's blocking all forward
    progress due to the queue draining.

    Most filesystems already get this implicitly by the way how submit_bh
    treats the buffer_ordered flag, and gfs2 sets it explicitly. But btrfs
    and XFS are still forgetting to set the flag, as is blkdev_issue_flush
    and some places in DM/MD.

    For XFS on metadata heavy workloads this gives a consistent speedup
    in the 2-3% range.

    Signed-off-by: Christoph Hellwig
    Signed-off-by: Jens Axboe

    Christoph Hellwig
     
  • Convert assertions to use WARN(). There are several error checks in the
    code for things that should never happen. Convert them to standard
    warnings so kerneloops.org will see them.

    Signed-off-by: Stephen Hemminger
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Stephen Hemminger
     
  • Convert wait loops to use wait_event_ macros.

    Signed-off-by: Stephen Hemminger
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Stephen Hemminger
     
  • Ioctl cmd value is unsigned, so change normalize_ioctl

    Signed-off-by: Stephen Hemminger
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Stephen Hemminger
     
  • As reported by sparse, cmos attribute is local.

    Signed-off-by: Stephen Hemminger
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Stephen Hemminger
     
  • The usage_count was being protected by a lock which was only there to
    create an atomic counter.

    Signed-off-by: Stephen Hemminger
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Stephen Hemminger
     
  • The first thing the floppy does is read block 0 to test geometry and to
    test for disk presence. If disk is not present this causes a console
    warning message about failed I/O. Set flag to silence.

    Signed-off-by: Stephen Hemminger
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Stephen Hemminger
     
  • These routines are all big enough that is better to let the compiler
    decide to inline or not.

    Signed-off-by: Stephen Hemminger
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Stephen Hemminger
     
  • Set debug jiffies offset at initialization. Avoids wierd values showing
    up if debugging enabled.

    Signed-off-by: Stephen Hemminger
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Stephen Hemminger
     
  • Change the command padding on 32-bit systems to 0 since setting it to 32
    has the identical effect.

    Signed-off-by: Mike Miller
    Cc: Stephen M. Cameron
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Mike Miller
     
  • Remove a debug statement left behind by accident Ths debug statement got
    left behind. It was commented out after use but not deleted.

    Signed-off-by: Mike Miller
    Cc: Stephen M. Cameron
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Mike Miller
     
  • The definition of next_command also ended up in wrong place It ended up
    inside an "#ifdef CONFIG_PROCFS". Already caught by Randy Dunlap and a
    couple others. Tried to put it somewhere that made sense.

    Signed-off-by: Mike Miller
    Cc: Stephen M. Cameron
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Mike Miller
     
  • call to put_controller_in_performant_mode was in the wrong place
    The call inadvertently ended up in an error path.

    Signed-off-by: Mike Miller
    Cc: Stephen M. Cameron
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Mike Miller
     
  • Make sure we register the performant mode interrupt Another blunder.
    Seemed to work because the call to put_controller_into_performant_mode was
    never called.

    Signed-off-by: Mike Miller
    Cc: Stephen M. Cameron
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Mike Miller
     
  • The code for nonrot, random, and io stats are completely identical.

    Signed-off-by: Jens Axboe

    Jens Axboe
     
  • There are two reasons for doing this:

    - On SSD disks, the completion times aren't as random as they
    are for rotational drives. So it's questionable whether they
    should contribute to the random pool in the first place.

    - Calling add_disk_randomness() has a lot of overhead.

    This adds /sys/block//queue/add_random that will allow you to
    switch off on a per-device basis. The default setting is on, so there
    should be no functional changes from this patch.

    Signed-off-by: Jens Axboe

    Jens Axboe
     
  • Add support for new controllers due out next year. HP must continue to
    support new controllers in older distros. All vendors require support be
    upstream. These controllers support only 16 commands in simple mode but
    can support up to 1024 in performant mode. See patch 5/6/ We have no
    marketing names yet.

    Signed-off-by: Mike Miller
    Cc: Stephen M. Cameron
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Mike Miller
     
  • Add a mode of controller operation called Performant Mode. Even though
    cciss has been deprecated in favor of hpsa there are new controllers due
    out next year that HP must support in older vendor distros. Vendors
    require all fixes/features be upstream. These new controllers support
    only 16 commands in simple mode but support up to 1024 in performant mode.
    This requires us to add this support at this late date.

    The performant mode transport minimizes host PCI accesses by performinf
    many completions per read. PCI writes are posted so the host can write
    then immediately get off the bus not waiting for the writwe to complete to
    the target. In the context of performant mode the host read out to a
    controller pulls all posted writes into host memory ensuring the reply
    queue is coherent.

    Signed-off-by: Mike Miller
    Cc: Stephen M. Cameron
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Mike Miller
     
  • Change the return type of our interrupt access routines to bool from
    unsigned long. It makes more sense that way.

    Signed-off-by: Mike Miller
    Cc: Stephen M. Cameron
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Mike Miller
     
  • Check to see if h->msi[x]_vector is set. We need this for a following
    patch. Without this check we process one interrupt then stop because in
    msi[x] mode the interrupt pending bit is not set. Not sure why we didn't
    encounter this before.

    Signed-off-by: Mike Miller
    Cc: Stephen M. Cameron
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Mike Miller
     
  • Simplify the interrupt handler code to more closely match hpsa and to
    hopefully make it easier to follow.

    Signed-off-by: Mike Miller
    Cc: Stephen M. Cameron
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Mike Miller
     
  • Clean up some code where we subit our io. The same 5 lines appeared
    several times. Also helps for a following patch.

    Signed-off-by: Mike Miller
    Cc: Stephen M. Cameron
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    Mike Miller
     

02 Aug, 2010

2 commits


31 Jul, 2010

13 commits

  • * master.kernel.org:/home/rmk/linux-2.6-arm:
    cyber2000fb: fix console in truecolor modes
    cyber2000fb: fix machine hang on module load
    SA1111: Eliminate use after free
    ARM: Fix Versatile/Realview/VExpress MMC card detection sense
    ARM: 6279/1: highmem: fix SMP preemption bug in kmap_high_l1_vipt
    ARM: Add barriers to io{read,write}{8,16,32} accessors as well
    ARM: 6273/1: Add barriers to the I/O accessors if ARM_DMA_MEM_BUFFERABLE
    ARM: 6272/1: Convert L2x0 to use the IO relaxed operations
    ARM: 6271/1: Introduce *_relaxed() I/O accessors
    ARM: 6275/1: ux500: don't use writeb() in uncompress.h
    ARM: 6270/1: clean files in arch/arm/boot/compressed/
    ARM: Fix csum_partial_copy_from_user()

    Linus Torvalds
     
  • * 'bugfixes' of git://git.linux-nfs.org/projects/trondmy/nfs-2.6:
    NFS: Ensure that writepage respects the nonblock flag
    NFS: kswapd must not block in nfs_release_page
    nfs: include space for the NUL in root path

    Linus Torvalds
     
  • * 'drm-fixes' of git://git.kernel.org/pub/scm/linux/kernel/git/airlied/drm-2.6:
    drm/edid: Fix the HDTV hack sync adjustment
    drm/radeon/kms: fix radeon mid power profile reporting

    Linus Torvalds
     
  • Debian's ia64 autobuilders have been seeing kernel freeze or reboot
    when running the gdb testsuite (Debian bug 588574): dannf bisected to
    2.6.32 62eede62dafb4a6633eae7ffbeb34c60dba5e7b1 "mm: ZERO_PAGE without
    PTE_SPECIAL"; and reproduced it with gdb's gcore on a simple target.

    I'd missed updating the gate_vma handling in __get_user_pages(): that
    happens to use vm_normal_page() (nowadays failing on the zero page),
    yet reported success even when it failed to get a page - boom when
    access_process_vm() tried to copy that to its intermediate buffer.

    Fix this, resisting cleanups: in particular, leave it for now reporting
    success when not asked to get any pages - very probably safe to change,
    but let's not risk it without testing exposure.

    Why did ia64 crash with 16kB pages, but succeed with 64kB pages?
    Because setup_gate() pads each 64kB of its gate area with zero pages.

    Reported-by: Andreas Barth
    Bisected-by: dann frazier
    Signed-off-by: Hugh Dickins
    Tested-by: dann frazier
    Cc: stable@kernel.org
    Signed-off-by: Linus Torvalds

    Hugh Dickins
     
  • Remove the __exit mark from cifs_exit_dns_resolver() as it's called by the
    module init routine in case of error, and so may have been discarded during
    linkage.

    Signed-off-by: David Howells
    Acked-by: Jeff Layton
    Signed-off-by: Linus Torvalds

    David Howells
     
  • Return value was not set to 0 in setcolreg() with truecolor modes. This causes
    fb_set_cmap() to abort after first color, resulting in blank palette - and
    blank console in 24bpp and 32bpp modes.

    Signed-off-by: Ondrej Zary
    Signed-off-by: Russell King

    Ondrej Zary
     
  • I was testing two CyberPro 2000 based PCI cards on x86 and the machine always
    hanged completely when the cyber2000fb module was loaded. It seems that the
    card hangs when some registers are accessed too quickly after writing RAMDAC
    control register. With this patch, both card work.

    Add delay after RAMDAC control register write to prevent hangs on module load.

    Signed-off-by: Ondrej Zary
    Signed-off-by: Russell King

    Ondrej Zary
     
  • __sa1111_remove always frees its argument, so the subsequent reference to
    sachip->saved_state represents a use after free. __sa1111_remove does not
    appear to use the saved_state field, so the patch simply frees it first.

    A simplified version of the semantic patch that finds this problem is as
    follows: (http://coccinelle.lip6.fr/)

    //
    @@
    expression E,E2;
    @@

    __sa1111_remove(E)
    ...
    (
    E = E2
    |
    * E
    )
    //

    Signed-off-by: Julia Lawall
    Signed-off-by: Russell King

    Julia Lawall
     
  • The MMC card detection sense has become really confused with negations
    at various levels, leading to some platforms not detecting inserted
    cards. Fix this by converting everything to positive logic throughout,
    thereby getting rid of these negations.

    Signed-off-by: Russell King

    Russell King
     
  • smp_processor_id() must not be called from a preemptible context (this
    is checked by CONFIG_DEBUG_PREEMPT). kmap_high_l1_vipt() was doing so.
    This lead to a problem where the wrong per_cpu kmap_high_l1_vipt_depth
    could be incremented, causing a BUG_ON(*depth

    Signed-off-by: Gary King
    Acked-by: Nicolas Pitre
    Signed-off-by: Russell King

    Gary King
     
  • Signed-off-by: Trond Myklebust

    Trond Myklebust
     
  • See https://bugzilla.kernel.org/show_bug.cgi?id=16056

    If other processes are blocked waiting for kswapd to free up some memory so
    that they can make progress, then we cannot allow kswapd to block on those
    processes.

    Signed-off-by: Trond Myklebust
    Cc: stable@kernel.org

    Trond Myklebust
     
  • In root_nfs_name() it does the following:

    if (strlen(buf) + strlen(cp) > NFS_MAXPATHLEN) {
    printk(KERN_ERR "Root-NFS: Pathname for remote directory too long.\n");
    return -1;
    }
    sprintf(nfs_export_path, buf, cp);

    In the original code if (strlen(buf) + strlen(cp) == NFS_MAXPATHLEN)
    then the sprintf() would lead to an overflow. Generally the rest of the
    code assumes that the path can have NFS_MAXPATHLEN (1024) characters and
    a NUL terminator so the fix is to add space to the nfs_export_path[]
    buffer.

    Signed-off-by: Dan Carpenter
    Signed-off-by: Trond Myklebust

    Dan Carpenter