Il 09/02/23 10:45, Chen-Yu Tsai ha scritto:
On Thu, Feb 9, 2023 at 5:20 PM AngeloGioacchino Del Regno
<angelogioacchino.delregno@xxxxxxxxxxxxx> wrote:
Il 09/02/23 09:49, Chen-Yu Tsai ha scritto:
On Wed, Feb 8, 2023 at 6:37 PM AngeloGioacchino Del Regno
<angelogioacchino.delregno@xxxxxxxxxxxxx> wrote:
Get GPU support on MT8186 by adding its compatible.
I'd skip MT8186 for now. We have to work out some binning details for the
OPP, in particular how to deal with both Panfrost (or Mali) and SVS adding
the OPP table. We were just looking at the Mali driver today.
Dealing with binning is fairly easy... I have something already done for
that one, but I'm not sure that it would be the best option.
My solution makes use of opp-supported-hw by "standard means", but perhaps
let's have a separated conversation about it?
I don't think that skipping this would give any benefit though, because
that is only adding a compatible and whatever binning support would have
to be generic and 99% not bound to any mediatek specific compatible.
The binning is related to voltage range, not maximum OPP. So it's more
like fast/slow example in Documentation/devicetree/bindings/opp/opp-v2.yaml
or the opp/allwinner,sun50i-h6-operating-points.yaml, minus the efuse node.
The downstream DT currently looks like this:
opp-950000000 {
opp-hz = /bits/ 64 <950000000>;
/* This is Mali specific; ignore
opp-hz-real = /bits/ 64 <950000000>,
/bits/ 64 <950000000>;
*/
opp-microvolt = <900000>, <1000000>;
opp-microvolt-bin4 = <875000>, <975000>;
opp-microvolt-bin5 = <850000>, <950000>;
};
Yes, my option is, in short:
opp-900000000 {
opp-hz = /bits/ 64 <900000000>;
opp-microvolt = <850000>;
opp-supported-hw = <0xcf>;
};
opp-900000000-bin4 {
opp-hz = /bits/ 64 <900000000>;
opp-microvolt = <837500>;
opp-supported-hw = <0x10>;
};
opp-900000000-bin5 {
opp-hz = /bits/ 64 <900000000>;
opp-microvolt = <825000>;
opp-supported-hw = <0x20>;
};
ChenYu