From mboxrd@z Thu Jan 1 00:00:00 1970 Delivery-date: Thu, 23 Jul 2026 15:58:29 +0200 Received: from mx1.white.stw.pengutronix.de ([2a0a:edc0:0:b01:1d::107]) by lore.white.stw.pengutronix.de with esmtps (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1wmtwS-001z8C-2c for lore@lore.pengutronix.de; Thu, 23 Jul 2026 15:58:29 +0200 Received: from bombadil.infradead.org (bombadil.infradead.org [IPv6:2607:7c80:54:3::133]) by mx1.white.stw.pengutronix.de (Postfix) with ESMTPS id DFE13202586 for ; Thu, 23 Jul 2026 15:58:28 +0200 (CEST) Authentication-Results: mx1.white.stw.pengutronix.de; dkim=pass header.d=lists.infradead.org header.s=bombadil.20210309 header.b=QR9blq6h; dkim=pass header.d=kernel.org header.s=k20201202 header.b="gl3v/spi"; dmarc=pass (policy=quarantine) header.from=kernel.org; spf=pass (mx1.white.stw.pengutronix.de: domain of "barebox-bounces+lore=pengutronix.de@lists.infradead.org" designates 2607:7c80:54:3::133 as permitted sender) smtp.mailfrom="barebox-bounces+lore=pengutronix.de@lists.infradead.org" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:Reply-To:List-Subscribe: List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id:Cc:To:In-Reply-To: References:Message-Id:Content-Transfer-Encoding:Content-Type:MIME-Version: Subject:Date:From:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=w09tpYtrD00ImixsTLMRC9KawaIIPk7VY3Na9harhYc=; b=QR9blq6heV0Tw39wxHyjh2vuUE pugpRkbkodIWHggp97C13CQl0lt1Sv/0nX6Kq1JMc804b4GkqL2xYfX85HSjY7qIDmQgYLqYaFwVG Lu0GMdiR7HLmhKBrtOs0IRORzlMFcGPJVz0nHfdO+BSFNydg/sCZigfhRASEKJ+MsMS9OEm2Ns0SU oHCr7q8/4UmNItQqvTLUHzaQAEGHt5bxKuj/Y69Dk/DjHHSbrdhNYidJ1KgEnGsqb7J76e5hTQykV 4xDHZferZ02zcx25TJPQr4YR+VSu1tVB54ryFguLh6Y5Hx3t7biLp8R+s+ge0ET1/JFDiCPGZIAa6 mmfSyBfw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.99.1 #2 (Red Hat Linux)) id 1wmtvA-0000000EQM2-1HQU; Thu, 23 Jul 2026 13:57:08 +0000 Received: from sea.source.kernel.org ([2600:3c0a:e001:78e:0:1991:8:25]) by bombadil.infradead.org with esmtps (Exim 4.99.1 #2 (Red Hat Linux)) id 1wmtv9-0000000EQLP-2eBo for barebox@lists.infradead.org; Thu, 23 Jul 2026 13:57:07 +0000 Received: from smtp.kernel.org (transwarp.subspace.kernel.org [100.75.92.58]) by sea.source.kernel.org (Postfix) with ESMTP id 6725E43CCE; Thu, 23 Jul 2026 13:57:07 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPS id 4D6D5C2BCC9; Thu, 23 Jul 2026 13:57:07 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1784815027; bh=Oh/iPu0vBAvSdnLLPcjMSuw5shpxW9AHpH7rB/MwEx4=; h=From:Date:Subject:References:In-Reply-To:To:Cc:Reply-To:From; b=gl3v/spiGdnrCIYZpY2HhAhthYUYYCyX5kONV6b15y7PhiYif6LXl6IL8rQ/FEy9a 2zll9MbU//fm/itm6wm94sCzO+cUMMiY9xTQGNfF3nhMUMfienmph/pKkE/Uq9WE8F gLdpNzJWftQHZ8RhinnVsH33lEG+fJePDMkVYvIRBlqdsVe6aPHlzpSKmAb6E7EyBp K7cNZt0+554wPpvn2JeQP4Co16YZJ3RlxN1vYvCEaw2iCzDZL8ry5OpxxQLT17tj0F aWdSKuCuyEXq8AnYEhT/YrG4Zir7cy8fTYRXwWYQJPsseh73Pq5B0+roEIB/e72s3j PXawH4U9C26aA== Received: from aws-us-west-2-korg-lkml-1.web.codeaurora.org (localhost.localdomain [127.0.0.1]) by smtp.lore.kernel.org (Postfix) with ESMTP id 382A1C531CB; Thu, 23 Jul 2026 13:57:07 +0000 (UTC) From: Luca Lauro via B4 Relay Date: Thu, 23 Jul 2026 15:57:42 +0200 Subject: [PATCH 04/19] ARM: dts: update RN102 Linux DTS MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Message-Id: <20260723-rn102-rn104-series-v1-4-7698d25df866@gmail.com> References: <20260723-rn102-rn104-series-v1-0-7698d25df866@gmail.com> In-Reply-To: <20260723-rn102-rn104-series-v1-0-7698d25df866@gmail.com> To: Sascha Hauer , "open list:BAREBOX" Cc: Luca Lauro X-Mailer: b4 0.15.2 X-Developer-Signature: v=1; a=ed25519-sha256; t=1784815061; l=4076; i=famlauro93l@gmail.com; s=20260723; h=from:subject:message-id; bh=BgY4qJyf3fh09obXlvqr22vPCRU9NrmhvUjxq/gi0GY=; b=hsusyw8JNtz4lbQqYvUoF1rVvTDY6Pt+pFNYPiMVrYyA4arMqO9RulmG2BXYnjQYNplBoPznq s0mAbMFX4GHCrcSUsXJhqq+kgr/roDfwYLDG6thHY/oJiKKI7I8cYGr X-Developer-Key: i=famlauro93l@gmail.com; a=ed25519; pk=OAJlcD69ugQCl99Vy6w+Aeu+ZUb1IVGcz1Ijxo6Ch78= X-Endpoint-Received: by B4 Relay for famlauro93l@gmail.com/20260723 with auth_id=892 X-Original-From: Luca Lauro X-BeenThere: barebox@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Reply-To: famlauro93l@gmail.com Sender: "barebox" X-Spamd-Result: default: False [-6.91 / 15.00]; DWL_DNSWL_MED(-4.00)[infradead.org:dkim,kernel.org:dkim]; BAYES_HAM(-3.00)[100.00%]; FREEMAIL_REPLYTO_NEQ_FROM(2.00)[]; DMARC_POLICY_ALLOW(-0.50)[kernel.org,quarantine]; RCVD_DKIM_ARC_DNSWL_MED(-0.50)[]; MAILLIST(-0.20)[mailman]; R_SPF_ALLOW(-0.20)[+mx:c]; RCVD_IN_DNSWL_MED(-0.20)[2607:7c80:54:3::133:from]; R_DKIM_ALLOW(-0.20)[lists.infradead.org:s=bombadil.20210309,kernel.org:s=k20201202]; MIME_GOOD(-0.10)[text/plain]; HAS_LIST_UNSUB(-0.01)[]; RCVD_TLS_LAST(0.00)[]; RECEIVED_HELO_LOCALHOST(0.00)[]; FUZZY_RATELIMITED(0.00)[rspamd.com]; FORGED_SENDER(0.00)[devnull@kernel.org,barebox-bounces@lists.infradead.org]; FREEMAIL_REPLYTO(0.00)[gmail.com]; ARC_NA(0.00)[]; MIME_TRACE(0.00)[0:+]; FORWARDED(0.00)[barebox@lists.infradead.org]; TO_DN_ALL(0.00)[]; FREEMAIL_CC(0.00)[gmail.com]; REPLYTO_DOM_NEQ_FROM_DOM(0.00)[]; FORGED_SENDER_FORWARDING(0.00)[]; RCVD_COUNT_FIVE(0.00)[5]; FROM_NEQ_ENVFROM(0.00)[devnull@kernel.org,barebox-bounces@lists.infradead.org]; FROM_HAS_DN(0.00)[]; TAGGED_FROM(0.00)[lore=pengutronix.de,famlauro93l.gmail.com]; NEURAL_HAM(-0.00)[-1.000]; ASN(0.00)[asn:7247, ipnet:2607:7c80:54::/48, country:US]; REPLYTO_DOM_NEQ_TO_DOM(0.00)[]; FORGED_SENDER_MAILLIST(0.00)[]; DKIM_TRACE(0.00)[lists.infradead.org:+,kernel.org:+]; RCPT_COUNT_THREE(0.00)[3]; HAS_REPLYTO(0.00)[famlauro93l@gmail.com] X-Rspamd-Action: no action X-Rspamd-Queue-Id: DFE13202586 X-Rspamd-Server: mx1 X-Stat-Signature: onkqh13fomeuye9si5kfhpduajrtwg81 From: Luca Lauro --- dts/src/arm/marvell/armada-370-netgear-rn102.dts | 114 ++++++++++++++--------- 1 file changed, 71 insertions(+), 43 deletions(-) diff --git a/dts/src/arm/marvell/armada-370-netgear-rn102.dts b/dts/src/arm/marvell/armada-370-netgear-rn102.dts index 079b37cf14..f1bad2a233 100644 --- a/dts/src/arm/marvell/armada-370-netgear-rn102.dts +++ b/dts/src/arm/marvell/armada-370-netgear-rn102.dts @@ -15,6 +15,10 @@ / { model = "NETGEAR ReadyNAS 102"; compatible = "netgear,readynas-102", "marvell,armada370", "marvell,armada-370-xp"; + aliases { + state = &state_nand; + }; + chosen { stdout-path = "serial0:115200n8"; }; @@ -54,7 +58,7 @@ ethernet@74000 { phy-mode = "rgmii-id"; }; - usb@50000 { + usb@50000 { status = "okay"; }; @@ -153,10 +157,35 @@ backup-button { gpio-poweroff { compatible = "gpio-poweroff"; - pinctrl-0 = <&poweroff>; + pinctrl-0 = <&poweroff_pin>; pinctrl-names = "default"; gpios = <&gpio0 8 GPIO_ACTIVE_LOW>; }; + + /* configure nand partition to store barebox environment */ + environment { + compatible = "barebox,environment"; + device-path = &nand_controller, "partname:environment"; + }; + + /* configure nand partition to store barebox-state backend */ + state_nand: nand_state_memory { + #address-cells = <1>; + #size-cells = <1>; + compatible = "barebox,state"; + magic = <0xab67421f>; + backend-type = "raw"; + backend = <&backend_state_nand>; + backend-storage-type = "circular"; + backend-stridesize = <32>; + + + variable@0 { + reg = <0x0 0x1>; + type ="uint8"; + default = <0x1>; + }; + }; }; &pciec { @@ -219,58 +248,57 @@ reset_button_pin: reset-button-pin { marvell,function = "gpio"; }; - poweroff: poweroff { + poweroff_pin: poweroff-pin { marvell,pins = "mpp8"; marvell,function = "gpio"; }; }; &nand_controller { + compatible = "marvell,armada370-nand", "marvell,pxa3xx-nand"; status = "okay"; - nand@0 { - reg = <0>; - label = "pxa3xx_nand-0"; - nand-rb = <0>; - marvell,nand-keep-config; - nand-on-flash-bbt; - - /* Use Hardware BCH ECC */ - nand-ecc-strength = <4>; - nand-ecc-step-size = <512>; - - partitions { - compatible = "fixed-partitions"; - #address-cells = <1>; - #size-cells = <1>; - - partition@0 { - label = "u-boot"; - reg = <0x0000000 0x180000>; /* 1.5MB */ - read-only; - }; + label = <&nand_controller>; + nand-rb = <0>; + marvell,nand-keep-config; + nand-on-flash-bbt; + + /* Use Hardware BCH ECC */ + nand-ecc-strength = <4>; + nand-ecc-step-size = <512>; + + partitions { + compatible = "fixed-partitions"; + #address-cells = <1>; + #size-cells = <1>; + + partition@0 { + label = "bootloader"; + reg = <0x0 0x400000>; /* 4MB */ + //read-only; + }; - partition@180000 { - label = "u-boot-env"; - reg = <0x180000 0x20000>; /* 128KB */ - read-only; - }; + partition@0x400000 { + label = "environment"; + reg = <0x400000 0x80000>; /* 0.5MB */ + //read-only; + }; - partition@200000 { - label = "uImage"; - reg = <0x0200000 0x600000>; /* 6MB */ - }; + backend_state_nand: partition@0x480000 { + label = "state"; + reg = <0x480000 0x80000>; /* 0.5MB */ + }; - partition@800000 { - label = "minirootfs"; - reg = <0x0800000 0x400000>; /* 4MB */ - }; + partition@0x500000 { + label = "kernel"; + reg = <0x500000 0x1400000>; /* 20MB */ + }; - /* Last MB is for the BBT, i.e. not writable */ - partition@c00000 { - label = "ubifs"; - reg = <0x0c00000 0x7400000>; /* 116MB */ - }; + partition@0x1900000 { + label = "minirootfs"; + reg = <0x1900000 0x6000000>; /* 100MB */ }; + + /* Last MB is for the BBT, i.e. not writable */ }; -}; +}; \ No newline at end of file -- 2.47.3