Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

powerpc/slb: Use a local to avoid multiple calls to get_slb_shadow()

For no reason other than it looks ugly.

Signed-off-by: Michael Ellerman <mpe@ellerman.id.au>

+5 -5
+5 -5
arch/powerpc/mm/slb.c
··· 62 62 unsigned long flags, 63 63 enum slb_index index) 64 64 { 65 + struct slb_shadow *p = get_slb_shadow(); 66 + 65 67 /* 66 68 * Clear the ESID first so the entry is not valid while we are 67 69 * updating it. No write barriers are needed here, provided 68 70 * we only update the current CPU's SLB shadow buffer. 69 71 */ 70 - get_slb_shadow()->save_area[index].esid = 0; 71 - get_slb_shadow()->save_area[index].vsid = 72 - cpu_to_be64(mk_vsid_data(ea, ssize, flags)); 73 - get_slb_shadow()->save_area[index].esid = 74 - cpu_to_be64(mk_esid_data(ea, ssize, index)); 72 + p->save_area[index].esid = 0; 73 + p->save_area[index].vsid = cpu_to_be64(mk_vsid_data(ea, ssize, flags)); 74 + p->save_area[index].esid = cpu_to_be64(mk_esid_data(ea, ssize, index)); 75 75 } 76 76 77 77 static inline void slb_shadow_clear(enum slb_index index)