From: Lennert Buytenhek Date: Fri, 3 Oct 2008 22:23:39 +0000 (-0700) Subject: orion_spi: fix handling of default transfer speed X-Git-Tag: v2.6.27-rc9~21 X-Git-Url: http://pilppa.com/gitweb/?a=commitdiff_plain;h=f2fe1638f624467ae583b1a41a01804405f29eee;p=linux-2.6-omap-h63xx.git orion_spi: fix handling of default transfer speed Accept zero (the default!) as a per-transfer clock speed override. Signed-off-by: Lennert Buytenhek Signed-off-by: David Brownell Signed-off-by: Andrew Morton Signed-off-by: Linus Torvalds --- diff --git a/drivers/spi/orion_spi.c b/drivers/spi/orion_spi.c index c4eaacd6e55..b872bfaf4bd 100644 --- a/drivers/spi/orion_spi.c +++ b/drivers/spi/orion_spi.c @@ -427,7 +427,7 @@ static int orion_spi_transfer(struct spi_device *spi, struct spi_message *m) goto msg_rejected; } - if (t->speed_hz < orion_spi->min_speed) { + if (t->speed_hz && t->speed_hz < orion_spi->min_speed) { dev_err(&spi->dev, "message rejected : " "device min speed (%d Hz) exceeds "