Skip to content
Open
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
72 changes: 72 additions & 0 deletions arch/arm64/boot/dts/apple/t8142-j704.dts
Original file line number Diff line number Diff line change
Expand Up @@ -329,3 +329,75 @@
#include "t8142-j704-hdmi.dtsi"
#include "t8142-j704-audio.dtsi"
#include "t8142-j704-usbc-display.dtsi"

&{/soc} {
/*
* The CPU clusters' power-gate enables (E at +0x0, P at +0x60) and
* display power words, shared across T8142.
*/
cluster_pwrgate: power-gate@380724000 {
compatible = "apple,t8142-cluster-pwrgate", "apple,cluster-pwrgate";
reg = <0x3 0x80724000 0x0 0x4>,
<0x3 0x80724060 0x0 0x4>;
};

dcp_power: display-power@380724000 {
compatible = "apple,t8142-display-power";
reg = <3 0x80724000 0 0x2000>,
<3 0x80700000 0 0x14000>;
reg-names = "pwrgate", "ps";
};
};

&dcp {
apple,display-power = <&dcp_power>;
};

&dcp_dart {
reg = <2 0x86340000 0 0x20000>,
<3 0x80717fdc 0 0x4>;
reg-names = "dart", "ps-wr-dis";
apple,ps-wr-dis-bit = <6>;
};

&dcpext0 {
apple,display-power = <&dcp_power>;
};

&dcpext1 {
apple,display-power = <&dcp_power>;
};

&dcpext0_dart {
reg = <5 0x06340000 0 0x20000>,
<3 0x80717fe8 0 0x4>;
reg-names = "dart", "ps-wr-dis";
apple,ps-wr-dis-bit = <15>;
};

&dcpext1_dart {
reg = <3 0xaa340000 0 0x20000>,
<3 0x80717fec 0 0x4>;
reg-names = "dart", "ps-wr-dis";
apple,ps-wr-dis-bit = <31>;
};

#include "t8142-j813-sep.dtsi"
#include "t8142-j813-j815-sleep.dtsi"

&sleep {
apple,display-coprocessors = <&dcp &dcpext0 &dcpext1>;
};

&hpm0 {
apple,sleep-ssps-rules;
};

&hpm1 {
apple,sleep-ssps-rules;
};

&hpm3 {
apple,sleep-ssps;
apple,sleep-ssps-rules;
};
1 change: 1 addition & 0 deletions drivers/mfd/macsmc.c
Original file line number Diff line number Diff line change
Expand Up @@ -768,6 +768,7 @@ static int apple_smc_probe(struct platform_device *pdev)
* its SMC hears last, after SEP and the other coprocessors stopped.
*/
if (of_machine_is_compatible("apple,j813") ||
of_machine_is_compatible("apple,j704") ||
of_device_is_compatible(dev->of_node, "apple,t8103-smc") ||
of_device_is_compatible(dev->of_node, "apple,t8112-smc"))
smc->saved_enabled = true;
Expand Down
4 changes: 3 additions & 1 deletion drivers/soc/apple/sleep.c
Original file line number Diff line number Diff line change
Expand Up @@ -2096,7 +2096,9 @@ bool apple_sleep_smc_defer_notice(void)
/* Gen 1 (T8103): SEP sleeps before the SMC is told, as on macOS and t6000. */
if (apple_sleep->soc->smc_gen1_keys)
return true;
return READ_ONCE(sleep_j813_smc_late) && of_machine_is_compatible("apple,j813");
return READ_ONCE(sleep_j813_smc_late) &&
(of_machine_is_compatible("apple,j813") ||
of_machine_is_compatible("apple,j704"));
}
EXPORT_SYMBOL_GPL(apple_sleep_smc_defer_notice);

Expand Down
Loading