21 May, 2019

1 commit

  • Add SPDX license identifiers to all files which:

    - Have no license information of any form

    - Have EXPORT_.*_SYMBOL_GPL inside which was used in the
    initial scan/conversion to ignore the file

    These files fall under the project license, GPL v2 only. The resulting SPDX
    license identifier is:

    GPL-2.0-only

    Signed-off-by: Thomas Gleixner
    Signed-off-by: Greg Kroah-Hartman

    Thomas Gleixner
     

09 May, 2019

1 commit

  • After a recent chat with Dave we agreed to try to finally kill off the
    legacy IDE code base. Set a two year grace period in which we try
    to move everyone over. There are a few pieces of hardware not
    supported by libata yet, but for many of them we aren't even sure
    if there are any users. For those that have users we have usually
    found a volunteer to add libata support.

    Signed-off-by: Christoph Hellwig
    Acked-by: Jens Axboe
    Signed-off-by: David S. Miller

    Christoph Hellwig
     

31 Jan, 2019

1 commit

  • There's an issue with how sense requests are handled in IDE. If ide-cd
    encounters an error, it queues a sense request. With how IDE request
    handling is done, this is the next request we need to handle. But it's
    impossible to guarantee this, as another request could come in between
    the sense being queued, and ->queue_rq() being run and handling it. If
    that request ALSO fails, then we attempt to doubly queue the single
    sense request we have.

    Since we only support one active request at the time, defer request
    processing when a sense request is queued.

    Fixes: 600335205b8d "ide: convert to blk-mq"
    Reported-by: He Zhe
    Tested-by: He Zhe
    Signed-off-by: Jens Axboe

    Jens Axboe
     

13 Nov, 2018

1 commit


08 Nov, 2018

1 commit

  • ide-disk and ide-cd tested as working just fine, ide-tape and
    ide-floppy haven't. But the latter don't require changes, so they
    should work without issue.

    Add helper function to insert a request from a work queue, since we
    cannot invoke the blk-mq request insertion from IRQ context.

    Cc: David Miller
    Reviewed-by: Hannes Reinecke
    Tested-by: Ming Lei
    Reviewed-by: Omar Sandoval
    Signed-off-by: Jens Axboe

    Jens Axboe
     

14 Aug, 2018

1 commit


13 Jun, 2018

