[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-ID: <cover.1681799201.git.quic_schowdhu@quicinc.com>
Date: Tue, 18 Apr 2023 12:16:02 +0530
From: Souradeep Chowdhury <quic_schowdhu@...cinc.com>
To: Andy Gross <agross@...nel.org>,
Konrad Dybcio <konrad.dybcio@...ainline.org>,
Krzysztof Kozlowski <krzysztof.kozlowski+dt@...aro.org>,
Bjorn Andersson <andersson@...nel.org>,
Rob Herring <robh+dt@...nel.org>
CC: <linux-arm-kernel@...ts.infradead.org>,
<linux-kernel@...r.kernel.org>, <linux-arm-msm@...r.kernel.org>,
<devicetree@...r.kernel.org>, Sibi Sankar <quic_sibis@...cinc.com>,
Rajendra Nayak <quic_rjendra@...cinc.com>,
Souradeep Chowdhury <quic_schowdhu@...cinc.com>
Subject: [PATCH V5 0/3] soc: qcom: boot_stats: Add driver support for boot_stats
Qualcomm's proprietary Android boot-loaders capture boot time
stats, like the time when the bootloader started execution and at what
point the bootloader handed over control to the kernel etc. in the IMEM
region. This information is captured in a specific format by this driver
by mapping a structure to the IMEM memory region and then accessing the
members of the structure to log the information in a debugfs file.
This information is useful in verifying if existing boot KPIs have
regressed or not.
A sample log in SM8450(waipio) device is as follows:-
/sys/kernel/debug/146aa6b0.boot_stats # cat abl_time
17898 ms
/sys/kernel/debug/146aa6b0.boot_stats # cat pre_abl_time
2879 ms
The Module Power Manager(MPM) sleep counter starts ticking at the PBL
stage and the timestamp generated by the sleep counter is logged by
the Qualcomm proprietary bootloader(ABL) at two points-> First when it
starts execution which is logged here as "pre_abl_time" and the second
when it is about to load the kernel logged as "abl_time". Both these
values are read up by the driver from IMEM region and printed as above.
Changes in V5
*Fixed the build warning in V4 of the patch.
Souradeep Chowdhury (3):
dt-bindings: sram: qcom,imem: Add Boot Stat region within IMEM
soc: qcom: boot_stat: Add Driver Support for Boot Stats
MAINTAINERS: Add the entry for boot_stats driver support
Documentation/ABI/testing/debugfs-driver-bootstat | 17 ++++
.../devicetree/bindings/sram/qcom,imem.yaml | 22 +++++
MAINTAINERS | 7 ++
drivers/soc/qcom/Kconfig | 9 ++
drivers/soc/qcom/Makefile | 1 +
drivers/soc/qcom/boot_stats.c | 101 +++++++++++++++++++++
6 files changed, 157 insertions(+)
create mode 100644 Documentation/ABI/testing/debugfs-driver-bootstat
create mode 100644 drivers/soc/qcom/boot_stats.c
--
2.7.4
Powered by blists - more mailing lists