Received: by 2002:a05:6a10:17d3:0:0:0:0 with SMTP id hz19csp3529438pxb; Wed, 14 Apr 2021 07:34:31 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwPVbs3xNj09ubhoVgGTWSqeb6roq3gPxDEmql/on1JeO1pCuAXpCfYFpVuGdG5Kvo/VlvX X-Received: by 2002:a17:906:3153:: with SMTP id e19mr6789002eje.351.1618410871552; Wed, 14 Apr 2021 07:34:31 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618410871; cv=none; d=google.com; s=arc-20160816; b=uPM/X+Xyzg1eGEklHVPyKPTzkDRvH5dPxvJYUOhIo9YBPY7nNeWWMkhwJf+bMlbx/p Xe4swyT+sRUVuO0xA4781zg5qOrbN+s13NMFFbm7l08IAjcVBUHfEdI3tUGgS6Kac9Tw 62OzWJebzySou6CadEaRoBQb4pGMx6imFDW25FRMZvN9Lruv0f8iIhs6lp+wAjyoPcuQ xBtwn7q4Z+BTVC4QeFQEpvtF0GAkDB23xSBAHiHRU+lL1tEG82ERHGln1ATq+mJQjYti tvrM8FF+/6f6likhFmpgHFMG0Bko4vRY8drjvlosG6jOqUR5IBNdCaRrUoMPXi9FZNb4 PHfA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:in-reply-to:content-disposition:mime-version :references:message-id:subject:cc:to:from:date:dkim-signature; bh=uTkER4Zk08/j0mkM24n9Jn10pYoXNo05JRrZsTVjASU=; b=xsPJWvU0GdPgTW3yPemAn98bT+aLScyzdn8Jx3UZ831TUAGWS84BcL7aLq6lR4jyjS rQXnzaHXVAU39GTOs6spdoqmspVm55MswSTG7ox6VBwJ40nv1cFW242prkpB9/0RWdet 35ehNI7NmVJr1GHcJeJ3cgpLg82CavZgpwf7vXasp7wYyy0thx1zrH+N8fRZ6XHC7/sB icbl1yHj5cbc/zd/pU4ytdeGavPjUIeLVXQwzQQRQM4JLQyLsxuBUEqbohacFUG/7GLn SjrDZnU5lbFSnP/rN2daiqJs153RlRplRmDMeRyEgKHdrUqMjLL/mj8CkNr59ikQzfMO mQTw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=YjXZBIfz; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id h8si3212160ejc.568.2021.04.14.07.34.07; Wed, 14 Apr 2021 07:34:31 -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=@kernel.org header.s=k20201202 header.b=YjXZBIfz; 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=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1348800AbhDNHv4 (ORCPT + 99 others); Wed, 14 Apr 2021 03:51:56 -0400 Received: from mail.kernel.org ([198.145.29.99]:36870 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1348092AbhDNHvx (ORCPT ); Wed, 14 Apr 2021 03:51:53 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 0C7B1601FE; Wed, 14 Apr 2021 07:51:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1618386692; bh=zojRrA+SEVZVplxBJb0vmN6/7XHw2L494AoVKdAZjdo=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=YjXZBIfzmd7krID9ftFF5zj6n3QXwljc5UVtlmUIp1qczKposRteSwRn1SCkkSB79 xXDGH2kHe1xw88jPPcIKqX/aQL/sEOupEL0rHQV3jBcXXswbsCU+L/kGFhuHeir97M 5A5IjzfNLtrRAh6PR6VqgTW+LxljS986sk1epPKBI8cB1o9VwzIEV+Bt3Nxl0G8T+L LLvqn0bGE46cJtctKu9AZHUWOrZd/7AcXJocdzWCXBOD3EvBVCwglCq2qz9UIMuKw5 omyLVHoSitohTApoN36vTizS4duxBYm5B5NTV9plqWGVBVmzZS+s2txkDtQUxc7JKa jq5jPwKzpLyrg== Date: Wed, 14 Apr 2021 09:51:27 +0200 From: Wolfram Sang To: Qinglang Miao Cc: Michal Simek , Dong Aisheng , Shawn Guo , Sascha Hauer , Pengutronix Kernel Team , Fabio Estevam , NXP Linux Team , Oleksij Rempel , Vignesh R , Aaro Koskinen , Tony Lindgren , Orson Zhai , Baolin Wang , Chunyan Zhang , Pierre-Yves MORDRET , Maxime Coquelin , Alexandre Torgue , linux-arm-kernel@lists.infradead.org, linux-i2c@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH 0/8] i2c: fix reference leak when pm_runtime_get_sync fails Message-ID: <20210414075127.GA2180@ninjato> References: <20201201092924.112461-1-miaoqinglang@huawei.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha512; protocol="application/pgp-signature"; boundary="opJtzjQTFsWo+cga" Content-Disposition: inline In-Reply-To: <20201201092924.112461-1-miaoqinglang@huawei.com> Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org --opJtzjQTFsWo+cga Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Dec 01, 2020 at 05:29:24PM +0800, Qinglang Miao wrote: > pm_runtime_get_sync will increment the PM reference count > even failed. Forgetting to putting operation will result > in a reference leak here.=20 >=20 > Replace it with pm_runtime_resume_and_get to keep usage > counter balanced.=20 >=20 > BTW, pm_runtime_resume_and_get is introduced in v5.10-rc5 as > dd8088d5a896 ("PM: runtime: Add pm_runtime_resume_and_get > to dealwith usage counter") >=20 > Qinglang Miao (8): > i2c: cadence: fix reference leak when pm_runtime_get_sync fails > i2c: img-scb: fix reference leak when pm_runtime_get_sync fails > i2c: imx-lpi2c: fix reference leak when pm_runtime_get_sync fails > i2c: imx: fix reference leak when pm_runtime_get_sync fails > i2c: omap: fix reference leak when pm_runtime_get_sync fails > i2c: sprd: fix reference leak when pm_runtime_get_sync fails > i2c: stm32f7: fix reference leak when pm_runtime_get_sync fails > i2c: xiic: fix reference leak when pm_runtime_get_sync fails I applied this series now to for-next, thanks! --opJtzjQTFsWo+cga Content-Type: application/pgp-signature; name="signature.asc" -----BEGIN PGP SIGNATURE----- iQIzBAABCgAdFiEEOZGx6rniZ1Gk92RdFA3kzBSgKbYFAmB2nvsACgkQFA3kzBSg KbbCtw/+NcMmI6QKvhWoRpGzsqS4JR3ve8xPWFEaYBcBABOFAJ3OtQeYoeFXyFv5 xJVaL0EqvTsppo22meJ8HGSDgp8cnGupdpwZhIWUxEAdwV2XPabWGQM0IOhq5fIo EXDs+bWvDeo0FqHi/fnc3ykUYXeEo2eh2te+rdhrQy8/l9HdzeFJhx7zOvu2bl/y F5sindz+A6+JxmDGrv5ocmCKDV0/ESIQG4QKadxtRrvNM55hkR7HLBo/XC3iwZx/ XSAJwJNwTxCLhIE2YHhSvO0vnMbXD/rcia9nJ+KcNRSDzNRu/KnECzM1r5HZ4k/8 iWKGyC5eZDfeBMDGDtBs3puS5lktt5bdeBJevXHkSch5Vjaa30fojPbAwHo7paHk v5ojLq1mXX38TkeVvofFBjF7XVyiNuiUwxcIFPHiu38AeSQdkAPRLczyRuU+1yNU uZ7fRS7UPZYy3twjnvgiAdSqiZXa3Z30pgD/bULDwZA39fsXiqg47/vh8pVUI9A6 fz/I3LOyn7qwxxGrLxvErdyAJXazGvEF+pouaAF0XKNgB7iokFV3t1YGTV7IZoWd Cg29vCPjjUsFTnaj1HNIjN0KDYD7kDjqzeYRQzzfPStheExujd2I5qtyZVhOKRal +AkE/oTuRAlxrmNH6/N3pgLdayySwS70gZ4mOGSO8bE/xV/bL+Q= =dXOi -----END PGP SIGNATURE----- --opJtzjQTFsWo+cga--