hw/sd/sdcard: Factor sd_req_get_rca() method out
authorPhilippe Mathieu-Daudé <philmd@linaro.org>
Tue, 11 Jun 2024 14:38:01 +0000 (16:38 +0200)
committerPhilippe Mathieu-Daudé <philmd@linaro.org>
Mon, 24 Jun 2024 08:41:42 +0000 (10:41 +0200)
commit0ab318ca3c0b370ff82e9fabf80633cc93d0574e
treee6d09a85c7334cde5d01c500fefbe62f387d7620
parenteded0d1a485f3e6279142b88edf444e5e764c9a6
hw/sd/sdcard: Factor sd_req_get_rca() method out

Extract sd_req_get_rca() so we can re-use it in various
SDProto handlers. Return a 16-bit value since RCA is 16-bit.

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-15-philmd@linaro.org>
hw/sd/sd.c