From: Anatolij Gustschin Date: Mon, 14 Jan 2013 20:27:00 +0000 (+0100) Subject: spi/spi-mpc512x-psc: init mode bits supported by the driver X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=c88dd349b5a83c9efa4030176a5184a9a1440475;p=GitHub%2Fexynos8895%2Fandroid_kernel_samsung_universal8895.git spi/spi-mpc512x-psc: init mode bits supported by the driver The driver should setup mode bits it supports, otherwise adding an SPI device might fail even if the driver supports the requested SPI mode. Signed-off-by: Anatolij Gustschin Signed-off-by: Grant Likely --- diff --git a/drivers/spi/spi-mpc512x-psc.c b/drivers/spi/spi-mpc512x-psc.c index 88e544151f6f..89480b281d74 100644 --- a/drivers/spi/spi-mpc512x-psc.c +++ b/drivers/spi/spi-mpc512x-psc.c @@ -438,6 +438,7 @@ static int mpc512x_psc_spi_do_probe(struct device *dev, u32 regaddr, master->num_chipselect = pdata->max_chipselect; } + master->mode_bits = SPI_CPOL | SPI_CPHA | SPI_CS_HIGH | SPI_LSB_FIRST; master->setup = mpc512x_psc_spi_setup; master->transfer = mpc512x_psc_spi_transfer; master->cleanup = mpc512x_psc_spi_cleanup;