From nobody Thu Dec 5 02:25:25 2024 Received: from mail-oa1-f50.google.com (mail-oa1-f50.google.com [209.85.160.50]) (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 0E038187332; Tue, 3 Dec 2024 05:12:12 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.160.50 ARC-Seal: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1733202735; cv=none; b=F6o0hG5J2FRz/Zs8d38NpDjrAIt4comB8lIW4LOotcsKpHgsTTz1ZFL2CndFcrUJBS4gzOtxZuJ0r2+ggbeGrpBC387MdsmczOXQ9+TxW8UTqdBJIIrFsPDa5JrvcGmRZwM8IQAapbIIE9A852ieoQnVdo4j50hyw8JoW55IrxQ= ARC-Message-Signature: i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1733202735; c=relaxed/simple; bh=usaCNOFtOJ89h9HLbxQysc6MANRxD6iOR984cQtuxW4=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=Xz/L6ia9Fjp1McXPhqiwpeSCFuf1BHLDuyD6y1bwSm6nNGs1FG5v1UQKNhCiGn7I7KlvVzbI5HmbyJ0aJyPHFcr+3MsYZEzFHe9XKmJOHz7QPsOwG40sN7KhyjoaAuRqRS12UUN0U8JqpljXIoz7ZGNIoJHswSTlN/FYMSO+coQ= ARC-Authentication-Results: i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=Cj5L3tE/; arc=none smtp.client-ip=209.85.160.50 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="Cj5L3tE/" Received: by mail-oa1-f50.google.com with SMTP id 586e51a60fabf-29e2e768952so2845182fac.3; Mon, 02 Dec 2024 21:12:12 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1733202732; x=1733807532; darn=vger.kernel.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=HThsFhdrYGz3zN9X3vgN5sb+Y6o8RirTuI9rS65tL3g=; b=Cj5L3tE/LLe8FhlJpPLmt90N+1wDrHY5gyR3pS0kBmLhb4TIp/tMTKRWlWbu+Xe5lr f160Bs9Xei6Ku/+Q5AFmt3jcB+NZoufWaMnNkP1VbuHH0vlhkNYAf2GzmzpNHmptLpdC ebRd44Nb5n1VnIFl+p/Bl3BWOa+NxL+RlwJhWWDpZuzqIAcEfOz7ktK4ZGoy4QrCMaYh Y6+cYo2C7gz2kMDb+YsiuW9ttuAA822UYWkjmP/Ql1bhb1Y2lP/GoXomWdA/Cc5j+jiX fn4B/JqsnoeXxu34yeVN3+lB7olCRxFhmtMQhOdndUpdNSfUGjFXJkP97S1zZzVEVsC6 7hlA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1733202732; x=1733807532; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=HThsFhdrYGz3zN9X3vgN5sb+Y6o8RirTuI9rS65tL3g=; b=S2x89y5E3hKjMKPiB/ox9WmjTwsQ/AIg8Uv9bUbj2Sxqb70m73cL8QpsOPibIpgpOL +xdG4ia+Y+6/lnNNR29hHMDOvSImzP/fSC5y2a3fgdjh8523qonKYivxNtqLSnTcsTUW MZZNoblvE0JzfpJ0YNkJG251b31fu/+PROr+/qU3LN8WX+i8oODcUuQXULvY1+BACJLN yudmjuZbkRUPtFtkmpPMKszp+4iqTXFpQcQ3fAX1ZclkQiNw8KKPGwxcMKmgzBtQZdiH qckY0WzJcb6CV4nvZZFrqETixYohIbeAlhQMoi0XDUyrUfdlQYok+fdGJ5aZrg3kow0c oIbw== X-Forwarded-Encrypted: i=1; AJvYcCUPXVwiFwg9xcqWU1DWwyMFCC4aPi4ajE4Zgz/yALYnn9QN82bfSbw/Hbv55D1xd2U8ylb5fafNV5NQbCts@vger.kernel.org, AJvYcCVqvJT1aHwd/OQxGWkrvREC4CwffFjUlPqkm3Pcfm28BSZqqcLPS0S3tKyN3RgMfcDv1Wqrd8IgFgja@vger.kernel.org X-Gm-Message-State: AOJu0YwX7ZR76m/xhW4n7xzfJk3gLch2c3VS+VkxhDcrfhZ/jf6Z5a2s oTTVuhnrjAb2YXfDnkpKRSFzRj4NNZYeap15W9KOVc47c/uXX6Yd X-Gm-Gg: ASbGncvcmjej9O/Lcboa2sS1V1dqzl26ziTaaENwp9OcaN+Nnziebg/5irwepHhfTi2 eEyc2MTrrczFcN8LZXOCd879/+xtUeHnVxd1yF2nB9QCD3JYKL+sThYeSdKh3afYDOacOfkvcOz F8PvQrqTuoTp94OUFE4HB9Wx9dbNWwLUekLorS/qS7+euCUDnvnzW3jQdlMjCURc9KazcQlAWor agpozKDLpprSGQtG3auVeVuxFLiOBP0cjMEG3SKcjHCE6KsdgAqwpWwA+Gv5LhWgw== X-Google-Smtp-Source: AGHT+IFPNhuZRcNjEQFhxajBDwQvbycrUxJzMD+W9B7eiTTs3MlE68RlXEHw107o+EFBZHBzobV1YQ== X-Received: by 2002:a05:6808:1795:b0:3ea:5880:fe1f with SMTP id 5614622812f47-3eae4ec41aemr1095330b6e.5.1733202731868; Mon, 02 Dec 2024 21:12:11 -0800 (PST) Received: from localhost.localdomain ([59.188.211.160]) by smtp.googlemail.com with ESMTPSA id d2e1a72fcca58-72541848916sm9525047b3a.172.2024.12.02.21.12.09 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 02 Dec 2024 21:12:11 -0800 (PST) From: Nick Chan To: Hector Martin , Sven Peter , Alyssa Rosenzweig , Rob Herring , Krzysztof Kozlowski , Conor Dooley , asahi@lists.linux.dev, linux-arm-kernel@lists.infradead.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org Cc: Aun-Ali Zaidi , Paul Pawlowski , Nick Chan Subject: [PATCH v2 2/3] arm64: dts: apple: Add T2 devices Date: Tue, 3 Dec 2024 13:10:28 +0800 Message-ID: <20241203051147.110980-3-towinchenmi@gmail.com> X-Mailer: git-send-email 2.47.1 In-Reply-To: <20241203051147.110980-1-towinchenmi@gmail.com> References: <20241203051147.110980-1-towinchenmi@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset="utf-8" Add DTS files for the T2 SoC and the following devices based on it: - Apple T2 MacBookPro15,2 (j132) - Apple T2 iMacPro1,1 (j137) - Apple T2 MacBookAir8,2 (j140a) - Apple T2 MacBookAir8,1 (j140k) - Apple T2 MacBookPro16,1 (j152f) - Apple T2 MacPro7,1 (j160) - Apple T2 Macmini8,1 (j174) - Apple T2 iMac20,1 (j185) - Apple T2 iMac20,2 (j185f) - Apple T2 MacBookPro15,4 (j213) - Apple T2 MacBookPro16,2 (j214k) - Apple T2 MacBookPro16,4 (j215) - Apple T2 MacBookPro16,3 (j223) - Apple T2 MacBookAir9,1 (j230k) - Apple T2 MacBookPro15,1 (j680) - Apple T2 MacBookPro15,3 (j780) The Apple T2 is an A10-based security chip found on some Intel Macs from 2017 onwards. On models with a touchbar, the touchbar's display is wired to it. These devices have no offical names, the naming scheme is from libirecovery. Signed-off-by: Nick Chan --- arch/arm64/boot/dts/apple/Makefile | 16 ++ arch/arm64/boot/dts/apple/t8012-j132.dts | 14 ++ arch/arm64/boot/dts/apple/t8012-j137.dts | 14 ++ arch/arm64/boot/dts/apple/t8012-j140a.dts | 14 ++ arch/arm64/boot/dts/apple/t8012-j140k.dts | 14 ++ arch/arm64/boot/dts/apple/t8012-j152f.dts | 15 ++ arch/arm64/boot/dts/apple/t8012-j160.dts | 14 ++ arch/arm64/boot/dts/apple/t8012-j174.dts | 14 ++ arch/arm64/boot/dts/apple/t8012-j185.dts | 14 ++ arch/arm64/boot/dts/apple/t8012-j185f.dts | 14 ++ arch/arm64/boot/dts/apple/t8012-j213.dts | 15 ++ arch/arm64/boot/dts/apple/t8012-j214k.dts | 15 ++ arch/arm64/boot/dts/apple/t8012-j215.dts | 15 ++ arch/arm64/boot/dts/apple/t8012-j223.dts | 15 ++ arch/arm64/boot/dts/apple/t8012-j230k.dts | 14 ++ arch/arm64/boot/dts/apple/t8012-j680.dts | 15 ++ arch/arm64/boot/dts/apple/t8012-j780.dts | 15 ++ arch/arm64/boot/dts/apple/t8012-jxxx.dtsi | 44 +++++ arch/arm64/boot/dts/apple/t8012-touchbar.dtsi | 19 ++ arch/arm64/boot/dts/apple/t8012.dtsi | 176 ++++++++++++++++++ 20 files changed, 486 insertions(+) create mode 100644 arch/arm64/boot/dts/apple/t8012-j132.dts create mode 100644 arch/arm64/boot/dts/apple/t8012-j137.dts create mode 100644 arch/arm64/boot/dts/apple/t8012-j140a.dts create mode 100644 arch/arm64/boot/dts/apple/t8012-j140k.dts create mode 100644 arch/arm64/boot/dts/apple/t8012-j152f.dts create mode 100644 arch/arm64/boot/dts/apple/t8012-j160.dts create mode 100644 arch/arm64/boot/dts/apple/t8012-j174.dts create mode 100644 arch/arm64/boot/dts/apple/t8012-j185.dts create mode 100644 arch/arm64/boot/dts/apple/t8012-j185f.dts create mode 100644 arch/arm64/boot/dts/apple/t8012-j213.dts create mode 100644 arch/arm64/boot/dts/apple/t8012-j214k.dts create mode 100644 arch/arm64/boot/dts/apple/t8012-j215.dts create mode 100644 arch/arm64/boot/dts/apple/t8012-j223.dts create mode 100644 arch/arm64/boot/dts/apple/t8012-j230k.dts create mode 100644 arch/arm64/boot/dts/apple/t8012-j680.dts create mode 100644 arch/arm64/boot/dts/apple/t8012-j780.dts create mode 100644 arch/arm64/boot/dts/apple/t8012-jxxx.dtsi create mode 100644 arch/arm64/boot/dts/apple/t8012-touchbar.dtsi create mode 100644 arch/arm64/boot/dts/apple/t8012.dtsi diff --git a/arch/arm64/boot/dts/apple/Makefile b/arch/arm64/boot/dts/apple= /Makefile index ab6ebb53218a..4f337bff36cd 100644 --- a/arch/arm64/boot/dts/apple/Makefile +++ b/arch/arm64/boot/dts/apple/Makefile @@ -46,6 +46,22 @@ dtb-$(CONFIG_ARCH_APPLE) +=3D t8011-j120.dtb dtb-$(CONFIG_ARCH_APPLE) +=3D t8011-j121.dtb dtb-$(CONFIG_ARCH_APPLE) +=3D t8011-j207.dtb dtb-$(CONFIG_ARCH_APPLE) +=3D t8011-j208.dtb +dtb-$(CONFIG_ARCH_APPLE) +=3D t8012-j132.dtb +dtb-$(CONFIG_ARCH_APPLE) +=3D t8012-j137.dtb +dtb-$(CONFIG_ARCH_APPLE) +=3D t8012-j140a.dtb +dtb-$(CONFIG_ARCH_APPLE) +=3D t8012-j140k.dtb +dtb-$(CONFIG_ARCH_APPLE) +=3D t8012-j152f.dtb +dtb-$(CONFIG_ARCH_APPLE) +=3D t8012-j160.dtb +dtb-$(CONFIG_ARCH_APPLE) +=3D t8012-j174.dtb +dtb-$(CONFIG_ARCH_APPLE) +=3D t8012-j185.dtb +dtb-$(CONFIG_ARCH_APPLE) +=3D t8012-j185f.dtb +dtb-$(CONFIG_ARCH_APPLE) +=3D t8012-j213.dtb +dtb-$(CONFIG_ARCH_APPLE) +=3D t8012-j215.dtb +dtb-$(CONFIG_ARCH_APPLE) +=3D t8012-j223.dtb +dtb-$(CONFIG_ARCH_APPLE) +=3D t8012-j230k.dtb +dtb-$(CONFIG_ARCH_APPLE) +=3D t8012-j214k.dtb +dtb-$(CONFIG_ARCH_APPLE) +=3D t8012-j680.dtb +dtb-$(CONFIG_ARCH_APPLE) +=3D t8012-j780.dtb dtb-$(CONFIG_ARCH_APPLE) +=3D t8015-d201.dtb dtb-$(CONFIG_ARCH_APPLE) +=3D t8015-d20.dtb dtb-$(CONFIG_ARCH_APPLE) +=3D t8015-d211.dtb diff --git a/arch/arm64/boot/dts/apple/t8012-j132.dts b/arch/arm64/boot/dts= /apple/t8012-j132.dts new file mode 100644 index 000000000000..778a69be18dd --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-j132.dts @@ -0,0 +1,14 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Apple T2 MacBookPro15,2 (j132), J132, iBridge2,4 + * Copyright (c) 2024, Nick Chan + */ + +/dts-v1/; + +#include "t8012-jxxx.dtsi" + +/ { + model =3D "Apple T2 MacBookPro15,2 (j132)"; + compatible =3D "apple,j132", "apple,t8012", "apple,arm-platform"; +}; diff --git a/arch/arm64/boot/dts/apple/t8012-j137.dts b/arch/arm64/boot/dts= /apple/t8012-j137.dts new file mode 100644 index 000000000000..dbde1ad7ce14 --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-j137.dts @@ -0,0 +1,14 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Apple T2 iMacPro1,1 (j137), J137, iBridge2,1 + * Copyright (c) 2024, Nick Chan + */ + +/dts-v1/; + +#include "t8012-jxxx.dtsi" + +/ { + model =3D "Apple T2 iMacPro1,1 (j137)"; + compatible =3D "apple,j137", "apple,t8012", "apple,arm-platform"; +}; diff --git a/arch/arm64/boot/dts/apple/t8012-j140a.dts b/arch/arm64/boot/dt= s/apple/t8012-j140a.dts new file mode 100644 index 000000000000..5df1ff74d2df --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-j140a.dts @@ -0,0 +1,14 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Apple T2 MacBookAir8,2 (j140a), J140a, iBridge2,12 + * Copyright (c) 2024, Nick Chan + */ + +/dts-v1/; + +#include "t8012-jxxx.dtsi" + +/ { + model =3D "Apple T2 MacBookAir8,2 (j140a)"; + compatible =3D "apple,j140a", "apple,t8012", "apple,arm-platform"; +}; diff --git a/arch/arm64/boot/dts/apple/t8012-j140k.dts b/arch/arm64/boot/dt= s/apple/t8012-j140k.dts new file mode 100644 index 000000000000..a0ef1585e5c2 --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-j140k.dts @@ -0,0 +1,14 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Apple T2 MacBookAir8,1 (j140k), J140k, iBridge2,8 + * Copyright (c) 2024, Nick Chan + */ + +/dts-v1/; + +#include "t8012-jxxx.dtsi" + +/ { + model =3D "Apple T2 MacBookAir8,1 (j140k)"; + compatible =3D "apple,j140k", "apple,t8012", "apple,arm-platform"; +}; diff --git a/arch/arm64/boot/dts/apple/t8012-j152f.dts b/arch/arm64/boot/dt= s/apple/t8012-j152f.dts new file mode 100644 index 000000000000..261416eaf97e --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-j152f.dts @@ -0,0 +1,15 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Apple T2 MacBookPro16,1 (j152f), J152f, iBridge2,14 + * Copyright (c) 2024, Nick Chan + */ + +/dts-v1/; + +#include "t8012-jxxx.dtsi" +#include "t8012-touchbar.dtsi" + +/ { + model =3D "Apple T2 MacBookPro16,1 (j152f)"; + compatible =3D "apple,j152f", "apple,t8012", "apple,arm-platform"; +}; diff --git a/arch/arm64/boot/dts/apple/t8012-j160.dts b/arch/arm64/boot/dts= /apple/t8012-j160.dts new file mode 100644 index 000000000000..fbcc0604f4a0 --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-j160.dts @@ -0,0 +1,14 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Apple T2 MacPro7,1 (j160), J160, iBridge2,6 + * Copyright (c) 2024, Nick Chan + */ + +/dts-v1/; + +#include "t8012-jxxx.dtsi" + +/ { + model =3D "Apple T2 MacPro7,1 (j160)"; + compatible =3D "apple,j160", "apple,t8012", "apple,arm-platform"; +}; diff --git a/arch/arm64/boot/dts/apple/t8012-j174.dts b/arch/arm64/boot/dts= /apple/t8012-j174.dts new file mode 100644 index 000000000000..d11c70f84a71 --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-j174.dts @@ -0,0 +1,14 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Apple T2 Macmini8,1 (j174), J174, iBridge2,5 + * Copyright (c) 2024, Nick Chan + */ + +/dts-v1/; + +#include "t8012-jxxx.dtsi" + +/ { + model =3D "Apple T2 Macmini8,1 (j174)"; + compatible =3D "apple,j174", "apple,t8012", "apple,arm-platform"; +}; diff --git a/arch/arm64/boot/dts/apple/t8012-j185.dts b/arch/arm64/boot/dts= /apple/t8012-j185.dts new file mode 100644 index 000000000000..33492f5db46d --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-j185.dts @@ -0,0 +1,14 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Apple T2 iMac20,1 (j185), J185, iBridge2,19 + * Copyright (c) 2024, Nick Chan + */ + +/dts-v1/; + +#include "t8012-jxxx.dtsi" + +/ { + model =3D "Apple T2 iMac20,1 (j185)"; + compatible =3D "apple,j185", "apple,t8012", "apple,arm-platform"; +}; diff --git a/arch/arm64/boot/dts/apple/t8012-j185f.dts b/arch/arm64/boot/dt= s/apple/t8012-j185f.dts new file mode 100644 index 000000000000..3a4abdd8f7d7 --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-j185f.dts @@ -0,0 +1,14 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Apple T2 iMac20,2 (j185f), J185f, iBridge2,20 + * Copyright (c) 2024, Nick Chan + */ + +/dts-v1/; + +#include "t8012-jxxx.dtsi" + +/ { + model =3D "Apple T2 iMac20,2 (j185f)"; + compatible =3D "apple,j185f", "apple,t8012", "apple,arm-platform"; +}; diff --git a/arch/arm64/boot/dts/apple/t8012-j213.dts b/arch/arm64/boot/dts= /apple/t8012-j213.dts new file mode 100644 index 000000000000..8270812b9a68 --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-j213.dts @@ -0,0 +1,15 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Apple T2 MacBookPro15,4 (j213), J213, iBridge2,10 + * Copyright (c) 2024, Nick Chan + */ + +/dts-v1/; + +#include "t8012-jxxx.dtsi" +#include "t8012-touchbar.dtsi" + +/ { + model =3D "Apple T2 MacBookPro15,4 (j213)"; + compatible =3D "apple,j213", "apple,t8012", "apple,arm-platform"; +}; diff --git a/arch/arm64/boot/dts/apple/t8012-j214k.dts b/arch/arm64/boot/dt= s/apple/t8012-j214k.dts new file mode 100644 index 000000000000..5b8e42512060 --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-j214k.dts @@ -0,0 +1,15 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Apple T2 MacBookPro16,2 (j214k), J214k, iBridge2,16 + * Copyright (c) 2024, Nick Chan + */ + +/dts-v1/; + +#include "t8012-jxxx.dtsi" +#include "t8012-touchbar.dtsi" + +/ { + model =3D "Apple T2 MacBookPro16,2 (j214k)"; + compatible =3D "apple,j214k", "apple,t8012", "apple,arm-platform"; +}; diff --git a/arch/arm64/boot/dts/apple/t8012-j215.dts b/arch/arm64/boot/dts= /apple/t8012-j215.dts new file mode 100644 index 000000000000..ad574fbf7f92 --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-j215.dts @@ -0,0 +1,15 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Apple T2 MacBookPro16,4 (j215), J215, iBridge2,22 + * Copyright (c) 2024, Nick Chan + */ + +/dts-v1/; + +#include "t8012-jxxx.dtsi" +#include "t8012-touchbar.dtsi" + +/ { + model =3D "Apple T2 MacBookPro16,4 (j215)"; + compatible =3D "apple,j215", "apple,t8012", "apple,arm-platform"; +}; diff --git a/arch/arm64/boot/dts/apple/t8012-j223.dts b/arch/arm64/boot/dts= /apple/t8012-j223.dts new file mode 100644 index 000000000000..de75d775aac5 --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-j223.dts @@ -0,0 +1,15 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Apple T2 MacBookPro16,3 (j223), J223, iBridge2,21 + * Copyright (c) 2024, Nick Chan + */ + +/dts-v1/; + +#include "t8012-jxxx.dtsi" +#include "t8012-touchbar.dtsi" + +/ { + model =3D "Apple T2 MacBookPro16,3 (j223)"; + compatible =3D "apple,j223", "apple,t8012", "apple,arm-platform"; +}; diff --git a/arch/arm64/boot/dts/apple/t8012-j230k.dts b/arch/arm64/boot/dt= s/apple/t8012-j230k.dts new file mode 100644 index 000000000000..4b19bc70ab0f --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-j230k.dts @@ -0,0 +1,14 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Apple T2 MacBookAir9,1 (j230k), J230k, iBridge2,15 + * Copyright (c) 2024, Nick Chan + */ + +/dts-v1/; + +#include "t8012-jxxx.dtsi" + +/ { + model =3D "Apple T2 MacBookAir9,1 (j230k)"; + compatible =3D "apple,j230k", "apple,t8012", "apple,arm-platform"; +}; diff --git a/arch/arm64/boot/dts/apple/t8012-j680.dts b/arch/arm64/boot/dts= /apple/t8012-j680.dts new file mode 100644 index 000000000000..aa5a72e07d3f --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-j680.dts @@ -0,0 +1,15 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Apple T2 MacBookPro15,1 (j680), J680, iBridge2,3 + * Copyright (c) 2024, Nick Chan + */ + +/dts-v1/; + +#include "t8012-jxxx.dtsi" +#include "t8012-touchbar.dtsi" + +/ { + model =3D "Apple T2 MacBookPro15,1 (j680)"; + compatible =3D "apple,j680", "apple,t8012", "apple,arm-platform"; +}; diff --git a/arch/arm64/boot/dts/apple/t8012-j780.dts b/arch/arm64/boot/dts= /apple/t8012-j780.dts new file mode 100644 index 000000000000..9cee891cb16d --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-j780.dts @@ -0,0 +1,15 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Apple T2 MacBookPro15,3 (j780), J780, iBridge2,7 + * Copyright (c) 2024, Nick Chan + */ + +/dts-v1/; + +#include "t8012-jxxx.dtsi" +#include "t8012-touchbar.dtsi" + +/ { + model =3D "Apple T2 MacBookPro15,3 (j780)"; + compatible =3D "apple,j780", "apple,t8012", "apple,arm-platform"; +}; diff --git a/arch/arm64/boot/dts/apple/t8012-jxxx.dtsi b/arch/arm64/boot/dt= s/apple/t8012-jxxx.dtsi new file mode 100644 index 000000000000..36e82633bc52 --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-jxxx.dtsi @@ -0,0 +1,44 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Common Device Tree for all T2 devices + * + * target-type: J132, J137, J140a, J140k, J152f, J160, J174, J185, J185f + * J213, J214k, J215, J223, J230k, J680, J780 + * + * Copyright (c) 2024, Nick Chan + */ + +#include "t8012.dtsi" + +/ { + chassis-type =3D "embedded"; + + aliases { + serial0 =3D &serial0; + }; + + chosen { + #address-cells =3D <2>; + #size-cells =3D <2>; + ranges; + + stdout-path =3D "serial0"; + }; + + memory@800000000 { + device_type =3D "memory"; + reg =3D <0x8 0 0 0>; /* To be filled by loader */ + }; + + reserved-memory { + #address-cells =3D <2>; + #size-cells =3D <2>; + ranges; + + /* To be filled by loader */ + }; +}; + +&serial0 { + status =3D "okay"; +}; diff --git a/arch/arm64/boot/dts/apple/t8012-touchbar.dtsi b/arch/arm64/boo= t/dts/apple/t8012-touchbar.dtsi new file mode 100644 index 000000000000..f4a8b12437f0 --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012-touchbar.dtsi @@ -0,0 +1,19 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Common Device Tree for T2 devices with a Touch Bar + * + * target-type: J152f, J213, J214k, J215, J223, J680, J780 + * + * Copyright (c) 2024, Nick Chan + */ + +/ { + chosen { + framebuffer0: framebuffer@0 { + compatible =3D "apple,simple-framebuffer", "simple-framebuffer"; + reg =3D <0 0 0 0>; /* To be filled by loader */ + /* Format properties will be added by loader */ + status =3D "disabled"; + }; + }; +}; diff --git a/arch/arm64/boot/dts/apple/t8012.dtsi b/arch/arm64/boot/dts/app= le/t8012.dtsi new file mode 100644 index 000000000000..45d24ca091b0 --- /dev/null +++ b/arch/arm64/boot/dts/apple/t8012.dtsi @@ -0,0 +1,176 @@ +// SPDX-License-Identifier: GPL-2.0+ OR MIT +/* + * Apple T8012 "T2" SoC + * + * Other names: H9M, "Gibraltar" + * + * Copyright (c) 2024, Nick Chan + */ + +#include +#include +#include +#include + +/ { + interrupt-parent =3D <&aic>; + #address-cells =3D <2>; + #size-cells =3D <2>; + + clkref: clock-ref { + compatible =3D "fixed-clock"; + #clock-cells =3D <0>; + clock-frequency =3D <24000000>; + clock-output-names =3D "clkref"; + }; + + cpus { + #address-cells =3D <2>; + #size-cells =3D <0>; + + cpu0: cpu@10000 { + compatible =3D "apple,hurricane-zephyr"; + reg =3D <0x0 0x10000>; + cpu-release-addr =3D <0 0>; /* To be filled by loader */ + enable-method =3D "spin-table"; + device_type =3D "cpu"; + }; + + cpu1: cpu@10001 { + compatible =3D "apple,hurricane-zephyr"; + reg =3D <0x0 0x10001>; + cpu-release-addr =3D <0 0>; /* To be filled by loader */ + enable-method =3D "spin-table"; + device_type =3D "cpu"; + }; + }; + + soc { + compatible =3D "simple-bus"; + #address-cells =3D <2>; + #size-cells =3D <2>; + nonposted-mmio; + ranges; + + serial0: serial@20a600000 { + compatible =3D "apple,s5l-uart"; + reg =3D <0x2 0x0a600000 0x0 0x4000>; + reg-io-width =3D <4>; + interrupt-parent =3D <&aic>; + interrupts =3D ; + /* Use the bootloader-enabled clocks for now. */ + clocks =3D <&clkref>, <&clkref>; + clock-names =3D "uart", "clk_uart_baud0"; + status =3D "disabled"; + }; + + aic: interrupt-controller@20e100000 { + compatible =3D "apple,t8010-aic", "apple,aic"; + reg =3D <0x2 0x0e100000 0x0 0x100000>; + #interrupt-cells =3D <3>; + interrupt-controller; + }; + + pinctrl_ap: pinctrl@20f100000 { + compatible =3D "apple,t8010-pinctrl", "apple,pinctrl"; + reg =3D <0x2 0x0f100000 0x0 0x100000>; + + gpio-controller; + #gpio-cells =3D <2>; + gpio-ranges =3D <&pinctrl_ap 0 0 221>; + apple,npins =3D <221>; + + interrupt-controller; + #interrupt-cells =3D <2>; + interrupt-parent =3D <&aic>; + interrupts =3D , + , + , + , + , + , + ; + }; + + pinctrl_aop: pinctrl@2100f0000 { + compatible =3D "apple,t8010-pinctrl", "apple,pinctrl"; + reg =3D <0x2 0x0100f0000 0x0 0x10000>; + + gpio-controller; + #gpio-cells =3D <2>; + gpio-ranges =3D <&pinctrl_aop 0 0 41>; + apple,npins =3D <41>; + + interrupt-controller; + #interrupt-cells =3D <2>; + interrupt-parent =3D <&aic>; + interrupts =3D , + , + , + , + , + , + ; + }; + + pinctrl_nub: pinctrl@2111f0000 { + compatible =3D "apple,t8010-pinctrl", "apple,pinctrl"; + reg =3D <0x2 0x111f0000 0x0 0x1000>; + + gpio-controller; + #gpio-cells =3D <2>; + gpio-ranges =3D <&pinctrl_nub 0 0 19>; + apple,npins =3D <19>; + + interrupt-controller; + #interrupt-cells =3D <2>; + interrupt-parent =3D <&aic>; + interrupts =3D , + , + ; + }; + + wdt: watchdog@2112b0000 { + compatible =3D "apple,t8010-wdt", "apple,wdt"; + reg =3D <0x2 0x112b0000 0x0 0x4000>; + clocks =3D <&clkref>; + interrupt-parent =3D <&aic>; + interrupts =3D ; + }; + + pinctrl_smc: pinctrl@212024000 { + compatible =3D "apple,t8010-pinctrl", "apple,pinctrl"; + reg =3D <0x2 0x12024000 0x0 0x1000>; + + gpio-controller; + #gpio-cells =3D <2>; + gpio-ranges =3D <&pinctrl_smc 0 0 81>; + apple,npins =3D <81>; + + interrupt-controller; + #interrupt-cells =3D <2>; + interrupt-parent =3D <&aic>; + interrupts =3D , + , + , + , + , + , + ; + /* + * SMC is not yet supported and accessing this pinctrl while SMC is + * suspended results in a hang. + */ + status =3D "disabled"; + }; + }; + + timer { + compatible =3D "arm,armv8-timer"; + interrupt-parent =3D <&aic>; + interrupt-names =3D "phys", "virt"; + /* Note that T2 doesn't actually have a hypervisor (EL2 is not implement= ed). */ + interrupts =3D , + ; + }; +}; --=20 2.47.1