Merge remote-tracking branch 'spi/fix/grant' into spi-linus
authorMark Brown <broonie@opensource.wolfsonmicro.com>
Mon, 13 May 2013 14:27:18 +0000 (18:27 +0400)
committerMark Brown <broonie@opensource.wolfsonmicro.com>
Mon, 13 May 2013 14:27:18 +0000 (18:27 +0400)
1  2 
drivers/spi/spi-atmel.c
drivers/spi/spi-davinci.c
drivers/spi/spi.c
include/linux/spi/spi.h

@@@ -1400,16 -846,9 +1400,16 @@@ static int atmel_spi_transfer(struct sp
                        }
                }
  
 +              if (xfer->bits_per_word > 8) {
 +                      if (xfer->len % 2) {
 +                              dev_dbg(&spi->dev, "buffer len should be 16 bits aligned\n");
 +                              return -EINVAL;
 +                      }
 +              }
 +
                /* FIXME implement these protocol options!! */
-               if (xfer->speed_hz) {
-                       dev_dbg(&spi->dev, "no protocol options yet\n");
+               if (xfer->speed_hz < spi->max_speed_hz) {
+                       dev_dbg(&spi->dev, "can't change speed in transfer\n");
                        return -ENOPROTOOPT;
                }
  
Simple merge
Simple merge
Simple merge