Skip to content

[PW_SID:986678] Fix broken link with TH1520 GMAC when linkspeed changes - #708

Closed
linux-riscv-bot wants to merge 3 commits into
workflow__riscv__fixesfrom
pw986678
Closed

[PW_SID:986678] Fix broken link with TH1520 GMAC when linkspeed changes#708
linux-riscv-bot wants to merge 3 commits into
workflow__riscv__fixesfrom
pw986678

Conversation

@linux-riscv-bot

Copy link
Copy Markdown

PR for series 986678 applied to workflow__riscv__fixes

Name: Fix broken link with TH1520 GMAC when linkspeed changes
URL: https://patchwork.kernel.org/project/linux-riscv/list/?series=986678
Version: 1

ziyao233 added 3 commits July 29, 2025 10:22
Besides ones for GMAC core and peripheral registers, the TH1520 GMAC
requires one more clock for configuring APB glue registers. Describe
it in the binding.

Though the clock is essential for operation, it's not marked as required
for now to avoid introducing new dt-binding warnings to existing dts.

Fixes: f920ce0 ("dt-bindings: net: Add T-HEAD dwmac support")
Signed-off-by: Yao Zi <ziyao@disroot.org>
Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
It's necessary to adjust the MAC TX clock when the linkspeed changes,
but it's noted such adjustment always fails on TH1520 SoC, and reading
back from APB glue registers that control clock generation results in
garbage, causing broken link.

With some testing, it's found a clock must be ungated for access to APB
glue registers. Without any consumer, the clock is automatically
disabled during late kernel startup. Let's get and enable it if it's
described in devicetree.

Fixes: 33a1a01 ("net: stmmac: Add glue layer for T-HEAD TH1520 SoC")
Signed-off-by: Yao Zi <ziyao@disroot.org>
Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
Describe perisys-apb4-hclk as the APB clock for TH1520 SoC, which is
essential for accessing GMAC glue registers.

