16 Jul, 2008

2 commits

  • Manual merge of:

    arch/powerpc/Kconfig
    arch/powerpc/kernel/stacktrace.c
    arch/powerpc/mm/slice.c
    arch/ppc/kernel/smp.c

    Benjamin Herrenschmidt
     
  • * 'upstream-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jgarzik/libata-dev:
    AHCI: Remove an unnecessary flush from ahci_qc_issue
    AHCI: speed up resume
    [libata] Add support for VPD page b1
    ata: endianness annotations in pata drivers
    libata-eh: update atapi_eh_request_sense() to take @dev instead of @qc
    [libata] sata_svw: update code comments relating to data corruption
    libata/ahci: enclosure management support
    libata: improve EH internal command timeout handling
    libata: use ULONG_MAX to terminate reset timeout table
    libata: improve EH retry delay handling
    libata: consistently use msecs for time durations

    Linus Torvalds
     

15 Jul, 2008

14 commits

  • Manual fixup of:

    arch/powerpc/Kconfig

    Benjamin Herrenschmidt
     
  • Benjamin Herrenschmidt
     
  • * 'for-linus' of git://git.kernel.dk/linux-2.6-block: (37 commits)
    splice: fix generic_file_splice_read() race with page invalidation
    ramfs: enable splice write
    drivers/block/pktcdvd.c: avoid useless memset
    cdrom: revert commit 22a9189 (cdrom: use kmalloced buffers instead of buffers on stack)
    scsi: sr avoids useless buffer allocation
    block: blk_rq_map_kern uses the bounce buffers for stack buffers
    block: add blk_queue_update_dma_pad
    DAC960: push down BKL
    pktcdvd: push BKL down into driver
    paride: push ioctl down into driver
    block: use get_unaligned_* helpers
    block: extend queue_flag bitops
    block: request_module(): use format string
    Add bvec_merge_data to handle stacked devices and ->merge_bvec()
    block: integrity flags can't use bit ops on unsigned short
    cmdfilter: extend default read filter
    sg: fix odd style (extra parenthesis) introduced by cmd filter patch
    block: add bounce support to blk_rq_map_user_iov
    cfq-iosched: get rid of enable_idle being unused warning
    allow userspace to modify scsi command filter on per device basis
    ...

    Linus Torvalds
     
  • In an I/O heavy workload (IOZone), ahci_qc_issue is the second-highest
    consumer of CPU cycles. Removing the flush gets us approximately 10%
    bandwidth improvement. I believe this to be because the CPU can start
    queueing the next request instead of waiting for the readl() to flush the
    writes to the device. The flush isn't necessary because we're using a
    'queue' metaphor; we don't guarantee the command has got to the device,
    nor do we need to guarantee the command has got to the controller.

    Signed-off-by: Matthew Wilcox
    Signed-off-by: Jeff Garzik

    Matthew Wilcox
     
  • During resume, sleep 1 second to wait for the HBA reset
    to finish is a waste of time.

    According to the AHCI 1.2 spec,
    We should poll the HOST_CTL register,
    and return error if the host reset is not
    finished within 1 second.

    Test results show that the HBA reset can be done quickly(in usecs).
    And this patch may save nearly 1 second during resume.

    Signed-off-by: Zhang Rui
    Signed-off-by: Jeff Garzik

    Zhang Rui
     
  • SCSI VPD page b1 reports the nominal rotation speed and physical size
    of the device. Devices that conform to ATA-8 can return this information
    in words 217 and 168 of the identify data.

    Signed-off-by: Matthew Wilcox
    Signed-off-by: Jeff Garzik

    Matthew Wilcox
     
  • drivers/ata/pata_qdi.c:142:9: warning: incorrect type in assignment (different base types)
    drivers/ata/pata_qdi.c:142:9: expected unsigned int [unsigned] [usertype] pad
    drivers/ata/pata_qdi.c:142:9: got restricted __le32 [usertype]
    drivers/ata/pata_qdi.c:146:15: warning: cast to restricted __le32

    drivers/ata/pata_winbond.c:110:9: warning: incorrect type in assignment (different base types)
    drivers/ata/pata_winbond.c:110:9: expected unsigned int [unsigned] [usertype] pad
    drivers/ata/pata_winbond.c:110:9: got restricted __le32 [usertype]
    drivers/ata/pata_winbond.c:114:15: warning: cast to restricted __le32

    drivers/ata/pata_legacy.c:310:9: warning: incorrect type in assignment (different base types)
    drivers/ata/pata_legacy.c:310:9: expected unsigned int [unsigned] [usertype] pad
    drivers/ata/pata_legacy.c:310:9: got restricted __le32 [usertype]
    drivers/ata/pata_legacy.c:314:15: warning: cast to restricted __le32
    drivers/ata/pata_legacy.c:752:11: warning: cast to restricted __le32
    drivers/ata/pata_legacy.c:756:9: warning: incorrect type in assignment (different base types)
    drivers/ata/pata_legacy.c:756:9: expected unsigned int [unsigned] [addressable] [assigned] [usertype] pad
    drivers/ata/pata_legacy.c:756:9: got restricted __le32 [usertype]

    Signed-off-by: Harvey Harrison
    Signed-off-by: Jeff Garzik

    Harvey Harrison
     
  • Update atapi_eh_request_sense() to take @dev, @sense_buf and
    @dfl_sense_key instead of taking @qc and extracting information from
    it. This change is to make the function more generic and allow it to
    be called from other places.

    While at it, make cdb initialization use initializer.

    Signed-off-by: Tejun Heo
    Signed-off-by: Jeff Garzik

    Tejun Heo
     
  • Signed-off-by: Pavel Machek
    Signed-off-by: Jeff Garzik

    Pavel Machek
     
  • Add Enclosure Management support to libata and ahci.

    Signed-off-by: Kristen Carlson Accardi
    Signed-off-by: Jeff Garzik

    Kristen Carlson Accardi
     
  • ATA_TMOUT_INTERNAL which was 30secs were used for all internal
    commands which is way too long when something goes wrong. This patch
    implements command type based stepped timeouts. Different command
    types can use different timeouts and each command type can use
    different timeout values after timeouts.

    ie. the initial timeout is set to a value which should cover most of
    the cases but not too long so that run away cases don't delay things
    too much. After the first try times out, the second try can use
    longer timeout and if that one times out too, it can go for full 30sec
    timeout.

    IDENTIFYs use 5s - 10s - 30s timeout and all other commands use 5s -
    10s timeouts.

    This patch significantly cuts down the needed time to handle failure
    cases while still allowing libata to work with nut job devices through
    retries.

    Signed-off-by: Tejun Heo
    Signed-off-by: Jeff Garzik

    Tejun Heo
     
  • This doesn't introduce any functional changes. This is to make reset
    timeout table consistent with to-be-added command timeout tables.

    Signed-off-by: Tejun Heo
    Signed-off-by: Jeff Garzik

    Tejun Heo
     
  • EH retries were delayed by 5 seconds to ensure that resets don't occur
    back-to-back. However, this 5 second delay is superflous or excessive
    in many cases. For example, after IDENTIFY times out, there's no
    reason to wait five more seconds before retrying.

    This patch adds ehc->last_reset timestamp and record the timestamp for
    the last reset trial or success and uses it to space resets by
    ATA_EH_RESET_COOL_DOWN which is 5 secs and removes unconditional 5 sec
    sleeps.

    As this change makes inter-try waits often shorter and they're
    redundant in nature, this patch also removes the "retrying..."
    messages.

    While at it, convert explicit rounding up division to DIV_ROUND_UP().

    This change speeds up EH in many cases w/o sacrificing robustness.

    Signed-off-by: Tejun Heo
    Signed-off-by: Jeff Garzik

    Tejun Heo
     
  • libata has been using mix of jiffies and msecs for time druations.
    This is getting confusing. As writing sub HZ values in jiffies is
    PITA and msecs_to_jiffies() can't be used as initializer, unify unit
    for all time durations to msecs. So, durations are in msecs and
    deadlines are in jiffies. ata_deadline() is added to compute deadline
    from a start time and duration in msecs.

    While at it, drop now superflous _msec suffix from arguments and
    rename @timeout to @deadline if it represents a fixed point in time
    rather than duration.

    Signed-off-by: Tejun Heo
    Signed-off-by: Jeff Garzik

    Tejun Heo
     

