Revision 1ff9b17cedb39bc78f9e3f82485765f9b467177d authored by Yong Wu on 25 September 2017, 10:15:26 UTC, committed by Joerg Roedel on 27 September 2017, 14:58:28 UTC
The ARM short descriptor has already limited the physical address to 32bit after the commit <76557391433c> ("iommu/io-pgtable: Sanitise map/unmap addresses"). But in MediaTek 4GB mode, the physical address is from 0x1_0000_0000 to 0x1_ffff_ffff. this will cause: WARNING: CPU: 4 PID: 3900 at xxx/drivers/iommu/io-pgtable-arm-v7s.c:482 arm_v7s_map+0x40/0xf8 Modules linked in: CPU: 4 PID: 3900 Comm: weston Tainted: G S W 4.9.44 #1 Hardware name: MediaTek MT2712m1v1 board (DT) task: ffffffc0eaa5b280 task.stack: ffffffc0e9858000 PC is at arm_v7s_map+0x40/0xf8 LR is at mtk_iommu_map+0x64/0x90 pc : [<ffffff80085b09e8>] lr : [<ffffff80085b29fc>] pstate: 000001c5 sp : ffffffc0e985b920 x29: ffffffc0e985b920 x28: 0000000127d00000 x27: 0000000000100000 x26: ffffff8008f9e000 x25: 0000000000000003 x24: 0000000000100000 x23: 0000000127d00000 x22: 00000000ff800000 x21: ffffffc0f7ec8ce0 x20: 0000000000000003 x19: 0000000000000003 x18: 0000000000000002 x17: 0000007f7e5d72c0 x16: ffffff80082b0f08 x15: 0000000000000001 x14: 000000000000003f x13: 0000000000000000 x12: 0000000000000028 x11: 0088000000000000 x10: 0000000000000000 x9 : ffffff80092fa000 x8 : ffffffc0e9858000 x7 : ffffff80085b29d8 x6 : 0000000000000000 x5 : ffffff80085b09a8 x4 : 0000000000000003 x3 : 0000000000100000 x2 : 0000000127d00000 x1 : 00000000ff800000 x0 : 0000000000000001 ... Call trace: [<ffffff80085b09e8>] arm_v7s_map+0x40/0xf8 [<ffffff80085b29fc>] mtk_iommu_map+0x64/0x90 [<ffffff80085ab5f8>] iommu_map+0x100/0x3a0 [<ffffff80085ab99c>] default_iommu_map_sg+0x104/0x168 [<ffffff80085aead8>] iommu_dma_alloc+0x238/0x3f8 [<ffffff8008098b30>] __iommu_alloc_attrs+0xa8/0x260 [<ffffff80085f364c>] mtk_drm_gem_create+0xac/0x180 [<ffffff80085f3894>] mtk_drm_gem_dumb_create+0x54/0xc8 [<ffffff80085d576c>] drm_mode_create_dumb_ioctl+0xa4/0xd8 [<ffffff80085cb2a0>] drm_ioctl+0x1c0/0x490 In order to satify this, Limit the physical address to 32bit. Signed-off-by: Yong Wu <yong.wu@mediatek.com> Acked-by: Will Deacon <will.deacon@arm.com> Signed-off-by: Joerg Roedel <jroedel@suse.de>
1 parent 5c62c1c
File | Mode | Size |
---|---|---|
partitions | ||
Kconfig | -rw-r--r-- | 6.1 KB |
Kconfig.iosched | -rw-r--r-- | 2.7 KB |
Makefile | -rw-r--r-- | 1.4 KB |
badblocks.c | -rw-r--r-- | 14.5 KB |
bfq-cgroup.c | -rw-r--r-- | 33.0 KB |
bfq-iosched.c | -rw-r--r-- | 163.7 KB |
bfq-iosched.h | -rw-r--r-- | 31.4 KB |
bfq-wf2q.c | -rw-r--r-- | 52.1 KB |
bio-integrity.c | -rw-r--r-- | 13.9 KB |
bio.c | -rw-r--r-- | 51.1 KB |
blk-cgroup.c | -rw-r--r-- | 37.6 KB |
blk-core.c | -rw-r--r-- | 95.5 KB |
blk-exec.c | -rw-r--r-- | 2.9 KB |
blk-flush.c | -rw-r--r-- | 16.6 KB |
blk-integrity.c | -rw-r--r-- | 12.1 KB |
blk-ioc.c | -rw-r--r-- | 10.9 KB |
blk-lib.c | -rw-r--r-- | 9.8 KB |
blk-map.c | -rw-r--r-- | 5.9 KB |
blk-merge.c | -rw-r--r-- | 19.7 KB |
blk-mq-cpumap.c | -rw-r--r-- | 1.7 KB |
blk-mq-debugfs.c | -rw-r--r-- | 23.4 KB |
blk-mq-debugfs.h | -rw-r--r-- | 2.1 KB |
blk-mq-pci.c | -rw-r--r-- | 1.6 KB |
blk-mq-rdma.c | -rw-r--r-- | 1.7 KB |
blk-mq-sched.c | -rw-r--r-- | 14.5 KB |
blk-mq-sched.h | -rw-r--r-- | 2.8 KB |
blk-mq-sysfs.c | -rw-r--r-- | 8.2 KB |
blk-mq-tag.c | -rw-r--r-- | 11.4 KB |
blk-mq-tag.h | -rw-r--r-- | 2.3 KB |
blk-mq-virtio.c | -rw-r--r-- | 1.7 KB |
blk-mq.c | -rw-r--r-- | 70.5 KB |
blk-mq.h | -rw-r--r-- | 4.0 KB |
blk-settings.c | -rw-r--r-- | 28.7 KB |
blk-softirq.c | -rw-r--r-- | 4.3 KB |
blk-stat.c | -rw-r--r-- | 5.5 KB |
blk-stat.h | -rw-r--r-- | 5.5 KB |
blk-sysfs.c | -rw-r--r-- | 23.4 KB |
blk-tag.c | -rw-r--r-- | 10.0 KB |
blk-throttle.c | -rw-r--r-- | 67.6 KB |
blk-timeout.c | -rw-r--r-- | 5.9 KB |
blk-wbt.c | -rw-r--r-- | 17.6 KB |
blk-wbt.h | -rw-r--r-- | 4.0 KB |
blk-zoned.c | -rw-r--r-- | 7.6 KB |
blk.h | -rw-r--r-- | 10.9 KB |
bounce.c | -rw-r--r-- | 6.4 KB |
bsg-lib.c | -rw-r--r-- | 7.1 KB |
bsg.c | -rw-r--r-- | 22.9 KB |
cfq-iosched.c | -rw-r--r-- | 127.1 KB |
cmdline-parser.c | -rw-r--r-- | 4.9 KB |
compat_ioctl.c | -rw-r--r-- | 10.8 KB |
deadline-iosched.c | -rw-r--r-- | 11.2 KB |
elevator.c | -rw-r--r-- | 26.8 KB |
genhd.c | -rw-r--r-- | 47.2 KB |
ioctl.c | -rw-r--r-- | 15.0 KB |
ioprio.c | -rw-r--r-- | 5.0 KB |
kyber-iosched.c | -rw-r--r-- | 21.0 KB |
mq-deadline.c | -rw-r--r-- | 16.8 KB |
noop-iosched.c | -rw-r--r-- | 2.6 KB |
opal_proto.h | -rw-r--r-- | 9.3 KB |
partition-generic.c | -rw-r--r-- | 16.7 KB |
scsi_ioctl.c | -rw-r--r-- | 20.0 KB |
sed-opal.c | -rw-r--r-- | 58.5 KB |
t10-pi.c | -rw-r--r-- | 4.9 KB |
![swh spinner](/static/img/swh-spinner.gif)
Computing file changes ...