Commit 562e514a authored by Elliot Berman's avatar Elliot Berman Committed by Todd Kjos
Browse files

ANDROID: virt: gunyah: Unpin, not folio_put, in gunyah_gup_reclaim_parcel



gunyah_gup_reclaim_parcel incorrectly used folio_put() to drop the
refcount for the pinned page. This leaves the folio pincount elevated.
If the VM initialization fails in Gunyah and Linux needs to reclaim the
mem parcel, mm will complain that the pincount was higher than refcount.

This reclaim path is not normally used, as memory backed by parcels is
reclaimed in the demand paging path if the VM starts successfully.

Bug: 358605784
Bug: 367452992
Fixes: 296cceed ("ANDROID: virt: gunyah: Add gup based demand paging support")
Change-Id: I88454e1f0527632f1f78345e3833d16cbc098467
Signed-off-by: default avatarElliot Berman <quic_eberman@quicinc.com>
(cherry picked from commit 1d520bc9)
parent 4284beb7
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment