summaryrefslogtreecommitdiff
path: root/include/linux/spi/dw_spi.h
diff options
context:
space:
mode:
authorGeorge Shore <george@georgeshore.com>2010-01-21 11:40:48 +0000
committerGrant Likely <grant.likely@secretlab.ca>2010-01-21 07:24:29 -0700
commit83fe518a839e317480e50a138ef4acd73510d7ce (patch)
treea13e5fba61277441066aaf371cd378af4149ac8a /include/linux/spi/dw_spi.h
parentc587b6fa05106606053fc5e8e344f07cd34ace23 (diff)
downloadlwn-83fe518a839e317480e50a138ef4acd73510d7ce.tar.gz
lwn-83fe518a839e317480e50a138ef4acd73510d7ce.zip
spi/dw_spi: enable platform specific chipselect.
The driver core allows for a platform-specific chipselect assert/deassert function, however the chipselect function in the core doesn't take advantage of this fact. This enables the use of a custom function, should it be defined. Signed-off-by: George Shore <george@georgeshore.com> Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'include/linux/spi/dw_spi.h')
-rw-r--r--include/linux/spi/dw_spi.h4
1 files changed, 4 insertions, 0 deletions
diff --git a/include/linux/spi/dw_spi.h b/include/linux/spi/dw_spi.h
index 1a127a31e017..cc813f95a2f2 100644
--- a/include/linux/spi/dw_spi.h
+++ b/include/linux/spi/dw_spi.h
@@ -172,6 +172,10 @@ static inline void spi_chip_sel(struct dw_spi *dws, u16 cs)
{
if (cs > dws->num_cs)
return;
+
+ if (dws->cs_control)
+ dws->cs_control(1);
+
dw_writel(dws, ser, 1 << cs);
}