linux/arch/powerpc
Alexey Kardashevskiy d41ce7b1bc powerpc/powernv/npu: Do not try invalidating 32bit table when 64bit table is enabled
GPUs and the corresponding NVLink bridges get different PEs as they
have separate translation validation entries (TVEs). We put these PEs
to the same IOMMU group so they cannot be passed through separately.
So the iommu_table_group_ops::set_window/unset_window for GPUs do set
tables to the NPU PEs as well which means that iommu_table's list of
attached PEs (iommu_table_group_link) has both GPU and NPU PEs linked.
This list is used for TCE cache invalidation.

The problem is that NPU PE has just a single TVE and can be programmed
to point to 32bit or 64bit windows while GPU PE has two (as any other
PCI device). So we end up having an 32bit iommu_table struct linked to
both PEs even though only the 64bit TCE table cache can be invalidated
on NPU. And a relatively recent skiboot detects this and prints
errors.

This changes GPU's iommu_table_group_ops::set_window/unset_window to
make sure that NPU PE is only linked to the table actually used by the
hardware. If there are two tables used by an IOMMU group, the NPU PE
will use the last programmed one which with the current use scenarios
is expected to be a 64bit one.

Signed-off-by: Alexey Kardashevskiy <aik@ozlabs.ru>
Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>
2018-03-27 23:44:57 +11:00
..
boot powerpc: dts: replace 'linux,stdout-path' with 'stdout-path' 2018-03-20 16:47:54 +11:00
configs powerpc updates for 4.16 2018-02-02 10:01:04 -08:00
crypto crypto: hash - annotate algorithms taking optional key 2018-01-12 23:03:35 +11:00
include powerpc/64s: Enhance the information in cpu_show_meltdown() 2018-03-27 23:44:53 +11:00
kernel powerpc/init: Do not advertise radix during client-architecture-support 2018-03-27 23:44:55 +11:00
kvm Merge branch 'topic/ppc-kvm' into next 2018-03-24 08:43:18 +11:00
lib powerpc/rfi-flush: Differentiate enabled and patched flush types 2018-03-27 19:25:14 +11:00
math-emu License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
mm powerpc/mm: Fix typo in comments 2018-03-27 23:44:56 +11:00
net powerpc/bpf/jit: Fix 32-bit JIT for seccomp_data access 2018-02-22 14:36:08 +11:00
oprofile powerpc: Use sizeof(*foo) rather than sizeof(struct foo) 2018-03-20 16:47:53 +11:00
perf powerpc/perf: Add blacklisted events for Power9 DD2.2 2018-03-27 19:25:11 +11:00
platforms powerpc/powernv/npu: Do not try invalidating 32bit table when 64bit table is enabled 2018-03-27 23:44:57 +11:00
purgatory License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
sysdev powerpc/xive: Use hw CPU ids when configuring the CPU queues 2018-02-15 09:54:43 +11:00
tools License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00
xmon powerpc/xmon: Move empty plpar_set_ciabr() into plpar_wrappers.h 2018-03-13 23:43:04 +11:00
Kconfig Merge branch 'linus' into sched/urgent, to resolve conflicts 2018-02-06 21:12:31 +01:00
Kconfig.debug powerpc: Add new kconfig CONFIG_PPC_IRQ_SOFT_MASK_DEBUG 2018-01-19 22:37:03 +11:00
Makefile powerpc: Keep const vars out of writable .sdata 2018-03-06 09:21:21 +11:00
Makefile.postlink License cleanup: add SPDX GPL-2.0 license identifier to files with no license 2017-11-02 11:10:55 +01:00