[alsa-devel] [PATCH 2/2] ASoC: dapm: Adapt for debugfs API change

Mark Brown broonie at kernel.org
Fri Jun 21 17:20:40 CEST 2019


On Fri, Jun 21, 2019 at 04:53:09PM +0200, Greg KH wrote:
> On Fri, Jun 21, 2019 at 03:30:53PM +0100, Mark Brown wrote:
> > On Fri, Jun 21, 2019 at 03:22:22PM +0200, Greg KH wrote:

> > This is a view I still hold and in any case debugfs as it stands (and
> > was in the kernel versions since this was broken) is still capable of
> > reporting errors so we should fix that.

> Sort story is, I am trying to change it so that it can not report errors :)

Yes, I know.  This is what I think is a bad idea.

> And even then, no kernel code should be doing anything different if
> debugfs calls fail or not, that is why I am I making these changes.  No
> "real" code should ever be affected, and right now, it is, if something
> goes wrong with debugfs.

> So removing those checks is the goal here.  Your driver code should not
> care if debugfs is working at all or not.

None of which addresses the issue which is that we should be telling
users who are trying to use debugfs to debug things that something went
wrong rather than silently failing and potentially confusing them with
corrupted data display.  This isn't something you can address through
API restrictions without hurting users unless you are prepared to add
user visible error reporting to the debugfs core.

The conditional code here beyond printing errors only affects the
creation of further debugfs files, it's just there to avoid spewing
secondary errors at people when something goes wrong so the underlying
problem is clearer and is entirely compatible with the idea of not
affecting real code.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://mailman.alsa-project.org/pipermail/alsa-devel/attachments/20190621/b113745b/attachment.sig>


More information about the Alsa-devel mailing list