[01/16] spi: txx9: Use transfer speed unconditionally
diff mbox

Message ID 1442323588-29642-1-git-send-email-jarkko.nikula@linux.intel.com
State Accepted
Commit fc306de9b54e94a2949fee452741c00259d7dd4a
Headers show

Commit Message

Jarkko Nikula Sept. 15, 2015, 1:26 p.m. UTC
SPI core validates the transfer speed and defaults to spi->max_speed_hz in
case the transfer speed is not set.

Signed-off-by: Jarkko Nikula <jarkko.nikula@linux.intel.com>
---
 drivers/spi/spi-txx9.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Mark Brown Sept. 16, 2015, 7:52 p.m. UTC | #1
On Tue, Sep 15, 2015 at 04:26:13PM +0300, Jarkko Nikula wrote:
> SPI core validates the transfer speed and defaults to spi->max_speed_hz in
> case the transfer speed is not set.

Please don't send large collections of unrelated changes as a single
series - this isn't one change done to a lot of drivers, this is a bunch
of unrelated changes.  Having things grouped into a patch series affects
how they get handled and reviewed, if this is misleading it can get in
the way (eg, not reading patches after one that has problems).

Patch
diff mbox

diff --git a/drivers/spi/spi-txx9.c b/drivers/spi/spi-txx9.c
index 9190124b6d90..d69f8f8f3fa6 100644
--- a/drivers/spi/spi-txx9.c
+++ b/drivers/spi/spi-txx9.c
@@ -181,7 +181,7 @@  static void txx9spi_work_one(struct txx9spi *c, struct spi_message *m)
 		u32 data;
 		unsigned int len = t->len;
 		unsigned int wsize;
-		u32 speed_hz = t->speed_hz ? : spi->max_speed_hz;
+		u32 speed_hz = t->speed_hz;
 		u8 bits_per_word = t->bits_per_word;
 
 		wsize = bits_per_word >> 3; /* in bytes */