Devicetree
 help / color / mirror / Atom feed
* [PATCH v2 1/2] dtc: dt-check-style: Narrow disallowing of tab in DTS only to YAML
@ 2026-07-06 10:24 Krzysztof Kozlowski
  2026-07-06 10:24 ` [PATCH v2 2/2] dtc: dt-check-style: Allow space-aligning indentation in DTS Krzysztof Kozlowski
  0 siblings, 1 reply; 4+ messages in thread
From: Krzysztof Kozlowski @ 2026-07-06 10:24 UTC (permalink / raw)
  To: Rob Herring, Saravana Kannan, devicetree, linux-kernel
  Cc: Krzysztof Kozlowski

DTS in the bindings (example in a YAML file) does not have tabs at all,
but regular DTS do, therefore entire check check_tab_in_dts() has
confusing name and should apply only to YAML files.

Signed-off-by: Krzysztof Kozlowski <krzysztof.kozlowski@oss.qualcomm.com>

---

Changes in v2:
1. New patch
---
 scripts/dtc/dt-check-style | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/scripts/dtc/dt-check-style b/scripts/dtc/dt-check-style
index 2d5723d41ea3..34e0f7e2a57a 100755
--- a/scripts/dtc/dt-check-style
+++ b/scripts/dtc/dt-check-style
@@ -340,7 +340,7 @@ def check_trailing_whitespace(ctx):
             yield (dl.lineno, 'trailing whitespace')
 
 
-def check_tab_in_dts(ctx):
+def check_tab_in_yaml_example(ctx):
     """Reject literal tabs in DTS lines when input is YAML.
 
     For YAML examples, indent and content must use spaces. Tabs inside
@@ -929,7 +929,7 @@ RULES = [
          check_trailing_whitespace),
     Rule('tab-in-dts', 'relaxed',
          'YAML examples may not contain tab characters',
-         check_tab_in_dts, applies_to=('yaml',)),
+         check_tab_in_yaml_example, applies_to=('yaml',)),
     Rule('mixed-indent-chars', 'relaxed',
          'indent must not mix tabs and spaces',
          check_mixed_indent_chars),
-- 
2.53.0


^ permalink raw reply related	[flat|nested] 4+ messages in thread

end of thread, other threads:[~2026-07-06 15:32 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-07-06 10:24 [PATCH v2 1/2] dtc: dt-check-style: Narrow disallowing of tab in DTS only to YAML Krzysztof Kozlowski
2026-07-06 10:24 ` [PATCH v2 2/2] dtc: dt-check-style: Allow space-aligning indentation in DTS Krzysztof Kozlowski
2026-07-06 10:31   ` sashiko-bot
2026-07-06 15:32     ` Krzysztof Kozlowski

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox