Received: by 2002:a25:ab43:0:0:0:0:0 with SMTP id u61csp4235685ybi; Tue, 11 Jun 2019 03:18:53 -0700 (PDT) X-Google-Smtp-Source: APXvYqza6vIYMxgp/67zfReO0H2HKAZJ8tdLUfuYPPwls//XubOOk6ZCbg5Qc5C4zoKbu7onj0nD X-Received: by 2002:a63:1f48:: with SMTP id q8mr2447861pgm.417.1560248333372; Tue, 11 Jun 2019 03:18:53 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1560248333; cv=none; d=google.com; s=arc-20160816; b=DPxKkFvq6+lua0vBGvfxAG6nAl2whFQ/ze0baB1sinTZJYZaV4vTue89ra3FLmbph+ MIRbKP77jaf93Jaa76BnYD+IqmQuSl9u0tnRK52U1b5UMsZfCk2AtXMOf13eq4wCXB7/ 8amflx+AjvXDR+CjehsaQblZFsD7ncAnljN6rpOrR+kvC5o2RxMGr3Q1sSlG685PrrNt 8qOzPRYF7m95WgMUvevC50bzlR7D7yToYp+EfyJRLYNz1kYYYaPvBL4LtQNg1RTp9Tf4 AZGMM1Bfb9ZPemhPHMDapyPUhKrdOy72mLUB9IKwH+eoJT2FQAP78LCs/7gSIgp6tcMW kOSQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :references:in-reply-to:message-id:date:subject:cc:to:from :dkim-signature; bh=rsJnOCqAbHu/SAKisDrT4DJEiAl8IicQvi/lVKIKIFo=; b=aFXiB5b2XSvk6h8toYp/jrq6ZYFwqwlBSqXtH+LGitVJBNBwLDhs4PaGJcfpcPsWRl c1rHOoND+FVQGrGN0xK1M7jT+1P6BQeD6Tj9b/gtT6dXECoFUSvidpm6G3Fd8mO+gi7a l1h4VBVJMx4c9lAVOg3FtFEKLud6FhSoTeXoSrTs7GJyBU3Eo3GsM7KHuhmxSR96UboX jyglIoVHQ7ZZMfgqxwmxbYmrkVV+PKqOvbcgRU7sYNhEzVw/j1ftDOQ+Ff/ItnKRXzw1 OcKui0RWm+APKoe0P3YClkPAYjwDZXBHb0xmH0aXC0d/DTXT/tvgiA+NFa490vxbvFF7 uhNQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=ymAPliOd; 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=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s101si2109259pjc.5.2019.06.11.03.18.38; Tue, 11 Jun 2019 03:18:53 -0700 (PDT) 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=@kernel.org header.s=default header.b=ymAPliOd; 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=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2405461AbfFKKSE (ORCPT + 99 others); Tue, 11 Jun 2019 06:18:04 -0400 Received: from mail.kernel.org ([198.145.29.99]:46174 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2405343AbfFKKR0 (ORCPT ); Tue, 11 Jun 2019 06:17:26 -0400 Received: from wens.tw (mirror2.csie.ntu.edu.tw [140.112.30.76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id 7FF02217D6; Tue, 11 Jun 2019 10:17:25 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1560248245; bh=Kn3t/CWfkqyvKZFbLUZs5AfcXKZa2BYUNUsJyKA5Gz4=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=ymAPliOd1nYzigdtr7cOMV+v9MT8eMmXKabPR70y5mCL4qj1cs47JlvfNUYtmgyOq 9ZShzsyUZy9VOg0hCDDc41T3QaLIZ32exlSgeLn3CVF1IC5dcIrjMgUNUGlNxearQA D0VCr/+Uxx++DrF4nUwsN8j4WHQXRxbWyoQRowVg= Received: by wens.tw (Postfix, from userid 1000) id 99DF660C93; Tue, 11 Jun 2019 18:17:18 +0800 (CST) From: Chen-Yu Tsai To: Maxime Ripard , Stephen Boyd , Michael Turquette Cc: Chen-Yu Tsai , linux-arm-kernel@lists.infradead.org, linux-clk@vger.kernel.org, linux-kernel@vger.kernel.org, Chen-Yu Tsai Subject: [PATCH v2 22/25] clk: sunxi-ng: h6-r: Use local parent references for CLK_FIXED_FACTOR Date: Tue, 11 Jun 2019 18:16:55 +0800 Message-Id: <20190611101658.23855-23-wens@kernel.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190611101658.23855-1-wens@kernel.org> References: <20190611101658.23855-1-wens@kernel.org> MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Chen-Yu Tsai With the new clk parenting code and CLK_FIXED_FACTOR_{HW,FW_NAME} macros, we can reference parents locally via pointers to struct clk_hw or DT clock-names. Convert existing CLK_FIXED_FACTOR definitions to either the _HW or _FW_NAME variant based on whether the parent clock is internal or external to the CCU. Acked-by: Maxime Ripard Signed-off-by: Chen-Yu Tsai --- drivers/clk/sunxi-ng/ccu-sun50i-h6-r.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/clk/sunxi-ng/ccu-sun50i-h6-r.c b/drivers/clk/sunxi-ng/ccu-sun50i-h6-r.c index 8d05d4f1f8a1..45a1ed3fe674 100644 --- a/drivers/clk/sunxi-ng/ccu-sun50i-h6-r.c +++ b/drivers/clk/sunxi-ng/ccu-sun50i-h6-r.c @@ -49,7 +49,7 @@ static struct ccu_div ar100_clk = { }, }; -static CLK_FIXED_FACTOR(r_ahb_clk, "r-ahb", "ar100", 1, 1, 0); +static CLK_FIXED_FACTOR_HW(r_ahb_clk, "r-ahb", &ar100_clk.common.hw, 1, 1, 0); static struct ccu_div r_apb1_clk = { .div = _SUNXI_CCU_DIV(0, 2), -- 2.20.1