Re: [PATCH] kernel/sys.c: improve the usage of return value

2013-08-07 Thread Chen Gang
According to the related discussion in another thread, this patch can be obsoleted now. Thanks. On 08/06/2013 04:43 PM, Chen Gang wrote: > Improve the usage of return value, so not only can make code clearer > to readers, but also can improve the performance. > > Assign the return error code

Re: [PATCH] kernel/sys.c: improve the usage of return value

2013-08-07 Thread Chen Gang
According to the related discussion in another thread, this patch can be obsoleted now. Thanks. On 08/06/2013 04:43 PM, Chen Gang wrote: Improve the usage of return value, so not only can make code clearer to readers, but also can improve the performance. Assign the return error code only

[PATCH] kernel/sys.c: improve the usage of return value

2013-08-06 Thread Chen Gang
Improve the usage of return value, so not only can make code clearer to readers, but also can improve the performance. Assign the return error code only when error occurs, so can save some instructions. For getcpu(), uname(), newuname(), and override_release(), can remove the return variable to

[PATCH] kernel/sys.c: improve the usage of return value

2013-08-06 Thread Chen Gang
Improve the usage of return value, so not only can make code clearer to readers, but also can improve the performance. Assign the return error code only when error occurs, so can save some instructions. For getcpu(), uname(), newuname(), and override_release(), can remove the return variable to