i2c: dt binding documentation for the Digicolor I2C controller
Subsystems (3)
Baruch Siach
maintainerPATCH v2 1/2 i2c: dt binding documentation for the Digicolor I2C controller
The CX92755 is an SoC in the Conexant Digicolor series. This devicetree binding document describes the I2C controller on the CX92755 SoC, that is also shared by some other SoCs in the Digicolor series.
---
v2: no change
--- .../devicetree/bindings/i2c/i2c-digicolor.txt | 25 ++++++++++++++++++++++ 1 file changed, 25 insertions(+) create mode 100644 Documentation/devicetree/bindings/i2c/i2c-digicolor.txt
Documentation/devicetree/bindings/i2c/i2c-digicolor.txt new file +25 -0
@@ -0,0 +1,25 @@ +Conexant Digicolor I2C controller + +Required properties: + - compatible: must be "cnxt,cx92755-i2c" + - reg: physical address and length of the device registers + - interrupts: a single interrupt specifier + - clocks: clock for the device + - #address-cells: should be <1> + - #size-cells: should be <0> + +Optional properties: +- clock-frequency: the desired I2C bus clock frequency in Hz; in + absence of this property the default value is used (100 kHz). + +Example: + + i2c: i2c at f0000120 { + compatible = "cnxt,cx92755-i2c"; + reg = <0xf0000120 0x10>; + interrupts = <28>; + clocks = <&main_clk>; + clock-frequency = <100000>; + #address-cells = <1>; + #size-cells = <0>; + };
Signature · 1 line
2.1.4
Baruch Siach
maintainerPATCH v2 2/2 i2c: driver for the Conexant Digicolor I2C controller
---
v2:
* Address the comment of Wolfram Sang:
- Advertise the I2C_FUNC_NOSTART capability
- Rebase on v4.0-rc1
--- drivers/i2c/busses/Kconfig | 9 + drivers/i2c/busses/Makefile | 1 + drivers/i2c/busses/i2c-digicolor.c | 384 +++++++++++++++++++++++++++++++++++++ 3 files changed, 394 insertions(+) create mode 100644 drivers/i2c/busses/i2c-digicolor.c
drivers/i2c/busses/Kconfig +9 -0
@@ -485,6 +485,15 @@ config I2C_DESIGNWARE_BAYTRAIL the platform firmware controlling it. You should say Y if running on a BayTrail system using the AXP288. +config I2C_DIGICOLOR + tristate "Conexant Digicolor I2C driver" + depends on ARCH_DIGICOLOR + help + Support for Conexant Digicolor SoCs (CX92755) I2C controller driver. + + This driver can also be built as a module. If so, the module + will be called i2c-digicolor. + config I2C_EFM32 tristate "EFM32 I2C controller" depends on ARCH_EFM32 || COMPILE_TEST
drivers/i2c/busses/Makefile +1 -0
@@ -45,6 +45,7 @@ i2c-designware-platform-objs := i2c-designware-platdrv.o i2c-designware-platform-$(CONFIG_I2C_DESIGNWARE_BAYTRAIL) += i2c-designware-baytrail.o obj-$(CONFIG_I2C_DESIGNWARE_PCI) += i2c-designware-pci.o i2c-designware-pci-objs := i2c-designware-pcidrv.o +obj-$(CONFIG_I2C_DIGICOLOR) += i2c-digicolor.o obj-$(CONFIG_I2C_EFM32) += i2c-efm32.o obj-$(CONFIG_I2C_EG20T) += i2c-eg20t.o obj-$(CONFIG_I2C_EXYNOS5) += i2c-exynos5.o
drivers/i2c/busses/i2c-digicolor.c new file +384 -0
384 lines not on this page · raw message
Signature · 1 line
2.1.4
PATCH v2 2/2 i2c: driver for the Conexant Digicolor I2C controller
Quoted 6 lines · Baruch Siach
Signed-off-by Baruch Siach <[email protected]>---
v2:
* Address the comment of Wolfram Sang:
- Advertise theI2C_FUNC_NOSTARTcapability
- Rebase on v4.0-rc1
Please fix:
Applying: i2c: driver for the Conexant Digicolor I2C controller
CHECKPATCH
...
ERROR: code indent should use tabs where possible #119: FILE: drivers/i2c/busses/i2c-digicolor.c:68:
+ STATE_IDLE,$
WARNING: please, no spaces at the start of a line #119: FILE: drivers/i2c/busses/i2c-digicolor.c:68:
+ STATE_IDLE,$
ERROR: code indent should use tabs where possible #120: FILE: drivers/i2c/busses/i2c-digicolor.c:69:
+ STATE_START,$
WARNING: please, no spaces at the start of a line #120: FILE: drivers/i2c/busses/i2c-digicolor.c:69:
+ STATE_START,$
ERROR: code indent should use tabs where possible #121: FILE: drivers/i2c/busses/i2c-digicolor.c:70:
+ STATE_ADDR,$
WARNING: please, no spaces at the start of a line #121: FILE: drivers/i2c/busses/i2c-digicolor.c:70:
+ STATE_ADDR,$
ERROR: code indent should use tabs where possible #122: FILE: drivers/i2c/busses/i2c-digicolor.c:71:
+ STATE_WRITE,$
WARNING: please, no spaces at the start of a line #122: FILE: drivers/i2c/busses/i2c-digicolor.c:71:
+ STATE_WRITE,$
ERROR: code indent should use tabs where possible #123: FILE: drivers/i2c/busses/i2c-digicolor.c:72:
+ STATE_READ,$
WARNING: please, no spaces at the start of a line #123: FILE: drivers/i2c/busses/i2c-digicolor.c:72:
+ STATE_READ,$
ERROR: code indent should use tabs where possible #124: FILE: drivers/i2c/busses/i2c-digicolor.c:73:
+ STATE_STOP,$
WARNING: please, no spaces at the start of a line #124: FILE: drivers/i2c/busses/i2c-digicolor.c:73:
+ STATE_STOP,$
CHECK: spaces preferred around that '+' (ctx:VxV) #160: FILE: drivers/i2c/busses/i2c-digicolor.c:109:
+ bool last = (i2c->msgbuf_ptr+1 == i2c->msg->len);
^
WARNING: Missing a blank line after declarations #161: FILE: drivers/i2c/busses/i2c-digicolor.c:110:
+ bool last = (i2c->msgbuf_ptr+1 == i2c->msg->len);
+ dc_i2c_cmd(i2c, last ? II_CMD_GET_NOACK : II_CMD_GET_ACK);
CHECK: Logical continuations should be on the previous line #226: FILE: drivers/i2c/busses/i2c-digicolor.c:175:
+ if (cmd_status == II_CMD_STATUS_ACK_BAD
+ || cmd_status == II_CMD_STATUS_ABORT) {
CHECK: spaces preferred around that '-' (ctx:VxV) #329: FILE: drivers/i2c/busses/i2c-digicolor.c:278:
+ writeb_relaxed(clocktime-1, i2c->regs + II_CLOCKTIME);
^
There are more checkpatch warnings I don't care about much. You can decide about them.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 819 bytes
Desc: Digital signature
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20150319/2ee17fd3/attachment.sig>
Baruch Siach
maintainerPATCH v2 2/2 i2c: driver for the Conexant Digicolor I2C controller
Hi Wolfram,
Quoted 10 lines · Wolfram Sang
Quoted 6 lines · Baruch Siach
Signed-off-by Baruch Siach <[email protected]>---
v2:
* Address the comment of Wolfram Sang:
- Advertise theI2C_FUNC_NOSTARTcapability
- Rebase on v4.0-rc1Please fix:
Quoted 7 lines
Applying: i2c: driver for the Conexant Digicolor I2C controller
CHECKPATCH
...ERROR: code indent should use tabs where possible #119: FILE:
drivers/i2c/busses/i2c-digicolor.c:68:
+ STATE_IDLE,$
Sorry. I should have caught these earlier. Will fix.
[...]
Quoted 2 lines
There are more checkpatch warnings I don't care about much. You can decide about them.
Thanks,
baruch
Signature · 3 lines
http://baruch.siach.name/blog/ ~. .~ Tk Open Systems
=}------------------------------------------------ooO--U--Ooo------------{=
- baruch at tkos.co.il - tel: +972.2.679.5364, http://www.tkos.co.il -