Re: [PATCH] staging: greybus: audio_codec: fix stack overflow in stream name parsing
From: Greg KH
Date: Thu Sep 03 2026 - 00:41:35 EST
On Wed, Sep 02, 2026 at 10:17:00AM -0500, Yudi Yang wrote:
> I found this with an internal program-analysis tool that I cannot disclose
> yet, then manually verified the finding. intf_name and dir are 32-byte
> arrays, while the unbounded %s conversions allow tokens from w->sname
> longer than 31 characters to overflow them. Using %31s limits each
> conversion to 31 characters.
Please read our documentation which describes how you need to identify
when you use tools like this.
> I do not have Greybus hardware, so testing was limited to building the
> affected object and running checkpatch.pl
That's not really testing the code :(
Please resubmit based on the documentation requirements.
thanks,
greg k-h