[PATCH v4 4/4] arm64: apple: Add PCIe node

Marc Zyngier maz at kernel.org
Sun Sep 12 14:30:42 PDT 2021


On Fri, 27 Aug 2021 18:15:29 +0100,
Mark Kettenis <mark.kettenis at xs4all.nl> wrote:
> 
> From: Mark Kettenis <kettenis at openbsd.org>
> 
> Add node corresponding to the apcie,t8103 node in the
> Apple device tree for the Mac mini (M1, 2020).
> 
> Clock references and DART (IOMMU) references are left out at the
> moment and will be added once the appropriate bindings have been
> settled upon.
> 
> Signed-off-by: Mark Kettenis <kettenis at openbsd.org>
> ---
>  arch/arm64/boot/dts/apple/t8103.dtsi | 63 ++++++++++++++++++++++++++++
>  1 file changed, 63 insertions(+)
> 
> diff --git a/arch/arm64/boot/dts/apple/t8103.dtsi b/arch/arm64/boot/dts/apple/t8103.dtsi
> index 503a76fc30e6..6e4677bdef44 100644
> --- a/arch/arm64/boot/dts/apple/t8103.dtsi
> +++ b/arch/arm64/boot/dts/apple/t8103.dtsi
> @@ -214,5 +214,68 @@ pinctrl_smc: pinctrl at 23e820000 {
>  				     <AIC_IRQ 396 IRQ_TYPE_LEVEL_HIGH>,
>  				     <AIC_IRQ 397 IRQ_TYPE_LEVEL_HIGH>;
>  		};
> +
> +		pcie0: pcie at 690000000 {
> +			compatible = "apple,t8103-pcie", "apple,pcie";
> +			device_type = "pci";
> +
> +			reg = <0x6 0x90000000 0x0 0x1000000>,
> +			      <0x6 0x80000000 0x0 0x4000>,

Only exposing 16kB for the 'rc' crashes the Linux driver as it tries
to configure the port ref-clock configurations, which live much
higher:

#define CORE_LANE_CFG(port)		(0x84000 + 0x4000 * (port))

Previous versions of the binding had this region as 1MB, which made
things work.

> +			      <0x6 0x81000000 0x0 0x8000>,
> +			      <0x6 0x82000000 0x0 0x8000>,
> +			      <0x6 0x83000000 0x0 0x8000>;

These used to be 16kB, and are now twice as much. Didn't cause any
issue with the Linux driver, but I wonder what trigger either change.

Thanks,

	M.

-- 
Without deviation from the norm, progress is not possible.



More information about the linux-arm-kernel mailing list