diff mbox series

[PULL,26/32] sdcard: handle the Security Specification commands

Message ID 20180222152307.7499-27-peter.maydell@linaro.org
State Accepted
Commit 688491c71adedcb349248ca467f2ddfc7c4cf566
Headers show
Series target-arm queue | expand

Commit Message

Peter Maydell Feb. 22, 2018, 3:23 p.m. UTC
From: Philippe Mathieu-Daudé <f4bug@amsat.org>


returning sd_illegal, since they are not implemented.

Signed-off-by: Philippe Mathieu-Daudé <f4bug@amsat.org>

Reviewed-by: Alistair Francis <alistair.francis@xilinx.com>

Message-id: 20180215221325.7611-11-f4bug@amsat.org
[PMM: tweak multiline comment format]
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>

---
 hw/sd/sd.c | 12 ++++++++++++
 1 file changed, 12 insertions(+)

-- 
2.16.1
diff mbox series

Patch

diff --git a/hw/sd/sd.c b/hw/sd/sd.c
index 63da05eaef..f13f33efca 100644
--- a/hw/sd/sd.c
+++ b/hw/sd/sd.c
@@ -1546,6 +1546,18 @@  static sd_rsp_type_t sd_app_command(SDState *sd,
         }
         break;
 
+    case 18:    /* Reserved for SD security applications */
+    case 25:
+    case 26:
+    case 38:
+    case 43 ... 49:
+        /* Refer to the "SD Specifications Part3 Security Specification" for
+         * information about the SD Security Features.
+         */
+        qemu_log_mask(LOG_UNIMP, "SD: CMD%i Security not implemented\n",
+                      req.cmd);
+        return sd_illegal;
+
     default:
         /* Fall back to standard commands.  */
         return sd_normal_command(sd, req);