weird reservation issues

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi Christian

In amdgpu_cs_parser_bos(), it calls ttm_eu_backoff_reservation() if @need_pages not empty, is it safe ?

You see that if two threads in parallel running in cs_parser_bos(), if the thread1 did call backoff_reservation and continue, that leaves
All following reservation functions on root BO executed without protection from the lock, Meanwhile if this time thread2 call cs_parser_bos() in parallel, it can
Get the lock of the reservation object on root BO (assume thread 1/2 share the same VM) immediately, so both of those threads consider they are
Under protection of lock of reservation on the root bo. Do you think it's a race issue ?

You know that I recently hit BUG() in reservation.c, and also found some weird bugs can be fixed by removing the kfree(obj->staged)
In reservation_object_reserve_shared(), and I think you right on the "staged" part that it shouldn't be freed if everything go with rules (
Always held the lock of the bo)


Thanks
/Monk

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://lists.freedesktop.org/archives/amd-gfx/attachments/20180228/756e07eb/attachment.html>


[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux