Skip to content

Commit

Permalink
spi: fix use of set_cs in spi_s3c24xx driver
Browse files Browse the repository at this point in the history
It turns out that the last patch to change set_cs to be kept in the
controller's structure instead of the platform data was an incomplete
change, and did not change the references to platfrom data in the setup
xfer code.  (This can prevent an oops.)

Reported-by: <[email protected]>
Signed-off-by: Ben Dooks <[email protected]>
Signed-off-by: David Brownell <[email protected]>
Signed-off-by: Andrew Morton <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>
  • Loading branch information
Ben Dooks authored and Linus Torvalds committed Apr 17, 2007
1 parent 88ed39b commit 3d2c5b4
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions drivers/spi/spi_s3c24xx.c
Original file line number Diff line number Diff line change
Expand Up @@ -77,7 +77,7 @@ static void s3c24xx_spi_chipsel(struct spi_device *spi, int value)

switch (value) {
case BITBANG_CS_INACTIVE:
hw->pdata->set_cs(hw->pdata, spi->chip_select, cspol^1);
hw->set_cs(hw->pdata, spi->chip_select, cspol^1);
break;

case BITBANG_CS_ACTIVE:
Expand All @@ -98,7 +98,7 @@ static void s3c24xx_spi_chipsel(struct spi_device *spi, int value)
/* write new configration */

writeb(spcon, hw->regs + S3C2410_SPCON);
hw->pdata->set_cs(hw->pdata, spi->chip_select, cspol);
hw->set_cs(hw->pdata, spi->chip_select, cspol);

break;
}
Expand Down

0 comments on commit 3d2c5b4

Please sign in to comment.