- Feb 15, 2019
-
-
Shubhrajyoti Datta authored
In case the hold bit is not needed we are carrying the old values. Fix the same by resetting the bit when not needed. Fixes the sporadic i2c bus lockups on National Instruments Zynq-based devices. Fixes: df8eb569 ("i2c: Add driver for Cadence I2C controller") Reported-by:
Kyle Roeschley <kyle.roeschley@ni.com> Acked-by:
Michal Simek <michal.simek@xilinx.com> Signed-off-by:
Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com> Tested-by:
Kyle Roeschley <kyle.roeschley@ni.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- Jul 31, 2017
-
-
Masahiro Yamada authored
Several drivers call to_platform_device() to get platform_device and pass it to platform_get_drvdata(). In platform_get_drvdata(), the platform_device is converted back to struct device again. Use dev_get_drvdata() to avoid platform_device/device dance. Signed-off-by:
Masahiro Yamada <yamada.masahiro@socionext.com> Reviewed-by: Andy Shevchenko <andriy.shevchenko@linux.intel.com> (for DesignWare only) Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- Jun 23, 2017
-
-
Matt Weber authored
The driver was clearing the hold bit in the control register before writing to the address register which resulted in a stop condition being generated rather than a repeated start. This issue was only observed when a system was running much slower than a normal processor would execute. The IP data sheet mentions a ordering of writing to the address register before clearing the hold. Fixes: df8eb569 ("i2c: Add driver for Cadence I2C controller") Signed-off-by:
John Linn <john.linn@xilinx.com> Signed-off-by:
Paresh Chaudhary <paresh.chaudhary@rockwellcollins.com> Signed-off-by:
Matthew Weber <matthew.weber@rockwellcollins.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- Jan 25, 2017
-
-
Mike Looijmans authored
The cadence I2C driver calls cdns_i2c_writereg(..) to setup a workaround in the controller, but did so after calling i2c_add_adapter() which starts probing devices on the bus. Change the order so that the configuration is completely finished before using the adapter. Signed-off-by:
Mike Looijmans <mike.looijmans@topic.nl> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- Sep 08, 2016
-
-
Geert Uytterhoeven authored
Signed-off-by:
Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- Aug 22, 2016
-
-
Wolfram Sang authored
The core will do this for us now. Signed-off-by:
Wolfram Sang <wsa-dev@sang-engineering.com> Reviewed-by:
Grygorii Strashko <grygorii.strashko@ti.com> Acked-by:
Peter Korsgaard <peter@korsgaard.com> Acked-by:
Heiko Stuebner <heiko@sntech.de> Acked-by:
Neil Horman <nhorman@tuxdriver.com> Acked-by:
Thierry Reding <treding@nvidia.com> Acked-by:
Ray Jui <ray.jui@broadcom.com> Acked-by:
Vladimir Zapolskiy <vz@mleia.com> Acked-by:
Ludovic Desroches <ludovic.desroches@atmel.com> Acked-by:
Krzysztof Kozlowski <k.kozlowski@samsung.com> Acked-by:
Laxman Dewangan <ldewangan@nvidia.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- Mar 12, 2016
-
-
Shubhrajyoti Datta authored
This fixes the below warnings drivers/i2c/busses/i2c-cadence.c:164: warning: No description found for parameter 'dev' drivers/i2c/busses/i2c-cadence.c:826: warning: No description found for parameter 'dev' drivers/i2c/busses/i2c-cadence.c:826: warning: Excess function parameter '_dev' description in 'cdns_i2c_runtime_suspend' drivers/i2c/busses/i2c-cadence.c:844: warning: No description found for parameter 'dev' drivers/i2c/busses/i2c-cadence.c:844: warning: Excess function parameter '_dev' description in 'cdns_i2c_runtime_resume' while at it also update the cdns_i2c_clear_bus_hold and the runtime function update. Tested-by:
Michal Simek <michal.simek@xilinx.com> Signed-off-by:
Shubhrajyoti Datta <shubhraj@xilinx.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- Nov 30, 2015
-
-
Shubhrajyoti Datta authored
The suspended flag is a flag holding the device's PM status. The runtime framework does that for us. Use pm_runtime_suspended call instead. Signed-off-by:
Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Shubhrajyoti Datta authored
Currently the clocks are enabled at probe and disabled at remove. Which keeps the clocks enabled even if no transaction is going on. This patch enables the clocks at the start of transfer and disables after it. Also adapts to runtime pm. converts dev pm to const to silence a checkpatch warning. Signed-off-by:
Shubhrajyoti Datta <shubhrajyoti.datta@xilinx.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- Aug 10, 2015
-
-
Masahiro Yamada authored
The owner of the adapter is missing, while this driver is tristate. Signed-off-by:
Masahiro Yamada <yamada.masahiro@socionext.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Anurag Kumar Vulisha authored
Cadence 1.0 version has bugs which have been fixed in the cadence 1.4 version. This patch removes the quirks present in the driver for cadence 1.4 version. Signed-off-by:
Anurag Kumar Vulisha <anuragku@xilinx.com> [wsa: fixed indentation issues in r1p10_i2c_def] Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- Mar 15, 2015
-
-
Nicholas Mc Guire authored
return type of wait_for_completion_timeout is unsigned long not int. The return variable is renamed to make the timeout condition clearly readable and the type adjusted to unsigned long. Signed-off-by:
Nicholas Mc Guire <hofrat@osadl.org> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- Jan 14, 2015
-
-
Harini Katakam authored
Cadence I2C controller has the following bugs: - completion indication is not given to the driver at the end of a read/receive transfer with HOLD bit set. - Invalid read transaction are generated on the bus when HW timeout condition occurs with HOLD bit set. As a result of the above, if a set of messages to be transferred with repeated start includes any message following a read message, completion is never indicated and timeout occurs. Hence a check is implemented to return -EOPNOTSUPP for such sequences. Signed-off-by:
Harini Katakam <harinik@xilinx.com> Signed-off-by:
Vishnu Motghare <vishnum@xilinx.com> [wsa: fixed some whitespaces] Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- Jan 13, 2015
-
-
Harini Katakam authored
The I2C controller sends a NACK to the slave when transfer size register reaches zero, irrespective of the hold bit. So, in order to handle transfers greater than 252 bytes, the transfer size register has to be maintained at a value >= 1. This patch implements the same. The interrupt status is cleared at the beginning of the isr instead of the end, to avoid missing any interrupts. Signed-off-by:
Harini Katakam <harinik@xilinx.com> [wsa: added braces around else branch] Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- Dec 04, 2014
-
-
Vishnu Motghare authored
Cadence I2C controller has bug wherein it generates invalid read transactions after timeout in master receiver mode. This driver does not use the HW timeout and this interrupt is disabled but the feature itself cannot be disabled. Hence, this patch writes the maximum value (0xFF) to this register. This is one of the workarounds to this bug and it will not avoid the issue completely but reduces the chances of error. Signed-off-by:
Vishnu Motghare <vishnum@xilinx.com> Signed-off-by:
Harini Katakam <harinik@xilinx.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de> Cc: stable@kernel.org
-
- Oct 20, 2014
-
-
Wolfram Sang authored
A platform_driver does not need to set an owner, it will be populated by the driver core. Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- Apr 06, 2014
-
-
Soren Brinkmann authored
Add a driver for the Cadence I2C controller. This controller is for example found in Xilinx Zynq. Signed-off-by:
Soren Brinkmann <soren.brinkmann@xilinx.com> Tested-by:
Michal Simek <michal.simek@xilinx.com> Reviewed-by:
Harini Katakam <harinik@xilinx.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-