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 2732BC7EE23 for ; Thu, 8 Jun 2023 18:38:22 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 062E986183; Thu, 8 Jun 2023 20:35:43 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=amarulasolutions.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=amarulasolutions.com header.i=@amarulasolutions.com header.b="Y1zBQUX0"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 9F7B7860BC; Thu, 8 Jun 2023 20:35:34 +0200 (CEST) Received: from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com [IPv6:2a00:1450:4864:20::32a]) (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 74AEA86124 for ; Thu, 8 Jun 2023 20:35:25 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=amarulasolutions.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=francis.laniel@amarulasolutions.com Received: by mail-wm1-x32a.google.com with SMTP id 5b1f17b1804b1-3f6da07ff00so9201655e9.3 for ; Thu, 08 Jun 2023 11:35:25 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; t=1686249325; x=1688841325; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=lygFXeSIQu9TiKVMsbuDrx1syQI3VmOkBEX5m4HrXnE=; b=Y1zBQUX0TTM3/5YhtrRqcEiodDBfaqV2VG1IW1wfdwrE6GcqgiaEjtlEi8hZ0rq+ov 4NO2CGdmC2JPlsQ8dJiCNolhv4L09NepuHGjsJrjOQjrsc3TAOdTlXxvtFYB6eyAHSRD gudlsONXB41TwnnFaNJnYiAr9Heb+WrHV1mZ8= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1686249325; x=1688841325; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=lygFXeSIQu9TiKVMsbuDrx1syQI3VmOkBEX5m4HrXnE=; b=MY+IYZdYMMWiuZbgxPgxDbmbhwUh8WlReaWSC18AK3YbKS0xje5xMN5b9TIWtVCtYi 3XStUtnMeJxz4ong27a5kg6qkqyX3y8AOSKzFdAcPNp4/PYHw3tG/MVtqCnJxwBc7j24 F4FBhmlzQoCV6ji9EfRimJFKdMU23RVpeAij5NDRZFSqUJOMDAsSXoi4G8vMEpnK32Bn o3C18tTDyKoe+H998kfw7YrbO+5jMz+xNFnfp3sWAtPYA36epwvlXKPv52BQt37a6PX2 czGVZ7T6zXeZP/YFG46ZVmD5NBW1kAsq+nJW5M7SpKVA2AduJlt5Y0vyu8B9r9oE2cBi cJsQ== X-Gm-Message-State: AC+VfDxVkLUikgC2S6jgX+FzS7UrzPCfX3xdoH5ag/dTJYjcHOsHH5dg 8HqIcU/9qZEiHr/xAyAFhXoiw1WZ4MLK3jIVZbOgBQ== X-Google-Smtp-Source: ACHHUZ5RaFE85Npkp5FwSaEoHXJh2UdnGLoQK0Tnp/9KsgXM3niRl9OYLTSiJ0LnimLo/2r4pExqQA== X-Received: by 2002:a7b:c042:0:b0:3f7:f2d0:b904 with SMTP id u2-20020a7bc042000000b003f7f2d0b904mr2421556wmc.8.1686249325023; Thu, 08 Jun 2023 11:35:25 -0700 (PDT) Received: from pwmachine.home (120.124.191.92.dynamic.jazztel.es. [92.191.124.120]) by smtp.gmail.com with ESMTPSA id t10-20020a1c770a000000b003f8009be6c0sm408783wmi.3.2023.06.08.11.35.23 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 08 Jun 2023 11:35:24 -0700 (PDT) From: Francis Laniel To: u-boot@lists.denx.de Cc: Michael Nazzareno Trimarchi , Tom Rini , Simon Glass , Harald Seiler , Francis Laniel , Heinrich Schuchardt , Ilias Apalodimas , Ramon Fried , Sean Edmond , Tobias Waldekranz , John Keeping , Devarsh Thakkar , Nikhil M Jain , Patrick Delaunay , Stefan Roese Subject: [RFC PATCH v9 09/23] cli: Add menu for hush parser Date: Thu, 8 Jun 2023 19:34:24 +0100 Message-Id: <20230608183438.16748-10-francis.laniel@amarulasolutions.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230608183438.16748-1-francis.laniel@amarulasolutions.com> References: <20230608183438.16748-1-francis.laniel@amarulasolutions.com> 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.8 at phobos.denx.de X-Virus-Status: Clean For the moment, the menu contains only entry: HUSH_OLD_PARSER which is the default. The goal is to prepare the field to add a new hush parser which guarantees actual behavior is still correct. Reviewed-by: Simon Glass Signed-off-by: Francis Laniel --- cmd/Kconfig | 13 +++++++++++++ common/Makefile | 2 +- 2 files changed, 14 insertions(+), 1 deletion(-) diff --git a/cmd/Kconfig b/cmd/Kconfig index 365371fb51..4a1dad3b54 100644 --- a/cmd/Kconfig +++ b/cmd/Kconfig @@ -23,6 +23,19 @@ config HUSH_PARSER If disabled, you get the old, much simpler behaviour with a somewhat smaller memory footprint. +menu "Hush flavor to use" + depends on HUSH_PARSER + + config HUSH_OLD_PARSER + bool "Use hush old parser" + default y + help + This option enables the old flavor of hush based on hush Busybox from + 2005. + + It is actually the default U-Boot shell when decided to use hush as shell. +endmenu + config CMDLINE_EDITING bool "Enable command line editing" depends on CMDLINE diff --git a/common/Makefile b/common/Makefile index c87bb2e78b..93d0a5a309 100644 --- a/common/Makefile +++ b/common/Makefile @@ -8,7 +8,7 @@ ifndef CONFIG_SPL_BUILD obj-y += init/ obj-y += main.o obj-y += exports.o -obj-$(CONFIG_HUSH_PARSER) += cli_hush.o +obj-$(CONFIG_HUSH_OLD_PARSER) += cli_hush.o obj-$(CONFIG_AUTOBOOT) += autoboot.o # # boards -- 2.34.1