summaryrefslogtreecommitdiff
path: root/drivers/spi/spi-tegra.c
AgeCommit message (Collapse)Author
2011-11-30arm: tegra: Clean up SOC conditionalsScott Williams
Change SOC conditionals to make them more forward-looking. Original-Change-Id: Ib60db4e690c2f396afdec962616d735548b5a8a9 Reviewed-on: http://git-master/r/32706 Reviewed-by: Niket Sirsi <nsirsi@nvidia.com> Tested-by: Niket Sirsi <nsirsi@nvidia.com> Rebase-Id: Ra0885f203904e0bd4bdd06c23b6aa7e03e7ec3bc
2011-11-30arm: tegra: dma: Adding client name with dma allocation.Laxman Dewangan
By changing the dma allocation API to take the client name, it is easy to track who is allocated the DMA channels when we run out of the DMA channels. Original-Change-Id: I016011cfd74089fed0da1bc0f121800017ce124a Reviewed-on: http://git-master/r/28031 Reviewed-by: Varun Colbert <vcolbert@nvidia.com> Tested-by: Varun Colbert <vcolbert@nvidia.com> Original-Change-Id: I048bcb87f95ee6d8ad2fdce993a1758dc5071666 Rebase-Id: R29b9645ecbe209f571018c6e707bfdd9cd65ad5d
2011-11-30spi: tegra: Spi controller configured during device setupLaxman Dewangan
When spi device calls the setup, the interface to that device should be configured immediately. For this, it is required to configure controller in setup call. Original-Change-Id: I77795c476729fe7403529a45cdf99d5732ad0784 Reviewed-on: http://git-master/r/27607 Reviewed-by: Niket Sirsi <nsirsi@nvidia.com> Tested-by: Niket Sirsi <nsirsi@nvidia.com> Original-Change-Id: I9a3f200dbea7d8cc057bb5413e790c28578e77cf Rebase-Id: R7e9907797bf951a9f7b9b6db0a440b3796dc977c
2011-11-30ARM: tegra: Use proper type for physical addressesScott Williams
Original-Change-Id: I158d2be97c795313e7e74ce9fb4ec0bdc7d95496 Reviewed-on: http://git-master/r/27559 Tested-by: Scott Williams <scwilliams@nvidia.com> Reviewed-by: Hiro Sugawara <hsugawara@nvidia.com> Reviewed-by: Jin Qian <jqian@nvidia.com> Reviewed-by: Kaz Fukuoka <kfukuoka@nvidia.com> Reviewed-by: Scott Williams <scwilliams@nvidia.com> Original-Change-Id: I0ff198daa548ed2837f7fb1794013bf0adf7e5a1 Rebase-Id: R61892d66dc9efd02f691a3ac75f92dd5d6d17078
2011-11-30spi: tegra: Supporting HW based CS controlLaxman Dewangan
Supporting the hw based CS to communicate to spi device. This provides the constraints in hold and setup time of CS before clock start and clock ends. The hw based CS can be selected if spi client provide the option through the device controler data and only one transfer per message is requested. Original-Change-Id: I56d5e466361cb8b3710646e01494ddac46791ae4 Reviewed-on: http://git-master/r/23988 Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com> Tested-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-by: Amit Kamath <akamath@nvidia.com> Reviewed-by: Ramachandrudu Kandhala <rkandhala@nvidia.com> Original-Change-Id: I52b1dcdefa199cd11ae7f838c61411a6268a2d32 Rebase-Id: Rd9f2c70e8c8551ea5ca6ce698a172ef00c08ca67
2011-11-30spi: tegra: Fixing misc issues.Laxman Dewangan
Following are the fixes; - Supportng half duplex. - Only using SW based CS. - Write to readback with command register does not work. Fixing issue. - Using cpu based transfer for smaller size and dma based for larger size. - reading proper transfer status after every transaction. bug 791149 bug 791780 Original-Change-Id: I293b3f1b571276f5d8fe4ad4da67f827926e4b73 Reviewed-on: http://git-master/r/20581 Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com> Tested-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com> Reviewed-by: Amit Kamath <akamath@nvidia.com> Rebase-Id: R29f88f7509bdb182f05916ecf31e1090b1b9d017
2011-11-30spi: tegra: disabling packed modeAmit Kamath
disable unstable packed spi mode Original-Change-Id: I81a11a0f5dd9515ff1430ccfcc7d2ed7371e79b3 Reviewed-on: http://git-master/r/16105 Reviewed-by: Varun Colbert <vcolbert@nvidia.com> Tested-by: Varun Colbert <vcolbert@nvidia.com> Rebase-Id: R010fbce5f63a377fa9661f3bdd89523c497989ec
2011-11-30[ARM] tegra: spi: Fixed setup bugsAmit Kamath
Enabled clocks at spi_setup Fixed problem with endianness for 16 bit word size Fixed issue with small packet size less than fifo depth Fixed typo that enabled RX and TX by default Integration from http://git-master/r/#change,14536 Original-Change-Id: I2cea3bdcb6a19780087671131a848095354105a3 Reviewed-on: http://git-master/r/15949 Reviewed-on: http://git-master/r/16048 Reviewed-by: Amit Kamath <akamath@nvidia.com> Tested-by: Amit Kamath <akamath@nvidia.com> Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com> Rebase-Id: Ra7c9c381f2ae897d002853c9965252ba28dc28ac
2011-11-30[tegra:spi] master tegra spi driver updateminwuklee
- DMA burst size can be set to 1, 4, or 8 depending on requested size - PACKED MODE support - When bits per word is 32, no endian conversion is needed; so use memcpy to copy from client buf to dma buf or vice versa - Do spi_complete operation in the last dma complete callback - Reducing the loop-count from 500 to 50, thus making sure suspend is not stuck. bug 747979 bug 765062 Original-Change-Id: I67fe1405e1cda886e9229b26dff5ebd80fd67247 Reviewed-on: http://git-master/r/12799 Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com> Tested-by: Bharat Nihalani <bnihalani@nvidia.com> Rebase-Id: R34ee80275312587666359ed2e0e8dab468068daf
2011-11-30[tegra:dma] set dma burst size for spi/slinkminwuklee
for spi/slink, depending on transfer size, burst size can be set to 1, 4, or 8. bug 747979 Original-Change-Id: Ieae0285d374e7d0eb6c2c2e633f8cafbb2b51b3a Reviewed-on: http://git-master/r/12076 Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com> Tested-by: Bharat Nihalani <bnihalani@nvidia.com> Rebase-Id: R366881cc8a4ba50cdd815b97f52b4e7d4dfb1ee6
2011-11-30[tegra:dma] set dma burst size for spi/slinkminwuklee
for spi/slink, set dma burst size based on transfer size. bug 747979 Original-Change-Id: I8c3c0a0410648a25190847590b9ac0304fb1105f Reviewed-on: http://git-master/r/11752 Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com> Tested-by: Bharat Nihalani <bnihalani@nvidia.com> Rebase-Id: R63f68e541c427778a412c5f09e656fb18da5f05d
2011-11-30spi: tegra: Use shared DMA channelColin Cross
To avoid running out of DMA channels, use the shared DMA channel for all four Tegra spi controllers. Change-Id: Iff644253cf7fae36aa2e42321a1ded35a728da4f Signed-off-by: Colin Cross <ccross@android.com>
2011-11-30spi: tegra: Increase delay between CS and clock startGreg Meiste
Some SPI devices require a delay between the CS and when the clock starts. Increase SS_SETUP to accommodate these devices. Change-Id: I301e3583e70c722cadde5a9f91119881805dd3a5 Signed-off-by: Greg Meiste <w30289@motorola.com>
2011-11-30[ARM] Tegra: SPI: Suspend/resume.Todd Poynor
Save/restore SLINK_COMMAND_0 register. Wait for in-progress transactions to complete before suspend. Reject and WARN_ON transactions when suspended. Change-Id: I0527781f0bf95781afa3a35a68282cde2f0189ae Signed-off-by: Todd Poynor <toddpoynor@google.com>
2011-07-05spi/tegra: Use engineering names in DT compatible propertyStephen Warren
Engineering names are more stable than marketing names. Hence, use them for Device Tree compatible properties instead. Signed-off-by: Stephen Warren <swarren@nvidia.com> Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
2011-06-15gpio/tegra: Move Tegra gpio driver to drivers/gpioGrant Likely
As part of the gpio driver consolidation, this patch moves the Tegra driver into drivers/gpio Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
2011-06-10spi: Convert uses of struct resource * to resource_size(ptr)Joe Perches
Done via coccinelle scripts like: @@ struct resource *ptr; @@ - ptr->end - ptr->start + 1 + resource_size(ptr) and some grep and typing. Mostly uncompiled, no cross-compilers. Signed-off-by: Joe Perches <joe@perches.com> Signed-off-by: Grant Likely <grant.likely@secretlab.ca>
2011-06-06spi: reorganize driversGrant Likely
Sort the SPI makefile and enforce the naming convention spi_*.c for spi drivers. This change also rolls the contents of atmel_spi.h into the .c file since there is only one user of that particular include file. v2: - Use 'spi-' prefix instead of 'spi_' to match what seems to be be the predominant pattern for subsystem prefixes. - Clean up filenames in Kconfig and header comment blocks Signed-off-by: Grant Likely <grant.likely@secretlab.ca> Acked-by: Wolfram Sang <w.sang@pengutronix.de> Acked-by: Linus Walleij <linus.walleij@linaro.org>