From patchwork Thu Nov 9 09:15:15 2017 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Tero Kristo X-Patchwork-Id: 118416 Delivered-To: patch@linaro.org Received: by 10.140.22.164 with SMTP id 33csp6345021qgn; Thu, 9 Nov 2017 01:16:01 -0800 (PST) X-Google-Smtp-Source: ABhQp+QsxUmQnQpOdA4XD9wX38q/aLH1+y0m3agnVO3hiKciN9YltOj4YvU7I68V5oroMaDq8fzK X-Received: by 10.98.64.141 with SMTP id f13mr3473940pfd.213.1510218961323; Thu, 09 Nov 2017 01:16:01 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1510218961; cv=none; d=google.com; s=arc-20160816; b=cWRWci8z+3JrwYm5TkvPMIo5lJz3BVhsOFtjnCOufvDfJUjLp5VLoXYEcuXaAbZPpQ gBsDYtnpLjR+ZDc5t7PvWzenlFDcmbt4NIy/Ib1tB0l7K7zRbiFgR/EK6v7WWepifs/6 78FJagtq6wYBYFeARV3qXM8gu6kYAyac5o/fUvEpm9Sjl9xYVxBh0Z2kHgCLCKTFI+u2 2Ptg+zIisgdZ3XgHfxwPIq5IIFTHUaR+0VMRIXZ5rWbhiRnUIXuaf3KeMdFbF7D4yxI8 iOBvtPc3FapPaCR/3wLj7Y1iKXZJZd2+PItdZIU+gRkZGlHinFTour8rRMVKzL3MXFWH ljgA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:dkim-signature :arc-authentication-results; bh=c8iQnOvud4uTD/t7s+SHtTOoqnSFCcUaBOVgbFvvnW4=; b=SxFfn29Y1TIx2om8NLPgpFCDltliYV6aN5BuYXkqY2/+V5FPPmkiMtOd0tlJFoZRJW u5X1/Yb1GQPu9tuqpC2sRoJndFi+Ft8ZgKVoItVXbwrfk78Euarlp6lP/HtVtbLyXcoR 88OE/OrMPEiSdw9SLIqO1my9UW2xpN1+By6F87sDYKeSMmyL8DJoN7WTkX6IokdGLI7W yf8B0Av1T6wFAhcHsDs04hrIUTMOau+IJGamSwjNljg/jgN6uDb67+tEz3+bAd9ZU/Fw 5sjAG4FJsFGImHxH+q6jKVxPUCkrNOL7GEJeXHsUqIGJAkjKf3SqfdZF2GUN4eXqbejl hYwA== ARC-Authentication-Results: i=1; mx.google.com; dkim=neutral (body hash did not verify) header.i=@ti.com header.s=ti-com-17Q1 header.b=EOZjGdgq; spf=pass (google.com: best guess record for domain of linux-omap-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-omap-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s14si5660417pgr.330.2017.11.09.01.16.01; Thu, 09 Nov 2017 01:16:01 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-omap-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=@ti.com header.s=ti-com-17Q1 header.b=EOZjGdgq; spf=pass (google.com: best guess record for domain of linux-omap-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-omap-owner@vger.kernel.org; dmarc=fail (p=QUARANTINE sp=NONE dis=NONE) header.from=ti.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753950AbdKIJPt (ORCPT + 4 others); Thu, 9 Nov 2017 04:15:49 -0500 Received: from lelnx193.ext.ti.com ([198.47.27.77]:64215 "EHLO lelnx193.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753920AbdKIJPo (ORCPT ); Thu, 9 Nov 2017 04:15:44 -0500 Received: from dlelxv90.itg.ti.com ([172.17.2.17]) by lelnx193.ext.ti.com (8.15.1/8.15.1) with ESMTP id vA99FfOQ025102; Thu, 9 Nov 2017 03:15:41 -0600 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=ti.com; s=ti-com-17Q1; t=1510218941; bh=d4MEsy8rMdDiGy4TPw2lXacnLs5c/4wmZTzcZce/u9M=; h=From:To:CC:Subject:Date:In-Reply-To:References; b=EOZjGdgqynqfriD6IYGrZH9FWw6SjWtAGbauZLnfE8eL4vMWNyznhx8FEtby6rsQN UaxOIbty24LHFws839R10sJ11GKDIEqfixL7E1yzHP0YZ2yyMgNx4vo8hsMYq7O8Ds vvckZQ3OJBSivg35izy3j4DbF9XiUvyXuUDAVnA8= Received: from DFLE102.ent.ti.com (dfle102.ent.ti.com [10.64.6.23]) by dlelxv90.itg.ti.com (8.14.3/8.13.8) with ESMTP id vA99Ff6h023947; Thu, 9 Nov 2017 03:15:41 -0600 Received: from DFLE107.ent.ti.com (10.64.6.28) by DFLE102.ent.ti.com (10.64.6.23) with Microsoft SMTP Server (version=TLS1_2, cipher=TLS_ECDHE_RSA_WITH_AES_256_CBC_SHA384_P256) id 15.1.845.34; Thu, 9 Nov 2017 03:15:40 -0600 Received: from dlep33.itg.ti.com (157.170.170.75) by DFLE107.ent.ti.com (10.64.6.28) with Microsoft SMTP Server (version=TLS1_0, cipher=TLS_RSA_WITH_AES_256_CBC_SHA) id 15.1.845.34 via Frontend Transport; Thu, 9 Nov 2017 03:15:40 -0600 Received: from gomoku.home (ileax41-snat.itg.ti.com [10.172.224.153]) by dlep33.itg.ti.com (8.14.3/8.13.8) with ESMTP id vA99FWbr012718; Thu, 9 Nov 2017 03:15:37 -0600 From: Tero Kristo To: , CC: , , Subject: [PATCHv2 05/28] clk: ti: convert retry_init param to use void data type Date: Thu, 9 Nov 2017 11:15:15 +0200 Message-ID: <1510218917-1725-3-git-send-email-t-kristo@ti.com> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1510218917-1725-1-git-send-email-t-kristo@ti.com> References: <1510218917-1725-1-git-send-email-t-kristo@ti.com> MIME-Version: 1.0 X-EXCLAIMER-MD-CONFIG: e1e8a2fd-e40a-4ac6-ac9b-f7e9cc9ee180 Sender: linux-omap-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-omap@vger.kernel.org User data should be void type, as the core framework doesn't need to know what is passed through. Signed-off-by: Tero Kristo --- drivers/clk/ti/apll.c | 3 ++- drivers/clk/ti/clk.c | 12 ++++++------ drivers/clk/ti/clock.h | 4 ++-- drivers/clk/ti/composite.c | 3 ++- drivers/clk/ti/dpll.c | 3 ++- 5 files changed, 14 insertions(+), 11 deletions(-) -- 1.9.1 -- Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki. Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki -- To unsubscribe from this list: send the line "unsubscribe linux-omap" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Acked-by: Stephen Boyd diff --git a/drivers/clk/ti/apll.c b/drivers/clk/ti/apll.c index 83b148f..9498e93 100644 --- a/drivers/clk/ti/apll.c +++ b/drivers/clk/ti/apll.c @@ -133,9 +133,10 @@ static u8 dra7_init_apll_parent(struct clk_hw *hw) .get_parent = &dra7_init_apll_parent, }; -static void __init omap_clk_register_apll(struct clk_hw *hw, +static void __init omap_clk_register_apll(void *user, struct device_node *node) { + struct clk_hw *hw = user; struct clk_hw_omap *clk_hw = to_clk_hw_omap(hw); struct dpll_data *ad = clk_hw->dpll_data; struct clk *clk; diff --git a/drivers/clk/ti/clk.c b/drivers/clk/ti/clk.c index 10a7045..302c9e6 100644 --- a/drivers/clk/ti/clk.c +++ b/drivers/clk/ti/clk.c @@ -178,7 +178,7 @@ void __init ti_dt_clocks_register(struct ti_dt_clk oclks[]) struct clk_init_item { struct device_node *node; - struct clk_hw *hw; + void *user; ti_of_clk_init_cb_t func; struct list_head link; }; @@ -188,14 +188,14 @@ struct clk_init_item { /** * ti_clk_retry_init - retries a failed clock init at later phase * @node: device not for the clock - * @hw: partially initialized clk_hw struct for the clock + * @user: user data pointer * @func: init function to be called for the clock * * Adds a failed clock init to the retry list. The retry list is parsed * once all the other clocks have been initialized. */ -int __init ti_clk_retry_init(struct device_node *node, struct clk_hw *hw, - ti_of_clk_init_cb_t func) +int __init ti_clk_retry_init(struct device_node *node, void *user, + ti_of_clk_init_cb_t func) { struct clk_init_item *retry; @@ -206,7 +206,7 @@ int __init ti_clk_retry_init(struct device_node *node, struct clk_hw *hw, retry->node = node; retry->func = func; - retry->hw = hw; + retry->user = user; list_add(&retry->link, &retry_list); return 0; @@ -328,7 +328,7 @@ void ti_dt_clk_init_retry_clks(void) while (!list_empty(&retry_list) && retries) { list_for_each_entry_safe(retry, tmp, &retry_list, link) { pr_debug("retry-init: %s\n", retry->node->name); - retry->func(retry->hw, retry->node); + retry->func(retry->user, retry->node); list_del(&retry->link); kfree(retry); } diff --git a/drivers/clk/ti/clock.h b/drivers/clk/ti/clock.h index 169241f..999fe72 100644 --- a/drivers/clk/ti/clock.h +++ b/drivers/clk/ti/clock.h @@ -235,7 +235,7 @@ struct omap_clkctrl_data { #define CLKF_HW_SUP BIT(1) #define CLKF_NO_IDLEST BIT(2) -typedef void (*ti_of_clk_init_cb_t)(struct clk_hw *, struct device_node *); +typedef void (*ti_of_clk_init_cb_t)(void *, struct device_node *); struct clk *ti_clk_register_gate(struct ti_clk *setup); struct clk *ti_clk_register_interface(struct ti_clk *setup); @@ -263,7 +263,7 @@ int ti_clk_parse_divider_data(int *div_table, int num_dividers, int max_div, int ti_clk_get_reg_addr(struct device_node *node, int index, struct clk_omap_reg *reg); void ti_dt_clocks_register(struct ti_dt_clk *oclks); -int ti_clk_retry_init(struct device_node *node, struct clk_hw *hw, +int ti_clk_retry_init(struct device_node *node, void *user, ti_of_clk_init_cb_t func); int ti_clk_add_component(struct device_node *node, struct clk_hw *hw, int type); diff --git a/drivers/clk/ti/composite.c b/drivers/clk/ti/composite.c index beea894..3eaba2d 100644 --- a/drivers/clk/ti/composite.c +++ b/drivers/clk/ti/composite.c @@ -161,9 +161,10 @@ struct clk *ti_clk_register_composite(struct ti_clk *setup) } #endif -static void __init _register_composite(struct clk_hw *hw, +static void __init _register_composite(void *user, struct device_node *node) { + struct clk_hw *hw = user; struct clk *clk; struct clk_hw_omap_comp *cclk = to_clk_hw_comp(hw); struct component_clk *comp; diff --git a/drivers/clk/ti/dpll.c b/drivers/clk/ti/dpll.c index d4e4444..d246598 100644 --- a/drivers/clk/ti/dpll.c +++ b/drivers/clk/ti/dpll.c @@ -152,9 +152,10 @@ * clk-bypass is missing), the clock is added to retry list and * the initialization is retried on later stage. */ -static void __init _register_dpll(struct clk_hw *hw, +static void __init _register_dpll(void *user, struct device_node *node) { + struct clk_hw *hw = user; struct clk_hw_omap *clk_hw = to_clk_hw_omap(hw); struct dpll_data *dd = clk_hw->dpll_data; struct clk *clk;