Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 291965
b: refs/heads/master
c: 35faa55
h: refs/heads/master
i:
  291963: 441c613
v: v3
  • Loading branch information
Sebastian Andrzej Siewior authored and Grant Likely committed Mar 15, 2012
1 parent bd69109 commit e91fd00
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: bb9c5687e8cd02d6f8a3aea40c118b439cb09501
refs/heads/master: 35faa55cff56441477973e454f62408714f35cd3
4 changes: 2 additions & 2 deletions trunk/drivers/spi/spi-fsl-espi.c
Original file line number Diff line number Diff line change
Expand Up @@ -180,15 +180,15 @@ static int fsl_espi_setup_transfer(struct spi_device *spi,

if ((mpc8xxx_spi->spibrg / hz) > 64) {
cs->hw_mode |= CSMODE_DIV16;
pm = (mpc8xxx_spi->spibrg - 1) / (hz * 64) + 1;
pm = DIV_ROUND_UP(mpc8xxx_spi->spibrg, hz * 16 * 4);

WARN_ONCE(pm > 16, "%s: Requested speed is too low: %d Hz. "
"Will use %d Hz instead.\n", dev_name(&spi->dev),
hz, mpc8xxx_spi->spibrg / 1024);
if (pm > 16)
pm = 16;
} else {
pm = (mpc8xxx_spi->spibrg - 1) / (hz * 4) + 1;
pm = DIV_ROUND_UP(mpc8xxx_spi->spibrg, hz * 4);
}
if (pm)
pm--;
Expand Down

0 comments on commit e91fd00

Please sign in to comment.