Commit b3fefbb
nouveau/svm: fix missing folio unlock + put after make_device_exclusive_range()
In case we have to retry the loop, we are missing to unlock+put the
folio. In that case, we will keep failing make_device_exclusive_range()
because we cannot grab the folio lock, and even return from the function
with the folio locked and referenced, effectively never succeeding the
make_device_exclusive_range().
While at it, convert the other unlock+put to use a folio as well.
This was found by code inspection.
Fixes: 8f18716 ("nouveau/svm: implement atomic SVM access")
Signed-off-by: David Hildenbrand <[email protected]>
Reviewed-by: Alistair Popple <[email protected]>
Tested-by: Alistair Popple <[email protected]>
Signed-off-by: Danilo Krummrich <[email protected]>
Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]1 parent a8972d5 commit b3fefbb
1 file changed
+7
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
590 | 590 | | |
591 | 591 | | |
592 | 592 | | |
| 593 | + | |
593 | 594 | | |
594 | 595 | | |
595 | 596 | | |
| |||
616 | 617 | | |
617 | 618 | | |
618 | 619 | | |
| 620 | + | |
619 | 621 | | |
620 | 622 | | |
621 | 623 | | |
622 | 624 | | |
623 | 625 | | |
624 | 626 | | |
| 627 | + | |
| 628 | + | |
| 629 | + | |
625 | 630 | | |
626 | 631 | | |
627 | 632 | | |
| |||
637 | 642 | | |
638 | 643 | | |
639 | 644 | | |
640 | | - | |
641 | | - | |
| 645 | + | |
| 646 | + | |
642 | 647 | | |
643 | 648 | | |
644 | 649 | | |
| |||
0 commit comments