From patchwork Sat Dec 21 07:54:36 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jagan Teki X-Patchwork-Id: 945 Return-Path: X-Original-To: linux-amarula@patchwork.amarulasolutions.com Delivered-To: linux-amarula@patchwork.amarulasolutions.com Received: from mail-pg1-f197.google.com (mail-pg1-f197.google.com [209.85.215.197]) by ganimede.amarulasolutions.com (Postfix) with ESMTPS id 2D7C23F08E for ; Sat, 21 Dec 2019 08:55:13 +0100 (CET) Received: by mail-pg1-f197.google.com with SMTP id a4sf6548841pgq.23 for ; Fri, 20 Dec 2019 23:55:13 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1576914912; cv=pass; d=google.com; s=arc-20160816; b=OZgJ/RUKQl7fy0KFDBSYMtmdsQwBl9NGWVkVhKLy9jd4msBmmGwP8Q+RC+JxzuDFND sG5umh2+YkITFRMRUejeEk8PV0dePkel4jxQ3xMKuDWaZSvtdZ/tfbXW2QVeT4JJpC7a XAskWE4xgPKcE6deEDEoGpS9lsa77ev8quQOXcaRea6lAqFy5tMsnP0G4dC+YgakX19c R4yAlF2CTr+YdRAtB8y00udiE+dlpIPyidB2Gl4WqzNXTWl5Z5u2Lf+9Jz7N/V49sj76 V3xK+2HApl/SRlrvHAbBc+x0SlMzOOnwiewYayaiiXc4d42Ste2w1aDIdhoLD+jq5qcV Uy5w== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-unsubscribe:list-archive:list-help:list-post:list-id :mailing-list:precedence:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=AUiYCZkZEHVgNzgPOAMxYjpW3FPF9pEMimyRcjLzaj0=; b=SUVy5KLT81xyTchZ62BPIlAmvyQoTayFinyRQU1lDZiJv64+4azYDz1EeiSlNb4mNG lSNqmbDCBq0HvY1sTfyvcSvI/bZSB3tbRj7FrF2xd3s0B8CLIk3VfE8w59kPMqfVXN9M nuypTfGOBd8UuJSGAwKL9cX7edjV7YwAMGChQMHBJHJU9aHQuO1rzOptxpzPPf51Z4Up q5Nm9U3SjXbWb8k85u82EswXem2M9bfFotDU6VbL2qkWsgwAczT9oZwO0k4NmZHXlflA 8/wyLigurJi/kedO2Rp1GExa3FFU6MOx/tJToGxmNO+vosmGFqbWdPjNC4CgMUuExyeb gKIg== ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=ibrsttwv; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:x-original-sender:x-original-authentication-results :precedence:mailing-list:list-id:list-post:list-help:list-archive :list-unsubscribe; bh=AUiYCZkZEHVgNzgPOAMxYjpW3FPF9pEMimyRcjLzaj0=; b=T5Ymj5zh4PfNNo3NVCPMiujBAQYG9KIFA7AMnohuCJXer/mVafpibgWKFFc5IIpp5S APb+oueO+v9nxnRUMxsDe5i/oTU2xLcjLLY23fWQ7ND+qls41B2XTm2H42DgSPLgXxbJ o0GXnSQMUL6meGH7v7TgB8c5/0N5oKSgO8pR8= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:x-original-sender :x-original-authentication-results:precedence:mailing-list:list-id :x-spam-checked-in-group:list-post:list-help:list-archive :list-unsubscribe; bh=AUiYCZkZEHVgNzgPOAMxYjpW3FPF9pEMimyRcjLzaj0=; b=b444Ga3n2lBbo6CnjbrbPC/5jQAU5xfaIXIwWMR3h0vptGrlZTHNUd241lV3fiXWrm 0VoDZATmxG9piieDqjxxwmv12ApeXX95+RdxMYqXm5B3hq4qZcfaZLbJr8uAvhOda0ih 6yfJWWcptMbNXr5MRbeQ+qfYIc3MbSdByviXQB31bOEc1qS52NszhtW/DmXZa4iOUfaZ npb5hf6+mDKek0NiBFeyFVs3Z0rkYJLdRB20uLDO6j7gCNUdU+Zkw9JEQZHVIKJaHEkn Y8VnYJP0JeRpwMOIXY3/yZ48SViZEFK0XtSgM25SssQvXlTBtqUS+PjVg7kIGtDK+xax /A2w== X-Gm-Message-State: APjAAAUZA476Wj1iZRyMyAl2VSFIcxuNEisyYe8UojUK/ucOoU+xs8k+ BoIfMMMFlv7kqoYUBJp8HvzojYw0 X-Google-Smtp-Source: APXvYqw6Op19uFcjcGpssY9dRT/qkRnxvHYXpw/dnGDXrPJhSphHV5KI1fnKnTS8REv+J2UDrExUsA== X-Received: by 2002:a63:ed48:: with SMTP id m8mr18986239pgk.399.1576914911859; Fri, 20 Dec 2019 23:55:11 -0800 (PST) X-BeenThere: linux-amarula@amarulasolutions.com Received: by 2002:a05:6a00:cc:: with SMTP id e12ls2949282pfj.6.gmail; Fri, 20 Dec 2019 23:55:11 -0800 (PST) X-Received: by 2002:a63:1953:: with SMTP id 19mr19034788pgz.157.1576914911380; Fri, 20 Dec 2019 23:55:11 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1576914911; cv=none; d=google.com; s=arc-20160816; b=Emq6kb+feMyI1/BjkDeoWEulw5M8nPLDvMy8H+tfD/rEuGipiZC6p6owyy9MYzLVGl +DglPv5GGwi/Vuy8sNm26CDLIy0EQXFY40GC1CcpuLnVH7oXqNj0AGVvvGw4SxVw6KvB BIuTS8zM0v+1xe+k5mJuSIMkNWBs2QKZR+tVuZrmo5/UVsY00UcZeiRMHGRRUi6B2oyP 4/29LaK+2c2gyQ2MtaUKibNYlDOZt0WhW2KK/bygUawMiR1d5bsET7jfpKjbqQmNJsY6 zxZIY8uoxxsMch8IJLbLIdsCMOZrz7kCEjCqPnQ5HirBTMpy8dxpaco53a5LIlHIWoF4 Z9TQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature; bh=O6MjjW/9J3RipD1dwouziFiSfBSsJxtZgCC8FcpGAZ8=; b=0+C0QWa4FDDiEdQOuJjFEUTuDrhwM2VzxkqpUPOOU7IudKW4lO2rNlFUzvsqVGwkKC ah700Fcr4krNQqUit/EGpOIiaMPuw6GaI4RwuwYEefSbsHp5ciFMA6IbX7Wrw05v57jM df6fOClJvPX6i3sNwaoeGGl5aKfs+ctBcVgFzJ23F1+SNfjQuwTrS8Zcy1T61UnSI5qm P9eh40xFBYHTbZQL5p8DfMmjq1xQFIACgHbvWLn0V67sbsce0Z0wv12b7t0IkmDVurcG DbFw1bg3UnhS6OnSlm5KNJiNwTc2q3BmfY/2xMvRzifOcBaGHQ45b92fMa5OrCBCG69b HsUA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=ibrsttwv; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com Received: from mail-sor-f65.google.com (mail-sor-f65.google.com. [209.85.220.65]) by mx.google.com with SMTPS id x15sor13399558pgf.28.2019.12.20.23.55.11 for (Google Transport Security); Fri, 20 Dec 2019 23:55:11 -0800 (PST) Received-SPF: pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) client-ip=209.85.220.65; X-Received: by 2002:a63:fb05:: with SMTP id o5mr19647783pgh.355.1576914911075; Fri, 20 Dec 2019 23:55:11 -0800 (PST) Received: from localhost.localdomain ([49.206.202.177]) by smtp.gmail.com with ESMTPSA id i9sm15551018pfk.24.2019.12.20.23.55.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 20 Dec 2019 23:55:10 -0800 (PST) From: Jagan Teki To: Simon Glass , Kever Yang , Philipp Tomsich Cc: u-boot@lists.denx.de, linux-amarula , linux-rockchip@lists.infradead.org, Jagan Teki Subject: [PATCH 07/11] env: Enable SPI flash env for rockchip Date: Sat, 21 Dec 2019 13:24:36 +0530 Message-Id: <20191221075440.6944-8-jagan@amarulasolutions.com> X-Mailer: git-send-email 2.18.0.321.gffc6fa0e3 In-Reply-To: <20191221075440.6944-1-jagan@amarulasolutions.com> References: <20191221075440.6944-1-jagan@amarulasolutions.com> MIME-Version: 1.0 X-Original-Sender: jagan@amarulasolutions.com X-Original-Authentication-Results: mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=ibrsttwv; spf=pass (google.com: domain of jagan@amarulasolutions.com designates 209.85.220.65 as permitted sender) smtp.mailfrom=jagan@amarulasolutions.com Content-Type: text/plain; charset="UTF-8" Precedence: list Mailing-list: list linux-amarula@amarulasolutions.com; contact linux-amarula+owners@amarulasolutions.com List-ID: X-Spam-Checked-In-Group: linux-amarula@amarulasolutions.com X-Google-Group-Id: 476853432473 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Most of the SPI flash devices in rockchip are 16MiB size. So, keeping U-Boot proper offset start from 128MiB with 1MiB size and then start env of 8KiB would be a compatible location between all variants of flash sizes. This patch add env start from 0x14000 with a size of 8KiB. Signed-off-by: Jagan Teki Reviewed-by: Kever Yang --- env/Kconfig | 3 +++ 1 file changed, 3 insertions(+) diff --git a/env/Kconfig b/env/Kconfig index 9416a70022..1bb3e1078e 100644 --- a/env/Kconfig +++ b/env/Kconfig @@ -489,6 +489,7 @@ config ENV_OFFSET depends on ENV_IS_IN_EEPROM || ENV_IS_IN_MMC || ENV_IS_IN_NAND || \ ENV_IS_IN_SPI_FLASH default 0x3f8000 if ARCH_ROCKCHIP && ENV_IS_IN_MMC + default 0x140000 if ARCH_ROCKCHIP && ENV_IS_IN_SPI_FLASH default 0x88000 if ARCH_SUNXI default 0xE0000 if ARCH_ZYNQ default 0x1E00000 if ARCH_ZYNQMP @@ -512,6 +513,7 @@ config ENV_SIZE default 0x40000 if ENV_IS_IN_SPI_FLASH && ARCH_ZYNQMP default 0x20000 if ARCH_SUNXI || ARCH_ZYNQ || ARCH_OMAP2PLUS || ARCH_AT91 default 0x8000 if ARCH_ROCKCHIP && ENV_IS_IN_MMC + default 0x2000 if ARCH_ROCKCHIP && ENV_IS_IN_SPI_FLASH default 0x8000 if ARCH_ZYNQMP || ARCH_VERSAL default 0x4000 if ARC default 0x1f000 @@ -521,6 +523,7 @@ config ENV_SIZE config ENV_SECT_SIZE hex "Environment Sector-Size" depends on ENV_IS_IN_FLASH || ENV_IS_IN_SPI_FLASH + default 0x2000 if ARCH_ROCKCHIP default 0x40000 if ARCH_ZYNQMP || ARCH_VERSAL default 0x20000 if ARCH_ZYNQ || ARCH_OMAP2PLUS || ARCH_AT91 help