From patchwork Thu Dec 6 00:46:47 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Glass X-Patchwork-Id: 204088 X-Patchwork-Delegate: sjg@chromium.org 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 2AD062C00D8 for ; Thu, 6 Dec 2012 11:52:56 +1100 (EST) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id C43CD4A196; Thu, 6 Dec 2012 01:52:27 +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 dQNw1j5buUpa; Thu, 6 Dec 2012 01:52:27 +0100 (CET) Received: from theia.denx.de (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 6C4154A197; Thu, 6 Dec 2012 01:50:48 +0100 (CET) Received: from localhost (localhost [127.0.0.1]) by theia.denx.de (Postfix) with ESMTP id 7F10D4A142 for ; Thu, 6 Dec 2012 01:50:32 +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 NDT5LtYN9D5s for ; Thu, 6 Dec 2012 01:50:31 +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-vb0-f74.google.com (mail-vb0-f74.google.com [209.85.212.74]) by theia.denx.de (Postfix) with ESMTPS id 025C64A11C for ; Thu, 6 Dec 2012 01:50:17 +0100 (CET) Received: by mail-vb0-f74.google.com with SMTP id s24so640601vbi.3 for ; Wed, 05 Dec 2012 16:50:16 -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=3I3zQ0lRJMeMFV7duo3GF2mXhxdiCXVIS5NYJSJIb5Q=; b=UNwMDv0iDPafdDAUe3hAFBr1KSrDAqh4hUIee1tspMptP/5Q7zzpWLcjybj3PMWRGU uRmi8iUBnpo3criISKCgVLyhpZlzjK/6Wa4zYXVzkIt5/MQUMJeDowZU9kzJAkuAO/1y hmPQfFbBs05CMt8df6XbBmJEZ7rm4VQjwDq5wrtFEduZUZjd6DybiECT1m4CO4WJlAl6 yab32XoAVyYNwxVKKfRFHuRhCryZip93trqtkir0DNsKoftAGSIoaZ4YVlsFIERREhoK c4347QeSwdOOaSYEeoteXYbytctW7NnOKLjeQaay7St8nt1vjOmgvmTWScN2yc5HHHH4 NBUA== Received: by 10.236.89.114 with SMTP id b78mr12395678yhf.16.1354755016330; Wed, 05 Dec 2012 16:50:16 -0800 (PST) Received: from wpzn3.hot.corp.google.com (216-239-44-65.google.com [216.239.44.65]) by gmr-mx.google.com with ESMTPS id i63si522910yhk.5.2012.12.05.16.50.16 (version=TLSv1/SSLv3 cipher=AES128-SHA); Wed, 05 Dec 2012 16:50:16 -0800 (PST) Received: from kaka.mtv.corp.google.com (kaka.mtv.corp.google.com [172.22.73.79]) by wpzn3.hot.corp.google.com (Postfix) with ESMTP id 2E68D100048; Wed, 5 Dec 2012 16:50:16 -0800 (PST) Received: by kaka.mtv.corp.google.com (Postfix, from userid 121222) id 0AFCF160A46; Wed, 5 Dec 2012 16:50:15 -0800 (PST) From: Simon Glass To: U-Boot Mailing List Date: Wed, 5 Dec 2012 16:46:47 -0800 Message-Id: <1354754807-21449-21-git-send-email-sjg@chromium.org> X-Mailer: git-send-email 1.7.7.3 In-Reply-To: <1354754807-21449-1-git-send-email-sjg@chromium.org> References: <1354754807-21449-1-git-send-email-sjg@chromium.org> X-Gm-Message-State: ALoCoQmn7Co7yZGuUTPBJcIxnNuVcbsbZ+1ax7Elk017v5BaScXOh9yXY3Pq0NKZTZYn5mVISW1xFSUiXfUxSJ+6Hf5oIAo8rrXSN8kgl35YgGCCBoiX8Cj/EwMGyifdn5h0FYAAE3CrP9+TABym1FmLLBmbnzOTxxvEOkzshl27OvfDWXVyQaDmWUIFpfZAeHxQIM9L+hQU Cc: Tom Rini , Stefan Reinauer Subject: [U-Boot] [PATCH v3 20/20] 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 v3: None 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; }