[3.11.y.z extended stable] Patch "spi/pxa2xx: initialize DMA channels to -1 to prevent inadvertent" has been added to staging queue
Luis Henriques
luis.henriques at canonical.com
Wed Feb 5 13:13:32 UTC 2014
This is a note to let you know that I have just added a patch titled
spi/pxa2xx: initialize DMA channels to -1 to prevent inadvertent
to the linux-3.11.y-queue branch of the 3.11.y.z extended stable tree
which can be found at:
http://kernel.ubuntu.com/git?p=ubuntu/linux.git;a=shortlog;h=refs/heads/linux-3.11.y-queue
If you, or anyone else, feels it should not be added to this tree, please
reply to this email.
For more information about the 3.11.y.z tree, see
https://wiki.ubuntu.com/Kernel/Dev/ExtendedStable
Thanks.
-Luis
------
>From a6d7bad4a755d7066e93442ee6f485eb6b48f35d Mon Sep 17 00:00:00 2001
From: Mika Westerberg <mika.westerberg at linux.intel.com>
Date: Mon, 13 Jan 2014 11:17:04 +0200
Subject: spi/pxa2xx: initialize DMA channels to -1 to prevent inadvertent
match
commit 483c319188c74e82b29a0ed7a7fa7065570f2193 upstream.
Commit cddb339badb0 (spi/pxa2xx: convert to dma_request_slave_channel_compat())
converted the driver to use ACPI provided DMA helpers but it forgot to
initialize the platform data for the channels to -1. Failing to do so will
result inadvertent match in the filter function because 0 is a valid
channel number.
Prevent this from happening by initializing both platform data channels
correctly to -1.
Fixes: cddb339badb0 (spi/pxa2xx: convert to dma_request_slave_channel_compat())
Signed-off-by: Mika Westerberg <mika.westerberg at linux.intel.com>
Signed-off-by: Mark Brown <broonie at linaro.org>
Signed-off-by: Luis Henriques <luis.henriques at canonical.com>
---
drivers/spi/spi-pxa2xx.c | 2 ++
1 file changed, 2 insertions(+)
diff --git a/drivers/spi/spi-pxa2xx.c b/drivers/spi/spi-pxa2xx.c
index 46e481f..b0e1331 100644
--- a/drivers/spi/spi-pxa2xx.c
+++ b/drivers/spi/spi-pxa2xx.c
@@ -1064,6 +1064,8 @@ pxa2xx_spi_acpi_get_pdata(struct platform_device *pdev)
pdata->num_chipselect = 1;
pdata->enable_dma = true;
+ pdata->tx_chan_id = -1;
+ pdata->rx_chan_id = -1;
return pdata;
}
--
1.8.3.2
More information about the kernel-team
mailing list