- 08 2月, 2013 1 次提交
-
-
由 Mika Westerberg 提交于
The PXA SPI driver uses PXA platform specific private DMA implementation which does not work on non-PXA platforms. In order to use this driver on other platforms we break out the private DMA implementation into a separate file that gets compiled only when CONFIG_SPI_PXA2XX_PXADMA is set. The DMA functions are stubbed out if there is no DMA implementation selected (i.e we are building on non-PXA platform). While we are there we can kill the dummy DMA bits in pxa2xx_spi.h as they are not needed anymore for CE4100. Once this is done we can add the generic DMA engine support to the driver that allows usage of any DMA controller that implements DMA engine API. Signed-off-by: NMika Westerberg <mika.westerberg@linux.intel.com> Acked-by: NLinus Walleij <linus.walleij@linaro.org> Tested-by: NLu Cao <lucao@marvell.com> Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-
- 26 1月, 2013 7 次提交
-
-
由 Matthias Brugger 提交于
This patch allows the board code to define SPI devices which needs to toggle the chip select after every word send. This is needed to get a better resolution reading e.g. an ADC data stream. Apart from that, as in the normal code CS is controlled by software, a transfer is done much faster. Signed-off-by: NMatthias Brugger <matthias.bgg@gmail.com> Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-
由 Matthias Brugger 提交于
This patch fixes some indentation errors. Signed-off-by: NMatthias Brugger <matthias.bgg@gmail.com> Reviewed-by: NJarkko Nikula <jarkko.nikula@bitmer.com> Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-
由 Maxime Ripard 提交于
The bindings assumed that the gpios properties were always there, which made the NO_TX and NO_RX mode not usable from device tree. Add extra checks to make sure that the driver can work if either MOSI or MISO is not used. Signed-off-by: NMaxime Ripard <maxime.ripard@free-electrons.com> Cc: Mark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-
由 Mika Westerberg 提交于
Convert clk_enable() to clk_prepare_enable() and clk_disable() to clk_disable_unprepare() respectively in order to support the common clk framework. Otherwise we get warnings on the console as the clock is not prepared before it is enabled. In addition we must cache the maximum clock rate to drv_data->max_clk_rate at probe time because clk_get_rate() cannot be called in tasklet context. Signed-off-by: NMika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-
由 Mika Westerberg 提交于
The SPI core provides infrastructure for standard message queueing so use that instead of handling everything in the driver. This simplifies the driver. Signed-off-by: NMika Westerberg <mika.westerberg@linux.intel.com> Acked-by: NLinus Walleij <linus.walleij@linaro.org> Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-
由 Mika Westerberg 提交于
Fix following warnings seen when compiling 64-bit: drivers/spi/spi-pxa2xx.c: In function ‘map_dma_buffers’: drivers/spi/spi-pxa2xx.c:384:7: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast] drivers/spi/spi-pxa2xx.c:384:40: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast] drivers/spi/spi-pxa2xx.c: In function ‘pxa2xx_spi_probe’: drivers/spi/spi-pxa2xx.c:1572:34: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast] drivers/spi/spi-pxa2xx.c:1572:34: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast] drivers/spi/spi-pxa2xx.c:1572:34: warning: cast from pointer to integer of different size [-Wpointer-to-int-cast] drivers/spi/spi-pxa2xx.c:1572:27: warning: cast to pointer from integer of different size [-Wint-to-pointer-cast] Signed-off-by: NMika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-
由 Mika Westerberg 提交于
We are going to use it on 64-bit kernel on Intel Lynxpoint so make sure we can build it into such kernel. Signed-off-by: NMika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-
- 14 1月, 2013 1 次提交
-
-
由 Guennadi Liakhovetski 提交于
Add a pointer variable to make spi_bitbang_start() look simpler. Signed-off-by: NGuennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-
- 08 1月, 2013 3 次提交
-
-
由 Mika Westerberg 提交于
The spi-pxa2xx-pci glue driver had to implement pxa_ssp_request()/free() in order to support the spi-pxa2xx platform driver. Since the ACPI enabled platforms can use the same platform driver we would need to implement pxa_ssp_request()/free() in some central place that can be shared by the ACPI and PCI glue code. Instead of doing that we can make pxa_ssp_request()/free() to be available only when CONFIG_ARCH_PXA is set. On other arches these are being stubbed out in preference to passing the ssp_device from the platform data directly. We also change the SPI bus number to be taken from ssp->port_id instead of platform device id. This way the supporting code that passes the ssp can decide the number (or it can set it to the same as pdev->id). Signed-off-by: NMika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-
由 Mika Westerberg 提交于
Instead of open-coding all the error management in the driver we can take advantage of the pcim_* interfaces that release the resources automatically. We also use platform_device_register_full() to register the platform device because it allows us to create and register the platform device at one go, simplifying the error management. This a preparatory step for getting rid of pxa_ssp_request()/free() which we will do in the next patch. Signed-off-by: NMika Westerberg <mika.westerberg@linux.intel.com> Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-
由 Mark Brown 提交于
Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-
- 19 12月, 2012 1 次提交
-
-
由 Cyril Roelandt 提交于
According to its documentation, clk_get() returns a "valid IS_ERR() condition containing errno", so we should call IS_ERR() rather than a NULL check. Signed-off-by: NCyril Roelandt <tipecaml@gmail.com> Acked-by: NKuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
- 18 12月, 2012 1 次提交
-
-
Use the newly introduce cs-gpios dt support on atmel. We do not use the hardware cs as it's wired and has bugs and limitations. As the controller believes that only active-low devices/systems exists. Signed-off-by: NJean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Acked-by: NNicolas Ferre <nicolas.ferre@atmel.com> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
- 15 12月, 2012 3 次提交
-
-
由 David Daney 提交于
To get modprobe to automatically load the proper modules, we need to prefix things with "spi:". Partially based on Grant Likely's suggestions. Signed-off-by: NDavid Daney <david.daney@cavium.com> [grant.likely: reworked because drivers/of/of_spi.c has been removed] Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
由 Kyoungil Kim 提交于
Setting SW_RST does TX/RX FIFO flush. After FIFO flush, SW_RST should be cleared. The above setting and clearing SW_RST operation should be done after spi channel off. Signed-off-by: NKyoungil Kim <ki0351.kim@samsung.com> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
由 Kyoungil Kim 提交于
During all transfers in one message, the device will not be chagned. So we don't need to deassert chipselect during one message. Signed-off-by: NKyoungil Kim <ki0351.kim@samsung.com> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
- 11 12月, 2012 1 次提交
-
-
由 Andreas Larsson 提交于
The spi support code works on SPARC too. No reason to exclude it from the party. Signed-off-by: NAndreas Larsson <andreas@gaisler.com> Acked-by: NDavid S. Miller <davem@davemloft.net> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
- 08 12月, 2012 1 次提交
-
-
由 Grant Likely 提交于
CONFIG_HOTPLUG is going away as an option. As result the __dev* markings will be going away. Remove use of __devinit, __devexit_p, __devinitdata, __devinitconst, and __devexit. Bill Pemberton has done most of the legwork on this series. I've used his script to purge the attributes from the drivers/gpio tree. Reported-by: NBill Pemberton <wfp5p@virginia.edu> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
- 07 12月, 2012 2 次提交
-
-
由 Lars-Peter Clausen 提交于
This patch allows to specify that a SPI device is connected in 3-wire mode via device tree. Signed-off-by: NLars-Peter Clausen <lars@metafoo.de> Acked-by: NRob Herring <rob.herring@calxeda.com> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
由 Grant Likely 提交于
Fix problem discovered with sparse: + drivers/spi/spi.c:1554:37: sparse: incompatible types in comparison expression (different signedness) drivers/spi/spi.c: In function 'spi_write_then_read': drivers/spi/spi.c:1554:23: warning: comparison of distinct pointer types lacks a cast [enabled by default] The change to SPI_BUFSIZ was introduced in commit b3a223ee, "spi: Remove SPI_BUFSIZ restriction on spi_write_then_read()" Cc: Mark Brown <broonie@opensource.wolfsonmicro.com> Reported-by: Nkbuild test robot <fengguang.wu@intel.com> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
- 06 12月, 2012 6 次提交
-
-
由 Jason Gunthorpe 提交于
Support these transfer modes from the SPI layer by setting the appropriate register bits before doing the transfer. This was tested on the Marvell kirkwood SOC that uses this driver. Reviewed-by: NJason Gunthorpe <jgunthorpe@obsidianresearch.com> Signed-off-by: NRolf Manderscheid <rvm@obsidianresearch.com> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
由 Bastian Hecht 提交于
The MSIOF hardware block is used in the SH Mobile series as well, so we add it here. Signed-off-by: NBastian Hecht <hechtb@gmail.com> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
由 Bastian Hecht 提交于
clk_get() no longer needs a character string for associating the right clock as this is done via the device struct now. Signed-off-by: NBastian Hecht <hechtb@gmail.com> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
由 Mark Brown 提交于
In order to avoid constantly allocating and deallocating there is a fixed buffer which spi_write_then_read() uses for transfers, with an early error check to ensure that the transfer fits within the buffer. This limits the size of transfers to this size, currently max(32, SMP_CACHE_BYTES). Since we can dynamically allocate and in fact already have a fallback to do so when there is contention for the fixed buffer remove this restriction and instead dynamically allocate a suitably sized buffer if the transfer won't fit. Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
由 Wolfram Sang 提交于
This driver is obsolete and can't even be built anymore since the platform it depends has been removed. The STMP series is completely covered by the MXS platform these days, so spi-mxs can be used instead. Signed-off-by: NWolfram Sang <w.sang@pengutronix.de> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
由 Alexander Shiyan 提交于
This patch add new driver for CLPS711X SPI master controller. Due to platform limitations driver supports only 8 bit transfer mode. Chip select control is handled via GPIO. Signed-off-by: NAlexander Shiyan <shc_work@mail.ru> Acked-by: NArnd Bergmann <arnd@arndb.de> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
- 02 12月, 2012 2 次提交
-
-
由 Sachin Kamat 提交于
linux/err.h was included twice. Signed-off-by: NSachin Kamat <sachin.kamat@linaro.org> Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-
由 Shubhrajyoti D 提交于
Fix the below warning drivers/spi/spi-omap2-mcspi.c:336:34: warning: symbol 'tx' shadows an earlier one drivers/spi/spi-omap2-mcspi.c:327:12: originally declared here So delete the u8 tx as it is assigned and not used(resigned afterwards). Signed-off-by: NShubhrajyoti D <shubhrajyoti@ti.com> Acked-by: NPeter Korsgaard <jacmet@sunsite.dk> Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-
- 30 11月, 2012 2 次提交
-
-
由 Mika Westerberg 提交于
ACPI 5 introduced SPISerialBus resource that allows us to enumerate and configure the SPI slave devices behind the SPI controller. This patch adds support for this to the SPI core. In addition we bind ACPI nodes to SPI devices. This makes it possible for the slave drivers to get the ACPI handle for further configuration. Signed-off-by: NMika Westerberg <mika.westerberg@linux.intel.com> Acked-by: NGrant Likely <grant.likely@secretlab.ca> Signed-off-by: NRafael J. Wysocki <rafael.j.wysocki@intel.com>
-
由 Alexander Sverdlin 提交于
Currently of_register_spi_devices() function registers all SPI devices, independetly from their status property in device tree. According to "ePAPR 1.1" spec, device should only be registered if there is no "status" property, or it has "ok" (or "okay") value (see of_device_is_available()). In case of "platform devices", of_platform_device_create_pdata() checks for "status" and ensures that disabled devices are not pupulated. But such check for SPI buses was missing until now. Fix it. Signed-off-by: NAlexander Sverdlin <alexander.sverdlin@sysgo.com> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
- 23 11月, 2012 1 次提交
-
-
由 Phil Edworthy 提交于
The current HSPI driver used automatic CS control, leading to CS active for each byte transmitted. This patch changes the driver to manual CS control, and ensures CS is active thoughout a whole message. Additionally, it uses the cs_change field to determine if CS is disabled between transfers in the message. Signed-off-by: NPhil Edworthy <phil.edworthy@renesas.com> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
- 22 11月, 2012 1 次提交
-
-
This will allow to use gpio for chip select with no modification in the driver binding When use the cs-gpios, the gpio number will be passed via the cs_gpio field and the number of chip select will automatically increased with max(hw cs, gpio cs). So if for example the controller has 2 CS lines, and the cs-gpios property looks like this: cs-gpios = <&gpio1 0 0> <0> <&gpio1 1 0> <&gpio1 2 0>; Then it should be configured so that num_chipselect = 4 with the following mapping: cs0 : &gpio1 0 0 cs1 : native cs2 : &gpio1 1 0 cs3 : &gpio1 2 0 Signed-off-by: NJean-Christophe PLAGNIOL-VILLARD <plagnioj@jcrosoft.com> Cc: devicetree-discuss@lists.ozlabs.org Cc: spi-devel-general@lists.sourceforge.net Signed-off-by: NRichard Genoud <richard.genoud@gmail.com> [grant.likely: fixed up type of cs count so min() can do type checking] Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
- 14 11月, 2012 5 次提交
-
-
由 Wei Yongjun 提交于
Remove duplicated include. Signed-off-by: NWei Yongjun <yongjun_wei@trendmicro.com.cn> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
由 Guennadi Liakhovetski 提交于
Use a proper list iterator instead of an open-coded loop and remove a superfluous list head initialisation. Signed-off-by: NGuennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
由 Guennadi Liakhovetski 提交于
This patch makes a loop look cleaner by replacing a "break" and a "continue" in its body by a single "if". Signed-off-by: NGuennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: NGrant Likely <grant.likely@secretlab.ca>
-
由 Daniel Mack 提交于
0384e90b ("spi/mcspi: allow configuration of pin directions") did what it claimed to do the wrong way around. D0/D1 is configured as output by *clearing* the bits in the conf registers, hence also breaking the former default behaviour. Fix this before that change is merged to mainline. Signed-off-by: NDaniel Mack <zonque@gmail.com> Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-
由 Laxman Dewangan 提交于
NVIDIA's Tegra20 have the SPI (SFLASH) controller to interface with spi flash device which is used for system boot. Add the spi driver for this controller. Signed-off-by: NLaxman Dewangan <ldewangan@nvidia.com> Acked-by: NStephen Warren <swarren@nvidia.com> Tested-by: NStephen Warren <swarren@nvidia.com> Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-
- 10 11月, 2012 2 次提交
-
-
由 Laxman Dewangan 提交于
Currently the master->setup() is called unconditionally. The assumption is that every driver need to implement this callback. This encourages drivers to populate empty functions to prevent crashing. This patch prevents the call of master->setup() if it is not populated. Signed-off-by: NLaxman Dewangan <ldewangan@nvidia.com> Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-
由 Laxman Dewangan 提交于
Sequence compatible list for tegra20-slink driver to first look for Tegra30 and then Tegra20. Tegra30 have additional feature in HW which need to be utilize if it is provided from DT. Signed-off-by: NLaxman Dewangan <ldewangan@nvidia.com> Signed-off-by: NMark Brown <broonie@opensource.wolfsonmicro.com>
-