linux-stable/arch/powerpc/platforms/pseries
Nishanth Aravamudan 4ad04e5987 powerpc/iommu: Remove IOMMU device references via bus notifier
After d905c5df9a ("PPC: POWERNV: move iommu_add_device earlier"), the
refcnt on the kobject backing the IOMMU group for a PCI device is
elevated by each call to pci_dma_dev_setup_pSeriesLP() (via
set_iommu_table_base_and_group). When we go to dlpar a multi-function
PCI device out:

        iommu_reconfig_notifier ->
                iommu_free_table ->
                        iommu_group_put
                        BUG_ON(tbl->it_group)

We trip this BUG_ON, because there are still references on the table, so
it is not freed. Fix this by moving the powernv bus notifier to common
code and calling it for both powernv and pseries.

Fixes: d905c5df9a ("PPC: POWERNV: move iommu_add_device earlier")
Signed-off-by: Nishanth Aravamudan <nacc@linux.vnet.ibm.com>
Tested-by: Nishanth Aravamudan <nacc@linux.vnet.ibm.com>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
2015-03-04 13:19:33 +11:00
..
cmm.c powerpc/pseries: Drop unnecessary continue 2014-09-23 11:00:40 +10:00
dlpar.c powerpc: use device_online/offline() instead of cpu_up/down() 2014-11-02 10:55:56 +11:00
dtl.c powerpc: Replace __get_cpu_var uses 2014-11-03 12:12:32 +11:00
eeh_pseries.c powerpc/pseries: Decrease message level on EEH initialization 2014-09-30 17:15:16 +10:00
event_sources.c of/irq: simplify args to irq_create_of_mapping 2013-10-24 11:42:57 +01:00
firmware.c powerpc/pseries: Update CPU maps when device tree is updated 2013-04-26 16:08:23 +10:00
hotplug-cpu.c powerpc: Replace cpumask_weight(cpu_possible_mask) with num_possible_cpus() 2015-01-23 14:02:51 +11:00
hotplug-memory.c powerpc updates for 3.19 2014-12-11 17:48:14 -08:00
hvCall.S powerpc/jump_label: Use HAVE_JUMP_LABEL 2014-11-10 09:59:30 +11:00
hvCall_inst.c powerpc: Replace __get_cpu_var uses 2014-11-03 12:12:32 +11:00
hvconsole.c pseries: Move plpar_wrapper.h to powerpc common include/asm location. 2013-08-27 14:43:05 +10:00
hvcserver.c powerpc/pseries/hvcserver: Fix endian issue in hvcs_get_partner_info 2014-08-13 15:14:04 +10:00
io_event_irq.c powerpc/le: Enable RTAS events support 2014-04-07 10:33:12 +10:00
iommu.c powerpc/iommu: Remove IOMMU device references via bus notifier 2015-03-04 13:19:33 +11:00
Kconfig powerpc/pseries: relocate "config DTL" so kconfig nests properly 2014-12-29 15:45:42 +11:00
kexec.c pseries: Move plpar_wrapper.h to powerpc common include/asm location. 2013-08-27 14:43:05 +10:00
lpar.c powerpc/kdump: Ignore failure in enabling big endian exception during crash 2014-12-29 15:44:53 +11:00
lparcfg.c powerpc/pseries: Fix endian issues in /proc/ppc64/lparcfg 2013-12-13 15:48:35 +11:00
Makefile powerpc/pseries/cpuidle: Move processor_idle.c to drivers/cpuidle. 2014-01-29 17:02:22 +11:00
mobility.c powerpc/pseries: Fix endian problems with LE migration 2015-01-27 14:03:53 +11:00
msi.c Merge branch 'irq-irqdomain-for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/tip/tip 2014-12-10 09:01:01 -08:00
nvram.c powerpc/pseries: Initialise nvram_pstore_info's buf_lock 2014-11-19 16:09:13 +11:00
offline_states.h powerpc/smp: soft-replugged CPUs must go back to start_secondary 2011-04-01 15:37:09 +11:00
pci.c powerpc/pseries: Quieten ibm,pcie-link-speed-stats warning 2014-11-10 09:59:33 +11:00
pci_dlpar.c powerpc/pci: Reorder pci bus/bridge unregistration during PHB removal 2014-08-05 15:40:58 +10:00
power.c powerpc/pseries: Switch pseries drivers to use machine_xxx_initcall() 2014-07-28 14:11:26 +10:00
pseries.h powerpc/pseries: Make CPU hotplug path endian safe 2014-10-15 11:25:59 +11:00
pseries_energy.c powerpc: Fix a number of sparse warnings 2013-08-14 11:50:24 +10:00
ras.c powerpc/pseries: All events of EPOW_SYSTEM_SHUTDOWN must initiate shutdown 2015-01-23 11:17:30 +11:00
reconfig.c powerpc/pseries: Switch pseries drivers to use machine_xxx_initcall() 2014-07-28 14:11:26 +10:00
rng.c powerpc/pseries: Switch pseries drivers to use machine_xxx_initcall() 2014-07-28 14:11:26 +10:00
scanlog.c ppc: Clean up scanlog 2013-05-01 17:29:45 -04:00
setup.c powerpc updates for 3.19 2014-12-11 17:48:14 -08:00
smp.c powerpc: Fix SMP issues with ppc64le ABIv2 2014-04-23 10:05:26 +10:00
suspend.c powerpc/pseries: Switch pseries drivers to use machine_xxx_initcall() 2014-07-28 14:11:26 +10:00