From mboxrd@z Thu Jan 1 00:00:00 1970 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 D9E23C433F5 for ; Wed, 12 Jan 2022 20:04:20 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 8C9EB83311; Wed, 12 Jan 2022 21:03:54 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org 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=chromium.org header.i=@chromium.org header.b="Cm9uMcg0"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 7D56D83373; Wed, 12 Jan 2022 21:03:51 +0100 (CET) Received: from mail-oi1-x235.google.com (mail-oi1-x235.google.com [IPv6:2607:f8b0:4864:20::235]) (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 E0DBA83381 for ; Wed, 12 Jan 2022 21:03:45 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=pass (p=none dis=none) header.from=chromium.org Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=sjg@google.com Received: by mail-oi1-x235.google.com with SMTP id w188so4814684oib.7 for ; Wed, 12 Jan 2022 12:03:45 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=1AL2oGHzJt59OAaeHLAjgoSK0Vqmx/UjdGcxOZM29a8=; b=Cm9uMcg0uypyRMCHZt0wyE8ZuDLl07cWDFpm7tOgaZETtmBepbxPv7NGjmj6OXPKsZ pkOGElZaMF239otIVCRpxEfoC0VNZYBtvKtNqcQc5YV6tDgbeR8yCc2cfWVf7tv4zfiC tiWqhwWUdaPaR24KCEeL4bB+MvHqnhfunEFAY= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=1AL2oGHzJt59OAaeHLAjgoSK0Vqmx/UjdGcxOZM29a8=; b=r/nKok4Ib5XiE0LYHbjmNxjk4v4sNBmb2trO+fGwSrhyvKdwuaw0+44lcN0QATOnn3 giy8l+4SOPOtkwj4Ujh4cQabYD5I+l6N4rtW6xsECFeoBv4FDvOqWXAuNgLEnmwMtNRW dq8SIz0puY2ML9tDMIuPA+mE96GXA8hbqyHBhDlGPEUZLHrfUKCWsDUfYPxl8SjAdaP1 U5v0U5r9j1sBgZUrj+I5XTUlHFAnq5G7jdjEvreaT+7qxjFAg+yA0tDdLijZhQ8zVahl j8b2V4tf87BkJUxLqK7HyeB2nNHkcyq3sST3Jz7heLHHUrkKiK89k4iVhVmufzIAGUBW 8L5Q== X-Gm-Message-State: AOAM5319CcbSxBTJzEkqT+n8rmCeh93hEV0MLHrM2TlPArGq9bzf99Ro nwu0hRgjLDP4l7AfsmsOFlRNhtCmDV3EW/9/9m39ow== X-Google-Smtp-Source: ABdhPJxREpvlfci2qQl/1OhrGftuH0cfs9BbHbAQMhEcgJd4gs3SzPsENF1HnEaimcDmTPFulZJSh9/GX6OLrQC4isE= X-Received: by 2002:a05:6808:16a3:: with SMTP id bb35mr886083oib.72.1642017824159; Wed, 12 Jan 2022 12:03:44 -0800 (PST) MIME-Version: 1.0 References: <20211231161327.24918-1-francis.laniel@amarulasolutions.com> <20211231161327.24918-9-francis.laniel@amarulasolutions.com> In-Reply-To: <20211231161327.24918-9-francis.laniel@amarulasolutions.com> From: Simon Glass Date: Wed, 12 Jan 2022 13:03:30 -0700 Message-ID: Subject: Re: [RFC PATCH v1 08/21] cli: Port Busybox 2021 hush to U-Boot. To: Francis Laniel Cc: U-Boot Mailing List , Marek Behun , Michael Nazzareno Trimarchi , Wolfgang Denk , Harald Seiler Content-Type: text/plain; charset="UTF-8" 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.2 at phobos.denx.de X-Virus-Status: Clean On Fri, 31 Dec 2021 at 09:14, Francis Laniel wrote: > > This commit adds new file cli_hush_2021.c, it is a copy of Busybox hush file as > it was of time to commit 37460f5da. > This commit modifies Busybox hush to not compile some part specific to Busybox > and adds some code > needed by U-Boot. > The modifications consists mainly on adding code #if(n)def guards. > > For the moment, this refurbished flavor of hush only permits running command > without any keywords (i.e., if and for are not recognized) or variable expansion > (i.e., echo $foo prints foo and not value stored in variable foo). > > A new file was also added to define some functions specific to U-Boot. > > Signed-off-by: Francis Laniel > Signed-off-by: Harald Seiler > --- > common/cli_hush_2021.c | 292 ++++++++++++++++++++ > common/cli_hush_2021_upstream.c | 470 +++++++++++++++++++++++++++++++- > 2 files changed, 761 insertions(+), 1 deletion(-) > create mode 100644 common/cli_hush_2021.c > Reviewed-by: Simon Glass