1 commit

  • The kmalloc() function has a 2-factor argument form, kmalloc_array(). This
    patch replaces cases of:

    kmalloc(a * b, gfp)

    with:
    kmalloc_array(a * b, gfp)

    as well as handling cases of:

    kmalloc(a * b * c, gfp)

    with:

    kmalloc(array3_size(a, b, c), gfp)

    as it's slightly less ugly than:

    kmalloc_array(array_size(a, b), c, gfp)

    This does, however, attempt to ignore constant size factors like:

    kmalloc(4 * 1024, gfp)

    though any constants defined via macros get caught up in the conversion.

    Any factors with a sizeof() of "unsigned char", "char", and "u8" were
    dropped, since they're redundant.

    The tools/ directory was manually excluded, since it has its own
    implementation of kmalloc().

    The Coccinelle script used for this was:

    // Fix redundant parens around sizeof().
    @@
    type TYPE;
    expression THING, E;
    @@

    (
    kmalloc(
    - (sizeof(TYPE)) * E
    + sizeof(TYPE) * E
    , ...)
    |
    kmalloc(
    - (sizeof(THING)) * E
    + sizeof(THING) * E
    , ...)
    )

    // Drop single-byte sizes and redundant parens.
    @@
    expression COUNT;
    typedef u8;
    typedef __u8;
    @@

    (
    kmalloc(
    - sizeof(u8) * (COUNT)
    + COUNT
    , ...)
    |
    kmalloc(
    - sizeof(__u8) * (COUNT)
    + COUNT
    , ...)
    |
    kmalloc(
    - sizeof(char) * (COUNT)
    + COUNT
    , ...)
    |
    kmalloc(
    - sizeof(unsigned char) * (COUNT)
    + COUNT
    , ...)
    |
    kmalloc(
    - sizeof(u8) * COUNT
    + COUNT
    , ...)
    |
    kmalloc(
    - sizeof(__u8) * COUNT
    + COUNT
    , ...)
    |
    kmalloc(
    - sizeof(char) * COUNT
    + COUNT
    , ...)
    |
    kmalloc(
    - sizeof(unsigned char) * COUNT
    + COUNT
    , ...)
    )

    // 2-factor product with sizeof(type/expression) and identifier or constant.
    @@
    type TYPE;
    expression THING;
    identifier COUNT_ID;
    constant COUNT_CONST;
    @@

    (
    - kmalloc
    + kmalloc_array
    (
    - sizeof(TYPE) * (COUNT_ID)
    + COUNT_ID, sizeof(TYPE)
    , ...)
    |
    - kmalloc
    + kmalloc_array
    (
    - sizeof(TYPE) * COUNT_ID
    + COUNT_ID, sizeof(TYPE)
    , ...)
    |
    - kmalloc
    + kmalloc_array
    (
    - sizeof(TYPE) * (COUNT_CONST)
    + COUNT_CONST, sizeof(TYPE)
    , ...)
    |
    - kmalloc
    + kmalloc_array
    (
    - sizeof(TYPE) * COUNT_CONST
    + COUNT_CONST, sizeof(TYPE)
    , ...)
    |
    - kmalloc
    + kmalloc_array
    (
    - sizeof(THING) * (COUNT_ID)
    + COUNT_ID, sizeof(THING)
    , ...)
    |
    - kmalloc
    + kmalloc_array
    (
    - sizeof(THING) * COUNT_ID
    + COUNT_ID, sizeof(THING)
    , ...)
    |
    - kmalloc
    + kmalloc_array
    (
    - sizeof(THING) * (COUNT_CONST)
    + COUNT_CONST, sizeof(THING)
    , ...)
    |
    - kmalloc
    + kmalloc_array
    (
    - sizeof(THING) * COUNT_CONST
    + COUNT_CONST, sizeof(THING)
    , ...)
    )

    // 2-factor product, only identifiers.
    @@
    identifier SIZE, COUNT;
    @@

    - kmalloc
    + kmalloc_array
    (
    - SIZE * COUNT
    + COUNT, SIZE
    , ...)

    // 3-factor product with 1 sizeof(type) or sizeof(expression), with
    // redundant parens removed.
    @@
    expression THING;
    identifier STRIDE, COUNT;
    type TYPE;
    @@

    (
    kmalloc(
    - sizeof(TYPE) * (COUNT) * (STRIDE)
    + array3_size(COUNT, STRIDE, sizeof(TYPE))
    , ...)
    |
    kmalloc(
    - sizeof(TYPE) * (COUNT) * STRIDE
    + array3_size(COUNT, STRIDE, sizeof(TYPE))
    , ...)
    |
    kmalloc(
    - sizeof(TYPE) * COUNT * (STRIDE)
    + array3_size(COUNT, STRIDE, sizeof(TYPE))
    , ...)
    |
    kmalloc(
    - sizeof(TYPE) * COUNT * STRIDE
    + array3_size(COUNT, STRIDE, sizeof(TYPE))
    , ...)
    |
    kmalloc(
    - sizeof(THING) * (COUNT) * (STRIDE)
    + array3_size(COUNT, STRIDE, sizeof(THING))
    , ...)
    |
    kmalloc(
    - sizeof(THING) * (COUNT) * STRIDE
    + array3_size(COUNT, STRIDE, sizeof(THING))
    , ...)
    |
    kmalloc(
    - sizeof(THING) * COUNT * (STRIDE)
    + array3_size(COUNT, STRIDE, sizeof(THING))
    , ...)
    |
    kmalloc(
    - sizeof(THING) * COUNT * STRIDE
    + array3_size(COUNT, STRIDE, sizeof(THING))
    , ...)
    )

    // 3-factor product with 2 sizeof(variable), with redundant parens removed.
    @@
    expression THING1, THING2;
    identifier COUNT;
    type TYPE1, TYPE2;
    @@

    (
    kmalloc(
    - sizeof(TYPE1) * sizeof(TYPE2) * COUNT
    + array3_size(COUNT, sizeof(TYPE1), sizeof(TYPE2))
    , ...)
    |
    kmalloc(
    - sizeof(TYPE1) * sizeof(THING2) * (COUNT)
    + array3_size(COUNT, sizeof(TYPE1), sizeof(TYPE2))
    , ...)
    |
    kmalloc(
    - sizeof(THING1) * sizeof(THING2) * COUNT
    + array3_size(COUNT, sizeof(THING1), sizeof(THING2))
    , ...)
    |
    kmalloc(
    - sizeof(THING1) * sizeof(THING2) * (COUNT)
    + array3_size(COUNT, sizeof(THING1), sizeof(THING2))
    , ...)
    |
    kmalloc(
    - sizeof(TYPE1) * sizeof(THING2) * COUNT
    + array3_size(COUNT, sizeof(TYPE1), sizeof(THING2))
    , ...)
    |
    kmalloc(
    - sizeof(TYPE1) * sizeof(THING2) * (COUNT)
    + array3_size(COUNT, sizeof(TYPE1), sizeof(THING2))
    , ...)
    )

    // 3-factor product, only identifiers, with redundant parens removed.
    @@
    identifier STRIDE, SIZE, COUNT;
    @@

    (
    kmalloc(
    - (COUNT) * STRIDE * SIZE
    + array3_size(COUNT, STRIDE, SIZE)
    , ...)
    |
    kmalloc(
    - COUNT * (STRIDE) * SIZE
    + array3_size(COUNT, STRIDE, SIZE)
    , ...)
    |
    kmalloc(
    - COUNT * STRIDE * (SIZE)
    + array3_size(COUNT, STRIDE, SIZE)
    , ...)
    |
    kmalloc(
    - (COUNT) * (STRIDE) * SIZE
    + array3_size(COUNT, STRIDE, SIZE)
    , ...)
    |
    kmalloc(
    - COUNT * (STRIDE) * (SIZE)
    + array3_size(COUNT, STRIDE, SIZE)
    , ...)
    |
    kmalloc(
    - (COUNT) * STRIDE * (SIZE)
    + array3_size(COUNT, STRIDE, SIZE)
    , ...)
    |
    kmalloc(
    - (COUNT) * (STRIDE) * (SIZE)
    + array3_size(COUNT, STRIDE, SIZE)
    , ...)
    |
    kmalloc(
    - COUNT * STRIDE * SIZE
    + array3_size(COUNT, STRIDE, SIZE)
    , ...)
    )

    // Any remaining multi-factor products, first at least 3-factor products,
    // when they're not all constants...
    @@
    expression E1, E2, E3;
    constant C1, C2, C3;
    @@

    (
    kmalloc(C1 * C2 * C3, ...)
    |
    kmalloc(
    - (E1) * E2 * E3
    + array3_size(E1, E2, E3)
    , ...)
    |
    kmalloc(
    - (E1) * (E2) * E3
    + array3_size(E1, E2, E3)
    , ...)
    |
    kmalloc(
    - (E1) * (E2) * (E3)
    + array3_size(E1, E2, E3)
    , ...)
    |
    kmalloc(
    - E1 * E2 * E3
    + array3_size(E1, E2, E3)
    , ...)
    )

    // And then all remaining 2 factors products when they're not all constants,
    // keeping sizeof() as the second factor argument.
    @@
    expression THING, E1, E2;
    type TYPE;
    constant C1, C2, C3;
    @@

    (
    kmalloc(sizeof(THING) * C2, ...)
    |
    kmalloc(sizeof(TYPE) * C2, ...)
    |
    kmalloc(C1 * C2 * C3, ...)
    |
    kmalloc(C1 * C2, ...)
    |
    - kmalloc
    + kmalloc_array
    (
    - sizeof(TYPE) * (E2)
    + E2, sizeof(TYPE)
    , ...)
    |
    - kmalloc
    + kmalloc_array
    (
    - sizeof(TYPE) * E2
    + E2, sizeof(TYPE)
    , ...)
    |
    - kmalloc
    + kmalloc_array
    (
    - sizeof(THING) * (E2)
    + E2, sizeof(THING)
    , ...)
    |
    - kmalloc
    + kmalloc_array
    (
    - sizeof(THING) * E2
    + E2, sizeof(THING)
    , ...)
    |
    - kmalloc
    + kmalloc_array
    (
    - (E1) * E2
    + E1, E2
    , ...)
    |
    - kmalloc
    + kmalloc_array
    (
    - (E1) * (E2)
    + E1, E2
    , ...)
    |
    - kmalloc
    + kmalloc_array
    (
    - E1 * E2
    + E1, E2
    , ...)
    )

    Signed-off-by: Kees Cook

    Kees Cook
     

