diff options
author | Igor V. Kovalenko <igor.v.kovalenko@gmail.com> | 2010-04-23 01:54:45 +0400 |
---|---|---|
committer | Blue Swirl <blauwirbel@gmail.com> | 2010-05-01 19:44:43 +0000 |
commit | 70ae65f5d91462e1905a53236179fde21cda3a2f (patch) | |
tree | 3a8aa8c27ce6c8e7560e9cbdb7e27d0ec6f0db66 /hw/ide/piix.c | |
parent | 9ed7b059ef776a3921cfd085e891f45076922542 (diff) | |
download | qemu-70ae65f5d91462e1905a53236179fde21cda3a2f.tar.gz qemu-70ae65f5d91462e1905a53236179fde21cda3a2f.tar.bz2 qemu-70ae65f5d91462e1905a53236179fde21cda3a2f.zip |
cmd646: pass pci_dev as it needs it
Instead of doing tricks to get the pci_dev, just pass it in the 1st
place. Patch is a bit longer that reverting the pci_dev field, but it
states more clearly (IMHO) what we are doing.
It also fixes the bm test, now that you told me that ->unit is not
always valid.
Signed-off-by: Juan Quintela <quintela@redhat.com>
Signed-off-by: Igor V. Kovalenko <igor.v.kovalenko@gmail.com>
Signed-off-by: Blue Swirl <blauwirbel@gmail.com>
Diffstat (limited to 'hw/ide/piix.c')
-rw-r--r-- | hw/ide/piix.c | 1 |
1 files changed, 0 insertions, 1 deletions
diff --git a/hw/ide/piix.c b/hw/ide/piix.c index 295a93d078..4fa38519ef 100644 --- a/hw/ide/piix.c +++ b/hw/ide/piix.c @@ -78,7 +78,6 @@ static void bmdma_map(PCIDevice *pci_dev, int region_num, BMDMAState *bm = &d->bmdma[i]; d->bus[i].bmdma = bm; bm->bus = d->bus+i; - bm->pci_dev = d; qemu_add_vm_change_state_handler(ide_dma_restart_cb, bm); register_ioport_write(addr, 1, 1, bmdma_cmd_writeb, bm); |