summaryrefslogtreecommitdiff
path: root/drivers/i2c
AgeCommit message (Collapse)Author
2018-09-27i2c: sw-edid: add a driver which simulates edidMax Krummenacher
This adds a driver which simulates a i2c bus with an attached EDID memory. The memory content is read from the device tree. This allows to simulate EDID data which may differ from an attached display. Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com> Signed-off-by: Dominik Sliwa <dominik.sliwa@toradex.com> Acked-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2014-06-13i2c: tegra: do bit-banging for i2c transfer at 50KHz.Laxman Dewangan
Bit-banging is enabled dueing power off. Do the bit-banging method of data transfer at 50KHz. Change-Id: I641ddb8c85c34aace2c82ab666de8c7630ef0395 Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/423071 GVS: Gerrit_Virtual_Submit
2014-06-13i2c: algo: add more error/info printsLaxman Dewangan
Enable more error/info prints to know the status of the transfer if it fails. Also when sending bytes, ignore the last byte ACK from the slave. Change-Id: I2b655da28545362d6e7855baceedbfd8588b3e43 Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/423070 GVS: Gerrit_Virtual_Submit
2014-05-28i2c: tegra: protect i2c state variablesSang-Hun Lee
- i2c state variables cancel_xfer_on_shutdown and atomic_xfer_only are accessed without any locking, which could lead to a race - lock the adapter when accessing these variables Bug 1510778 Change-Id: If4a69b1e85e3801616cf8f3da6938fca4b0ab816 Signed-off-by: Sang-Hun Lee <sanlee@nvidia.com> Reviewed-on: http://git-master/r/411129 Reviewed-by: Mandar Padmawar <mpadmawar@nvidia.com> Tested-by: Mandar Padmawar <mpadmawar@nvidia.com>
2014-05-28i2c-algo-bit: fix scheduling while atomicAllen Yu
i2c transfer using bit-banging may be in atomic context. This patch avoid relinquishing processor during try_address() in case of atomic context transfer. Bug 200005734 Change-Id: I5ed18588acc9f7d46c840f218d194086ac09bb94 Signed-off-by: Allen Yu <alleny@nvidia.com> Reviewed-on: http://git-master/r/411560 Reviewed-on: http://git-master/r/415023 Reviewed-by: Robert Shih <rshih@nvidia.com> Reviewed-by: Mitch Luban <mluban@nvidia.com> Reviewed-by: Kerwin Wan <kerwinw@nvidia.com>
2014-05-23i2c: tegra: warn on i2c init failureSang-Hun Lee
- If tegra_i2c_init fails during xfer, the error is being silently ignored, making the debug difficult - If tegra_i2c_init fails, at least print a warning and stack trace to make the failure explicit Bug 1510778 Change-Id: Id885b3ad64f1f26304fa6d6cdb5c5ec8e682c038 Signed-off-by: Sang-Hun Lee <sanlee@nvidia.com> Reviewed-on: http://git-master/r/411721 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
2014-03-25i2c: tegra: Set pinctrl drive settings dynamically for HS modeChaitanya Bandi
Added support for setting pinctrl drive settings dynamically during boot in case a controller is configured to operate in HS mode. Bug 1396451 Change-Id: I6f2fd88d6f0263423e32f0cdcb54e8e89324a409 Signed-off-by: Chaitanya Bandi <bandik@nvidia.com> Reviewed-on: http://git-master/r/385532 Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
2014-03-20i2c: tegra: Make TX_FIFO filling un-interruptibleChaitanya Bandi
While programming an I2C transaction, no significant delay should be present between packet headers and data in case of write transactions. Any significant delay between them may cause clock-stretching with the controller waiting for the data to be written to TX_FIFO. Hence made the programming of these two happen in an uninterruptible fashion. Bug 1474556 Change-Id: Ife1afe9b9e3d4c571309a2e4dae4e0662c99c72e Signed-off-by: Chaitanya Bandi <bandik@nvidia.com> Reviewed-on: http://git-master/r/383807 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
2014-03-13i2c: tegra: do bitbanging xfer if atomic xfer is requiredLaxman Dewangan
If atomic context transfer is required then only do bit-banging transfers. bug 1451967 bug 1469284 Change-Id: Icd516610918fc4c59aef32ad154b763dd5418172 Signed-off-by: Chaitanya Bandi <bandik@nvidia.com> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/380933
2014-03-13i2c: core: do only atomic transfer in machine shutdown/restartLaxman Dewangan
Add mechanism to tell the i2c core to do only atomic transfer when machine restart/shutdown is required. bug 1451967 bug 1469284 Change-Id: Ib2f4dde2a624ddd7332a1a1345c52c94ba5460a1 Signed-off-by: Chaitanya Bandi <bandik@nvidia.com> Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/380932
2014-03-13Merge branch 'linux-3.10.33' into dev-kernel-3.10Deepak Nibade
Bug 1456092 Change-Id: I3021247ec68a3c2dddd9e98cde13d70a45191d53 Signed-off-by: Deepak Nibade <dnibade@nvidia.com>
2014-03-03i2c: tegra: Enable PACKET_MODE_EN only during xferChaitanya Bandi
Enabled the PACKET_MODE_EN bit only during transfer. This helps MTS to check whether any I2C transaction is in progress. Bug 1454386 Change-Id: I62ce2f4ec69bcfd0472e6a01bc5282e74b48f54d Signed-off-by: Chaitanya Bandi <bandik@nvidia.com> Reviewed-on: http://git-master/r/374850 Reviewed-by: Aleksandr Frid <afrid@nvidia.com> Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Venkat Moganty <vmoganty@nvidia.com>
2014-02-13i2c: i801: SMBus patch for Intel Coleto Creek DeviceIDsSeth Heasley
commit f39901c1befa556bc91902516a3e2e460000b4a8 upstream. This patch adds the i801 SMBus Controller DeviceIDs for the Intel Coleto Creek PCH. Signed-off-by: Seth Heasley <seth.heasley@intel.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> Cc: "Chan, Wei Sern" <wei.sern.chan@intel.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2014-02-13i2c: tegra: Allow no transactions after shutdownChaitanya Bandi
Do not allow I2C transactions after shutdown. Bug 1453601 Change-Id: Ifd655117b692508e7b0ad2604b5ab2b79b7873ad Signed-off-by: Chaitanya Bandi <bandik@nvidia.com> Reviewed-on: http://git-master/r/364164 Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
2014-02-05i2c: tegra: call adapter lock in shutdown callbackLaxman Dewangan
Call the adapter shutdown to cancel any further i2c transfer from shutdown callback. This will be require to stop any transfer on bus after shutdown happen. Bug 1443347 Change-Id: I4bf7de911c76b1c0032f1d82ffd956a099351cd8 Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/362874 (cherry picked from commit 2376afbfd638fbe37d61158154dc8ba85a099b31) Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Change-Id: I72437b5b53e14926fa1652c5df34ab7efa93f46a Reviewed-on: http://git-master/r/363716
2014-02-05i2c: add flag for cancel transfer when adapter shutdownLaxman Dewangan
Add support to cancel the transfer when the adapater in shutdown state. Also add API to re-enable transfer when actually client wants to do forcefully transfer. Bug 1443347 Change-Id: I750c9d3f97fcb5bd1d7ce8e5c721496e4c0debcc Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/362873 (cherry picked from commit fff546d83e8bd56cb26eb14ac6abac63070e3a95) Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Change-Id: Ia0a64938afc45aa143fce21473e6a2a67853aa5e Reviewed-on: http://git-master/r/363715
2014-02-03mux: pca954x: fix compilation warningsLaxman Dewangan
Fix compilation warning as /** i2c-mux-pca954x.c: In function 'pca954x_probe': i2c-mux-pca954x.c:225:6: warning: 'ret' may be used uninitialized in this function [-Wmaybe-uninitialized] */ Change-Id: I876282732c6f2e607ff267130884b90ae3113e5a Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/359793 (cherry picked from commit d656b44485a273e002872402c5819ef5e201c3c0) Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Change-Id: Icf1e829930a108d50bab80428770b5ac8cbf27ce Reviewed-on: http://git-master/r/362838
2014-01-21i2c: tegra: fix building errorKerwin Wan
Change-Id: Ie908c05466429e4b84797cc2a5e10138153daf0f Signed-off-by: Kerwin Wan <kerwinw@nvidia.com> Reviewed-on: http://git-master/r/347146 Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Alexander Van Brunt <avanbrunt@nvidia.com> Tested-by: Alexander Van Brunt <avanbrunt@nvidia.com>
2014-01-21i2c: tegra: Replace writesl/readsl callsChaitanya Bandi
Replaced writesl/readsl calls by adding writes/reads multiple times. Bug 1423775 Change-Id: I26649f947b57b77bc5940b5b78833ee8900f95e4 Signed-off-by: Chaitanya Bandi <bandik@nvidia.com> Reviewed-on: http://git-master/r/346455 Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-by: Suresh Mangipudi <smangipudi@nvidia.com>
2014-01-15i2c: pca954x: Use devm_* managed allocatorLaxman Dewangan
This simplifies error and removal paths. Change-Id: Ie39b6afaf6517b20ba7ea838dd43cbc141cce477 Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/356051
2014-01-15i2c: mux: pca954x: make pullup regulator optionalLaxman Dewangan
The PCA954X driver require two supply, one for self as vcc and other for output bus pullup as vcc-pullup. Making vcc-pullup as optional as this is not mandatory regulator for device and if it is not available then just do not enable it and not cause to driver fail. Change-Id: I1c63a13d01ac609af0a74934742daca7e68b4d00 Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/356050 Reviewed-by: Jihoon Bang <jbang@nvidia.com>
2014-01-13i2c: mux: pca954x: pass deselect mux when it is register from DTLaxman Dewangan
If device is registered from DT then pass the deslect_mux callback always to register the bus adpater. i2c-mux core driver parse the required propery from child bus node and enable deselct-mux accordingly. Change-Id: If11b251c39575812639af6bd455d9c84c7282eba Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/354256 GVS: Gerrit_Virtual_Submit
2014-01-13i2c: mux-core: add deselect property on child nodeLaxman Dewangan
Add deselect enable property on the child node of the mux bus. If child node of mux device have this property then deselect option will be enabled. Change-Id: I7907429e1937c8af608970c8680fe2fcea90da5a Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/354255 GVS: Gerrit_Virtual_Submit
2014-01-13i2c: tegra: remove bus number aliasing with nodeLaxman Dewangan
Tegra I2C aliases the i2c node with bus number. As the i2c-core framework supports the aliasing of bus number with device node, it is not require to have this in driver code. Hence removing this part of code. Change-Id: I1a9e63c62a1f17716d587d4588d0d426d3c297f2 Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/354254 GVS: Gerrit_Virtual_Submit
2013-12-30i2c: tegra: add dt parsing for cldvfs clock requirementsLaxman Dewangan
I2C5 (power i2c) bus shared between cldvfs and I2C5 controller. For bus arbitration, the cldvfs clock need to be enable. Parse this information from DT node and enable clock accordingly. Change-Id: Id9b35d465378cb9bba68c3634e647a92249d2947 Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/350117
2013-12-16Merge tag 'v3.10.24' into HEADAjay Nandakumar
This is the 3.10.24 stable release Change-Id: Ibd2734f93d44385ab86867272a1359158635133b
2013-12-04i2c: mux: gpio: use gpio_set_value_cansleep()Ionut Nicu
commit 250ad590d6f12d93f4d85be305b0a598d609232e upstream. Some gpio chips may have get/set operations that can sleep. gpio_set_value() only works for chips which do not sleep, for the others we will get a kernel warning. Using gpio_set_value_cansleep() will work for both chips that do sleep and those who don't. Signed-off-by: Ionut Nicu <ioan.nicu.ext@nsn.com> Acked-by: Peter Korsgaard <peter.korsgaard@barco.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-12-04i2c: mux: gpio: use reg value for i2c_add_mux_adapterIonut Nicu
commit 8c0ec2500eeb89749341884a972860d7f9e56f9c upstream. The i2c-mux driver requires that the chan_id parameter passed to the i2c_add_mux_adapter() function is equal to the reg value for that adapter: for_each_child_of_node(mux_dev->of_node, child) { ret = of_property_read_u32(child, "reg", &reg); if (ret) continue; if (chan_id == reg) { priv->adap.dev.of_node = child; break; } } The i2c-mux-gpio driver uses an internal logical index for chan_id when calling i2c_add_mux_adapter() instead of using the reg value. Because of this, there will problems in selecting the right adapter when the i2c-mux-gpio's index into mux->data.values doesn't match the reg value. An example of such a case: mux->data.values = { 1, 0 } For chan_id = 0, i2c-mux will bind the adapter to the of_node with reg = <0>, but when it will call the select() callback with chan_id set to 0, the i2c-mux-gpio will use it as an index into mux->data.values and it will actually select the bus with reg = <1>. Signed-off-by: Ionut Nicu <ioan.nicu.ext@nsn.com> Acked-by: Alexander Sverdlin <alexander.sverdlin@nsn.com> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-11-04i2c: tegra: handle Tegra pm notifier eventsPrashant Gaikwad
Bug 1254633 Change-Id: I82fac153273c51ddd2f1a54ab7b67bc69643a60e Signed-off-by: Prashant Gaikwad <pgaikwad@nvidia.com> Reviewed-on: http://git-master/r/310064 Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com> Tested-by: Bharat Nihalani <bnihalani@nvidia.com>
2013-11-04Revert "i2c: tegra: restore i2c after resume from LP0"Prashant Gaikwad
This reverts commit 98d2ffb58e7649eb158367a0f4d675939fe5abef. Instead of using domain for this purpose notifiers will be used. Change http://git-master/r/#/c/310064 is pushed to achieve this. Change-Id: Ie463e266d16c5678dafbf7ffa9d110cd1e7b4caf Reviewed-on: http://git-master/r/309647 Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com> Tested-by: Bharat Nihalani <bnihalani@nvidia.com>
2013-11-04i2c: ismt: initialize DMA bufferJames Ralston
commit bf4169100c909667ede6af67668b3ecce6928343 upstream. This patch adds code to initialize the DMA buffer to compensate for possible hardware data corruption. Signed-off-by: James Ralston <james.d.ralston@intel.com> [wsa: changed to use 'sizeof'] Signed-off-by: Wolfram Sang <wsa@the-dreams.de> Cc: Jean Delvare <jdelvare@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-10-31Revert "i2c: tegra: handle Tegra pm notifier events"Juha Tukkinen
This reverts commit 9b5639a6da0b5dc842fbaa6bd213b0d801cd2a70. Change-Id: Ibfa871d9bc8d98d5663f69d1f75d4b0bac2b8d4a Reviewed-on: http://git-master/r/310026 Tested-by: Arto Merilainen <amerilainen@nvidia.com> Reviewed-by: Juha Tukkinen <jtukkinen@nvidia.com>
2013-10-31i2c: tegra: handle Tegra pm notifier eventsPrashant Gaikwad
Bug 1254633 Change-Id: I4827c6464d1770d40d4135a252e47c8be330c753 Signed-off-by: Prashant Gaikwad <pgaikwad@nvidia.com> Reviewed-on: http://git-master/r/309618 Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
2013-10-31Merge tag 'v3.10.17' into dev-kernel-3.10Ajay Nandakumar
This is the 3.10.17 stable release Conflicts: drivers/usb/host/xhci.c Change-Id: I6bd3b15ff92a0b94568b9d02e9bb1036becfca20
2013-10-18i2c: omap: Clear ARDY bit twiceTaras Kondratiuk
commit 4cdbf7d346e7461c3b93a26707c852e2c9db3753 upstream. Initially commit cb527ede1bf6ff2008a025606f25344b8ed7b4ac "i2c-omap: Double clear of ARDY status in IRQ handler" added a workaround for undocumented errata ProDB0017052. But then commit 1d7afc95946487945cc7f5019b41255b72224b70 "i2c: omap: ack IRQ in parts" refactored code and missed one of ARDY clearings. So current code violates errata. It causes often i2c bus timeouts on my Pandaboard. This patch adds a second clearing in place. Signed-off-by: Grygorii Strashko <grygorii.strashko@ti.com> Signed-off-by: Taras Kondratiuk <taras.kondratiuk@linaro.org> Signed-off-by: Wolfram Sang <wsa@the-dreams.de> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
2013-10-17i2c: tegra: restore i2c after resume from LP0Prashant Gaikwad
Add function to restore all i2c controllers after resume from LP0. It will happen in idle thread where irqs are disabled and it is expected that no one would be using i2c device. Bug 1254633 Change-Id: Ice6f0f96c4097ccf61f5b36ac8b7b811c333c0b6 Signed-off-by: Prashant Gaikwad <pgaikwad@nvidia.com> Reviewed-on: http://git-master/r/299461 Reviewed-by: Bharat Nihalani <bnihalani@nvidia.com>
2013-09-14ARM: tegra: Use <linux/clk/tegra.h> instead of <mach/clk.h>Dan Willemsen
So that the upstream common clk infrastructure can live side by side. Signed-off-by: Dan Willemsen <dwillemsen@nvidia.com> Change-Id: I0fe0ef8cd207d27b707821eed838c75b8ec04025
2013-09-14i2c: tegra: Add debug prints for i2c timed out caseChaitanya Bandi
Added debug prints for i2c timed out case to help debug. Change-Id: I9b8b66acdc80b9bbddbf9d824d7fbd71fa602460 Signed-off-by: Chaitanya Bandi <bandik@nvidia.com> Signed-off-by: Pradeep Goudagunta <pgoudagunta@nvidia.com> Reviewed-on: http://git-master/r/266034 Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com> Tested-by: Laxman Dewangan <ldewangan@nvidia.com>
2013-09-14i2c: tegra: Use appropriate clk divisor and debounce for HS modeChaitanya Bandi
Bug 1318578 Change-Id: I5d53b71e977f0a8ab8282820dbcdbfe6188d588a Signed-off-by: Chaitanya Bandi <bandik@nvidia.com> (cherry picked from commit a307421c4e0a400ed1905648ee5b695f17bbf403) Reviewed-on: http://git-master/r/266040 GVS: Gerrit_Virtual_Submit Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
2013-09-14i2c: tegra: Add appropriate clk divisor for FM Plus modeChaitanya Bandi
Added appropriate clock divisor for FM Plus mode. Bug 1318578 Change-Id: I5f5d0fdbcb3df54f6ca74b752c81b00ab8841f05 Signed-off-by: Chaitanya Bandi <bandik@nvidia.com> (cherry picked from commit 01faecda1d6ab479ada1f12ada3da4fbbe1fb7e1) Reviewed-on: http://git-master/r/266039 GVS: Gerrit_Virtual_Submit Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
2013-09-14i2c: tegra: add compatible and platform id for Tegra124Laxman Dewangan
Add compatible and platform id for T124 I2C and keeping the HW chip specific paramter is same as T14x. Change-Id: Ic222abf1c8835850b6ff1e794c4cb0e67ac34352 Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/264891 Reviewed-by: Chaitanya Bandi <bandik@nvidia.com> Reviewed-by: Hayden Du <haydend@nvidia.com>
2013-09-14i2c: tegra: Implement the bit banging method for i2c transfer after shutdownLaxman Dewangan
Implement bit banging method of doing i2c transfer after shutdown call back get called. For bit banging method, driver will use bit algo for i2c transfer. Make this as optional and can be selected through platform data. bug 1213113 Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/260041 (cherry picked from commit 74e591524d6dbff96d133a254e363ecee90094c9) Change-Id: Id68c53f9685ea93e2e16d5523619cf9254ef4dac Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/261007 GVS: Gerrit_Virtual_Submit
2013-09-14i2c: tegra: enable I2C_INT_ALL_PACKETS_XFER_COMPLETE interrupt.Nitin Sehgal
- fix i2c timeout issue as I2C_INT_ALL_PACKETS_XFER_COMPLETE is disabled. bug 1313673 Change-Id: I2a2c39c64298ed6e087abbe047ba01113db80f3e Signed-off-by: Nitin Sehgal <nsehgal@nvidia.com> Reviewed-on: http://git-master/r/243891 (cherry picked from commit ca3063b3717b6cb4777d4ea2882636e98f9ccd5a) Reviewed-on: http://git-master/r/246480 Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Ashutosh Patel <ashutoshp@nvidia.com> Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
2013-09-14arm: tegra: gmi: Fix driver dependencies for devices on gmi bus.Nitin Sehgal
- nor mapping driver, pca gmi & sram driver could be selected independently. - efs & pflash should depend on nor mapping driver. bug 1294819 Change-Id: I8d201f6aad5ec742ff57d2c11a2507b2bc4f5a8d Signed-off-by: Nitin Sehgal <nsehgal@nvidia.com> Reviewed-on: http://git-master/r/235036 Reviewed-by: Automatic_Commit_Validation_User GVS: Gerrit_Virtual_Submit Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
2013-09-14i2c: tegra: do not suspend i2c interruptsLaxman Dewangan
There is possibility of I2C transfer calls even after suspend of drivers occur. To have the I2C transfer properly in this case, it should not suspend interrupt of I2C so that interrupt support should be available. bug 1272661 bug 1266321 bug 1257433 Change-Id: I2c98c3c7f7c6e5583a9c6d63e06227c70bb01e18 Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/220599 Reviewed-by: Automatic_Commit_Validation_User
2013-09-14i2c: tegra: move error prints from isr to caller contextLaxman Dewangan
To reduce the interrupt processing time in the isr, moving the warning/error prints from isr context to caller context as the status of errors are already saved. bug 1243783 Change-Id: Ib99801d47658af509948d56780bbf612267ec0c4 Signed-off-by: Laxman Dewangan <ldewangan@nvidia.com> Reviewed-on: http://git-master/r/218169 Reviewed-by: Chaitanya Bandi <bandik@nvidia.com> Reviewed-by: Antti Miettinen <amiettinen@nvidia.com>
2013-09-14i2c: tegra: Return -EAGAIN in case of ARB LostChaitanya Bandi
In case of ARB lost, return -EAGAIN so that the communication is retried. Bug 1222180 Change-Id: I003e02732568e08fabf6fe15f687e6ae73169f66 Signed-off-by: Chaitanya Bandi <bandik@nvidia.com> Reviewed-on: http://git-master/r/195401 (cherry picked from commit f2c6207ff4f4b93227a103a71d1519b7744e609d) Reviewed-on: http://git-master/r/204986 Reviewed-by: Automatic_Commit_Validation_User Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>
2013-09-14i2c: tegra: Use ALL_PACKETS_XFER_COMPLETE interruptChaitanya Bandi
The issue is that some clock stretching is observed in case of coupled Write-Read transaction after the write transaction because we wait for PACKET_XFER_COMPLETE. Using ALL_PACKETS_XFER_COMPLETE will prevent that clock stretching. In case of non-coupled transactions, PACKET_XFER_COMPLETE is used. Bug 1234504 Reviewed-on: http://git-master/r/204520 (cherry picked from commit 6ccd093d5282dbddb5c590d6c1ebd4cc5d097a12) Change-Id: Iba30d5c1cfd19d1e2af4007fe8ed72f13aa78df0 Signed-off-by: Chaitanya Bandi <bandik@nvidia.com> Reviewed-on: http://git-master/r/213710 Reviewed-by: Seshendra Gadagottu <sgadagottu@nvidia.com> Tested-by: Seshendra Gadagottu <sgadagottu@nvidia.com> Reviewed-by: Bitan Biswas <bbiswas@nvidia.com> Reviewed-by: Thomas Cherry <tcherry@nvidia.com>
2013-09-14i2c: tegra: Add cl_dvfs clock enabling for PWR_I2CChaitanya Bandi
Added cl_dvfs clocks enabling for PWR_I2C in i2c driver. Bug 1234556 Change-Id: Ied62a1cfc3d8c296e9aa46f08c7f34d0ab9766e1 Signed-off-by: Chaitanya Bandi <bandik@nvidia.com> Reviewed-on: http://git-master/r/201584 (cherry picked from commit 5ee5ac1624de959b8293242def231276c1d5d823) Reviewed-on: http://git-master/r/206942 Reviewed-by: Bitan Biswas <bbiswas@nvidia.com> Tested-by: Bitan Biswas <bbiswas@nvidia.com> Reviewed-by: Automatic_Commit_Validation_User
2013-09-14i2c: tegra: Add CONFIG_LOAD register setting for T14xChaitanya Bandi
Added CONFIG_LOAD register setting for T14x. Change-Id: Ib667362cd8881d50f24c0942d3acbb40f7fbf9c5 Signed-off-by: Chaitanya Bandi <bandik@nvidia.com> Reviewed-on: http://git-master/r/194696 GVS: Gerrit_Virtual_Submit Reviewed-by: Laxman Dewangan <ldewangan@nvidia.com>