summaryrefslogtreecommitdiff
path: root/drivers/spi/pxa2xx_spi.c
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2009-06-11 12:58:01 +0400
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2009-06-11 12:58:01 +0400
commit4894e4aca82aca927d0404ce61f021f790de4b1e (patch)
treebbe0d083829f5858295298f188d885367cf4b1f6 /drivers/spi/pxa2xx_spi.c
parent05e882f890038c702a4f15d385135d03cf74ad48 (diff)
parent07a2039b8eb0af4ff464efd3dfd95de5c02648c6 (diff)
downloadlinux-4894e4aca82aca927d0404ce61f021f790de4b1e.tar.xz
Merge commit 'v2.6.30' into next
Diffstat (limited to 'drivers/spi/pxa2xx_spi.c')
-rw-r--r--drivers/spi/pxa2xx_spi.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/drivers/spi/pxa2xx_spi.c b/drivers/spi/pxa2xx_spi.c
index 885194a07418..3f3c08c6ba4e 100644
--- a/drivers/spi/pxa2xx_spi.c
+++ b/drivers/spi/pxa2xx_spi.c
@@ -1373,6 +1373,9 @@ static void cleanup(struct spi_device *spi)
{
struct chip_data *chip = spi_get_ctldata(spi);
+ if (!chip)
+ return;
+
if (gpio_is_valid(chip->gpio_cs))
gpio_free(chip->gpio_cs);