mbox series

[v8,0/4] Add Naneng combo PHY support for RK3568

Message ID 20220208091326.12495-1-yifeng.zhao@rock-chips.com
Headers show
Series Add Naneng combo PHY support for RK3568 | expand

Message

Yifeng Zhao Feb. 8, 2022, 9:13 a.m. UTC
This phy can be used as pcie-phy, usb3-phy, sata-phy or sgmii-phy.

Changes in v8:
- rename 'mode' to 'type'
- using devm_reset_control_array_get_exclusive
- move rockchip_combphy_set_mode into rockchip_combphy_init

Changes in v7:
- remove u3otg0_port_en, u3otg1_port_en and pipe_sgmii_mac_sel
- rename regs

Changes in v5:
- modify description for ssc and ext-refclk
- remove apb reset
- add rockchip_combphy_updatel()
- restyle

Changes in v4:
- restyle
- remove some minItems
- add more properties
- remove reset-names
- move #phy-cells
- add rockchip,rk3568-pipe-grf
- add rockchip,rk3568-pipe-phy-grf
- add devm_reset_control_array_get()
- remove clk structure
- change refclk DT parse
- change dev_err message
- add dot to phrase
- add ext_refclk variable
- add enable_ssc variable
- rename rockchip_combphy_param_write
- remove param_read
- replace rockchip-naneng-combphy driver name
- rename node name

Changes in v3:
- Using api devm_reset_control_get_optional_exclusive and dev_err_probe.
- Remove apb_rst.
- Redefine registers address.
- Move pipe_phy_grf0 to rk3568.dtsi

Changes in v2:
- Fix dtschema/dtc warnings/errors
- Using api devm_platform_get_and_ioremap_resource.
- Modify rockchip_combphy_set_Mode.
- Add some PHY registers definition.
- Move phy0 to rk3568.dtsi

Johan Jonker (1):
  dt-bindings: soc: grf: add naneng combo phy register compatible

Yifeng Zhao (3):
  dt-bindings: phy: rockchip: Add Naneng combo PHY bindings
  phy: rockchip: add naneng combo phy for RK3568
  arm64: dts: rockchip: add naneng combo phy nodes for rk3568

 .../phy/phy-rockchip-naneng-combphy.yaml      | 109 ++++
 .../devicetree/bindings/soc/rockchip/grf.yaml |   2 +
 arch/arm64/boot/dts/rockchip/rk3568.dtsi      |  21 +
 arch/arm64/boot/dts/rockchip/rk356x.dtsi      |  47 ++
 drivers/phy/rockchip/Kconfig                  |   8 +
 drivers/phy/rockchip/Makefile                 |   1 +
 .../rockchip/phy-rockchip-naneng-combphy.c    | 581 ++++++++++++++++++
 7 files changed, 769 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/phy/phy-rockchip-naneng-combphy.yaml
 create mode 100644 drivers/phy/rockchip/phy-rockchip-naneng-combphy.c

Comments

Rob Herring Feb. 28, 2022, 7:17 p.m. UTC | #1
On Tue, Feb 8, 2022 at 3:15 AM Yifeng Zhao <yifeng.zhao@rock-chips.com> wrote:
>
> Add the compatible strings for the Naneng combo PHY found on rockchip SoC.
>
> Reviewed-by: Rob Herring <robh@kernel.org>
> Signed-off-by: Yifeng Zhao <yifeng.zhao@rock-chips.com>
> Signed-off-by: Johan Jonker <jbx6244@gmail.com>
> ---
>
> Changes in v8: None
> Changes in v7:
> - remove u3otg0_port_en, u3otg1_port_en and pipe_sgmii_mac_sel
>
> Changes in v5:
> - modify description for ssc and ext-refclk
> - remove apb reset
>
> Changes in v4:
> - restyle
> - remove some minItems
> - add more properties
> - remove reset-names
> - move #phy-cells
> - add rockchip,rk3568-pipe-grf
> - add rockchip,rk3568-pipe-phy-grf
>
> Changes in v3: None
> Changes in v2:
> - Fix dtschema/dtc warnings/errors
>
>  .../phy/phy-rockchip-naneng-combphy.yaml      | 109 ++++++++++++++++++
>  1 file changed, 109 insertions(+)
>  create mode 100644 Documentation/devicetree/bindings/phy/phy-rockchip-naneng-combphy.yaml

