[RFC 0/8] mm/damon: implement DAMOS apply intervals

2023-09-09 Thread SeongJae Park
DAMON-based operation schemes are applied for every aggregation interval. That is mainly because schemes are using nr_accesses, which be complete to be used for every aggregation interval. However, DAMON provides nr_accesses_bp, which is updated for each sampling interval in a way that reasonable

[PATCH v5 08/17] arm64: mm: Add dynamic ramoops region support through command line

2023-09-09 Thread Mukesh Ojha
The reserved memory region for ramoops is assumed to be at a fixed and known location when read from the devicetree. This may not be required for something like Qualcomm's minidump which is interested in knowing addresses of ramoops region but it does not put hard requirement of address being fixed

[PATCH v5 10/17] pstore: Add pstore_region_defined() helper and export it

2023-09-09 Thread Mukesh Ojha
There are users like Qualcomm minidump which is interested in knowing the pstore frontend addresses and sizes from the backend (ram) to be able to register it with firmware to finally collect them during crash for debugging. Signed-off-by: Mukesh Ojha --- fs/pstore/platform.c | 15

[PATCH v5 11/17] qcom_minidump: Register ramoops region with minidump

2023-09-09 Thread Mukesh Ojha
Register all the pstore frontend with minidump, so that they can be dumped as default Linux minidump region to be collected on SoC where minidump is enabled. Helper functions is written in separate file and built along with the minidump driver, since it is client of minidump and also call it at ap

[PATCH v5 15/17] firmware: scm: Modify only the download bits in TCSR register

2023-09-09 Thread Mukesh Ojha
Crashdump collection is based on the DLOAD bit of TCSR register. To retain other bits, we read the register and modify only the DLOAD bit as the other bits have their own significance. Co-developed-by: Poovendhan Selvaraj Signed-off-by: Mukesh Ojha --- drivers/firmware/qcom_scm.c | 12 +

[PATCH v5 17/17] firmware: qcom_scm: Add multiple download mode support

2023-09-09 Thread Mukesh Ojha
Currently, scm driver only supports full dump when download mode is selected. Add support to enable minidump as well as enable it along with fulldump. Signed-off-by: Mukesh Ojha --- drivers/firmware/qcom_scm.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/firmw

[PATCH v5 16/17] firmware: qcom_scm: Refactor code to support multiple download mode

2023-09-09 Thread Mukesh Ojha
Currently on Qualcomm SoC, download_mode is enabled if CONFIG_QCOM_SCM_DOWNLOAD_MODE_DEFAULT is selected. Refactor the code such that it supports multiple download modes and drop CONFIG_QCOM_SCM_DOWNLOAD_MODE_DEFAULT config instead, give interface to set the download mode from module parameter. S

[PATCH v5 12/17] MAINTAINERS: Add entry for minidump related files

2023-09-09 Thread Mukesh Ojha
Add the entries into maintainer file for all the minidump related modules. Signed-off-by: Mukesh Ojha --- MAINTAINERS | 10 ++ 1 file changed, 10 insertions(+) diff --git a/MAINTAINERS b/MAINTAINERS index d590ce31aa72..0595176e76fb 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -17640,6

[PATCH v5 13/17] firmware: qcom_scm: provide a read-modify-write function

2023-09-09 Thread Mukesh Ojha
It was realized by Srinivas K. that there is a need of read-modify-write scm exported function so that it can be used by multiple clients. Let's introduce qcom_scm_io_update_field() which masks out the bits and write the passed value to that bit-offset. Subsequent patch will use this function. Su

[PATCH v5 14/17] pinctrl: qcom: Use qcom_scm_io_update_field()

2023-09-09 Thread Mukesh Ojha
Use qcom_scm_io_update_field() exported function in pinctrl-msm driver. Signed-off-by: Mukesh Ojha --- drivers/pinctrl/qcom/pinctrl-msm.c | 10 -- 1 file changed, 4 insertions(+), 6 deletions(-) diff --git a/drivers/pinctrl/qcom/pinctrl-msm.c b/drivers/pinctrl/qcom/pinctrl-msm.c index

