* [PATCH v3 0/2] Add support for Etek ET7304 Controller
@ 2026-02-20 6:22 Yuanshen Cao
2026-02-20 6:22 ` [PATCH v3 1/2] dt-bindings: usb: document the Etek ET7304 USB Type-C Port Controller Yuanshen Cao
2026-02-20 6:22 ` [PATCH v3 2/2] usb: typec: tcpm: Add vid and chip info for Etek ET7304 Yuanshen Cao
0 siblings, 2 replies; 5+ messages in thread
From: Yuanshen Cao @ 2026-02-20 6:22 UTC (permalink / raw)
To: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski,
Conor Dooley, Heikki Krogerus
Cc: linux-usb, devicetree, linux-kernel, Yuanshen Cao
The Etek Micro ET7304 is a USB Type-C Port Controller with USB-PD used on
the Radxa Cubie A7Z.
According to the ET7304 datasheet [1] and the vendor BSP source code
provided by Radxa [2], this controller is functionally identical as
Richtek RT1715, with the only difference being the VID.
Add support for the ET7304 by registering its chip info in the driver.
Tested on Radxa Cubie A7Z.
[1] https://www.etekmicro.com/wp-content/uploads/datasheets/ET7304_datasheet.pdf
[2] https://github.com/radxa/allwinner-bsp/commit/156b6578cc173855b41ea311a229403ccbadb17c
Signed-off-by: Yuanshen Cao <alex.caoys@gmail.com>
---
Changes in v3:
- Reorder the table alphabetically
- Use etekmicro as the vender prefix
- Link to v2: https://lore.kernel.org/r/20260219-et7304-v2-0-b2e268494ae8@gmail.com/
Changes in v2:
- Put dt-bindings Documentation changes in a separate patch
- Add Etek to the vendor prefixes
- Link to v1: https://lore.kernel.org/r/20260217190010.67-1-alex.caoys@gmail.com/
---
Yuanshen Cao (2):
dt-bindings: usb: document the Etek ET7304 USB Type-C Port Controller
usb: typec: tcpm: Add vid and chip info for Etek ET7304
.../devicetree/bindings/usb/richtek,rt1711h.yaml | 3 ++-
Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 ++
drivers/usb/typec/tcpm/tcpci_rt1711h.c | 16 +++++++++++++++-
3 files changed, 19 insertions(+), 2 deletions(-)
---
base-commit: 8bf22c33e7a172fbc72464f4cc484d23a6b412ba
change-id: 20260220-et7304-d07e48fe2295
Best regards,
--
Yuanshen Cao <alex.caoys@gmail.com>
^ permalink raw reply [flat|nested] 5+ messages in thread* [PATCH v3 1/2] dt-bindings: usb: document the Etek ET7304 USB Type-C Port Controller 2026-02-20 6:22 [PATCH v3 0/2] Add support for Etek ET7304 Controller Yuanshen Cao @ 2026-02-20 6:22 ` Yuanshen Cao 2026-02-20 7:17 ` Krzysztof Kozlowski 2026-02-20 6:22 ` [PATCH v3 2/2] usb: typec: tcpm: Add vid and chip info for Etek ET7304 Yuanshen Cao 1 sibling, 1 reply; 5+ messages in thread From: Yuanshen Cao @ 2026-02-20 6:22 UTC (permalink / raw) To: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski, Conor Dooley, Heikki Krogerus Cc: linux-usb, devicetree, linux-kernel, Yuanshen Cao Document the ETEK Micro ET7304 USB Type-C Port Controller with USB-PD. Signed-off-by: Yuanshen Cao <alex.caoys@gmail.com> --- Documentation/devicetree/bindings/usb/richtek,rt1711h.yaml | 3 ++- Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 ++ 2 files changed, 4 insertions(+), 1 deletion(-) diff --git a/Documentation/devicetree/bindings/usb/richtek,rt1711h.yaml b/Documentation/devicetree/bindings/usb/richtek,rt1711h.yaml index ae611f7e57ca..1eb611f35998 100644 --- a/Documentation/devicetree/bindings/usb/richtek,rt1711h.yaml +++ b/Documentation/devicetree/bindings/usb/richtek,rt1711h.yaml @@ -19,10 +19,11 @@ description: | properties: compatible: enum: + - etekmicro,et7304 - richtek,rt1711h - richtek,rt1715 description: - RT1711H support PD20, RT1715 support PD30 except Fast Role Swap. + RT1711H support PD20, ET7304 and RT1715 support PD30 except Fast Role Swap. reg: maxItems: 1 diff --git a/Documentation/devicetree/bindings/vendor-prefixes.yaml b/Documentation/devicetree/bindings/vendor-prefixes.yaml index ee7fd3cfe203..5e504cebbcda 100644 --- a/Documentation/devicetree/bindings/vendor-prefixes.yaml +++ b/Documentation/devicetree/bindings/vendor-prefixes.yaml @@ -541,6 +541,8 @@ patternProperties: description: ESTeem Wireless Modems "^eswin,.*": description: Beijing ESWIN Technology Group Co. Ltd. + "^etekmicro,.*": + description: Wuxi ETEK Micro-Electronics Co.,Ltd. "^ettus,.*": description: NI Ettus Research "^eukrea,.*": -- 2.53.0 ^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH v3 1/2] dt-bindings: usb: document the Etek ET7304 USB Type-C Port Controller 2026-02-20 6:22 ` [PATCH v3 1/2] dt-bindings: usb: document the Etek ET7304 USB Type-C Port Controller Yuanshen Cao @ 2026-02-20 7:17 ` Krzysztof Kozlowski 0 siblings, 0 replies; 5+ messages in thread From: Krzysztof Kozlowski @ 2026-02-20 7:17 UTC (permalink / raw) To: Yuanshen Cao, Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski, Conor Dooley, Heikki Krogerus Cc: linux-usb, devicetree, linux-kernel On 20/02/2026 07:22, Yuanshen Cao wrote: > Document the ETEK Micro ET7304 USB Type-C Port Controller with USB-PD. > > Signed-off-by: Yuanshen Cao <alex.caoys@gmail.com> > --- > Documentation/devicetree/bindings/usb/richtek,rt1711h.yaml | 3 ++- > Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 ++ > 2 files changed, 4 insertions(+), 1 deletion(-) > Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com> Best regards, Krzysztof ^ permalink raw reply [flat|nested] 5+ messages in thread
* [PATCH v3 2/2] usb: typec: tcpm: Add vid and chip info for Etek ET7304 2026-02-20 6:22 [PATCH v3 0/2] Add support for Etek ET7304 Controller Yuanshen Cao 2026-02-20 6:22 ` [PATCH v3 1/2] dt-bindings: usb: document the Etek ET7304 USB Type-C Port Controller Yuanshen Cao @ 2026-02-20 6:22 ` Yuanshen Cao 2026-02-23 15:09 ` Heikki Krogerus 1 sibling, 1 reply; 5+ messages in thread From: Yuanshen Cao @ 2026-02-20 6:22 UTC (permalink / raw) To: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski, Conor Dooley, Heikki Krogerus Cc: linux-usb, devicetree, linux-kernel, Yuanshen Cao Move VID field to chip info to accommodate different VIDs. Add chip info for Etek Micro ET7304. ET7304 is functionally identical to the Richtek RT1715, with the only difference being the VID. Signed-off-by: Yuanshen Cao <alex.caoys@gmail.com> --- drivers/usb/typec/tcpm/tcpci_rt1711h.c | 16 +++++++++++++++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/drivers/usb/typec/tcpm/tcpci_rt1711h.c b/drivers/usb/typec/tcpm/tcpci_rt1711h.c index 88c50b984e8a..37cf55ad74f8 100644 --- a/drivers/usb/typec/tcpm/tcpci_rt1711h.c +++ b/drivers/usb/typec/tcpm/tcpci_rt1711h.c @@ -19,9 +19,11 @@ #include <linux/regulator/consumer.h> #define RT1711H_VID 0x29CF +#define ET7304_VID 0x6DCF #define RT1711H_PID 0x1711 #define RT1711H_DID 0x2171 #define RT1715_DID 0x2173 +#define ET7304_DID 0x2173 #define RT1711H_PHYCTRL1 0x80 #define RT1711H_PHYCTRL2 0x81 @@ -55,6 +57,7 @@ struct rt1711h_chip_info { u32 rxdz_sel; + u16 vid; u16 did; bool enable_pd30_extended_message; }; @@ -308,7 +311,7 @@ static int rt1711h_check_revision(struct i2c_client *i2c, struct rt1711h_chip *c ret = i2c_smbus_read_word_data(i2c, TCPC_VENDOR_ID); if (ret < 0) return ret; - if (ret != RT1711H_VID) { + if (ret != chip->info->vid) { dev_err(&i2c->dev, "vid is not correct, 0x%04x\n", ret); return -ENODEV; } @@ -405,17 +408,27 @@ static void rt1711h_remove(struct i2c_client *client) tcpci_unregister_port(chip->tcpci); } +static const struct rt1711h_chip_info et7304 = { + .rxdz_sel = RT1711H_BMCIO_RXDZSEL, + .vid = ET7304_VID, + .did = ET7304_DID, + .enable_pd30_extended_message = true, +}; + static const struct rt1711h_chip_info rt1711h = { + .vid = RT1711H_VID, .did = RT1711H_DID, }; static const struct rt1711h_chip_info rt1715 = { .rxdz_sel = RT1711H_BMCIO_RXDZSEL, + .vid = RT1711H_VID, .did = RT1715_DID, .enable_pd30_extended_message = true, }; static const struct i2c_device_id rt1711h_id[] = { + { "et7304", (kernel_ulong_t)&et7304 }, { "rt1711h", (kernel_ulong_t)&rt1711h }, { "rt1715", (kernel_ulong_t)&rt1715 }, {} @@ -423,6 +436,7 @@ static const struct i2c_device_id rt1711h_id[] = { MODULE_DEVICE_TABLE(i2c, rt1711h_id); static const struct of_device_id rt1711h_of_match[] = { + { .compatible = "etekmicro,et7304", .data = &et7304 }, { .compatible = "richtek,rt1711h", .data = &rt1711h }, { .compatible = "richtek,rt1715", .data = &rt1715 }, {} -- 2.53.0 ^ permalink raw reply related [flat|nested] 5+ messages in thread
* Re: [PATCH v3 2/2] usb: typec: tcpm: Add vid and chip info for Etek ET7304 2026-02-20 6:22 ` [PATCH v3 2/2] usb: typec: tcpm: Add vid and chip info for Etek ET7304 Yuanshen Cao @ 2026-02-23 15:09 ` Heikki Krogerus 0 siblings, 0 replies; 5+ messages in thread From: Heikki Krogerus @ 2026-02-23 15:09 UTC (permalink / raw) To: Yuanshen Cao Cc: Greg Kroah-Hartman, Rob Herring, Krzysztof Kozlowski, Conor Dooley, linux-usb, devicetree, linux-kernel Fri, Feb 20, 2026 at 06:22:41AM +0000, Yuanshen Cao wrote: > Move VID field to chip info to accommodate different VIDs. > Add chip info for Etek Micro ET7304. ET7304 is functionally > identical to the Richtek RT1715, with the only difference > being the VID. > > Signed-off-by: Yuanshen Cao <alex.caoys@gmail.com> Reviewed-by: Heikki Krogerus <heikki.krogerus@linux.intel.com> > --- > drivers/usb/typec/tcpm/tcpci_rt1711h.c | 16 +++++++++++++++- > 1 file changed, 15 insertions(+), 1 deletion(-) > > diff --git a/drivers/usb/typec/tcpm/tcpci_rt1711h.c b/drivers/usb/typec/tcpm/tcpci_rt1711h.c > index 88c50b984e8a..37cf55ad74f8 100644 > --- a/drivers/usb/typec/tcpm/tcpci_rt1711h.c > +++ b/drivers/usb/typec/tcpm/tcpci_rt1711h.c > @@ -19,9 +19,11 @@ > #include <linux/regulator/consumer.h> > > #define RT1711H_VID 0x29CF > +#define ET7304_VID 0x6DCF > #define RT1711H_PID 0x1711 > #define RT1711H_DID 0x2171 > #define RT1715_DID 0x2173 > +#define ET7304_DID 0x2173 > > #define RT1711H_PHYCTRL1 0x80 > #define RT1711H_PHYCTRL2 0x81 > @@ -55,6 +57,7 @@ > > struct rt1711h_chip_info { > u32 rxdz_sel; > + u16 vid; > u16 did; > bool enable_pd30_extended_message; > }; > @@ -308,7 +311,7 @@ static int rt1711h_check_revision(struct i2c_client *i2c, struct rt1711h_chip *c > ret = i2c_smbus_read_word_data(i2c, TCPC_VENDOR_ID); > if (ret < 0) > return ret; > - if (ret != RT1711H_VID) { > + if (ret != chip->info->vid) { > dev_err(&i2c->dev, "vid is not correct, 0x%04x\n", ret); > return -ENODEV; > } > @@ -405,17 +408,27 @@ static void rt1711h_remove(struct i2c_client *client) > tcpci_unregister_port(chip->tcpci); > } > > +static const struct rt1711h_chip_info et7304 = { > + .rxdz_sel = RT1711H_BMCIO_RXDZSEL, > + .vid = ET7304_VID, > + .did = ET7304_DID, > + .enable_pd30_extended_message = true, > +}; > + > static const struct rt1711h_chip_info rt1711h = { > + .vid = RT1711H_VID, > .did = RT1711H_DID, > }; > > static const struct rt1711h_chip_info rt1715 = { > .rxdz_sel = RT1711H_BMCIO_RXDZSEL, > + .vid = RT1711H_VID, > .did = RT1715_DID, > .enable_pd30_extended_message = true, > }; > > static const struct i2c_device_id rt1711h_id[] = { > + { "et7304", (kernel_ulong_t)&et7304 }, > { "rt1711h", (kernel_ulong_t)&rt1711h }, > { "rt1715", (kernel_ulong_t)&rt1715 }, > {} > @@ -423,6 +436,7 @@ static const struct i2c_device_id rt1711h_id[] = { > MODULE_DEVICE_TABLE(i2c, rt1711h_id); > > static const struct of_device_id rt1711h_of_match[] = { > + { .compatible = "etekmicro,et7304", .data = &et7304 }, > { .compatible = "richtek,rt1711h", .data = &rt1711h }, > { .compatible = "richtek,rt1715", .data = &rt1715 }, > {} > > -- > 2.53.0 -- heikki ^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2026-02-23 15:09 UTC | newest] Thread overview: 5+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2026-02-20 6:22 [PATCH v3 0/2] Add support for Etek ET7304 Controller Yuanshen Cao 2026-02-20 6:22 ` [PATCH v3 1/2] dt-bindings: usb: document the Etek ET7304 USB Type-C Port Controller Yuanshen Cao 2026-02-20 7:17 ` Krzysztof Kozlowski 2026-02-20 6:22 ` [PATCH v3 2/2] usb: typec: tcpm: Add vid and chip info for Etek ET7304 Yuanshen Cao 2026-02-23 15:09 ` Heikki Krogerus
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox