From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-ej1-f42.google.com (mail-ej1-f42.google.com [209.85.218.42]) (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 7FDB686E6 for ; Tue, 6 Sep 2022 19:26:48 +0000 (UTC) Received: by mail-ej1-f42.google.com with SMTP id fg1so3429098ejc.2 for ; Tue, 06 Sep 2022 12:26:48 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:from:to:cc:subject:date; bh=3oOVdi/bQtPCfcN+ik9XE1mlmO3wSv0j3YsV+Rxg9iA=; b=oi+lsbgrsow9eDnffOWYdWZn4LHOIOGIOUe13rTHqTRCoiuHIMKfqZu2hMrnBmEDZf sdpLszwKJF4wcItH10Gu5dYZH85MdPRVCwbugwAhEuAFcgxy6hkXnUaszaH8TcTxKbBT dRfDl0qCbcEA/yByUASgFx/EuLvYr/BJYr27xx8NkZ4VRhKy4YkRwlDKzBJjFB8y9DO0 hwVyxz0Z6dgjavxRhDvcb3YBNnUROMbRikIG6tqHMf6AWhGvg0homiIxi7iyiu4FlMTY bHfRzthhlW3dusDlm/x94JHGS5coTG5jDaStTJBO5aknisKj/UugmTQ/UcIi8Fa+gJMa uUDg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:cc:to:subject:message-id:date:from :in-reply-to:references:mime-version:x-gm-message-state:from:to:cc :subject:date; bh=3oOVdi/bQtPCfcN+ik9XE1mlmO3wSv0j3YsV+Rxg9iA=; b=8NOWPoJzZP2HdKRuN1if/Eg1FILGmLBPE9Niv6iu75+oG6KM5cSoCK210NIQpaGltT sNXMIy2KuniiQmVDNluvBPQXFUGg0o/OvKZD1XMk28dqwMcMIR1P6jEZ6FihqRWbuG06 QJD0odVjbQ1vdcNsj42L/NzbmXKm2HRoykgPOtO8/tBRmmPKwpReC0ctK5VXFivm0fmz P/MIcjOOP8Dr7PxPOaoKuFNYNkmgs5r071PoRgHQ6ubbHaDRzSlcClhawXq+HFqHqYM0 6zPzA5yJz/Cdxi/fmabYDv66qXBrDo9/lMioJTQrKfs1/dIlfRLutFGIqVmsAwAo5ABK C7ZQ== X-Gm-Message-State: ACgBeo3KvC9JxKhfWLHkRLCpFBM5fEiQ4f9XVAHFVWgL1KckGkdyAVy4 bYA6wbWiLKfs1ISR3d6kSi0JJCm/PzC9gUvNIEA= X-Google-Smtp-Source: AA6agR70GthhctG+XzaKnAyD3X1E8+YQzb/0n4Tcz5GSF++oD42tAArTNShHfOuNh/UxP2ah4WQAFSc4TdMmm+SuxC4= X-Received: by 2002:a17:906:9fc1:b0:761:9192:504f with SMTP id hj1-20020a1709069fc100b007619192504fmr23306ejc.116.1662492406523; Tue, 06 Sep 2022 12:26:46 -0700 (PDT) Precedence: bulk X-Mailing-List: linux-sunxi@lists.linux.dev List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 References: <20220906153034.153321-1-peron.clem@gmail.com> <20220906153034.153321-4-peron.clem@gmail.com> <12048299.O9o76ZdvQC@kista> In-Reply-To: <12048299.O9o76ZdvQC@kista> From: =?UTF-8?B?Q2zDqW1lbnQgUMOpcm9u?= Date: Tue, 6 Sep 2022 21:26:34 +0200 Message-ID: Subject: Re: [PATCH v4 3/5] arm64: dts: allwinner: h6: Add GPU OPP table To: =?UTF-8?Q?Jernej_=C5=A0krabec?= Cc: Chen-Yu Tsai , Samuel Holland , Rob Herring , Krzysztof Kozlowski , devicetree , linux-arm-kernel , linux-sunxi@lists.linux.dev, linux-kernel , dri-devel Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: quoted-printable Hi Jernej, On Tue, 6 Sept 2022 at 21:10, Jernej =C5=A0krabec wrote: > > Dne torek, 06. september 2022 ob 17:30:32 CEST je Cl=C3=A9ment P=C3=A9ron= napisal(a): > > Add an Operating Performance Points table for the GPU to > > enable Dynamic Voltage & Frequency Scaling on the H6. > > > > The voltage range is set with minimal voltage set to the target > > and the maximal voltage set to 1.2V. This allow DVFS framework to > > work properly on board with fixed regulator. > > > > Signed-off-by: Cl=C3=A9ment P=C3=A9ron > > --- > > .../boot/dts/allwinner/sun50i-h6-gpu-opp.dtsi | 87 +++++++++++++++++++ > > 1 file changed, 87 insertions(+) > > create mode 100644 arch/arm64/boot/dts/allwinner/sun50i-h6-gpu-opp.dts= i > > > > diff --git a/arch/arm64/boot/dts/allwinner/sun50i-h6-gpu-opp.dtsi > > b/arch/arm64/boot/dts/allwinner/sun50i-h6-gpu-opp.dtsi new file mode 10= 0644 > > index 000000000000..b48049c4fc85 > > --- /dev/null > > +++ b/arch/arm64/boot/dts/allwinner/sun50i-h6-gpu-opp.dtsi > > @@ -0,0 +1,87 @@ > > +// SPDX-License-Identifier: (GPL-2.0+ OR MIT) > > +// Copyright (C) 2022 Cl=C3=A9ment P=C3=A9ron > > + > > +/ { > > + gpu_opp_table: opp-table-gpu { > > + compatible =3D "operating-points-v2"; > > + > > + opp-216000000 { > > + opp-hz =3D /bits/ 64 <216000000>; > > + opp-microvolt =3D <810000 810000 1200000>; > > + }; > > + > > + opp-264000000 { > > + opp-hz =3D /bits/ 64 <264000000>; > > + opp-microvolt =3D <810000 810000 1200000>; > > + }; > > As mentioned in clock patch review, rates below 288 MHz are deemed unstab= le on > GPU PLL by vendor GPU kernel driver. At least in the BSP version that I h= ave. > Did you test these points? If not, better to drop them. I changed the governor to userspace and set the freq to 216MHz / 264MHz Run glmark2 and didn't observe any glitch nor issue. I'm not sure if it's enough to say it's stable but I didn't observe any strange behavior. Regards, Clement > > Best regards, > Jernej > > > + > > + opp-312000000 { > > + opp-hz =3D /bits/ 64 <312000000>; > > + opp-microvolt =3D <810000 810000 1200000>; > > + }; > > + > > + opp-336000000 { > > + opp-hz =3D /bits/ 64 <336000000>; > > + opp-microvolt =3D <810000 810000 1200000>; > > + }; > > + > > + opp-360000000 { > > + opp-hz =3D /bits/ 64 <360000000>; > > + opp-microvolt =3D <820000 820000 1200000>; > > + }; > > + > > + opp-384000000 { > > + opp-hz =3D /bits/ 64 <384000000>; > > + opp-microvolt =3D <830000 830000 1200000>; > > + }; > > + > > + opp-408000000 { > > + opp-hz =3D /bits/ 64 <408000000>; > > + opp-microvolt =3D <840000 840000 1200000>; > > + }; > > + > > + opp-420000000 { > > + opp-hz =3D /bits/ 64 <420000000>; > > + opp-microvolt =3D <850000 850000 1200000>; > > + }; > > + > > + opp-432000000 { > > + opp-hz =3D /bits/ 64 <432000000>; > > + opp-microvolt =3D <860000 860000 1200000>; > > + }; > > + > > + opp-456000000 { > > + opp-hz =3D /bits/ 64 <456000000>; > > + opp-microvolt =3D <870000 870000 1200000>; > > + }; > > + > > + opp-504000000 { > > + opp-hz =3D /bits/ 64 <504000000>; > > + opp-microvolt =3D <890000 890000 1200000>; > > + }; > > + > > + opp-540000000 { > > + opp-hz =3D /bits/ 64 <540000000>; > > + opp-microvolt =3D <910000 910000 1200000>; > > + }; > > + > > + opp-576000000 { > > + opp-hz =3D /bits/ 64 <576000000>; > > + opp-microvolt =3D <930000 930000 1200000>; > > + }; > > + > > + opp-624000000 { > > + opp-hz =3D /bits/ 64 <624000000>; > > + opp-microvolt =3D <950000 950000 1200000>; > > + }; > > + > > + opp-756000000 { > > + opp-hz =3D /bits/ 64 <756000000>; > > + opp-microvolt =3D <1040000 1040000 1200000>; > > + }; > > + }; > > +}; > > + > > +&gpu { > > + operating-points-v2 =3D <&gpu_opp_table>; > > +}; > > -- > > 2.34.1 > >