Re: [PATCH] ubifs: compress lines for immediate return

2016-09-07 Thread Richard Weinberger
Heiko, On 05.09.2016 06:59, Heiko Schocher wrote: > fix the following code: > > -ret = expression; > -if (ret) > -return ret; > -return 0; > +return expression; "Fix"? ;-) What was broken? I agree that we can write the expression in a different way, but is it really worth it? Is this

Re: [PATCH] ubifs: compress lines for immediate return

2016-09-07 Thread Richard Weinberger
Heiko, On 05.09.2016 06:59, Heiko Schocher wrote: > fix the following code: > > -ret = expression; > -if (ret) > -return ret; > -return 0; > +return expression; "Fix"? ;-) What was broken? I agree that we can write the expression in a different way, but is it really worth it? Is this

Re: [PATCH] ubifs: compress lines for immediate return

2016-09-07 Thread Richard Weinberger
Heiko, On 05.09.2016 08:35, Heiko Schocher wrote: > I think yes ... > >> Is this part of a tree-wide cleanup? > > Yes, and I thought it is worth to change this part in linux too. Agreed. Can you please resend with a proper change log and (more important) a correct sob-chain? From: and first

Re: [PATCH] ubifs: compress lines for immediate return

2016-09-07 Thread Richard Weinberger
Heiko, On 05.09.2016 08:35, Heiko Schocher wrote: > I think yes ... > >> Is this part of a tree-wide cleanup? > > Yes, and I thought it is worth to change this part in linux too. Agreed. Can you please resend with a proper change log and (more important) a correct sob-chain? From: and first

Re: [PATCH] ubifs: compress lines for immediate return

2016-09-05 Thread Heiko Schocher
Hello Richard, Am 05.09.2016 um 08:28 schrieb Richard Weinberger: Heiko, On 05.09.2016 06:59, Heiko Schocher wrote: fix the following code: -ret = expression; -if (ret) -return ret; -return 0; +return expression; "Fix"? ;-) What was broken? Ok, fix is to hard spoken ... nothing

Re: [PATCH] ubifs: compress lines for immediate return

2016-09-05 Thread Heiko Schocher
Hello Richard, Am 05.09.2016 um 08:28 schrieb Richard Weinberger: Heiko, On 05.09.2016 06:59, Heiko Schocher wrote: fix the following code: -ret = expression; -if (ret) -return ret; -return 0; +return expression; "Fix"? ;-) What was broken? Ok, fix is to hard spoken ... nothing

Re: [PATCH] ubifs: compress lines for immediate return

2016-09-05 Thread Richard Weinberger
Heiko, On 05.09.2016 08:35, Heiko Schocher wrote: > I think yes ... > >> Is this part of a tree-wide cleanup? > > Yes, and I thought it is worth to change this part in linux too. Agreed. Can you please resend with a proper change log and (more important) a correct sob-chain? From: and first

Re: [PATCH] ubifs: compress lines for immediate return

2016-09-05 Thread Richard Weinberger
Heiko, On 05.09.2016 08:35, Heiko Schocher wrote: > I think yes ... > >> Is this part of a tree-wide cleanup? > > Yes, and I thought it is worth to change this part in linux too. Agreed. Can you please resend with a proper change log and (more important) a correct sob-chain? From: and first

Re: [PATCH] ubifs: compress lines for immediate return

2016-09-05 Thread Richard Weinberger
Heiko, On 05.09.2016 06:59, Heiko Schocher wrote: > fix the following code: > > -ret = expression; > -if (ret) > -return ret; > -return 0; > +return expression; "Fix"? ;-) What was broken? I agree that we can write the expression in a different way, but is it really worth it? Is this

Re: [PATCH] ubifs: compress lines for immediate return

2016-09-05 Thread Richard Weinberger
Heiko, On 05.09.2016 06:59, Heiko Schocher wrote: > fix the following code: > > -ret = expression; > -if (ret) > -return ret; > -return 0; > +return expression; "Fix"? ;-) What was broken? I agree that we can write the expression in a different way, but is it really worth it? Is this

[PATCH] ubifs: compress lines for immediate return

2016-09-04 Thread Heiko Schocher
fix the following code: -ret = expression; -if (ret) -return ret; -return 0; +return expression; From: Masahiro Yamada posted on the U-Boot mailinglist. Signed-off-by: Heiko Schocher --- fs/ubifs/budget.c | 7 ++- fs/ubifs/gc.c

[PATCH] ubifs: compress lines for immediate return

2016-09-04 Thread Heiko Schocher
fix the following code: -ret = expression; -if (ret) -return ret; -return 0; +return expression; From: Masahiro Yamada posted on the U-Boot mailinglist. Signed-off-by: Heiko Schocher --- fs/ubifs/budget.c | 7 ++- fs/ubifs/gc.c | 6 ++ fs/ubifs/lpt_commit.c | 5