An error occurred fetching the project authors.
- 02 Jan, 2016 1 commit
-
-
Wolfram Sang authored
These macros don't really hide complexity, but C idioms. Removing them makes the code easier to read IMO and make a planned extension easier. Acked-by:
Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- 14 Dec, 2015 3 commits
-
-
Wolfram Sang authored
Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
Switch to the new generic functions. Plain convert, no functionality added yet. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
The probe function is a little bit messy, something here, something there. Rework it so that there is some order: first init the private structure, then the adapter, then do HW init. This also allows us to remove the device argument of the clock calculation function, because it now can be deduced from the private structure. Also, shorten some lines where possible. This is a preparation for further refactoring. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- 30 Nov, 2015 11 commits
-
-
Wolfram Sang authored
Signed-off-by:
Ryo Kataoka <ryo.kataoka.wt@renesas.com> Signed-off-by:
Hiromitsu Yamasaki <hiromitsu.yamasaki.ym@renesas.com> Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
Update the comments to match current behaviour. Shorten some comments. Update copyrights. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
If we don't clear START generation as soon as possible, it may cause another message to be generated, e.g. when receiving NACK in address phase. To keep the race window as small as possible, we clear it right at the beginning of the interrupt. We don't need any checks since we always want to stop START and STOP generation on the next occasion after we started it. This patch improves the situation but sadly does not completely fix it. It is still to be researched if we can do better given this HW design. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
Due to the HW design, master IRQs are timing critical, so give them precedence over slave IRQ. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
The manual says (55.4.8.6) that HW does automatically send STOP after NACK was received. My measuerments confirm that. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
Setting up new messages was done in process context while handling a message was in interrupt context. Because of the HW design, this IP core is sensitive to timing, so the context switches were too expensive. Move this setup to interrupt context as well. In my test setup, this fixed the occasional 'data byte sent twice' issue which a number of people have seen. It also fixes to send REP_START after a read message which was wrongly send as a STOP + START sequence before. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
We want to reuse this function later. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
After making sure to reinit the HW and clear interrupts in the timeout case, we know that interrupts are always disabled in the sections protected by the spinlock. Thus, we can simply remove it which is a preparation for further refactoring. While here, rename the timeout variable to time_left which is way more readable. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
We don't need to init HW before every transfer since we know the HW state then. HW init at probe time is enough. While here, add setting the clock register which belongs to init HW. Also, set MDBS bit since not setting it is prohibited according to the manual. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
When calculating the bus speed, the clock should be on, of course. Most bootloaders left them on, so this went unnoticed so far. Move the ioremapping out of this clock-enabled-block and prepare for adding hw initialization there, too. Reported-by:
Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- 30 Oct, 2015 1 commit
-
-
Wolfram Sang authored
This whole series caused sometimes timeouts and even OOPSes on some r8a7791 Koelsch boards. We need to understand and fix those first. Revert "i2c: rcar: clean up after refactoring" Revert "i2c: rcar: revoke START request early" Revert "i2c: rcar: check master irqs before slave irqs" Revert "i2c: rcar: don't issue stop when HW does it automatically" Revert "i2c: rcar: init new messages in irq" Revert "i2c: rcar: refactor setup of a msg" Revert "i2c: rcar: remove spinlock" Revert "i2c: rcar: remove unused IOERROR state" Revert "i2c: rcar: rework hw init" Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- 20 Oct, 2015 2 commits
-
-
Geert Uytterhoeven authored
Since commit 4baadb9e ("ARM: shmobile: r8a7778: remove obsolete setup code"), Renesas R-Car SoCs are only supported in generic DT-only ARM multi-platform builds. The driver doesn't need to use platform data anymore, hence remove platform data configuration. Signed-off-by:
Geert Uytterhoeven <geert+renesas@glider.be> [wsa: removed now unused ret value and cast to proper enum type] Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
Enable the I2C core for this SoC. I add a new type because this version has new features (e.g. DMA) which will be added somewhen later. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Tested-by:
Kuninori Morimoto <kuninori.morimoto.gx@renesas.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- 15 Oct, 2015 1 commit
-
-
Wolfram Sang authored
The core may register clients attached to this master which may use funtionality from the master. So, RuntimePM must be enabled before, otherwise this will fail. While here, move drvdata, too. Reported-by:
Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de> Cc: stable@kernel.org
-
- 09 Oct, 2015 9 commits
-
-
Wolfram Sang authored
Update the comments to match current behaviour. Shorten some comments. Update copyrights. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
If we don't clear START generation as soon as possible, it may cause another message to be generated. To keep the race window as small as possible, we clear it right at the beginning of the interrupt. We don't need checking since we always want to stop START and STOP generation on the next occasion after we started it. This patch improves the situation but sadly does not completely fix it. It is still to be researched if we can do better given this HW design. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
Due to broken HW design, master IRQs are more timing critical, so give them precedence over slave IRQ. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
The manual says (55.4.8.6) that HW does automatically send STOP after NACK was received. My measuerments confirm that. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
Setting up new messages was done in process context while handling a message was in interrupt context. Because of the HW design, this IP core is sensitive to timing, so the context switches were too expensive. Move this setup to interrupt context as well. In my test setup, this fixed the occasional 'data byte sent twice' issue which a number of people have seen. It also fixes to send REP_START after a read message which was wrongly send as a STOP + START sequence before. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
We want to reuse this function later. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
We make sure to reinit the HW in the timeout case; then we know that interrupts are always disabled in the sections protected by the spinlock. Thus, we can simply remove it which is a preparation for further refactoring. While here, rename the timeout variable to time_left which is way more readable. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
We don't need to init HW before every transfer since we know the HW state then. HW init at probe time is enough. While here, add setting the clock register which belongs to init HW. Also, set MDBS bit since not setting it is prohibited according to the manual. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- 23 Jun, 2015 2 commits
-
-
Wolfram Sang authored
wait_event_timeout returns long, not int. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-by:
Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Wolfram Sang authored
5 seconds is a very large timeout, and it is hardcoded. Use the default timeout from 'struct adapter' which is 1 second. It can also be modified from userspace for specific workloads via i2c-dev. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-by:
Laurent Pinchart <laurent.pinchart@ideasonboard.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- 31 May, 2015 1 commit
-
-
Wolfram Sang authored
Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-by:
Geert Uytterhoeven <geert+renesas@glider.be> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- 12 May, 2015 1 commit
-
-
Krzysztof Kozlowski authored
The platform_device_id is not modified by these drivers and core uses it as const. Signed-off-by:
Krzysztof Kozlowski <k.kozlowski.k@gmail.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- 27 Mar, 2015 1 commit
-
-
Wolfram Sang authored
After more discussion, brave users, and additional datasheet evaluation, some API updates for the new I2C slave framework became imminent. The slave events now get some easier to understand naming. Also, the event handling has been simplified to only need a single call to the slave callback when an action by the backend is required. Reported-by:
Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-by:
Geert Uytterhoeven <geert+renesas@glider.be> Acked-by:
Uwe Kleine-König <u.kleine-koenig@pengutronix.de> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- 11 Dec, 2014 1 commit
-
-
Wolfram Sang authored
The first I2C slave provider using the new generic interface. Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- 20 Oct, 2014 1 commit
-
-
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>
-
- 29 Sep, 2014 4 commits
-
-
Wolfram Sang authored
gcc rightfully says: drivers/i2c/busses/i2c-rcar.c:198:10: warning: comparison between signed and unsigned integer expressions [-Wsign-compare] Signed-off-by:
Wolfram Sang <wsa+renesas@sang-engineering.com> Acked-by:
Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Sergei Shtylyov authored
Check if the ICMSR register (masked with the ICMIER register) evaluates to 0 in the driver's interrupt handler and return IRQ_NONE in that case, like many other drivers do. Signed-off-by:
Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Sergei Shtylyov authored
rcar_i2c_prepare_msg() always returns 0, so we can make this function return *void* and thus remove the result check in rcar_i2c_master_xfer(). Signed-off-by:
Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
Sergei Shtylyov authored
rcar_i2c_master_xfer() needlessly compares the message pointers (using indirect addressing) in order to detect the last I2C message, while it's enough to only compare the message indexes. Signed-off-by:
Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-
- 20 Sep, 2014 1 commit
-
-
Sergei Shtylyov authored
Bits 8-31 of all registers reflect the value of bits 0-7 on reads and should be 0 on writes, according to the manuals. RCAR_IRQ_ACK_{RECV|SEND} macros have all 1's in bits 8-31, thus going against the manuals, so fix them. Signed-off-by:
Sergei Shtylyov <sergei.shtylyov@cogentembedded.com> Cc: stable@vger.kernel.org Signed-off-by:
Wolfram Sang <wsa@the-dreams.de>
-