x86: quark: Fix unused warnings
PATCH 1/1 x86: quark: Fix unused warnings
The variable t_rfc is never used, so drop it. The variables ddr_wctl and ddr_wcmd are only used in certain manual instances, so guard their declaration by the same check as their use.
Cc Bin Meng <[email protected]>
Signed-off-by Tom Rini <[email protected]>
--- arch/x86/cpu/quark/smc.c | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-)
arch/x86/cpu/quark/smc.c +4 -9
@@ -17,15 +17,6 @@#include "hte.h" #include "smc.h" -/* t_rfc values (in picoseconds) per density */ -static const uint32_t t_rfc[5 ] = { -90000 ,/* 512Mb */ -110000 ,/* 1Gb */ -160000 ,/* 2Gb */ -300000 ,/* 4Gb */ -350000 ,/* 8Gb */ -}; -/* t_ck clock period in picoseconds per speed index 800, 1066, 1333 */ static const uint32_t t_ck[3 ] = {2500 ,
@@ -35,8 +26,12 @@ static const uint32_t t_ck[3] = {/* Global variables */ static const uint16_t ddr_wclk[] = {193 ,158 }; +#ifdef BACKUP_WCTL static const uint16_t ddr_wctl[] = {1 ,217 }; +#endif +#ifdef BACKUP_WCMD static const uint16_t ddr_wcmd[] = {1 ,220 }; +#endif #ifdef BACKUP_RCVN static const uint16_t ddr_rcvn[] = {129 ,498 };
Signature · 1 line
2.7.4
PATCH 1/1 x86: quark: Fix unused warnings
Quoted 10 lines · Tom Rini
The variable
t_rfcis never used, so drop it. The variablesddr_wctlandddr_wcmdare only used in certain manual instances, so guard their declaration by the same check as their use.Cc Bin Meng <[email protected]>Signed-off-by Tom Rini <[email protected]>--- arch/x86/cpu/quark/smc.c | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-)
Reviewed-by Bin Meng <[email protected]>
Tested-by Bin Meng <[email protected]>
PATCH 1/1 x86: quark: Fix unused warnings
Quoted 12 lines · Bin Meng
Quoted 10 lines · Tom Rini
The variable
t_rfcis never used, so drop it. The variablesddr_wctlandddr_wcmdare only used in certain manual instances, so guard their declaration by the same check as their use.Cc Bin Meng <[email protected]>Signed-off-by Tom Rini <[email protected]>--- arch/x86/cpu/quark/smc.c | 13 ++++--------- 1 file changed, 4 insertions(+), 9 deletions(-)
Quoted 2 lines
Reviewed-by Bin Meng <[email protected]>Tested-by Bin Meng <[email protected]>
applied to u-boot-x86, thanks!