* [PATCH] - UV fix for size of hub mappings
@ 2008-09-25 12:52 Jack Steiner
2008-09-27 17:42 ` Ingo Molnar
0 siblings, 1 reply; 4+ messages in thread
From: Jack Steiner @ 2008-09-25 12:52 UTC (permalink / raw)
To: mingo, tglx; +Cc: linux-kernel
Fix the size of the mappings of UV hub registers. Size must
be a function of the maximum node number within the SSI.
Signed-off-by: Jack Steiner <steiner@sgi.com>
---
arch/x86/kernel/genx2apic_uv_x.c | 13 +++++++------
1 file changed, 7 insertions(+), 6 deletions(-)
Index: linux/arch/x86/kernel/genx2apic_uv_x.c
===================================================================
--- linux.orig/arch/x86/kernel/genx2apic_uv_x.c 2008-08-17 01:21:43.000000000 -0500
+++ linux/arch/x86/kernel/genx2apic_uv_x.c 2008-08-17 07:24:38.000000000 -0500
@@ -286,12 +286,13 @@ static __init void map_low_mmrs(void)
enum map_type {map_wb, map_uc};
-static __init void map_high(char *id, unsigned long base, int shift, enum map_type map_type)
+static __init void map_high(char *id, unsigned long base, int shift,
+ int max_pnode, enum map_type map_type)
{
unsigned long bytes, paddr;
paddr = base << shift;
- bytes = (1UL << shift);
+ bytes = (1UL << shift) * (max_pnode + 1);
printk(KERN_INFO "UV: Map %s_HI 0x%lx - 0x%lx\n", id, paddr,
paddr + bytes);
if (map_type == map_uc)
@@ -307,7 +308,7 @@ static __init void map_gru_high(int max_
gru.v = uv_read_local_mmr(UVH_RH_GAM_GRU_OVERLAY_CONFIG_MMR);
if (gru.s.enable)
- map_high("GRU", gru.s.base, shift, map_wb);
+ map_high("GRU", gru.s.base, shift, max_pnode, map_wb);
}
static __init void map_config_high(int max_pnode)
@@ -317,7 +318,7 @@ static __init void map_config_high(int m
cfg.v = uv_read_local_mmr(UVH_RH_GAM_CFG_OVERLAY_CONFIG_MMR);
if (cfg.s.enable)
- map_high("CONFIG", cfg.s.base, shift, map_uc);
+ map_high("CONFIG", cfg.s.base, shift, max_pnode, map_uc);
}
static __init void map_mmr_high(int max_pnode)
@@ -327,7 +328,7 @@ static __init void map_mmr_high(int max_
mmr.v = uv_read_local_mmr(UVH_RH_GAM_MMR_OVERLAY_CONFIG_MMR);
if (mmr.s.enable)
- map_high("MMR", mmr.s.base, shift, map_uc);
+ map_high("MMR", mmr.s.base, shift, max_pnode, map_uc);
}
static __init void map_mmioh_high(int max_pnode)
@@ -337,7 +338,7 @@ static __init void map_mmioh_high(int ma
mmioh.v = uv_read_local_mmr(UVH_RH_GAM_MMIOH_OVERLAY_CONFIG_MMR);
if (mmioh.s.enable)
- map_high("MMIOH", mmioh.s.base, shift, map_uc);
+ map_high("MMIOH", mmioh.s.base, shift, max_pnode, map_uc);
}
static __init void uv_rtc_init(void)
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] - UV fix for size of hub mappings
2008-09-25 12:52 [PATCH] - UV fix for size of hub mappings Jack Steiner
@ 2008-09-27 17:42 ` Ingo Molnar
2008-09-27 19:56 ` Jack Steiner
0 siblings, 1 reply; 4+ messages in thread
From: Ingo Molnar @ 2008-09-27 17:42 UTC (permalink / raw)
To: Jack Steiner; +Cc: tglx, linux-kernel, H. Peter Anvin, Yinghai Lu
* Jack Steiner <steiner@sgi.com> wrote:
> Fix the size of the mappings of UV hub registers. Size must be a
> function of the maximum node number within the SSI.
>
> Signed-off-by: Jack Steiner <steiner@sgi.com>
applied to tip/x86/uv, thanks Jack!
i'm wondering, the code still has a couple of ZZZ fixmes like:
#ifdef ZZZ /* Needs x2apic patch */
static void uv_send_IPI_self(int vector)
{
apic_write(APIC_SELF_IPI, vector);
}
#endif
x2apic support is available in tip/master, so it would be nice to glue
UV to generic x2apic support properly and remove duplication and fixmes.
For example, do we really need apic_x2apic_uv_x, or could we use
apic_x2apic_cluster?
Ingo
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] - UV fix for size of hub mappings
2008-09-27 17:42 ` Ingo Molnar
@ 2008-09-27 19:56 ` Jack Steiner
2008-09-27 20:02 ` Ingo Molnar
0 siblings, 1 reply; 4+ messages in thread
From: Jack Steiner @ 2008-09-27 19:56 UTC (permalink / raw)
To: Ingo Molnar; +Cc: tglx, linux-kernel, H. Peter Anvin, Yinghai Lu
On Sat, Sep 27, 2008 at 07:42:33PM +0200, Ingo Molnar wrote:
>
> * Jack Steiner <steiner@sgi.com> wrote:
>
> > Fix the size of the mappings of UV hub registers. Size must be a
> > function of the maximum node number within the SSI.
> >
> > Signed-off-by: Jack Steiner <steiner@sgi.com>
>
> applied to tip/x86/uv, thanks Jack!
>
> i'm wondering, the code still has a couple of ZZZ fixmes like:
>
> #ifdef ZZZ /* Needs x2apic patch */
> static void uv_send_IPI_self(int vector)
> {
> apic_write(APIC_SELF_IPI, vector);
> }
> #endif
>
> x2apic support is available in tip/master, so it would be nice to glue
> UV to generic x2apic support properly and remove duplication and fixmes.
Good point. I'll send the fixes to you early next week. Recently,
I've been focused on a distro release which is still waiting for
the x2apic code. However, I don't need to wait to fix this upstream...
> For example, do we really need apic_x2apic_uv_x, or could we use
> apic_x2apic_cluster?
Unfortunately, we really need a uv genapic. IPIs on large UV systems
can't use an x2apic model. Because of the size of our large systems, APICIDs
in the cpu MSRs are not globally unique. We have a special feature
in the UV chipset that must be used for on large systems for IPIs.
Small & medium sized system can and do use the x2apic genapic.
--- jack
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] - UV fix for size of hub mappings
2008-09-27 19:56 ` Jack Steiner
@ 2008-09-27 20:02 ` Ingo Molnar
0 siblings, 0 replies; 4+ messages in thread
From: Ingo Molnar @ 2008-09-27 20:02 UTC (permalink / raw)
To: Jack Steiner; +Cc: tglx, linux-kernel, H. Peter Anvin, Yinghai Lu
* Jack Steiner <steiner@sgi.com> wrote:
> > x2apic support is available in tip/master, so it would be nice to
> > glue UV to generic x2apic support properly and remove duplication
> > and fixmes.
>
> Good point. I'll send the fixes to you early next week. Recently, I've
> been focused on a distro release which is still waiting for the x2apic
> code. However, I don't need to wait to fix this upstream...
great!
> > For example, do we really need apic_x2apic_uv_x, or could we use
> > apic_x2apic_cluster?
>
> Unfortunately, we really need a uv genapic. IPIs on large UV systems
> can't use an x2apic model. Because of the size of our large systems,
> APICIDs in the cpu MSRs are not globally unique. We have a special
> feature in the UV chipset that must be used for on large systems for
> IPIs. Small & medium sized system can and do use the x2apic genapic.
not a problem really - it's not really complex or intrusive, we just
want to make sure all unnecessary duplication is eliminated.
Ingo
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2008-09-27 20:02 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-09-25 12:52 [PATCH] - UV fix for size of hub mappings Jack Steiner
2008-09-27 17:42 ` Ingo Molnar
2008-09-27 19:56 ` Jack Steiner
2008-09-27 20:02 ` Ingo Molnar
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox
all inboxes | Powered by JetHome®