162306a36Sopenharmony_ciMediaTek SCPSYS 262306a36Sopenharmony_ci=============== 362306a36Sopenharmony_ci 462306a36Sopenharmony_ciThe System Control Processor System (SCPSYS) has several power management 562306a36Sopenharmony_cirelated tasks in the system. The tasks include thermal measurement, dynamic 662306a36Sopenharmony_civoltage frequency scaling (DVFS), interrupt filter and lowlevel sleep control. 762306a36Sopenharmony_ciThe System Power Manager (SPM) inside the SCPSYS is for the MTCMOS power 862306a36Sopenharmony_cidomain control. 962306a36Sopenharmony_ci 1062306a36Sopenharmony_ciThe driver implements the Generic PM domain bindings described in 1162306a36Sopenharmony_cipower/power-domain.yaml. It provides the power domains defined in 1262306a36Sopenharmony_ci- include/dt-bindings/power/mt8173-power.h 1362306a36Sopenharmony_ci- include/dt-bindings/power/mt6797-power.h 1462306a36Sopenharmony_ci- include/dt-bindings/power/mt6765-power.h 1562306a36Sopenharmony_ci- include/dt-bindings/power/mt2701-power.h 1662306a36Sopenharmony_ci- include/dt-bindings/power/mt2712-power.h 1762306a36Sopenharmony_ci- include/dt-bindings/power/mt7622-power.h 1862306a36Sopenharmony_ci 1962306a36Sopenharmony_ciRequired properties: 2062306a36Sopenharmony_ci- compatible: Should be one of: 2162306a36Sopenharmony_ci - "mediatek,mt2701-scpsys" 2262306a36Sopenharmony_ci - "mediatek,mt2712-scpsys" 2362306a36Sopenharmony_ci - "mediatek,mt6765-scpsys" 2462306a36Sopenharmony_ci - "mediatek,mt6797-scpsys" 2562306a36Sopenharmony_ci - "mediatek,mt7622-scpsys" 2662306a36Sopenharmony_ci - "mediatek,mt7623-scpsys", "mediatek,mt2701-scpsys": For MT7623 SoC 2762306a36Sopenharmony_ci - "mediatek,mt7623a-scpsys": For MT7623A SoC 2862306a36Sopenharmony_ci - "mediatek,mt7629-scpsys", "mediatek,mt7622-scpsys": For MT7629 SoC 2962306a36Sopenharmony_ci - "mediatek,mt8173-scpsys" 3062306a36Sopenharmony_ci- #power-domain-cells: Must be 1 3162306a36Sopenharmony_ci- reg: Address range of the SCPSYS unit 3262306a36Sopenharmony_ci- infracfg: must contain a phandle to the infracfg controller 3362306a36Sopenharmony_ci- clock, clock-names: clocks according to the common clock binding. 3462306a36Sopenharmony_ci These are clocks which hardware needs to be 3562306a36Sopenharmony_ci enabled before enabling certain power domains. 3662306a36Sopenharmony_ci Required clocks for MT2701 or MT7623: "mm", "mfg", "ethif" 3762306a36Sopenharmony_ci Required clocks for MT2712: "mm", "mfg", "venc", "jpgdec", "audio", "vdec" 3862306a36Sopenharmony_ci Required clocks for MT6765: MUX: "mm", "mfg" 3962306a36Sopenharmony_ci CG: "mm-0", "mm-1", "mm-2", "mm-3", "isp-0", 4062306a36Sopenharmony_ci "isp-1", "cam-0", "cam-1", "cam-2", 4162306a36Sopenharmony_ci "cam-3","cam-4" 4262306a36Sopenharmony_ci Required clocks for MT6797: "mm", "mfg", "vdec" 4362306a36Sopenharmony_ci Required clocks for MT7622 or MT7629: "hif_sel" 4462306a36Sopenharmony_ci Required clocks for MT7623A: "ethif" 4562306a36Sopenharmony_ci Required clocks for MT8173: "mm", "mfg", "venc", "venc_lt" 4662306a36Sopenharmony_ci 4762306a36Sopenharmony_ciOptional properties: 4862306a36Sopenharmony_ci- vdec-supply: Power supply for the vdec power domain 4962306a36Sopenharmony_ci- venc-supply: Power supply for the venc power domain 5062306a36Sopenharmony_ci- isp-supply: Power supply for the isp power domain 5162306a36Sopenharmony_ci- mm-supply: Power supply for the mm power domain 5262306a36Sopenharmony_ci- venc_lt-supply: Power supply for the venc_lt power domain 5362306a36Sopenharmony_ci- audio-supply: Power supply for the audio power domain 5462306a36Sopenharmony_ci- usb-supply: Power supply for the usb power domain 5562306a36Sopenharmony_ci- mfg_async-supply: Power supply for the mfg_async power domain 5662306a36Sopenharmony_ci- mfg_2d-supply: Power supply for the mfg_2d power domain 5762306a36Sopenharmony_ci- mfg-supply: Power supply for the mfg power domain 5862306a36Sopenharmony_ci 5962306a36Sopenharmony_ciExample: 6062306a36Sopenharmony_ci 6162306a36Sopenharmony_ci scpsys: scpsys@10006000 { 6262306a36Sopenharmony_ci #power-domain-cells = <1>; 6362306a36Sopenharmony_ci compatible = "mediatek,mt8173-scpsys"; 6462306a36Sopenharmony_ci reg = <0 0x10006000 0 0x1000>; 6562306a36Sopenharmony_ci infracfg = <&infracfg>; 6662306a36Sopenharmony_ci clocks = <&clk26m>, 6762306a36Sopenharmony_ci <&topckgen CLK_TOP_MM_SEL>; 6862306a36Sopenharmony_ci <&topckgen CLK_TOP_VENC_SEL>, 6962306a36Sopenharmony_ci <&topckgen CLK_TOP_VENC_LT_SEL>; 7062306a36Sopenharmony_ci clock-names = "mfg", "mm", "venc", "venc_lt"; 7162306a36Sopenharmony_ci }; 7262306a36Sopenharmony_ci 7362306a36Sopenharmony_ciExample consumer: 7462306a36Sopenharmony_ci 7562306a36Sopenharmony_ci afe: mt8173-afe-pcm@11220000 { 7662306a36Sopenharmony_ci compatible = "mediatek,mt8173-afe-pcm"; 7762306a36Sopenharmony_ci power-domains = <&scpsys MT8173_POWER_DOMAIN_AUDIO>; 7862306a36Sopenharmony_ci }; 79