All of lore.kernel.org
 help / color / mirror / Atom feed
From: Konrad Dybcio <konrad.dybcio@somainline.org>
To: AngeloGioacchino Del Regno 
	<angelogioacchino.delregno@collabora.com>,
	robh+dt@kernel.org
Cc: krzysztof.kozlowski+dt@linaro.org, vkoul@kernel.org,
	chaotian.jing@mediatek.com, ulf.hansson@linaro.org,
	matthias.bgg@gmail.com, hsinyi@chromium.org,
	nfraprado@collabora.com, allen-kh.cheng@mediatek.com,
	fparent@baylibre.com, sam.shih@mediatek.com,
	sean.wang@mediatek.com, long.cheng@mediatek.com,
	wenbin.mei@mediatek.com, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org, dmaengine@vger.kernel.org,
	linux-mmc@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
	linux-mediatek@lists.infradead.org, phone-devel@vger.kernel.org,
	~postmarketos/upstreaming@lists.sr.ht
Subject: Re: [PATCH 7/7] arm64: dts: mediatek: Add support for MT6795 Sony Xperia M5 smartphone
Date: Fri, 29 Jul 2022 14:00:02 +0200	[thread overview]
Message-ID: <a8fa9e22-8c3f-60b2-a0db-01cfd5c37765@somainline.org> (raw)
In-Reply-To: <20220729104441.39177-8-angelogioacchino.delregno@collabora.com>



On 29.07.2022 12:44, AngeloGioacchino Del Regno wrote:
> Add a basic support for the Sony Xperia M5 (codename "Holly")
> smartphone, powered by a MediaTek Helio X10 SoC.
> 
> This achieves a console boot.
> 
> Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
> ---
>  arch/arm64/boot/dts/mediatek/Makefile         |  1 +
>  .../dts/mediatek/mt6795-sony-xperia-m5.dts    | 90 +++++++++++++++++++
>  2 files changed, 91 insertions(+)
>  create mode 100644 arch/arm64/boot/dts/mediatek/mt6795-sony-xperia-m5.dts
> 
> diff --git a/arch/arm64/boot/dts/mediatek/Makefile b/arch/arm64/boot/dts/mediatek/Makefile
> index af362a085a02..72fd683c9264 100644
> --- a/arch/arm64/boot/dts/mediatek/Makefile
> +++ b/arch/arm64/boot/dts/mediatek/Makefile
> @@ -3,6 +3,7 @@ dtb-$(CONFIG_ARCH_MEDIATEK) += mt2712-evb.dtb
>  dtb-$(CONFIG_ARCH_MEDIATEK) += mt6755-evb.dtb
>  dtb-$(CONFIG_ARCH_MEDIATEK) += mt6779-evb.dtb
>  dtb-$(CONFIG_ARCH_MEDIATEK) += mt6795-evb.dtb
> +dtb-$(CONFIG_ARCH_MEDIATEK) += mt6795-sony-xperia-m5.dtb
-holly.dtb?

>  dtb-$(CONFIG_ARCH_MEDIATEK) += mt6797-evb.dtb
>  dtb-$(CONFIG_ARCH_MEDIATEK) += mt6797-x20-dev.dtb
>  dtb-$(CONFIG_ARCH_MEDIATEK) += mt7622-rfb1.dtb
> diff --git a/arch/arm64/boot/dts/mediatek/mt6795-sony-xperia-m5.dts b/arch/arm64/boot/dts/mediatek/mt6795-sony-xperia-m5.dts
> new file mode 100644
> index 000000000000..94d011c4126c
> --- /dev/null
> +++ b/arch/arm64/boot/dts/mediatek/mt6795-sony-xperia-m5.dts
> @@ -0,0 +1,90 @@
> +// SPDX-License-Identifier: GPL-2.0-only
> +/*
> + * Copyright (c) 2022, Collabora Ltd
> + * Author: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
> + */
> +
> +/dts-v1/;
> +#include "mt6795.dtsi"
> +
> +#include <dt-bindings/gpio/gpio.h>
Looks unused.

