Received: by 2002:a25:c205:0:0:0:0:0 with SMTP id s5csp1156231ybf; Fri, 28 Feb 2020 15:34:01 -0800 (PST) X-Google-Smtp-Source: APXvYqxwFIiv9NvoZ0qMveVK+EnKUIBt6bcNgHMN1bLdLHckzvjzHWq4SaXXq1Yrva4WvZYzdTUI X-Received: by 2002:aca:1215:: with SMTP id 21mr4874072ois.5.1582932840927; Fri, 28 Feb 2020 15:34:00 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1582932840; cv=none; d=google.com; s=arc-20160816; b=NhQO5IAjfFrAuZkxs9Zin2U64idnW8+5CzM4Q87OuHCfhDbeRN+lYM8gtkv7Ddifxu ugYi5pe2YvdzAh5zC+LTUxrXtl4wMdsxiCisohu68mfmjCxGotgc3nu698rrC6JknRYj PnjeQokc2oyvqK/qM9ARtgAW62WA5S1AVoW8pSsOUVatBqJEJjDgdHgTt9cJ2c5/tHOl 4YnoibK1O8JdzA/11RYeIJ+46SxJg7Evlz1cgOy3bk75M8fA78wmuI4KpUlxUjyXu+H7 KwJjbqHhdejarW7O6b0ubLK8jA8DUpCCqy0CQX0nOOR695Ctf2hpJ4sxbjAmoXNvQtPQ gvLg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:dkim-signature; bh=hkOrGQTUil2jVBBDqFqKrlwpeqHUXILYxK5e31tvxS0=; b=kwwUJzFc+Ib07BP41AolrQOyImX+8Tus9GXuRSXWxdnIeAgglS858tYg/AxlLMvn3T 4iCUgbkxoSx889QoSt06W64sc1z1zaQGRBnMLqDcaShpTuYxAuVj6yzv82msnlcSZUWp 435qe7BYboxSQf1d0LFqBsHysZ0c5UqpYNbo/VPkiDp47uyi59JKeiFuUbkhF0sclsK5 0f077oGCcUcBfmPJkAOyjiZsCCQG0YimNblq/EPmVXHqMT2Lct1Fjb5fZa2JiZAS+J+O JFXGwZGJQCfChrr69LF3lmfQBqZ9lKRvODr5CBrDYbjexb33FUlP2VlGjR+njmggioD/ xrPA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=jgpmxZ9f; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id m17si2643364otk.109.2020.02.28.15.33.45; Fri, 28 Feb 2020 15:34:00 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@linaro.org header.s=google header.b=jgpmxZ9f; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726561AbgB1Xdm (ORCPT + 99 others); Fri, 28 Feb 2020 18:33:42 -0500 Received: from mail-lj1-f195.google.com ([209.85.208.195]:36504 "EHLO mail-lj1-f195.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726046AbgB1Xdm (ORCPT ); Fri, 28 Feb 2020 18:33:42 -0500 Received: by mail-lj1-f195.google.com with SMTP id r19so5215312ljg.3 for ; Fri, 28 Feb 2020 15:33:40 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=hkOrGQTUil2jVBBDqFqKrlwpeqHUXILYxK5e31tvxS0=; b=jgpmxZ9fGsCQjwNW/xYZU8NzhYJJRQsRKUYM60FMiBWYpPSsA7yiWqy2cNQkzN6eMn 1dvuYUIwF+XcZvWePefIMwMv/yGaE/mALxU/IQ5K74qLNwittf9Rx8wYiHQA8BYMvz3P xeebvZyWyYsSE6tTbgxclyjnPm92OscKGM6g8pLz8T1eXbaHkxG2RR+x0Sjb6FrZXKe4 gJ3/p62lkJV/+eUgMnbkrxPoKaKzyrrBSx55VoFnx9K/tywC/s1NU6eAtdGg3PIY5d8k s7or8Wbym9H0j3o8BbmZURm+e9xD9cNkQFBtD0UTkC4dVqrErAH2fDnaSqWXZ3hvIJ+V s77A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=hkOrGQTUil2jVBBDqFqKrlwpeqHUXILYxK5e31tvxS0=; b=FnvJHDm5tDHqvVEDUdho+rTOYKnzJzMYgJbBI3Ss7t48NYjR+jXoc27jHACft8phLW MLtylpy+7IZ8mt06olAcE21EVXePIKPyeuFxBUMUfj93i9tPtLDdRR9l1IswEMGXSXlt /RhUGVGB8SgyYW4hE1jlWxV37GcBBS88vcuf4Ix+ipvC6NXfkta1OatBDpFG6AnY37No blK4/HVHrzI8vzT4a/rv6WG6ESQCI0PAiTXIRVcmbspd9Q3ZCO4/ejqXFuo6E305q4kC eT/XYkUe54wBzJfsuOYLQEB553qGtTsc8cT/XXG/7PBke+cuNYiMqWnmVU+oDJNu1kEF H1DA== X-Gm-Message-State: ANhLgQ0IswquvVLdw4ExYe4FhGsssOj097o9K3hqtGgfk8xCcW90I/DW MRqrvhT78oh1P79uaInR7Cz5EAjbi/7wyiSF47ODrpJn X-Received: by 2002:a05:651c:2c7:: with SMTP id f7mr4259493ljo.125.1582932820144; Fri, 28 Feb 2020 15:33:40 -0800 (PST) MIME-Version: 1.0 References: <20200228154142.13860-1-ckeepax@opensource.cirrus.com> In-Reply-To: <20200228154142.13860-1-ckeepax@opensource.cirrus.com> From: Linus Walleij Date: Sat, 29 Feb 2020 00:33:29 +0100 Message-ID: Subject: Re: [PATCH] pinctrl: core: Remove extra kref_get which blocks hogs being freed To: Charles Keepax Cc: ext Tony Lindgren , "open list:GPIO SUBSYSTEM" , "linux-kernel@vger.kernel.org" , patches@opensource.cirrus.com Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Fri, Feb 28, 2020 at 4:41 PM Charles Keepax wrote: > kref_init starts with the reference count at 1, which will be balanced > by the pinctrl_put in pinctrl_unregister. The additional kref_get in > pinctrl_claim_hogs will increase this count to 2 and cause the hogs to > not get freed when pinctrl_unregister is called. > > Fixes: 6118714275f0 ("pinctrl: core: Fix pinctrl_register_and_init() with pinctrl_enable()") > Signed-off-by: Charles Keepax Patch applied for fixes. Yours, Linus Walleij