07 May, 2018

2 commits

  • We now have ways to deal with drainage in the block layer, and libata has
    been using it for ages. We also want to get rid of PCI_DMA_BUS_IS_PHYS
    now, so just reduce the PCI transfer size for ide - anyone who cares for
    performance on PCI controllers should have switched to libata long ago.

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

    Christoph Hellwig
     
  • ide_toggle_bounce did select various strange block bounce limits, including
    not bouncing at all as soon as an iommu is present in the system. Given
    that the dma_map routines now handle any required bounce buffering except
    for ISA DMA, and the ide code already must handle either ISA DMA or highmem
    at least for iommu equipped systems we can get rid of the block layer
    bounce limit setting entirely.

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

    Christoph Hellwig
     

09 Mar, 2018

1 commit

  • This patch has been generated as follows:

    for verb in set_unlocked clear_unlocked set clear; do
    replace-in-files queue_flag_${verb} blk_queue_flag_${verb%_unlocked} \
    $(git grep -lw queue_flag_${verb} drivers block/bsg*)
    done

    Except for protecting all queue flag changes with the queue lock
    this patch does not change any functionality.

    Cc: Mike Snitzer
    Cc: Shaohua Li
    Cc: Christoph Hellwig
    Cc: Hannes Reinecke
    Cc: Ming Lei
    Signed-off-by: Bart Van Assche
    Reviewed-by: Martin K. Petersen
    Reviewed-by: Johannes Thumshirn
    Acked-by: Martin K. Petersen
    Signed-off-by: Jens Axboe

    Bart Van Assche
     

01 Mar, 2018

1 commit


27 Feb, 2018

1 commit


14 Nov, 2017

1 commit

  • Pull timer updates from Thomas Gleixner:
    "Yet another big pile of changes:

    - More year 2038 work from Arnd slowly reaching the point where we
    need to think about the syscalls themself.

    - A new timer function which allows to conditionally (re)arm a timer
    only when it's either not running or the new expiry time is sooner
    than the armed expiry time. This allows to use a single timer for
    multiple timeout requirements w/o caring about the first expiry
    time at the call site.

    - A new NMI safe accessor to clock real time for the printk timestamp
    work. Can be used by tracing, perf as well if required.

    - A large number of timer setup conversions from Kees which got
    collected here because either maintainers requested so or they
    simply got ignored. As Kees pointed out already there are a few
    trivial merge conflicts and some redundant commits which was
    unavoidable due to the size of this conversion effort.

    - Avoid a redundant iteration in the timer wheel softirq processing.

    - Provide a mechanism to treat RTC implementations depending on their
    hardware properties, i.e. don't inflict the write at the 0.5
    seconds boundary which originates from the PC CMOS RTC to all RTCs.
    No functional change as drivers need to be updated separately.

    - The usual small updates to core code clocksource drivers. Nothing
    really exciting"

    * 'timers-core-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip: (111 commits)
    timers: Add a function to start/reduce a timer
    pstore: Use ktime_get_real_fast_ns() instead of __getnstimeofday()
    timer: Prepare to change all DEFINE_TIMER() callbacks
    netfilter: ipvs: Convert timers to use timer_setup()
    scsi: qla2xxx: Convert timers to use timer_setup()
    block/aoe: discover_timer: Convert timers to use timer_setup()
    ide: Convert timers to use timer_setup()
    drbd: Convert timers to use timer_setup()
    mailbox: Convert timers to use timer_setup()
    crypto: Convert timers to use timer_setup()
    drivers/pcmcia: omap1: Fix error in automated timer conversion
    ARM: footbridge: Fix typo in timer conversion
    drivers/sgi-xp: Convert timers to use timer_setup()
    drivers/pcmcia: Convert timers to use timer_setup()
    drivers/memstick: Convert timers to use timer_setup()
    drivers/macintosh: Convert timers to use timer_setup()
    hwrng/xgene-rng: Convert timers to use timer_setup()
    auxdisplay: Convert timers to use timer_setup()
    sparc/led: Convert timers to use timer_setup()
    mips: ip22/32: Convert timers to use timer_setup()
    ...

    Linus Torvalds
     

