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 mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id F2C94C433F5 for ; Thu, 28 Oct 2021 10:49:39 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 597C260EFF for ; Thu, 28 Oct 2021 10:49:39 +0000 (UTC) DMARC-Filter: OpenDMARC Filter v1.4.1 mail.kernel.org 597C260EFF Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: mail.kernel.org; spf=pass smtp.mailfrom=lists.denx.de Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 70AF683499; Thu, 28 Oct 2021 12:49:37 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=denx.de; s=phobos-20191101; t=1635418178; bh=VNgyXTpSX4giuHIWaT2+zoxt0/BdALCaTIEPD6pN93Y=; h=Subject:To:Cc:References:From:Date:In-Reply-To:List-Id: List-Unsubscribe:List-Archive:List-Post:List-Help:List-Subscribe: From; b=csY1yGqUsSwgDXyYDVvruV/GfGDr5QSuR+uoZzuw+hJmQYd97cCU3LYpYwM2LDZnI 8kYSt2NriOV2oEQUVIITvYu1Z+sZerGYhS0cKMBLICRP+RaTmNvPdJX3xTF0dCPVBc IRfcWVifPGEG1xFSCOYVYjSvVtF5wI/VzDZhL2Sv7TMgOXLkqBQGQDW+y3/68dCiB4 8R9stqshTRvk9e+l1Es77okXUKjG9+Rf3lmWdPJVHupCahQBd6Mw+E7giFg2y8KtOG Ys/8FcAGRyjN0JXqaCRfgjm8TVCDl4DwR9HA/xKx5QH6F6STCaztlsIDQ8B+IAx8js ON4i/IEYUjtHQ== Received: by phobos.denx.de (Postfix, from userid 109) id B6F3E83480; Thu, 28 Oct 2021 12:49:35 +0200 (CEST) Received: from mout-u-204.mailbox.org (mout-u-204.mailbox.org [91.198.250.253]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 0066D834A4 for ; Thu, 28 Oct 2021 12:49:31 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=denx.de Authentication-Results: phobos.denx.de; spf=fail smtp.mailfrom=sr@denx.de Received: from smtp202.mailbox.org (unknown [91.198.250.118]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (P-384) server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) by mout-u-204.mailbox.org (Postfix) with ESMTPS id 4Hg2PR6Bt9zQjgJ; Thu, 28 Oct 2021 12:49:31 +0200 (CEST) Subject: Re: [PATCH] arm: mvebu: turris_omnia: Fix MTD partitions order for Linux To: =?UTF-8?Q?Pali_Roh=c3=a1r?= Cc: =?UTF-8?Q?Marek_Beh=c3=ban?= , u-boot@lists.denx.de References: <20211021155548.21099-1-pali@kernel.org> From: Stefan Roese Message-ID: Date: Thu, 28 Oct 2021 12:49:27 +0200 MIME-Version: 1.0 In-Reply-To: <20211021155548.21099-1-pali@kernel.org> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: de-DE Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: B93F11315 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 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.2 at phobos.denx.de X-Virus-Status: Clean On 21.10.21 17:55, Pali Rohár wrote: > Linux enumerates MTD partitions in DTB order, while the fdt_add_subnode() > function puts a new subnode at the beginning. > > To fix this, put MTD partitions into DTB in reverse order. > > Fixes: 92f36c8e74c1 ("arm: mvebu: turris_omnia: fixup MTD partitions in Linux' DTB") > Signed-off-by: Pali Rohár > Reviewed-by: Marek Behún Applied to u-boot-marvell/master Thanks, Stefan > --- > board/CZ.NIC/turris_omnia/turris_omnia.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/board/CZ.NIC/turris_omnia/turris_omnia.c b/board/CZ.NIC/turris_omnia/turris_omnia.c > index a48e1f5c305d..d2f510993449 100644 > --- a/board/CZ.NIC/turris_omnia/turris_omnia.c > +++ b/board/CZ.NIC/turris_omnia/turris_omnia.c > @@ -601,7 +601,7 @@ static bool fixup_mtd_partitions(void *blob, int offset, struct mtd_info *mtd) > > mtd_probe_devices(); > > - list_for_each_entry(slave, &mtd->partitions, node) { > + list_for_each_entry_reverse(slave, &mtd->partitions, node) { > char name[32]; > int part; > > Viele Grüße, Stefan -- DENX Software Engineering GmbH, Managing Director: Wolfgang Denk HRB 165235 Munich, Office: Kirchenstr.5, D-82194 Groebenzell, Germany Phone: (+49)-8142-66989-51 Fax: (+49)-8142-66989-80 Email: sr@denx.de