]> git.baikalelectronics.ru Git - kernel.git/commit
kbuild: determine the output format of DTC by the target suffix
authorMasahiro Yamada <masahiroy@kernel.org>
Mon, 27 Apr 2020 13:49:30 +0000 (22:49 +0900)
committerMasahiro Yamada <masahiroy@kernel.org>
Tue, 12 May 2020 04:28:33 +0000 (13:28 +0900)
commit7a6ca4b90b37ce2bea6f1a1171c2c4e1a9cccf2b
tree28022eb621119b167603a8ac3024df03a1c790d5
parentd576e921122c149bfe031689cc818767d6893fc6
kbuild: determine the output format of DTC by the target suffix

cmd_dtc takes the additional parameter $(2) to select the target
format, dtb or yaml. This makes things complicated when it is used
with cmd_and_fixdep and if_changed_rule. I actually stumbled on this.
See commit 4228a26d45a9 ("kbuild: fix DT binding schema rule again to
avoid needless rebuilds").

Extract the suffix part of the target instead of passing the parameter.
Fortunately, this works for both $(obj)/%.dtb and $(obj)/%.dt.yaml .

Signed-off-by: Masahiro Yamada <masahiroy@kernel.org>
scripts/Makefile.lib