From patchwork Tue Mar 10 10:11:46 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Marc Gonzalez X-Patchwork-Id: 11429069 Return-Path: Received: from mail.kernel.org (pdx-korg-mail-1.web.codeaurora.org [172.30.200.123]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id 80D4E1800 for ; Tue, 10 Mar 2020 10:20:08 +0000 (UTC) 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 mail.kernel.org (Postfix) with ESMTPS id 5C7D220727 for ; Tue, 10 Mar 2020 10:20:08 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="qW8pAY7R" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org 5C7D220727 Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=free.fr Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org 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:MIME-Version:Date:Message-ID:To:Subject :From:Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From: Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References: List-Owner; bh=uULS2y9Pk5D85mLPS87+CTq52eul9DA7vxoDK4nrAME=; b=qW8pAY7RDm3Bgw +4x6h3szMvLwg49CLcVQLnDMZadtkug25oD4nE36qDQQS0wq7ZB1bry1+VGnv9QarAyhxHAkkt013 hGFhVDZ8JSVk0bq+DJkBzw29/mO5X4WrnUtS3gTbumFNLdOkWv+zN45LIbRIPsSfJOUDQWE15kdWe BDI1WA4CkDCj+EJj8BrrmaUoOBgHOVdXN8Tqi4OtQt+iO94G+U5jgrvYrcMue/Wh/BFr0E2Awq9M3 8f5PEJASvezF4zmPuDEIhBDFYp1SB8cwW/ZHvqvcWNcsDdeZdnU/TFm49Afes1NOlc6Xew/NW3JcS 4+A970Nbj2bKbNDk6oPw==; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1jBbzS-0007cd-Qc; Tue, 10 Mar 2020 10:19:58 +0000 Received: from ns.iliad.fr ([212.27.33.1]) by bombadil.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1jBbz9-0007Om-Vf for linux-arm-kernel@lists.infradead.org; Tue, 10 Mar 2020 10:19:41 +0000 Received: from ns.iliad.fr (localhost [127.0.0.1]) by ns.iliad.fr (Postfix) with ESMTP id 069311FFC2; Tue, 10 Mar 2020 11:19:33 +0100 (CET) Received: from [192.168.108.51] (freebox.vlq16.iliad.fr [213.36.7.13]) by ns.iliad.fr (Postfix) with ESMTP id E68701FF7A; Tue, 10 Mar 2020 11:19:32 +0100 (CET) From: Marc Gonzalez Subject: [PATCH v5 0/2] Small devm helper for devm implementations To: Stephen Boyd , Michael Turquette , Kuninori Morimoto , Russell King , Sudip Mukherjee , Dmitry Torokhov , Guenter Roeck , Bjorn Andersson , Robin Murphy , Geert Uytterhoeven , Arnd Bergmann , Ard Biesheuvel , Greg Kroah-Hartman , Rafael Wysocki , Suzuki Poulose , Mark Rutland Message-ID: Date: Tue, 10 Mar 2020 11:11:46 +0100 User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:68.0) Gecko/20100101 Thunderbird/68.4.1 MIME-Version: 1.0 Content-Language: en-US X-Virus-Scanned: ClamAV using ClamSMTP ; ns.iliad.fr ; Tue Mar 10 11:19:33 2020 +0100 (CET) X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20200310_031940_171621_4456997D X-CRM114-Status: UNSURE ( 8.33 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -2.3 (--) X-Spam-Report: SpamAssassin version 3.4.3 on bombadil.infradead.org summary: Content analysis details: (-2.3 points) pts rule name description ---- ---------------------- -------------------------------------------------- -2.3 RCVD_IN_DNSWL_MED RBL: Sender listed at https://www.dnswl.org/, medium trust [212.27.33.1 listed in list.dnswl.org] 0.0 FREEMAIL_FROM Sender email is commonly abused enduser mail provider [marc.w.gonzalez[at]free.fr] 0.0 SPF_NONE SPF: sender does not publish an SPF Record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record 0.0 SPOOFED_FREEMAIL No description available. X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: linux-clk , Linux ARM , LKML Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org Hello, Differences from v4 to v5 x Fix the grammar in devm_add comments [Geert] x Undo an unrelated change in devm_clk_put [Geert] Differences from v3 to v4 x Add a bunch of kerneldoc above devm_add() [Greg KH] x Split patch in two [Greg KH] Differences from v2 to v3 x Make devm_add() return an error-code rather than the raw data pointer (in case devres_alloc ever returns an ERR_PTR) as suggested by Geert x Provide a variadic version devm_vadd() to work with structs as suggested by Geert x Don't use nested ifs in clk_devm* implementations (hopefully simpler code logic to follow) as suggested by Geert Marc Gonzalez (2): devres: Provide new helper for devm functions clk: Use devm_add in managed functions drivers/base/devres.c | 28 ++++++++++++ drivers/clk/clk-devres.c | 97 +++++++++++++++------------------------- include/linux/device.h | 3 ++ 3 files changed, 67 insertions(+), 61 deletions(-)