Fixes: 7e75667 ("riscv: dts: thead: Add TH1520 ethernet nodes")
Signed-off-by: Yao Zi <ziyao@disroot.org>
Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "[net,1/3] dt-bindings: net: thead,th1520-gmac: Describe APB interface clock"
build-rv32-defconfig
Desc: Builds riscv32 defconfig
Duration: 106.55 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "[net,1/3] dt-bindings: net: thead,th1520-gmac: Describe APB interface clock"
build-rv64-clang-allmodconfig
Desc: Builds riscv64 allmodconfig with Clang, and checks for errors and added warnings
Duration: 980.12 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "[net,1/3] dt-bindings: net: thead,th1520-gmac: Describe APB interface clock"
build-rv64-gcc-allmodconfig
Desc: Builds riscv64 allmodconfig with GCC, and checks for errors and added warnings
Duration: 1311.05 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "[net,1/3] dt-bindings: net: thead,th1520-gmac: Describe APB interface clock"
build-rv64-nommu-k210-defconfig
Desc: Builds riscv64 defconfig with NOMMU for K210
Duration: 21.08 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "[net,1/3] dt-bindings: net: thead,th1520-gmac: Describe APB interface clock"
build-rv64-nommu-k210-virt
Desc: Builds riscv64 defconfig with NOMMU for the virt platform
Duration: 22.48 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "[net,1/3] dt-bindings: net: thead,th1520-gmac: Describe APB interface clock"
checkpatch
Desc: Runs checkpatch.pl on the patch
Duration: 1.13 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "[net,1/3] dt-bindings: net: thead,th1520-gmac: Describe APB interface clock"
dtb-warn-rv64
Desc: Checks for Device Tree warnings/errors
Duration: 83.21 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "[net,1/3] dt-bindings: net: thead,th1520-gmac: Describe APB interface clock"
header-inline
Desc: Detects static functions without inline keyword in header files
Duration: 0.24 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "[net,1/3] dt-bindings: net: thead,th1520-gmac: Describe APB interface clock"
kdoc
Desc: Detects for kdoc errors
Duration: 3.70 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "[net,1/3] dt-bindings: net: thead,th1520-gmac: Describe APB interface clock"
module-param
Desc: Detect module_param changes
Duration: 0.26 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "[net,1/3] dt-bindings: net: thead,th1520-gmac: Describe APB interface clock"
verify-fixes
Desc: Verifies that the Fixes: tags exist
Duration: 0.28 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 1: "[net,1/3] dt-bindings: net: thead,th1520-gmac: Describe APB interface clock"
verify-signedoff
Desc: Verifies that Signed-off-by: tags are correct
Duration: 0.31 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 2: "[net,2/3] net: stmmac: thead: Get and enable APB clock on initialization"
build-rv32-defconfig
Desc: Builds riscv32 defconfig
Duration: 106.27 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 2: "[net,2/3] net: stmmac: thead: Get and enable APB clock on initialization"
build-rv64-clang-allmodconfig
Desc: Builds riscv64 allmodconfig with Clang, and checks for errors and added warnings
Duration: 1004.27 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 2: "[net,2/3] net: stmmac: thead: Get and enable APB clock on initialization"
build-rv64-gcc-allmodconfig
Desc: Builds riscv64 allmodconfig with GCC, and checks for errors and added warnings
Duration: 1359.24 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 2: "[net,2/3] net: stmmac: thead: Get and enable APB clock on initialization"
build-rv64-nommu-k210-defconfig
Desc: Builds riscv64 defconfig with NOMMU for K210
Duration: 21.22 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 2: "[net,2/3] net: stmmac: thead: Get and enable APB clock on initialization"
build-rv64-nommu-k210-virt
Desc: Builds riscv64 defconfig with NOMMU for the virt platform
Duration: 22.44 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 2: "[net,2/3] net: stmmac: thead: Get and enable APB clock on initialization"
checkpatch
Desc: Runs checkpatch.pl on the patch
Duration: 0.78 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 2: "[net,2/3] net: stmmac: thead: Get and enable APB clock on initialization"
dtb-warn-rv64
Desc: Checks for Device Tree warnings/errors
Duration: 71.87 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 2: "[net,2/3] net: stmmac: thead: Get and enable APB clock on initialization"
header-inline
Desc: Detects static functions without inline keyword in header files
Duration: 0.24 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 2: "[net,2/3] net: stmmac: thead: Get and enable APB clock on initialization"
kdoc
Desc: Detects for kdoc errors
Duration: 0.91 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 2: "[net,2/3] net: stmmac: thead: Get and enable APB clock on initialization"
module-param
Desc: Detect module_param changes
Duration: 0.26 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 2: "[net,2/3] net: stmmac: thead: Get and enable APB clock on initialization"
verify-fixes
Desc: Verifies that the Fixes: tags exist
Duration: 0.29 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 2: "[net,2/3] net: stmmac: thead: Get and enable APB clock on initialization"
verify-signedoff
Desc: Verifies that Signed-off-by: tags are correct
Duration: 0.31 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 3: "[net,3/3] riscv: dts: thead: Add APB clocks for TH1520 GMACs"
build-rv32-defconfig
Desc: Builds riscv32 defconfig
Duration: 106.60 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 3: "[net,3/3] riscv: dts: thead: Add APB clocks for TH1520 GMACs"
build-rv64-clang-allmodconfig
Desc: Builds riscv64 allmodconfig with Clang, and checks for errors and added warnings
Duration: 1039.34 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 3: "[net,3/3] riscv: dts: thead: Add APB clocks for TH1520 GMACs"
build-rv64-gcc-allmodconfig
Desc: Builds riscv64 allmodconfig with GCC, and checks for errors and added warnings
Duration: 1405.74 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 3: "[net,3/3] riscv: dts: thead: Add APB clocks for TH1520 GMACs"
build-rv64-nommu-k210-defconfig
Desc: Builds riscv64 defconfig with NOMMU for K210
Duration: 21.16 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 3: "[net,3/3] riscv: dts: thead: Add APB clocks for TH1520 GMACs"
build-rv64-nommu-k210-virt
Desc: Builds riscv64 defconfig with NOMMU for the virt platform
Duration: 22.47 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 3: "[net,3/3] riscv: dts: thead: Add APB clocks for TH1520 GMACs"
checkpatch
Desc: Runs checkpatch.pl on the patch
Duration: 0.73 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 3: "[net,3/3] riscv: dts: thead: Add APB clocks for TH1520 GMACs"
dtb-warn-rv64
Desc: Checks for Device Tree warnings/errors
Duration: 71.75 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 3: "[net,3/3] riscv: dts: thead: Add APB clocks for TH1520 GMACs"
header-inline
Desc: Detects static functions without inline keyword in header files
Duration: 0.24 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 3: "[net,3/3] riscv: dts: thead: Add APB clocks for TH1520 GMACs"
kdoc
Desc: Detects for kdoc errors
Duration: 0.82 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 3: "[net,3/3] riscv: dts: thead: Add APB clocks for TH1520 GMACs"
module-param
Desc: Detect module_param changes
Duration: 0.25 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 3: "[net,3/3] riscv: dts: thead: Add APB clocks for TH1520 GMACs"
verify-fixes
Desc: Verifies that the Fixes: tags exist
Duration: 0.27 seconds
Result: PASS

@linux-riscv-bot

Copy link
Copy Markdown
Author

Patch 3: "[net,3/3] riscv: dts: thead: Add APB clocks for TH1520 GMACs"
verify-signedoff
Desc: Verifies that Signed-off-by: tags are correct
Duration: 0.31 seconds
Result: PASS

@linux-riscv-bot
linux-riscv-bot deleted the pw986678 branch July 29, 2025 20:23
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants