Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 478e4e9d authored by Linus Torvalds's avatar Linus Torvalds
Browse files

Merge branch 'next-spi' of git://git.secretlab.ca/git/linux-2.6

* 'next-spi' of git://git.secretlab.ca/git/linux-2.6: (23 commits)
  spi: fix probe/remove section markings
  Add OMAP spi100k driver
  spi-imx: don't access struct device directly but use dev_get_platdata
  spi-imx: Add mx25 support
  spi-imx: use positive logic to distinguish cpu variants
  spi-imx: correct check for platform_get_irq failing
  ARM: NUC900: Add spi driver support for nuc900
  spi: SuperH MSIOF SPI Master driver V2
  spi: fix spidev compilation failure when VERBOSE is defined
  spi/au1550_spi: fix setupxfer not to override cfg with zeros
  spi/mpc8xxx: don't use __exit_p to wrap plat_mpc8xxx_spi_remove
  spi/i.MX: fix broken error handling for gpio_request
  spi/i.mx: drain MXC SPI transfer buffer when probing device
  MAINTAINERS: add SPI co-maintainer.
  spi/xilinx_spi: fix incorrect casting
  spi/mpc52xx-spi: minor cleanups
  xilinx_spi: add a platform driver using the xilinx_spi common module.
  xilinx_spi: add support for the DS570 IP.
  xilinx_spi: Switch to iomem functions and support little endian.
  xilinx_spi: Split into of driver and generic part.
  ...
parents 2205afa7 965346e3
Loading
Loading
Loading
Loading
+1 −0
Original line number Diff line number Diff line
@@ -5080,6 +5080,7 @@ F: drivers/char/specialix*

SPI SUBSYSTEM
M:	David Brownell <dbrownell@users.sourceforge.net>
M:	Grant Likely <grant.likely@secretlab.ca>
L:	spi-devel-general@lists.sourceforge.net
S:	Maintained
F:	Documentation/spi/
+35 −0
Original line number Diff line number Diff line
/*
 * arch/arm/mach-w90x900/include/mach/nuc900_spi.h
 *
 * Copyright (c) 2009 Nuvoton technology corporation.
 *
 * Wan ZongShun <mcuos.com@gmail.com>
 *
 * This program is free software; you can redistribute it and/or modify
 * it under the terms of the GNU General Public License as published by
 * the Free Software Foundation;version 2 of the License.
 *
 */

#ifndef __ASM_ARCH_SPI_H
#define __ASM_ARCH_SPI_H

extern void mfp_set_groupg(struct device *dev);

struct nuc900_spi_info {
	unsigned int num_cs;
	unsigned int lsb;
	unsigned int txneg;
	unsigned int rxneg;
	unsigned int divider;
	unsigned int sleep;
	unsigned int txnum;
	unsigned int txbitlen;
	int bus_num;
};

struct nuc900_spi_chip {
	unsigned char bits_per_word;
};

#endif /* __ASM_ARCH_SPI_H */
+38 −2
Original line number Diff line number Diff line
@@ -169,6 +169,12 @@ config SPI_OMAP24XX
	  SPI master controller for OMAP24xx/OMAP34xx Multichannel SPI
	  (McSPI) modules.

config SPI_OMAP_100K
	tristate "OMAP SPI 100K"
	depends on SPI_MASTER && (ARCH_OMAP850 || ARCH_OMAP730)
	help
	  OMAP SPI 100K master controller for omap7xx boards.

config SPI_ORION
	tristate "Orion SPI master (EXPERIMENTAL)"
	depends on PLAT_ORION && EXPERIMENTAL
@@ -220,6 +226,13 @@ config SPI_S3C24XX_GPIO
	  the inbuilt hardware cannot provide the transfer mode, or
	  where the board is using non hardware connected pins.

config SPI_SH_MSIOF
	tristate "SuperH MSIOF SPI controller"
	depends on SUPERH && HAVE_CLK
	select SPI_BITBANG
	help
	  SPI driver for SuperH MSIOF blocks.

config SPI_SH_SCI
	tristate "SuperH SCI SPI controller"
	depends on SUPERH
@@ -240,15 +253,38 @@ config SPI_TXX9
	  SPI driver for Toshiba TXx9 MIPS SoCs

