Files
rocm-systems/src
Philip Yang a11cb2a633 libhsakmt: child process destroy vm objects in all apertures
child process clone vm objects from svm->apertures if parent process
doesn't free memory before fork. fmm_clear_all_mem suppose to clear the
apertures in forked child process but this only works if gpu_vm is not
NULL. parent process call hsaKmtCloseKFD reset gpu_vm to NULL and then
fork, then child process will not clear svm->apertures.

As a result, the child process will allocate vm object with same address
and add to aperture, there are duplicate vm objects with same address
in aperture. Then mapping to GPU will find the wrong vm object and
create incorrect GPU mapping cause rocrtst IPC test VM fault. The issue
happened with HSA_USERPTR_FOR_PAGED_MEM=1.

The fix is to clear vm objects in all apertures in clear_after_fork.

Change-Id: I92e42a967075a634a3f475b915c8242d82077ecb
Signed-off-by: Philip Yang <Philip.Yang@amd.com>
2019-08-20 13:31:37 -04:00
..
2018-12-13 10:17:12 -05:00
2019-04-30 15:40:50 -05:00
2017-05-31 14:38:59 -04:00
2017-05-31 14:38:59 -04:00
2019-08-01 23:10:28 -04:00
2019-03-28 17:17:40 -04:00
2019-08-01 23:10:28 -04:00
2017-05-31 14:38:59 -04:00
2018-07-08 22:38:22 -04:00
2018-07-08 22:38:22 -04:00
2018-01-25 16:48:17 -05:00
2018-01-25 16:48:17 -05:00