[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <46acc080-56f5-f970-a9fa-3a9ece0dd2a3@gmail.com>
Date: Tue, 21 Dec 2021 18:20:14 +0300
From: Dmitry Osipenko <digetx@...il.com>
To: Sameer Pujar <spujar@...dia.com>, tiwai@...e.com,
broonie@...nel.org, lgirdwood@...il.com, robh+dt@...nel.org,
thierry.reding@...il.com, perex@...ex.cz
Cc: jonathanh@...dia.com, mkumard@...dia.com,
alsa-devel@...a-project.org, devicetree@...r.kernel.org,
linux-tegra@...r.kernel.org, linux-kernel@...r.kernel.org,
stable@...r.kernel.org
Subject: Re: [PATCH v2 1/3] ALSA: hda/tegra: Fix Tegra194 HDA reset failure
21.12.2021 09:18, Sameer Pujar пишет:
>
>
> On 12/21/2021 6:51 AM, Dmitry Osipenko wrote:
>>
>> All stable kernels affected by this problem that don't support the bulk
>> reset API are EOL now. Please use bulk reset API like I suggested in the
>> comment to v1, it will allow us to have a cleaner and nicer code.
>
> Agree that it would be compact and cleaner, but any specific reset
> failure in the group won't be obvious in the logs. In this case it
> failed silently. If compactness is preferred, then may be I can keep an
> error print at group level so that we see some failure context whenever
> it happens.
The group shouldn't fail ever unless device-tree is wrong. Why do you
think we should care about the case which realistically won't ever
happen? This is a bit unpractical approach.
If we really care about those error messages, then will be much more
reasonable to add them to the reset core, like clk core does it [1],
IMO. This will be a trivial change. Will you be happy with this variant?
[1]
https://elixir.bootlin.com/linux/v5.16-rc6/source/drivers/clk/clk-bulk.c#L100
diff --git a/drivers/reset/core.c b/drivers/reset/core.c
index 61e688882643..85ce0d6eeb34 100644
--- a/drivers/reset/core.c
+++ b/drivers/reset/core.c
@@ -962,6 +962,11 @@ int __reset_control_bulk_get(struct device *dev,
int num_rstcs,
shared, optional, acquired);
if (IS_ERR(rstcs[i].rstc)) {
ret = PTR_ERR(rstcs[i].rstc);
+
+ if (ret != -EPROBE_DEFER)
+ dev_err(dev, "Failed to get reset '%s': %d\n",
+ rstcs[i].id, ret);
+
goto err;
}
}
Powered by blists - more mailing lists