Received: by 2002:a05:6a10:6744:0:0:0:0 with SMTP id w4csp3850303pxu; Mon, 12 Oct 2020 02:56:06 -0700 (PDT) X-Google-Smtp-Source: ABdhPJwhGRMTpMp1i8RSOYi+yyqeBfDPg5PMO3nsfjH1lHxbxVNOaO+M41dcb124SSqOFIUvKfxV X-Received: by 2002:a17:906:8295:: with SMTP id h21mr19046917ejx.278.1602496565777; Mon, 12 Oct 2020 02:56:05 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1602496565; cv=none; d=google.com; s=arc-20160816; b=pomK/3Am+4a/ETjONh5lqk40YXypjn6VvbtrOFOSwOSlyqqThwnM0r7Eva6PmJEgdT 8tr9LGdhMG6QpR4vxbDHAb2IcJ5W5yRbB6SEL+n/reh3PyDcWeLbRWhRsqkMVWba4C8P vi4UbAc73UbpQuYsk5IMjdprd3N0OkI6WZw7xuYZJSbKUuRqUzCWo79+bF4OcZLebOAK 3AQmF9yza5dO1W9/dboZd3eC1wvxxIJbbwFOn3Wp4m4W/i3XHvTIm6ZfnLqEBf1MgdVZ GTJPyer5/8sqQ0Oj8r4bUaEBR+fHqCRERKybD1jREz2xY7SDKWHLlXxpChMwPWlv6gpb c8fQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:message-id:date:subject:cc:to:from :dkim-signature; bh=iGo+ZN3tAXAxv3w8yNYuIIpSkiLbRMRp3Fk34AunwFo=; b=K6nF4+wjCDTDnF1meFsikhYg/zciGU8FmDB9Nus+Zkp488BSCkvjIKtk5RrwsYoDIc 6sVm4Ia5Hhpry5N4Ry9PbeG4uhz2ztDpeyqci60HY02D+ibYvgmBW1CH1SCIrLvyRetW bPGZf5W4k+6vbCi3edu+YaM7SoHQ6hbMM6KTtSHloDBsoJGQsJWfL4HV07SPi+1dSjTr nEOVkA0A+ZWbrKvStJJBwPI56SseNbXKCrdupW2/1UiS5hxDOgUx9NckZsyyp4mjUhnf a1+kqnQU86L4oYrvXPCvOXDS2+TPk9mwgQzd2ZLpoq1eFHSKZqWhIrOT/4HFStBrY/kT hRyQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Z8qjXpJm; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id b3si5841787ejz.322.2020.10.12.02.55.41; Mon, 12 Oct 2020 02:56:05 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=Z8qjXpJm; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729501AbgJLJyH (ORCPT + 99 others); Mon, 12 Oct 2020 05:54:07 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:52542 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726510AbgJLJyG (ORCPT ); Mon, 12 Oct 2020 05:54:06 -0400 Received: from mail-ed1-x541.google.com (mail-ed1-x541.google.com [IPv6:2a00:1450:4864:20::541]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 56EBAC0613CE; Mon, 12 Oct 2020 02:54:06 -0700 (PDT) Received: by mail-ed1-x541.google.com with SMTP id o18so16276815edq.4; Mon, 12 Oct 2020 02:54:06 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id; bh=iGo+ZN3tAXAxv3w8yNYuIIpSkiLbRMRp3Fk34AunwFo=; b=Z8qjXpJma1fftxvQeo8JughAkkolo9T2zLHCRb0WgSqanywbY8nDc5tNb7CFaDzh0K 1axx2jb5E5GAdrAUGcjgF493gNmTdPqbSuyLmRtUDLcSQcp6eKwQm3sIbH94Wm9B0jn8 vbNZ3cq016hHWU2hOar7rqO4cgWhyf4cB5zrrJs857cOouUWAZBTg3pexYRmbz+NJhsn snCXnKqpzQeXRo+o9dK6NH8kCneNHnAYXuYv2VMDGTymSrGUlgWwr7qaRgBfyaZggUdh yAUqHQJQNHuXcIHrxVaRo871hVw5EscjwpJsaO/z/jk1Hw9LTGwmvht7AZUTKQ8Yeqb9 wnnw== 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; bh=iGo+ZN3tAXAxv3w8yNYuIIpSkiLbRMRp3Fk34AunwFo=; b=pH8OIQevXjaMwq9/ueJk6Z5lWXtaQWCsPIKJYtwGrhobcRjTK9cyodCjZpaUuD+KTP oOyt4Puje8xx4+SPffDpf3c5wd6Nh/NvinqU7qD8OJoywstTyGx7Lrq5M7GxCJiFw+im gynUziNXzxATFxjk6ETK6+J/3L7Ophg73+oHk3tBTye2QsQAD0iEoB6WlcrZj/tRLYd8 QzuxxV1brkgvpRxKPwLzBdBM2lLfYH+g4QuLpp4BGcqfzmlfr63skr8HlqwGXkjE0fHx 5nKzb9Iu1ogu41t/S6O6A08Q+n8wmMxBmVPrmRtP4TGcx5ZLaBIB0WmnugnWvDDYKZSp rN7g== X-Gm-Message-State: AOAM531q6NjZR1LoHlJj6cB3ZwVuWcskFQMIcYth7nGJxi/Cdgyav1VM wY6l9PvALH8An9G/1Gedtrl/m7qs78c= X-Received: by 2002:a05:6402:2292:: with SMTP id cw18mr13678803edb.112.1602496445047; Mon, 12 Oct 2020 02:54:05 -0700 (PDT) Received: from debian.home (81-204-249-205.fixed.kpn.net. [81.204.249.205]) by smtp.gmail.com with ESMTPSA id bt16sm10369895ejb.89.2020.10.12.02.54.04 (version=TLS1_2 cipher=ECDHE-ECDSA-AES128-GCM-SHA256 bits=128/128); Mon, 12 Oct 2020 02:54:04 -0700 (PDT) From: Johan Jonker To: heiko@sntech.de Cc: zhangqing@rock-chips.com, finley.xiao@rock-chips.com, zhengyang@rock-chips.com, hjc@rock-chips.com, mturquette@baylibre.com, sboyd@kernel.org, linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-rockchip@lists.infradead.org, linux-kernel@vger.kernel.org Subject: [RFC PATCH v1] clk: rockchip: add CLK_SET_RATE_PARENT to sclk for rk3066a i2s and uart clocks Date: Mon, 12 Oct 2020 11:53:57 +0200 Message-Id: <20201012095357.4852-1-jbx6244@gmail.com> X-Mailer: git-send-email 2.11.0 Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Add CLK_SET_RATE_PARENT to sclk for rk3066a i2s and uart clocks, so that the parent COMPOSITE_FRACMUX and COMPOSITE_NOMUX also update. Signed-off-by: Johan Jonker --- drivers/clk/rockchip/clk-rk3188.c | 28 ++++++++++++++-------------- 1 file changed, 14 insertions(+), 14 deletions(-) diff --git a/drivers/clk/rockchip/clk-rk3188.c b/drivers/clk/rockchip/clk-rk3188.c index 730020fcc..db8c58813 100644 --- a/drivers/clk/rockchip/clk-rk3188.c +++ b/drivers/clk/rockchip/clk-rk3188.c @@ -255,19 +255,19 @@ static struct rockchip_clk_branch common_spdif_fracmux __initdata = RK2928_CLKSEL_CON(5), 8, 2, MFLAGS); static struct rockchip_clk_branch common_uart0_fracmux __initdata = - MUX(SCLK_UART0, "sclk_uart0", mux_sclk_uart0_p, 0, + MUX(SCLK_UART0, "sclk_uart0", mux_sclk_uart0_p, CLK_SET_RATE_PARENT, RK2928_CLKSEL_CON(13), 8, 2, MFLAGS); static struct rockchip_clk_branch common_uart1_fracmux __initdata = - MUX(SCLK_UART1, "sclk_uart1", mux_sclk_uart1_p, 0, + MUX(SCLK_UART1, "sclk_uart1", mux_sclk_uart1_p, CLK_SET_RATE_PARENT, RK2928_CLKSEL_CON(14), 8, 2, MFLAGS); static struct rockchip_clk_branch common_uart2_fracmux __initdata = - MUX(SCLK_UART2, "sclk_uart2", mux_sclk_uart2_p, 0, + MUX(SCLK_UART2, "sclk_uart2", mux_sclk_uart2_p, CLK_SET_RATE_PARENT, RK2928_CLKSEL_CON(15), 8, 2, MFLAGS); static struct rockchip_clk_branch common_uart3_fracmux __initdata = - MUX(SCLK_UART3, "sclk_uart3", mux_sclk_uart3_p, 0, + MUX(SCLK_UART3, "sclk_uart3", mux_sclk_uart3_p, CLK_SET_RATE_PARENT, RK2928_CLKSEL_CON(16), 8, 2, MFLAGS); static struct rockchip_clk_branch common_clk_branches[] __initdata = { @@ -408,28 +408,28 @@ static struct rockchip_clk_branch common_clk_branches[] __initdata = { COMPOSITE_NOMUX(0, "uart0_pre", "uart_src", 0, RK2928_CLKSEL_CON(13), 0, 7, DFLAGS, RK2928_CLKGATE_CON(1), 8, GFLAGS), - COMPOSITE_FRACMUX(0, "uart0_frac", "uart0_pre", 0, + COMPOSITE_FRACMUX(0, "uart0_frac", "uart0_pre", CLK_SET_RATE_PARENT, RK2928_CLKSEL_CON(17), 0, RK2928_CLKGATE_CON(1), 9, GFLAGS, &common_uart0_fracmux), COMPOSITE_NOMUX(0, "uart1_pre", "uart_src", 0, RK2928_CLKSEL_CON(14), 0, 7, DFLAGS, RK2928_CLKGATE_CON(1), 10, GFLAGS), - COMPOSITE_FRACMUX(0, "uart1_frac", "uart1_pre", 0, + COMPOSITE_FRACMUX(0, "uart1_frac", "uart1_pre", CLK_SET_RATE_PARENT, RK2928_CLKSEL_CON(18), 0, RK2928_CLKGATE_CON(1), 11, GFLAGS, &common_uart1_fracmux), COMPOSITE_NOMUX(0, "uart2_pre", "uart_src", 0, RK2928_CLKSEL_CON(15), 0, 7, DFLAGS, RK2928_CLKGATE_CON(1), 12, GFLAGS), - COMPOSITE_FRACMUX(0, "uart2_frac", "uart2_pre", 0, + COMPOSITE_FRACMUX(0, "uart2_frac", "uart2_pre", CLK_SET_RATE_PARENT, RK2928_CLKSEL_CON(19), 0, RK2928_CLKGATE_CON(1), 13, GFLAGS, &common_uart2_fracmux), COMPOSITE_NOMUX(0, "uart3_pre", "uart_src", 0, RK2928_CLKSEL_CON(16), 0, 7, DFLAGS, RK2928_CLKGATE_CON(1), 14, GFLAGS), - COMPOSITE_FRACMUX(0, "uart3_frac", "uart3_pre", 0, + COMPOSITE_FRACMUX(0, "uart3_frac", "uart3_pre", CLK_SET_RATE_PARENT, RK2928_CLKSEL_CON(20), 0, RK2928_CLKGATE_CON(1), 15, GFLAGS, &common_uart3_fracmux), @@ -543,15 +543,15 @@ static struct clk_div_table div_aclk_cpu_t[] = { }; static struct rockchip_clk_branch rk3066a_i2s0_fracmux __initdata = - MUX(SCLK_I2S0, "sclk_i2s0", mux_sclk_i2s0_p, 0, + MUX(SCLK_I2S0, "sclk_i2s0", mux_sclk_i2s0_p, CLK_SET_RATE_PARENT, RK2928_CLKSEL_CON(2), 8, 2, MFLAGS); static struct rockchip_clk_branch rk3066a_i2s1_fracmux __initdata = - MUX(SCLK_I2S1, "sclk_i2s1", mux_sclk_i2s1_p, 0, + MUX(SCLK_I2S1, "sclk_i2s1", mux_sclk_i2s1_p, CLK_SET_RATE_PARENT, RK2928_CLKSEL_CON(3), 8, 2, MFLAGS); static struct rockchip_clk_branch rk3066a_i2s2_fracmux __initdata = - MUX(SCLK_I2S2, "sclk_i2s2", mux_sclk_i2s2_p, 0, + MUX(SCLK_I2S2, "sclk_i2s2", mux_sclk_i2s2_p, CLK_SET_RATE_PARENT, RK2928_CLKSEL_CON(4), 8, 2, MFLAGS); static struct rockchip_clk_branch rk3066a_clk_branches[] __initdata = { @@ -615,21 +615,21 @@ static struct rockchip_clk_branch rk3066a_clk_branches[] __initdata = { COMPOSITE_NOMUX(0, "i2s0_pre", "i2s_src", 0, RK2928_CLKSEL_CON(2), 0, 7, DFLAGS, RK2928_CLKGATE_CON(0), 7, GFLAGS), - COMPOSITE_FRACMUX(0, "i2s0_frac", "i2s0_pre", 0, + COMPOSITE_FRACMUX(0, "i2s0_frac", "i2s0_pre", CLK_SET_RATE_PARENT, RK2928_CLKSEL_CON(6), 0, RK2928_CLKGATE_CON(0), 8, GFLAGS, &rk3066a_i2s0_fracmux), COMPOSITE_NOMUX(0, "i2s1_pre", "i2s_src", 0, RK2928_CLKSEL_CON(3), 0, 7, DFLAGS, RK2928_CLKGATE_CON(0), 9, GFLAGS), - COMPOSITE_FRACMUX(0, "i2s1_frac", "i2s1_pre", 0, + COMPOSITE_FRACMUX(0, "i2s1_frac", "i2s1_pre", CLK_SET_RATE_PARENT, RK2928_CLKSEL_CON(7), 0, RK2928_CLKGATE_CON(0), 10, GFLAGS, &rk3066a_i2s1_fracmux), COMPOSITE_NOMUX(0, "i2s2_pre", "i2s_src", 0, RK2928_CLKSEL_CON(4), 0, 7, DFLAGS, RK2928_CLKGATE_CON(0), 11, GFLAGS), - COMPOSITE_FRACMUX(0, "i2s2_frac", "i2s2_pre", 0, + COMPOSITE_FRACMUX(0, "i2s2_frac", "i2s2_pre", CLK_SET_RATE_PARENT, RK2928_CLKSEL_CON(8), 0, RK2928_CLKGATE_CON(0), 12, GFLAGS, &rk3066a_i2s2_fracmux), -- 2.11.0