Re: [PATCH v5] USB hub_probe: rework ugly goto-into-compound-statement

2016-11-18 Thread Eugene Korenevsky
> Ok, I'm going to be really pedantic here and ask that you spell this > last statement out: >if (usb...) > return true; >return false; > > Also, the comment should say: > /* If the first endpoint is not interrupt IN, we... */ > It's better to inverse the

Re: [PATCH v5] USB hub_probe: rework ugly goto-into-compound-statement

2016-11-13 Thread Greg Kroah-Hartman
On Sun, Nov 13, 2016 at 03:53:58PM +0300, Eugene Korenevsky wrote: > Rework smelling code (goto inside compound statement). Perhaps this is > legacy. Anyway such code is not appropriate for Linux kernel. > > Signed-off-by: Eugene Korenevsky > --- > Changes in v5: make `bool` a return type of `hub

Re: [PATCH v5] USB hub_probe: rework ugly goto-into-compound-statement

2016-11-13 Thread Greg Kroah-Hartman
On Sun, Nov 13, 2016 at 03:53:58PM +0300, Eugene Korenevsky wrote: > Rework smelling code (goto inside compound statement). Perhaps this is > legacy. Anyway such code is not appropriate for Linux kernel. > > Signed-off-by: Eugene Korenevsky > --- > Changes in v5: make `bool` a return type of `hub

[PATCH v5] USB hub_probe: rework ugly goto-into-compound-statement

2016-11-13 Thread Eugene Korenevsky
Rework smelling code (goto inside compound statement). Perhaps this is legacy. Anyway such code is not appropriate for Linux kernel. Signed-off-by: Eugene Korenevsky --- Changes in v5: make `bool` a return type of `hub_check_descriptor_sanity()` Changes in v4: fix typo Changes in v3: extract the