From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 772A3C433EF for ; Sat, 21 May 2022 10:26:03 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:Content-Type: List-Subscribe:List-Help:List-Post:List-Archive:List-Unsubscribe:List-Id: In-Reply-To:MIME-Version:References:Message-ID:Subject:Cc:To:From:Date: Reply-To:Content-Transfer-Encoding:Content-ID:Content-Description:Resent-Date :Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=OvOJ1eCyLVjmCbtgrpLY0ZbWOL0DHS9VMSIB/Vn8pgE=; b=M8Ki7d0kLTzysy5JawSKfQkdUO rJoN6c7E84TsTIsus6Yv0CumPV1hEWt0TCiutLUHCv5gVlrqBkFzeLk3GF+LzGvlkGP97fPNu0sdr p+8+3MVaEmU8+voFtlAjxrRArsxmf2DKQQKgwPjfZMoHBEymYYn3FoCdJ2kpASIXxNhsCbLtfCWgr 2EzUNvZj+CSvKmKCLlPTuA0TtDaYF+APbnMlG2NKIVy008eneLYZooBiG/sgqlRH3Cppz/4B+VFX+ P/O/dC/qd1FWvb+S+ZzkKPkZxmV+NgfXLTpM04/aALnArZO2XUKgt3sb3IiZFrXTLK3IoTHdskuc7 16d/41Iw==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.94.2 #2 (Red Hat Linux)) id 1nsMHa-00GAfo-Ei; Sat, 21 May 2022 10:24:26 +0000 Received: from ams.source.kernel.org ([2604:1380:4601:e00::1]) by bombadil.infradead.org with esmtps (Exim 4.94.2 #2 (Red Hat Linux)) id 1nsMHX-00GAev-FK for linux-arm-kernel@lists.infradead.org; Sat, 21 May 2022 10:24:25 +0000 Received: from smtp.kernel.org (relay.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by ams.source.kernel.org (Postfix) with ESMTPS id A9871B81B24; Sat, 21 May 2022 10:24:21 +0000 (UTC) Received: by smtp.kernel.org (Postfix) with ESMTPSA id 937A4C385A9; Sat, 21 May 2022 10:24:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1653128660; bh=aQ66ppQ61E71sBFPrUxFfvV2qUpYZYEcuTJAKUG3/QU=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=AY+09pKT65P2pPSdS3VAfGddTMbpF/wFn9/KqlXrneEKNqbFZRY44lI5pUmqmleY5 UYgKcKRWWgorhTduIw0Ol3Tey50HhqiJUm9HL71TkFgMORRbjwgjDd2d1JJobHGl5w 9nXOzj4KWnDEKldhqtBBgF6X+fFaZ2PruRuwkRoH1gg6AgNv//w1f2Iay8ftg8TLdc gsijrQdMiZnoM34Y+I80MSYd3FiXQE/8ht7+heIARr1wOJXMt27EUmQh17ayCCRF7B zUWZAeZS7JXjSSpIQw4/z18rP0tEpFcDEVBbseWiC5Am0eV645QLdRSFoWRPP/LLrr 5h9/fj/k+w0gA== Date: Sat, 21 May 2022 12:24:16 +0200 From: Wolfram Sang To: Alexander Stein Cc: Alifer Moraes , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, eran.m@variscite.com, festevam@gmail.com, kernel@pengutronix.de, linux-imx@nxp.com, linux-i2c@vger.kernel.org, linux@rempel-privat.de, pierluigi.p@variscite.com, s.hauer@pengutronix.de, shawnguo@kernel.org, gaopan , Fugang Duan , Vipul Kumar Subject: Re: (EXT) [PATCH] i2c: imx: add irqf_no_suspend Message-ID: Mail-Followup-To: Wolfram Sang , Alexander Stein , Alifer Moraes , linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, eran.m@variscite.com, festevam@gmail.com, kernel@pengutronix.de, linux-imx@nxp.com, linux-i2c@vger.kernel.org, linux@rempel-privat.de, pierluigi.p@variscite.com, s.hauer@pengutronix.de, shawnguo@kernel.org, gaopan , Fugang Duan , Vipul Kumar References: <20220307143630.28697-1-alifer.m@variscite.com> <3676803.kQq0lBPeGt@steina-w> MIME-Version: 1.0 In-Reply-To: <3676803.kQq0lBPeGt@steina-w> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20220521_032423_847806_9206ACC4 X-CRM114-Status: GOOD ( 18.10 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: multipart/mixed; boundary="===============5487021705048313637==" Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org --===============5487021705048313637== Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="bW5lVs4zqF9WjfiD" Content-Disposition: inline --bW5lVs4zqF9WjfiD Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable Hi everyone, > > The i2c irq is masked when pcie starts a i2c transfer process > > during noirq suspend stage. As a result, i2c transfer fails. > > To solve the problem, IRQF_NO_SUSPEND is added to i2c bus. > >=20 > > Signed-off-by: Gao Pan > > Signed-off-by: Fugang Duan > > Signed-off-by: Vipul Kumar The SoB from Alifer Moraes is missing, too. > > goto rpm_disable; > >=20 > > /* Request IRQ */ > > - ret =3D request_threaded_irq(irq, i2c_imx_isr, NULL, IRQF_SHARED, > > + ret =3D request_threaded_irq(irq, i2c_imx_isr, NULL, > > + IRQF_SHARED | IRQF_NO_SUSPEND, > > pdev->name, i2c_imx); > > if (ret) { > > dev_err(&pdev->dev, "can't claim irq %d\n", irq); >=20 >=20 > I stumbled across Documentation/power/suspend-and-interrupts.rst which st= ates: > > For this reason, using IRQF_NO_SUSPEND and IRQF_SHARED at the > > same time should be avoided. > Given this IMHO at least a comment should be inserted why this is fine. I= dont=20 > have a full picture about the situation, but to me it seems there is a=20 > reference missing, or why/how does some PCIe start some I2C transfer when= the > controller is suspended already? Do I miss something? Thank you for this comment, Alexander. I second you, this needs explanation. Happy hacking, Wolfram --bW5lVs4zqF9WjfiD Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEOZGx6rniZ1Gk92RdFA3kzBSgKbYFAmKIvcwACgkQFA3kzBSg KbYBVw//eUEuyxhP5NHyCEWeN7/A9Rbd45Wch8anz2ZxTHwrQ/d5jocPR0ZZjb7H pGhesAIMaw+LH88Bhw49U8TpbjKNRUwB8J9uaREwtI8X7rlmx8iHLqMadis83HPM RZblDYVbe+69+EAKHfKu3WrzMWhGc+tO+hinRPaxCY26h1isuQPaELPBfTyuqiJ5 NHYfDhVV/qZtMYZI8xfEf8UAN/wGYaVL4Zhputw/XL5ZjCAuczavsInFdwzkzRyX JlRb+VXvJAqI5CAz6AYGuaWlMO7hZB81fpGm4+5B6UVPQA6jWl9e9s/L7sVZ1Zjs cJYjL3BD3/j0XQArEoMhySZAfs2KNeoXHWnc0zVas1lHHh4HwbEWLFRrK/sv5Wkz KkR1mMiLjlFsmxHwFIh+eWN0KDM8pTWCYEaiiCuYaQfeQH6RTE9Ju1l/+tb03mu7 dPOK6S9Vl+nJ6qYGAS/HDj9nq6GQIX1i3T/bkYvLYE1/lK81AJt/7TuQdV7ulmwF jQHd5hpFjh8Bx25oyaK3kqQeCV6PUVtqdxoNCPffqH9BJwRWPdy275ucpZR9+7p9 ysOhQQ+HDc3kXAVgpWE1AJgj95w/O7WVSpf7D5zwfpjiRyHaNp8qTB1IbcSC6Ty4 frxbSqyQa4wbGBJfcsiuAe8linmZkmoZfCa3+Sh0vggMmpBM9Pg= =CxIu -----END PGP SIGNATURE----- --bW5lVs4zqF9WjfiD-- --===============5487021705048313637== Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ linux-arm-kernel mailing list linux-arm-kernel@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-arm-kernel --===============5487021705048313637==--