> +
> +/ {
> +	model = "Sony Xperia M5";
> +	compatible = "sony,xperia-m5", "mediatek,mt6795";
sony,holly?

> +	chassis-type = "handset";
> +
> +	aliases {
> +		mmc0 = &mmc0;
> +		mmc1 = &mmc1;
> +		serial0 = &uart0;
> +		serial1 = &uart1;
> +	};
> +
> +	memory@40000000 {
> +		device_type = "memory";
> +		reg = <0 0x40000000 0 0x1E800000>;
Lowercase hex in size. Also, doesn't the bootloader fill it in?

> +	};
> +
> +	reserved_memory: reserved-memory {
> +		#address-cells = <2>;
> +		#size-cells = <2>;
> +		ranges;
> +
> +		/* 128 KiB reserved for ARM Trusted Firmware (BL31) */
Is that true for all devices with this SoC, or..? If so, it may be worth
moving this into mt6795.dtsi.

> +		bl31_secmon_reserved: secmon@43000000 {
memory@, everywhere. Use labels to name the nodes.

> +			no-map;
reg goes first.
> +			reg = <0 0x43000000 0 0x30000>;
> +		};
> +
> +		/* preloader and bootloader regions cannot be touched */
> +		preloader-region@44800000 {
> +			no-map;
> +			reg = <0 0x44800000 0 0x100000>;
> +		};
> +
> +		bootloader-region@46000000 {
> +			no-map;
> +			reg = <0 0x46000000 0 0x400000>;
> +		};
> +	};
> +};
> +
> +&pio {
> +	uart0_pins: uart0-pins {
> +		pins-rx {
> +			pinmux = <PINMUX_GPIO113__FUNC_URXD0>;
> +			bias-pull-up;
> +			input-enable;
> +		};
> +		pins-tx {
> +			pinmux = <PINMUX_GPIO114__FUNC_UTXD0>;
> +			output-high;
> +		};
> +	};
> +
> +	uart2_pins: uart2-pins {
> +		pins-rx {
> +			pinmux = <PINMUX_GPIO31__FUNC_URXD2>;
> +			bias-pull-up;
> +			input-enable;
> +		};
> +		pins-tx {
> +			pinmux = <PINMUX_GPIO32__FUNC_UTXD2>;
> +		};
> +	};
> +};
> +
> +&uart0 {
> +	status = "okay";
Status last here and below, please.

Konrad
> +
> +	pinctrl-names = "default";
> +	pinctrl-0 = <&uart0_pins>;
> +};
> +
> +&uart2 {
> +	status = "okay";
> +
> +	pinctrl-names = "default";
> +	pinctrl-0 = <&uart2_pins>;
> +};
> 

WARNING: multiple messages have this Message-ID (diff)
From: Konrad Dybcio <konrad.dybcio@somainline.org>
To: AngeloGioacchino Del Regno
	<angelogioacchino.delregno@collabora.com>,
	robh+dt@kernel.org
Cc: krzysztof.kozlowski+dt@linaro.org, vkoul@kernel.org,
	chaotian.jing@mediatek.com, ulf.hansson@linaro.org,
	matthias.bgg@gmail.com, hsinyi@chromium.org,
	nfraprado@collabora.com, allen-kh.cheng@mediatek.com,
	fparent@baylibre.com, sam.shih@mediatek.com,
	sean.wang@mediatek.com, long.cheng@mediatek.com,
	wenbin.mei@mediatek.com, devicetree@vger.kernel.org,
	linux-kernel@vger.kernel.org, dmaengine@vger.kernel.org,
	linux-mmc@vger.kernel.org, linux-arm-kernel@lists.infradead.org,
	linux-mediatek@lists.infradead.org, phone-devel@vger.kernel.org,
	~postmarketos/upstreaming@lists.sr.ht
Subject: Re: [PATCH 7/7] arm64: dts: mediatek: Add support for MT6795 Sony Xperia M5 smartphone
Date: Fri, 29 Jul 2022 14:00:02 +0200	[thread overview]
Message-ID: <a8fa9e22-8c3f-60b2-a0db-01cfd5c37765@somainline.org> (raw)
In-Reply-To: <20220729104441.39177-8-angelogioacchino.delregno@collabora.com>



On 29.07.2022 12:44, AngeloGioacchino Del Regno wrote:
> Add a basic support for the Sony Xperia M5 (codename "Holly")
> smartphone, powered by a MediaTek Helio X10 SoC.
> 
> This achieves a console boot.
> 
> Signed-off-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
> ---
>  arch/arm64/boot/dts/mediatek/Makefile         |  1 +
>  .../dts/mediatek/mt6795-sony-xperia-m5.dts    | 90 +++++++++++++++++++
>  2 files changed, 91 insertions(+)
>  create mode 100644 arch/arm64/boot/dts/mediatek/mt6795-sony-xperia-m5.dts
> 
> diff --git a/arch/arm64/boot/dts/mediatek/Makefile b/arch/arm64/boot/dts/mediatek/Makefile
> index af362a085a02..72fd683c9264 100644
> --- a/arch/arm64/boot/dts/mediatek/Makefile
> +++ b/arch/arm64/boot/dts/mediatek/Makefile
> @@ -3,6 +3,7 @@ dtb-$(CONFIG_ARCH_MEDIATEK) += mt2712-evb.dtb
>  dtb-$(CONFIG_ARCH_MEDIATEK) += mt6755-evb.dtb
>  dtb-$(CONFIG_ARCH_MEDIATEK) += mt6779-evb.dtb
>  dtb-$(CONFIG_ARCH_MEDIATEK) += mt6795-evb.dtb
> +dtb-$(CONFIG_ARCH_MEDIATEK) += mt6795-sony-xperia-m5.dtb
-holly.dtb?

