Skip to content
Merged
Show file tree
Hide file tree
Changes from 1 commit
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
61 changes: 61 additions & 0 deletions arch/arm64/boot/dts/apple/t6050-k114-k116-display.dtsi
Original file line number Diff line number Diff line change
@@ -0,0 +1,61 @@
// SPDX-License-Identifier: GPL-2.0+ OR MIT
/*
* The internal tandem OLED panel and its display coprocessor on the K114c, K114s, K116c and
* K116s, for the boot loader's display hand-off. The four ADTs have the same disp0, dart-disp0,
* dcp and dart-dcp (the live K114s and K116s ADTs: disp0 clock-ids 361 and 458, both DARTs
* vm-base 1 TiB, vm-size 3 TiB) and no I2C backlight controller: the OLED's luminance is a DCP
* request (ADT /backlight-override dcp-brightness-node = 1).
*
* Everything stays disabled. The loader checks the ADT and the live DCP and DART state,
* publishes the DCP's firmware properties, the panel's brightness scale (ADT
* user-accessible-max-nits) and the ADT /vram as the framebuffer, and only then enables dcp,
* its DARTs and mailbox and the display subsystem. A loader without the hand-off, or one whose
* checks fail, leaves the boot framebuffer to simpledrm.
*
* The board adds the panel's size (the ADTs carry none).
*/

/ {
aliases {
/* The loader writes apple,notch-height into the "dcp" alias */
dcp = &dcp;
disp0 = &display;
};

/* As on J714s, with the internal display's DART (disp0, SID 0) */
display: display-subsystem {
compatible = "apple,display-subsystem";
iommus = <&disp0_dart 0>;
status = "disabled";
};
};

/* ADT dart-dcp and dart-disp0: vm-base 1 TiB, vm-size 3 TiB */
&dcp_dart {
apple,dma-range = <0x100 0x0 0x300 0x0>;
};

&disp0_dart {
apple,dma-range = <0x100 0x0 0x300 0x0>;
};

&dcp {
/*
* ADT disp0 clock-ids. The loader adds the clock nodes, "clocks" and the
* bandwidth request scratch ("apple,bw-scratch") when it hands the panel
* over, as on the J714s, and refuses a tree that already has them.
*/
apple,clock-ids = <361 458>;

/*
* The panel's plug takes about 2.9 ms on the K116s from the video interface's
* announcement to the firmware's "ioav i/f is now closed", and the next round of
* reports follows about 33 ms later. With the J714s's 2500 us the open landed 25 us
* before the close. The K boards run the same 27.2 DCP image for the same panel family.
*/
apple,panel-video-open-delay-us = <10000>;

panel: panel {
compatible = "apple,panel";
};
};
13 changes: 13 additions & 0 deletions arch/arm64/boot/dts/apple/t6050-k114c.dts
Original file line number Diff line number Diff line change
Expand Up @@ -155,6 +155,19 @@
/* The GPU, handed over by the boot loader */
#include "t6050-k114-k116-gpu.dtsi"

/* The internal panel, handed over by the boot loader */
#include "t6050-k114-k116-display.dtsi"

/*
* The 14.2-inch 3024x1986 panel's active area (254 dpi, the notch rows included), for the
* DPI only (the ADT carries none)
*/
&panel {
compatible = "apple,panel-k114", "apple,panel";
width-mm = <302>;
height-mm = <199>;
};

/*
* The K114c keeps J714's card with its speakers, at the J714's safe level. The
* chassis' K114 entry (t6050-k114.dtsi) has the jack only.
Expand Down
13 changes: 13 additions & 0 deletions arch/arm64/boot/dts/apple/t6050-k114s.dts
Original file line number Diff line number Diff line change
Expand Up @@ -34,6 +34,19 @@
/* The GPU, handed over by the boot loader */
#include "t6050-k114-k116-gpu.dtsi"

/* The internal panel, handed over by the boot loader */
#include "t6050-k114-k116-display.dtsi"

/*
* The 14.2-inch 3024x1986 panel's active area (254 dpi, the notch rows included), for the
* DPI only (the ADT carries none)
*/
&panel {
compatible = "apple,panel-k114", "apple,panel";
width-mm = <302>;
height-mm = <199>;
};

