Re: [PATCH AUTOSEL 3.18 15/98] usb: musb: Fix a few off-by-one lengths

From: Rasmus Villemoes
Date: Fri Oct 26 2018 - 06:47:22 EST


On 2018-10-25 16:17, Sasha Levin wrote:
> From: Rasmus Villemoes <linux@xxxxxxxxxxxxxxxxxx>
>
> [ Upstream commit e87c3f80ad0490d26ffe04754b7d094463b40f30 ]
>
> !strncmp(buf, "force host", 9) is true if and only if buf starts with
> "force hos". This was obviously not what was intended. The same error
> exists for "force full-speed", "force high-speed" and "test
> packet". Using strstarts avoids the error-prone hardcoding of the
> prefix length.

Not sure this qualifies for -stable, but if some other "real" -stable
patch depends textually on this, it should be ok/harmless. Just my 2c.

Rasmus