13 Jul, 2008

1 commit


11 Jul, 2008

3 commits

  • The problem is introduced by commit
    664d080c41463570b95717b5ad86e79dc1be0877.

    acpi_evaluate_integer is a sleeping function,
    and it should not be called with spin_lock_irqsave.
    https://bugzilla.redhat.com/show_bug.cgi?id=451399

    Signed-off-by: Zhang Rui
    Signed-off-by: Jeff Garzik

    Zhang Rui
     
  • This enables short 40-wire detection for my laptop thus
    enabling UDMA/100.

    Signed-off-by: Jeff Garzik

    Kai Krakow
     
  • Some BIOSen enable DIPM via _GTF which causes command timeouts under
    certain configuration. This didn't occur on 2.6.25 because 2.6.25
    defaulted to SRST, so _GTF wasn't executed during boot probe, so ahci
    host reset disabled DIPM and as _GTF wasn't executed after SRST, DIPM
    wasn't enabled. On 2.6.26, hardreset is used during probe and after
    probe _GTF is executed enabling DIPM and thus the failures.

    This patch could theoretically disable DIPM on machines which used to
    have it enabled on 2.6.25 but AFAIK ahci is currently the only driver
    which uses SATA ACPI hierarchy (_SDD) and as the host reset would have
    always disabled DIPM, this shouldn't happen.

    Signed-off-by: Tejun Heo
    Signed-off-by: Jeff Garzik

    Tejun Heo
     

