Skip to content

Commit b3e9912

Browse files
robherringbebarino
authored andcommitted
dt-bindings: clock: fixed: Define a preferred node name
Define "clock-<freq>" as the preferred node name for fixed-clock and fixed-factor-clock where <freq> is the output frequency of the clock. There isn't much of an existing pattern for names of these nodes. The most frequent patterns are a prefix or suffix of "clk", but there's a bunch that don't follow any sort of pattern. We could use "clock-controller-.*", but these nodes aren't really a controller in any way. So let's at least align with part of that and use 'clock-'. For now this only serves as documentation as the schema still allows anything to avoid lots of additional warnings for something low priority to fix. Once a "no deprecated" mode is added to the tools, warnings can be enabled selectively. Signed-off-by: Rob Herring (Arm) <robh@kernel.org> Link: https://lore.kernel.org/r/20240430180415.657067-1-robh@kernel.org Acked-by: Conor Dooley <conor.dooley@microchip.com> Signed-off-by: Stephen Boyd <sboyd@kernel.org>
1 parent 4cece76 commit b3e9912

File tree

2 files changed

+18
-0
lines changed

2 files changed

+18
-0
lines changed

Documentation/devicetree/bindings/clock/fixed-clock.yaml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,15 @@ maintainers:
1111
- Stephen Boyd <sboyd@kernel.org>
1212

1313
properties:
14+
$nodename:
15+
anyOf:
16+
- description:
17+
Preferred name is 'clock-<freq>' with <freq> being the output
18+
frequency as defined in the 'clock-frequency' property.
19+
pattern: "^clock-([0-9]+|[a-z0-9-]+)$"
20+
- description: Any name allowed
21+
deprecated: true
22+
1423
compatible:
1524
const: fixed-clock
1625

Documentation/devicetree/bindings/clock/fixed-factor-clock.yaml

Lines changed: 9 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -11,6 +11,15 @@ maintainers:
1111
- Stephen Boyd <sboyd@kernel.org>
1212

1313
properties:
14+
$nodename:
15+
anyOf:
16+
- description:
17+
If the frequency is fixed, the preferred name is 'clock-<freq>' with
18+
<freq> being the output frequency.
19+
pattern: "^clock-([0-9]+|[0-9a-z-]+)$"
20+
- description: Any name allowed
21+
deprecated: true
22+
1423
compatible:
1524
enum:
1625
- fixed-factor-clock

0 commit comments

Comments
 (0)