Received: by 2002:a05:6358:3188:b0:123:57c1:9b43 with SMTP id q8csp3941946rwd; Tue, 23 May 2023 00:17:42 -0700 (PDT) X-Google-Smtp-Source: ACHHUZ4l/IeeOtuJ+t3pEwWXPgkTjS3A0yilht5kZr2OWsqrLGgBEqWAEkHc4XUjmBtUpcNpEYY2 X-Received: by 2002:a17:902:7785:b0:1ad:f912:c047 with SMTP id o5-20020a170902778500b001adf912c047mr11192592pll.42.1684826262246; Tue, 23 May 2023 00:17:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1684826262; cv=none; d=google.com; s=arc-20160816; b=cVkSSH5ObDIHuc6V4+9qTYGtxT5oMEP2JIGXyrl7nJAAnLMTa8Ht3tOtSqyqi6uN1O cPbaGFqXVBZEUjCcHmtjP6r2cmqUlFiBDcnLhvdMJBxmKO9mnLAhQFMSv22a62bgL5Mb C986vMsQI65cVplqaQAcNeQSnw3WvQlHpKFSD+k0K/tMbDc6qYKBd0XRdw1tvrg8ZUn+ v+OPg7i7QCb3KLulnCazTRcF3FMBtvAto+aZMM8xQmm/HeOocP4Ngc8RB8gal1TRh7wK VQru1nIFr6Y97TW0TQJTi6TrPWSXsCG+TbYbqaEKIbbs9Uu3geRNR7qHE/85qa1agMQJ xaIA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:in-reply-to:references :cc:to:from:content-language:subject:user-agent:mime-version:date :message-id:dkim-signature; bh=WunWLfUM1BDPCf5hUydCa5WtQ1zWOb5ZCVJ4rLQ98Bg=; b=mZnZ/02W26yOXNJuZKxEuwcMt40Emhazz8ysW4l76+FKiOsRin696dpX0PHtPU6prk +aWpzdQwLDbP3o1Pgtjs0NXz36PcIbRXEGTlX+kvGxIUAyseu/W2kzTbiXkQVnOTsZEv UtNqaVKonVj/KID8RaMU/CVNq1POFvRhh7sypBdt5/AtSylupp2rbv8e9W9pI870M2Gk 8MIwm4kejJtFHjbRcFDqiBfxPD3hwV/s93rRLN0SrZo0E/1x3+5glHkzZxfKaiHVGQpK tXy7IuqlxTMzxkJInrNy2JabOKcbAZ81JfM9b6+7Ugcb48BBRkgkfAtDft3f7ijIjZuC 0kqQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b="O5/qU42y"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Return-Path: Received: from out1.vger.email (out1.vger.email. [2620:137:e000::1:20]) by mx.google.com with ESMTP id v7-20020a17090a6b0700b0024bccf6609dsi2865958pjj.114.2023.05.23.00.17.26; Tue, 23 May 2023 00:17:42 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) client-ip=2620:137:e000::1:20; Authentication-Results: mx.google.com; dkim=pass header.i=@intel.com header.s=Intel header.b="O5/qU42y"; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 2620:137:e000::1:20 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=intel.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235034AbjEWHGw (ORCPT + 99 others); Tue, 23 May 2023 03:06:52 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51430 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232450AbjEWHGv (ORCPT ); Tue, 23 May 2023 03:06:51 -0400 Received: from mga14.intel.com (mga14.intel.com [192.55.52.115]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id A96A1118; Tue, 23 May 2023 00:06:32 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=intel.com; i=@intel.com; q=dns/txt; s=Intel; t=1684825592; x=1716361592; h=message-id:date:mime-version:subject:from:to:cc: references:in-reply-to:content-transfer-encoding; bh=fR8HB2n9ezHVRM9B2hodfzVRG1PK2D+2ABIDICohet0=; b=O5/qU42yvHctTfsTe19J5VVx0FZqmd1SL8jFbtqFoekXS6KVcOSQ3oQW LroCBsKAQAPP15OLJ1dVfug62j4EF11oa1yjTwqmPKxxYp5ZaHS26WcUT 7gN3zcchDrZ3coxOJHisx12Dx4HKfDsvth24NgzBP576Gzm62W4I/4BmJ mbP1GPq6e2aPwjZotGQxJ1A1CppLxoMHmIdrQvvJ2T3AEMK63il1jf9JF 3jvxmjnSLV/rX//oP7ejNmHLmLzCDOIQwOXvFMuDBsP0KF7cX2x7NP1hO 5WWCKz6FHG55S2j08YF+NRyLDahzXpWQy2PvQiVDlRHULRZjWfit+aCBU g==; X-IronPort-AV: E=McAfee;i="6600,9927,10718"; a="353181834" X-IronPort-AV: E=Sophos;i="6.00,185,1681196400"; d="scan'208";a="353181834" Received: from orsmga007.jf.intel.com ([10.7.209.58]) by fmsmga103.fm.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 23 May 2023 00:06:32 -0700 X-ExtLoop1: 1 X-IronPort-AV: E=McAfee;i="6600,9927,10718"; a="697946091" X-IronPort-AV: E=Sophos;i="6.00,185,1681196400"; d="scan'208";a="697946091" Received: from nmkenne1-mobl2.ger.corp.intel.com (HELO [10.252.53.154]) ([10.252.53.154]) by orsmga007-auth.jf.intel.com with ESMTP/TLS/ECDHE-RSA-AES256-GCM-SHA384; 23 May 2023 00:06:28 -0700 Message-ID: <058e2e0f-70b4-a506-3ada-2578b99e9163@linux.intel.com> Date: Tue, 23 May 2023 10:07:27 +0300 MIME-Version: 1.0 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:102.0) Gecko/20100101 Firefox/102.0 Thunderbird/102.11.0 Subject: Re: [PATCH 1/2] tpm, tpm_tis: Handle interrupt storm Content-Language: en-US From: =?UTF-8?Q?P=c3=a9ter_Ujfalusi?= To: Lino Sanfilippo , peterhuewe@gmx.de, jarkko@kernel.org, jgg@ziepe.ca Cc: jsnitsel@redhat.com, hdegoede@redhat.com, oe-lkp@lists.linux.dev, lkp@intel.com, peterz@infradead.org, linux@mniewoehner.de, linux-integrity@vger.kernel.org, linux-kernel@vger.kernel.org, l.sanfilippo@kunbus.com, lukas@wunner.de, p.rosenberger@kunbus.com References: <20230522143105.8617-1-LinoSanfilippo@gmx.de> In-Reply-To: Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Status: No, score=-4.4 required=5.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,DKIM_VALID_EF,NICE_REPLY_A,RCVD_IN_DNSWL_MED, SPF_HELO_NONE,SPF_NONE,T_SCC_BODY_TEXT_LINE,URIBL_BLOCKED autolearn=ham autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 23/05/2023 09:48, Péter Ujfalusi wrote: >> static void tpm_tis_gen_interrupt(struct tpm_chip *chip) >> @@ -804,6 +857,15 @@ static void tpm_tis_gen_interrupt(struct tpm_chip *chip) >> chip->flags &= ~TPM_CHIP_FLAG_IRQ; >> } >> >> +static void tpm_tis_free_irq_func(struct work_struct *work) >> +{ >> + struct tpm_tis_data *priv = container_of(work, typeof(*priv), free_irq_work); >> + struct tpm_chip *chip = priv->chip; >> + >> + devm_free_irq(chip->dev.parent, priv->irq, chip); >> + priv->irq = 0; > > Should disable_interrupts() be called instead (with the locality > request/relinquish)? > > Is there a chance of a race or is a race matters? Nevermind this comment, it is good. -- Péter