lkml.org 
[lkml]   [2021]   [Oct]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 2/5] reset: tegra-bpmp: Handle errors in BPMP response
From
Date
Hi Philipp,

On 15/09/2021 09:55, Mikko Perttunen wrote:
> The return value from tegra_bpmp_transfer indicates the success or
> failure of the IPC transaction with BPMP. If the transaction
> succeeded, we also need to check the actual command's result code.
> Add code to do this.
>
> Signed-off-by: Mikko Perttunen <mperttunen@nvidia.com>
> ---
> drivers/reset/tegra/reset-bpmp.c | 9 ++++++++-
> 1 file changed, 8 insertions(+), 1 deletion(-)
>
> diff --git a/drivers/reset/tegra/reset-bpmp.c b/drivers/reset/tegra/reset-bpmp.c
> index 24d3395964cc..4c5bba52b105 100644
> --- a/drivers/reset/tegra/reset-bpmp.c
> +++ b/drivers/reset/tegra/reset-bpmp.c
> @@ -20,6 +20,7 @@ static int tegra_bpmp_reset_common(struct reset_controller_dev *rstc,
> struct tegra_bpmp *bpmp = to_tegra_bpmp(rstc);
> struct mrq_reset_request request;
> struct tegra_bpmp_message msg;
> + int err;
>
> memset(&request, 0, sizeof(request));
> request.cmd = command;
> @@ -30,7 +31,13 @@ static int tegra_bpmp_reset_common(struct reset_controller_dev *rstc,
> msg.tx.data = &request;
> msg.tx.size = sizeof(request);
>
> - return tegra_bpmp_transfer(bpmp, &msg);
> + err = tegra_bpmp_transfer(bpmp, &msg);
> + if (err)
> + return err;
> + if (msg.rx.ret)
> + return -EINVAL;
> +
> + return 0;
> }
>
> static int tegra_bpmp_reset_module(struct reset_controller_dev *rstc,
>


I see that you have pulled this into the mainline for v5.15.
Unfortunately, this is causing a regression for the Tegra HDA
controller. We need to fix the Tegra HDA driver but this is too late now
for v5.15 and so we need to revert this change for v5.15. Sorry about
this, but I did not expect this to be pulled in so late.

Jon

--
nvpublic

\
 
 \ /
  Last update: 2021-10-28 13:55    [W:0.395 / U:0.004 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site