Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit a93b92cb authored by Minming Qi's avatar Minming Qi
Browse files

Merge android-4.9.122 (54068d61) into msm-4.9



* refs/heads/tmp-54068d61:
  Linux 4.9.122
  x86/speculation/l1tf: Exempt zeroed PTEs from inversion

Change-Id: Ib8fcbf79cefcdfbb9c313ef3953e0d0dfa1f4d67
Signed-off-by: default avatarBlagovest Kolenichev <bkolenichev@codeaurora.org>
Signed-off-by: default avatarMinming Qi <mqi@codeaurora.org>
parents 1f33e242 54068d61
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
VERSION = 4
PATCHLEVEL = 9
SUBLEVEL = 121
SUBLEVEL = 122
EXTRAVERSION =
NAME = Roaring Lionus

+10 −1
Original line number Diff line number Diff line
@@ -4,9 +4,18 @@

#ifndef __ASSEMBLY__

/*
 * A clear pte value is special, and doesn't get inverted.
 *
 * Note that even users that only pass a pgprot_t (rather
 * than a full pte) won't trigger the special zero case,
 * because even PAGE_NONE has _PAGE_PROTNONE | _PAGE_ACCESSED
 * set. So the all zero case really is limited to just the
 * cleared page table entry case.
 */
static inline bool __pte_needs_invert(u64 val)
{
	return !(val & _PAGE_PRESENT);
	return val && !(val & _PAGE_PRESENT);
}

/* Get a mask to xor with the page table entry to get the correct pfn. */