diff options
author | Philippe Mathieu-Daudé <philmd@linaro.org> | 2024-06-17 13:03:56 +0200 |
---|---|---|
committer | Philippe Mathieu-Daudé <philmd@linaro.org> | 2024-06-24 10:41:42 +0200 |
commit | 904547845c559d7530a20792d599a77d8e2ae442 (patch) | |
tree | b8b4036b9c4b82ba236f20e21597dccf1160606e | |
parent | f17fb69c55c7020b90cc1a9eaefe716902a5bc0e (diff) | |
download | qemu-904547845c559d7530a20792d599a77d8e2ae442.zip qemu-904547845c559d7530a20792d599a77d8e2ae442.tar.gz qemu-904547845c559d7530a20792d599a77d8e2ae442.tar.bz2 |
hw/sd/sdcard: Use registerfield CSR::CURRENT_STATE definition
Use registerfield-generated definitions to update card_status.
Signed-off-by: Philippe Mathieu-Daudé <philmd@linaro.org>
Reviewed-by: Cédric Le Goater <clg@redhat.com>
Tested-by: Cédric Le Goater <clg@redhat.com>
Message-Id: <20240621080554.18986-6-philmd@linaro.org>
-rw-r--r-- | hw/sd/sd.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -1788,8 +1788,8 @@ int sd_do_command(SDState *sd, SDRequest *req, * (Do this now so they appear in r1 responses.) */ sd->current_cmd = req->cmd; - sd->card_status &= ~CURRENT_STATE; - sd->card_status |= (last_state << 9); + sd->card_status = FIELD_DP32(sd->card_status, CSR, + CURRENT_STATE, last_state); } send_response: |