From patchwork Thu Nov 4 01:12:47 2021 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Mathew McBride X-Patchwork-Id: 1550694 Return-Path: X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=pass (2048-bit key; unprotected) header.d=traverse.com.au header.i=@traverse.com.au header.a=rsa-sha256 header.s=fm2 header.b=hWAJNzVK; dkim=pass (2048-bit key; unprotected) header.d=messagingengine.com header.i=@messagingengine.com header.a=rsa-sha256 header.s=fm1 header.b=i50v7fMc; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.denx.de (client-ip=2a01:238:438b:c500:173d:9f52:ddab:ee01; helo=phobos.denx.de; envelope-from=u-boot-bounces@lists.denx.de; receiver=) Received: from phobos.denx.de (phobos.denx.de [IPv6:2a01:238:438b:c500:173d:9f52:ddab:ee01]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (4096 bits)) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4Hl5JT2f2bz9sR4 for ; Thu, 4 Nov 2021 12:14:17 +1100 (AEDT) Received: from h2850616.stratoserver.net (localhost [IPv6:::1]) by phobos.denx.de (Postfix) with ESMTP id 71BE383654; Thu, 4 Nov 2021 02:14:10 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=traverse.com.au 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=traverse.com.au header.i=@traverse.com.au header.b="hWAJNzVK"; dkim=pass (2048-bit key; unprotected) header.d=messagingengine.com header.i=@messagingengine.com header.b="i50v7fMc"; dkim-atps=neutral Received: by phobos.denx.de (Postfix, from userid 109) id 2611F83373; Thu, 4 Nov 2021 02:14:08 +0100 (CET) X-Spam-Checker-Version: SpamAssassin 3.4.2 (2018-09-13) on phobos.denx.de X-Spam-Level: X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,DKIM_VALID_AU,DKIM_VALID_EF,RCVD_IN_MSPIKE_H2,SPF_HELO_PASS, SPF_PASS autolearn=ham autolearn_force=no version=3.4.2 Received: from out5-smtp.messagingengine.com (out5-smtp.messagingengine.com [66.111.4.29]) (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 A476F83373 for ; Thu, 4 Nov 2021 02:14:02 +0100 (CET) Authentication-Results: phobos.denx.de; dmarc=none (p=none dis=none) header.from=traverse.com.au Authentication-Results: phobos.denx.de; spf=pass smtp.mailfrom=matt@traverse.com.au Received: from compute6.internal (compute6.nyi.internal [10.202.2.46]) by mailout.nyi.internal (Postfix) with ESMTP id 4ED8A5C00D0; Wed, 3 Nov 2021 21:14:01 -0400 (EDT) Received: from mailfrontend2 ([10.202.2.163]) by compute6.internal (MEProxy); Wed, 03 Nov 2021 21:14:01 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=traverse.com.au; h=from:to:cc:subject:date:message-id:mime-version :content-transfer-encoding; s=fm2; bh=Chtx6aKDuCkX1hMLLOF1exYU5o sba0TK+7pq3R/GEh0=; b=hWAJNzVKDP7A+Bg7Y6gGnpkUMn79Xqlh5U+jP4qN4P xV7r9s2Ro+YRXGG5efeot7O9dxdb6QI94izkT65PHoNulzyMjXONtIakuzMMe5l/ 4/73/FHr/miyegzNhZtzBPePpJJP/Z5K+NtXZZZZGaTiqMRy4SgdUCaSdvQqeZsI tc6Bb4x6lgYfWmi/YC+ZXYpAC0IDZgPAIC9xuFAHMKz8YCTADtDemHkJU+hjSH09 bbBkwL+VFo7yoxkyx+gaB65kT2mpSrbv9fnWdLtsdE2Dc+9t8YcWwpfg5AWV3hoQ yublNTxO++3butTnGlZ/l6Ldh4ygHiSDAv1gmhHW0Djw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-transfer-encoding:date:from :message-id:mime-version:subject:to:x-me-proxy:x-me-proxy :x-me-sender:x-me-sender:x-sasl-enc; s=fm1; bh=Chtx6aKDuCkX1hMLL OF1exYU5osba0TK+7pq3R/GEh0=; b=i50v7fMce/glW3enfdqd/5ABdkYZYHE4E MSIYp3SypJupPKucHYnXiAaciyDACgFstXvNL3rF1xuOwZK2+PtKmZJtGv1sxuwU ohjJoffVBt2i9uKfQBT7IlCP8J0WY6mCC2d52N6SFo8cqAjw93CdwcoqJx/txwVn amZ+alH7aaShQlen2OWkb4jAzrgDzWPILFgKONqmDy2Ra+YLwkTpbyUaAN8rfybn fmH3VI4hisfZPX/ejWKagHa8Ij4MZaGJav3G0CjJRDAkSlYLJZWt98bbFiFEHGj6 ko6GyXz9ysTYLVL3DqOEDkTaoEkf4/7pat1AGIfA+lIl0jj3w/fWQ== X-ME-Sender: X-ME-Received: X-ME-Proxy-Cause: gggruggvucftvghtrhhoucdtuddrgedvuddrtdefgddvlecutefuodetggdotefrodftvf curfhrohhfihhlvgemucfhrghsthforghilhdpqfgfvfdpuffrtefokffrpgfnqfghnecu uegrihhlohhuthemuceftddtnecusecvtfgvtghiphhivghnthhsucdlqddutddtmdenuc fjughrpefhvffufffkofgggfestdekredtredttdenucfhrhhomhepofgrthhhvgifucfo tgeurhhiuggvuceomhgrthhtsehtrhgrvhgvrhhsvgdrtghomhdrrghuqeenucggtffrrg htthgvrhhnpeduuddugffhfeejjeduvdeuleeftedtheduueevueeludelteeijedvgefh gfdufeenucffohhmrghinhepohiilhgrsghsrdhorhhgnecuvehluhhsthgvrhfuihiivg eptdenucfrrghrrghmpehmrghilhhfrhhomhepmhgrthhtsehtrhgrvhgvrhhsvgdrtgho mhdrrghu X-ME-Proxy: Received: by mail.messagingengine.com (Postfix) with ESMTPA; Wed, 3 Nov 2021 21:13:59 -0400 (EDT) From: Mathew McBride To: u-boot@lists.denx.de, Ilias Apalodimas , Simon Glass Cc: Mathew McBride Subject: [PATCH 0/6] Fix Atmel/Microchip TPMv1.2 issues Date: Thu, 4 Nov 2021 01:12:47 +0000 Message-Id: <20211104011253.4401-1-matt@traverse.com.au> X-Mailer: git-send-email 2.30.1 MIME-Version: 1.0 X-BeenThere: u-boot@lists.denx.de X-Mailman-Version: 2.1.34 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.2 at phobos.denx.de X-Virus-Status: Clean While doing bringup/rebase for the Ten64 I did some troubleshooting for the tpm (v1.2, NOT tpm2) command which did not appear to function, despite the Linux driver and tools (tcsd) working on the same board. Evidently the Atmel TPM driver hasn't kept up with various step changes in the I2C and TPM stacks, and while TPMv1.2 is quite dated to TPMv2 it would be nice to make some use of the hardware that is there. (Admittedly I would love to replace our hardware TPM with an fTPM but that is a project for another day) There are also subcommands in tpm-v1 which also have been missed in changes to the TPMv1 API and are fixed in this patchset. I have checked that this set isn't impacted by Ilias' TPM cleanup series[1] which only touches TPMv2. [1] - http://patchwork.ozlabs.org/project/uboot/cover/20211103150910.69732-1-ilias.apalodimas@linaro.org/ Mathew McBride (6): cmd: tpm-v1: fix compile error in TPMv1 list resources command cmd: tpm-v1: fix load_key_by_sha1 compile errors drivers: tpm: atmel_twi: drop non-DM_I2C compatibility drivers: tpm: atmel_twi: do not use an offset byte drivers: tpm: atmel_twi: implement get_desc operation drivers: tpm: atmel_twi: fix printf specifier compile warning cmd/tpm-v1.c | 17 +++++++++++------ drivers/tpm/tpm_atmel_twi.c | 22 +++++++--------------- lib/tpm-v1.c | 4 ++-- 3 files changed, 20 insertions(+), 23 deletions(-)