[PATCH v5 09/17] pstore/ram: Use dynamic ramoops reserve resource

2023-09-09 Thread Mukesh Ojha
As dynamic ramoops command line parsing is now added, so lets add the support in ramoops driver to get the resource structure and add it during platform device registration. Signed-off-by: Mukesh Ojha --- fs/pstore/ram.c | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff --gi

[PATCH v5 06/17] soc: qcom: Add Qualcomm APSS minidump kernel driver

2023-09-09 Thread Mukesh Ojha
Minidump is a best effort mechanism to collect useful and predefined data for first level of debugging on end user devices running on Qualcomm SoCs. It is built on the premise that System on Chip (SoC) or subsystem part of SoC crashes, due to a range of hardware and software bugs. Hence, the abilit

[PATCH v5 07/17] soc: qcom: minidump: Add pending region registration

2023-09-09 Thread Mukesh Ojha
Pending regions are those apss minidump regions which came for registration before minidump was initialized or ready to do register the region. We can add regions to pending region list and register all of them from apss minidump driver probe in one go. Signed-off-by: Mukesh Ojha --- drivers/so

[PATCH v5 04/17] remoteproc: qcom: Remove minidump related data from qcom_common.c

2023-09-09 Thread Mukesh Ojha
As minidump specific data structure and functions move under config QCOM_RPROC_MINIDUMP, so remove minidump specific data from driver/remoteproc/qcom_common.c . Signed-off-by: Mukesh Ojha --- drivers/remoteproc/qcom_common.c | 150 --- 1 file changed, 150 dele

[PATCH v5 05/17] init: export linux_banner data variable

2023-09-09 Thread Mukesh Ojha
Some debug loadable module like minidump is interested in knowing the kernel version against which it is being build. Let's export linux_banner. Signed-off-by: Mukesh Ojha --- include/linux/init.h | 3 +++ init/version-timestamp.c | 3 +++ 2 files changed, 6 insertions(+) diff --git a/inclu

[PATCH v5 01/17] docs: qcom: Add qualcomm minidump guide

2023-09-09 Thread Mukesh Ojha
Add the qualcomm minidump guide for the users which tries to cover the dependency, API use and the way to test and collect minidump on Qualcomm supported SoCs. Signed-off-by: Mukesh Ojha --- Documentation/admin-guide/index.rst | 1 + Documentation/admin-guide/qcom_minidump.rst | 272 ++

[PATCH v5 02/17] soc: qcom: Add qcom_rproc_minidump module

2023-09-09 Thread Mukesh Ojha
Add qcom_rproc_minidump module in a preparation to remove minidump specific code from driver/remoteproc/qcom_common.c and provide needed exported API, this as well helps to abstract minidump specific data layout from qualcomm's remoteproc driver. It is just a copying of qcom_minidump() functionali

[PATCH v5 00/17] Add Qualcomm Minidump kernel driver related support

2023-09-09 Thread Mukesh Ojha
Hi All, This is to continuation from the conversation happened at v4 https://lore.kernel.org/lkml/632c5b97-4a91-c3e8-1e6c-33d6c4f64...@quicinc.com/ https://lore.kernel.org/lkml/695133e6-105f-de2a-5559-555cea0a0...@quicinc.com/ We have put abstract on LPC on this topic as well as initiated a mai

[PATCH v5 03/17] remoteproc: qcom_q6v5_pas: Use qcom_rproc_minidump()

2023-09-09 Thread Mukesh Ojha
Now, as all the minidump specific data structure is moved to minidump specific files and implementation wise qcom_rproc_minidump() and qcom_minidump() exactly same and the name qcom_rproc_minidump make more sense as it happen to collect the minidump for the remoteproc processors. So, let's use qcom