From patchwork Mon Nov 5 09:06:52 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: AKASHI Takahiro X-Patchwork-Id: 150161 Delivered-To: patch@linaro.org Received: by 2002:a2e:299d:0:0:0:0:0 with SMTP id p29-v6csp2358722ljp; Mon, 5 Nov 2018 01:11:52 -0800 (PST) X-Google-Smtp-Source: AJdET5dXhZ9EWl27TJ6fbCi2jxNS4bdH5A3f6O0AAC2N5gHX5f4GjMhwjsNlchejHXKqRyqnZvA6 X-Received: by 2002:a17:906:5a0a:: with SMTP id p10-v6mr13763817ejq.43.1541409112682; Mon, 05 Nov 2018 01:11:52 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1541409112; cv=none; d=google.com; s=arc-20160816; b=shg6u8tTTkQniw3DK8X7n1j0PEeQ7Fvw4eTXcSmfewvM58qCjo/ESVdUlcQyiaO1ec iBwKwVwwTNeq96v0ebxq9XaXrhye1GTW0mZ27hUZaEn+2Z98ofJGb2oCpi8ys8s9nfH3 l5JOX6nq/BauAAq1SOlQ2CPzxySBrlVZNokjbqIeNcCB6laPyYQJS7jShuZRFAybblD3 6dFs9h4A2FEzoFW0Q09/UkO6NZY6+puSVMQAXXiVFCUDrGFDxANR+Zm6VyBxXTQ9zBW/ MnVJ4gOZXIDlkDenZRIqBjsxS8BUJLvGJ2OgotjcznC+sT/3ttbeydjKFFzqPCkkceMS OqKQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=sender:errors-to:content-transfer-encoding:list-subscribe:list-help :list-post:list-archive:list-unsubscribe:list-id:precedence:subject :cc:mime-version:references:in-reply-to:message-id:date:to:from :dkim-signature; bh=4mSm3khrStCzzhTFjShWHiq0zOQARuvPZw4DuR9oW6s=; b=xWnSwBKgPMpQSyo0Hp1LsVs1WkDh3G4EfSzG1lH5rOpA9ZWI8qjVdoodvKGuiZKVZ8 5PEGO0X/jH46kAx3KN6A1JBb5zH47xCI4DFgSnXg5/SiguO59fVmF89rv/25+jUMMCKQ jpUF84Ke0Z9DYEZTLCkqcJRN2IXH3P79mRZfUqNYgg4J8GFBi11J7JnkR9N3XrvjxSKd WuxJAt033laRNk/B0LeYxRjgeu3vP/5q1BSZZkTCpgw8d8QZSDl8yY8pivIVKJy7UdXP UmDrpfxLb322qMrgs669tu9em1WmNqbD7zGrl1ae8k7ua3qQ7rR+xbD7KpMwEQ3WLGRR iu8w== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=WlkzVTNp; spf=pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from lists.denx.de (dione.denx.de. [81.169.180.215]) by mx.google.com with ESMTP id a18-v6si4524008ejp.257.2018.11.05.01.11.52; Mon, 05 Nov 2018 01:11:52 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) client-ip=81.169.180.215; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=WlkzVTNp; spf=pass (google.com: best guess record for domain of u-boot-bounces@lists.denx.de designates 81.169.180.215 as permitted sender) smtp.mailfrom=u-boot-bounces@lists.denx.de; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: by lists.denx.de (Postfix, from userid 105) id 4F917C22644; Mon, 5 Nov 2018 09:09:27 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on lists.denx.de X-Spam-Level: X-Spam-Status: No, score=0.0 required=5.0 tests=RCVD_IN_MSPIKE_H2, T_DKIM_INVALID autolearn=unavailable autolearn_force=no version=3.4.0 Received: from lists.denx.de (localhost [IPv6:::1]) by lists.denx.de (Postfix) with ESMTP id DBF1EC22214; Mon, 5 Nov 2018 09:09:24 +0000 (UTC) Received: by lists.denx.de (Postfix, from userid 105) id D58F5C221F7; Mon, 5 Nov 2018 09:05:27 +0000 (UTC) Received: from mail-yb1-f193.google.com (mail-yb1-f193.google.com [209.85.219.193]) by lists.denx.de (Postfix) with ESMTPS id B2A46C22228 for ; Mon, 5 Nov 2018 09:05:23 +0000 (UTC) Received: by mail-yb1-f193.google.com with SMTP id i78-v6so3488040ybg.0 for ; Mon, 05 Nov 2018 01:05:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=dWhOR3dnYcdkdhkvjAt25icHpNn8S0syUXenH+co7oA=; b=WlkzVTNpbAVMznDxUElXDg3HO5nqemmaGmH2Hyd1k/7Tn/mY2kJXEqwnx5KhhKhaBh I1CMpI9E3UPehMfOkLXv2JLM4grBIe1WEqkwNTO0YetE2qaV5+zphlEU/TKK40zgxu/x G2Z0gGZTyEOcuz+OTLhbv0S13WPy3Rj/NRuuo= 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:in-reply-to :references:mime-version:content-transfer-encoding; bh=dWhOR3dnYcdkdhkvjAt25icHpNn8S0syUXenH+co7oA=; b=SQavLWBNT/JIoDWOCklPYnKfrVbT0pjCoySZbtSKGtdNrSECc2U0yVorpKYvC+Y5BB 6r6rxtL7CGXJUBYcKsouw0MvJMVStMAq6HoBIm7lLuxOZsee5/vsenv6ZYeNulTYxf9a tH7IIF0fBvsdt755REzqtFQ/vzEag/gEMPrsY2sRrdpovaQWvI2wDnPLECeYPtP+ICET Rix07ONCJiYgHt+P3qaz1O7xO3XiJmLZ5op/S/GzA5FPgdyM1FvdYmoomROMcXXfjM7R WV/UN2hWlPTHgVGOU1uvqnPn3H9xx8SoLu97aZ167MdGPntNVy+yTUly3JtyoKt1k4px 2khQ== X-Gm-Message-State: AGRZ1gLop+lqKUfXimMyoWnIQBJymSIj3feWnuhWl+/S1zzGcgYk82dL 1lEvXSEs4mJSbW0P6l3f06YnQw== X-Received: by 2002:a25:1d05:: with SMTP id d5-v6mr20536733ybd.395.1541408722597; Mon, 05 Nov 2018 01:05:22 -0800 (PST) Received: from linaro.org ([121.95.100.191]) by smtp.googlemail.com with ESMTPSA id 10-v6sm7591744ywt.47.2018.11.05.01.05.22 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 05 Nov 2018 01:05:22 -0800 (PST) From: AKASHI Takahiro To: trini@konsulko.com, agraf@suse.de Date: Mon, 5 Nov 2018 18:06:52 +0900 Message-Id: <20181105090653.7409-14-takahiro.akashi@linaro.org> X-Mailer: git-send-email 2.19.0 In-Reply-To: <20181105090653.7409-1-takahiro.akashi@linaro.org> References: <20181105090653.7409-1-takahiro.akashi@linaro.org> MIME-Version: 1.0 Cc: xypron.glpk@gmx.de, u-boot@lists.denx.de Subject: [U-Boot] [PATCH v2 13/14] cmd: efishell: export uefi variable helper functions X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.18 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" Those function will be used for integration with 'env' command so as to handle uefi variables. Signed-off-by: AKASHI Takahiro --- cmd/efishell.c | 4 ++-- include/command.h | 2 ++ 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/cmd/efishell.c b/cmd/efishell.c index bd2b99e74079..8122b842dd76 100644 --- a/cmd/efishell.c +++ b/cmd/efishell.c @@ -68,7 +68,7 @@ static void dump_var_data(char *data, unsigned long len) * * efi_$guid_$varname = {attributes}(type)value */ -static int do_efi_dump_var(int argc, char * const argv[]) +int do_efi_dump_var(int argc, char * const argv[]) { char regex[256]; char * const regexlist[] = {regex}; @@ -228,7 +228,7 @@ out: return 0; } -static int do_efi_set_var(int argc, char * const argv[]) +int do_efi_set_var(int argc, char * const argv[]) { char *var_name, *value = NULL; unsigned long size = 0; diff --git a/include/command.h b/include/command.h index 5bb675122cce..2ce8b53f74c8 100644 --- a/include/command.h +++ b/include/command.h @@ -50,6 +50,8 @@ extern int do_run(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]); #endif #if defined(CONFIG_CMD_BOOTEFI) int do_bootefi_bootmgr_exec(int boot_id); +int do_efi_dump_var(int argc, char * const argv[]); +int do_efi_set_var(int argc, char * const argv[]); #endif /* common/command.c */