Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

dt-bindings: Add running yamllint to dt_binding_check

Add a yamllint config file and support for running yamllint on DT
binding schema files. This runs on the whole tree as yamllint is Python
and suffers from Python's slow startup times.

Users can run on individual files doing:

yamllint -c Documentation/devicetree/bindings/.yamllint <binding file>

Link: https://lore.kernel.org/r/20201009170557.168785-1-robh@kernel.org
Signed-off-by: Rob Herring <robh@kernel.org>

+47 -1
+39
Documentation/devicetree/bindings/.yamllint
··· 1 + extends: relaxed 2 + 3 + rules: 4 + line-length: 5 + # 80 chars should be enough, but don't fail if a line is longer 6 + max: 110 7 + allow-non-breakable-words: true 8 + level: warning 9 + braces: 10 + min-spaces-inside: 0 11 + max-spaces-inside: 1 12 + min-spaces-inside-empty: 0 13 + max-spaces-inside-empty: 0 14 + brackets: 15 + min-spaces-inside: 0 16 + max-spaces-inside: 1 17 + min-spaces-inside-empty: 0 18 + max-spaces-inside-empty: 0 19 + colons: {max-spaces-before: 0, max-spaces-after: 1} 20 + commas: {min-spaces-after: 1, max-spaces-after: 1} 21 + comments: 22 + require-starting-space: false 23 + min-spaces-from-content: 1 24 + comments-indentation: disable 25 + document-start: 26 + present: true 27 + empty-lines: 28 + max: 3 29 + max-end: 1 30 + empty-values: 31 + forbid-in-block-mappings: true 32 + forbid-in-flow-mappings: true 33 + hyphens: 34 + max-spaces-after: 1 35 + indentation: 36 + spaces: 2 37 + indent-sequences: true 38 + check-multi-line-strings: false 39 + trailing-spaces: false
+8 -1
Documentation/devicetree/bindings/Makefile
··· 3 3 DT_EXTRACT_EX ?= dt-extract-example 4 4 DT_MK_SCHEMA ?= dt-mk-schema 5 5 6 + DT_SCHEMA_LINT = $(shell which yamllint) 7 + 6 8 DT_SCHEMA_MIN_VERSION = 2020.8.1 7 9 8 10 PHONY += check_dtschema_version ··· 26 24 -name 'processed-schema*' ! \ 27 25 -name '*.example.dt.yaml' \) 28 26 27 + quiet_cmd_yamllint = LINT $(src) 28 + cmd_yamllint = $(find_cmd) | \ 29 + xargs $(DT_SCHEMA_LINT) -f parsable -c $(srctree)/$(src)/.yamllint 30 + 29 31 quiet_cmd_chk_bindings = CHKDT $@ 30 32 cmd_chk_bindings = $(find_cmd) | \ 31 33 xargs -n200 -P$$(nproc) $(DT_DOC_CHECKER) -u $(srctree)/$(src) ··· 43 37 rm -f $$f 44 38 45 39 define rule_chkdt 40 + $(if $(DT_SCHEMA_LINT),$(call cmd,yamllint),) 46 41 $(call cmd,chk_bindings) 47 42 $(call cmd,mk_schema) 48 43 endef ··· 55 48 -Wno-graph_child_address \ 56 49 -Wno-interrupt_provider 57 50 58 - $(obj)/processed-schema-examples.json: $(DT_DOCS) check_dtschema_version FORCE 51 + $(obj)/processed-schema-examples.json: $(DT_DOCS) $(src)/.yamllint check_dtschema_version FORCE 59 52 $(call if_changed_rule,chkdt) 60 53 61 54 ifeq ($(DT_SCHEMA_FILES),)