1. 23 Apr, 2009 2 commits
  2. 22 Apr, 2009 1 commit
    • David Brownell's avatar
      palm_bk3710: UDMA performance fix · db2f38c2
      David Brownell authored
      Fix UDMA throughput bug:  tCYC averages t2CYCTYP/2, but the code
      previously assumed it was the same as t2CYCTYP.  (That is, it was
      using just one clock edge, not both.)  Move the table's type
      declaration so it's adjacent to the table, making it more clear
      what those numbers mean.
      On one system this change increased throughput by almost 4x: UDMA/66
      sometimes topped 23 MB/sec (on a drive known to do much better).  On
      another system it was around a 10% win (UDMA/66 up to 7+ MB/sec).
      The difference might be caused by the ratio between memory and IDE
      clocks.  In the system with large speedup, this was exactly 2 (as a
      workaround for a rev 1.1 silicon bug).  The other system used a more
      standard ratio of 1.63 (and rev 2.1 silicon) ... clock domain synch
      might have some issues, they're not unheard-of.
      Signed-off-by: default avatarDavid Brownell <dbrownell@users.sourceforge.net>
      Acked-by: default avatarSergei Shtylyov <sshtylyov@ru.mvista.com>
      Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
  3. 27 Mar, 2009 1 commit
  4. 19 Jan, 2009 1 commit
  5. 06 Jan, 2009 1 commit
  6. 21 Oct, 2008 1 commit
  7. 10 Oct, 2008 3 commits
  8. 02 Sep, 2008 2 commits
  9. 05 Aug, 2008 1 commit
  10. 24 Jul, 2008 1 commit
  11. 23 Jul, 2008 5 commits
    • Bartlomiej Zolnierkiewicz's avatar
      ide: add ide_host_add() helper · 6f904d01
      Bartlomiej Zolnierkiewicz authored
      Add ide_host_add() helper which does ide_host_alloc()+ide_host_register(),
      then convert ide_setup_pci_device[s](), ide_legacy_device_add() and some
      host drivers to use it.
      While at it:
      * Fix ide_setup_pci_device[s](), ide_arm.c, gayle.c, ide-4drives.c,
        macide.c, q40ide.c, cmd640.c and cs5520.c to return correct error value.
      * -ENOENT -> -ENOMEM in rapide.c, ide-h8300.c, ide-generic.c, au1xxx-ide.c
        and pmac.c
      * -ENODEV -> -ENOMEM in palm_bk3710.c, ide_platform.c and delkin_cb.c
      * -1 -> -ENOMEM in ide-pnp.c
      Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
    • Bartlomiej Zolnierkiewicz's avatar
      ide: add struct ide_host (take 3) · 48c3c107
      Bartlomiej Zolnierkiewicz authored
      * Add struct ide_host which keeps pointers to host's ports.
      * Add ide_host_alloc[_all]() and ide_host_remove() helpers.
      * Pass 'struct ide_host *host' instead of 'u8 *idx' to
        ide_device_add[_all]() and rename it to ide_host_register[_all]().
      * Convert host drivers and core code to use struct ide_host.
      * Remove no longer needed ide_find_port().
      * Make ide_find_port_slot() static.
      * Unexport ide_unregister().
      * Add missing 'struct ide_host *host' to macide.c.
      * Fix build problem in pmac.c (s/ide_alloc_host/ide_host_alloc/)
        (Noticed by Stephen Rothwell).
      Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
    • Bartlomiej Zolnierkiewicz's avatar
      ide: remove ->INB, ->OUTB and ->OUTBSYNC methods · 761052e6
      Bartlomiej Zolnierkiewicz authored
      * Remove no longer needed ->INB, ->OUTB and ->OUTBSYNC methods.
      * Remove no longer used default_hwif_[mm]iops() and ide_[mm_]outbsync().
      * Cleanup SuperIO handling in ns87415.c.
      There should be no functional changes caused by this patch.
      Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
    • Bartlomiej Zolnierkiewicz's avatar
      ide: remove ide_setup_dma() · 81e8d5a3
      Bartlomiej Zolnierkiewicz authored
      Export sff_dma_ops and then remove ide_setup_dma().
      There should be no functional changes caused by this patch.
      Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
    • Bartlomiej Zolnierkiewicz's avatar
      ide: pass hw_regs_t-s to ide_device_add[_all]() (take 3) · c97c6aca
      Bartlomiej Zolnierkiewicz authored
      * Add 'hw_regs_t **hws' argument to ide_device_add[_all]() and convert
        host drivers + ide_legacy_init_one() + ide_setup_pci_device[s]() to use
        it instead of calling ide_init_port_hw() directly.
        [ However if host has > 1 port we must still set hwif->chipset to hint
          consecutive ide_find_port() call that the previous slot is occupied. ]
      * Unexport ide_init_port_hw().
      * Use defines instead of hard-coded values in buddha.c, gayle.c and q40ide.c.
        (Suggested by Geert Uytterhoeven)
      * Better patch description.
      * Fix build problem in ide-cs.c. (Noticed by Stephen Rothwell)
      There should be no functional changes caused by this patch.
      Cc: Geert Uytterhoeven <geert@linux-m68k.org>
      Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
  12. 16 Jul, 2008 2 commits
  13. 15 Jul, 2008 2 commits
  14. 08 Jul, 2008 1 commit
    • Sergei Shtylyov's avatar
      palm_bk3710: fix IDECLK period calculation · ffab6cf4
      Sergei Shtylyov authored
      The driver uses completely bogus rounding formula for calculating period from
      the IDECLK frequency which gives one-off period values (e.g. 11 ns with 100 MHz
      IDECLK) which in turn can lead to overclocked IDE transfer timings.  Actually,
      rounding is just wrong in this case, so use a mere division for a safe result.
      While at it, also:
      - give 'ide_palm_clk' variable a more suitable name;
      - get rid of the useless 'ideclkp' variable;
      - drop the LISP stype 'p' postfix from the 'clkp' variable's name. :-)
      Signed-off-by: default avatarSergei Shtylyov <sshtylyov@ru.mvista.com>
      Cc: mcherkashin@ru.mvista.com
      Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
  15. 20 Jun, 2008 1 commit
  16. 10 Jun, 2008 1 commit
  17. 28 Apr, 2008 1 commit
    • Bartlomiej Zolnierkiewicz's avatar
      ide: add IDE_HFLAG_MMIO host flag (take 2) · c5dd43ec
      Bartlomiej Zolnierkiewicz authored
      * Add IDE_HFLAG_MMIO host flag and set it for hosts which use
      * Fix kernel panic in pmac host driver (',' should be '|').
        Thanks to Kamalesh for reporting it + testing the fix
        and to Andrew for hinting me about the source of the issue.
      Cc: Kamalesh Babulal <kamalesh@linux.vnet.ibm.com>
      Cc: Andrew Morton <akpm@linux-foundation.org>
      Cc: Stephen Rothwell <sfr@canb.auug.org.au>
      Cc: Andy Whitcroft <apw@shadowen.org>
      Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
  18. 27 Apr, 2008 2 commits
  19. 26 Apr, 2008 7 commits
  20. 24 Apr, 2008 1 commit
  21. 17 Apr, 2008 3 commits
    • Bartlomiej Zolnierkiewicz's avatar
      ide: remove ->hold field from ide_hwif_t (take 2) · 2304dc64
      Bartlomiej Zolnierkiewicz authored
      ->hold is write-only now, remove it.
      * v1 missed bast-ide, palm_bk3710, ide-cs and delkin_cb host drivers.
      Acked-by: default avatarSergei Shtylyov <sshtylyov@ru.mvista.com>
      Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
    • Bartlomiej Zolnierkiewicz's avatar
      ide: remove broken/dangerous HDIO_[UNREGISTER,SCAN]_HWIF ioctls (take 3) · 93de00fd
      Bartlomiej Zolnierkiewicz authored
      hdparm explicitely marks HDIO_[UNREGISTER,SCAN]_HWIF ioctls as DANGEROUS
      and given the number of bugs we can assume that there are no real users:
      * DMA has no chance of working because DMA resources are released by
        ide_unregister() and they are never allocated again.
      * Since ide_init_hwif_ports() is used for ->io_ports[] setup the ioctls
        don't work for almost all hosts with "non-standard" (== non ISA-like)
        layout of IDE taskfile registers (there is a lot of such host drivers).
      * ide_port_init_devices() is not called when probing IDE devices so:
        - drive->autotune is never set and IDE host/devices are not programmed
          for the correct PIO/DMA transfer modes (=> possible data corruption)
        - host specific I/O 32-bit and IRQ unmasking settings are not applied
          (=> possible data corruption)
        - host specific ->port_init_devs method is not called (=> no luck with
          ht6560b, qd65xx and opti621 host drivers)
      * ->rw_disk method is not preserved (=> no HPT3xxN chipsets support).
      * ->serialized flag is not preserved (=> possible data corruption when
         using icside, aec62xx (ATP850UF chipset), cmd640, cs5530, hpt366
         (HPT3xxN chipsets), rz1000, sc1200, dtc2278 and ht6560b host drivers).
      * ->ack_intr method is not preserved (=> needed by ide-cris, buddha,
        gayle and macide host drivers).
      * ->sata_scr[] and sata_misc[] is cleared by ide_unregister() and it
        isn't initialized again (SiI3112 support needs them).
      * To issue an ioctl() there need to be at least one IDE device present
        in the system.
      * ->cable_detect method is not preserved + it is not called when probing
        IDE devices so cable detection is broken (however since DMA support is
        also broken it doesn't really matter ;-).
      * Some objects which may have already been freed in ide_unregister()
        are restored by ide_hwif_restore() (i.e. ->hwgroup).
      * ide_register_hw() may unregister unrelated IDE ports if free ide_hwifs[]
        slot cannot be found.
      * When IDE host drivers are modular unregistered port may be re-used by
        different host driver that owned it first causing subtle bugs.
      Since we now have a proper warm-plug support remove these ioctls,
      then remove no longer needed:
      - ide_register_hw() and ide_hwif_restore() functions
      - 'init_default' and 'restore' arguments of ide_unregister()
      - zeroeing of hwif->{dma,extra}_* fields in ide_unregister()
      As an added bonus IDE core code size shrinks by ~3kB (x86-32).
      * fix ide_unregister() arguments in cleanup_module() (Andrew Morton).
      * fix ide_unregister() arguments in palm_bk3710.c.
      Acked-by: default avatarSergei Shtylyov <sshtylyov@ru.mvista.com>
      Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>
    • Bartlomiej Zolnierkiewicz's avatar
      ide: use ide_find_port() instead of ide_deprecated_find_port() · 4f0eee4d
      Bartlomiej Zolnierkiewicz authored
      * Use ide_find_port() instead of ide_deprecated_find_port() in bast-ide/
        palm_bk3710/ide-cs/delkin_cb host drivers and in ide_register_hw().
      * Remove no longer needed ide_deprecated_find_port().
      Signed-off-by: default avatarBartlomiej Zolnierkiewicz <bzolnier@gmail.com>