net: phy: Introduce PHY Package concept
Status from this message: This series was applied to netdev/net-next.git (main)
Get series with b4
b4 am [email protected]Versions newest first · linked by author and title
- v7 Latest10 patches 7 repliesApplied 10/10
- v610 patches 2 repliesSuperseded
- v59 patches 31 repliesSuperseded
Earlier versions · 3
| Version | Posted | Patches | Replies | Status |
|---|---|---|---|---|
| v3 RFC | 8 patches | 24 replies | Superseded | |
| v2 RFC | 11 patches | 6 replies | Superseded | |
| v1 RFC | 14 patches | 39 replies | Superseded |
Changes in v7 from the cover letter
- Rebase on top of net-next
- Add Reviewed-by tag for DT patch
- Change tx-driver-strength to tx-drive-strength
- Drop driver reference in DT
Patches in v7 All 10 applied
| # | Subject and files | Size | Replies | Applied |
|---|---|---|---|---|
| 1/10 | dt-bindings: net: document ethernet PHY package nodesDocumentation/ | +52 | 0 replies | Applied |
| 2/10 | net: phy: add support for scanning PHY in PHY packages nodesdrivers/ drivers/ | +92 | 1 reply | Applied |
| 3/10 | net: phy: add devm/of_phy_package_join helperdrivers/ include/ | +102 | 1 reply | Applied |
| 4/10 | net: phy: qcom: move more function to shared librarydrivers/ drivers/ drivers/ +1 more | +244 | 1 reply | Applied |
| 5/10 | dt-bindings: net: Document Qcom QCA807x PHY packageDocumentation/ | +184 | 1 reply | Applied |
| 6/10 | net: phy: provide whether link has changed in c37_read_statusdrivers/ drivers/ drivers/ +1 more | +14 | 1 reply | Applied |
| 7/10 | net: phy: qcom: add support for QCA807x PHY Familydrivers/ drivers/ drivers/ | +606 | 1 reply | Applied |
| 8/10 | net: phy: qcom: move common qca808x LED define to shared headerdrivers/ drivers/ | +65 | 1 reply | Applied |
| 9/10 | net: phy: qcom: generalize some qca808x LED functionsdrivers/ drivers/ drivers/ | +65 | 0 replies | Applied |
| 10/10 | net: phy: qca807x: add support for configurable LEDdrivers/ | +254 | 0 replies | Applied |
Reviews trailers per patch
7 of 10 patches have a Reviewed-by or Acked-by.
| Patch | Conor Dooley | Andrew Lunn |
|---|---|---|
| 1/10 | ||
| 2/10 | R-b | |
| 3/10 | R-b | |
| 4/10 | R-b | |
| 5/10 | R-b | R-b |
| 6/10 | R-b | |
| 7/10 | R-b | |
| 8/10 | R-b | |
| 9/10 | ||
| 10/10 |
Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes.
Cover letter [net-next PATCH v7 00/10] net: phy: Introduce PHY Package concept
Idea of this big series is to introduce the concept of PHY package in DT and give PHY drivers a way to derive the base address from DT.
The concept of PHY package is nothing new and is already a thing in the kernel with the API phy_package_join/leave/read/write.
What is currently lacking is describing this in DT and better reference a base address to calculate offset from.
In the scenario of a PHY package where multiple address are used and there isn't a way to get the base address of the PHY package from some regs, getting the information from DT is the only way.
A possible example to this problem is this:
ethernet-phy-package@0 {
compatible = "qcom,qca8075-package";
#address-cells = <1>;
#size-cells = <0>;
reg = <0>;
qcom,package-mode = "qsgmii";
ethernet-phy@1 {
reg = <1>;
};
phy4: ethernet-phy@4 {
reg = <4>;
};
};The mdio parse functions are changed to address for this additional special node, the function is changed to simply detect this node and search also in this. (we match the node name to be "ethernet-phy-package")
PHY driver can then use introduced helper of_phy_package_join to join the PHY to the PHY package and derive the base address from DT.
Changes v7:
- Rebase on top of net-next
- Add Reviewed-by tag for DT patch
- Change tx-driver-strength to tx-drive-strength
- Drop driver reference in DT
Changes v6:
- Back to absolute PHY implementation
- Correctly drop refcount for node on error condition and on PHY leave
- Drop DT include patch in favor for 3 boolean vendor property
- Fix Documentation problem for compatible and missing type and description
- Drop redundand gpio-controller dependency and description
- Skip scanphy with invalid PHY Package node and make reg mandatory
- Rework fiber read status to use more generic function
- Split qca808x LED generalization patch to permit easier review
- Correctly return -EINVAL with wrong data passed to vendor property
- Drop removing LED ops for qca807x PHY driver with gpio-controller Changes v5:
- Rebase on top of net-next
- Change implementation to base addr + offset in subnode
- Adapt to all the changes and cleanup done to at803x Changes v4:
- Rework DT implementation
- Drop of autojoin support and rework to simple helper
- Rework PHY driver to the new implementation
- Add compatible for qca807x package
- Further cleanup patches
Changes v3:
- Add back compatible implementation
- Detach patch that can be handled separately (phy_package_mmd, phy_package extended)
- Rework code to new simplified implementation with base addr + offset
- Improve documentation with additional info and description Changes v2:
- Drop compatible "ethernet-phy-package", use node name prefix matching instead
- Improve DT example
- Add reg for ethernet-phy-package
- Drop phy-mode for ethernet-phy-package
- Drop patch for generalization of phy-mode
- Drop global-phy property (handle internally to the PHY driver)
- Rework OF phy package code and PHY driver to handle base address
- Fix missing of_node_put
- Add some missing docs for added variables in struct
- Move some define from dt-bindings include to PHY driver
- Handle qsgmii validation in PHY driver
- Fix wrong include for gpiolib
- Drop reduntant version.h include
Christian Marangi (9):
dt-bindings: net: document ethernet PHY package nodes
net: phy: add support for scanning PHY in PHY packages nodes
net: phy: add devm/of_phy_package_join helper
net: phy: qcom: move more function to shared library
dt-bindings: net: Document Qcom QCA807x PHY package
net: phy: provide whether link has changed in c37_read_status
net: phy: qcom: move common qca808x LED define to shared header
net: phy: qcom: generalize some qca808x LED functions
net: phy: qca807x: add support for configurable LED
Robert Marko (1):
net: phy: qcom: add support for QCA807x PHY Family
.../bindings/net/ethernet-phy-package.yaml | 52 ++ .../devicetree/bindings/net/qcom,qca807x.yaml | 184 ++++ drivers/net/mdio/of_mdio.c | 79 +- drivers/net/phy/broadcom.c | 3 +- drivers/net/phy/mdio_bus.c | 44 +- drivers/net/phy/phy_device.c | 107 ++- drivers/net/phy/qcom/Kconfig | 8 + drivers/net/phy/qcom/Makefile | 1 + drivers/net/phy/qcom/at803x.c | 38 +- drivers/net/phy/qcom/qca807x.c | 849 ++++++++++++++++++ drivers/net/phy/qcom/qca808x.c | 308 +------ drivers/net/phy/qcom/qcom-phy-lib.c | 247 +++++ drivers/net/phy/qcom/qcom.h | 123 +++ include/linux/phy.h | 8 +- 14 files changed, 1676 insertions(+), 375 deletions(-) create mode 100644 Documentation/devicetree/bindings/net/ethernet-phy-package.yaml create mode 100644 Documentation/devicetree/bindings/net/qcom,qca807x.yaml create mode 100644 drivers/net/phy/qcom/qca807x.c
Signature · 1 line
2.43.0