- 18 12月, 2014 2 次提交
-
-
由 Wolfram Sang 提交于
DMA is opt-in for this driver. So, we can't use deferred probing for requesting DMA channels in probe, because our driver would get endlessly deferred if DMA support is compiled in AND the DMA driver is missing. Because we can't know when the DMA driver might show up, we always try again when a DMA transfer would be possible. The downside is that there is more overhead for setting up PIO transfers under the above scenario. But well, having DMA enabled and the proper DMA driver missing looks like a broken or test config anyhow. Reported-by: NGeert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
由 Wolfram Sang 提交于
Refactor DMA setup to keep the errno so we can implement better deferred probe support in the next step. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
- 12 12月, 2014 1 次提交
-
-
由 Wolfram Sang 提交于
We don't need the mask since we obtain the channels via DT. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
- 05 12月, 2014 1 次提交
-
-
由 Wolfram Sang 提交于
We can simply pass the pointer to the private structure to the irq routine instead of passing the platform device and looking up its driver_data. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Acked-by: NGeert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
- 19 11月, 2014 1 次提交
-
-
由 Wolfram Sang 提交于
It should be the DMA device, not the platform device. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Acked-by: NGeert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
- 13 11月, 2014 2 次提交
-
-
由 Wolfram Sang 提交于
No user needs magic hex values, makes this debug output. Add DMA info. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
由 Wolfram Sang 提交于
Make it possible to transfer i2c message buffers via DMA. Start/Stop/Sending_Slave_Address is still handled using the old state machine, it is sending the actual data that is done via DMA. This is least intrusive and allows us to work with the message buffers directly instead of preparing a custom buffer which involves copying the data around. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> [wsa: fixed an uninitialized var problem] Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
- 12 11月, 2014 1 次提交
-
-
由 Wolfram Sang 提交于
Improves readability and reduces chances of duplicates. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
- 10 11月, 2014 1 次提交
-
-
由 Geert Uytterhoeven 提交于
Add support for r8a73a4 (R-Mobile APE6) and sh73a0 (SH-Mobile AG5). On these SoCs, the operating clock runs faster that on previous SoCs, and the internal SCL clock counter gets incremented every 2 clocks of the operating clock, just like on R-Car Gen2. Cfr. the "/2" in the calculation of ICCL/ICCH in section "I2C Bus Interface (IIC)", subsection "Transfer Rate" of the datasheets. Signed-off-by: NGeert Uytterhoeven <geert+renesas@glider.be> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
- 08 11月, 2014 1 次提交
-
-
由 Wolfram Sang 提交于
We have a central copy of the GPL for that. Some addresses were already outdated. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com>
-
- 20 10月, 2014 1 次提交
-
-
由 Wolfram Sang 提交于
A platform_driver does not need to set an owner, it will be populated by the driver core. Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
- 02 6月, 2014 1 次提交
-
-
由 Wolfram Sang 提交于
Signed-off-by: NWolfram Sang <wsa@sang-engineering.com> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
- 22 5月, 2014 9 次提交
-
-
由 Wolfram Sang 提交于
Newer SoCs have so fast input clocks that the ICCL/H registers only count every second clock to have a meaningful 9-bit range. The driver was already prepared for that happening, but didn't use it so far. Add the proper DT configuration for SoCs that need it. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
由 Wolfram Sang 提交于
Due to misconfiguration, it can happen that the calculated timing parameters are out of range. Bail out if that happens. We can also simplify some logic later because of the verified value. Also, make the printouts of the values more precise by adding the hex-prefixes. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
由 Wolfram Sang 提交于
sh_mobile_i2c_init() could detect wrong settings, but didn't bail out, so it would continue unconfigured. Fix this. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
由 Wolfram Sang 提交于
Following the KISS principle, remove unneeded stuff. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
由 Wolfram Sang 提交于
This is what devm was made for. No rollback mechanism needed, remove the hook parameter from the irq setup function and simplify it. While we are here change some variables to proper types. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Reviewed-by: NGeert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
由 Wolfram Sang 提交于
Convert the easy parts to devm. irqs will be converted in a seperate patch to keep diffs readable. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Reviewed-by: NGeert Uytterhoeven <geert@linux-m68k.org> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
由 Wolfram Sang 提交于
Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
由 Wolfram Sang 提交于
Use standard i2c error codes for i2c failures. Also, don't print something on timeout since it happens regularly with i2c. Simplify some, logic, too. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
由 Wolfram Sang 提交于
No functional change, binaries are identical. Signed-off-by: NWolfram Sang <wsa+renesas@sang-engineering.com> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
- 31 10月, 2013 1 次提交
-
-
由 Laurent Pinchart 提交于
Turn clk_enable() and clk_disable() calls into clk_prepare_enable() and clk_disable_unprepare() to get ready for the migration to the common clock framework. Signed-off-by: NLaurent Pinchart <laurent.pinchart+renesas@ideasonboard.com> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
- 23 8月, 2013 1 次提交
-
-
由 Wolfram Sang 提交于
I2C of helpers used to live in of_i2c.c but experience (from SPI) shows that it is much cleaner to have this in the core. This also removes a circular dependency between the helpers and the core, and so we can finally register child nodes in the core instead of doing this manually in each driver. So, fix the drivers and documentation, too. Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
- 20 8月, 2013 1 次提交
-
-
由 Jingoo Han 提交于
Use the wrapper function for retrieving the platform data instead of accessing dev->platform_data directly. Signed-off-by: NJingoo Han <jg1.han@samsung.com> Signed-off-by: NWolfram Sang <wsa@the-dreams.de>
-
- 11 2月, 2013 4 次提交
-
-
由 Guennadi Liakhovetski 提交于
By default there should be no stop bit on I2C between single messages within transfers. Fix the driver to comply and only send a stop bit at the end of transfers or if I2C_M_STOP is set. Signed-off-by: NGuennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: NWolfram Sang <wolfram@the-dreams.de>
-
由 Guennadi Liakhovetski 提交于
Eliminate an open-coded "goto" loop by introducing a function. Signed-off-by: NGuennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: NWolfram Sang <wolfram@the-dreams.de>
-
由 Guennadi Liakhovetski 提交于
In a timeout case return an error immediately from the driver's .master_xfer() method, instead of continuing and letting higher layers fail. Signed-off-by: NGuennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: NWolfram Sang <wolfram@the-dreams.de>
-
由 Guennadi Liakhovetski 提交于
Reduce 2 boolean functions from "if (condition) return 1; return 0;" to "return condition;" Signed-off-by: NGuennadi Liakhovetski <g.liakhovetski@gmx.de> Signed-off-by: NWolfram Sang <wolfram@the-dreams.de>
-
- 23 12月, 2012 1 次提交
-
-
由 Bill Pemberton 提交于
CONFIG_HOTPLUG is going away as an option. As result the __dev* markings will be going away. Remove use of __devinit, __devexit_p, __devinitdata, __devinitconst, and __devexit. Signed-off-by: NBill Pemberton <wfp5p@virginia.edu> Acked-by: Peter Korsgaard <peter.korsgaard@barco.com> (for ocores and mux-gpio) Acked-by: Havard Skinnemoen <hskinnemoen@gmail.com> (for i2c-gpio) Acked-by: Guan Xuetao <gxt@mprc.pku.edu.cn> (for puf3) Acked-by: Barry Song <baohua.song@csr.com> (for sirf) Reviewed-by: NJean Delvare <khali@linux-fr.org> [wsa: Fixed "foo* bar" flaws while we are here] Signed-off-by: NWolfram Sang <w.sang@pengutronix.de>
-
- 16 11月, 2012 4 次提交
-
-
由 Shinya Kuribayashi 提交于
Ensure that any of preceding register write operations to the I2C hardware block reached the module, and the write data is reflected in the registers, before leaving the interrupt handler. Otherwise, we'll suffer from spurious WAIT interrupts that lead to 'Transfer request timed out' message, and the transaction failed. Reported-by: NTeppei Kamijou <teppei.kamijou.yb@renesas.com> Signed-off-by: NShinya Kuribayashi <shinya.kuribayashi.px@renesas.com> Signed-off-by: NWolfram Sang <w.sang@pengutronix.de>
-
由 Shinya Kuribayashi 提交于
On newer SH-/R-Mobile SoCs, a clock supply to the I2C hardware block, which is used to generate the SCL clock output, is getting faster than before, while on the other hand, the SCL clock control registers, ICCH and ICCL, stay unchanged in 9-bit-wide (8+1). On such silicons, the internal SCL clock counter gets incremented every 2 clocks of the operating clock. This patch makes it configurable through platform data. Signed-off-by: NShinya Kuribayashi <shinya.kuribayashi.px@renesas.com> Signed-off-by: NWolfram Sang <w.sang@pengutronix.de>
-
由 Shinya Kuribayashi 提交于
ICCH/ICCL values is supposed to be calculated/optimized to strictly meet the timing specs required by the I2C standard. The resulting I2C bus speed does not matter at all, if it's less than 100 or 400 kHz. With this change, sh_mobile_i2c_icch() is virtually identical to sh_mobile_i2c_iccl(), but they're providing good descriptions of SH-/R-Mobile I2C hardware spec, and I'd leave them as separated. Also fix a typo in the comment, print icch/iccl values at probe, etc. Signed-off-by: NShinya Kuribayashi <shinya.kuribayashi.px@renesas.com> [wsa: squashed two patches for bisectability] Signed-off-by: NWolfram Sang <w.sang@pengutronix.de>
-
由 Shinya Kuribayashi 提交于
Currently SCL clock parameters (ICCH/ICCL) are calculated in activate_ch(), which gets called every time sh_mobile_i2c_xfer() is processed, while each I2C bus speed is system-defined and in general those parameters do not have to be updated over I2C transactions. The only reason I could see having it transaction-time is to adjust ICCH/ICCL values according to the operating frequency of the I2C hardware block, in the face of DFS (Dynamic Frequency Scaling). However, this won't be necessary. The operating frequency of the I2C hardware block can change _even_ in the middle of I2C transactions. There is no way to prevent it from happening, and I2C hardware block can work with such dynamic frequency change, of course. Another is that ICCH/ICCL clock parameters optimized for the faster operating frequency, can also be applied to the slower operating frequency, as long as slave devices work. However, the converse is not true. It would violate SCL timing specs of the I2C standard. What we can do now is to calculate the ICCH/ICCL clock parameters according to the fastest operating clock of the I2C hardware block. And if that's the case, that calculation should be done just once at driver-module-init time. This patch moves ICCH/ICCL calculating part from activate_ch() into sh_mobile_i2c_init(), and call it from sh_mobile_i2c_probe(). Note that sh_mobile_i2c_init() just prepares clock parameters using the clock rate and platform data provided, but does _not_ make any hardware I/O accesses. We don't have to care about run-time PM maintenance here. Signed-off-by: NShinya Kuribayashi <shinya.kuribayashi.px@renesas.com> Signed-off-by: NWolfram Sang <w.sang@pengutronix.de>
-
- 12 5月, 2012 1 次提交
-
-
由 Magnus Damm 提交于
This patch enables DT support for the IIC driver used on SH-based SoCs such as sh7722 and sh7724 among others as well as SH-Mobile SoCs such as sh7367, sh7377, sh7372, sh73a0 and r8a7740. Tested with out-of-tree DT support code on the sh7372 Mackerel board. Signed-off-by: NMagnus Damm <damm@opensource.se> Signed-off-by: NWolfram Sang <w.sang@pengutronix.de>
-
- 29 10月, 2011 1 次提交
-
-
由 Yong Zhang 提交于
Since commit [c58543c8: genirq: Run irq handlers with interrupts disabled], We run all interrupt handlers with interrupts disabled and we even check and yell when an interrupt handler returns with interrupts enabled (see commit [b738a50a: genirq: Warn when handler enables interrupts]). So now this flag is a NOOP and can be removed. Signed-off-by: NYong Zhang <yong.zhang0@gmail.com> Acked-by: NWolfram Sang <w.sang@pengutronix.de> Acked-by: NLinus Walleij <linus.walleij@linaro.org> Acked-by: NBarry Song <21cnbao@gmail.com> Signed-off-by: NBen Dooks <ben-linux@fluff.org>
-
- 11 5月, 2011 2 次提交
-
-
由 Magnus Damm 提交于
Add support to the i2c-sh_mobile driver for setting the I2C bus speed using platform data. Signed-off-by: NMagnus Damm <damm@opensource.se> Signed-off-by: NBen Dooks <ben-linux@fluff.org>
-
由 Magnus Damm 提交于
Remove the clock string magic from the i2c-sh_mobile driver now when all platforms support clkdev properly. Signed-off-by: NMagnus Damm <damm@opensource.se> Signed-off-by: NBen Dooks <ben-linux@fluff.org>
-
- 18 4月, 2011 1 次提交
-
-
由 Guennadi Liakhovetski 提交于
This patch enables I2C driver autoloading on sh-mobile systems. Signed-off-by: NGuennadi Liakhovetski <g.liakhovetski@gmx.de> Reviewed-by: NSimon Horman <horms@verge.net.au> Cc: Magnus Damm <damm@opensource.se> Signed-off-by: NPaul Mundt <lethal@linux-sh.org>
-
- 04 8月, 2010 1 次提交
-
-
由 Magnus Damm 提交于
Update the i2c-sh_mobile driver to properly free interrupts. The function sh_mobile_i2c_hook_irqs() is fixed so module both unload and load are working as expected. Signed-off-by: NMagnus Damm <damm@opensource.se> Signed-off-by: NPaul Mundt <lethal@linux-sh.org>
-
- 07 4月, 2010 1 次提交
-
-
由 Magnus Damm 提交于
Add support for a new version of the IIC block found in the SH-Mobile ARM line of processors. Prototype patch written by Nishimoto-san. Tested on sh7377 and sh7372. Signed-off-by: NNISHIMOTO Hiroki <nishimoto.hiroki@renesas.com> Signed-off-by: NMagnus Damm <damm@opensource.se> Signed-off-by: NPaul Mundt <lethal@linux-sh.org>
-