hw/sd/sd.c: Drop unused sd_acmd_type[] array
PATCH 1/1 hw/sd/sd.c: Drop unused sd_acmd_type[] array
Drop the sd_acmd_type[] array: it is never used. (The equivalent sd_cmd_type[] array for normal commands is used to identify those commands whose argument includes the card address in the top 16 bits; but for app commands the card address is passed with the APP_CMD prefix, not with the argument to the app command itself.)
---
clang 3.4 warns about this unused variable. If we ever turn out to need the information it's all in the sd card spec anyway.
hw/sd/sd.c | 11 ----------- 1 file changed, 11 deletions(-)
hw/sd/sd.c +0 -11
@@ -151,17 +151,6 @@ static const sd_cmd_type_t sd_cmd_type[64] = { sd_adtc, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, }; -static const sd_cmd_type_t sd_acmd_type[64 ] = { - sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_ac, sd_none, - sd_none, sd_none, sd_none, sd_none, sd_none, sd_adtc, sd_none, sd_none, - sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_adtc, sd_ac, - sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, - sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, - sd_none, sd_bcr, sd_ac, sd_none, sd_none, sd_none, sd_none, sd_none, - sd_none, sd_none, sd_none, sd_adtc, sd_none, sd_none, sd_none, sd_none, - sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, -}; -static const int sd_cmd_class[64 ] = {0 ,0 ,0 ,0 ,0 ,9 ,10 ,0 ,0 ,0 ,0 ,1 ,0 ,0 ,0 ,0 ,2 ,2 ,2 ,2 ,3 ,3 ,3 ,3 ,4 ,4 ,4 ,4 ,6 ,6 ,6 ,6 ,
Signature · 1 line
1.9.2
Quoted 8 lines · Peter Maydell
Drop the sd_acmd_type[] array: it is never used. (The equivalent sd_cmd_type[] array for normal commands is used to identify those commands whose argument includes the card address in the top 16 bits; but for app commands the card address is passed with the
APP_CMDprefix, not with the argument to the app command itself.)Signed-off-by Peter Maydell <[email protected]>
Quoted 33 lines
---
clang 3.4 warns about this unused variable. If we ever turn out to need the information it's all in the sd card spec anyway.hw/sd/sd.c | 11 ----------- 1 file changed, 11 deletions(-)hw/sd/sd.c +0
-12@@ -151,17 +151,6 @@ static const sd_cmd_type_t sd_cmd_type[64] = { sd_adtc, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, }; -static const sd_cmd_type_t sd_acmd_type[64 ] = { - sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_ac, sd_none, - sd_none, sd_none, sd_none, sd_none, sd_none, sd_adtc, sd_none, sd_none, - sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_adtc, sd_ac, - sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, - sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, - sd_none, sd_bcr, sd_ac, sd_none, sd_none, sd_none, sd_none, sd_none, - sd_none, sd_none, sd_none, sd_adtc, sd_none, sd_none, sd_none, sd_none, - sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, sd_none, -}; -static const int sd_cmd_class[64 ] = {0 ,0 ,0 ,0 ,0 ,9 ,10 ,0 ,0 ,0 ,0 ,1 ,0 ,0 ,0 ,0 ,2 ,2 ,2 ,2 ,3 ,3 ,3 ,3 ,4 ,4 ,4 ,4 ,6 ,6 ,6 ,6 , --1.9.2
Michael Tokarev
AppliedApplied to -trivial, thank you!
/mjt