From patchwork Thu Nov 22 19:13:07 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 201138 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Received: from theia.denx.de (theia.denx.de [85.214.87.163]) by ozlabs.org (Postfix) with ESMTP id 1D32E2C0089 for ; Fri, 23 Nov 2012 06:15:29 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id E65CE4A021; Thu, 22 Nov 2012 20:15:23 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id XpjeI3B9Ps0H; Thu, 22 Nov 2012 20:15:23 +0100 (CET) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 76F844A02F; Thu, 22 Nov 2012 20:14:57 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 5648B4A048 for ; Thu, 22 Nov 2012 20:14:50 +0100 (CET) X-Virus-Scanned: Debian amavisd-new at theia.denx.de Received: from theia.denx.de ([127.0.0.1]) by localhost (theia.denx.de [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id xNLSs4THSPTG for ; Thu, 22 Nov 2012 20:14:48 +0100 (CET) X-policyd-weight: NOT_IN_SBL_XBL_SPAMHAUS=-1.5 NOT_IN_SPAMCOP=-1.5 NOT_IN_BL_NJABL=-1.5 (only DNSBL check requested) Received: from mail-fa0-f74.google.com (mail-fa0-f74.google.com [209.85.161.74]) by theia.denx.de (Postfix) with ESMTPS id 261B64A025 for ; Thu, 22 Nov 2012 20:14:48 +0100 (CET) Received: by mail-fa0-f74.google.com with SMTP id t1so346506fae.3 for ; Thu, 22 Nov 2012 11:14:47 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=from:to:cc:subject:date:message-id:x-mailer:in-reply-to:references :x-gm-message-state; bh=IYRpwi3C6BvqNIugkRRxkamGP51GZ+gQ8EcxdmXoS2E=; b=Zt7+I8qJI3KnRcmLJlwXWxpv2uc+iqf6PSvo6XkKv05WsTwugVxj1UGsVo5yE+hOSL Yqvd5sh3AQJMInLDHTJhgA8ljm6tUA2tSU0O/+61TjXLK7UdaKcyFI3eGXryTVKruskO s8wYfFosf0kXXuol3EwoGi0Y6WxTSFuFJfENx30TQdATmxcbeqMS4CiNp0COKEvqDJy+ +Ica8cORkhtQhPG5nCAurQciFhsmwp2yw/11+0JdTRfEi7mYx/wZbLYIpT4zPsymxTKn R2C1QtbMb/lq4A6tr7QAT4NOi4ZZSvfX1O8riazZVS+H41bVy2yYNRP/IXjgFd3+5XKU I10Q== Received: by 10.14.213.135 with SMTP id a7mr2199151eep.2.1353611687807; Thu, 22 Nov 2012 11:14:47 -0800 (PST) Received: from hpza10.eem.corp.google.com ([74.125.121.33]) by gmr-mx.google.com with ESMTPS id u8si1007639een.1.2012.11.22.11.14.47 (version=TLSv1/SSLv3 cipher=AES128-SHA); Thu, 22 Nov 2012 11:14:47 -0800 (PST) Received: from kaka.mtv.corp.google.com (kaka.mtv.corp.google.com [172.22.73.79]) by hpza10.eem.corp.google.com (Postfix) with ESMTP id 70EEA200059; Thu, 22 Nov 2012 11:14:47 -0800 (PST) Received: by kaka.mtv.corp.google.com (Postfix, from userid 121222) id 30EEB160AC8; Thu, 22 Nov 2012 11:14:47 -0800 (PST) From: Simon Glass To: U-Boot Mailing List Date: Thu, 22 Nov 2012 11:13:07 -0800 Message-Id: <1353611587-18186-24-git-send-email-sjg@chromium.org> X-Mailer: git-send-email 1.7.7.3 In-Reply-To: <1353611587-18186-1-git-send-email-sjg@chromium.org> References: <1353611587-18186-1-git-send-email-sjg@chromium.org> X-Gm-Message-State: ALoCoQlvyk9LlMF+Zd5gfqP8HdBiHjGYbccpD6inDKbRxIGjY6NeZAiqSRsDGvhYhDv8hV1EQxx83u2fbeWktw0s1fbVmw6FigE/uO3/BtjzXgxtYnuKiiQaY8p0CXi5C7pjVZXa3RRSarxKELsWr5gIMnjX4vlCPcarEKf35iaTy2Qq2mg0SdZzVa1em4Os1tvIDdOzEtx3 Cc: Tom Rini , Stefan Reinauer Subject: [U-Boot] [PATCH v2 23/23] x86: Add coreboot version to u-boot's version command X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.11 Precedence: list List-Id: U-Boot discussion List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: u-boot-bounces@lists.denx.de Errors-To: u-boot-bounces@lists.denx.de From: Stefan Reinauer Since U-Boot runs from coreboot on x86, the Coreboot version is an important part of the boot state. This version information is available in the coreboot tables, so print it when the 'version' command is used. Signed-off-by: Simon Glass --- Changes in v2: - Add x86 tag to version command patch common/cmd_version.c | 7 ++++++- 1 files changed, 6 insertions(+), 1 deletions(-) diff --git a/common/cmd_version.c b/common/cmd_version.c index ab4c560..e8f40d3 100644 --- a/common/cmd_version.c +++ b/common/cmd_version.c @@ -25,6 +25,9 @@ #include #include #include +#ifdef CONFIG_SYS_COREBOOT +#include +#endif const char __weak version_string[] = U_BOOT_VERSION_STRING; @@ -37,7 +40,9 @@ static int do_version(cmd_tbl_t *cmdtp, int flag, int argc, char * const argv[]) #ifdef LD_VERSION_STRING puts(LD_VERSION_STRING "\n"); #endif - +#ifdef CONFIG_SYS_COREBOOT + printf("coreboot-%s (%s)\n", lib_sysinfo.version, lib_sysinfo.build); +#endif return 0; }