This now fails in linux-next:

/builds/robherring/linux-dt/Documentation/devicetree/bindings/phy/phy-rockchip-naneng-combphy.example.dt.yaml:
syscon@fdc50000: compatible: 'oneOf' conditional failed, one must be
fixed:
 ['rockchip,rk3568-pipe-grf', 'syscon'] is too short
 'rockchip,rk3568-pipe-grf' is not one of ['rockchip,rk3288-sgrf',
'rockchip,rk3568-usb2phy-grf', 'rockchip,rv1108-usbgrf']
Peter Geis Feb. 28, 2022, 9:36 p.m. UTC | #2
On Mon, Feb 28, 2022 at 2:18 PM Rob Herring <robh+dt@kernel.org> wrote:
>
> On Tue, Feb 8, 2022 at 3:15 AM Yifeng Zhao <yifeng.zhao@rock-chips.com> wrote:
> >
> > Add the compatible strings for the Naneng combo PHY found on rockchip SoC.
> >
> > Reviewed-by: Rob Herring <robh@kernel.org>
> > Signed-off-by: Yifeng Zhao <yifeng.zhao@rock-chips.com>
> > Signed-off-by: Johan Jonker <jbx6244@gmail.com>
> > ---
> >
> > Changes in v8: None
> > Changes in v7:
> > - remove u3otg0_port_en, u3otg1_port_en and pipe_sgmii_mac_sel
> >
> > Changes in v5:
> > - modify description for ssc and ext-refclk
> > - remove apb reset
> >
> > Changes in v4:
> > - restyle
> > - remove some minItems
> > - add more properties
> > - remove reset-names
> > - move #phy-cells
> > - add rockchip,rk3568-pipe-grf
> > - add rockchip,rk3568-pipe-phy-grf
> >
> > Changes in v3: None
> > Changes in v2:
> > - Fix dtschema/dtc warnings/errors
> >
> >  .../phy/phy-rockchip-naneng-combphy.yaml      | 109 ++++++++++++++++++
> >  1 file changed, 109 insertions(+)
> >  create mode 100644 Documentation/devicetree/bindings/phy/phy-rockchip-naneng-combphy.yaml
>
> This now fails in linux-next:
>
> /builds/robherring/linux-dt/Documentation/devicetree/bindings/phy/phy-rockchip-naneng-combphy.example.dt.yaml:
> syscon@fdc50000: compatible: 'oneOf' conditional failed, one must be
> fixed:
>  ['rockchip,rk3568-pipe-grf', 'syscon'] is too short
>  'rockchip,rk3568-pipe-grf' is not one of ['rockchip,rk3288-sgrf',
> 'rockchip,rk3568-usb2phy-grf', 'rockchip,rv1108-usbgrf']
> From schema: /builds/robherring/linux-dt/Documentation/devicetree/bindings/soc/rockchip/grf.yaml
> /builds/robherring/linux-dt/Documentation/devicetree/bindings/phy/phy-rockchip-naneng-combphy.example.dt.yaml:
> syscon@fdc70000: compatible: 'oneOf' conditional failed, one must be
> fixed:
>  ['rockchip,rk3568-pipe-phy-grf', 'syscon'] is too short
>  'rockchip,rk3568-pipe-phy-grf' is not one of ['rockchip,rk3288-sgrf',
> 'rockchip,rk3568-usb2phy-grf', 'rockchip,rv1108-usbgrf']
> From schema: /builds/robherring/linux-dt/Documentation/devicetree/bindings/soc/rockchip/grf.yaml
>
>
> The problem appears to be that patch 1 was applied incorrectly and the
> compatibles ended up in the wrong section (the one requiring
> 'simple-mfd'). Patch 1 probably conflicts as my bot will just skip the
> patch if it conflicts which is why this had a different error report.

Good Afternoon Rob,

This is fixed in the first patch of my rk356x dwc3 enablement series:
https://patchwork.kernel.org/project/linux-rockchip/patch/20220228135700.1089526-2-pgwipeout@gmail.com/

Very Respectfully,
Peter Geis

>
> Rob
>
> _______________________________________________
> Linux-rockchip mailing list
> Linux-rockchip@lists.infradead.org
> http://lists.infradead.org/mailman/listinfo/linux-rockchip