07 Nov, 2017

1 commit

  • In preparation for unconditionally passing the struct timer_list pointer to
    all timer callbacks, switch to using the new timer_setup() and from_timer()
    to pass the timer pointer explicitly.

    Cc: "David S. Miller"
    Cc: linux-ide@vger.kernel.org
    Signed-off-by: Kees Cook

    Kees Cook
     

04 Oct, 2017

1 commit

  • Recent pci_assign_irq() changes uncovered a problem with missing freeing of
    ide_port class instance on hwif_init() failure in ide_host_register():

    ide0: disabled, no IRQ
    ide0: failed to initialize IDE interface
    ide0: disabling port
    cmd64x 0000:00:02.0: IDE controller (0x1095:0x0646 rev 0x07)
    CMD64x_IDE 0000:00:02.0: BAR 0: can't reserve [io 0x8050-0x8057]
    cmd64x 0000:00:02.0: can't reserve resources
    CMD64x_IDE: probe of 0000:00:02.0 failed with error -16
    ide_generic: please use "probe_mask=0x3f" module parameter for probing all legacy ISA IDE ports
    ------------[ cut here ]------------
    WARNING: CPU: 0 PID: 1 at fs/sysfs/dir.c:31 sysfs_warn_dup+0x94/0xd0
    sysfs: cannot create duplicate filename '/class/ide_port/ide0'
    ...

    Trace:
    [] __warn+0x160/0x190
    [] sysfs_warn_dup+0x94/0xd0
    [] warn_slowpath_fmt+0x58/0x70
    [] sysfs_warn_dup+0x94/0xd0
    [] kernfs_path_from_node+0x30/0x60
    [] kernfs_put+0x16c/0x2c0
    [] kernfs_put+0x16c/0x2c0
    [] sysfs_do_create_link_sd.isra.2+0x100/0x120
    [] device_add+0x2a4/0x7c0
    [] device_create_groups_vargs+0x14c/0x170
    [] device_create_groups_vargs+0x98/0x170
    [] device_create+0x50/0x70
    [] ide_host_register+0x48c/0xa00
    [] ide_host_register+0x450/0xa00
    [] device_register+0x20/0x50
    [] ide_host_register+0x450/0xa00
    [] ide_host_add+0x64/0xe0
    [] kobject_uevent_env+0x16c/0x710
    [] do_one_initcall+0x68/0x260
    [] kernel_init+0x1c/0x1a0
    [] kernel_init+0x0/0x1a0
    [] ret_from_kernel_thread+0x18/0x20
    [] kernel_init+0x0/0x1a0

    ---[ end trace 24a70433c3e4d374 ]---
    ide0: disabling port

    Fix the problem by adding missing code to ide_host_register().

    Fixes: 30fdfb929e82 ("PCI: Add a call to pci_assign_irq() in pci_device_probe()")
    Fixes: 0e4c2eeb758a ("alpha/PCI: Replace pci_fixup_irqs() call with host bridge IRQ mapping hooks")
    Link: http://lkml.kernel.org/r/32ec730f-c1b0-5584-cd35-f8a809122b96@roeck-us.net
    Reported-by: Guenter Roeck
    Tested-by: Guenter Roeck
    Signed-off-by: Bartlomiej Zolnierkiewicz
    [bhelgaas: add Fixes:]
    Signed-off-by: Bjorn Helgaas
    Cc: Richard Henderson
    Cc: Ivan Kokshaysky
    Cc: Matt Turner

    Bartlomiej Zolnierkiewicz
     

