android_kernel_lge_bullhead/arch/s390/pci
Sebastian Ott ab6c86a004 s390/pci: fix use after free in dma_init
commit dba599091c191d209b1499511a524ad9657c0e5a upstream.

After a failure during registration of the dma_table (because of the
function being in error state) we free its memory but don't reset the
associated pointer to zero.

When we then receive a notification from firmware (about the function
being in error state) we'll try to walk and free the dma_table again.

Fix this by resetting the dma_table pointer. In addition to that make
sure that we free the iommu_bitmap when appropriate.

Signed-off-by: Sebastian Ott <sebott@linux.vnet.ibm.com>
Reviewed-by: Gerald Schaefer <gerald.schaefer@de.ibm.com>
Signed-off-by: Martin Schwidefsky <schwidefsky@de.ibm.com>
Cc: Sumit Semwal <sumit.semwal@linaro.org>
Signed-off-by: Jiri Slaby <jslaby@suse.cz>
Signed-off-by: Willy Tarreau <w@1wt.eu>
2017-06-20 14:04:33 +02:00
..
Makefile s390/pci: uninline instruction wrappers 2013-04-17 14:07:37 +02:00
pci.c s390/pci: Implement IRQ functions if !PCI 2013-06-10 16:06:04 +02:00
pci_clp.c s390/pci: debug device states 2013-04-17 14:07:35 +02:00
pci_debug.c s390/pci: debug device states 2013-04-17 14:07:35 +02:00
pci_dma.c s390/pci: fix use after free in dma_init 2017-06-20 14:04:33 +02:00
pci_event.c s390/pci: performance statistics and debug infrastructure 2012-12-14 10:01:17 +01:00
pci_insn.c s390/pci: do not read data after failed load 2013-04-17 14:07:38 +02:00
pci_msi.c s390/pci: msi cleanup hash usage 2013-04-17 14:07:35 +02:00
pci_sysfs.c s390/pci: s390 specific PCI sysfs attributes 2012-11-30 17:47:26 +01:00