diff options
Diffstat (limited to 'hw/sd/ssi-sd.c')
-rw-r--r-- | hw/sd/ssi-sd.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/hw/sd/ssi-sd.c b/hw/sd/ssi-sd.c index ad825220e2..3717b2e721 100644 --- a/hw/sd/ssi-sd.c +++ b/hw/sd/ssi-sd.c @@ -254,9 +254,8 @@ static void ssi_sd_realize(SSISlave *d, Error **errp) dinfo = drive_get_next(IF_SD); carddev = qdev_new(TYPE_SD_CARD); if (dinfo) { - qdev_prop_set_drive_err(carddev, "drive", blk_by_legacy_dinfo(dinfo), - &err); - if (err) { + if (!qdev_prop_set_drive_err(carddev, "drive", + blk_by_legacy_dinfo(dinfo), &err)) { goto fail; } } |