From patchwork Tue Nov 14 08:52:38 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Benjamin Gaignard X-Patchwork-Id: 118859 Delivered-To: patch@linaro.org Received: by 10.140.22.164 with SMTP id 33csp2784663qgn; Tue, 14 Nov 2017 00:53:44 -0800 (PST) X-Google-Smtp-Source: AGs4zMb9CGbR9Eh2BHqEUa1unArOIKVVwvN9n1qbKvmNnN1MVil9qtTZgKEWcZRAXh2Ify5ktvQq X-Received: by 10.101.81.196 with SMTP id i4mr11280352pgq.54.1510649624342; Tue, 14 Nov 2017 00:53:44 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1510649624; cv=none; d=google.com; s=arc-20160816; b=HHxkVwYMFRejzjEaHcDPIWNLVR7JKVz0sdp/DUCMHBrkEJXkFVnmyWPXeqGxhWMGNa B+SyLiZniZ6T1cONnnw8cnfi/3Xx0XhSIvd+OosyHk3nWVojYeHJ2ShaPO9eZVAcaz42 /Rff7BrFJ4EyQxQBlv8Y8vVg/kLcTYChtHE6FTO/yla++9FGb7Zc9+bj/tmkJ7OZSjW4 dJOftSrxtctINiNO9rUVlZtRiJb5VhpWoFsUufGKbu6PNtJzanNrUsnAYSSNYIJ1XG/8 O3LKmwcvUYVtXXZ5MufxKE5jrxoKvKRf/tBn0VHV0p1Z8w29c1mi/jo8xq6jv3fqAoki IM8g== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:dkim-signature:arc-authentication-results; bh=cv16l5k2e7xOREILQsEImDgJzjwpvIbT3BdFo0llNt4=; b=PpHMPQcIRpeT0XoQyN2dJCb+WdxCeNpLUnGagPCEiYhdc1RfQdRiArp3S7BC6Rb12f nXPr/BEK2xi0yD/sKJP+I+eeIn6h7sfuuDgDEb+XYAdfVD3tcoKFRxfM+AsuRZlWFJY5 /NKBmJBWJAsJf2nlrFmowmAx33no8Y1axkrLGc4AVIhVxe1sRdocPALyGV0Xa079qtNQ TafKixuaW1ctmevQ0fZCpxwH3nSPIrbNihb5hN09j4HA+5Fk7zz15/6E5sO5U8gyukeZ Q5zBrFLpPkY6Z1sAtn3DOOHh17HJBfLiHPPw0e2AENvpOn2FmVwAFuOwBFlpFtEgQxJa pnOQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=UKeJb7F5; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=fail (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 x8si11130279pgq.460.2017.11.14.00.53.44; Tue, 14 Nov 2017 00:53:44 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=neutral (body hash did not verify) header.i=@linaro.org header.s=google header.b=UKeJb7F5; spf=pass (google.com: best guess record for domain of devicetree-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=devicetree-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753544AbdKNIxh (ORCPT + 6 others); Tue, 14 Nov 2017 03:53:37 -0500 Received: from mail-wr0-f194.google.com ([209.85.128.194]:49977 "EHLO mail-wr0-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753137AbdKNIxU (ORCPT ); Tue, 14 Nov 2017 03:53:20 -0500 Received: by mail-wr0-f194.google.com with SMTP id o88so16759968wrb.6 for ; Tue, 14 Nov 2017 00:53:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=GlBilOK4xrPCZn69luv1A0oG1iUpeKmAhROpfSnoqIA=; b=UKeJb7F53lhIEzK0WisHVYW7a+3xsQbxb/OvveUUQK0tiYvpUeiFfViCWaz2D+CAs+ srbVOjElp94NgmY/wR+LkXTlHnxPWL1ke5EXaP8nNp/1aW4DplW2sIKEV9wH5TF0pAwL Luukaq3MPOXEwyMRXSWeqPyfgmeLt4Fq7UYH0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=GlBilOK4xrPCZn69luv1A0oG1iUpeKmAhROpfSnoqIA=; b=pdei2OGLVaZAo6QckgzIgcOVrQdnS3rco0D0Xdymgu/XZgKaDK7zJ8BK7cPTaWvQAb TLaw4RHFEI+0Sl2E/ujJxG7/k/iqpdgoYxqHprzvM3DSi9NFiN/2Mkw4cIOXXiwhrbwx iazf18NICb68LFE8gsysjKt6OANFeseVkReov/gp+l1RiEL/wt2JMfAk7pVy/64nru1n XMoqMDGic8SbFlzEw6dkvoFOieVx+6g8ivHkVBCFo9TMYmE91DeWn8/i7a7VU8xsOOMF JDIgVAB7qqd14fhYCjHfGoQq6ShlFTURVAgEghqAQ3s2pziCHQ8TsJFo/+7ojYo1cnQ3 XZPw== X-Gm-Message-State: AJaThX6GUNQKfO6ovU180Dg4yBta59T/vL5gD4fg9IQW8e1/HsMHKg5E Z+KSuUGIywrM7BCFE/hH/+vZnw== X-Received: by 10.223.185.33 with SMTP id k30mr9537203wrf.40.1510649599459; Tue, 14 Nov 2017 00:53:19 -0800 (PST) Received: from lmecxl0911.lme.st.com ([80.215.205.30]) by smtp.gmail.com with ESMTPSA id g28sm22894551wra.31.2017.11.14.00.53.16 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Tue, 14 Nov 2017 00:53:18 -0800 (PST) From: Benjamin Gaignard To: robh+dt@kernel.org, mark.rutland@arm.com, linux@armlinux.org.uk, mcoquelin.stm32@gmail.com, alexandre.torgue@st.com, daniel.lezcano@linaro.org, tglx@linutronix.de, ludovic.barre@st.com, julien.thierry@arm.com, sudeep.holla@arm.com, arnd@arndb.de Cc: devicetree@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, Benjamin Gaignard Subject: [PATCH v8 1/6] clocksource: timer_of: rename timer_of_exit to timer_of_cleanup Date: Tue, 14 Nov 2017 09:52:38 +0100 Message-Id: <1510649563-22975-2-git-send-email-benjamin.gaignard@linaro.org> X-Mailer: git-send-email 2.7.4 In-Reply-To: <1510649563-22975-1-git-send-email-benjamin.gaignard@linaro.org> References: <1510649563-22975-1-git-send-email-benjamin.gaignard@linaro.org> Sender: devicetree-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org Change function name to something more explicit since it is only used in init error cases. Add __init annotation and description about the function usage. Signed-off-by: Benjamin Gaignard --- drivers/clocksource/timer-of.c | 9 ++++++++- drivers/clocksource/timer-of.h | 2 +- 2 files changed, 9 insertions(+), 2 deletions(-) -- 2.7.4 -- To unsubscribe from this list: send the line "unsubscribe devicetree" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html diff --git a/drivers/clocksource/timer-of.c b/drivers/clocksource/timer-of.c index 7c64a5c1..a319904 100644 --- a/drivers/clocksource/timer-of.c +++ b/drivers/clocksource/timer-of.c @@ -177,7 +177,14 @@ int __init timer_of_init(struct device_node *np, struct timer_of *to) return ret; } -void timer_of_exit(struct timer_of *to) +/** + * timer_of_cleanup - release timer_of ressources + * @to: timer_of structure + * + * Release the ressources that has been used in timer_of_init(). + * This function should be called in init error cases + */ +void __init timer_of_cleanup(struct timer_of *to) { if (to->flags & TIMER_OF_IRQ) timer_irq_exit(&to->of_irq); diff --git a/drivers/clocksource/timer-of.h b/drivers/clocksource/timer-of.h index 44f57e0..f521477 100644 --- a/drivers/clocksource/timer-of.h +++ b/drivers/clocksource/timer-of.h @@ -67,6 +67,6 @@ static inline unsigned long timer_of_period(struct timer_of *to) extern int __init timer_of_init(struct device_node *np, struct timer_of *to); -extern void timer_of_exit(struct timer_of *to); +extern void __init timer_of_cleanup(struct timer_of *to); #endif