>  dtb-$(CONFIG_ARCH_MEDIATEK) += mt6797-evb.dtb
>  dtb-$(CONFIG_ARCH_MEDIATEK) += mt6797-x20-dev.dtb
>  dtb-$(CONFIG_ARCH_MEDIATEK) += mt7622-rfb1.dtb
> diff --git a/arch/arm64/boot/dts/mediatek/mt6795-sony-xperia-m5.dts b/arch/arm64/boot/dts/mediatek/mt6795-sony-xperia-m5.dts
> new file mode 100644
> index 000000000000..94d011c4126c
> --- /dev/null
> +++ b/arch/arm64/boot/dts/mediatek/mt6795-sony-xperia-m5.dts
> @@ -0,0 +1,90 @@
> +// SPDX-License-Identifier: GPL-2.0-only
> +/*
> + * Copyright (c) 2022, Collabora Ltd
> + * Author: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
> + */
> +
> +/dts-v1/;
> +#include "mt6795.dtsi"
> +
> +#include <dt-bindings/gpio/gpio.h>
Looks unused.

> +
> +/ {
> +	model = "Sony Xperia M5";
> +	compatible = "sony,xperia-m5", "mediatek,mt6795";
sony,holly?

> +	chassis-type = "handset";
> +
> +	aliases {
> +		mmc0 = &mmc0;
> +		mmc1 = &mmc1;
> +		serial0 = &uart0;
> +		serial1 = &uart1;
> +	};
> +
> +	memory@40000000 {
> +		device_type = "memory";
> +		reg = <0 0x40000000 0 0x1E800000>;
Lowercase hex in size. Also, doesn't the bootloader fill it in?

> +	};
> +
> +	reserved_memory: reserved-memory {
> +		#address-cells = <2>;
> +		#size-cells = <2>;
> +		ranges;
> +
> +		/* 128 KiB reserved for ARM Trusted Firmware (BL31) */
Is that true for all devices with this SoC, or..? If so, it may be worth
moving this into mt6795.dtsi.

> +		bl31_secmon_reserved: secmon@43000000 {
memory@, everywhere. Use labels to name the nodes.

> +			no-map;
reg goes first.
> +			reg = <0 0x43000000 0 0x30000>;
> +		};
> +
> +		/* preloader and bootloader regions cannot be touched */
> +		preloader-region@44800000 {
> +			no-map;
> +			reg = <0 0x44800000 0 0x100000>;
> +		};
> +
> +		bootloader-region@46000000 {
> +			no-map;
> +			reg = <0 0x46000000 0 0x400000>;
> +		};
> +	};
> +};
> +
> +&pio {
> +	uart0_pins: uart0-pins {
> +		pins-rx {
> +			pinmux = <PINMUX_GPIO113__FUNC_URXD0>;
> +			bias-pull-up;
> +			input-enable;
> +		};
> +		pins-tx {
> +			pinmux = <PINMUX_GPIO114__FUNC_UTXD0>;
> +			output-high;
> +		};
> +	};
> +
> +	uart2_pins: uart2-pins {
> +		pins-rx {
> +			pinmux = <PINMUX_GPIO31__FUNC_URXD2>;
> +			bias-pull-up;
> +			input-enable;
> +		};
> +		pins-tx {
> +			pinmux = <PINMUX_GPIO32__FUNC_UTXD2>;
> +		};
> +	};
> +};
> +
> +&uart0 {
> +	status = "okay";
Status last here and below, please.

Konrad
> +
> +	pinctrl-names = "default";
> +	pinctrl-0 = <&uart0_pins>;
> +};
> +
> +&uart2 {
> +	status = "okay";
> +
> +	pinctrl-names = "default";
> +	pinctrl-0 = <&uart2_pins>;
> +};
> 

