17 Jun
2013
17 Jun
'13
3:29 p.m.
On Sun, Jun 16, 2013 at 10:54 PM, Tomasz Figa tomasz.figa@gmail.com wrote:
Further patch will introduce support for PL080S, which requires some things to be done conditionally, thus increasing indentation level of some functions even more.
This patch reduces indentation level of pl08x_getbytes_chan() function by inverting several conditions and returning from function wherever possible.
Signed-off-by: Tomasz Figa tomasz.figa@gmail.com
Nice refactoring and a patch that should be applied immediately no matter what happens with the rest. Reviewed-by: Linus Walleij linus.walleij@linaro.org
PS:
if (!ch || !txd)
return bytes;
Just return 0; is even clearer in this case but who cares.
Yours, Linus Walleij