Thread (11 messages) flat view 11 messages, 3 authors, 2021-05-27

Re: [PATCH 3/3] ASoC: rsnd: add null CLOCKIN support

From: Mark Brown <broonie@kernel.org>
Date: 2021-05-27 09:49:15
Also in: alsa-devel

On Thu, May 27, 2021 at 09:30:38AM +0200, Geert Uytterhoeven wrote:
It adds a dummy object, which needs to be cleaned up.  Basically you
are trading a simple NULL pointer check for a zero clock rate check
deeper inside the driver, with the additional burden of needing to
take care of the dummy clock's life cycle.
Note that most clk_*() calls happily operate on a NULL pointer, and
just return success.  This includes clk_get_rate(), which returns
a zero rate.
Mark might have a different view, though, due to his experience with
dummy regulators?
Not particularly TBH.  The regulator API doesn't accept NULL
pointers due to constant issues with people just ignoring errors
especially around trying to decide that devices don't need power,
it'd just make all that worse.

Attachments

Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help