diff options
author | David S. Miller <davem@davemloft.net> | 2013-04-07 18:37:01 -0400 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-04-07 18:37:01 -0400 |
commit | d978a6361ad13f1f9694fcb7b5852d253a544d92 (patch) | |
tree | 8e8a8c62286fab2c044c4b53563222c1b66d7cb0 /drivers/spi/spi.c | |
parent | 8303e699f7089a1cd1421750fb33f289e5f3e1b9 (diff) | |
parent | cb28ea3b13b86fb23448525f34720e659bda7aa8 (diff) |
Merge git://git.kernel.org/pub/scm/linux/kernel/git/davem/net
Conflicts:
drivers/nfc/microread/mei.c
net/netfilter/nfnetlink_queue_core.c
Pull in 'net' to get Eric Biederman's AF_UNIX fix, upon which
some cleanups are going to go on-top.
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/spi/spi.c')
-rw-r--r-- | drivers/spi/spi.c | 17 |
1 files changed, 8 insertions, 9 deletions
diff --git a/drivers/spi/spi.c b/drivers/spi/spi.c index f996c600eb8..004b10f184d 100644 --- a/drivers/spi/spi.c +++ b/drivers/spi/spi.c @@ -543,17 +543,16 @@ static void spi_pump_messages(struct kthread_work *work) /* Lock queue and check for queue work */ spin_lock_irqsave(&master->queue_lock, flags); if (list_empty(&master->queue) || !master->running) { - if (master->busy && master->unprepare_transfer_hardware) { - ret = master->unprepare_transfer_hardware(master); - if (ret) { - spin_unlock_irqrestore(&master->queue_lock, flags); - dev_err(&master->dev, - "failed to unprepare transfer hardware\n"); - return; - } + if (!master->busy) { + spin_unlock_irqrestore(&master->queue_lock, flags); + return; } master->busy = false; spin_unlock_irqrestore(&master->queue_lock, flags); + if (master->unprepare_transfer_hardware && + master->unprepare_transfer_hardware(master)) + dev_err(&master->dev, + "failed to unprepare transfer hardware\n"); return; } @@ -984,7 +983,7 @@ static void acpi_register_spi_devices(struct spi_master *master) acpi_status status; acpi_handle handle; - handle = ACPI_HANDLE(&master->dev); + handle = ACPI_HANDLE(master->dev.parent); if (!handle) return; |