diff options
author | Alexander Aring <alex.aring@gmail.com> | 2015-09-21 12:24:25 +0300 |
---|---|---|
committer | Marcel Holtmann <marcel@holtmann.org> | 2015-09-22 12:51:21 +0300 |
commit | 78aedb6bfa43f43dacd8fc7b06452a87d33e3886 (patch) | |
tree | 712525d9c827bb46eb19745f8dee2458f76e8e9f /drivers/net | |
parent | a339e1849b9504b6e9631777e41ea2a240e58621 (diff) | |
download | linux-78aedb6bfa43f43dacd8fc7b06452a87d33e3886.tar.xz |
mrf24j40: remove spi settings overwrite
This patch removes spi settings while mrf24j40 probing. These settings
cannot be overwrite while device probing where spi controller should be
already configured. These settings need to be setup by device tree or
platform data.
Reviewed-by: Stefan Schmidt <stefan@osg.samsung.com>
Signed-off-by: Alexander Aring <alex.aring@gmail.com>
Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
Diffstat (limited to 'drivers/net')
-rw-r--r-- | drivers/net/ieee802154/mrf24j40.c | 8 |
1 files changed, 5 insertions, 3 deletions
diff --git a/drivers/net/ieee802154/mrf24j40.c b/drivers/net/ieee802154/mrf24j40.c index de63cba88fa0..41d9f5770148 100644 --- a/drivers/net/ieee802154/mrf24j40.c +++ b/drivers/net/ieee802154/mrf24j40.c @@ -746,9 +746,11 @@ static int mrf24j40_probe(struct spi_device *spi) if (!devrec->buf) goto err_register_device; - spi->mode = SPI_MODE_0; /* TODO: Is this appropriate for right here? */ - if (spi->max_speed_hz > MAX_SPI_SPEED_HZ) - spi->max_speed_hz = MAX_SPI_SPEED_HZ; + if (spi->max_speed_hz > MAX_SPI_SPEED_HZ) { + dev_warn(&spi->dev, "spi clock above possible maximum: %d", + MAX_SPI_SPEED_HZ); + return -EINVAL; + } mutex_init(&devrec->buffer_mutex); init_completion(&devrec->tx_complete); |