Re: [PATCH] ASoC: SOF: Don't allow pointer operations on unconfigured streams
From: Mark Brown
Date: Fri Mar 27 2026 - 12:57:56 EST
On Fri, Mar 27, 2026 at 11:49:41AM +0200, Péter Ujfalusi wrote:
> On 26/03/2026 16:52, Mark Brown wrote:
> > + if (!sstream->channels || !sstream->sample_container_bytes)
> > + return -EBUSY;
> > +
> Is this a theoretical fix?
> I don't think this can happen in real world as set_params would need to
> fail and if that failed then applications would not ask for a pointer as
> the compress stream cannot be even started.
Yes, it's not something that would happen in the real world with a non
buggy (or hostile) userspace. Still, we shouldn't leave this stuff
open.
Attachment:
signature.asc
Description: PGP signature