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 38291C433EF for ; Fri, 31 Dec 2021 16:15:29 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 91214834CF; Fri, 31 Dec 2021 17:14:42 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (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="V7a7y3+f"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 4B0FD830AD; Fri, 31 Dec 2021 17:14:25 +0100 (CET) Received: from mail-wr1-x435.google.com (mail-wr1-x435.google.com [IPv6:2a00:1450:4864:20::435]) (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 B5728833E7 for ; Fri, 31 Dec 2021 17:14:09 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=amarulasolutions.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=francis.laniel@amarulasolutions.com Received: by mail-wr1-x435.google.com with SMTP id e5so56678364wrc.5 for ; Fri, 31 Dec 2021 08:14:09 -0800 (PST) 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:content-transfer-encoding; bh=dg9D4tbeivUYFzrNAaXJdT1aOIeMzpsEuj3+T1iwaLk=; b=V7a7y3+f79PLXjE2khprbXk0QYrbwWVMgg3D3ogVpW9OyXfVNWrIyrB6vFyG3P77P5 agCAsROQtEOcyoK+Ck6tBsVCs7BxNeTWAmFOEJtZYisYFMkN2qs+Wz6WBFkG8YSsNJwp UXKtYUc7V8VtnlyBpD73mDr4WMiJglpy3RZXI= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=dg9D4tbeivUYFzrNAaXJdT1aOIeMzpsEuj3+T1iwaLk=; b=ACso4zKCQgLmNMIphls7gnBJE2CCnZmuWn/ITBSV+K8L5arpbfAFVh9qIk2Ea+pNXC ZVl49me3XiEen3PdzLNxgn+7brA6LgMZsVz3QFefa88MCNafvvgh0f6eaqe608ISS3qv dZUUMyX2Qdh2d851+y4zgyaJYsr+UmFTeCGptIhR2HZWdwKCKB6iAx5WSedd9AXR02LY dN1WtJICqpVNVs5/u2sc2CG2fCaC0u+Qg8+iFAOlX3J860MKLYP+huQak1QW99vbDZON 5wFndfpHVYNbzT17lrYplmPL9PCOeFZGPMwetJSm4bo9rqjA9x4fR2tbi17zAcpL8UhF V/Ig== X-Gm-Message-State: AOAM533MY5E0B4svGhEK0wqmg+rDiFeCcVqXLKPsTUkI0v7KzcEeuROl amwxLA4gawcfiJMU5urf/2Cd4LTAwWoBTQ== X-Google-Smtp-Source: ABdhPJyx4NzMbF5yImqbY4+ychLtTyFpXNLLvAezO7RipQdyDSBOAQ6iWLYKy5mNSWvmEkb0wBGk3A== X-Received: by 2002:adf:d226:: with SMTP id k6mr28900765wrh.243.1640967248761; Fri, 31 Dec 2021 08:14:08 -0800 (PST) Received: from pwmachine.home ([2a01:cb14:983:1f00:eef7:8bf8:8ee0:cb1a]) by smtp.gmail.com with ESMTPSA id f6sm31855522wmq.6.2021.12.31.08.14.08 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 31 Dec 2021 08:14:08 -0800 (PST) From: Francis Laniel To: u-boot@lists.denx.de Cc: Marek Behun , Michael Nazzareno Trimarchi , Simon Glass , Wolfgang Denk , Harald Seiler , Francis Laniel Subject: [RFC PATCH v1 09/21] cli: Add choice for hush parser. Date: Fri, 31 Dec 2021 17:13:15 +0100 Message-Id: <20211231161327.24918-10-francis.laniel@amarulasolutions.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20211231161327.24918-1-francis.laniel@amarulasolutions.com> References: <20211231161327.24918-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.38 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 For the moment, the choice contains only entry: HUSH_OLD_PARSER which is the default. The goal of this commit is to prepare the field to add a new hush parser and it does not change anything to actual behavior. Signed-off-by: Francis Laniel --- cmd/Kconfig | 14 ++++++++++++++ common/Makefile | 2 +- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/cmd/Kconfig b/cmd/Kconfig index 02c298fdbe..be24346c56 100644 --- a/cmd/Kconfig +++ b/cmd/Kconfig @@ -23,6 +23,20 @@ config HUSH_PARSER If disabled, you get the old, much simpler behaviour with a somewhat smaller memory footprint. +choice HUSH_FLAVOR + bool "Hush flavor to use" + depends on HUSH_PARSER + default HUSH_OLD_PARSER + + config HUSH_OLD_PARSER + bool "Use hush old parser" + 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. +endchoice + config CMDLINE_EDITING bool "Enable command line editing" depends on CMDLINE diff --git a/common/Makefile b/common/Makefile index c500bcd7d8..8b4627fccf 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.25.1