/ {
aliases {
/* asahi-bless and the boot loader find the NVRAM partition by this alias */
Expand Down
10 changes: 10 additions & 0 deletions arch/arm64/boot/dts/apple/t6050-k116c.dts
Original file line number Diff line number Diff line change
Expand Up @@ -29,5 +29,15 @@
/* The GPU, handed over by the boot loader */
#include "t6050-k114-k116-gpu.dtsi"

/* The internal panel, handed over by the boot loader */
#include "t6050-k114-k116-display.dtsi"

/* The 16.2-inch 3456x2234 panel's active area, for the DPI only (the ADT carries none) */
&panel {
compatible = "apple,panel-k116", "apple,panel";
width-mm = <345>;
height-mm = <223>;
};

/* The USB-C ports ATC1 and ATC2, as on the other K boards */
#include "t6050-k114-k116-usb.dtsi"
66 changes: 12 additions & 54 deletions arch/arm64/boot/dts/apple/t6050-k116s.dts
Original file line number Diff line number Diff line change
Expand Up @@ -171,57 +171,6 @@
};
};

/*
* The internal panel and the display coprocessor, for the boot loader's display
* hand-off (aura, chosen.aurora,t6050-display=1). Everything stays disabled: the
* loader checks the ADT and the live DCP and DART state, publishes the DCP's
* firmware properties, reserves the ADT /vram as the framebuffer and only then
* enables dcp, its DARTs and mailbox and the display subsystem. A loader without
* the hand-off leaves the boot framebuffer to simpledrm.
*/
/ {
aliases {
/* The loader writes apple,notch-height into the "dcp" alias */
dcp = &dcp;
disp0 = &display;
};

/* As on J714s, with the internal display's DART (disp0, SID 0) */
display: display-subsystem {
compatible = "apple,display-subsystem";
iommus = <&disp0_dart 0>;
status = "disabled";
};
};

/* ADT dart-dcp and dart-disp0: vm-base 1 TiB, vm-size 3 TiB */
&dcp_dart {
apple,dma-range = <0x100 0x0 0x300 0x0>;
};

&disp0_dart {
apple,dma-range = <0x100 0x0 0x300 0x0>;
};

&dcp {
/*
* ADT disp0 clock-ids. The loader adds the clock nodes, "clocks" and the
* bandwidth request scratch ("apple,bw-scratch") when it hands the panel
* over, as on the J714s, and refuses a tree that already has them.
*/
apple,clock-ids = <361 458>;

/*
* The 16.2-inch 3456x2234 tandem OLED panel. The ADT carries no dimensions;
* these are the panel's active area, for the DPI only.
*/
panel {
compatible = "apple,panel-k116", "apple,panel";
width-mm = <345>;
height-mm = <223>;
};
};

/*
* The trackpad's AFE reset. The ADT names the SMC pcIO template (0x10000,
* 0x11c0000), the same line as SMC GPIO gp1c, active low, which gpio-macsmc
Expand Down Expand Up @@ -610,6 +559,16 @@
/* The GPU, handed over by the boot loader */
#include "t6050-k114-k116-gpu.dtsi"

/* The internal panel, handed over by the boot loader */
#include "t6050-k114-k116-display.dtsi"

/* The 16.2-inch 3456x2234 panel's active area, for the DPI only (the ADT carries none) */
&panel {
compatible = "apple,panel-k116", "apple,panel";
width-mm = <345>;
height-mm = <223>;
};

/*
* As t6050-j714s.dts: the GPU on the PMP's GFX report entry (report@f, on ps_gfx), so the PMP
* is told the GPU is on only while it is powered. This board runs the PMP with its report
Expand Down Expand Up @@ -812,9 +771,8 @@
};

/*
* The panel's plug takes about 2.9 ms here from the video interface's announcement to the
* firmware's "ioav i/f is now closed", and the next round of reports follows about 33 ms later.
* With the J714s's 2500 us the open landed 25 us before the close.
* t6050-j714s-sleep-soc.dtsi, included above, sets the J714s's 2500 us; keep the K boards'
* 10000 us (t6050-k114-k116-display.dtsi).
*/
&dcp {
apple,panel-video-open-delay-us = <10000>;
Expand Down