[Qemu-devel] [PATCH v2 06/25] sdcard: let cmd_valid_while_locked() returns a bool

Philippe Mathieu-Daudé posted 25 patches 7 years, 9 months ago
[Qemu-devel] [PATCH v2 06/25] sdcard: let cmd_valid_while_locked() returns a bool
Posted by Philippe Mathieu-Daudé 7 years, 9 months ago
Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
---
 hw/sd/sd.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/hw/sd/sd.c b/hw/sd/sd.c
index 7bb5c6fb5e..b0e54f69d8 100644
--- a/hw/sd/sd.c
+++ b/hw/sd/sd.c
@@ -1549,7 +1549,7 @@ static sd_rsp_type_t sd_app_command(SDState *sd,
     return sd_illegal;
 }
 
-static int cmd_valid_while_locked(SDState *sd, SDRequest *req)
+static bool cmd_valid_while_locked(SDState *sd, SDRequest *req)
 {
     /* Valid commands in locked state:
      * basic class (0)
@@ -1563,7 +1563,7 @@ static int cmd_valid_while_locked(SDState *sd, SDRequest *req)
         return req->cmd == 41 || req->cmd == 42;
     }
     if (req->cmd == 16 || req->cmd == 55) {
-        return 1;
+        return true;
     }
     return sd_cmd_class[req->cmd] == 0
             || sd_cmd_class[req->cmd] == 7;
-- 
2.15.1