mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-30 03:27:44 -04:00
vmw_balloon: fix inflation with batching
Embarrassingly, the recent fix introduced worse problem than it solved,
causing the balloon not to inflate. The VM informed the hypervisor that
the pages for lock/unlock are sitting in the wrong address, as it used
the page that is used the uninitialized page variable.
Fixes: b23220fe05 ("vmw_balloon: fixing double free when batching mode is off")
Cc: [email protected]
Reviewed-by: Xavier Deguillard <[email protected]>
Signed-off-by: Nadav Amit <[email protected]>
Signed-off-by: Greg Kroah-Hartman <[email protected]>
This commit is contained in:
parent
7daf201d7f
commit
90d72ce079
1 changed files with 2 additions and 2 deletions
|
|
@ -467,7 +467,7 @@ static int vmballoon_send_batched_lock(struct vmballoon *b,
|
|||
unsigned int num_pages, bool is_2m_pages, unsigned int *target)
|
||||
{
|
||||
unsigned long status;
|
||||
unsigned long pfn = page_to_pfn(b->page);
|
||||
unsigned long pfn = PHYS_PFN(virt_to_phys(b->batch_page));
|
||||
|
||||
STATS_INC(b->stats.lock[is_2m_pages]);
|
||||
|
||||
|
|
@ -515,7 +515,7 @@ static bool vmballoon_send_batched_unlock(struct vmballoon *b,
|
|||
unsigned int num_pages, bool is_2m_pages, unsigned int *target)
|
||||
{
|
||||
unsigned long status;
|
||||
unsigned long pfn = page_to_pfn(b->page);
|
||||
unsigned long pfn = PHYS_PFN(virt_to_phys(b->batch_page));
|
||||
|
||||
STATS_INC(b->stats.unlock[is_2m_pages]);
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue