Skip to content

Commit 8eb050c

Browse files
FRASTMcfriedt
authored andcommitted
dts: clock: stm32 configure ahb prescaler for HCLK
AHB prescaler is a value which divides the SYSCLOCK to provide the HCLK. The HCLK supplies the core, AHB bus, memory. On the stm32wb and stm32wl, the HCLK for CPU1 is HCLK1 with cpu1-prescaler. By default the value is 1, else the HCLK must be correctly set. Signed-off-by: Francois Ramu <[email protected]>
1 parent f371ae3 commit 8eb050c

File tree

2 files changed

+23
-7
lines changed

2 files changed

+23
-7
lines changed

dts/bindings/clock/st,stm32-rcc.yaml

Lines changed: 9 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -58,12 +58,18 @@ properties:
5858
required: false
5959
enum:
6060
- 1
61+
- 2
62+
- 4
63+
- 8
64+
- 16
65+
- 64
66+
- 128
67+
- 256
68+
- 512
6169
description: |
6270
AHB prescaler. Sets a HCLK frequency (feeding Cortex-M Systick)
6371
lower than SYSCLK frequency (actual core frequency).
64-
Zephyr doesn't make a difference today between these two clocks.
65-
Changing this prescaler is not allowed until it is made possible to
66-
use them independently in Zephyr clock subsystem.
72+
The HCLK clocks CPU, AHB, memories and DMA.
6773
6874
apb1-prescaler:
6975
type: int

dts/bindings/clock/st,stm32wb-rcc.yaml

Lines changed: 14 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -18,13 +18,23 @@ properties:
1818
required: false
1919
enum:
2020
- 1
21+
- 2
22+
- 3
23+
- 4
24+
- 5
25+
- 6
26+
- 8
27+
- 10
28+
- 16
29+
- 32
30+
- 64
31+
- 128
32+
- 256
33+
- 512
2134
description: |
2235
CPU1 prescaler. Sets a HCLK1 frequency (feeding Cortex-M Systick)
2336
lower than SYSCLK frequency (actual core frequency).
24-
Zephyr doesn't make a difference today between these two clocks.
25-
Changing this prescaler is not allowed until it is made possible to
26-
use them independently in Zephyr clock subsystem.
27-
HCLK1 clocks CPU1, AHB1, AHB2, AHB3 and SRAM1.
37+
The HCLK1 clocks CPU1, AHB1, AHB2, AHB3 and SRAM1.
2838
2939
cpu2-prescaler:
3040
type: int

0 commit comments

Comments
 (0)