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 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 smtp.lore.kernel.org (Postfix) with ESMTPS id C021EC433EF for ; Wed, 22 Jun 2022 19:21:54 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id DB66984265; Wed, 22 Jun 2022 21:21:52 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (1024-bit key; unprotected) header.d=konsulko.com header.i=@konsulko.com header.b="hnWkcAt5"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 9D7B48421D; Wed, 22 Jun 2022 21:21:51 +0200 (CEST) Received: from mail-qv1-xf2d.google.com (mail-qv1-xf2d.google.com [IPv6:2607:f8b0:4864:20::f2d]) (using TLSv1.3 with cipher TLS_AES_128_GCM_SHA256 (128/128 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 59BB88428F for ; Wed, 22 Jun 2022 21:21:49 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=konsulko.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=trini@konsulko.com Received: by mail-qv1-xf2d.google.com with SMTP id 89so26670661qvc.0 for ; Wed, 22 Jun 2022 12:21:49 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=konsulko.com; s=google; h=from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=wRlJwxxDszrqxqMVdfjjj6cXgYvMBQk0x51uyuleXeQ=; b=hnWkcAt5wgy5Iv37HuM58oamGIKz9Jev7T8oPFi4zFHqqH7oKtKUSkKK+0g8Olc1zG aJY4wdA9Rlv+DxrWJAX5I5okP/+WGhU47fr3Zx08/2i4Z27CpPD5i61cLu89xVm8wjCz CYZ777PJthsPXajt/WuvKMI8fU2fF2WjfNFIQ= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:subject:date:message-id:mime-version :content-transfer-encoding; bh=wRlJwxxDszrqxqMVdfjjj6cXgYvMBQk0x51uyuleXeQ=; b=NPJyxXGDvyb1yHTHtZZE0p4JFXz9SpTSLNXtJWZYez3DSZJcZpJeUYK0jJ8ZBp8hGo FyS31DbRVOhbVa89WR3LbF9aXf/9DSGut4gL69SXYc94oVFSjVOQBBrR4/M9zFIWfcFG D8YTVqSWQyDJn6bl1EjBJZgnfA/ilXPVuX8OGGEr2jWwI7ABN4EGO3AN2ffNpcrvAYhI ydE5OAjhzJ53SKFwWdI/VQf8fn6Dkeuh82D9flaJGfVD4ryCz4vdnkfruclpeTmLloQJ /sc7NxSdYwBTMVe1jcK2D5V8VHJEGyhXB7MSMCFCM2QbfN8XZ1hx5KZObxQtr+w9Ipyl fqYQ== X-Gm-Message-State: AJIora9/w6Vcwcf47o1+LvS+xqwOjU0dliUMRXNhFfc81I7i9KBegyCI Q5HS7fFdMMdhHKK8BPlqLqui6uG4AeH9MA== X-Google-Smtp-Source: AGRyM1u0VpbzkIYpiCfFyCzDrpWLJ15yCdy+0LgkDBaVinUv40g5x2QmKI4LnyR2A3RrG0oZDtzGyA== X-Received: by 2002:ad4:5b8b:0:b0:470:597a:dd91 with SMTP id 11-20020ad45b8b000000b00470597add91mr6615439qvp.10.1655925707187; Wed, 22 Jun 2022 12:21:47 -0700 (PDT) Received: from bill-the-cat.lan (cpe-65-184-195-139.ec.res.rr.com. [65.184.195.139]) by smtp.gmail.com with ESMTPSA id w8-20020a05620a444800b006a6f68c8a87sm18262264qkp.126.2022.06.22.12.21.46 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 22 Jun 2022 12:21:46 -0700 (PDT) From: Tom Rini To: u-boot@lists.denx.de Subject: [PATCH 1/2] gxp: Convert to text file environment Date: Wed, 22 Jun 2022 15:21:44 -0400 Message-Id: <20220622192145.3696770-1-trini@konsulko.com> X-Mailer: git-send-email 2.25.1 MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.39 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.6 at phobos.denx.de X-Virus-Status: Clean Convert this platform to using the text file environment rather than defining CONFIG_EXTRA_ENV_SETTINGS. Signed-off-by: Tom Rini --- board/hpe/gxp/gxp.env | 27 +++++++++++++++++++++++++++ include/configs/gxp.h | 28 ---------------------------- 2 files changed, 27 insertions(+), 28 deletions(-) create mode 100644 board/hpe/gxp/gxp.env diff --git a/board/hpe/gxp/gxp.env b/board/hpe/gxp/gxp.env new file mode 100644 index 000000000000..4760bf1663a7 --- /dev/null +++ b/board/hpe/gxp/gxp.env @@ -0,0 +1,27 @@ +/* SPDX-License-Identifier: GPL-2.0+ */ + +recover_file=openbmc-hpe-recovery-image.mtd +recover_cmd=usb start; mw.b 0xD100000D 0x40; + if fatload usb 0 0x50000000 $recover_file 0x4C0000 0x80000; then + setenv bootargs console=ttyS0,115200 recovery; + setenv force_recovery; + saveenv; + bootm 0x50000000; + else + while itest 0 < 1; do + mw.b 0xd1000005 0xc0; + sleep .1; + mw.b 0xd1000005 0x00; + sleep .1; + done; + fi; + reset; +spiboot=if itest.b *0xD10000B2 == 6; then + run recover_cmd; + fi; + if printenv force_recovery; then + run recover_cmd; + else + bootm 0xfc080000; + run recover_cmd; + fi; diff --git a/include/configs/gxp.h b/include/configs/gxp.h index ae46126399f8..e3c97b20d51e 100644 --- a/include/configs/gxp.h +++ b/include/configs/gxp.h @@ -12,32 +12,4 @@ #define CONFIG_SYS_SDRAM_BASE 0x40000000 -#define CONFIG_EXTRA_ENV_SETTINGS \ - "recover_file=openbmc-hpe-recovery-image.mtd\0" \ - "recover_cmd=usb start; " \ - "mw.b 0xD100000D 0x40; " \ - "if fatload usb 0 0x50000000 $recover_file 0x4C0000 0x80000; then " \ - "setenv bootargs console=ttyS0,115200 recovery; " \ - "setenv force_recovery; " \ - "saveenv; " \ - "bootm 0x50000000; " \ - "else " \ - "while itest 0 < 1; do " \ - "mw.b 0xd1000005 0xc0; " \ - "sleep .1; " \ - "mw.b 0xd1000005 0x00; " \ - "sleep .1; " \ - "done; " \ - "fi; " \ - "reset;\0" \ - "spiboot=if itest.b *0xD10000B2 == 6; then " \ - "run recover_cmd;" \ - "fi;" \ - "if printenv force_recovery; then " \ - "run recover_cmd; " \ - "else " \ - "bootm 0xfc080000; " \ - "run recover_cmd; " \ - "fi;\0" - #endif -- 2.25.1