lkml.org 
[lkml]   [2012]   [Jun]   [11]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH for v3.5 1/2] misc: mei: Disable MSI when IRQ registration fails
    Date
    From: Samuel Ortiz <sameo@linux.intel.com>

    Since MSI is enabled right before that, we should disable it when
    registration fails.

    Signed-off-by: Samuel Ortiz <sameo@linux.intel.com>
    Signed-off-by: Tomas Winkler <tomas.winkler@intel.com>
    ---
    drivers/misc/mei/main.c | 4 ++--
    1 files changed, 2 insertions(+), 2 deletions(-)

    diff --git a/drivers/misc/mei/main.c b/drivers/misc/mei/main.c
    index a5a17e7..7de1389 100644
    --- a/drivers/misc/mei/main.c
    +++ b/drivers/misc/mei/main.c
    @@ -992,7 +992,7 @@ static int __devinit mei_probe(struct pci_dev *pdev,
    if (err) {
    dev_err(&pdev->dev, "request_threaded_irq failure. irq = %d\n",
    pdev->irq);
    - goto unmap_memory;
    + goto disable_msi;
    }
    INIT_DELAYED_WORK(&dev->timer_work, mei_timer);
    if (mei_hw_init(dev)) {
    @@ -1023,8 +1023,8 @@ release_irq:
    mei_disable_interrupts(dev);
    flush_scheduled_work();
    free_irq(pdev->irq, dev);
    +disable_msi:
    pci_disable_msi(pdev);
    -unmap_memory:
    pci_iounmap(pdev, dev->mem_addr);
    free_device:
    kfree(dev);
    --
    1.7.4.4


    \
     
     \ /
      Last update: 2012-06-11 12:42    [W:0.024 / U:30.228 seconds]
    ©2003-2016 Jasper Spaans. hosted at Digital OceanAdvertise on this site