Skip to content

Commit

Permalink
arm64: dts: qcom: pmk8350: Make RTC disabled by default; enable on sc…
Browse files Browse the repository at this point in the history
…7280-idp

The RTC on the pmk8350 is not useful on all boards. Some boards may
not provide backup power to the PMIC but might have another RTC on the
board that does have backup power. In this case it's better to not use
the RTC on the PMIC.

At the moment, the only boards that includes this PMIC are sc7280-idp
and sc7280-idp2. On sc7280-idp I'm not aware of any other RTCs, but
sc7280-idp2 has a Chrome OS EC on it and this is intended to provide
the RTC for the AP.

Let's do what we normally do for hardware that's not used by all
boards and set it to a default status of "disabled" and then enable it
on the boards that need it.

NOTE: for sc7280-idp it's _possible_ we might also want to add
`allow-set-time;`. That could be the subject of a future patch if it
is indeed true.

Signed-off-by: Douglas Anderson <[email protected]>
Reviewed-by: Satya Priya <[email protected]>
Reviewed-by: Stephen Boyd <[email protected]>
Reviewed-by: Matthias Kaehlcke <[email protected]>
[bjorn: Enable the RTC on the MTP as well]
Signed-off-by: Bjorn Andersson <[email protected]>
Link: https://lore.kernel.org/r/20210929153553.1.Ib44c2ac967833d7a3f51452d44d15b7b8d23c1f0@changeid
  • Loading branch information
dianders authored and andersson committed Oct 24, 2021
1 parent 9c0bd8e commit 12a7f71
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 0 deletions.
1 change: 1 addition & 0 deletions arch/arm64/boot/dts/qcom/pmk8350.dtsi
Original file line number Diff line number Diff line change
Expand Up @@ -59,6 +59,7 @@
reg = <0x6100>, <0x6200>;
reg-names = "rtc", "alarm";
interrupts = <0x0 0x62 0x1 IRQ_TYPE_EDGE_RISING>;
status = "disabled";
};

pmk8350_gpios: gpio@b000 {
Expand Down
4 changes: 4 additions & 0 deletions arch/arm64/boot/dts/qcom/sc7280-idp.dts
Original file line number Diff line number Diff line change
Expand Up @@ -61,6 +61,10 @@
modem-init;
};

&pmk8350_rtc {
status = "okay";
};

&pmk8350_vadc {
pmr735a_die_temp {
reg = <PMR735A_ADC7_DIE_TEMP>;
Expand Down
4 changes: 4 additions & 0 deletions arch/arm64/boot/dts/qcom/sm8350-mtp.dts
Original file line number Diff line number Diff line change
Expand Up @@ -286,6 +286,10 @@
firmware-name = "qcom/sm8350/modem.mbn";
};

&pmk8350_rtc {
status = "okay";
};

&qupv3_id_0 {
status = "okay";
};
Expand Down

0 comments on commit 12a7f71

Please sign in to comment.