mbox series

[00/11] hw/sd/sdcard: Consolidate SDProto::cmd[] arrays

Message ID 20240627163843.81592-1-philmd@linaro.org (mailing list archive)
Headers show
Series hw/sd/sdcard: Consolidate SDProto::cmd[] arrays | expand

Message

Philippe Mathieu-Daudé June 27, 2024, 4:38 p.m. UTC
Use the SDProto structure to handle command properties
such name, type, class and handler.
Add stubs for optional commands to ease tracing.

Based-on: <20240627163403.81220-1-philmd@linaro.org>

Full series for testing:
https://gitlab.com/philmd/qemu/-/tags/emmc-v4

Philippe Mathieu-Daudé (11):
  hw/sd/sdcard: Move sd_[a]cmd_name() methods to sd.c
  hw/sd/sdcard: Pass SDState as argument to sd_[a]cmd_name()
  hw/sd/sdcard: Prepare SDProto to contain more fields
  hw/sd/sdcard: Store command name in SDProto
  hw/sd/sdcard: Store command type in SDProto
  hw/sd/sdcard: Store command class in SDProto
  hw/sd/sdcard: Remove SEND_DSR dead case (CMD4)
  hw/sd/sdcard: Register generic optional handlers (CMD11 and CMD20)
  hw/sd/sdcard: Register optional handlers from spec v6.00
  hw/sd/sdcard: Register SDIO optional handlers
  hw/sd/sdcard: Register Security Extension optional handlers

 hw/sd/sdmmc-internal.h |  26 ------
 include/hw/sd/sd.h     |   5 +-
 hw/sd/sd.c             | 192 ++++++++++++++++++++++++++++++-----------
 hw/sd/sdmmc-internal.c |  72 ----------------
 hw/sd/meson.build      |   2 +-
 5 files changed, 144 insertions(+), 153 deletions(-)
 delete mode 100644 hw/sd/sdmmc-internal.c