summaryrefslogtreecommitdiffstats
path: root/drivers/spi/spi-topcliff-pch.c
diff options
context:
space:
mode:
authorGrant Likely <grant.likely@secretlab.ca>2012-05-19 23:42:08 -0600
committerGrant Likely <grant.likely@secretlab.ca>2012-05-19 23:42:08 -0600
commit1e8a52e18cfb381bc9cc1f0b720540364d2a6edd (patch)
treec10c014afe3e7cab09773b8af214a0c2e85aac2e /drivers/spi/spi-topcliff-pch.c
parent71422f9e68d43f3fbc6c8939ca8d1b80aa2e4d1a (diff)
downloadop-kernel-dev-1e8a52e18cfb381bc9cc1f0b720540364d2a6edd.zip
op-kernel-dev-1e8a52e18cfb381bc9cc1f0b720540364d2a6edd.tar.gz
spi: By default setup spi_masters with 1 chipselect and dynamics bus number
Trivial simplification. Instead of requiring spi master drivers to always set the bus number (even when a dynamic number is desired), this patch modifies spi_alloc_master() to initialize num_chipselect to 1 (because there will always be at least one CS) and bus_num to -1 for dynamic allocation. This simplifies the code needed to be written for drivers. Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
Diffstat (limited to 'drivers/spi/spi-topcliff-pch.c')
-rw-r--r--drivers/spi/spi-topcliff-pch.c1
1 files changed, 0 insertions, 1 deletions
diff --git a/drivers/spi/spi-topcliff-pch.c b/drivers/spi/spi-topcliff-pch.c
index 77c4562..cd56dcf 100644
--- a/drivers/spi/spi-topcliff-pch.c
+++ b/drivers/spi/spi-topcliff-pch.c
@@ -1438,7 +1438,6 @@ static int __devinit pch_spi_pd_probe(struct platform_device *plat_dev)
plat_dev->id, data->io_remap_addr);
/* initialize members of SPI master */
- master->bus_num = -1;
master->num_chipselect = PCH_MAX_CS;
master->setup = pch_spi_setup;
master->transfer = pch_spi_transfer;
OpenPOWER on IntegriCloud