21 Jun, 2017

2 commits

  • Since scsi_req_init() works on a struct scsi_request, change the
    argument type into struct scsi_request *.

    Signed-off-by: Bart Van Assche
    Reviewed-by: Christoph Hellwig
    Reviewed-by: Hannes Reinecke
    Reviewed-by: Martin K. Petersen
    Signed-off-by: Jens Axboe

    Bart Van Assche
     
  • Instead of explicitly calling scsi_req_init() after blk_get_request(),
    call that function from inside blk_get_request(). Add an
    .initialize_rq_fn() callback function to the block drivers that need
    it. Merge the IDE .init_rq_fn() function into .initialize_rq_fn()
    because it is too small to keep it as a separate function. Keep the
    scsi_req_init() call in ide_prep_sense() because it follows a
    blk_rq_init() call.

    References: commit 82ed4db499b8 ("block: split scsi_request out of struct request")
    Signed-off-by: Bart Van Assche
    Cc: Christoph Hellwig
    Cc: Hannes Reinecke
    Cc: Omar Sandoval
    Cc: Nicholas Bellinger
    Signed-off-by: Jens Axboe

    Bart Van Assche
     

02 Jun, 2017

1 commit

  • From the context where a SCSI command is submitted it is not always
    possible to figure out whether or not the queue the command is
    submitted to has struct scsi_request as the first member of its
    private data. Hence introduce the flag QUEUE_FLAG_SCSI_PASSTHROUGH.

    Signed-off-by: Bart Van Assche
    Reviewed-by: Hannes Reinecke
    Reviewed-by: Christoph Hellwig
    Reviewed-by: Martin K. Petersen
    Cc: Omar Sandoval
    Cc: Don Brace
    Signed-off-by: Jens Axboe

    Bart Van Assche
     

09 May, 2017

1 commit


28 Jan, 2017

1 commit

  • And require all drivers that want to support BLOCK_PC to allocate it
    as the first thing of their private data. To support this the legacy
    IDE and BSG code is switched to set cmd_size on their queues to let
    the block layer allocate the additional space.

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

    Christoph Hellwig
     

25 Dec, 2016

1 commit


27 Mar, 2015

1 commit


05 Mar, 2014