_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel

  reply	other threads:[~2022-07-29 12:09 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-07-29 10:44 [PATCH 0/8] MT6795 Devicetrees and Sony Xperia M5 AngeloGioacchino Del Regno
2022-07-29 10:44 ` AngeloGioacchino Del Regno
2022-07-29 10:44 ` [PATCH 1/8] dt-bindings: dma: mediatek,uart-dma: Add binding for MT6795 SoC AngeloGioacchino Del Regno
2022-07-29 10:44   ` AngeloGioacchino Del Regno
2022-08-02  7:34   ` Krzysztof Kozlowski
2022-08-02  7:34     ` Krzysztof Kozlowski
2022-09-04 17:26   ` Vinod Koul
2022-09-04 17:26     ` Vinod Koul
2022-07-29 10:44 ` [PATCH 2/8] dt-bindings: mmc: Add compatible for MT6795 Helio X10 SoC AngeloGioacchino Del Regno
2022-07-29 10:44   ` AngeloGioacchino Del Regno
2022-07-29 23:05   ` Rob Herring
2022-07-29 23:05     ` Rob Herring
2022-08-15 18:28   ` Ulf Hansson
2022-08-15 18:28     ` Ulf Hansson
2022-07-29 10:44 ` [PATCH 3/8] arm64: dts: mediatek: mt6795: Add topckgen, infra, peri clocks/resets AngeloGioacchino Del Regno
2022-07-29 10:44   ` AngeloGioacchino Del Regno
2022-07-29 10:44 ` [PATCH 4/8] arm64: dts: mediatek: mt6795: Replace UART dummy clocks with pericfg AngeloGioacchino Del Regno
2022-07-29 10:44   ` AngeloGioacchino Del Regno
2022-07-29 10:44 ` [PATCH 5/8] arm64: dts: mediatek: mt6795: Add support for APDMA and wire up UART DMAs AngeloGioacchino Del Regno
2022-07-29 10:44   ` AngeloGioacchino Del Regno
2022-07-29 10:44 ` [PATCH 6/8] arm64: dts: mediatek: mt6795: Add support for eMMC/SD/SDIO controllers AngeloGioacchino Del Regno
2022-07-29 10:44   ` AngeloGioacchino Del Regno
2022-07-29 10:44 ` [PATCH 7/7] arm64: dts: mediatek: Add support for MT6795 Sony Xperia M5 smartphone AngeloGioacchino Del Regno
2022-07-29 10:44   ` AngeloGioacchino Del Regno
2022-07-29 12:00   ` Konrad Dybcio [this message]
2022-07-29 12:00     ` Konrad Dybcio
2022-10-27  9:28     ` AngeloGioacchino Del Regno
2022-10-27  9:28       ` AngeloGioacchino Del Regno
2022-10-27  9:40       ` Konrad Dybcio
2022-10-27  9:40         ` Konrad Dybcio
2022-10-27 10:01         ` AngeloGioacchino Del Regno
2022-10-27 10:01           ` AngeloGioacchino Del Regno
2022-07-29 10:44 ` [PATCH 7/8] dt-bindings: arm: mediatek: Add compatible for MT6795 Sony Xperia M5 AngeloGioacchino Del Regno
2022-07-29 10:44   ` AngeloGioacchino Del Regno
2022-07-29 23:05   ` Rob Herring
2022-07-29 23:05     ` Rob Herring
2022-07-29 10:44 ` [PATCH 8/8] arm64: dts: mediatek: Add support for MT6795 Sony Xperia M5 smartphone AngeloGioacchino Del Regno
2022-07-29 10:44   ` AngeloGioacchino Del Regno

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=a8fa9e22-8c3f-60b2-a0db-01cfd5c37765@somainline.org \
    --to=konrad.dybcio@somainline.org \
    --cc=allen-kh.cheng@mediatek.com \
    --cc=angelogioacchino.delregno@collabora.com \
    --cc=chaotian.jing@mediatek.com \
    --cc=devicetree@vger.kernel.org \
    --cc=dmaengine@vger.kernel.org \
    --cc=fparent@baylibre.com \
    --cc=hsinyi@chromium.org \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mediatek@lists.infradead.org \
    --cc=linux-mmc@vger.kernel.org \
    --cc=long.cheng@mediatek.com \
    --cc=matthias.bgg@gmail.com \
    --cc=nfraprado@collabora.com \
    --cc=phone-devel@vger.kernel.org \
    --cc=robh+dt@kernel.org \
    --cc=sam.shih@mediatek.com \
    --cc=sean.wang@mediatek.com \
    --cc=ulf.hansson@linaro.org \
    --cc=vkoul@kernel.org \
    --cc=wenbin.mei@mediatek.com \
    --cc=~postmarketos/upstreaming@lists.sr.ht \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.