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 C6F1FC0015E for ; Fri, 14 Jul 2023 16:45:11 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id B8C0C86DEB; Fri, 14 Jul 2023 18:44:35 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=quarantine dis=none) header.from=collabora.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=u-boot-bounces@lists.denx.de Authentication-Results: phobos.denx.de; dkim=pass (2048-bit key; unprotected) header.d=collabora.com header.i=@collabora.com header.b="XJeziSX7"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id C815186DE4; Fri, 14 Jul 2023 18:44:29 +0200 (CEST) Received: from madras.collabora.co.uk (madras.collabora.co.uk [46.235.227.172]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits)) (No client certificate requested) by phobos.denx.de (Postfix) with ESMTPS id 5BFAC86DD2 for ; Fri, 14 Jul 2023 18:44:27 +0200 (CEST) Authentication-Results: phobos.denx.de; dmarc=pass (p=quarantine dis=none) header.from=collabora.com Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=detlev.casanova@collabora.com Received: from arisu.hitronhub.home (unknown [23.233.251.139]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits) server-digest SHA256) (No client certificate requested) (Authenticated sender: detlev) by madras.collabora.co.uk (Postfix) with ESMTPSA id 40040660705E; Fri, 14 Jul 2023 17:44:26 +0100 (BST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1689353067; bh=EZJ62zfpNuvi0BhRi+P+9bd6T8SPITHFgfYXVTOWYM0=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=XJeziSX78mY1cztGfNOeemDTT1ljY80367CM/kphKwcIMroHGdkv/Nbv0y4tPdI8q AXJ5ITbl/ikytytVudVMFvsvCH/Rtr7j4Mp5L4U1Rrrg7DhbRGA+yWx5NU9Dljz3Uk RWFcqQSGJX4XKz9lDyltOaiCU156eDBcyuAUSEjeZLSA2hxU9So5AfKmbodLrwnesD dtM49BzQfsRo1xvlrUyQx6A4in0TB+f89mXzScqwgAGohlzlYT3njQP7DtWyUXZ+t/ dgoHbOA3NP+Vh57yytd+n4nbcmc7Kyqmnxmkzq1iX+FtgxUYpImfloyTFFMAuX2eWo LR2UOrpLMcIjA== From: Detlev Casanova To: u-boot@lists.denx.de Cc: Marek Vasut , Hai Pham , Tam Nguyen , Simon Glass , Detlev Casanova Subject: [PATCH v3 4/6] sysinfo: Add documentation Date: Fri, 14 Jul 2023 12:43:46 -0400 Message-ID: <20230714164424.838842-5-detlev.casanova@collabora.com> X-Mailer: git-send-email 2.41.0 In-Reply-To: <20230714164424.838842-1-detlev.casanova@collabora.com> References: <20230714164424.838842-1-detlev.casanova@collabora.com> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 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.8 at phobos.denx.de X-Virus-Status: Clean Add documentation for the sysinfo command with examples. Signed-off-by: Detlev Casanova --- doc/usage/cmd/sysinfo.rst | 56 +++++++++++++++++++++++++++++++++++++++ 1 file changed, 56 insertions(+) create mode 100644 doc/usage/cmd/sysinfo.rst diff --git a/doc/usage/cmd/sysinfo.rst b/doc/usage/cmd/sysinfo.rst new file mode 100644 index 00000000000..3dad1f4f38d --- /dev/null +++ b/doc/usage/cmd/sysinfo.rst @@ -0,0 +1,56 @@ +.. SPDX-License-Identifier: GPL-2.0+: + +sysinfo command +=============== + +Synopis +------- + +:: + + sysinfo id + sysinfo model + sysinfo revision + +Description +----------- + +The `sysinfo` command is used to show information about the running system + +The `sysinfo id` command prints or sets an environment variable to the board id +as an hex value. + + varname + an optional environment variable to store the board id into. + +The `sysinfo model` command prints or sets an environment variable to the board +model name as a string value. + + varname + an optional environment variable to store the board model name into. + +The `sysinfo revision` command prints or sets an environment variable to the +board revision in the . format, where MINOR and MINOR are int +values. + + varname + an optional environment variable to store the board revision into. + +Examples +-------- + +:: + + => sysinfo id + 0x0b + => sysinfo model + Renesas Starter Kit Premier board rev 2.1 + => sysinfo revision varname + => env print varname + 2.1 + +Return value +------------ + +The return value $? is set to 0 (true) if the command succededd. If an +error occurs, the return value $? is set to 1 (false). -- 2.41.0