Re: [PATCH] r8152: simplify loops in generic_ocp_{read,write}()
Sergey Shtylyov <[email protected]>
| Newsgroups | org.kernel.vger.netdev,org.kernel.vger.linux-usb |
|---|---|
| Message-ID | <[email protected]> |
On 8/22/26 11:21 PM, Sergey Shtylyov wrote:
> In generic_ocp_{read,write}(), the *while* loops look very strange:
> the last iteration is executed differently to the prior ones, doing
> some useless assignments before *break*. Move the code for the last
> iteration out of the loop bodies, dropping the pointless statements
> as well...
>
> Found by Linux Verification Center (linuxtesting.org) with the Svace
> static analysis tool.
>
> Signed-off-by: Sergey Shtylyov <[email protected]>
[...]
And of course I forgot [net-next] in the subject... :-)
MBR, Sergey