Commit 80a34d67a5061ef1fbe8d8f77e866aa350f70959
1 parent
544c4be6
Remove dead code.
git-svn-id: svn://svn.savannah.nongnu.org/qemu/trunk@2632 c046a42c-6fe2-441c-8c8c-71466251a162
Showing
1 changed file
with
6 additions
and
13 deletions
hw/rtl8139.c
| @@ -461,7 +461,6 @@ typedef struct RTL8139State { | @@ -461,7 +461,6 @@ typedef struct RTL8139State { | ||
| 461 | uint16_t CpCmd; | 461 | uint16_t CpCmd; |
| 462 | uint8_t TxThresh; | 462 | uint8_t TxThresh; |
| 463 | 463 | ||
| 464 | - int irq; | ||
| 465 | PCIDevice *pci_dev; | 464 | PCIDevice *pci_dev; |
| 466 | VLANClientState *vc; | 465 | VLANClientState *vc; |
| 467 | uint8_t macaddr[6]; | 466 | uint8_t macaddr[6]; |
| @@ -685,16 +684,10 @@ static void rtl8139_update_irq(RTL8139State *s) | @@ -685,16 +684,10 @@ static void rtl8139_update_irq(RTL8139State *s) | ||
| 685 | int isr; | 684 | int isr; |
| 686 | isr = (s->IntrStatus & s->IntrMask) & 0xffff; | 685 | isr = (s->IntrStatus & s->IntrMask) & 0xffff; |
| 687 | 686 | ||
| 688 | - DEBUG_PRINT(("RTL8139: Set IRQ line %d to %d (%04x %04x)\n", | ||
| 689 | - s->irq, isr ? 1 : 0, s->IntrStatus, s->IntrMask)); | 687 | + DEBUG_PRINT(("RTL8139: Set IRQ to %d (%04x %04x)\n", |
| 688 | + isr ? 1 : 0, s->IntrStatus, s->IntrMask)); | ||
| 690 | 689 | ||
| 691 | - if (s->irq == 16) { | ||
| 692 | - /* PCI irq */ | ||
| 693 | - pci_set_irq(s->pci_dev, 0, (isr != 0)); | ||
| 694 | - } else { | ||
| 695 | - /* ISA irq */ | ||
| 696 | - pic_set_irq(s->irq, (isr != 0)); | ||
| 697 | - } | 690 | + pci_set_irq(s->pci_dev, 0, (isr != 0)); |
| 698 | } | 691 | } |
| 699 | 692 | ||
| 700 | #define POLYNOMIAL 0x04c11db6 | 693 | #define POLYNOMIAL 0x04c11db6 |
| @@ -3173,7 +3166,8 @@ static void rtl8139_save(QEMUFile* f,void* opaque) | @@ -3173,7 +3166,8 @@ static void rtl8139_save(QEMUFile* f,void* opaque) | ||
| 3173 | qemu_put_be16s(f, &s->CpCmd); | 3166 | qemu_put_be16s(f, &s->CpCmd); |
| 3174 | qemu_put_8s(f, &s->TxThresh); | 3167 | qemu_put_8s(f, &s->TxThresh); |
| 3175 | 3168 | ||
| 3176 | - qemu_put_be32s(f, &s->irq); | 3169 | + i = 0; |
| 3170 | + qemu_put_be32s(f, &i); /* unused. */ | ||
| 3177 | qemu_put_buffer(f, s->macaddr, 6); | 3171 | qemu_put_buffer(f, s->macaddr, 6); |
| 3178 | qemu_put_be32s(f, &s->rtl8139_mmio_io_addr); | 3172 | qemu_put_be32s(f, &s->rtl8139_mmio_io_addr); |
| 3179 | 3173 | ||
| @@ -3267,7 +3261,7 @@ static int rtl8139_load(QEMUFile* f,void* opaque,int version_id) | @@ -3267,7 +3261,7 @@ static int rtl8139_load(QEMUFile* f,void* opaque,int version_id) | ||
| 3267 | qemu_get_be16s(f, &s->CpCmd); | 3261 | qemu_get_be16s(f, &s->CpCmd); |
| 3268 | qemu_get_8s(f, &s->TxThresh); | 3262 | qemu_get_8s(f, &s->TxThresh); |
| 3269 | 3263 | ||
| 3270 | - qemu_get_be32s(f, &s->irq); | 3264 | + qemu_get_be32s(f, &i); /* unused. */ |
| 3271 | qemu_get_buffer(f, s->macaddr, 6); | 3265 | qemu_get_buffer(f, s->macaddr, 6); |
| 3272 | qemu_get_be32s(f, &s->rtl8139_mmio_io_addr); | 3266 | qemu_get_be32s(f, &s->rtl8139_mmio_io_addr); |
| 3273 | 3267 | ||
| @@ -3447,7 +3441,6 @@ void pci_rtl8139_init(PCIBus *bus, NICInfo *nd, int devfn) | @@ -3447,7 +3441,6 @@ void pci_rtl8139_init(PCIBus *bus, NICInfo *nd, int devfn) | ||
| 3447 | pci_register_io_region(&d->dev, 1, 0x100, | 3441 | pci_register_io_region(&d->dev, 1, 0x100, |
| 3448 | PCI_ADDRESS_SPACE_MEM, rtl8139_mmio_map); | 3442 | PCI_ADDRESS_SPACE_MEM, rtl8139_mmio_map); |
| 3449 | 3443 | ||
| 3450 | - s->irq = 16; /* PCI interrupt */ | ||
| 3451 | s->pci_dev = (PCIDevice *)d; | 3444 | s->pci_dev = (PCIDevice *)d; |
| 3452 | memcpy(s->macaddr, nd->macaddr, 6); | 3445 | memcpy(s->macaddr, nd->macaddr, 6); |
| 3453 | rtl8139_reset(s); | 3446 | rtl8139_reset(s); |