Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

arm64: dts: qcom: sm8550-qrd: enable PMIC Volume and Power buttons

The Volume Down & Power buttons are controlled by the PMIC via
the PON hardware, and the Volume Up is connected to a PMIC gpio.

Enable the necessary hardware and setup the GPIO state for the
Volume Up gpio key.

Reviewed-by: Konrad Dybcio <konrad.dybcio@linaro.org>
Signed-off-by: Neil Armstrong <neil.armstrong@linaro.org>
Signed-off-by: Bjorn Andersson <andersson@kernel.org>
Link: https://lore.kernel.org/r/20230525-topic-sm8550-upstream-pm8550-lpg-dt-v4-4-a288f24af81b@linaro.org

authored by

Neil Armstrong and committed by
Bjorn Andersson
bb47bfbd a791fc19

+36
+36
arch/arm64/boot/dts/qcom/sm8550-qrd.dts
··· 54 54 stdout-path = "serial0:115200n8"; 55 55 }; 56 56 57 + gpio-keys { 58 + compatible = "gpio-keys"; 59 + 60 + pinctrl-0 = <&volume_up_n>; 61 + pinctrl-names = "default"; 62 + 63 + key-volume-up { 64 + label = "Volume Up"; 65 + linux,code = <KEY_VOLUMEUP>; 66 + gpios = <&pm8550_gpios 6 GPIO_ACTIVE_LOW>; 67 + debounce-interval = <15>; 68 + linux,can-disable; 69 + wakeup-source; 70 + }; 71 + }; 72 + 57 73 pmic-glink { 58 74 compatible = "qcom,sm8550-pmic-glink", "qcom,pmic-glink"; 59 75 #address-cells = <1>; ··· 532 516 }; 533 517 }; 534 518 519 + &pm8550_gpios { 520 + volume_up_n: volume-up-n-state { 521 + pins = "gpio6"; 522 + function = "normal"; 523 + power-source = <1>; 524 + bias-pull-up; 525 + input-enable; 526 + }; 527 + }; 528 + 535 529 &pm8550_pwm { 536 530 status = "okay"; 537 531 ··· 572 546 &pm8550b_eusb2_repeater { 573 547 vdd18-supply = <&vreg_l15b_1p8>; 574 548 vdd3-supply = <&vreg_l5b_3p1>; 549 + }; 550 + 551 + &pon_pwrkey { 552 + status = "okay"; 553 + }; 554 + 555 + &pon_resin { 556 + linux,code = <KEY_VOLUMEDOWN>; 557 + 558 + status = "okay"; 575 559 }; 576 560 577 561 &pcie_1_phy_aux_clk {