[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: [PATCH RFC 1/2] hw/sd/ssi-sd: Do not create SD card within controlle
From: |
Peter Maydell |
Subject: |
Re: [PATCH RFC 1/2] hw/sd/ssi-sd: Do not create SD card within controller's realize |
Date: |
Mon, 15 Nov 2021 13:40:36 +0000 |
On Mon, 15 Nov 2021 at 12:56, Markus Armbruster <armbru@redhat.com> wrote:
>
> ssi_sd_realize() creates an "sd-card" device. This is inappropriate,
> and marked FIXME.
>
> Move it to the boards that create these devices. Prior art: commit
> eb4f566bbb for device "generic-sdhci", and commit 26c607b86b for
> device "pl181".
>
> Signed-off-by: Markus Armbruster <armbru@redhat.com>
> ---
> @@ -670,7 +672,7 @@ static void sifive_u_machine_init(MachineState *machine)
>
> /* Connect an SPI flash to SPI0 */
> flash_dev = qdev_new("is25wp256");
> - dinfo = drive_get_next(IF_MTD);
> + dinfo = drive_get(IF_MTD, 0, 0);
> if (dinfo) {
> qdev_prop_set_drive_err(flash_dev, "drive",
> blk_by_legacy_dinfo(dinfo),
This part looks like it should have been in the other patch.
-- PMM