From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from metis.whiteo.stw.pengutronix.de (metis.whiteo.stw.pengutronix.de [185.203.201.7]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 0B0B42E6128 for ; Wed, 11 Jun 2025 18:15:33 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=185.203.201.7 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1749665735; cv=none; b=YAKSRYtgWLzehaLadswdeNsWP7PtCkfiyc+wxcBkti4TAhhcH4hIkxIs0kUiRGnNhGFTIg8klIimfsh7Dq+enFRkszoG2cJTh1BeSp963POa65IAUf7s9ldNzBYsipFrGAw2Ac9O6IcR/HNjxoHQsEDK6jDU74EOdzczaNnUa5Q= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1749665735; c=relaxed/simple; bh=ShxLF+BQufGmHMrV74DXXvxSMTrFEmKWtn9TGUP97OY=; h=Message-ID:Date:MIME-Version:Subject:From:To:Cc:References: In-Reply-To:Content-Type; b=TFD7k84kEcddsN64ebtRtTAhg7gP9avv6yDQX4uyJEkJw48Kxucntinp7bZcxfNkRoApOwIVbQZ/EisA0LtcY1cjgnKkqiBW5tBFF8Gdd4mB2PoVt4FhC3k0gFnkfwuiYrebXlmVyfpxIJjTvWW6YHQNv2XF60nbPkoIg6dNFjA= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=pengutronix.de; spf=pass smtp.mailfrom=pengutronix.de; arc=none smtp.client-ip=185.203.201.7 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=pengutronix.de Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=pengutronix.de Received: from ptz.office.stw.pengutronix.de ([2a0a:edc0:0:900:1d::77] helo=[127.0.0.1]) by metis.whiteo.stw.pengutronix.de with esmtp (Exim 4.92) (envelope-from ) id 1uPPyh-0004Yh-S0; Wed, 11 Jun 2025 20:15:11 +0200 Message-ID: Date: Wed, 11 Jun 2025 20:15:04 +0200 Precedence: bulk X-Mailing-List: devicetree@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Subject: Re: Co-existence of GPT and fixed partitions (Was: Re: [PATCH v6 5/6] block: add support for partition table defined in OF) From: Ahmad Fatoum To: "Christian Marangi (Ansuel)" Cc: Ulf Hansson , Riyan Dhiman , linux-doc@vger.kernel.org, Linus Walleij , Dominique Martinet , Li Zhijian , Daniel Golle , Miquel Raynal , Christoph Hellwig , Rob Herring , Jonathan Corbet , Christoph Hellwig , Jorge Ramirez-Ortiz , Lorenzo Bianconi , devicetree@vger.kernel.org, Conor Dooley , Ming Lei , linux-block@vger.kernel.org, Avri Altman , Christophe JAILLET , Al Viro , Li Lingfeng , Jens Axboe , Christian Brauner , INAGAKI Hiroshi , linux-mmc@vger.kernel.org, Adrian Hunter , linux-kernel@vger.kernel.org, Mikko Rapeli , Pengutronix Kernel Team , Krzysztof Kozlowski , upstream@airoha.com, Christian Heusel , Jens Wiklander References: <20241002221306.4403-1-ansuelsmth@gmail.com> <20241002221306.4403-6-ansuelsmth@gmail.com> <5e9a80d6-6c89-478e-99c9-584647661f5e@pengutronix.de> <4218cdae-07ee-433c-8a68-bb07885e43ab@pengutronix.de> Content-Language: en-US, de-DE, de-BE In-Reply-To: <4218cdae-07ee-433c-8a68-bb07885e43ab@pengutronix.de> Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 7bit X-SA-Exim-Connect-IP: 2a0a:edc0:0:900:1d::77 X-SA-Exim-Mail-From: a.fatoum@pengutronix.de X-SA-Exim-Scanned: No (on metis.whiteo.stw.pengutronix.de); SAEximRunCond expanded to false X-PTX-Original-Recipient: devicetree@vger.kernel.org Hi, On 12/5/24 13:12, Ahmad Fatoum wrote: >> Or you are telling me you had a downstream patch that declares additional >> partition in addition to a disk with a GPT partition table? >> If that's the case, I'm confused of why the additional partition can't >> be declared >> directly in GPT. > > Many of the older boards supported by barebox used to place the barebox image > and the environment prior to the first partition in the unpartitioned area. > > To still be able to access them, fixed partitions were used and the rest > of the system was described by MBR/GPT partitions. > > This was partially made necessary by BootROMs having strange expectations > of where the bootloader needs to be placed, which partially overlapped > the MBR/GPT itself, making it difficult to define a partition for the bootloader. > > For newer boards, it's more common to place the bootloader in a GPT partition > now. barebox has no DT binding for generically describing such a GPT partition > though, so boards may create a fixed-partition "alias" and use that. FTR, starting with barebox v2025.03.0, barebox' default is to fix up a partitions container with a barebox,fixed-partition compatible for everything that's not an MTD. This avoids clashing with the binding added here for MMCs and possibly a future binding for partitioning EEPROMs. Cheers, Ahmad > > Cheers, > Ahmad > -- Pengutronix e.K. | | Steuerwalder Str. 21 | http://www.pengutronix.de/ | 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 | Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |