Received: by 2002:a05:7412:bbc7:b0:fc:a2b0:25d7 with SMTP id kh7csp492937rdb; Thu, 1 Feb 2024 15:03:50 -0800 (PST) X-Google-Smtp-Source: AGHT+IHQgDLjNs5yGM+mX1IO9LhgibQqHNHw8vHVTuLqFy8RZmVeA4vq7oUaTKj6QO1vNjeSUnfl X-Received: by 2002:a05:620a:2451:b0:783:e3cf:5e5b with SMTP id h17-20020a05620a245100b00783e3cf5e5bmr4848437qkn.74.1706828630636; Thu, 01 Feb 2024 15:03:50 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1706828630; cv=pass; d=google.com; s=arc-20160816; b=md8KKTeeqntm2cjIV8ZhygyE0H2pGBwUf6KkBHJ9co9jigjMmvCovxSA0elKT4sE33 LVWcsiPUHg6v3yMD/NvQNgi4fEIBYbFmoXaNuqIjaDcxnHmiwQPdGNcFYikpt5jrNvkM 8rnrQW2EtbpXWb4jsSwPNdJFmpXojrzI6xbCtABcBsLAjwbd+sQY+VxI0nkYAjcct/gp Jrnxojh0KMjjd099W2n+yBT5vK2nHhWMoZmsSSoHKkNt+2U7umOOc6PIydZaUSv72Vj2 9M9Eru0p4G92I3FO2NgLvvf+nOyY8IPmcGTQ0ycKZOx8OCSGQrlgB/2NgPEANXhhZP1h 2s0w== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:references:to:from:subject:cc:message-id:date :content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:dkim-signature; bh=2pJJOOuMdW6bYre9HzebIS2CmUbpa1Q6NXeiWA6O69Y=; fh=5het+mqVGYwOi4xoqpwtnBEV1NnJosr26FqkJOdzTts=; b=cMnKVp9QnfVoOHQVnyorH5uzHqyk+A2PlBVFR5RnF3BpzwUVXlEcnDHPuLtV2dcf+7 gFA7nCJlekh3/dK8JucP/Y2RVoEdZdPUekJEPw0oMARxzndoGdwrQYNH7W9dqluTYMwG 3/Yqfpq05jr1SbfsAU92VZ0Gs9E80Yxam00h7ZaSlPU2vWAooYSFHPZb9BnfNpepLBNe 47wuWnpaBpbz7CGmCaxG55m62ezXGgv61+VQQMKdxFDwGuBRrHcjVCArzt546oaT6LGa 2zCmRwU54oR8LMgSDmqosJgY7SZS4hu66SRq4u/HhHhb3CBIheEv3zHO+RmSlC/KtRY2 cQXg==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=nO2rXlrF; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-48974-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-48974-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org X-Forwarded-Encrypted: i=1; AJvYcCVpei6Bnuues19UVnB+ACEdmn5ue7Z9xrqO5EJ0JaO7v4aWx7mZ6tdWU2OD7gexMzVorIbrdIe/hyCHCduEzuxQM2dfnzpqr3NVvm64Sg== Return-Path: Received: from ny.mirrors.kernel.org (ny.mirrors.kernel.org. [147.75.199.223]) by mx.google.com with ESMTPS id bp42-20020a05620a45aa00b0078400fab7c3si748584qkb.71.2024.02.01.15.03.50 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Thu, 01 Feb 2024 15:03:50 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-48974-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) client-ip=147.75.199.223; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=nO2rXlrF; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-kernel+bounces-48974-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.199.223 as permitted sender) smtp.mailfrom="linux-kernel+bounces-48974-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ny.mirrors.kernel.org (Postfix) with ESMTPS id 5738C1C2349E for ; Thu, 1 Feb 2024 23:03:50 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id ECCAB47A7B; Thu, 1 Feb 2024 23:03:41 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="nO2rXlrF" Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 19E413D960; Thu, 1 Feb 2024 23:03:40 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706828621; cv=none; b=t3D6rKezXZ7WiEweqmGPVhbtlk8sFZkceYcigaIDa1HsyBo7BhmKC87dS74tLkiiQNd0PhfwgxbXrpb6hTM9+PKsI4bjKBgRJ/rhKviHd7M/2II5wIj1Ei0WoyYhEBnZ/Cvn2DzIfxUtKDW0dRDA6gpE72qnoEdKbz17v7TZGeg= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1706828621; c=relaxed/simple; bh=LNTO+c64KChLGhrxel1IzuAD7R4UluaRK677Eqkl+KA=; h=Mime-Version:Content-Type:Date:Message-Id:Cc:Subject:From:To: References:In-Reply-To; b=G7YlG/vkoPc47GropVw8WRpwMwqMUgo0ugOuPrkujTqaPsVOyxydyDWyk6V/BFrxlID1Jbv2k9gIFuP8LZ5XD2HSXRGV2koBeyXKFivzVnPy/jwI1C1+COpBx08IdW1V924nZYtMJuLHWw+LL/TApvze1FK+KCXFAZZXRZgv0xs= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=nO2rXlrF; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id BCA41C433C7; Thu, 1 Feb 2024 23:03:38 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1706828620; bh=LNTO+c64KChLGhrxel1IzuAD7R4UluaRK677Eqkl+KA=; h=Date:Cc:Subject:From:To:References:In-Reply-To:From; b=nO2rXlrF/E80L5xMAbP2msyJqY2RziYyjjxpeXrNH/Ne3p3ncg6RLw52N9ljGOI4z PHw+gD28jS5IyNHJxcnma7mto+7nz4gXedC5lky2cH4RSHEuzgjCJxOmUbHywYWGQy I5kncSgbFH2caZ/ShtsVbkwxcIhhtjLpvoGwIV3k6nIq4XOZcKAjZ8D5pbpIfPgDPm x6HuC0cpH+YM393LIiFCwOoFy2ZNkSLggMFfMTqwVcVHs4mj7odFaMSKStnhzhe9wk 6KFnRmTH9GGmbJleqdW+61GHna7Lk/b/bjB+cZoP6+tuSlCFQmE/HWp2OWZD8fdRSj L5BKDlulAHvmA== Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: Mime-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=UTF-8 Date: Fri, 02 Feb 2024 01:03:36 +0200 Message-Id: Cc: , , , , , , Subject: Re: [PATCH] tpm,tpm_tis: Avoid warning splat at shutdown From: "Jarkko Sakkinen" To: "Lino Sanfilippo" , X-Mailer: aerc 0.15.2 References: <20240201113646.31734-1-l.sanfilippo@kunbus.com> In-Reply-To: <20240201113646.31734-1-l.sanfilippo@kunbus.com> On Thu Feb 1, 2024 at 1:36 PM EET, Lino Sanfilippo wrote: > If interrupts are not activated the work struct 'free_irq_work' is not > initialized. This results in a warning splat at module shutdown. > > Fix this by always initializing the work regardless of whether interrupts > are activated or not. > > cc: stable@vger.kernel.org > Fixes: 481c2d14627d ("tpm,tpm_tis: Disable interrupts after 1000 unhandle= d IRQs") > Reported-by: Jarkko Sakkinen > Closes: https://lore.kernel.org/all/CX32RFOMJUQ0.3R4YCL9MDCB96@kernel.org= / > Signed-off-by: Lino Sanfilippo > --- > drivers/char/tpm/tpm_tis_core.c | 3 +-- > 1 file changed, 1 insertion(+), 2 deletions(-) > > diff --git a/drivers/char/tpm/tpm_tis_core.c b/drivers/char/tpm/tpm_tis_c= ore.c > index 1b350412d8a6..64c875657687 100644 > --- a/drivers/char/tpm/tpm_tis_core.c > +++ b/drivers/char/tpm/tpm_tis_core.c > @@ -919,8 +919,6 @@ static int tpm_tis_probe_irq_single(struct tpm_chip *= chip, u32 intmask, > int rc; > u32 int_status; > =20 > - INIT_WORK(&priv->free_irq_work, tpm_tis_free_irq_func); > - > rc =3D devm_request_threaded_irq(chip->dev.parent, irq, NULL, > tis_int_handler, IRQF_ONESHOT | flags, > dev_name(&chip->dev), chip); > @@ -1132,6 +1130,7 @@ int tpm_tis_core_init(struct device *dev, struct tp= m_tis_data *priv, int irq, > priv->phy_ops =3D phy_ops; > priv->locality_count =3D 0; > mutex_init(&priv->locality_count_mutex); > + INIT_WORK(&priv->free_irq_work, tpm_tis_free_irq_func); > =20 > dev_set_drvdata(&chip->dev, priv); > =20 > > base-commit: 41bccc98fb7931d63d03f326a746ac4d429c1dd3 Thank you had forgotten about this. Reviewed-by: Jarkko Sakkinen BR, Jarkko