Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp146382ybl; Wed, 11 Dec 2019 15:31:57 -0800 (PST) X-Google-Smtp-Source: APXvYqx9O2nm+lC8YAqt0iuJV2v8dt4wMzgKkDkU5VQ7gn9f/mxTUjZ918YNs6/7bR7wB4BxCOKm X-Received: by 2002:a9d:760f:: with SMTP id k15mr4593960otl.65.1576107117326; Wed, 11 Dec 2019 15:31:57 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1576107117; cv=none; d=google.com; s=arc-20160816; b=YRJ6JqmEoEos6PndB/vDVtSBjQ2I15v8l3AEG08DRgiaVOZCAPpDGgClnMjp3xNdtx e0sBpjdbpW+qfaKi+xTcVlNGzq0r+ftxIcK4ul0nMBgGZ74L//MqNE0RowVy9FkzPeFe Gat685KJII/wmIhsNDq5NaXIpLsTxt93qp/HvXQqchQJtrXvKKr1MXtFQEElB68+7VdU JCzLAz7vhAbt1dgurgqQqa3PEoqjtwVrISFtGit78bRV+N81fVbx5S4JezSwj56SXjt2 ikW9xYIchwXIIxF60h6tPA3vTVVY8v/0jLk+DbfGZpCgrcZ8ikF9aUFkYmRoUPu4ssma /+RQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=u5EYBeY7DMUFDYGcRwf5OFQhhNuQnK3tgQ7xtLF/bL0=; b=JwqxXKIvj2AV0PwoajXS66tyF0PKkZ5gYnoX4nLvfaVz1ThiqH2LA55x5FxCkiB66A JcdWT6T06tGQRTsvIYiklE0cMbooNoxxoM0tiNt++av+DxmvMQnSt+7HWCsGGYQmbHtB YSCPOylRydsGY4161YCqS/hiuOfgmvAKmpetlP5pMiRmK/hzMSozV2E8slJIyrGOKsef NFwoHb8fIZq9znkmLLXGHiCc1uBd66gPKfsALuQm1W1ZBZoQC9T7CxN+KYjfM8d8+c8H 0sJWesFA0jbonsY8AFoNX3jkyqV5N/hhXTAGVLML/0EvVLhtBiceQhWKS3NHD9ouPeA5 fjYQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=ijN0BBii; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id w4si2118666otl.214.2019.12.11.15.31.45; Wed, 11 Dec 2019 15:31:57 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@intel-com.20150623.gappssmtp.com header.s=20150623 header.b=ijN0BBii; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727127AbfLKXax (ORCPT + 99 others); Wed, 11 Dec 2019 18:30:53 -0500 Received: from mail-oi1-f194.google.com ([209.85.167.194]:44827 "EHLO mail-oi1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726928AbfLKXaw (ORCPT ); Wed, 11 Dec 2019 18:30:52 -0500 Received: by mail-oi1-f194.google.com with SMTP id d62so310109oia.11 for ; Wed, 11 Dec 2019 15:30:52 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=intel-com.20150623.gappssmtp.com; s=20150623; h=mime-version:references:in-reply-to:from:date:message-id:subject:to; bh=u5EYBeY7DMUFDYGcRwf5OFQhhNuQnK3tgQ7xtLF/bL0=; b=ijN0BBiifrHOQUvBafavzPiAtfcjrHqSWNBtq7gCsmBw3lOMLU5xy2mEy+NAB2WCfZ QXMTvO+d2I6Tcn3VJk+x6SfqhAhnBHDF0hbU1WxTxKaOpnL+xUkp+jVe4Bvz+uoiHxH1 auO0DvWjcmNwkom7gtlF7YZKxpBsil4zLgi+1bFXkDujDluhddarjR4cXvvLKBBq5W/j pB6KrFffB7ThG5i27LLkqbIzqGa04oovBm2zbwEOJR1eB4LFjCOD6hpRwf3+laE8R+eb AclMiFO+ekBDEy9Sarhe4JUZurtOoikzqnoJmc15XLfkfVRRvsumrut/YJ3t4O38ubix mmSQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to; bh=u5EYBeY7DMUFDYGcRwf5OFQhhNuQnK3tgQ7xtLF/bL0=; b=PVEKR4KZMNVffeiJ8gJOx5IKlnOjz3Kf5nbUyiyFUrVK7vZwl8ywfBD+v1cb0i1Bem N1FpprUtL1HBGdn96zX1dtXGEXMQ0HsEAO2ADCx/U4ofL3tO32VsVlpPQv0I9HW+oIzU gWKoEOu9VpKHhqyChlEwl95KJM4sjerjG4SVlxWrbA6caK1wGC9MBzmjzzi/+GMYKlnW dfgaDnohfXOEcH3Xz7U06fxyOCMbOct7RPb3Rmx92Whh9pwf3x93UOtrVHsNEYs6NxsB grG8Z4hZYkLy4KHHFC8sYkWHok4dI/XqhGTfIQnGk8V6v2e6hEeKtmRChh8Ml/MK5gXG VcGw== X-Gm-Message-State: APjAAAXfjisFWB58rar00vrJ06V7nM6+Cwabkv/WuANNTNcqQi4fdijO y+s3ym2aw4iiDgTufwUyInD0C7LICTpfeWzjhmIyag== X-Received: by 2002:a05:6808:7da:: with SMTP id f26mr4285646oij.73.1576107051733; Wed, 11 Dec 2019 15:30:51 -0800 (PST) MIME-Version: 1.0 References: <20191211231758.22263-1-jsnitsel@redhat.com> <20191211232612.miaizaxxikhlgvfj@cantor> In-Reply-To: <20191211232612.miaizaxxikhlgvfj@cantor> From: Dan Williams Date: Wed, 11 Dec 2019 15:30:40 -0800 Message-ID: Subject: Re: [PATCH] tpm_tis: reserve chip for duration of tpm_tis_core_init To: Jerry Snitselaar , Linux Kernel Mailing List , Christian Bundy , Dan Williams , Peter Huewe , Jarkko Sakkinen , Jason Gunthorpe , Stefan Berger , stable , linux-integrity@vger.kernel.org Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Dec 11, 2019 at 3:27 PM Jerry Snitselaar wrote: > > On Wed Dec 11 19, Jerry Snitselaar wrote: > >Instead of repeatedly calling tpm_chip_start/tpm_chip_stop when > >issuing commands to the tpm during initialization, just reserve the > >chip after wait_startup, and release it when we are ready to call > >tpm_chip_register. > > > >Cc: Christian Bundy > >Cc: Dan Williams > >Cc: Peter Huewe > >Cc: Jarkko Sakkinen > >Cc: Jason Gunthorpe > >Cc: Stefan Berger > >Cc: stable@vger.kernel.org > >Cc: linux-intergrity@vger.kernel.org > > Typo on the list address, do you want me to resend Jarkko? > > >Fixes: a3fbfae82b4c ("tpm: take TPM chip power gating out of tpm_transmit()") > >Signed-off-by: Jerry Snitselaar > >--- > > I did some initial testing with both a 1.2 device and a 2.0 device here. > Christian, can you verify that this still solves your timeouts problem > you were seeing? Dan, can you try this on the internal system with > the interrupt issues? I will see if I can get the t490s owner to run > it as well. Will do. I assume you'd also want to add 'Fixes: 5b359c7c4372 ("tpm_tis_core: Turn on the TPM before probing IRQ's")' if it works?