Skip to content

Commit 5094bf6

Browse files
committed
[nrf fromlist] soc: nordic: nrf54h20: Make HSFLL trims optional
Upstream PR: zephyrproject-rtos/zephyr#71536 If no HSFLL needs trimming, then `trim_hsfll()` should be compiled out. This makes it easier to reuse the rest of `soc.c` out of tree. Furthermore, some HSFLL instances can be trimmed before booting Zephyr, so the FICR client properties in the DT binding should not be required. Signed-off-by: Grzegorz Swiderski <[email protected]> (cherry picked from commit 0803dc254b193dd10d94a99ca1289318d483087f)
1 parent 326effc commit 5094bf6

File tree

2 files changed

+4
-6
lines changed

2 files changed

+4
-6
lines changed

dts/bindings/clock/nordic,nrf-hsfll.yaml

Lines changed: 0 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -57,9 +57,3 @@ properties:
5757
- 368000000
5858
- 384000000
5959
- 400000000
60-
61-
nordic,ficrs:
62-
required: true
63-
64-
nordic,ficr-names:
65-
required: true

soc/arm/nordic_nrf/nrf54h/soc.c

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -48,6 +48,8 @@ static void power_domain_init(void)
4848

4949
static int trim_hsfll(void)
5050
{
51+
#if defined(HSFLL_NODE)
52+
5153
NRF_HSFLL_Type *hsfll = (NRF_HSFLL_Type *)DT_REG_ADDR(HSFLL_NODE);
5254
nrf_hsfll_trim_t trim = {
5355
.vsup = sys_read32(FICR_ADDR_GET(HSFLL_NODE, vsup)),
@@ -70,6 +72,8 @@ static int trim_hsfll(void)
7072
LOG_DBG("NRF_HSFLL->TRIM.COARSE = %d", hsfll->TRIM.COARSE);
7173
LOG_DBG("NRF_HSFLL->TRIM.FINE = %d", hsfll->TRIM.FINE);
7274

75+
#endif /* defined(HSFLL_NODE) */
76+
7377
return 0;
7478
}
7579

0 commit comments

Comments
 (0)