Open GoogleCodeExporter opened 8 years ago
To supplement described above,
[the expected behavior]
If the process wants using CPU to access the buffer, it should call
gralloc_lock/gralloc_unlock during the buffer access.
gralloc_lock: should call "to_cpu cache sync" to invalidate CPU cache
gralloc_unlock: should call "to_dev cache sync" to clean CPU cache
[actual behavior]
there is no interface in ion to do "to_cpu" and "to_dev" seperately, then we
should find a way to resolve it.
[solution]
1. gralloc : add the "to_cpu" cache sync in gralloc_lock, and the "to_dev"
cache sync in gralloc_unlock.
2. libion : add the flag in the interface ion_sync_fd to tell "to_cpu" or
"to_dev", which make gralloc call according to its situation.
3. kernel : Modify the implementation of the ioctl ion_sync_fd, and do the
different cache sync operation according to the flags.
Original comment by xu.mar...@gmail.com
on 25 May 2015 at 10:52
Original issue reported on code.google.com by
xu.mar...@gmail.com
on 20 May 2015 at 3:40