diff options
author | Nathan Rossi <nathan@nathanrossi.com> | 2016-04-10 22:23:27 +1000 |
---|---|---|
committer | Nathan Rossi <nathan@nathanrossi.com> | 2016-04-12 23:37:08 +1000 |
commit | 150c913a07ca9688282e133328dc1cddff244e24 (patch) | |
tree | b2fb24b2c7e008fd280a9aab6711d1f9061496ed | |
parent | b7862924902489ece6dbd028afcd26e5937e5e37 (diff) | |
download | meta-xilinx-150c913a07ca9688282e133328dc1cddff244e24.tar.gz |
device-tree.bb: Add deprecation warning for 'zynq7-base.dtsi'
The zynq7-base.dtsi include is deprecated and will be removed in the
future. This informs users of its deprecation, in order to encourage
users to move to the 'zynq-7000.dtsi' include.
This include is deprecated in favour of the 'zynq-7000.dtsi' include
which is available and kept up to date in kernel releases as well as the
linux-xlnx vendor tree releases. The device-tree recipe automatically
provides this include (and dependent includes) to allow for custom
device-trees to be built without needing to embed or patch the kernel
source.
Signed-off-by: Nathan Rossi <nathan@nathanrossi.com>
-rw-r--r-- | recipes-bsp/device-tree/device-tree.bb | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/recipes-bsp/device-tree/device-tree.bb b/recipes-bsp/device-tree/device-tree.bb index 95ca0f35..3311a6f7 100644 --- a/recipes-bsp/device-tree/device-tree.bb +++ b/recipes-bsp/device-tree/device-tree.bb | |||
@@ -44,6 +44,18 @@ python () { | |||
44 | " ".join([d.getVarFlag("do_compile", "depends", True) or "", "virtual/kernel:do_shared_workdir"])) | 44 | " ".join([d.getVarFlag("do_compile", "depends", True) or "", "virtual/kernel:do_shared_workdir"])) |
45 | } | 45 | } |
46 | 46 | ||
47 | python do_deprecation_check() { | ||
48 | # check for use of 'zynq7-base.dtsi' | ||
49 | import re | ||
50 | for i in d.getVar('MACHINE_DEVICETREE', True).split(): | ||
51 | filepath = os.path.join(d.getVar("WORKDIR", True), i) | ||
52 | if os.path.exists(filepath): | ||
53 | with open(filepath, 'rb') as f: | ||
54 | if re.search("/include/ \"zynq7-base.dtsi\"", f.read()): | ||
55 | bb.warn("%s includes 'zynq7-base.dtsi', this include is deprecated." % i) | ||
56 | } | ||
57 | addtask do_deprecation_check after do_unpack | ||
58 | |||
47 | do_compile() { | 59 | do_compile() { |
48 | if test -n "${MACHINE_DEVICETREE}"; then | 60 | if test -n "${MACHINE_DEVICETREE}"; then |
49 | mkdir -p ${WORKDIR}/devicetree | 61 | mkdir -p ${WORKDIR}/devicetree |