1 commit

  • On m68k, host->get_lock is used to both lock and register the interrupt
    that the IDE host shares with other device drivers. Registering the
    IDE interrupt handler in ide-probe.c results in duplicating the
    interrupt registered (once via host->get lock, and also via init_irq()),
    and may result in IDE accepting interrupts even when another driver has
    locked the interrupt hardware. This opens the whole locking scheme up
    to races.

    host->get_lock is set on m68k only, so other drivers' behaviour is not
    changed.

    Signed-off-by: Michael Schmitz
    Cc: Geert Uytterhoeven
    Cc: David S. Miller
    Cc: linux-ide@vger.kernel.org
    Signed-off-by: David S. Miller

    Michael Schmitz
     

04 Jul, 2013

1 commit

  • Calling dev_set_name with a single paramter causes it to be handled as a
    format string. Many callers are passing potentially dynamic string
    content, so use "%s" in those cases to avoid any potential accidents,
    including wrappers like device_create*() and bdi_register().

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

    Kees Cook
     

14 Sep, 2010

1 commit

  • We must ensure that ide_proc_port_register_devices() occurs on an
    interface before ide_proc_register_driver() executes for that
    interfaces drives.

    Therefore defer the registry of the driver device objects backed by
    ide_bus_type until after ide_proc_port_register_devices() has run
    and thus all of the drive->proc procfs directory pointers have been
    setup.

    Signed-off-by: Wolfram Sang
    Signed-off-by: David S. Miller

    Wolfram Sang
     

29 Mar, 2010

1 commit


05 Mar, 2010

1 commit

  • * git://git.kernel.org/pub/scm/linux/kernel/git/davem/ide-next-2.6: (49 commits)
    drivers/ide: Fix continuation line formats
    ide: fixed section mismatch warning in cmd640.c
    ide: ide_timing_compute() fixup
    ide: make ide_get_best_pio_mode() static
    via82cxxx: use ->pio_mode value to determine pair device speed
    tx493xide: use ->pio_mode value to determine pair device speed
    siimage: use ->pio_mode value to determine pair device speed
    palm_bk3710: use ->pio_mode value to determine pair device speed
    it821x: use ->pio_mode value to determine pair device speed
    cs5536: use ->pio_mode value to determine pair device speed
    cs5535: use ->pio_mode value to determine pair device speed
    cmd64x: fix handling of address setup timings
    amd74xx: use ->pio_mode value to determine pair device speed
    alim15x3: fix handling of UDMA enable bit
    alim15x3: fix handling of DMA timings
    alim15x3: fix handling of command timings
    alim15x3: fix handling of address setup timings
    ide-timings: use ->pio_mode value to determine fastest PIO speed
    ide: change ->set_dma_mode method parameters
    ide: change ->set_pio_mode method parameters
    ...

    Linus Torvalds
     

26 Feb, 2010

2 commits


19 Jan, 2010

1 commit


06 Nov, 2009

1 commit

  • This reverts commit 6029336426a2b43e4bc6f4a84be8789a047d139e.

    Ok, we really do need to revert this, even with Bart's sis5513.c
    fix in there.

    The problem is that several driver's ->set_pio_mode() method
    depends upon the drive->media type being set properly. Most
    of them use this to enable prefetching, which can only be done
    for disk media.

    But the commit being reverted here calls ->set_pio_mode() before
    it's setup. Actually it considers everything disk because that
    is the default media type set by ide_port_init_devices_data().

    The set of drivers that depend upon the media type in their
    ->set_pio_method() are:

    drivers/ide/alim15x3.c
    drivers/ide/it8172.c
    drivers/ide/it8213.c
    drivers/ide/pdc202xx_old.c
    drivers/ide/piix.c
    drivers/ide/qd65xx.c
    drivers/ide/sis5513.c
    drivers/ide/slc90e66.c

    And it is possible that we could fix this by guarding the prefetching
    and other media dependent setting changes with a test on
    IDE_PFLAG_PROBING in hwif->port_flags, that's simply too risky for
    2.6.32-rcX and -stable.

    Signed-off-by: David S. Miller

    David S. Miller
     

07 Oct, 2009

1 commit


05 Oct, 2009

1 commit


21 Sep, 2009

1 commit


