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 D6FFFEB64D7 for ; Wed, 28 Jun 2023 19:33:07 +0000 (UTC) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 2B86886631; Wed, 28 Jun 2023 21:32:50 +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="B80XFpsM"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id DB9878663A; Wed, 28 Jun 2023 21:32:42 +0200 (CEST) Received: from madras.collabora.co.uk (madras.collabora.co.uk [IPv6:2a00:1098:0:82:1000:25:2eeb:e5ab]) (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 2E02686628 for ; Wed, 28 Jun 2023 21:32:40 +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.mtl.collabora.ca (mtl.collabora.ca [66.171.169.34]) (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 083666606FE8; Wed, 28 Jun 2023 20:32:38 +0100 (BST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=collabora.com; s=mail; t=1687980759; bh=S/ybJhWZYeuf/S02QzLSd6u2BXJGv6Vto3G06vLzIoA=; h=From:To:Cc:Subject:Date:From; b=B80XFpsM3u1D/+4RbTOiA1FEmWZOMEF8e9jEY+cMhpG/bL4AzJunEqAXtVQMlYvsV I28OXXlhDcdIHIXfmQtf3hiO39g3UlJMoWUfPtPwty29+7aO6akF27E4PkOBPS/YRt iVKCAKxJ2qJe/qYsfIQdzOQTzCJ4ZMr+ByzaOc2KMLRX6MOyDixDMRJVQZMGQC3zXB 3nWOZMkJNaHr7OYJN3RAcMEGsqZBDtK9zsDpzwHMXe2MnZbaChVtquL7b7egZSTeNK 5ZVp0DYg9fhVlgbfbaj4yGct6dMY+X5NS40pGtOsQ+m53fXjzXW1mrt40gbItVTaO/ FmOigdSO7za7Q== From: Detlev Casanova To: u-boot@lists.denx.de Cc: Marek Vasut , Hai Pham , Tam Nguyen , Detlev Casanova Subject: [PATCH v2 0/4] Introduce the sysinfo command Date: Wed, 28 Jun 2023 15:32:35 -0400 Message-Id: <20230628193239.268704-1-detlev.casanova@collabora.com> X-Mailer: git-send-email 2.39.3 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 The command can be used to show various information that can be used to identify the running system. Currently supported subcommands are: * model: A string representing the model * id: The id of the board * revision: The revision of this board. I'm also not sure if a test should be added and where to start to test this kind of command. Changes since v1: - Removed shell function to select linux device tree. This will be distributions job. - Break revision in rev_major and rev_minor in the sysinfo driver. Detlev Casanova (4): sysinfo: Add IDs for board id and revision cmd: Add a sysinfo command sysinfo: rcar3: Use int instead of char for revision sysinfo: rcar3: Implement BOARD_ID and BOARD_REVISION_* cmd/Kconfig | 6 ++ cmd/Makefile | 1 + cmd/sysinfo.c | 134 ++++++++++++++++++++++++++++++++++++++ drivers/sysinfo/rcar3.c | 141 ++++++++++++++++++++++++++++------------ include/sysinfo.h | 5 ++ 5 files changed, 245 insertions(+), 42 deletions(-) create mode 100644 cmd/sysinfo.c -- 2.39.3