Received: by 2002:ab2:3319:0:b0:1ef:7a0f:c32d with SMTP id i25csp289653lqc; Thu, 7 Mar 2024 18:44:50 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCW5Ikul5QKcVBCVvDunGTJ/Zgz3RvsoXvhNbgXxzbtWS5cVpO3OVyUerh6cwcv5d2zglQuiuJ4iCUqZUzl7qlMjuAgbUpTHRYC3zCu4UQ== X-Google-Smtp-Source: AGHT+IE1aWGHUJdB1uDJcEu9NTUGj54WzxD56xdD9rOhMhXWE2TP51B9n1idCtUzn2S+ZGwz1kt1 X-Received: by 2002:ad4:58e8:0:b0:690:a30f:ff2f with SMTP id di8-20020ad458e8000000b00690a30fff2fmr2723320qvb.64.1709865890246; Thu, 07 Mar 2024 18:44:50 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1709865890; cv=pass; d=google.com; s=arc-20160816; b=yF1dm3YsZMP9NDcrx4hu9Wl5FKe5w7pe9IuywAT0Bz3ZXiaiJouME9R4nwXylDmEhe nxacqJTKe+eNHAo9kAg49UWKkOS2dRI+JJdFaLCg1q3KXPZPW2WgPunV+UCFPq9lR2/S 5m/d4kkwAfOQ2Mv/+tPrrZ41i3FjXQD/z1IZ75swkFuOnnbYGjJfe/X/Y71tfxFm5k8+ GDMws95EP/KfqypxuXJTr4P5b3Jf8hYnwdmO+bxqgZ53AL2y+z/0KRa4r0lULubOIUAm xi0BQUsze3ynZ2/ELnsUB9Q24NzSOLwbHzdcCOzC63ofFO1057volf1TuE1PFdtz2eqM dvPA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:list-unsubscribe:list-subscribe:list-id:precedence :dkim-signature; bh=JxG3C1fNlHZOl1qKhga4bIFtxN+IbPgWY3WbkNFh0bI=; fh=CTo8p1RF7LBBaGmfWqShwva8+LzEiv+ob9nbdn+w/LA=; b=mCYGrMO+MXAhd86Sep1L+heVB48TYoif1eDIOU/R9bJ4gblbDJNYpwx2xS46NUNVWr JYjLSdJEdcLSGvblpICfD1N2bsgv3SaoPWneQuOxKSQo0nEDO0+jyPLfvj+khREa64Ek 7U7XKM9OqMRH4qub+iDNbYWaSZcrULQ/hcKUQstkO/fJRS5ehhPPrUqTFwzCC+c80yAM yhXlFe+PP9aqq8xuLmaUsgzz7l+SzOdE6EtT0oizzwJCyZW8aMXhJIl2klOCJc9QzK5d lqcEu6mY0hfIB5SxeWQMYyaAU+O2RV/Ej7pARejlM/AqcVPx+Pe8w8yiurpeV9Admozs iZQw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=dLdTOEbp; arc=pass (i=1 spf=pass spfdomain=chromium.org dkim=pass dkdomain=chromium.org dmarc=pass fromdomain=chromium.org); spf=pass (google.com: domain of linux-kernel+bounces-96453-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-96453-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id jt15-20020a05621427ef00b0068edf664eadsi1580432qvb.213.2024.03.07.18.44.50 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 07 Mar 2024 18:44:50 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-96453-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@chromium.org header.s=google header.b=dLdTOEbp; arc=pass (i=1 spf=pass spfdomain=chromium.org dkim=pass dkdomain=chromium.org dmarc=pass fromdomain=chromium.org); spf=pass (google.com: domain of linux-kernel+bounces-96453-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-96453-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=chromium.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 9C1E51C211D7 for ; Fri, 8 Mar 2024 02:44:49 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 9158228DC8; Fri, 8 Mar 2024 02:44:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b="dLdTOEbp" Received: from mail-qv1-f49.google.com (mail-qv1-f49.google.com [209.85.219.49]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id E0C6F288B0 for ; Fri, 8 Mar 2024 02:44:37 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.219.49 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709865879; cv=none; b=O4/D/gPJ8KkNwWJSSRSiugt05e/w/K0e1HE/RWmPJD87fHxqvSMkhjDExnC3jL421K0j37/WhoU1fEVCZ/kLDciYaaHywz+LRmXLAP+8oOMMeLRgQ2P8gD7QhBleCpu2RZm/1OfOsQeC8Cs9uSgckMvoIMnXk66RB6MmYpvZ3FQ= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1709865879; c=relaxed/simple; bh=fSQs6edR7FFIscZnvuVJJSuwUJjidAWISLuv00JfLLM=; h=MIME-Version:References:In-Reply-To:From:Date:Message-ID:Subject: To:Cc:Content-Type; b=JQWIQA/9t+RZC7zEKkg4WcdYkc4EKT3h5v7isGud7ulQoimOl6Uhi0cv210SI4k5xSIe2Ttv/B5dVsCb2D+6XwW6z6rEMmy5aZ0aeVNpdROgLA0GGURBMnB3wF2rZ/B0vFknkQm9jb/h7L1YQSmVh+5WW8sOUvy21E689WwfWFE= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=chromium.org; spf=pass smtp.mailfrom=chromium.org; dkim=pass (1024-bit key) header.d=chromium.org header.i=@chromium.org header.b=dLdTOEbp; arc=none smtp.client-ip=209.85.219.49 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=chromium.org Received: by mail-qv1-f49.google.com with SMTP id 6a1803df08f44-6908b540cdbso7248886d6.2 for ; Thu, 07 Mar 2024 18:44:37 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1709865877; x=1710470677; darn=vger.kernel.org; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:from:to:cc:subject:date:message-id:reply-to; bh=JxG3C1fNlHZOl1qKhga4bIFtxN+IbPgWY3WbkNFh0bI=; b=dLdTOEbp2ObpxZMn65sla/kwZo6SneJwaBY+SudLypUyHvMOSCEeN4xn4YWfHFBd4N yTIlUFeOilOHkSzLYd0Mx/LAuT0UaxY6A3u25gaWYJtiWRt0WyjSGCbPMJv7RmQ3p8kC faLO6wPkQ9o+Vafd/0NPgBdXI1yPEQVFxKEhg= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1709865877; x=1710470677; h=cc:to:subject:message-id:date:from:in-reply-to:references :mime-version:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=JxG3C1fNlHZOl1qKhga4bIFtxN+IbPgWY3WbkNFh0bI=; b=nRo+8LORPb7ik9nk5DpBYHULWbgYM36DfS4IUDtLmocOQRfZ6olGOMCxreLCC8vh1f /DupFDxoxw9YcvQNG+Hf8oZmsBjnam0LS1C1fvbMXE+o2iEQJvLkdxUpfWIkRWB+19Ns A/NfeYbSnpOwdDCc8ZOjFha4dHbyzpxYxpFy4Y8/UDaCDhk3gMiolP8XSjHMh3OAsHws iCX9O7fA0iSwFaNXDzXW2PhxaQPn6vpFbb+SEwKyTsgL3NRVI/fYbmwcjTo9umAf1TRz JYX/GKs5qJafguPxtHO0J2CE7fngU/jT8iOLqRE/wj8qgJR8t+Qmm6mqCxp/IXJYPfep ysXQ== X-Forwarded-Encrypted: i=1; AJvYcCWAV8XGPbbC0G3oS+YbfMcJAgBTVgBLxFQSRnmkPssJacto3nEMeMtmPP9mgJk2ikldHc0qElHjozBnwrc4ZvVS/5Cr2hVsMGivKai6 X-Gm-Message-State: AOJu0YyHP3wykeX/96bRu2NDgkUvDZXCE8D52uoPpG5nsO+M4PYaTBjp re1gYcgAl9JQoGaSsFiAkfGg2c0T42YrYAzyAjDRWRlM32MfK1RGDiCVKlsm2bO5BYEXXUl2P33 uYW8IB5ELYsAaMID1eAy57h/iBWtVPKQnI1v6 X-Received: by 2002:a0c:ec47:0:b0:690:aaa8:a019 with SMTP id n7-20020a0cec47000000b00690aaa8a019mr2720578qvq.47.1709865876833; Thu, 07 Mar 2024 18:44:36 -0800 (PST) Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20231116172859.393744-1-sjg@chromium.org> <20231208150042.GA1278773-robh@kernel.org> <20231214172702.GA617226-robh@kernel.org> <20240205085056.44278f2c@xps-13> <20240205131755.3462084f@xps-13> In-Reply-To: <20240205131755.3462084f@xps-13> From: Simon Glass Date: Fri, 8 Mar 2024 15:44:25 +1300 Message-ID: Subject: Re: [PATCH v6 1/3] dt-bindings: mtd: partitions: Add binman compatible To: Miquel Raynal Cc: Rob Herring , devicetree@vger.kernel.org, linux-mtd@lists.infradead.org, Tom Rini , Michael Walle , U-Boot Mailing List , Conor Dooley , Krzysztof Kozlowski , Pratyush Yadav , =?UTF-8?B?UmFmYcWCIE1pxYJlY2tp?= , Richard Weinberger , Vignesh Raghavendra , linux-kernel@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Hi Miquel, On Tue, 6 Feb 2024 at 01:17, Miquel Raynal wrote: > > Hi Simon, > > > > > > > > > > > > > > +description: | > > > > > > > > > > > > > + The binman node provides a layout for firmware, used when packaging firmware > > > > > > > > > > > > > + from multiple projects. It is based on fixed-partitions, with some > > > > > > > > > > > > > + extensions, but uses 'compatible' to indicate the contents of the node, to > > > > > > > > > > > > > + avoid perturbing or confusing existing installations which use 'label' for a > > > > > > > > > > > > > + particular purpose. > > > > > > > > > > > > > + > > > > > > > > > > > > > + Binman supports properties used as inputs to the firmware-packaging process, > > > > > > > > > > > > > + such as those which control alignment of partitions. This binding addresses > > > > > > > > > > > > > + these 'input' properties. For example, it is common for the 'reg' property > > > > > > > > > > > > > + (an 'output' property) to be set by Binman, based on the alignment requested > > > > > > > > > > > > > + in the input. > > > > > > > > > > > > > + > > > > > > > > > > > > > + Once processing is complete, input properties have mostly served their > > > > > > > > > > > > > + purpose, at least until the firmware is repacked later, e.g. due to a > > > > > > > > > > > > > + firmware update. The 'fixed-partitions' binding should provide enough > > > > > > > > > > > > > + information to read the firmware at runtime, including decompression if > > > > > > > > > > > > > + needed. > > > > > > > > > > > > > > > > > > > > > > > > How is this going to work exactly? binman reads these nodes and then > > > > > > > > > > > > writes out 'fixed-partitions' nodes. But then you've lost the binman > > > > > > > > > > > > specifc parts needed for repacking. > > > > > > > > > > > > > > > > > > > > > > No, they are the same node. I do want the extra information to stick > > > > > > > > > > > around. So long as it is compatible with fixed-partition as well, this > > > > > > > > > > > should work OK. > > > > > > > > > > > > > > > > > > > > How can it be both? The partitions node compatible can be either > > > > > > > > > > 'fixed-partitions' or 'binman'. > > > > > > > > > > > > > > > > > > Can we not allow it to be both? I have tried to adjust things in > > > > > > > > > response to feedback but perhaps the feedback was leading me down the > > > > > > > > > wrong path? > > > > > > > > > > > > > > > > Sure, but then the schema has to and that means extending > > > > > > > > fixed-partitions. > > > > > > > > > > > > > > Can we cross that bridge later? There might be resistance to it. I'm > > > > > > > not sure. For now, perhaps just a binman compatible works well enough > > > > > > > to make progress. > > > > > > > > > > > > Is there any way to make progress on this? I would like to have > > > > > > software which doesn't understand the binman compatible to at least be > > > > > > able to understand the fixed-partition compatible. Is that acceptable? > > > > > > > > > > There's only 2 ways that it can work. Either binman writes out > > > > > fixed-partition nodes dropping/replacing anything only defined for > > > > > binman or fixed-partition is extended to include what binman needs. > > > > > > > > OK, then I suppose the best way is to add a new binman compatible, as > > > > is done with this v6 series. People then need to choose it instead of > > > > fixed-partition. > > > > > > I'm sorry this is not at all what Rob suggested, or did I totally > > > misunderstand his answer? > > > > > > In both cases the solution is to generate a "fixed-partition" node. Now > > > up to you to decide whether binman should adapt the output to the > > > current schema, or if the current schema should be extended to > > > understand all binman's output. > > > > > > At least that is my understanding and also what I kind of agree with. > > > > I do want to binman schema to include all the features of Binman. > > > > So are you saying that there should not be a 'binman' schema, but I > > should just add all the binman properties to the fixed-partition > > schema? > > This is my current understanding, yes. But acknowledgment from Rob is > also welcome. I am trying again to wade through all the confusion here. There is not actually a 'fixed-partition' node. So are you saying I should add one? There is already a 'partitions' node. Won't they conflict? Would it be possible for you to look at my patches and suggest something? I think at this point, after so many hours of trying different things and trying to understand what is needed, I could really use a little help. Thank you, Simon