06 Jul, 2008

1 commit

  • Commit ea0c62f7cf70f13a67830471b613337bd0c9a62e tried to clear all
    bits in irq_stat but it didn't actually achieve that as irq_stat was
    anded with port_map right after read. This patch makes ahci driver
    always use the unmasked value to clear irq_status.

    While at it, add explanation on the peculiarities of ahci IRQ
    clearing.

    This was spotted by Linus Torvalds.

    Signed-off-by: Tejun Heo
    Signed-off-by: Linus Torvalds

    Tejun Heo
     

04 Jul, 2008

5 commits

  • There is a miniscule chance that two separate host controllers
    might be in sata_mv at the same time and manage to decrement
    the static limit_warnings variable below zero.

    Fix the comparison to deal with it.

    Signed-off-by: Mark Lord
    Signed-off-by: Jeff Garzik

    Mark Lord
     
  • Improve SFF HSM violation reporting such that each HSM violation can
    be distinguished using ehi_desc.

    Signed-off-by: Tejun Heo
    Signed-off-by: Jeff Garzik

    Tejun Heo
     
  • Some AHCI controllers (ICH7 was reported) set pending bit in
    HOST_IRQ_STAT for non-existent ports and when it's not cleared falls
    into IRQ storm. Always clear full irq_stat instead of only the bits
    that are handled. As nothing changes for recognized ports, the risk
    of breaking things is pretty low.

    Reported and verified by Philipp Thomas in the following suse
    bugzilla.

    https://bugzilla.novell.com/attachment.cgi?id=215692

    Signed-off-by: Tejun Heo
    Cc: Philipp Thomas
    Signed-off-by: Jeff Garzik

    Tejun Heo
     
  • There's another DID used for Adaptec card. Add it.

    Reported by Travis Read.

    Signed-off-by: Tejun Heo
    Cc: Travis Read
    Signed-off-by: Jeff Garzik

    Tejun Heo
     
  • This adds blk_queue_update_dma_pad to prevent LLDs from overwriting
    the dma pad mask wrongly (we added blk_queue_update_dma_alignment due
    to the same reason).

    This also converts libata to use blk_queue_update_dma_pad instead of
    blk_queue_dma_pad.

    Signed-off-by: FUJITA Tomonori
    Cc: Tejun Heo
    Cc: Bartlomiej Zolnierkiewicz
    Cc: Thomas Bogendoerfer
    Cc: James Bottomley
    Signed-off-by: Andrew Morton
    Signed-off-by: Jens Axboe

    FUJITA Tomonori
     

27 Jun, 2008

1 commit

  • sata_uli can't do hardresets reliably and lock up. This went
    unnoticed till now as softreset was the default and hardreset was only
    used after softreset failed.

    Reported by Christian Casteyde in bz#10860.

    Signed-off-by: Tejun Heo
    Cc: Christian Casteyde
    Signed-off-by: Jeff Garzik

    Tejun Heo
     

21 Jun, 2008

