android_kernel_xiaomi_sm8350/arch/powerpc/platforms/iseries
Linas Vepstas 5d2efba64b [POWERPC] Use 4kB iommu pages even on 64kB-page systems
The 10Gigabit ethernet device drivers appear to be able to chew
up all 256MB of TCE mappings on pSeries systems, as evidenced by
numerous error messages:

 iommu_alloc failed, tbl c0000000010d5c48 vaddr c0000000d875eff0 npages 1

Some experimentation indicates that this is essentially because
one 1500 byte ethernet MTU gets mapped as a 64K DMA region when
the large 64K pages are enabled. Thus, it doesn't take much to
exhaust all of the available DMA mappings for a high-speed card.

This patch changes the iommu allocator to work with its own
unique, distinct page size. Although the patch is long, its
actually quite simple: it just #defines a distinct IOMMU_PAGE_SIZE
and then uses this in all the places that matter.

As a side effect, it also dramatically improves network performance
on platforms with H-calls on iommu translation inserts/removes (since
we no longer call it 16 times for a 1500 bytes packet when the iommu HW
is still 4k).

In the future, we might want to make the IOMMU_PAGE_SIZE a variable
in the iommu_table instance, thus allowing support for different HW
page sizes in the iommu itself.

Signed-off-by: Linas Vepstas <linas@austin.ibm.com>
Signed-off-by: Benjamin Herrenschmidt <benh@kernel.crashing.org>
Acked-by: Olof Johansson <olof@lixom.net>
Acked-by: Stephen Rothwell <sfr@canb.auug.org.au>
Signed-off-by: Paul Mackerras <paulus@samba.org>
2006-11-01 14:52:48 +11:00
..
call_hpt.h
call_pci.h [PATCH] powerpc: reintroduce HvCallPci_configLoad32 2006-05-24 16:08:56 +10:00
call_sm.h
dt.c Merge branch 'mpe' 2006-07-14 17:27:26 +10:00
htab.c [POWERPC] powerpc: Initialise ppc_md htab pointers earlier 2006-06-28 11:59:47 +10:00
hvcall.S
hvlog.c [PATCH] ppc64: support 64k pages 2005-11-06 16:56:47 -08:00
hvlpconfig.c [POWERPC] iseries: Move ItLpNaca into platforms/iseries 2006-07-13 18:42:52 +10:00
iommu.c [POWERPC] Use 4kB iommu pages even on 64kB-page systems 2006-11-01 14:52:48 +11:00
ipl_parms.h
irq.c [POWERPC] Fix up after irq changes 2006-10-07 22:08:26 +10:00
irq.h [POWERPC] Fix up after irq changes 2006-10-07 22:08:26 +10:00
it_exp_vpd_panel.h [POWERPC] iseries: Make ItExtVpdPanel private to iSeries 2006-07-13 18:42:29 +10:00
it_lp_naca.h [POWERPC] iseries: Move ItLpNaca into platforms/iseries 2006-07-13 18:42:52 +10:00
Kconfig [POWERPC] iseries: A new iSeries console 2006-07-13 18:51:22 +10:00
ksyms.c
lpardata.c [POWERPC] iseries: Move ItLpNaca into platforms/iseries 2006-07-13 18:42:52 +10:00
lpevents.c [POWERPC] Fix up after irq changes 2006-10-07 22:08:26 +10:00
main_store.h [POWERPC] iseries: remove some gcc 4.1 warnings 2006-08-25 13:27:35 +10:00
Makefile [PATCH] powerpc: make iSeries flattened device tree dynamic 2006-05-24 16:08:57 +10:00
mf.c [POWERPC] Fix up after irq changes 2006-10-07 22:08:26 +10:00
misc.S [PATCH] powerpc: Remove lppaca structure from the PACA 2006-01-13 21:17:39 +11:00
naca.h
pci.c [POWERPC] iSeries does not need pcibios_fixup_resources 2006-10-03 16:50:11 +10:00
pci.h
proc.c [POWERPC] Clean up it_lp_queue.h 2006-06-28 15:18:55 +10:00
processor_vpd.h
release_data.h
setup.c [POWERPC] Consolidate feature fixup code 2006-10-25 11:42:10 +10:00
setup.h [PATCH] powerpc: split device tree stuff out of iseries/setup.c 2006-05-24 16:08:57 +10:00
smp.c [POWERPC] Fix iseries/smp.c for irq breakage 2006-10-07 10:10:30 +10:00
smp.h [POWERPC] Fix iseries/smp.c for irq breakage 2006-10-07 10:10:30 +10:00
spcomm_area.h
viopath.c [POWERPC] Fix up after irq changes 2006-10-07 22:08:26 +10:00
vpd_areas.h
vpdinfo.c [POWERPC] iseries: Fix a compiler warning in platforms/iseries/vpdinfo.c 2006-07-13 18:43:12 +10:00