ion: rockchip: fix snapshot alignment fault on armv8
authorHuang, Tao <huangtao@rock-chips.com>
Tue, 23 Dec 2014 13:36:07 +0000 (21:36 +0800)
committerHuang, Tao <huangtao@rock-chips.com>
Tue, 23 Dec 2014 13:36:07 +0000 (21:36 +0800)
commit22eb70f0632f26bd0ab604841979279ce6b4535e
tree23a75ebc90975ac36f155fe58d23aff0f9eb42c4
parente93588288ec31cef005be6304e562250f469a2e7
ion: rockchip: fix snapshot alignment fault on armv8

Fix this bug:
Unhandled fault: alignment fault (0x96000061) at 0xffffff8000006016
Internal error: : 96000061 [#1] PREEMPT SMP
Modules linked in: dc_fbdev(O) pvrsrvkm(O)
CPU: 0 PID: 125 Comm: Binder_2 Tainted: G           O 3.10.0 #36
task: ffffffc0530f7380 ti: ffffffc0531c0000 task.ti: ffffffc0531c0000
PC is at memcpy+0x2c/0x60
LR is at vsnprintf+0x100/0x598
[<ffffffc0002e093c>] memcpy+0x2c/0x60
[<ffffffc00018b3bc>] seq_vprintf+0x48/0x84
[<ffffffc00018b44c>] seq_printf+0x54/0x60
[<ffffffc00063a238>] ion_alloc+0x4fc/0x778
[<ffffffc00063a98c>] ion_ioctl+0x164/0x360
[<ffffffc00017bfa8>] vfs_ioctl+0x20/0x3c
[<ffffffc00017c8ac>] do_vfs_ioctl+0x474/0x540
[<ffffffc00017c9d4>] SyS_ioctl+0x5c/0x88

pgprot_noncached will map buffer as MT_DEVICE, but
All store accesses to Device memory use the asynchronous abort mechanism on
Cortex-A53.

Signed-off-by: Huang, Tao <huangtao@rock-chips.com>
drivers/staging/android/ion/rockchip/rockchip_ion_snapshot.c