Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from phobos.denx.de (phobos.denx.de [85.214.62.61]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id C4A10EB64DC for ; Fri, 21 Jul 2023 16:07:28 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id BCA8B8638D; Fri, 21 Jul 2023 18:07:26 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=chromium.org header.i=@chromium.org header.b="DfeYkMCf"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 55AC5862E9; Fri, 21 Jul 2023 18:07:25 +0200 (CEST) Received: from mail-io1-xd32.google.com (mail-io1-xd32.google.com [IPv6:2607:f8b0:4864:20::d32]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id D6B9982A2C for ; Fri, 21 Jul 2023 18:07:22 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@chromium.org Received: by mail-io1-xd32.google.com with SMTP id ca18e2360f4ac-7835ffc53bfso54755139f.1 for ; Fri, 21 Jul 2023 09:07:22 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1689955641; x=1690560441; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=LmefAAZbhqlqqXo5flJ4MCn5hlaum5ybqeG0La5P+f4=; b=DfeYkMCfJNkvpudWX1XJas1eeTYT6PIm6YKd9ILxfCNuKTxX7N+iTfIMdxeuZF5V3E qjAfOmag3u0h30SmB+CbSR7Z3WlYYDxGLLa6VF7Ag9X4ObGP1puafz+cpD1KiyqmRuP4 xEu8ZOlSFEXtVhvCGUFOVGbUL2pQu12Oiph8M= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1689955641; x=1690560441; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=LmefAAZbhqlqqXo5flJ4MCn5hlaum5ybqeG0La5P+f4=; b=dacfdEz3ork9u14tw7cJEE+3kKcT10UYMvGveqUqztYTk54z1b4JWDemWMM+TFqzJ6 D1Jwa4ZfRPwM8SmyifbW3QecjBGeEls5MK07ItskIf4jS5clQuh0MkcbBTwwTNo/W7EP D+Lk2LoTflZ9i+znMnBIpRio/kCfWXGhDnrym0bWDPsA4UOJha+wVuAxnJpwDIaKfZXW 4Nr95AnsRxg2LnDnLB6Tpj6kriK1LNLjnQHED8ZQeiWY9qePFnn2zSIuE9Ikui3/zZzO nTB96dgShMwqj/DMGZqXbip8Ad9oVsfpkinLOku8tfkDqveD8mXbz4U4uXElx+G7lIt4 vILw== X-Gm-Message-State: ABy/qLaddimxT675e40wIVqA/DmYn7v3KjtZSoEw0TmjVlGfJV8ocZSf VSg3LEikCL7wBKnW40YnCoZ++YCvzXe+nzqZl1U= X-Google-Smtp-Source: APBJJlFrnKVA4dJSm1Aj8fTkqC7XvAibooBnol0A8RNHPcv/dfhVIB+J16F7Mhh2ELGmTRDQXAjVcg== X-Received: by 2002:a5e:a810:0:b0:786:7100:5727 with SMTP id c16-20020a5ea810000000b0078671005727mr203854ioa.1.1689955641296; Fri, 21 Jul 2023 09:07:21 -0700 (PDT) Received: from sjg1.lan (c-73-14-173-85.hsd1.co.comcast.net. [73.14.173.85]) by smtp.gmail.com with ESMTPSA id r17-20020a6bd911000000b0078680780694sm1158685ioc.34.2023.07.21.09.07.19 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 21 Jul 2023 09:07:20 -0700 (PDT) From: Simon Glass To: U-Boot Mailing List Cc: Alper Nebi Yasak , Neha Malcom Francis , Stefan Herbrechtsmeier , Philippe Reynes , Peng Fan , Simon Glass , Heinrich Schuchardt , Jerry Van Baren Subject: [PATCH 0/6] binman: Template fixes and improvements Date: Fri, 21 Jul 2023 10:07:00 -0600 Message-ID: <20230721160710.968748-1-sjg@chromium.org> X-Mailer: git-send-email 2.41.0.487.g6d72f3e995-goog MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: u-boot-bounces@lists.denx.de Sender: "U-Boot" X-Virus-Scanned: clamav-milter 0.103.8 at phobos.denx.de X-Virus-Status: Clean With the basic template feature in place, some problems have come to light. Firstly, keeping the template around while processing entries seems unnecessary and perhaps confusing, so this is removed. Secondly this series aims to support phandles in a more intuitive way, rather than just ignoring them in templates. It includes an experimental patch to copy phandles from template so that it is possible to so something like: template { some_node: some-node { }; }; image { insert-template = <&template>; }; with the some_node phandle being copied to the 'image' node, to result in: image { insert-template = <&template>; some_node: some-node { }; }; Simon Glass (6): binman: Produce a template-file after processing dtoc: Make properties dirty when purging them dtoc: Add some debugging when copying nodes fdt: Allow copying phandles into templates binman: Remove templates after use WIP: binman: Support templates containing phandles tools/binman/binman.rst | 8 +++- tools/binman/control.py | 32 ++++++++++++-- tools/binman/ftest.py | 31 +++++++++++++ tools/binman/test/291_template_phandle.dts | 51 ++++++++++++++++++++++ tools/dtoc/fdt.py | 9 +++- tools/dtoc/test/dtoc_test_copy.dts | 6 ++- tools/dtoc/test_fdt.py | 34 ++++++++++----- 7 files changed, 153 insertions(+), 18 deletions(-) create mode 100644 tools/binman/test/291_template_phandle.dts -- 2.41.0.487.g6d72f3e995-goog