Commit 1a8f6f97 authored by Jeremy Kerr's avatar Jeremy Kerr Committed by Benjamin Herrenschmidt

powerpc: Make slb_shadow a local

The only external user of slb_shadow is the pseries lpar code, and it
can access through the paca array instead.
Signed-off-by: default avatarJeremy Kerr <jk@ozlabs.org>
Signed-off-by: default avatarBenjamin Herrenschmidt <benh@kernel.crashing.org>
parent d317ac17
...@@ -132,8 +132,6 @@ struct slb_shadow { ...@@ -132,8 +132,6 @@ struct slb_shadow {
} save_area[SLB_NUM_BOLTED]; } save_area[SLB_NUM_BOLTED];
} ____cacheline_aligned; } ____cacheline_aligned;
extern struct slb_shadow slb_shadow[];
/* /*
* Layout of entries in the hypervisor's dispatch trace log buffer. * Layout of entries in the hypervisor's dispatch trace log buffer.
*/ */
......
...@@ -99,7 +99,7 @@ static inline void free_lppacas(void) { } ...@@ -99,7 +99,7 @@ static inline void free_lppacas(void) { }
* 3 persistent SLBs are registered here. The buffer will be zero * 3 persistent SLBs are registered here. The buffer will be zero
* initially, hence will all be invaild until we actually write them. * initially, hence will all be invaild until we actually write them.
*/ */
struct slb_shadow slb_shadow[] __cacheline_aligned = { static struct slb_shadow slb_shadow[] __cacheline_aligned = {
[0 ... (NR_CPUS-1)] = { [0 ... (NR_CPUS-1)] = {
.persistent = cpu_to_be32(SLB_NUM_BOLTED), .persistent = cpu_to_be32(SLB_NUM_BOLTED),
.buffer_length = cpu_to_be32(sizeof(struct slb_shadow)), .buffer_length = cpu_to_be32(sizeof(struct slb_shadow)),
......
...@@ -92,7 +92,7 @@ void vpa_init(int cpu) ...@@ -92,7 +92,7 @@ void vpa_init(int cpu)
* PAPR says this feature is SLB-Buffer but firmware never * PAPR says this feature is SLB-Buffer but firmware never
* reports that. All SPLPAR support SLB shadow buffer. * reports that. All SPLPAR support SLB shadow buffer.
*/ */
addr = __pa(&slb_shadow[cpu]); addr = __pa(paca[cpu].slb_shadow_ptr);
if (firmware_has_feature(FW_FEATURE_SPLPAR)) { if (firmware_has_feature(FW_FEATURE_SPLPAR)) {
ret = register_slb_shadow(hwcpu, addr); ret = register_slb_shadow(hwcpu, addr);
if (ret) if (ret)
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment