diff mbox series

[3/3] remoteproc: qcom_q6v5_mss: Update MBA log info

Message ID 20200716123630.21892-4-sibis@codeaurora.org (mailing list archive)
State Superseded
Headers show
Series Add modem debug features | expand

Commit Message

Sibi Sankar July 16, 2020, 12:36 p.m. UTC
Update MBA text logs location/size in IMEM to aid tools extract
them after ramdump collection.

Signed-off-by: Sibi Sankar <sibis@codeaurora.org>
---
 drivers/remoteproc/qcom_q6v5_mss.c | 3 +++
 1 file changed, 3 insertions(+)

Comments

Bjorn Andersson July 17, 2020, 4:59 a.m. UTC | #1
On Thu 16 Jul 05:36 PDT 2020, Sibi Sankar wrote:

> Update MBA text logs location/size in IMEM to aid tools extract
> them after ramdump collection.
> 
> Signed-off-by: Sibi Sankar <sibis@codeaurora.org>
> ---
>  drivers/remoteproc/qcom_q6v5_mss.c | 3 +++
>  1 file changed, 3 insertions(+)
> 
> diff --git a/drivers/remoteproc/qcom_q6v5_mss.c b/drivers/remoteproc/qcom_q6v5_mss.c
> index 4ddf084b2c6fc..539594ab955f1 100644
> --- a/drivers/remoteproc/qcom_q6v5_mss.c
> +++ b/drivers/remoteproc/qcom_q6v5_mss.c
> @@ -932,6 +932,9 @@ static int q6v5_mba_load(struct q6v5 *qproc)
>  	if (ret)
>  		goto reclaim_mba;
>  
> +	if (qproc->has_mba_logs)
> +		qcom_pil_info_store("mba", qproc->mba_phys, MBA_LOG_SIZE);

Is there a reason why we don't unconditionally write this to the PIL
info? And why it shouldn't be mba_size?

Regards,
Bjorn

> +
>  	ret = q6v5_rmb_mba_wait(qproc, 0, 5000);
>  	if (ret == -ETIMEDOUT) {
>  		dev_err(qproc->dev, "MBA boot timed out\n");
> -- 
> The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
> a Linux Foundation Collaborative Project
>
Sibi Sankar July 17, 2020, 5:28 a.m. UTC | #2
On 2020-07-17 10:29, Bjorn Andersson wrote:
> On Thu 16 Jul 05:36 PDT 2020, Sibi Sankar wrote:
> 
>> Update MBA text logs location/size in IMEM to aid tools extract
>> them after ramdump collection.
>> 
>> Signed-off-by: Sibi Sankar <sibis@codeaurora.org>
>> ---
>>  drivers/remoteproc/qcom_q6v5_mss.c | 3 +++
>>  1 file changed, 3 insertions(+)
>> 
>> diff --git a/drivers/remoteproc/qcom_q6v5_mss.c 
>> b/drivers/remoteproc/qcom_q6v5_mss.c
>> index 4ddf084b2c6fc..539594ab955f1 100644
>> --- a/drivers/remoteproc/qcom_q6v5_mss.c
>> +++ b/drivers/remoteproc/qcom_q6v5_mss.c
>> @@ -932,6 +932,9 @@ static int q6v5_mba_load(struct q6v5 *qproc)
>>  	if (ret)
>>  		goto reclaim_mba;
>> 
>> +	if (qproc->has_mba_logs)
>> +		qcom_pil_info_store("mba", qproc->mba_phys, MBA_LOG_SIZE);
> 
> Is there a reason why we don't unconditionally write this to the PIL
> info? And why it shouldn't be mba_size?

MBA text logs of size specified are the
only things extracted from MBA region by
the postmortem tools (the tool assumes
that the entire region is text). The MBA
log feature was only added to SC7180 MSS
firmware.

> 
> Regards,
> Bjorn
> 
>> +
>>  	ret = q6v5_rmb_mba_wait(qproc, 0, 5000);
>>  	if (ret == -ETIMEDOUT) {
>>  		dev_err(qproc->dev, "MBA boot timed out\n");
>> --
>> The Qualcomm Innovation Center, Inc. is a member of the Code Aurora 
>> Forum,
>> a Linux Foundation Collaborative Project
>>
diff mbox series

Patch

diff --git a/drivers/remoteproc/qcom_q6v5_mss.c b/drivers/remoteproc/qcom_q6v5_mss.c
index 4ddf084b2c6fc..539594ab955f1 100644
--- a/drivers/remoteproc/qcom_q6v5_mss.c
+++ b/drivers/remoteproc/qcom_q6v5_mss.c
@@ -932,6 +932,9 @@  static int q6v5_mba_load(struct q6v5 *qproc)
 	if (ret)
 		goto reclaim_mba;
 
+	if (qproc->has_mba_logs)
+		qcom_pil_info_store("mba", qproc->mba_phys, MBA_LOG_SIZE);
+
 	ret = q6v5_rmb_mba_wait(qproc, 0, 5000);
 	if (ret == -ETIMEDOUT) {
 		dev_err(qproc->dev, "MBA boot timed out\n");