09 Jan, 2012

1 commit

  • This patch converts the drivers in drivers/ata/* to use the
    module_platform_driver() macro which makes the code smaller and a bit
    simpler.

    Cc: Viresh Kumar
    Cc: Jeff Garzik
    Cc: Arnaud Patard
    Cc: Alessandro Zummo
    Cc: Sylvain Munaut
    Cc: Anton Vorontsov
    Cc: Marek Vasut
    Cc: Florian Fainelli
    Cc: Mark Miesfeld
    Cc: Ashish Kalra
    Cc: Paul Mundt
    Signed-off-by: Axel Lin
    Signed-off-by: Jeff Garzik

    Axel Lin
     

19 Aug, 2011

1 commit

  • Currently, error handling code in this function calls the function
    sata_dwc_port_stop, but this function has essentially no effect if hsdevp
    has not been stored in ap, which is the case throughout this function. The
    only effect is to print a debugging message including ap->print_id.

    The code is rewritten to not call sata_dwc_port_stop, but instead to jump
    to a local label that prints the original error message and the print_id
    information. In the case where hsdevp has been already allocated (but not
    yet stored in ap), this value is freed as well.

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

    //
    @exists@
    local idexpression x;
    statement S,S1;
    expression E;
    identifier fl;
    expression *ptr != NULL;
    @@

    x = \(kmalloc\|kzalloc\|kcalloc\)(...);
    ...
    if (x == NULL) S
    }
    when any
    when != true x == NULL
    x->fl
    ...>
    (
    if (x == NULL) S1
    |
    if (...) { ... when != x
    when forall
    (
    return \(0\|\|ptr\);
    |
    * return ...;
    )
    }
    )
    //

    Signed-off-by: Julia Lawall
    Signed-off-by: Jeff Garzik

    Julia Lawall
     

26 Jul, 2011

1 commit


24 Jul, 2011

1 commit

  • Fixed hsdev memleak on sata_dwc_probe() error.
    As dma_dwc_exit() can be called multiple times without sata_dma_regs and
    irq_dma changes, it might lead to double free on sequential
    dma_dwc_exit() calls. So, zero these fields after free calls.

    Signed-off-by: Vasiliy Kulikov
    Signed-off-by: Jeff Garzik

    Vasiliy Kulikov
     

24 Jun, 2011

1 commit


17 Mar, 2011

1 commit

  • * 'devicetree/next' of git://git.secretlab.ca/git/linux-2.6: (21 commits)
    tty: serial: altera_jtaguart: Add device tree support
    tty: serial: altera_uart: Add devicetree support
    dt: eliminate of_platform_driver shim code
    dt: Eliminate of_platform_{,un}register_driver
    dt/serial: Eliminate users of of_platform_{,un}register_driver
    dt/usb: Eliminate users of of_platform_{,un}register_driver
    dt/video: Eliminate users of of_platform_{,un}register_driver
    dt/net: Eliminate users of of_platform_{,un}register_driver
    dt/sound: Eliminate users of of_platform_{,un}register_driver
    dt/spi: Eliminate users of of_platform_{,un}register_driver
    dt: uartlite: merge platform and of_platform driver bindings
    dt: xilinx_hwicap: merge platform and of_platform driver bindings
    ipmi: convert OF driver to platform driver
    leds/leds-gpio: merge platform_driver with of_platform_driver
    dt/sparc: Eliminate users of of_platform_{,un}register_driver
    dt/powerpc: Eliminate users of of_platform_{,un}register_driver
    dt/powerpc: move of_bus_type infrastructure to ibmebus
    drivercore/dt: add a match table pointer to struct device
    dt: Typo fix.
    altera_ps2: Add devicetree support
    ...

    Linus Torvalds
     

02 Mar, 2011

6 commits

  • All checks of ATA_FLAG_NO_LEGACY have been removed by the commits
    c791c30670ea61f19eec390124128bf278e854fe ([libata] minor PCI IDE probe
    fixes and cleanups) and f0d36efdc624beb3d9e29b9ab9e9537bf0f25d5b (libata:
    update libata core layer to use devres), so I think it's time to finally
    get rid of this flag...

    Signed-off-by: Sergei Shtylyov
    Signed-off-by: Jeff Garzik

    Sergei Shtylyov
     
  • Commit 0d5ff566779f894ca9937231a181eb31e4adff0e (libata: convert to iomap)
    removed all checks of ATA_FLAG_MMIO but neglected to remove the flag itself.
    Do it now, at last...

    Signed-off-by: Sergei Shtylyov
    Signed-off-by: Jeff Garzik

    Sergei Shtylyov
     
  • The driver erroneously uses ata_get_cmd_descript() not only for printing out
    the ATA commands but also the protocol and DMA direction enums. Add functions
    for properly printing those out...

    Signed-off-by: Sergei Shtylyov
    Signed-off-by: Jeff Garzik

    Sergei Shtylyov
     
  • The caller expects this function to return the DMA channel number on success,
    while it returns 0...

    Signed-off-by: Sergei Shtylyov
    Signed-off-by: Jeff Garzik

    Sergei Shtylyov
     
  • Fix the following compilation errors/warnings:

    drivers/ata/sata_dwc_460ex.c:43:1: warning: "DRV_NAME" redefined
    In file included from drivers/ata/sata_dwc_460ex.c:38:
    drivers/ata/libata.h:31:1: warning: this is the location of the previous
    definition
    drivers/ata/sata_dwc_460ex.c:44:1: warning: "DRV_VERSION" redefined
    drivers/ata/libata.h:32:1: warning: this is the location of the previous
    definition
    drivers/ata/sata_dwc_460ex.c: In function `sata_dwc_exec_command_by_tag':
    drivers/ata/sata_dwc_460ex.c:1356: warning: passing argument 1 of
    `ata_get_cmd_descript' makes integer from pointer without a cast
    drivers/ata/sata_dwc_460ex.c: In function `sata_dwc_qc_issue':
    drivers/ata/sata_dwc_460ex.c:1476: warning: `err' is used uninitialized in this
    function
    drivers/ata/sata_dwc_460ex.c:1465: note: `err' was declared here
    drivers/ata/sata_dwc_460ex.c: In function `sata_dwc_qc_issue':
    drivers/ata/sata_dwc_460ex.c:1493: warning: passing argument 1 of
    `ata_get_cmd_descript' makes integer from pointer without a cast
    drivers/ata/sata_dwc_460ex.c: In function `sata_dwc_qc_prep':
    drivers/ata/sata_dwc_460ex.c:1537: error: `tag' undeclared (first use in this
    function)
    drivers/ata/sata_dwc_460ex.c:1537: error: (Each undeclared identifier is
    reported only once
    drivers/ata/sata_dwc_460ex.c:1537: error: for each function it appears in.)

    NB: error only happens if DEBUG_NCQ macro is defined...

    Signed-off-by: Sergei Shtylyov
    Signed-off-by: Jeff Garzik

    Sergei Shtylyov
     
  • Somehow the driver was committed with a bare number for the PIO mask, instead
    of ATA_PIO4...

    Signed-off-by: Sergei Shtylyov
    Signed-off-by: Jeff Garzik

    Sergei Shtylyov
     

01 Mar, 2011

1 commit


26 Aug, 2010

1 commit


17 Aug, 2010

1 commit


02 Aug, 2010

1 commit