Received: by 2002:a05:7412:d008:b0:f9:6acb:47ec with SMTP id bd8csp42746rdb; Tue, 19 Dec 2023 08:54:47 -0800 (PST) X-Google-Smtp-Source: AGHT+IHJqNuhCbScKRIzwdqdEIxxCwty8MWLVNlGW1/lV4ic9R6A3Y96V5b1YuPOU1Lo2C4KO30g X-Received: by 2002:a17:906:1ce:b0:a22:faed:defc with SMTP id 14-20020a17090601ce00b00a22faeddefcmr4570640ejj.7.1703004886873; Tue, 19 Dec 2023 08:54:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1703004886; cv=none; d=google.com; s=arc-20160816; b=Ajy8Ej2ucpHP/cbivCgLM0nc+BhxhJsl/AFPrgd17E6x+zju8jHjqrPVjCYdA2s7xI t53h9VqBXqP6aIMDZEqlevroWNPEDCy4PAqKLyZB/b2Ls+Wna8ImKhi+py14EKiCHHbI vf1rRDsjagVhG0wOyat9EtPR1tuB0rViVemTQvTUZk+NZuoIOADGQHMCXIHPSSwp7KhI v4N2w0Jbkfy2x0/181RkeXgTa6euwaOdsYHIh8SEJZZPNPyPaEABialGf8V0kbUN7n5v MrkZz5QAxs5tr8quryBRMPdLU/xyHoag0Zfw4E5fFozHPFpd77kU2dTCU7WSM7eT69Jd uwWQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=content-transfer-encoding:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:in-reply-to:message-id :date:subject:cc:to:from:dkim-signature; bh=Hnbv43rPSyuI7Tjsf1jCy999PgtXeEb5DS5jkSFPK+Y=; fh=dTac3MWzER1z7M0gaFMOk+5cVuNyukYZMIMsRvoaD6M=; b=eXGBajCwNJ5FkR9okPlVNdFa0qSmBlNGRta/1VnzwUFnoY6p6pldzBqYtZkwgdgqUE ffVcmp4Aw4QUXzMZfHo3OdCbtqk4pilIM70JHY7RB6QfKKRM4KrSOTi3SOf0TwBrYDOW HOpECskqyqpRGhTAN4mDX3S0jLfIbpP4DgXsFG0Sg35XP7fDqfCvcnPzczbfNGywpLn+ 9fhrpN0dScpLgHeebqmzWfRoYMHUfY5DumYvvVwod3O4XuzTF69eh7K9nIhNN53Ud43e pvwi+OvqjlumBmYbJyRpGOHjOSoVLDL3PXTKjZAoHixcYB4+IQZ1zwoahkYcjWYeuRy/ VPDA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=Q4thzRet; spf=pass (google.com: domain of linux-kernel+bounces-5606-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-5606-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from am.mirrors.kernel.org (am.mirrors.kernel.org. [2604:1380:4601:e00::3]) by mx.google.com with ESMTPS id p13-20020a170906228d00b00a2353a1f41bsi2066624eja.751.2023.12.19.08.54.46 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 19 Dec 2023 08:54:46 -0800 (PST) Received-SPF: pass (google.com: domain of linux-kernel+bounces-5606-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) client-ip=2604:1380:4601:e00::3; Authentication-Results: mx.google.com; dkim=pass header.i=@gmail.com header.s=20230601 header.b=Q4thzRet; spf=pass (google.com: domain of linux-kernel+bounces-5606-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:4601:e00::3 as permitted sender) smtp.mailfrom="linux-kernel+bounces-5606-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by am.mirrors.kernel.org (Postfix) with ESMTPS id 9E65F1F21889 for ; Tue, 19 Dec 2023 16:54:46 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 0D23B208B7; Tue, 19 Dec 2023 16:54:26 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="Q4thzRet" X-Original-To: linux-kernel@vger.kernel.org Received: from mail-ej1-f48.google.com (mail-ej1-f48.google.com [209.85.218.48]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C04632E647; Tue, 19 Dec 2023 16:54:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Received: by mail-ej1-f48.google.com with SMTP id a640c23a62f3a-a1fae88e66eso535224766b.3; Tue, 19 Dec 2023 08:54:23 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1703004862; x=1703609662; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=Hnbv43rPSyuI7Tjsf1jCy999PgtXeEb5DS5jkSFPK+Y=; b=Q4thzRetp4YzPjqgrzT5mlQeGocrwukaFH6SBZ+xXSF05WlMawLdI0D/S2iMLoiqBo fTpO+hopSKLezmu3j8SYzKy2s3b1vm+d5beln/XOsLNur546CLZu/BEUdQyKlffSnWPo un2+Cjqnuj57s/Hdu6QjncUf3JchagRUf7RAqRVubvta4r2hAs+7wrTHtG2i7gw+r27x qVK1i9stPdHgM89B0AZdJWV59SvHDPLoUQ+WPidRTS1B+5Gu6A01y8E9M0o/mUKRScQk 1Nb9H7XHPXd5nBOY0rBobrsppdQjnDHWx9BZxFf1qEZirxituYmvYqCzZUM+x0baCWHk PQpg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1703004862; x=1703609662; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=Hnbv43rPSyuI7Tjsf1jCy999PgtXeEb5DS5jkSFPK+Y=; b=S1SmMvJNj3U8BDuvrqelFs6HNSZ9fUHT/SNoY+x9mcjs+fBpohOLR1WxpJ3JeW5uFD kyiwi9iKpDdu8LoNYYq1FXerpng4x6EwQs5EuMr/mAyp1Hy8eN2t7tTIcFSPiW/Gu3LS ruSP6wRRclmYItkny10h1MFh81OZkR3p4y/C3KRBjs5GJtnhxvVgLLmBc0R9fY7bC5Bh 4rhUN9A7CcAfWk2qtVaKHXbTvqr/90e/jsuJYgsOxe+xksBVq7hCuCrRJSS6U4NjYL94 Qw3fo1TKk8LGwt0YeT5gdhP5vsNSdI50p5awZ8CjgSe0M0IOJKN5wX+JDotR8NxbV3LL skLw== X-Gm-Message-State: AOJu0YwUzwNmiuZpFs1zgZEanMjf62ajBk+SDRi277GmgbPg9sJINSCL /YC+ckOerj8eEBKd3p6wp8Y= X-Received: by 2002:a17:906:2611:b0:a23:48d2:be33 with SMTP id h17-20020a170906261100b00a2348d2be33mr1859295ejc.128.1703004861755; Tue, 19 Dec 2023 08:54:21 -0800 (PST) Received: from jernej-laptop.localnet (82-149-12-148.dynamic.telemach.net. [82.149.12.148]) by smtp.gmail.com with ESMTPSA id s19-20020a170906c31300b00a236e9cfe74sm1381021ejz.103.2023.12.19.08.54.20 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 19 Dec 2023 08:54:21 -0800 (PST) From: Jernej =?utf-8?B?xaBrcmFiZWM=?= To: Michael Turquette , Stephen Boyd , Chen-Yu Tsai , Samuel Holland , Guido =?ISO-8859-1?Q?G=FCnther?= , Purism Kernel Team , Ondrej Jirman , Neil Armstrong , Jessica Zhang , Sam Ravnborg , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Daniel Vetter , Frank Oltmanns Cc: linux-clk@vger.kernel.org, linux-arm-kernel@lists.infradead.org, linux-sunxi@lists.linux.dev, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, Frank Oltmanns Subject: Re: [PATCH 4/5] clk: sunxi-ng: a64: Add constraints on PLL-VIDEO0's n/m ratio Date: Tue, 19 Dec 2023 17:54:19 +0100 Message-ID: <13411739.uLZWGnKmhe@jernej-laptop> In-Reply-To: <20231218-pinephone-pll-fixes-v1-4-e238b6ed6dc1@oltmanns.dev> References: <20231218-pinephone-pll-fixes-v1-0-e238b6ed6dc1@oltmanns.dev> <20231218-pinephone-pll-fixes-v1-4-e238b6ed6dc1@oltmanns.dev> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 7Bit Content-Type: text/plain; charset="us-ascii" Dne ponedeljek, 18. december 2023 ob 14:35:22 CET je Frank Oltmanns napisal(a): > The Allwinner A64 manual lists the following constraint for the > PLL-VIDEO0 clock: 8 <= N/M <= 25 > > Use this constraint. > > Signed-off-by: Frank Oltmanns > --- > drivers/clk/sunxi-ng/ccu-sun50i-a64.c | 8 ++++++-- > 1 file changed, 6 insertions(+), 2 deletions(-) > > diff --git a/drivers/clk/sunxi-ng/ccu-sun50i-a64.c b/drivers/clk/sunxi-ng/ccu-sun50i-a64.c > index c034ac027d1c..75d839da446c 100644 > --- a/drivers/clk/sunxi-ng/ccu-sun50i-a64.c > +++ b/drivers/clk/sunxi-ng/ccu-sun50i-a64.c > @@ -68,7 +68,8 @@ static SUNXI_CCU_NM_WITH_SDM_GATE_LOCK(pll_audio_base_clk, "pll-audio-base", > BIT(28), /* lock */ > CLK_SET_RATE_UNGATE); > > -static SUNXI_CCU_NM_WITH_FRAC_GATE_LOCK_MIN_MAX_CLOSEST(pll_video0_clk, "pll-video0", > +static SUNXI_CCU_NM_WITH_FRAC_GATE_LOCK_MIN_MAX_FEAT_NM_RATIO(pll_video0_clk, > + "pll-video0", > "osc24M", 0x010, > 192000000, /* Minimum rate */ > 1008000000, /* Maximum rate */ > @@ -80,7 +81,10 @@ static SUNXI_CCU_NM_WITH_FRAC_GATE_LOCK_MIN_MAX_CLOSEST(pll_video0_clk, "pll-vid > 297000000, /* frac rate 1 */ > BIT(31), /* gate */ > BIT(28), /* lock */ > - CLK_SET_RATE_UNGATE); > + CLK_SET_RATE_UNGATE, > + CCU_FEATURE_FRACTIONAL | > + CCU_FEATURE_CLOSEST_RATE, Above flags are unrelated change, put them in new patch if needed. Best regards, Jernej > + 8, 25); /* min/max nm ratio */ > > static SUNXI_CCU_NM_WITH_FRAC_GATE_LOCK(pll_ve_clk, "pll-ve", > "osc24M", 0x018, > >