1. 29 10月, 2007 3 次提交
    • T
      libata: implement ata_wait_after_reset() · 88ff6eaf
      Tejun Heo 提交于
      On certain device/controller combination, 0xff status is asserted
      after reset and doesn't get cleared during 150ms post-reset wait.  As
      0xff status is interpreted as no device (for good reasons), this can
      lead to misdetection on such cases.
      
      This patch implements ata_wait_after_reset() which replaces the 150ms
      sleep and waits upto ATA_TMOUT_FF_WAIT if status is 0xff.
      ATA_TMOUT_FF_WAIT is currently 800ms which is enough for
      HHD424020F7SV00 to get detected but not enough for Quantum GoVault
      drive which is known to take upto 2s.
      
      Without parallel probing, spending 2s on 0xff port would incur too
      much delay on ata_piix's which use 0xff to indicate empty port and
      doesn't have SCR register, so GoVault needs to wait till parallel
      probing.
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NAndrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      88ff6eaf
    • T
      libata: track SLEEP state and issue SRST to wake it up · 054a5fba
      Tejun Heo 提交于
      ATA devices in SLEEP mode don't respond to any commands.  SRST is
      necessary to wake it up.  Till now, when a command is issued to a
      device in SLEEP mode, the command times out, which makes EH reset the
      device and retry the command after that, causing a long delay.
      
      This patch makes libata track SLEEP state and issue SRST automatically
      if a command is about to be issued to a device in SLEEP.
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Cc: Bruce Allen <ballen@gravity.phys.uwm.edu>
      Cc: Andrew Paprocki <andrew@ishiboo.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      054a5fba
    • T
      libata: relocate and fix post-command processing · 4dbfa39b
      Tejun Heo 提交于
      Some commands need post-processing after successful completion.  This
      was done in ata_scsi_qc_complete() till now but this has the following
      problems.
      
      * Post-command processing gets executed when qc is completed from EH.
        Some qc's are retried from EH with zero err_mask and thus triggers
        unnecessary/incorrect post-command processing.
      
      * Command post processing doesn't belong to SAT layer.
      
      * Link-wide revalidation was scheduled where device revalidation
        suffices.
      
      This patch moves post-command processing to success completion path of
      ata_qc_complete() which is travelled iff the command is going to be
      completed without passing through EH and updates post-command
      processing such that device-specific action is used.  While at it,
      restructure code a bit for readability.
      Signed-off-by: NTejun Heo <htejun@gmail.com>
      Signed-off-by: NJeff Garzik <jeff@garzik.org>
      4dbfa39b
  2. 28 10月, 2007 3 次提交
  3. 27 10月, 2007 11 次提交
    • D
      mmc_spi: Fix mmc-over-spi regression · 460cd058
      David Brownell 提交于
      Patch 49dce689 changed the sysfs data
      structures for SPI in a way which broke the MMC-over-SPI host driver.
      
      This patch fixes that regression by changing the scheme used to keep
      from knowingly trying to use a shared bus segment, and updates the
      adjacent comments slightly to better explain the issue.
      Signed-off-by: NDavid Brownell <dbrownell@users.sourceforge.net>
      Signed-off-by: NPierre Ossman <drzeus@drzeus.cx>
      460cd058
    • P
      mmc: use common byte swap macros · 1fa8dd14
      Pierre Ossman 提交于
      Use the more generic byte swapping macros instead of the socket variants.
      Signed-off-by: NPierre Ossman <drzeus@drzeus.cx>
      1fa8dd14
    • P
      mmc: fix cid and csd byte order · 78e48073
      Pierre Ossman 提交于
      MMC over SPI sends the CID and CSD registers as data, not responses,
      which means that the host driver won't do the necessary byte flipping
      for us.
      Signed-off-by: NPierre Ossman <drzeus@drzeus.cx>
      78e48073
    • P
      at91_mci: Fix bad reference · 6356a9d9
      Pierre Ossman 提交于
      The flags parameter got removed in a previous commit, but some
      references were overlooked.
      Signed-off-by: NPierre Ossman <drzeus@drzeus.cx>
      6356a9d9
    • H
      [CRYPTO] users: Fix up scatterlist conversion errors · 68e3f5dd
      Herbert Xu 提交于
      This patch fixes the errors made in the users of the crypto layer during
      the sg_init_table conversion.  It also adds a few conversions that were
      missing altogether.
      Signed-off-by: NHerbert Xu <herbert@gondor.apana.org.au>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      68e3f5dd
    • E
      [NET]: Marking struct pernet_operations __net_initdata was inappropriate · 2b008b0a
      Eric W. Biederman 提交于
      It is not safe to to place struct pernet_operations in a special section.
      We need struct pernet_operations to last until we call unregister_pernet_subsys.
      Which doesn't happen until module unload.
      
      So marking struct pernet_operations is a disaster for modules in two ways.
      - We discard it before we call the exit method it points to.
      - Because I keep struct pernet_operations on a linked list discarding
        it for compiled in code removes elements in the middle of a linked
        list and does horrible things for linked insert.
      
      So this looks safe assuming __exit_refok is not discarded
      for modules.
      Signed-off-by: NEric W. Biederman <ebiederm@xmission.com>
      Signed-off-by: NDavid S. Miller <davem@davemloft.net>
      2b008b0a
    • B
      ide: add SH-S202J to ivb_list[] · 8588a2b7
      Bartlomiej Zolnierkiewicz 提交于
      From the report by Nick Warne.
      Tested-by: NNick Warne <nick@ukfsn.org>
      Cc: Lennart Sorensen <lsorense@csclub.uwaterloo.ca>
      Signed-off-by: NBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
      8588a2b7
    • J
      drivers/ide/pci/sc1200.c: fix suspend/resume buglets and warnings · 9d434813
      Jeff Garzik 提交于
      * We shouldn't bother with dev->current_state, the PCI API functions we
        call manage this for us (and do a far better job at it too).
      
      * Remove pci_set_power_state(dev, PCI_D0) call in resume, as
        pci_enable_device() does the same thing.
      
      * Check pci_enable_device() return value.  If it failed, fail
        the entire resume and avoid programming timings into the [potentially
        dead/asleep] chip.
      Signed-off-by: NJeff Garzik <jgarzik@redhat.com>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
      9d434813
    • B
      drivers/ide/pci/generic: fix build for CONFIG_HOTPLUG=n · d5271be6
      Bartlomiej Zolnierkiewicz 提交于
      It turns out that const and __{dev}initdata cannot be mixed currently
      and that generic IDE PCI host driver is also affected by the same issue:
      
      On Thursday 25 October 2007, Ralf Baechle wrote:
      >   CC      drivers/ide/pci/generic.o
      > drivers/ide/pci/generic.c:52: error: __setup_str_ide_generic_all_on causes a
      > +section type conflict
      
      [ Also reported by Martijn Uffing <mp3project@sarijopen.student.utwente.nl>. ]
      
      This patch workarounds the problem in a bit hackish way but without
      removing const from generic_chipsets[] (it adds const to __setup() so
      __setup_str_ide_generic_all becomes const).
      
      Now all __{dev}initdata data in generic IDE PCI host driver are read-only
      so it builds again (driver's .init.data section gets marked as READONLY).
      
      Cc: Martijn Uffing <mp3project@sarijopen.student.utwente.nl>
      Cc: Ralf Baechle <ralf@linux-mips.org>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Signed-off-by: NBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
      d5271be6
    • B
      hpt366: fix build for CONFIG_HOTPLUG=n · 282037f1
      Bartlomiej Zolnierkiewicz 提交于
      On Saturday 20 October 2007, Avuton Olrich wrote:
      
      > My randconfig script the attached config caught an error on:
      > drivers/ide/pci/cy82c693.c:439: error: primary causes a section type conflict
      >
      > My git tree: c00046c2
      >
      > Bisected to:
      > 85620436 is first bad commit
      > commit 85620436
      > Author: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
      > Date:   Sat Oct 20 00:32:34 2007 +0200
      >
      >     ide: constify struct ide_port_info
      >
      >     Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
      
      It turns out that const and __{dev}initdata cannot be mixed currently
      and that hpt366 host driver is also affected by the same issue:
      
      > drivers/ide/pci/hpt366.c:1428: error: hpt366_chipsets causes a section type
      > conflict
      
      This patch workarounds the problem by making static struct hpt_info instances
      const.  Now all __devinitdata data in hpt366 host driver are read-only so it
      builds again (driver's .init.data section gets marked as READONLY).
      
      While at it:
      
      * Bump driver version.
      
      Cc: Sergei Shtylyov <sshtylyov@ru.mvista.com>
      Cc: "Avuton Olrich" <avuton@gmail.com>
      Cc: Randy Dunlap <randy.dunlap@oracle.com>
      Signed-off-by: NBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
      282037f1
    • B
      cy82c693: fix build for CONFIG_HOTPLUG=n · f32d26ae
      Bartlomiej Zolnierkiewicz 提交于
      On Saturday 20 October 2007, Avuton Olrich wrote:
      
      > My randconfig script the attached config caught an error on:
      > drivers/ide/pci/cy82c693.c:439: error: primary causes a section type conflict
      >
      > My git tree: c00046c2
      >
      > Bisected to:
      > 85620436 is first bad commit
      > commit 85620436
      > Author: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
      > Date:   Sat Oct 20 00:32:34 2007 +0200
      >
      >     ide: constify struct ide_port_info
      >
      >     Signed-off-by: Bartlomiej Zolnierkiewicz <bzolnier@gmail.com>
      
      It turns out that const and __{dev}initdata cannot be mixed currently.
      
      This patch workarounds the problem by removing __devinitdata tag from 'primary'
      variable (which makes 'primary' to be moved from .init.data to .bss section).
      Now all __devinitdata data in cy82c693 host driver are read-only so it builds
      again (driver's .init.data section gets marked as READONLY).
      
      While at it:
      
      * Move 'primary' variable to its only user, init_iops_cy82c693().
      
      * Bump driver version.
      
      Cc: "Avuton Olrich" <avuton@gmail.com>
      Cc: Randy Dunlap <randy.dunlap@oracle.com>
      Signed-off-by: NBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
      f32d26ae
  4. 26 10月, 2007 23 次提交