08 Aug, 2009

1 commit

  • * Un-static __ide_wait_stat().

    * Allow ide_dev_read_id() helper to be called from the IRQ context by
    adding irq_ctx flag and using mdelay()/__ide_wait_stat() when needed.

    * Switch ide_driveid_update() to set irq_ctx flag.

    This change is needed for the consecutive patch which fixes races in
    handling of user-space SET XFER commands but for improved bisectability
    and clarity it is better to do it in a separate patch.

    Signed-off-by: Bartlomiej Zolnierkiewicz
    Signed-off-by: David S. Miller

    Bartlomiej Zolnierkiewicz
     

24 Jun, 2009

1 commit

  • Add ide_host_enable_irqs() helper and use it in ide_host_register()
    before registering ports. Then remove no longer needed IRQ unmasking
    from in init_irq().

    This should fix the problem with "screaming" shared IRQ on the first
    port (after request_irq() call while we have the unexpected IRQ pending
    on the second port) which was uncovered by my rework of the serialized
    interfaces support.

    Reported-by: Frans Pop
    Tested-by: Frans Pop
    Signed-off-by: Bartlomiej Zolnierkiewicz
    Signed-off-by: David S. Miller

    Bartlomiej Zolnierkiewicz
     

21 Jun, 2009

1 commit

  • * 'for-2.6.31' of git://git.kernel.org/pub/scm/linux/kernel/git/bart/ide-2.6: (34 commits)
    ide-cd: prevent null pointer deref via cdrom_newpc_intr
    ide: BUG() on unknown requests
    ide: filter out invalid DMA xfer mode changes in HDIO_DRIVE_CMD ioctl handler
    ide: do not access ide_drive_t 'drive_data' field directly
    sl82c105: implement test_irq() method
    siimage: implement test_irq() method
    pdc202xx_old: implement test_irq() method (take 2)
    cmd64x: implement test_irq() method
    cmd640: implement test_irq() method
    ide: move ack_intr() method into 'struct ide_port_ops' (take 2)
    ide: move IRQ clearing from ack_intr() method to clear_irq() method (take 2)
    siimage: use ide_dma_test_irq() (take 2)
    cmd64x: implement clear_irq() method (take 2)
    ide: call clear_irq() method in ide_timer_expiry()
    sgiioc4: coding style cleanup
    ide: don't enable IORDY at a probe time
    ide: IORDY handling fixes
    ata: add ata_id_pio_need_iordy() helper (v2)
    ide-tape: fix build issue
    ide: unify interrupt reason checking
    ...

    Linus Torvalds
     

16 Jun, 2009

3 commits

  • In the near future, the driver core is going to not allow direct access
    to the driver_data pointer in struct device. Instead, the functions
    dev_get_drvdata() and dev_set_drvdata() should be used. These functions
    have been around since the beginning, so are backwards compatible with
    all older kernel versions.

    Cc: linux-ide@vger.kernel.org
    Acked-by: Bartlomiej Zolnierkiewicz
    Signed-off-by: Greg Kroah-Hartman

    Greg Kroah-Hartman
     
  • Move the ack_intr() method into 'struct ide_port_ops', also renaming it to
    test_irq() while at it...

    Signed-off-by: Sergei Shtylyov
    Signed-off-by: Bartlomiej Zolnierkiewicz

    Sergei Shtylyov
     
  • * Add 'unsigned long port_flags' field to ide_hwif_t.

    * Add IDE_PFLAG_PROBING port flag and keep it set during probing.

    * Fix ide_pio_need_iordy() to not enable IORDY at a probe time
    (IORDY may lead to controller lock up on certain controllers
    if the port is not occupied).

    Loosely based on the recent libata's fix by Tejun, thanks to Alan
    for the hint that IDE may also need it.

    Signed-off-by: Bartlomiej Zolnierkiewicz

    Bartlomiej Zolnierkiewicz