Skip to content

Commit 495310e

Browse files
jgross1KAGA-KOKO
authored andcommitted
x86/paravirt: Remove unneeded mmu related paravirt ops bits
There is no need to have 32-bit code for CONFIG_PGTABLE_LEVELS >= 4. Remove it. Signed-off-by: Juergen Gross <jgross@suse.com> Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Cc: xen-devel@lists.xenproject.org Cc: virtualization@lists.linux-foundation.org Cc: akataria@vmware.com Cc: rusty@rustcorp.com.au Cc: boris.ostrovsky@oracle.com Cc: hpa@zytor.com Link: https://lkml.kernel.org/r/20180828074026.820-16-jgross@suse.com
1 parent fdc0269 commit 495310e

File tree

1 file changed

+3
-17
lines changed

1 file changed

+3
-17
lines changed

arch/x86/include/asm/paravirt.h

Lines changed: 3 additions & 17 deletions
Original file line numberDiff line numberDiff line change
@@ -506,25 +506,14 @@ static inline pud_t __pud(pudval_t val)
506506
{
507507
pudval_t ret;
508508

509-
if (sizeof(pudval_t) > sizeof(long))
510-
ret = PVOP_CALLEE2(pudval_t, mmu.make_pud, val, (u64)val >> 32);
511-
else
512-
ret = PVOP_CALLEE1(pudval_t, mmu.make_pud, val);
509+
ret = PVOP_CALLEE1(pudval_t, mmu.make_pud, val);
513510

514511
return (pud_t) { ret };
515512
}
516513

517514
static inline pudval_t pud_val(pud_t pud)
518515
{
519-
pudval_t ret;
520-
521-
if (sizeof(pudval_t) > sizeof(long))
522-
ret = PVOP_CALLEE2(pudval_t, mmu.pud_val,
523-
pud.pud, (u64)pud.pud >> 32);
524-
else
525-
ret = PVOP_CALLEE1(pudval_t, mmu.pud_val, pud.pud);
526-
527-
return ret;
516+
return PVOP_CALLEE1(pudval_t, mmu.pud_val, pud.pud);
528517
}
529518

530519
static inline void pud_clear(pud_t *pudp)
@@ -536,10 +525,7 @@ static inline void set_p4d(p4d_t *p4dp, p4d_t p4d)
536525
{
537526
p4dval_t val = native_p4d_val(p4d);
538527

539-
if (sizeof(p4dval_t) > sizeof(long))
540-
PVOP_VCALL3(mmu.set_p4d, p4dp, val, (u64)val >> 32);
541-
else
542-
PVOP_VCALL2(mmu.set_p4d, p4dp, val);
528+
PVOP_VCALL2(mmu.set_p4d, p4dp, val);
543529
}
544530

545531
#if CONFIG_PGTABLE_LEVELS >= 5

0 commit comments

Comments
 (0)