diff mbox series

[SRU,jammy/focal,-gcp,1/1] UBUNTU: SAUCE: (no-up) x86/mm: Fixing notify_range_enc_status_changed incorrect argument

Message ID 20231025021722.43875-2-john.cabaj@canonical.com
State New
Headers show
Series [SRU,jammy/focal,-gcp,1/1] UBUNTU: SAUCE: (no-up) x86/mm: Fixing notify_range_enc_status_changed incorrect argument | expand

Commit Message

John Cabaj Oct. 25, 2023, 2:17 a.m. UTC
BugLink: https://bugs.launchpad.net/bugs/2040337

ac3f9c9f1b37 introduced change to notify_range_enc_status_changed()
to accept page size instead of number of pages, but function was not updated.

Signed-off-by: John Cabaj <john.cabaj@canonical.com>
---
 arch/x86/mm/pat/set_memory.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/arch/x86/mm/pat/set_memory.c b/arch/x86/mm/pat/set_memory.c
index d72661f7c8ff..a749fde9a772 100644
--- a/arch/x86/mm/pat/set_memory.c
+++ b/arch/x86/mm/pat/set_memory.c
@@ -2040,7 +2040,7 @@  static int __set_memory_enc_dec(unsigned long addr, int numpages, bool enc)
 	 * Notify hypervisor that a given memory range is mapped encrypted
 	 * or decrypted.
 	 */
-	notify_range_enc_status_changed(addr, numpages, enc);
+	notify_range_enc_status_changed(addr, numpages << PAGE_SHIFT, enc);
 
 	return ret;
 }