arch/arm64/boot/dts/qcom/sdm845-lg-common.dtsi | 31 ++++++++++++++++++++++++++ 1 file changed, 31 insertions(+)
Add the i2c and tlmm nodes to support the NXP PN547 NFC chip
Downstream dtsi for reference:
https://github.com/LineageOS/android_kernel_lge_sdm845/blob/lineage-22.2/arch/arm64/boot/dts/lge/sdm845-judy/sdm845-judyln_lao_com/sdm845-judyln_lao_com-nfc.dtsi
Signed-off-by: Paul Sajna <sajattack@postmarketos.org>
---
Changes in v2:
- correct drive-strength
- add gpio116
- Link to v1: https://lore.kernel.org/r/20260902-sdm845-lg-judy-nfc-v1-1-282173900569@postmarketos.org
---
arch/arm64/boot/dts/qcom/sdm845-lg-common.dtsi | 31 ++++++++++++++++++++++++++
1 file changed, 31 insertions(+)
diff --git a/arch/arm64/boot/dts/qcom/sdm845-lg-common.dtsi b/arch/arm64/boot/dts/qcom/sdm845-lg-common.dtsi
index b030a10009c5..c77da1b0d57d 100644
--- a/arch/arm64/boot/dts/qcom/sdm845-lg-common.dtsi
+++ b/arch/arm64/boot/dts/qcom/sdm845-lg-common.dtsi
@@ -471,6 +471,25 @@ &gpu {
status = "okay";
};
+&i2c3 {
+ clock-frequency = <1000000>;
+
+ status = "okay";
+
+ nfc@28 {
+ compatible = "nxp,pn547", "nxp,nxp-nci-i2c";
+ reg = <0x28>;
+
+ interrupts-extended = <&tlmm 63 IRQ_TYPE_EDGE_RISING>;
+
+ enable-gpios = <&tlmm 12 GPIO_ACTIVE_HIGH>;
+ firmware-gpios = <&tlmm 62 GPIO_ACTIVE_HIGH>;
+
+ pinctrl-0 = <&nfc_default>;
+ pinctrl-names = "default";
+ };
+};
+
&ipa {
status = "okay";
};
@@ -551,6 +570,11 @@ &qupv3_id_1 {
status = "okay";
};
+&qup_i2c3_default {
+ drive-strength = <2>;
+ bias-disable;
+};
+
&qup_uart9_rx {
drive-strength = <2>;
bias-pull-up;
@@ -609,6 +633,13 @@ sd_card_det_n: sd-card-det-n-state {
function = "gpio";
bias-pull-up;
};
+
+ nfc_default: nfc-default-state {
+ pins = "gpio12", "gpio62", "gpio63", "gpio116";
+ function = "gpio";
+ drive-strength = <2>;
+ bias-pull-up;
+ };
};
&uart6 {
---
base-commit: 32b6ef9a5d0eca44f9cd91f52f4faa89f145a0de
change-id: 20260902-sdm845-lg-judy-nfc-5f9e5775393d
Best regards,
--
Paul Sajna <sajattack@postmarketos.org>
On 06/09/2026 23:11, Paul Sajna wrote:
> Add the i2c and tlmm nodes to support the NXP PN547 NFC chip
>
> Downstream dtsi for reference:
> https://github.com/LineageOS/android_kernel_lge_sdm845/blob/lineage-22.2/arch/arm64/boot/dts/lge/sdm845-judy/sdm845-judyln_lao_com/sdm845-judyln_lao_com-nfc.dtsi
>
> Signed-off-by: Paul Sajna <sajattack@postmarketos.org>
> ---
> Changes in v2:
> - correct drive-strength
> - add gpio116
> - Link to v1: https://lore.kernel.org/r/20260902-sdm845-lg-judy-nfc-v1-1-282173900569@postmarketos.org
> ---
> arch/arm64/boot/dts/qcom/sdm845-lg-common.dtsi | 31 ++++++++++++++++++++++++++
> 1 file changed, 31 insertions(+)
>
> diff --git a/arch/arm64/boot/dts/qcom/sdm845-lg-common.dtsi b/arch/arm64/boot/dts/qcom/sdm845-lg-common.dtsi
> index b030a10009c5..c77da1b0d57d 100644
> --- a/arch/arm64/boot/dts/qcom/sdm845-lg-common.dtsi
> +++ b/arch/arm64/boot/dts/qcom/sdm845-lg-common.dtsi
> @@ -471,6 +471,25 @@ &gpu {
> status = "okay";
> };
>
> +&i2c3 {
> + clock-frequency = <1000000>;
> +
> + status = "okay";
> +
> + nfc@28 {
> + compatible = "nxp,pn547", "nxp,nxp-nci-i2c";
> + reg = <0x28>;
> +
> + interrupts-extended = <&tlmm 63 IRQ_TYPE_EDGE_RISING>;
> +
> + enable-gpios = <&tlmm 12 GPIO_ACTIVE_HIGH>;
> + firmware-gpios = <&tlmm 62 GPIO_ACTIVE_HIGH>;
> +
> + pinctrl-0 = <&nfc_default>;
> + pinctrl-names = "default";
> + };
> +};
> +
> &ipa {
> status = "okay";
> };
> @@ -551,6 +570,11 @@ &qupv3_id_1 {
> status = "okay";
> };
>
> +&qup_i2c3_default {
> + drive-strength = <2>;
> + bias-disable;
> +};
> +
> &qup_uart9_rx {
> drive-strength = <2>;
> bias-pull-up;
> @@ -609,6 +633,13 @@ sd_card_det_n: sd-card-det-n-state {
> function = "gpio";
> bias-pull-up;
> };
> +
> + nfc_default: nfc-default-state {
> + pins = "gpio12", "gpio62", "gpio63", "gpio116";
here the verbosity may not be bad (device-tree functions as documentation too)
gpio116 is associated with eSE NFC part (just guessing, but... it worked before,
so), and generally the pn547 doesn't need it at all to work.
TBH not sure if there or what consensus is here about this. The eSE needs it,
but we don't have the driver thus also no integration with NFC part.
David
> + function = "gpio";
> + drive-strength = <2>;
> + bias-pull-up;
> + };
> };
>
> &uart6 {
>
> ---
> base-commit: 32b6ef9a5d0eca44f9cd91f52f4faa89f145a0de
> change-id: 20260902-sdm845-lg-judy-nfc-5f9e5775393d
>
> Best regards,
On 9/6/26 11:32 PM, David Heidelberg wrote:
> On 06/09/2026 23:11, Paul Sajna wrote:
>> Add the i2c and tlmm nodes to support the NXP PN547 NFC chip
>>
>> Downstream dtsi for reference:
>> https://github.com/LineageOS/android_kernel_lge_sdm845/blob/lineage-22.2/arch/arm64/boot/dts/lge/sdm845-judy/sdm845-judyln_lao_com/sdm845-judyln_lao_com-nfc.dtsi
>>
>> Signed-off-by: Paul Sajna <sajattack@postmarketos.org>
>> ---
[...]
>> + nfc_default: nfc-default-state {
>> + pins = "gpio12", "gpio62", "gpio63", "gpio116";
>
> here the verbosity may not be bad (device-tree functions as documentation too)
> gpio116 is associated with eSE NFC part (just guessing, but... it worked before, so), and generally the pn547 doesn't need it at all to work.
>
> TBH not sure if there or what consensus is here about this. The eSE needs it, but we don't have the driver thus also no integration with NFC part.
The eSE driver would still be acting on the NFC node, right?
Konrad
On 09/09/2026 15:16, Konrad Dybcio wrote:
> On 9/6/26 11:32 PM, David Heidelberg wrote:
>> On 06/09/2026 23:11, Paul Sajna wrote:
>>> Add the i2c and tlmm nodes to support the NXP PN547 NFC chip
>>>
>>> Downstream dtsi for reference:
>>> https://github.com/LineageOS/android_kernel_lge_sdm845/blob/lineage-22.2/arch/arm64/boot/dts/lge/sdm845-judy/sdm845-judyln_lao_com/sdm845-judyln_lao_com-nfc.dtsi
>>>
>>> Signed-off-by: Paul Sajna <sajattack@postmarketos.org>
>>> ---
>
> [...]
>
>>> + nfc_default: nfc-default-state {
>>> + pins = "gpio12", "gpio62", "gpio63", "gpio116";
>>
>> here the verbosity may not be bad (device-tree functions as documentation too)
>> gpio116 is associated with eSE NFC part (just guessing, but... it worked before, so), and generally the pn547 doesn't need it at all to work.
>>
>> TBH not sure if there or what consensus is here about this. The eSE needs it, but we don't have the driver thus also no integration with NFC part.
>
> The eSE driver would still be acting on the NFC node, right?
So far that's the Android design. So, yes.
David
>
> Konrad
© 2016 - 2026 Red Hat, Inc.