[U-Boot] [PATCH V2] MX31: Make get_reset_cause() static and drop unreachable code

2011-05-17 Thread Stefano Babic
get_reset_cause() should not be exported. Drop code in the function after return statement that can generate warnings due to unreachable code. Signed-off-by: Stefano Babic Signed-off-by: Fabio Estevam --- arch/arm/cpu/arm1136/mx31/generic.c |6 +- 1 files changed, 1 insertions(+), 5 del

Re: [U-Boot] [PATCH V2] MX31: Make get_reset_cause() static

2011-05-17 Thread Stefano Babic
On 05/17/2011 07:10 AM, Jason Liu wrote: > Hi, Stefano, > Hi Jason, > But looking at the code bellow, beside we need make the function static, > do we need to remove the break after the return statement? Otherwise, > some complier may warn un-reachable code, IMHO. You are right, and the break s

Re: [U-Boot] [PATCH V2] MX31: Make get_reset_cause() static

2011-05-16 Thread Jason Liu
Hi, Stefano, 2011/5/16 Stefano Babic : > Signed-off-by: Fabio Estevam > Signed-off-by: Stefano Babic > --- > > Changes since V1: >        - as get_cpu_rev is exported, only get_reset_cause >        is set to static. > >  arch/arm/cpu/arm1136/mx31/generic.c |    2 +- >  1 files changed, 1 inserti

[U-Boot] [PATCH V2] MX31: Make get_reset_cause() static

2011-05-16 Thread Stefano Babic
Signed-off-by: Fabio Estevam Signed-off-by: Stefano Babic --- Changes since V1: - as get_cpu_rev is exported, only get_reset_cause is set to static. arch/arm/cpu/arm1136/mx31/generic.c |2 +- 1 files changed, 1 insertions(+), 1 deletions(-) diff --git a/arch/arm/cpu/arm113