On 9/1/25 17:20, Bernhard Beschow wrote:
Am 9. Januar 2025 11:40:10 UTC schrieb "Philippe Mathieu-Daudé"
<phi...@linaro.org>:
Hi Bernhard,
On 8/1/25 10:25, Bernhard Beschow wrote:
Signed-off-by: Bernhard Beschow <shen...@gmail.com>
---
hw/sd/sd.c | 12 ++++++++----
1 file changed, 8 insertions(+), 4 deletions(-)
@@ -876,8 +878,8 @@ static void sd_reset(DeviceState *dev)
sd->cmd_line = true;
sd->multi_blk_cnt = 0;
- qemu_set_irq(sd->readonly_cb, sd_get_readonly(sd));
- qemu_set_irq(sd->inserted_cb, sd_get_inserted(sd));
+ qemu_set_irq(sd->readonly_cb, sd_get_readonly(sd) ^
sd->readonly_active_low);
Please embed in sd_get_readonly(),
+ qemu_set_irq(sd->inserted_cb, sd_get_inserted(sd) ^
sd->inserted_active_low);
and sd_get_inserted().
Are you sure? I deliberately implemented it as is because embedding would
change the internal logic of the device as well as SDCardClass::{get_inserted,
get_readonly}.
Yes, this is why I requested that change. Why don't you think it is correct?
Best regards,
Bernhard
With the requested changes:
Reviewed-by: Philippe Mathieu-Daudé <phi...@linaro.org>