[PATCH v3] SPI: add CSR SiRFprimaII SPI controller driver

Jean-Christophe PLAGNIOL-VILLARD plagnioj at jcrosoft.com
Wed Feb 8 11:26:39 EST 2012


 +
> +static int spi_sirfsoc_setup(struct spi_device *spi)
> +{
> +	struct spi_bitbang *bitbang;
> +	struct sirfsoc_spi *sspi;
> +
> +	if (!spi->max_speed_hz)
> +		return -EINVAL;
> +
> +	sspi = spi_master_get_devdata(spi->master);
> +	bitbang = &sspi->bitbang;
why do you need this?
> +
> +	if (!spi->bits_per_word)
> +		spi->bits_per_word = 8;
> +
> +	return spi_sirfsoc_setup_transfer(spi, NULL);
> +}

Best Regards,
J.



More information about the linux-arm-kernel mailing list