config SPI_XILINX
	tristate "Xilinx SPI controller"
	depends on (XILINX_VIRTEX || MICROBLAZE) && EXPERIMENTAL
	tristate "Xilinx SPI controller common module"
	depends on HAS_IOMEM && EXPERIMENTAL
	select SPI_BITBANG
	select SPI_XILINX_OF if (XILINX_VIRTEX || MICROBLAZE)
	help
	  This exposes the SPI controller IP from the Xilinx EDK.

	  See the "OPB Serial Peripheral Interface (SPI) (v1.00e)"
	  Product Specification document (DS464) for hardware details.

	  Or for the DS570, see "XPS Serial Peripheral Interface (SPI) (v2.00b)"

config SPI_XILINX_OF
	tristate "Xilinx SPI controller OF device"
	depends on SPI_XILINX && (XILINX_VIRTEX || MICROBLAZE)
	help
	  This is the OF driver for the SPI controller IP from the Xilinx EDK.

config SPI_XILINX_PLTFM
	tristate "Xilinx SPI controller platform device"
	depends on SPI_XILINX
	help
	  This is the platform driver for the SPI controller IP
	  from the Xilinx EDK.

config SPI_NUC900
	tristate "Nuvoton NUC900 series SPI"
	depends on ARCH_W90X900 && EXPERIMENTAL
	select SPI_BITBANG
	help
	  SPI driver for Nuvoton NUC900 series ARM SoCs

#
# Add new SPI master controllers in alphabetical order above this line
#
+5 −0
Original line number Diff line number Diff line
@@ -22,6 +22,7 @@ obj-$(CONFIG_SPI_LM70_LLP) += spi_lm70llp.o
obj-$(CONFIG_SPI_PXA2XX)		+= pxa2xx_spi.o
obj-$(CONFIG_SPI_OMAP_UWIRE)		+= omap_uwire.o
obj-$(CONFIG_SPI_OMAP24XX)		+= omap2_mcspi.o
obj-$(CONFIG_SPI_OMAP_100K)		+= omap_spi_100k.o
obj-$(CONFIG_SPI_ORION)			+= orion_spi.o
obj-$(CONFIG_SPI_PL022)			+= amba-pl022.o
obj-$(CONFIG_SPI_MPC52xx_PSC)		+= mpc52xx_psc_spi.o
@@ -32,8 +33,12 @@ obj-$(CONFIG_SPI_S3C24XX_GPIO) += spi_s3c24xx_gpio.o
obj-$(CONFIG_SPI_S3C24XX)		+= spi_s3c24xx.o
obj-$(CONFIG_SPI_TXX9)			+= spi_txx9.o
obj-$(CONFIG_SPI_XILINX)		+= xilinx_spi.o
obj-$(CONFIG_SPI_XILINX_OF)		+= xilinx_spi_of.o
obj-$(CONFIG_SPI_XILINX_PLTFM)		+= xilinx_spi_pltfm.o
obj-$(CONFIG_SPI_SH_SCI)		+= spi_sh_sci.o
obj-$(CONFIG_SPI_SH_MSIOF)		+= spi_sh_msiof.o
obj-$(CONFIG_SPI_STMP3XXX)		+= spi_stmp.o
obj-$(CONFIG_SPI_NUC900)		+= spi_nuc900.o
# 	... add above this line ...

# SPI protocol drivers (device/link on bus)
+8 −2
Original line number Diff line number Diff line
@@ -237,8 +237,14 @@ static int au1550_spi_setupxfer(struct spi_device *spi, struct spi_transfer *t)
	unsigned bpw, hz;
	u32 cfg, stat;

	bpw = t ? t->bits_per_word : spi->bits_per_word;
	hz = t ? t->speed_hz : spi->max_speed_hz;
	bpw = spi->bits_per_word;
	hz = spi->max_speed_hz;
	if (t) {
		if (t->bits_per_word)
			bpw = t->bits_per_word;
		if (t->speed_hz)
			hz = t->speed_hz;
	}

	if (bpw < 4 || bpw > 24) {
		dev_err(&spi->dev, "setupxfer: invalid bits_per_word=%d\n",
Loading