Received: by 2002:a05:6a10:f347:0:0:0:0 with SMTP id d7csp4081421pxu; Mon, 30 Nov 2020 17:26:07 -0800 (PST) X-Google-Smtp-Source: ABdhPJy2ZmlVLp+DDiAATqQzW+qZXlTaPyZ1V81K2hM+vZlnQIW6ATXCnCHKiXCFWYGHOSGNb6VN X-Received: by 2002:a05:6402:1803:: with SMTP id g3mr573447edy.360.1606785967621; Mon, 30 Nov 2020 17:26:07 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1606785967; cv=none; d=google.com; s=arc-20160816; b=hj2+K3W9R9e+dXUO7zJ0Em+XHCqiNwQCRgbnds+jrX2z1fKsYhb2pfu1atQIsSCco4 4JhNJWl59u+KJ7IARfLQrBCXUCEA5c1CXCApwfW8rsW6ULYCAJhfYR/VWRucU3XJec3c x94tXu8uVK/HJvzh03N/sryIgvtrw2BFRlAjMIRRv0+1i8nzofb/hOA/8wvqGp+m3xXS a5N+eZ5aNP5Lglxl9+8ZBUVcIhyPOqAifApyuiBBqr17MizYVG3JACXK8oYXCRW6OH3F 2jtHaDQu/ym8Iisuh7CxW56Afj3ntf3elnvWpE4K8xsHS7o7QHtXZj0BEek2EwaX/Txp 9tNg== 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 :mime-version:user-agent:date:message-id:from:references:cc:to :subject; bh=UbeqhuXJFxfVMR6xGWnYz4cSEHXItnKK4HVLciJv+rA=; b=o9FCQ7+cBr55BmKnwkKEEV2n6EBbylj8Hi1i5yhozQHvbdphA8LVJH6f70poN6llpo Wy5SGe5yimGfkdHkQ9r114fQMljGmvNOT9HjjHkt1wzUQZG/RUDwQQvTCTyCz9B/VSHg yg6YfWgxe8bGDk9tSrH+9o26IZClHW77z5yhhtLu52vQL6W+yK02nPKZNLjmzbtTzWRY tNsd8Z2iXoD1umW7rfMCaFSO5Ov19sZdvqy8XJvy+bg+cdDuE5dKIu+xnWkc+Ajacp5o +6E1uJfXG9bi9poaOzNWbygyTQkZ1EazpbGYBP+6U0yMYw6G4EFsJffi2nPWNIh3AkfM KLzQ== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id uz9si10004610ejb.386.2020.11.30.17.25.44; Mon, 30 Nov 2020 17:26:07 -0800 (PST) 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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1730590AbgLABXq (ORCPT + 99 others); Mon, 30 Nov 2020 20:23:46 -0500 Received: from szxga07-in.huawei.com ([45.249.212.35]:8890 "EHLO szxga07-in.huawei.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729106AbgLABXq (ORCPT ); Mon, 30 Nov 2020 20:23:46 -0500 Received: from DGGEMS403-HUB.china.huawei.com (unknown [172.30.72.59]) by szxga07-in.huawei.com (SkyGuard) with ESMTP id 4ClPV70wFkz768H; Tue, 1 Dec 2020 09:22:39 +0800 (CST) Received: from [10.174.177.149] (10.174.177.149) by DGGEMS403-HUB.china.huawei.com (10.3.19.203) with Microsoft SMTP Server id 14.3.487.0; Tue, 1 Dec 2020 09:23:00 +0800 Subject: Re: [PATCH] gpio: zynq: fix reference leak in zynq_gpio functions To: Bartosz Golaszewski CC: Linus Walleij , Michal Simek , linux-gpio , arm-soc , LKML References: <20201127094445.121232-1-miaoqinglang@huawei.com> From: Qinglang Miao Message-ID: Date: Tue, 1 Dec 2020 09:23:00 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:68.0) Gecko/20100101 Thunderbird/68.7.0 MIME-Version: 1.0 In-Reply-To: Content-Type: text/plain; charset="utf-8"; format=flowed Content-Transfer-Encoding: 8bit X-Originating-IP: [10.174.177.149] X-CFilter-Loop: Reflected Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 在 2020/12/1 0:44, Bartosz Golaszewski 写道: > On Fri, Nov 27, 2020 at 10:40 AM Qinglang Miao wrote: >> >> pm_runtime_get_sync will increment pm usage counter even it >> failed. Forgetting to putting operation will result in a >> reference leak here. >> >> A new function pm_runtime_resume_and_get is introduced in >> [0] to keep usage counter balanced. So We fix the reference >> leak by replacing it with new funtion. >> >> [0] dd8088d5a896 ("PM: runtime: Add pm_runtime_resume_and_get to deal with usage counter") > > Is this upstream yet? > > Bartosz > . Yep, it's introduced in v5.10-rc5 >