From patchwork Mon Jul 26 10:20:17 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dimitri John Ledkov X-Patchwork-Id: 1509958 X-Patchwork-Delegate: uboot@andestech.com Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Authentication-Results: ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=canonical.com header.i=@canonical.com header.a=rsa-sha256 header.s=20210705 header.b=Fp7rXmG1; dkim-atps=neutral Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by ozlabs.org (Postfix) with ESMTPS id 4GYGCN2X22z9sXJ for ; Mon, 26 Jul 2021 20:20:32 +1000 (AEST) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 38C2D83301; Mon, 26 Jul 2021 12:20:27 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=canonical.com 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=canonical.com header.i=@canonical.com header.b="Fp7rXmG1"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id F3EE983303; Mon, 26 Jul 2021 12:20:25 +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.0 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,SPF_HELO_NONE autolearn=ham autolearn_force=no version=3.4.2 Received: from smtp-relay-canonical-1.canonical.com (smtp-relay-canonical-1.canonical.com [185.125.188.121]) (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 AE431832FD for ; Mon, 26 Jul 2021 12:20:22 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=canonical.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=dimitri.ledkov@canonical.com Received: from mail-wr1-f70.google.com (mail-wr1-f70.google.com [209.85.221.70]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-canonical-1.canonical.com (Postfix) with ESMTPS id 586723F349 for ; Mon, 26 Jul 2021 10:20:22 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1627294822; bh=NzUqfO3jw+rrwh5e/R7QdfJWhI9S8EwTUQ135l5W0zc=; h=From:To:Cc:Subject:Date:Message-Id:MIME-Version; b=Fp7rXmG1908JOdBCOKI3uqUDnpN2BFhIECFMwXJbSHO1UGPTXAwDtg/lSB/bdgmyx jhQD4O2iVR0CaO/TZvuXYwJHGf8qaWbla3OQxWfgkDBChBBNlo3vC+Z9jXbCMhwDyh zzb3GqtAjMMo35Ye+CmZOV97eyum6RaGzujarNAPduSeA0QLyJv0Q8GyKmPQAgezeF WTTYiZUn/z9Av37hO0gywtIFTshrWFCcrJVhK8Y+bv4Ht2cghR6dHLC7g+Hoen/NaG nOBfH+GIsvmV2dSmm4IM3NBwVh9+GJkyCT6rsMLGZ6t+AorVH6rkv67Q9lKM83Cbzj SiExQjUr/4GjA== Received: by mail-wr1-f70.google.com with SMTP id p2-20020a5d48c20000b0290150e4a5e7e0so4501408wrs.13 for ; Mon, 26 Jul 2021 03:20:22 -0700 (PDT) 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:mime-version :content-transfer-encoding; bh=NzUqfO3jw+rrwh5e/R7QdfJWhI9S8EwTUQ135l5W0zc=; b=fSqVZ+IMAyO6U4A40dfSErEjQEcZhe9v6VjzoDtbpEsbWdVEnuj1A3xK1ju9Q+rwag ERVqGBZic95ClAFuAetr88ABVzJxWz3zMhJ4QOlboBBZhvvEQszeLqOdUN98pk9gBP+r hafvmhWWlQwQLPheXye/HHlJpV1CM45s75SFs2LnJccZOCltAdBP+492ffioXoMSNeT+ oZ5PFdYTA8/xPR7mXbUWCyzELbjYIWw/pxV/qrEtC+3S9PIB7aJOT1adeX8C59l0blF+ a7MbfYlqu/uvoNJfclYrBYohy0+Jpji8IP3fJb08bXw7SEwtYCBnkf/XiHIeW7Jxlc3D /4PQ== X-Gm-Message-State: AOAM532zFyY4qySm8NETpxUgnxWRjNU4zlw0RCmBsXEbpUiyh+I8f4UI J0/z3F1fLdsdaFaNlMMHQDlnbfVx+qN5BaHLs5FNKBAp7HOlNSjByBNYeqxTESH++X882Z9Di+X 8aC0De8+RCUPw4F/6yIXxg/bl8xhsBOM= X-Received: by 2002:a1c:c91a:: with SMTP id f26mr16521675wmb.162.1627294821801; Mon, 26 Jul 2021 03:20:21 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyZYQyWsWTGTJ/psASeL/oGx5t9J2RFPkOpM0FSwcy9ile66Yr7MHtbhejTEf44aRetZhQXRg== X-Received: by 2002:a1c:c91a:: with SMTP id f26mr16521667wmb.162.1627294821611; Mon, 26 Jul 2021 03:20:21 -0700 (PDT) Received: from localhost ([2a01:4b00:85fd:d700:e841:2407:b739:ad64]) by smtp.gmail.com with ESMTPSA id n18sm40450932wrt.89.2021.07.26.03.20.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 26 Jul 2021 03:20:21 -0700 (PDT) From: Dimitri John Ledkov To: u-boot@lists.denx.de Cc: Fu Wei , David Abdurachmanov Subject: [PATCH v3] qemu-riscv64_smode: fix extlinux (define preboot) Date: Mon, 26 Jul 2021 11:20:17 +0100 Message-Id: <20210726102017.15487-1-dimitri.ledkov@canonical.com> X-Mailer: git-send-email 2.30.2 MIME-Version: 1.0 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 Commit 37304aaf60bf ("Convert CONFIG_USE_PREBOOT and CONFIG_PREBOOT to Kconfig") removed preboot commands in RISC-V targets and broke extlinux support as reported by Fu Wei . The patch finishes migration of CONFIG_USE_PREBOOT and CONFIG_REBOOT to Kconfig. Fixes: 37304aaf60bf ("Convert CONFIG_USE_PREBOOT and CONFIG_PREBOOT to Kconfig") Reported-By: Fu Wei Signed-off-by: David Abdurachmanov Signed-off-by: Dimitri John Ledkov Reviewed-by: Leo Yu-Chi Liang --- changes since my v1 patch: - Add reported-by & fixes tags changes since my v2 patch: - use savedefconfig to order defconfig correctly Original patch author is David Abdurachmanov Previously this was submitted in 2019 https://patchwork.ozlabs.org/project/uboot/patch/20190821190720.4286-1-david.abdurachmanov@sifive.com/ Since then the sifive fu540 portion of this change was merged, but not the qemu one. Submitting the qemu portion again. Without this change, qemu smode cannot boot Ubuntu's riscv64 cloud images with extlinux.conf. configs/qemu-riscv64_smode_defconfig | 2 ++ 1 file changed, 2 insertions(+) diff --git a/configs/qemu-riscv64_smode_defconfig b/configs/qemu-riscv64_smode_defconfig index 0000564e41..4a6416e254 100644 --- a/configs/qemu-riscv64_smode_defconfig +++ b/configs/qemu-riscv64_smode_defconfig @@ -6,6 +6,8 @@ CONFIG_ARCH_RV64I=y CONFIG_RISCV_SMODE=y CONFIG_DISTRO_DEFAULTS=y CONFIG_FIT=y +CONFIG_USE_PREBOOT=y +CONFIG_PREBOOT="setenv fdt_addr ${fdtcontroladdr}; fdt addr ${fdtcontroladdr};" CONFIG_DISPLAY_CPUINFO=y CONFIG_DISPLAY_BOARDINFO=y CONFIG_CMD_BOOTEFI_SELFTEST=y