3 commits

  • * git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6:
    BAST: Remove old IDE driver
    pcmcia ide kingston compactflash's have a new manufacturer id
    pcmcia: add another pata/ide ID
    pcmcia: add an pata/ide ID
    ide: increase timeout in wait_drive_not_busy()
    palm_bk3710: fix resource management

    Linus Torvalds
     
  • Addition of Transcend 1GB 45x id so that it is properly detected.

    [bart: fix typo in ide-cs's ID spotted by Alan Cox]

    Signed-off-by: William Peters
    Signed-off-by: Kristoffer Ericson
    CC: Alan Cox
    CC: linux-ide@vger.kernel.org
    Signed-off-by: Dominik Brodowski
    Signed-off-by: Bartlomiej Zolnierkiewicz

    Kristoffer Ericson
     
  • Add an id for:

    product info: "M-Systems", "CF300", ""
    manfid: 0x000a, 0x0000
    function: 4 (fixed disk)

    Signed-off-by: Matt Reimer
    CC: Alan Cox
    CC: linux-ide@vger.kernel.org
    Signed-off-by: Dominik Brodowski
    Signed-off-by: Bartlomiej Zolnierkiewicz

    Matt Reimer
     

19 Jun, 2008

7 commits

  • From: Piter PUNK

    SiS AHCIs say they can do PMP but can't and fail detection if SRST w/
    pmp==15 is used. Turn off PMP support.

    tj: added patch description, adapted patch to #upstream-fixes and
    renamed board_ahci_sis to board_ahci_nopmp.

    Signed-off-by: Tejun Heo
    Signed-off-by: Jeff Garzik

    Tejun Heo
     
  • TOSHIBA also used "TECRA M4" in additon to "Tecra M4", add it.

    Signed-off-by: Tejun Heo
    Signed-off-by: Jeff Garzik

    Tejun Heo
     
  • Add HAVE_PATA_PLATFORM to select the pata platform driver
    to ensure that we do not end up with a long 'depends on' list
    when other users of this driver turn up.

    Signed-off-by: Ben Dooks
    Signed-off-by: Jeff Garzik

    Ben Dooks
     
  • Chip errata sometimes prevents reliable use of PIO commands which involve
    more than a single DRQ (data request). In normal operation, libata should
    not generate such PIO commands (uses DMA instead), but they could be sent
    in via SG_IO from userspace.

    A full workaround might be to break up such commands into sequences
    of single DRQ ones, but that's just way too complex for something
    that doesn't normally happen in real life.

    So, allow the attempt (it often works, despite the errata),
    but log the event for reference when somebody screams.

    Signed-off-by: Mark Lord
    Signed-off-by: Jeff Garzik

    Mark Lord
     
  • The early chipsets cannot safely handle Async Notification (AN),
    but 6041/6081 chip revision "C0" (and newer) can handle it.

    So allow AN for "C0" and higher.

    This enables use of hotplug on PMP ports for the 6041/6081 PCI Rev.9 chips.

    Signed-off-by: Mark Lord
    Signed-off-by: Jeff Garzik

    Mark Lord
     
  • There's no reason to check whether to use DMA or not for no data
    commands. Don't do it. While at it, make local variable using_pio in
    atapi_xlat() set iff ATAPI_PROT_PIO is going to be used and rename
    ata_check_atapi_dma() to atapi_check_dma() for consistency.

    Signed-off-by: Tejun Heo
    Signed-off-by: Jeff Garzik

    Tejun Heo
     
  • JMB361 has only one port but reports it has two causing longish probe
    failure on the second one. Quirk it.

    Reported by Gajo Petrovic in bz 10911.

    Signed-off-by: Tejun Heo
    Cc: Gajo Petrovic
    Signed-off-by: Jeff Garzik

    Tejun Heo
     

13 Jun, 2008

2 commits


05 Jun, 2008

1 commit

  • Fix G5 SATA irq 18: nobody cared, reported on -rc5 by Olaf Hering:
    fixlet to a57c1bade5a0ee5cd8b74502db9cbebb7f5780b2 libata-sff:
    Fix oops reported in kerneloops.org for pnp devices with no ctl

    Signed-off-by: Hugh Dickins
    Acked-by: Alan Cox
    Tested-by: Olaf Hering
    Signed-off-by: Linus Torvalds

    Hugh Dickins