arm64: dts: qcom: sc7180-trogdor: Split out keyboard node and describe detachables
Subsystems (4)
PATCH v2 1/1 arm64: dts: qcom: sc7180-trogdor: Split out keyboard node and describe detachables
Trogdor devices that have a detachable keyboard still have a non-detachable keyboard input device present because we include the cros-ec-keyboard.dtsi snippet in the top-level sc7180-trogdor.dtsi file that every variant board includes. We do this because the keyboard-controller node also provides some buttons like the power button and volume buttons. Unfortunately, this means we register a keyboard input device that doesn't do anything on boards with a detachable keyboard.
Change the node's compatible on detachables to the newly introduced "google,cros-ec-keyb-switches" compatible to indicate that there are only switches and no keyboard to register. Similarly, move the keyboard include that defines the keyboard-controller node out of sc7180-trogdor.dtsi to boards that actually have a keyboard so that the matrix properties are not defined on boards with the switches compatible. Future boards can either use the include approach or the node definition approach to describe a keyboard with possible switches or just some switches.
---
Changes from v1 (https://lore.kernel.org/r/[email protected]):
* Rebased onto Joe's series applied on top of qcom's arm64-fixes-for-4.19
* Updated more dtsi files
arch/arm64/boot/dts/qcom/sc7180-trogdor-coachz.dtsi | 4 ++++ arch/arm64/boot/dts/qcom/sc7180-trogdor-homestar.dtsi | 6 ++++++ arch/arm64/boot/dts/qcom/sc7180-trogdor-kingoftown.dtsi | 2 +- arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor.dtsi | 1 + arch/arm64/boot/dts/qcom/sc7180-trogdor-mrbland.dtsi | 6 ++++++ arch/arm64/boot/dts/qcom/sc7180-trogdor-pazquel.dtsi | 1 + arch/arm64/boot/dts/qcom/sc7180-trogdor-pompom.dtsi | 2 ++ arch/arm64/boot/dts/qcom/sc7180-trogdor-quackingstick.dtsi | 6 ++++++ arch/arm64/boot/dts/qcom/sc7180-trogdor-r1.dts | 2 ++ arch/arm64/boot/dts/qcom/sc7180-trogdor-wormdingler.dtsi | 4 ++++ arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi | 1 - 11 files changed, 33 insertions(+), 2 deletions(-)
arch/arm64/boot/dts/qcom/sc7180-trogdor-coachz.dtsi +4 -0
@@ -81,6 +81,10 @@ &camcc { }; &cros_ec { + keyboard-controller { + compatible = "google,cros-ec-keyb-switches"; + }; + cros_ec_proximity: proximity { compatible = "google,cros-ec-mkbp-proximity"; label = "proximity-wifi";
arch/arm64/boot/dts/qcom/sc7180-trogdor-homestar.dtsi +6 -0
@@ -114,6 +114,12 @@ &camcc { status = "okay"; }; +&cros_ec { + keyboard-controller { + compatible = "google,cros-ec-keyb-switches"; + }; +}; + &panel { compatible = "samsung,atna33xc20"; enable-gpios = <&tlmm 12 GPIO_ACTIVE_HIGH>;
arch/arm64/boot/dts/qcom/sc7180-trogdor-kingoftown.dtsi +1 -1
@@ -6,7 +6,7 @@ */ /* This file must be included after sc7180-trogdor.dtsi */ - +#include <arm/cros-ec-keyboard.dtsi> #include "sc7180-trogdor-lte-sku.dtsi" &alc5682 {
arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor.dtsi +1 -0
@@ -6,6 +6,7 @@ */ /* This file must be included after sc7180-trogdor.dtsi */ +#include <arm/cros-ec-keyboard.dtsi> &ap_sar_sensor { semtech,cs0-ground;
arch/arm64/boot/dts/qcom/sc7180-trogdor-mrbland.dtsi +6 -0
@@ -58,6 +58,12 @@ &camcc { status = "okay"; }; +&cros_ec { + keyboard-controller { + compatible = "google,cros-ec-keyb-switches"; + }; +}; + &dsi0 { panel: panel@0 {
arch/arm64/boot/dts/qcom/sc7180-trogdor-pazquel.dtsi +1 -0
@@ -6,6 +6,7 @@ */ /* This file must be included after sc7180-trogdor.dtsi */ +#include <arm/cros-ec-keyboard.dtsi> &ap_sar_sensor { compatible = "semtech,sx9324";
arch/arm64/boot/dts/qcom/sc7180-trogdor-pompom.dtsi +2 -0
@@ -6,6 +6,8 @@ */ #include "sc7180-trogdor.dtsi" +/* Must come after sc7180-trogdor.dtsi to modify cros_ec */ +#include <arm/cros-ec-keyboard.dtsi> #include "sc7180-trogdor-ti-sn65dsi86.dtsi" / {
arch/arm64/boot/dts/qcom/sc7180-trogdor-quackingstick.dtsi +6 -0
@@ -46,6 +46,12 @@ &camcc { status = "okay"; }; +&cros_ec { + keyboard-controller { + compatible = "google,cros-ec-keyb-switches"; + }; +}; + &dsi0 { panel: panel@0 { /* Compatible will be filled in per-board */
arch/arm64/boot/dts/qcom/sc7180-trogdor-r1.dts +2 -0
@@ -8,6 +8,8 @@ /dts-v1/; #include "sc7180-trogdor.dtsi" +/* Must come after sc7180-trogdor.dtsi to modify cros_ec */ +#include <arm/cros-ec-keyboard.dtsi> #include "sc7180-trogdor-ti-sn65dsi86.dtsi" / {
arch/arm64/boot/dts/qcom/sc7180-trogdor-wormdingler.dtsi +4 -0
@@ -104,6 +104,10 @@ &cros_ec { base_detection: cbas { compatible = "google,cros-cbas"; }; + + keyboard-controller { + compatible = "google,cros-ec-keyb-switches"; + }; }; &dsi0 {
arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi +0 -1
@@ -903,7 +903,6 @@ cros_ec_fp: ec@0 { }; }; -#include <arm/cros-ec-keyboard.dtsi> #include <arm/cros-ec-sbs.dtsi> &uart3 {
base-commit: d640974d1c4ee510fcc8f05f0ddaaf9d17b47643
prerequisite-patch-id: e4e5e59ecf0e67976cbf6e54a85e5ba2018dc0ff
prerequisite-patch-id: dc0ebbff0f2ed6c8674bdebef127d7f10b7dacbf
prerequisite-patch-id: 41a558fdc22515e78b2caeb3630ecd075072eb74
prerequisite-patch-id: 90167e33f0cd4d8aa92cb6221964779de53d8cf4
prerequisite-patch-id: b7cfa974f20a01ba2121cbe61dc1c9ac70ec8442
Signature · 1 line
https://chromeos.dev
Hi,
Quoted 32 lines · Stephen Boyd
Trogdor devices that have a detachable keyboard still have a non-detachable keyboard input device present because we include the
cros-ec-keyboard.dtsisnippet in the top-levelsc7180-trogdor.dtsifile that every variant board includes. We do this because the keyboard-controller node also provides some buttons like the power button and volume buttons. Unfortunately, this means we register a keyboard input device that doesn't do anything on boards with a detachable keyboard.Change the node's compatible on detachables to the newly introduced "google,cros-ec-keyb-switches" compatible to indicate that there are only switches and no keyboard to register. Similarly, move the keyboard include that defines the keyboard-controller node out of
sc7180-trogdor.dtsito boards that actually have a keyboard so that the matrix properties are not defined on boards with the switches compatible. Future boards can either use the include approach or the node definition approach to describe a keyboard with possible switches or just some switches.Cc Benson Leung <[email protected]>Cc Guenter Roeck <[email protected]>Cc Douglas Anderson <[email protected]>Cc Hsin-Yi Wang <[email protected]>Cc "Joseph S. Barrera III" <[email protected]>Signed-off-by Stephen Boyd <[email protected]>---
Changes from v1 (https://lore.kernel.org/r/[email protected]):
* Rebased onto Joe's series applied on top of qcom's arm64-fixes-for-4.19
* Updated more dtsi files
Quoted 12 lines
arch/arm64/boot/dts/qcom/sc7180-trogdor-coachz.dtsi | 4 ++++ arch/arm64/boot/dts/qcom/sc7180-trogdor-homestar.dtsi | 6 ++++++ arch/arm64/boot/dts/qcom/sc7180-trogdor-kingoftown.dtsi | 2 +- arch/arm64/boot/dts/qcom/sc7180-trogdor-lazor.dtsi | 1 + arch/arm64/boot/dts/qcom/sc7180-trogdor-mrbland.dtsi | 6 ++++++ arch/arm64/boot/dts/qcom/sc7180-trogdor-pazquel.dtsi | 1 + arch/arm64/boot/dts/qcom/sc7180-trogdor-pompom.dtsi | 2 ++ arch/arm64/boot/dts/qcom/sc7180-trogdor-quackingstick.dtsi | 6 ++++++ arch/arm64/boot/dts/qcom/sc7180-trogdor-r1.dts | 2 ++ arch/arm64/boot/dts/qcom/sc7180-trogdor-wormdingler.dtsi | 4 ++++ arch/arm64/boot/dts/qcom/sc7180-trogdor.dtsi | 1 - 11 files changed, 33 insertions(+), 2 deletions(-)
Bjorn Andersson
AppliedRe: (subset) [PATCH v2] arm64: dts: qcom: sc7180-trogdor: Split out keyboard node and describe detachables
In reply to Stephen BoydQuoted 10 lines · Stephen Boyd
Trogdor devices that have a detachable keyboard still have a non-detachable keyboard input device present because we include the
cros-ec-keyboard.dtsisnippet in the top-levelsc7180-trogdor.dtsifile that every variant board includes. We do this because the keyboard-controller node also provides some buttons like the power button and volume buttons. Unfortunately, this means we register a keyboard input device that doesn't do anything on boards with a detachable keyboard.[...]
Applied, thanks!
[1/1] arm64: dts: qcom: sc7180-trogdor: Split out keyboard node and describe detachables
commit: a10b760b7402563661fa305882b181a75a1d4894
Best regards,
Signature · 1 line
Bjorn Andersson <[email protected]>