From patchwork Mon Jun 17 08:56:14 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Caleb Connolly X-Patchwork-Id: 804873 Delivered-To: patch@linaro.org Received: by 2002:adf:fb90:0:b0:360:93e7:1765 with SMTP id a16csp462052wrr; Mon, 17 Jun 2024 01:56:48 -0700 (PDT) X-Forwarded-Encrypted: i=2; AJvYcCX15BiNmiR9d4xrp5+et5U6kaQCtFLhHim3xtQF4bQMs/bIKBHzqqMR5JHDHQTXNzVbD8S6zcMlZ+vNcOv8aoK3 X-Google-Smtp-Source: AGHT+IGMa4028t4zfWYoQOLbnueHAq0CfYYLKznX6NYOtizOXLB1MDm0v3uyLVNsrQpXsEGppzzX X-Received: by 2002:a17:907:d408:b0:a6f:8138:a35a with SMTP id a640c23a62f3a-a6f8138a3e9mr319019366b.5.1718614608038; Mon, 17 Jun 2024 01:56:48 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1718614608; cv=none; d=google.com; s=arc-20160816; b=c1n26T3YK6wiasN+IjS4y6LvwKDXIUy/qQ/vezr4qDR1xabxYuu9wNtmt2CRf0oB8r TjtUG3SrLZmQ66DzGGmWsSl0vOsrAqogMw+f64rzdedKsNhDBfhUL/NS1gaFzlDQ5VoK bKM0UVx/9Lj+hCwlZdjm4Hh6TemMeTEu1GBKx82Ip0fYEOB+ouaetrL+iPi/U2Xu7qrp UqMY+3K+PE5Nc9f6fukoCoSPsNv58fQjEbPnZLQsdMvB2KYFwoaAy/mkhCICYhet39Ly EQCanJ6MLcQWDj0kwwqZMwMLmIRPeiisaCQy2hXPHYvIOpfNpjzd/bRwDpJzM3I8UEb8 M/pA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:list-subscribe:list-help:list-post:list-archive :list-unsubscribe:list-id:precedence:content-transfer-encoding :mime-version:message-id:date:subject:cc:to:from:dkim-signature; bh=+TuMLTzlh/GvtdiyeSsducUjy4fM1iL405jRIFBU1Ms=; fh=8pAQzRFnVN8zrZNtsRM0Iqu2MynFBuynI/J9AcDcpo4=; b=XbtI00sd37zIDstceejWXNzJGqOulQWNwuqOec5NukRMmnkKGuflCmkVZ1Y+wYkO/5 eE54eiP6eZK2Xh8LxA0abdUoo9KAy6bZ2sXK96dwygk+sROVTk0HTDvxGV1+zIWThtsj hu1WwGnM0GlXUSNhrmA9GUbfnxCcQz5QUHTNfBE2pX94XnCDSpry1jjmn3hXBkt6roL8 X7Tmf+SZA9VZrTYuW7k+KdAuaPWOu25QC4PVxuSF5AVRQSmh7E+jVb8pK+cJDJb9CJPn 435z8LSERp9ASBoyoktzK7B1yCzD16YQZgNGAgAcOackyGh9kuDFqcoZfjcBfhm6Nr5E Xf5A==; dara=google.com ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=RtD8tbOU; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from phobos.denx.de (phobos.denx.de. [85.214.62.61]) by mx.google.com with ESMTPS id a640c23a62f3a-a6f56dd68bcsi441919166b.430.2024.06.17.01.56.47 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Jun 2024 01:56:48 -0700 (PDT) Received-SPF: pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) client-ip=85.214.62.61; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=RtD8tbOU; spf=pass (google.com: domain of u-boot-bounces@lists.denx.de designates 85.214.62.61 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 92CE587DC7; Mon, 17 Jun 2024 10:56:46 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=linaro.org header.i=@linaro.org header.b="RtD8tbOU"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id CA91387E52; Mon, 17 Jun 2024 10:56:44 +0200 (CEST) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,SPF_HELO_NONE,SPF_PASS, T_SCC_BODY_TEXT_LINE autolearn=ham autolearn_force=no version=3.4.2 Received: from mail-ej1-x62d.google.com (mail-ej1-x62d.google.com [IPv6:2a00:1450:4864:20::62d]) (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 A17E086784 for ; Mon, 17 Jun 2024 10:56:42 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=linaro.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=caleb.connolly@linaro.org Received: by mail-ej1-x62d.google.com with SMTP id a640c23a62f3a-a63359aaacaso629502866b.1 for ; Mon, 17 Jun 2024 01:56:42 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; t=1718614602; x=1719219402; darn=lists.denx.de; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:from:to:cc:subject:date:message-id:reply-to; bh=+TuMLTzlh/GvtdiyeSsducUjy4fM1iL405jRIFBU1Ms=; b=RtD8tbOU3MsrugxdJFUavPHUvFh8JuWBgMchSgglxSWZ7FDH5YZLT4dMYxm2fdGHYu 9imsoNV2aQ3v5oFmJgGwrxyaiW+NNYinM9b8XctmB4aJgg+4Om42KiJSNpZMGo7FdwHz BtDCQLyHtI2gqa9jFIUTCITRXNTB2p250h0wqd530QyCvvTine6cxV8KvcSkaRRksMk2 cZJRGNt/Juq1B2YGArdsT0I2HzY1eOmIhgzYd5P4mTSf9U+fPSKuNC0fqubwtLHCC7JH tper0Z+P2DtWBhiI91ajPIbtTKHouExTVEAynDAMa2kimDKpQitS3TYgM3lis8yHf0GP Jrbw== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1718614602; x=1719219402; h=content-transfer-encoding:mime-version:message-id:date:subject:cc :to:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=+TuMLTzlh/GvtdiyeSsducUjy4fM1iL405jRIFBU1Ms=; b=B1hQSa68fGJ2hMmBsx/XChFKzSLd4wkglyK8g0y5yoz3NPQhNI6+I1hB/nxxrG8VYc VSgD/L+g+rer1vg72oqQwWIRyvp67sqNd040Lg/K/UtANPbe85vS4kXcH/nLbHk/tUCM FCoJjEo38r9ushzHQqWp/FbOAG3fpf8WcHdyd6EmYmJHv1YjwXwbKOprmsiJ723IJBvK JNZDPP8eSjbfX97TOUNk7ydmvPYZQNZiAQKvMsxVbsRExVOeq+JHJVefMKuZIIJJ0+GD i4S+b97VdU7TijbTX25A38VftHuaVEGqLIbaj1rD+7lpbOh8ovrvzYcW5OGik/yyUefV ODug== X-Gm-Message-State: AOJu0YzIq/VpDO4tHFG9SruP3L+Yfx8XKbqRcs5D+z8x1/avRZ3yHex1 EKlZr3mJk45/LW2zG2ZQqGsI0qyu3VvZDMUDf2ngY/8aJWOYW/pzacEtujnp+y0= X-Received: by 2002:a17:906:2503:b0:a6e:feb5:148e with SMTP id a640c23a62f3a-a6f60d29902mr631281466b.27.1718614601918; Mon, 17 Jun 2024 01:56:41 -0700 (PDT) Received: from cymric.caleb.rex.connolly.tech ([2a02:8109:aa0d:be00::52af]) by smtp.gmail.com with ESMTPSA id a640c23a62f3a-a6f56f9978esm489125066b.200.2024.06.17.01.56.41 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 17 Jun 2024 01:56:41 -0700 (PDT) From: Caleb Connolly To: Caleb Connolly , Neil Armstrong , Sumit Garg , Tom Rini Cc: u-boot@lists.denx.de, u-boot-qcom@groups.io Subject: [PATCH] mach-snapdragon: move default environment to a file Date: Mon, 17 Jun 2024 10:56:14 +0200 Message-ID: <20240617085629.1744017-1-caleb.connolly@linaro.org> X-Mailer: git-send-email 2.45.0 MIME-Version: 1.0 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.8 at phobos.denx.de X-Virus-Status: Clean Make use of CONFIG_DEFAULT_ENV_FILE and move the default qcom environment to a file under board/qualcomm. This is much cleaner and means we don't need to recompile on changing the environment. Additionally, extend the environment to include a boot menu and auto-boot using EFI instead of bootm. Since we now support MMC and USB on most platforms, these are much more useful defaults. Signed-off-by: Caleb Connolly Reviewed-by: Sumit Garg --- board/qualcomm/default.env | 12 ++++++++++++ configs/qcom_defconfig | 2 ++ include/configs/qcom.h | 7 ------- 3 files changed, 14 insertions(+), 7 deletions(-) create mode 100644 board/qualcomm/default.env diff --git a/board/qualcomm/default.env b/board/qualcomm/default.env new file mode 100644 index 000000000000..243aede77be7 --- /dev/null +++ b/board/qualcomm/default.env @@ -0,0 +1,12 @@ +stdin=serial,button-kbd +stdout=serial,vidconsole +stderr=serial,vidconsole +bootfile=/extlinux/extlinux.conf +preboot=scsi scan; usb start +fastboot=fastboot -l $fastboot_addr_r usb 0 +do_boot=bootefi bootmgr +bootmenu_0=Boot first available device=run do_boot +bootmenu_1=Enable fastboot mode=run fastboot +bootmenu_2=Reset device=reset +menucmd=bootmenu +bootcmd=run do_boot diff --git a/configs/qcom_defconfig b/configs/qcom_defconfig index 80ad3b32e139..a9e3797bb39a 100644 --- a/configs/qcom_defconfig +++ b/configs/qcom_defconfig @@ -35,8 +35,10 @@ CONFIG_CMD_BMP=y CONFIG_CMD_LOG=y CONFIG_OF_LIVE=y CONFIG_OF_BOARD_SETUP=y CONFIG_BUTTON_QCOM_PMIC=y +CONFIG_USE_DEFAULT_ENV_FILE=y +CONFIG_DEFAULT_ENV_FILE="board/qualcomm/default.env" CONFIG_CLK=y CONFIG_CLK_QCOM_QCM2290=y CONFIG_CLK_QCOM_QCS404=y CONFIG_CLK_QCOM_SDM845=y diff --git a/include/configs/qcom.h b/include/configs/qcom.h index e50b3bce5cdd..5b5ebbd844df 100644 --- a/include/configs/qcom.h +++ b/include/configs/qcom.h @@ -10,12 +10,5 @@ #define __CONFIGS_SNAPDRAGON_H #define CFG_SYS_BAUDRATE_TABLE { 115200, 230400, 460800, 921600 } -/* Load addressed are calculated during board_late_init(). See arm/mach-snapdragon/board.c */ -#define CFG_EXTRA_ENV_SETTINGS \ - "stdin=serial,button-kbd\0" \ - "stdout=serial,vidconsole\0" \ - "stderr=serial,vidconsole\0" \ - "bootcmd=bootm $prevbl_initrd_start_addr\0" - #endif