summaryrefslogtreecommitdiffstats
path: root/drivers/spi
Commit message (Collapse)AuthorAgeFilesLines
* spi: remove more dev->power.power_state usageDavid Brownell2008-02-062-28/+0
| | | | | | | | | | | Remove some more references to dev->power.power_state. That field is overdue for removal, but we can't do that while it's still referenced in the kernel. The only reason to update it was to make the /sys/devices/.../power/state files (now removed) work better. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi_bfin: headers are not for changelogsMike Frysinger2008-02-061-29/+3
| | | | | | | | | | | Use simpler comment headers, and strip out information that is maintained in GIT history Signed-off-by: Mike Frysinger <michael.frysinger@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi_bfin: wait for tx to complete on write pathsSonic Zhang2008-02-061-12/+10
| | | | | | | | | | SPI writes should also not return until the last bit is sent. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi_bfin: wait for tx to complete on full duplex pathsBryan Wu2008-02-061-15/+3
| | | | | | | | | | | | | Full duplex SPI operation should not read a dummy byte at the first transfer. Bug and fix by Jean-Christian de Rivaz <jc@eclis.ch>: http://blackfin.uclinux.org/gf/project/uclinux-dist/tracker/?action=TrackerItemEdit&tracker_item_id=3678 Signed-off-by: Jean-Christian de Rivaz <jc@eclis.ch> Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi_bfin: wait for tx to complete on some cs_chg pathsBryan Wu2008-02-061-28/+12
| | | | | | | | | | | | | PBX 2 SPI devices need the nonstandard "cs change per word" mechanism. This patch is one of three updating this driver to make the last data bits get sent before advancing the transfer ... in this case, before the chipselect gets deactivated. Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi_bfin: use more useful GPIO labelsBryan Wu2008-02-061-1/+1
| | | | | | | | | | | Use the SPI driver's name when requesting gpio lines. When there are gpio conflicts, this helps to narrow down the problems; "bfin-spi" is not informative. Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi_bfin: remove useless fault pathBryan Wu2008-02-061-13/+2
| | | | | | | | | | | Remove useless return status check in restore_state function. Issue was pointed out by Michael. Cc: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi: omap2_mcspi handles omap3 tooGirish2008-02-062-4/+39
| | | | | | | | | This adds driver OMAP SPI specific changes to support OMAP 3430 Signed-off-by: Girish S G <girishsg@ti.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi: SuperH SPI using SCIMagnus Damm2008-02-063-0/+213
| | | | | | | | | | | | | Add support for SPI over SCI pins. SCI is a very simple serial controller block that can be found on older SuperH processors. In theory it is possible to use the SCI hardware block in syncronous mode, but this version of the driver simply hooks up the bit banging code on the SCI pins. Signed-off-by: Magnus Damm <damm@igel.co.jp> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Cc: Paul Mundt <lethal@linux-sh.org> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi: s3c drivers shouldn't care about spi_board_infoDavid Brownell2008-02-062-24/+0
| | | | | | | | | | | | | | | | The two S3C SPI master drivers got merged without much review, so I just noticed that they're doing something that the SPI core code is responsible for, rather than any adapter driver: they try to register SPI devices. This removes that support from those drivers so they act normally. Interestingly, none of the current boards are affected. So it's a net code shrink with no loss of functionality. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Cc: Ben Dooks <ben-linux@fluff.org> Cc: Russell King <rmk@arm.linux.org.uk> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* atmel_spi: fix dmachain oops with DEBUG enabledHaavard Skinnemoen2008-02-061-8/+12
| | | | | | | | | | | | | | | | In atmel_spi_next_xfer, xfer can be NULL because the next transfer may already have been submitted to the PDC (using DMA chaining). This can cause an oops, since the debug message assumed it was never null. The fix changes how those debug messages are issued, ensuring that one is issued each time a transfer is started instead of once per call. Also, properly indent the "can this transfer be chained" test so it's not hidden as if it were non-conditional code. Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* atmel_spi: chain DMA transfersSilvester Erdeg2008-02-061-45/+101
| | | | | | | | | | | | | | | | | | | | | | | | | | Add support for chained transfers in the atmel_spi driver, letting the DMA controller switch to the next buffer pair without CPU intervention. This reduced I/O latencies by about 2% in one bulk I/O test. It should also help work around several interrelated errata affecting chipselect 0 on at91rm9200 chips. Almost all of the changes are in the reworked atmel_spi_next_xfer() function. That's now called with the driver in one of three states: 1. It isn't transferring anything (in which case the first transfer of the current message is going to be sent) 2. It has finished transfering a non-chainable transfer (in which case it will go to the next transfer in the message) 3. It has finished transfering a chained transfer (in which case the next transfer is already queued) After that it will queue the next transfer if it can be chained. Signed-off-by: Szilveszter Ordog <slipszi@gmail.com> Acked-by: Haavard Skinnemoen <hskinnemoen@atmel.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* atmel_spi throughput improvementHaavard Skinnemoen2008-02-061-3/+8
| | | | | | | | | | | | | | | | | Don't insert (undesirable) delays between consecutive words (DLYBCT) or when activating chipselects (DLYBS). Removing the between-word delays improves the performance of bulk transfers (such as mtd_dataflash, m25p80, mmc_spi) significantly. In one test, the improvement was a factor of more than eight! (The large DLYBCT value came from the legacy at91 SPI driver, and it's not clear why it used such a huge value.) Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi core: stop updating dev->power.power_stateDavid Brownell2008-02-061-20/+14
| | | | | | | | | | Don't update dev->power.power_state any more in the SPI core. The only reason to update this scheduled-to-be-removed field was to make the already-removed /sys/devices/.../power/state files work better. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* Remove pointless casts from void pointersJeff Garzik2008-02-061-1/+1
| | | | | | | | | | | | | | | | | | | | | | Mostly in and around irq handlers. Signed-off-by: Jeff Garzik <jgarzik@redhat.com> Cc: Russell King <rmk@arm.linux.org.uk> Cc: "Luck Tony" <tony.luck@intel.com> Cc: Roman Zippel <zippel@linux-m68k.org> Cc: Geert Uytterhoeven <geert@linux-m68k.org> Cc: Paul Mackerras <paulus@samba.org> Cc: Benjamin Herrenschmidt <benh@kernel.crashing.org> Acked-by: Dmitry Torokhov <dtor@mail.ru> Cc: Karsten Keil <kkeil@suse.de> Acked-by: "John W. Linville" <linville@tuxdriver.com> Cc: James Bottomley <James.Bottomley@steeleye.com> Cc: David Brownell <david-b@pacbell.net> Cc: "Antonino A. Daplas" <adaplas@pol.net> Acked-by: Josh Boyer <jwboyer@linux.vnet.ibm.com> Acked-by: Holger Schurig <hs4233@mail.mn-solutions.de> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* Remove inclusions of <linux/autoconf.h>Ralf Baechle2008-02-061-1/+0
| | | | | | | | | | Nothing should ever include this file. Signed-off-by: Ralf Baechle <ralf@linux-mips.org> Acked-by: "Mike Frysinger" <vapier.adi@gmail.com> Acked-by: "Bryan Wu" <cooloney.lkml@gmail.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* Spelling fixes: lenght->lengthPaulius Zaleckas2008-02-031-1/+1
| | | | | Signed-off-by: Paulius Zaleckas <pauliusz@yahoo.com> Signed-off-by: Adrian Bunk <bunk@kernel.org>
* Merge branch 'linux-2.6'Paul Mackerras2008-01-314-100/+72
|\
| * [ARM] pxa: make pxa2xx_spi driver use ssp_request()/ssp_free()eric miao2008-01-262-86/+53
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1. make pxa2xx_spi.c use ssp_request() and ssp_free() to get the common information of the designated SSP port. 2. remove those IRQ/memory request code, ssp_request() has done that for the driver 3. the SPI platform device is thus made psuedo, no resource (memory/IRQ) has to be defined, all will be retreived by ssp_request() 4. introduce ssp_get_clk_div() to handle controller difference in clock divisor setting 5. use clk_xxx() API for clock enable/disable, and clk_get_rate() to handle the different SSP clock frequency between different processors Signed-off-by: eric miao <eric.miao@marvell.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
| * [ARM] pxa: move SSP register definitions from pxa-regs.h to regs-ssp.heric miao2008-01-261-0/+1
| | | | | | | | | | Signed-off-by: eric miao <eric.miao@marvell.com> Signed-off-by: Russell King <rmk+kernel@arm.linux.org.uk>
| * spi: use class iteration apiDave Young2008-01-241-11/+15
| | | | | | | | | | | | | | | | | | Convert to use the class iteration api. Signed-off-by: Dave Young <hidave.darkstar@gmail.com> Acked-by: David Brownell <david-b@pacbell.net> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
| * spi: omap2_mcspi PIO RX fixKalle Valo2008-01-241-3/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Before transmission of the last word in PIO RX_ONLY mode rx+tx mode is enabled: /* prevent last RX_ONLY read from triggering * more word i/o: switch to rx+tx */ if (c == 0 && tx == NULL) mcspi_write_cs_reg(spi, OMAP2_MCSPI_CHCONF0, l); But because c is decremented after the test, c will never be zero and rx+tx will not be enabled. This breaks RX_ONLY mode PIO transfers. Fix it by decrementing c in the beginning of the various I/O loops. Signed-off-by: Kalle Valo <kalle.valo@nokia.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | Merge branch 'for-2.6.25' of git://git.secretlab.ca/git/linux-2.6-mpc52xxPaul Mackerras2008-01-311-77/+5
|\ \
| * | [POWERPC] mpc52xx_psc_spi device driver must not touch port_config and cdmGrant Likely2008-01-261-75/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | It is dangerous for an mpc52xx device driver to modify the port_config register. If the driver is probed incorrectly, it will change the pin IO configuration in ways which may not be compatible with the board. port_config should be set up by the bootloader, or failing that, in the platform setup code in arch/powerpc/platforms/52xx. Also, modifying CDM registers directly can cause a race condition with other drivers. Instead call a common routine to modify CDM settings. Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Acked-by: Dragos Carp <dragos.carp@toptica.com>
| * | [POWERPC] mpc5200: normalize compatible property bindingsGrant Likely2008-01-261-2/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Update MPC5200 drivers to also look for compatible properties in the form "fsl,mpc5200-*" to better conform to open firmware generic names recommended practice as published here: http://www.openfirmware.org/1275/practice/gnames/gnamv14a.html This patch should *not* break compatibility with older device trees which do not use the 'fsl,' prefix. The drivers will still bind against the older names also. Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
* | | spi_mpc83xx: use brg-frequency for SPI in QEAnton Vorontsov2008-01-281-5/+1
|/ / | | | | | | | | | | | | | | | | | | | | In case of QE we can use brg-frequency (which is qeclk/2). Thus no need to divide sysclk in the spi_mpc83xx. This patch also adds code to use get_brgfreq() on QE chips. Signed-off-by: Anton Vorontsov <avorontsov@ru.mvista.com> Acked-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Kumar Gala <galak@kernel.crashing.org>
* | Merge branch 'linux-2.6'Paul Mackerras2008-01-241-2/+3
|\ \ | |/
| * spi_bitbang: always grab lock with irqs blockedDavid Brownell2008-01-081-2/+3
| | | | | | | | | | | | | | | | | | Fix a glitch reported by lockdep in the spi_bitbang code: it needs to consistently block IRQs when holding that spinlock. Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* | [POWERPC] mpc5200: eliminate mpc52xx_*_map_*() functions.Grant Likely2008-01-181-2/+7
|/ | | | | | | mpc5200 platform code defines a bunch of map functions which duplicate the functionality of of_iomap(). Remove them and use of_iomap() instead. Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
* atmel_spi: reload RCR before TCRRini van Zetten2007-12-101-1/+1
| | | | | | | | | | | | | | | | | | | | We have a wifi module connected to the spi bus and got sometimes FIFO overrun errors on the spi bus. After some investigation i found that the driver loads the TCR (transmit count) register before the RCR (receive count). When the transfer list is not empty the atmel_spi_next_message is called while tx and rx are enabled. As soon as the TCR is loaded, hardware starts transfer and causes a rx fifo overrun because the RCR is not loaded yet. Load the RCR before the TCR. After this patch the fifo overrun disapears at out setup. Signed-off-by: Haavard Skinnemoen <hskinnemoen@atmel.com> Signed-off-by: Rini van Zetten <rini@arvoo.nl> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi_imx: fix typo in descriptionWill Newton2007-12-101-1/+1
| | | | | | | Signed-off-by: Will Newton <will.newton@gmail.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi_bfin5xx: fix typo in descriptionWill Newton2007-12-101-1/+1
| | | | | | | Signed-off-by: Will Newton <will.newton@gmail.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* pxa2xx_spi: fix typo in descriptionWill Newton2007-12-101-1/+1
| | | | | | | Signed-off-by: Will Newton <will.newton@gmail.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* Blackfin SPI driver: reconfigure speed_hz and bits_per_word in each spi transferBryan Wu2007-12-051-7/+45
| | | | | | | | | | | - reconfigure SPI baud from speed_hz of each spi transfer - according to spi_transfer.bits_per_word to reprogram register and setup correct SPI operation handlers Signed-off-by: Bryan Wu <bryan.wu@analog.com> Cc: David Brownell <david-b@pacbell.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* Blackfin SPI driver: move hard coded pin_req to board fileBryan Wu2007-12-051-21/+7
| | | | | | | | | | | | | Remove some sort of bloaty code, try to get these pin_req arrays built at compile-time - move this static things to the blackfin board file - add pin_req array to struct bfin5xx_spi_master - tested on BF537/BF548 with SPI flash Signed-off-by: Bryan Wu <bryan.wu@analog.com> Cc: David Brownell <david-b@pacbell.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* Blackfin SPI driver: use void __iomem * for regs_baseBryan Wu2007-12-051-5/+4
| | | | | | | Signed-off-by: Bryan Wu <bryan.wu@analog.com> Cc: David Brownell <david-b@pacbell.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* Blackfin SPI driver: use cpu_relax() to replace continue in while busywaitBryan Wu2007-12-051-39/+39
| | | | | | | Signed-off-by: Bryan Wu <bryan.wu@analog.com> Cc: David Brownell <david-b@pacbell.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi: spi_bfin: resequence DMA start/stopSonic Zhang2007-12-051-11/+19
| | | | | | | | | | Set correct baud for spi mmc and enable SPI only after DMA is started. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi: spi_bfin: update handling of delay-after-deselectBryan Wu2007-12-051-15/+9
| | | | | | | | | | | | | | Move cs_chg_udelay handling (specific to this driver) to cs_deactive(), fixing a bug when some SPI LCD driver needs delay after cs_deactive. Fix bug reported by Cameron Barfield <cbarfield@cyberdata.net> https://blackfin.uclinux.org/gf/project/uclinux-dist/forum/?action=ForumBrowse&forum_id=39&_forum_action=ForumMessageBrowse&thread_id=23630&feedback=Message%20replied. Cc: Cameron Barfield <cbarfield@cyberdata.net> Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi: spi_bfin: bugfix for 8..16 bit word sizesBryan Wu2007-12-051-1/+1
| | | | | | | | | | Fix bug in u16_cs_chg_reader to read data_len-2 bytes data firstly, then read out the last 2 bytes data Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi: spi_bfin: handle multiple spi_mastersBryan Wu2007-12-051-182/+189
| | | | | | | | | | Move global SPI regs_base and dma_ch to struct driver_data. Test on BF54x SPI Flash with 2 spi_master devices enabled. Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi: spi_bfin: relocate spin/waitsSonic Zhang2007-12-051-32/+52
| | | | | | | | | | Move spin/waits to more correct locations in bfin SPI driver. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi: spi_bfin: change handling of communication parametersSonic Zhang2007-12-051-75/+87
| | | | | | | | | | | | | | | | | Fix SPI driver to work with SPI flash ST M25P16 on bf548 Currently the SPI driver enables the SPI controller and sets the SPI baud register for each SPI transfer. But they should never be changed within a SPI message session, in which several SPI transfers are pumped. This patch moves SPI setting to the begining of a message session, and never disables SPI controller until an error occurs. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi: spi_bfin, rearrange portmux callsSonic Zhang2007-12-051-25/+28
| | | | | | | | | | Move pin muxing to setup and cleanup methods. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi: spi_bfin uses portmux for additional bussesSonic Zhang2007-12-051-20/+31
| | | | | | | | | | | Use portmux mechanism to support SPI busses 1 and 2, instead of just the original bus 0. Signed-off-by: Sonic Zhang <sonic.zhang@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi: spi_bfin uses platform device resourcesBryan Wu2007-12-051-41/+83
| | | | | | | | | | | Update spi driver to support multi-ports by using platform resources; tested on STAMP537+SPI_MMC, other boards need more testing. Plus other minor updates. Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi: spi_bfin, don't bypass spi frameworkMike Frysinger2007-12-051-0/+12
| | | | | | | | | | | Prevent people from setting bits in ctl_reg that the SPI framework already handles, hopefully we can one day drop ctl_reg completely Signed-off-by: Mike Frysinger <michael.frysinger@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi: spi_bfin handles spi_transfer.cs_changeBryan Wu2007-12-051-22/+54
| | | | | | | | | | Respect per-transfer cs_change field (protocol tweaking support) by adding and using cs_active/cs_deactive functions. Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi: spi_bfin cleanups, error handlingBryan Wu2007-12-051-64/+47
| | | | | | | | | | | | | | | Cleanup and error handling - add error handling in SPI bus driver with selecting clients - use proper defines to access Blackfin MMRs - remove useless SSYNCs - cleaner use of portmux calls Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* spi: bfin spi uses portmux callsMichael Hennerich2007-12-051-6/+22
| | | | | | | | | | Use new Blackfin portmux interface, add error handling. Signed-off-by: Michael Hennerich <michael.hennerich@analog.com> Signed-off-by: Bryan Wu <bryan.wu@analog.com> Signed-off-by: David Brownell <dbrownell@users.sourceforge.net> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
OpenPOWER on IntegriCloud