diff options
author | Denys Dmytriyenko <denis@denix.org> | 2009-03-17 14:32:59 -0400 |
---|---|---|
committer | Denys Dmytriyenko <denis@denix.org> | 2009-03-17 14:32:59 -0400 |
commit | 709c4d66e0b107ca606941b988bad717c0b45d9b (patch) | |
tree | 37ee08b1eb308f3b2b6426d5793545c38396b838 /recipes/qemu/qemu-0.9.0+cvs20070613/qemu-pci-irq-sharing.patch | |
parent | fa6cd5a3b993f16c27de4ff82b42684516d433ba (diff) |
rename packages/ to recipes/ per earlier agreement
See links below for more details:
http://thread.gmane.org/gmane.comp.handhelds.openembedded/21326
http://thread.gmane.org/gmane.comp.handhelds.openembedded/21816
Signed-off-by: Denys Dmytriyenko <denis@denix.org>
Acked-by: Mike Westerhof <mwester@dls.net>
Acked-by: Philip Balister <philip@balister.org>
Acked-by: Khem Raj <raj.khem@gmail.com>
Acked-by: Marcin Juszkiewicz <hrw@openembedded.org>
Acked-by: Koen Kooi <koen@openembedded.org>
Acked-by: Frans Meulenbroeks <fransmeulenbroeks@gmail.com>
Diffstat (limited to 'recipes/qemu/qemu-0.9.0+cvs20070613/qemu-pci-irq-sharing.patch')
-rw-r--r-- | recipes/qemu/qemu-0.9.0+cvs20070613/qemu-pci-irq-sharing.patch | 52 |
1 files changed, 52 insertions, 0 deletions
diff --git a/recipes/qemu/qemu-0.9.0+cvs20070613/qemu-pci-irq-sharing.patch b/recipes/qemu/qemu-0.9.0+cvs20070613/qemu-pci-irq-sharing.patch new file mode 100644 index 0000000000..c47e89895f --- /dev/null +++ b/recipes/qemu/qemu-0.9.0+cvs20070613/qemu-pci-irq-sharing.patch @@ -0,0 +1,52 @@ +diff -pNaur qemu-cvs-ts-orig/hw/pci.c qemu-cvs-ts/hw/pci.c +--- qemu-cvs-ts-orig/hw/pci.c 2006-08-17 10:46:34.000000000 +0000 ++++ qemu-cvs-ts/hw/pci.c 2006-09-23 17:02:41.000000000 +0000 +@@ -34,6 +34,7 @@ struct PCIBus { + SetIRQFunc *low_set_irq; + void *irq_opaque; + PCIDevice *devices[256]; ++ int irq_count[4]; + }; + + static void pci_update_mappings(PCIDevice *d); +@@ -49,6 +50,7 @@ PCIBus *pci_register_bus(pci_set_irq_fn + bus->set_irq = set_irq; + bus->irq_opaque = pic; + bus->devfn_min = devfn_min; ++ memset(bus->irq_count, 0, sizeof(bus->irq_count)); + first_bus = bus; + return bus; + } +@@ -100,6 +102,7 @@ PCIDevice *pci_register_device(PCIBus *b + pci_dev->bus = bus; + pci_dev->devfn = devfn; + pstrcpy(pci_dev->name, sizeof(pci_dev->name), name); ++ memset(pci_dev->irq_state, 0, sizeof(pci_dev->irq_state)); + + if (!config_read) + config_read = pci_default_read_config; +@@ -404,7 +407,10 @@ uint32_t pci_data_read(void *opaque, uin + void pci_set_irq(PCIDevice *pci_dev, int irq_num, int level) + { + PCIBus *bus = pci_dev->bus; +- bus->set_irq(pci_dev, bus->irq_opaque, irq_num, level); ++ bus->irq_count[irq_num] += level - pci_dev->irq_state[irq_num]; ++ pci_dev->irq_state[irq_num] = level; ++ bus->set_irq(pci_dev, bus->irq_opaque, ++ irq_num, !!bus->irq_count[irq_num]); + } + + /***********************************************************/ +diff -pNaur qemu-cvs-ts-orig/vl.h qemu-cvs-ts/vl.h +--- qemu-cvs-ts-orig/vl.h 2006-09-18 01:15:29.000000000 +0000 ++++ qemu-cvs-ts/vl.h 2006-09-23 17:15:21.000000000 +0000 +@@ -733,6 +733,9 @@ struct PCIDevice { + PCIConfigWriteFunc *config_write; + /* ??? This is a PC-specific hack, and should be removed. */ + int irq_index; ++ ++ /* remember last irq levels */ ++ int irq_state[4]; + }; + + PCIDevice *pci_register_device(PCIBus *bus, const char *name, |