blob: de0d6090c0fd200f241aa0c71b5d208c62bde45c [file] [log] [blame]
Jason Cooper2a933002013-12-17 16:59:40 +00001
2 Submitting devicetree (DT) binding patches
3
4I. For patch submitters
5
Mauro Carvalho Chehab8c27ceff32016-10-18 10:12:27 -02006 0) Normal patch submission rules from Documentation/process/submitting-patches.rst
Jason Cooper2a933002013-12-17 16:59:40 +00007 applies.
8
Rob Herring44acf102018-06-05 16:37:47 -06009 1) The Documentation/ and include/dt-bindings/ portion of the patch should
10 be a separate patch. The preferred subject prefix for binding patches is:
11
12 "dt-bindings: <binding dir>: ..."
13
14 The 80 characters of the subject are precious. It is recommended to not
15 use "Documentation" or "doc" because that is implied. All bindings are
16 docs. Repeating "binding" again should also be avoided.
Jason Cooper2a933002013-12-17 16:59:40 +000017
18 2) Submit the entire series to the devicetree mailinglist at
19
20 devicetree@vger.kernel.org
21
Matt Porterd1e9fa92015-03-05 10:53:11 -050022 and Cc: the DT maintainers. Use scripts/get_maintainer.pl to identify
23 all of the DT maintainers.
24
Javier Martinez Canillasef0b97e2014-10-09 20:24:07 +020025 3) The Documentation/ portion of the patch should come in the series before
26 the code implementing the binding.
27
Paul Walmsley10638a42015-01-30 15:11:04 -070028 4) Any compatible strings used in a chip or board DTS file must be
29 previously documented in the corresponding DT binding text file
30 in Documentation/devicetree/bindings. This rule applies even if
31 the Linux device driver does not yet match on the compatible
32 string. [ checkpatch will emit warnings if this step is not
33 followed as of commit bff5da4335256513497cc8c79f9a9d1665e09864
34 ("checkpatch: add DT compatible string documentation checks"). ]
35
36 5) The wildcard "<chip>" may be used in compatible strings, as in
37 the following example:
38
39 - compatible: Must contain '"nvidia,<chip>-pcie",
40 "nvidia,tegra20-pcie"' where <chip> is tegra30, tegra132, ...
41
42 As in the above example, the known values of "<chip>" should be
43 documented if it is used.
44
45 6) If a documented compatible string is not yet matched by the
46 driver, the documentation should also include a compatible
47 string that is matched by the driver (as in the "nvidia,tegra20-pcie"
48 example above).
49
50
Jason Cooper2a933002013-12-17 16:59:40 +000051II. For kernel maintainers
52
53 1) If you aren't comfortable reviewing a given binding, reply to it and ask
54 the devicetree maintainers for guidance. This will help them prioritize
55 which ones to review and which ones are ok to let go.
56
57 2) For driver (not subsystem) bindings: If you are comfortable with the
58 binding, and it hasn't received an Acked-by from the devicetree
59 maintainers after a few weeks, go ahead and take it.
60
61 Subsystem bindings (anything affecting more than a single device)
62 then getting a devicetree maintainer to review it is required.
63
64 3) For a series going though multiple trees, the binding patch should be
65 kept with the driver using the binding.
66
67III. Notes
68
69 0) Please see ...bindings/ABI.txt for details regarding devicetree ABI.
70
71 1) This document is intended as a general familiarization with the process as
72 decided at the 2013 Kernel Summit. When in doubt, the current word of the
73 devicetree maintainers overrules this document. In that situation, a patch
74 updating this document would be appreciated.