Received: by 2002:a05:6a10:f3d0:0:0:0:0 with SMTP id a16csp667907pxv; Thu, 24 Jun 2021 17:21:17 -0700 (PDT) X-Google-Smtp-Source: ABdhPJx/9vFEEMV19nagT799CsWp8V8PGL3RElEXhzHVYdWFKisj+y3tvgrG/PPzX6zC2fQ51zT+ X-Received: by 2002:a50:ccd8:: with SMTP id b24mr10854939edj.386.1624580476809; Thu, 24 Jun 2021 17:21:16 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1624580476; cv=none; d=google.com; s=arc-20160816; b=MzYtHWGJEZumC5edCBCZK7+q4Oi0VqUtfaPQH8clA53YgNkSVIV6wE4NNYqTsPzk2F BcgMFZ3BeFzDQ2n/NCihlbju/eI+JW3u4CFp4bHmdQlH0LXg/BiueEUGnr0l8JxzWir+ 6Xh4MeNkbNTLSpVg54q2GBPHDYf3+ZIx/eT5+6mupbVfj53+MJIy2aYfVadhc49WeKdb 0rqoSQ23Rc4E/gsThyye6WYQw0ZTNL9SwzHTrGJ29BuL3MtUL6nd0pCyJ+oOjvJYbE+C KBCYzTNXtjqtITK8XMjYfCPamf2UNBQwj8mAkvVdNE5epdQRrcYFHYyj7BjnfReC0RWT Iz7Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:content-language :in-reply-to:mime-version:user-agent:date:message-id:from:references :cc:to:subject:dkim-signature; bh=swjWUhJ7ti4wOo9q/TLpVinRb1Z0wsQCkXa7GXKM7Pw=; b=ZscrNwmkZQvc8vkRFDeYOi58fO6NxgLihVHvCKi0lwqq6tGwoMtjgFbo1YIINQgN9A 09nxq04vCC8CE9f7vQaIjNaPO5Mk9s+aCwW0vOsN/o06fiykrp0uy6v/+LWxk1ImjQW7 Epg2Kv1bqWv+N1yaSDpz49t7et15K9sWGO2U7AX96ix+s9fD+fFmItfCR1pWRbhzy4+9 wdxzXTd4Irdpoo7D18HTw0gdktS0rbNqPG/AwKBIqrJxhQjhpecW6TyyaahZRkahCQ/x lOIhH01GRtmsi7i+DXyjyBZ2xmxyIccJy4hcL3NF7puoIdbIRPx1iMcvS9auCSeBXicw JskQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmx.net header.s=badeba3b8450 header.b=lJEtIVn2; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=gmx.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id cq14si4450696edb.313.2021.06.24.17.20.53; Thu, 24 Jun 2021 17:21:16 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmx.net header.s=badeba3b8450 header.b=lJEtIVn2; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=gmx.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232915AbhFYAUZ (ORCPT + 99 others); Thu, 24 Jun 2021 20:20:25 -0400 Received: from mout.gmx.net ([212.227.15.18]:50913 "EHLO mout.gmx.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229521AbhFYAUY (ORCPT ); Thu, 24 Jun 2021 20:20:24 -0400 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=gmx.net; s=badeba3b8450; t=1624580280; bh=swjWUhJ7ti4wOo9q/TLpVinRb1Z0wsQCkXa7GXKM7Pw=; h=X-UI-Sender-Class:Subject:To:Cc:References:From:Date:In-Reply-To; b=lJEtIVn2kqP8E9SR2FEf8KnQz+6kcxjydfyBSBl5xwXyp6QQBoLYZ+PILl6DcnHN5 0uTyxsbqc/b3LEyPjeXntZHBygYQ5QxHMXIX0skcJ0SDgbgMKhN5llODFQ/uct+5aw WuHgBBRdbwd9ZOhvmIhJLKTj+6uprrSjrlFv/5wc= X-UI-Sender-Class: 01bb95c1-4bf8-414a-932a-4f6e2808ef9c Received: from [192.168.178.51] ([149.172.234.120]) by mail.gmx.net (mrgmx005 [212.227.17.190]) with ESMTPSA (Nemesis) id 1MeU4s-1lMPqN3yJI-00aTzd; Fri, 25 Jun 2021 02:18:00 +0200 Subject: Re: [PATCH v2] tpm, tpm_tis_spi: Allow to sleep in the interrupt handler To: Jarkko Sakkinen Cc: peterhuewe@gmx.de, jgg@ziepe.ca, linus.walleij@linaro.org, linux-integrity@vger.kernel.org, linux-kernel@vger.kernel.org, stable@vger.kernel.org References: <20210620023444.14684-1-LinoSanfilippo@gmx.de> <20210623133420.gw2lziue5nkvjtps@kernel.org> From: Lino Sanfilippo Message-ID: <5fbe3f44-8c0d-f185-45fd-fcaa7af3657d@gmx.de> Date: Fri, 25 Jun 2021 02:17:59 +0200 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.10.0 MIME-Version: 1.0 In-Reply-To: <20210623133420.gw2lziue5nkvjtps@kernel.org> Content-Type: text/plain; charset=utf-8 Content-Language: en-US Content-Transfer-Encoding: quoted-printable X-Provags-ID: V03:K1:BpmE95Wz/wro0J6PeKv1BJFP5+cb7QlgHSxV6ggbmZlD8k8/pHD Br7wsTabWG4goyqNdHv7ZvKp/NvmJcAYXmO2MyFwPom4FEU0Bk5F7nMolL1XAV+Rfnm+9ZY U/nZuSW+0VZQ2HHwlb6ohwjNImWP/nmY4R5CfrExzGZKPLeJmgBohVXu+WCbjUcgDku9DSd ao0W+BTrtUI+Brz6/2XyQ== X-Spam-Flag: NO X-UI-Out-Filterresults: notjunk:1;V03:K0:3PmWfYZqWHQ=:Eei6EZGPIT8eAOSXRj5g6l M03hkwEZ/08UCZi7364D+HUcqz3E1PakHXJd4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3503kQmjF/0WZaPkI3qRgdcOotx02Us55+yh3A== Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi, On 23.06.21 at 15:34, Jarkko Sakkinen wrote: > On Sun, Jun 20, 2021 at 04:34:44AM +0200, Lino Sanfilippo wrote: >> Interrupt handling at least includes reading and writing the interrupt >> status register within the interrupt routine. For accesses over SPI a m= utex >> is used in the concerning functions. Since this requires a sleepable >> context request a threaded interrupt handler for this case. >> >> Cc: stable@vger.kernel.org >> Fixes: 1a339b658d9d ("tpm_tis_spi: Pass the SPI IRQ down to the driver"= ) >> Signed-off-by: Lino Sanfilippo > > I'll test this after rc1 PR (I have one NUC which uses tpm_tis_spi). > > /Jarkko > Sounds great, thank you! Regards, Lino