Message ID | ae2234e4b639d2e80c8e5b8f7e25f3d0fe7acfde.1540970653.git.matti.vaittinen@fi.rohmeurope.com (mailing list archive) |
---|---|
State | Superseded, archived |
Headers | show
Return-Path: <linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org> Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 578F114E2 for <patchwork-linux-arm@patchwork.kernel.org>; Wed, 31 Oct 2018 08:32:52 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 40EF42A317 for <patchwork-linux-arm@patchwork.kernel.org>; Wed, 31 Oct 2018 08:32:52 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3430E2A338; Wed, 31 Oct 2018 08:32:52 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.9 required=2.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,MAILING_LIST_MULTI,RCVD_IN_DNSWL_NONE autolearn=ham version=3.3.1 Received: from bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (using TLSv1.2 with cipher AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id D84A02A317 for <patchwork-linux-arm@patchwork.kernel.org>; Wed, 31 Oct 2018 08:32:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20170209; h=Sender: Content-Transfer-Encoding:Content-Type:Cc:List-Subscribe:List-Help:List-Post: List-Archive:List-Unsubscribe:List-Id:In-Reply-To:MIME-Version:References: Message-ID:Subject:To:From:Date:Reply-To:Content-ID:Content-Description: Resent-Date:Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID: List-Owner; bh=lzTTL4ZauqG+LAu44m2PPBVvqGlxJ5Vj5qOLoJCVYdg=; b=bFzstfUVBOJR+8 Ihfrmxd2GwH/CE9+7ejZ6JvEle1xfWJUrU/0fmKYp8YHcrZ0Ze/X85NKDFP+CUJLT1Lu1DGhC6kTe fLnl+m8mJoGrkkBcLhDzxAR4LC2K9Eu7Ke5pNIIZ4zi0sYtdaJXnnOBAUrDEUDt7yz+k0OjWElMUZ EUIpfs2NxrA52KL1iHBRPQFyQDAHePXl8Abpkx+SXPMc0IuXlGrPIOV6XrdPVeCo1IvtmT0Wxqh8F gCmN/DxBBbYAPiVMHa6RZ3CWgzeXqp2A3bP7NjbgLjepMGKjjHfIrJ8CGaqlxgGygpMC+TLDwC9Zl HHRI2NQjZZoidUdQoDrA==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.90_1 #2 (Red Hat Linux)) id 1gHlvm-0007C5-9W; Wed, 31 Oct 2018 08:32:50 +0000 Received: from mail-lj1-f193.google.com ([209.85.208.193]) by bombadil.infradead.org with esmtps (Exim 4.90_1 #2 (Red Hat Linux)) id 1gHlvi-00079w-Gr for linux-arm-kernel@lists.infradead.org; Wed, 31 Oct 2018 08:32:48 +0000 Received: by mail-lj1-f193.google.com with SMTP id z80-v6so7945969ljb.8 for <linux-arm-kernel@lists.infradead.org>; Wed, 31 Oct 2018 01:32:36 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:date:from:to:cc:subject:message-id:references :mime-version:content-disposition:in-reply-to:user-agent; bh=COmn/EezDX/GWsah2t8NJRxiKg5KtxdFjJeZJYU4E4A=; b=savYeh0SkniBD7Us+SatQHEfv8JS+ru301rBAZc49rPgUJ5doDUxIRP7yLSgX3arWb MGWWPcMTgIysuciDC6Y2LfK7p3K0vq9hiYKlFN9EkztiSSYYl4TMHt4OqWUO2sguIONE Ycn8GUwi54pZaEVexZqj7s9RMg0wygxJEMHJdHu/JCva8yqsfp50ZpPaeJ0Z6Aywofkl gpPNXep40qWDEHVd/vceLRfcrODTENZw6dki5prd+xQBRVhh4NhxzeHl/J4UW+5VZXSv koUZlK4Y63EujQKSZ0uUkaNJY7lcVPbeWl0gBIMd8+oy5r8lGW4j80luXhVaIsHe/kdS PtlQ== X-Gm-Message-State: AGRZ1gKo3uQAthAZWMzhjX63fyvGz4dHniAHR+aXqN5epax+hLOBaFWX PXgrvQ1Y2lRkvtq4B/S9/ao= X-Google-Smtp-Source: AJdET5dN5g/dAlTN28IcLopaJGJqDFRn9JUStvqdSb8+QrYQcyIrmuQUnYRVAQPdJ563Hod4iCxVeQ== X-Received: by 2002:a2e:1510:: with SMTP id s16-v6mr1345261ljd.4.1540974754722; Wed, 31 Oct 2018 01:32:34 -0700 (PDT) Received: from localhost.localdomain ([213.255.186.46]) by smtp.gmail.com with ESMTPSA id j13-v6sm3966819ljh.42.2018.10.31.01.32.33 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 31 Oct 2018 01:32:34 -0700 (PDT) Date: Wed, 31 Oct 2018 10:32:21 +0200 From: Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com> To: Jonathan Corbet <corbet@lwn.net>, Michael Turquette <mturquette@baylibre.com>, Stephen Boyd <sboyd@kernel.org>, Chanwoo Choi <cw00.choi@samsung.com>, Krzysztof Kozlowski <krzk@kernel.org>, Bartlomiej Zolnierkiewicz <b.zolnierkie@samsung.com>, Russell King <linux@armlinux.org.uk>, Andy Gross <andy.gross@linaro.org>, David Brown <david.brown@linaro.org>, Kukjin Kim <kgene@kernel.org>, Sylwester Nawrocki <s.nawrocki@samsung.com>, Tomasz Figa <tomasz.figa@gmail.com>, Andrey Smirnov <andrew.smirnov@gmail.com>, Sebastian Reichel <sre@kernel.org>, Guenter Roeck <linux@roeck-us.net>, Rob Herring <robh@kernel.org>, Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com>, Huang Shijie <sjhuang@iluvatar.ai>, Akshu Agrawal <Akshu.Agrawal@amd.com>, "Rafael J. Wysocki" <rafael.j.wysocki@intel.com>, Daniel Kurtz <djkurtz@chromium.org>, mazziesaccount@gmail.com Subject: [PATCH 4/8] clk: clk-st: avoid clkdev lookup leak at remove Message-ID: <ae2234e4b639d2e80c8e5b8f7e25f3d0fe7acfde.1540970653.git.matti.vaittinen@fi.rohmeurope.com> References: <cover.1540970653.git.matti.vaittinen@fi.rohmeurope.com> MIME-Version: 1.0 Content-Disposition: inline In-Reply-To: <cover.1540970653.git.matti.vaittinen@fi.rohmeurope.com> User-Agent: Mutt/1.9.2 (2017-12-15) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20181031_013246_639393_3B283AD7 X-CRM114-Status: GOOD ( 14.50 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.21 Precedence: list List-Id: <linux-arm-kernel.lists.infradead.org> List-Unsubscribe: <http://lists.infradead.org/mailman/options/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=unsubscribe> List-Archive: <http://lists.infradead.org/pipermail/linux-arm-kernel/> List-Post: <mailto:linux-arm-kernel@lists.infradead.org> List-Help: <mailto:linux-arm-kernel-request@lists.infradead.org?subject=help> List-Subscribe: <http://lists.infradead.org/mailman/listinfo/linux-arm-kernel>, <mailto:linux-arm-kernel-request@lists.infradead.org?subject=subscribe> Cc: linux-samsung-soc@vger.kernel.org, linux-doc@vger.kernel.org, linux-arm-msm@vger.kernel.org, matti.vaittinen@fi.rohmeurope.com, linux-kernel@vger.kernel.org, linux-soc@vger.kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 7bit Sender: "linux-arm-kernel" <linux-arm-kernel-bounces@lists.infradead.org> Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org X-Virus-Scanned: ClamAV using ClamSMTP |
Series |
clk: clkdev: managed clk lookup and provider registrations
|
expand
|
diff --git a/drivers/clk/x86/clk-st.c b/drivers/clk/x86/clk-st.c index fb62f3938008..32d8df9bd853 100644 --- a/drivers/clk/x86/clk-st.c +++ b/drivers/clk/x86/clk-st.c @@ -52,7 +52,8 @@ static int st_clk_probe(struct platform_device *pdev) 0, st_data->base + MISCCLKCNTL1, OSCCLKENB, CLK_GATE_SET_TO_DISABLE, NULL); - clk_hw_register_clkdev(hws[ST_CLK_GATE], "oscout1", NULL); + devm_clk_hw_register_clkdev(&pdev->dev, hws[ST_CLK_GATE], "oscout1", + NULL); return 0; }
Use devm based clkdev lookup registration to avoid leaking lookup structures. Signed-off-by: Matti Vaittinen <matti.vaittinen@fi.rohmeurope.com> --- drivers/clk/x86/clk-st.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-)