From f38492669f95ecd89c6d80d48f80a9c826201f4a Mon Sep 17 00:00:00 2001 From: Colin Ngam Date: Tue, 10 May 2005 09:12:00 -0700 Subject: [PATCH] --- yaml --- r: 3981 b: refs/heads/master c: 71030994a77e7689a7a792128b131ef7a10b9f74 h: refs/heads/master i: 3979: dba0fd66bef87612b5f26fce242874b499595307 v: v3 --- [refs] | 2 +- trunk/include/asm-ia64/sn/addrs.h | 17 ++++++++++++----- 2 files changed, 13 insertions(+), 6 deletions(-) diff --git a/[refs] b/[refs] index ef9c411da14f..90a82308e19b 100644 --- a/[refs] +++ b/[refs] @@ -1,2 +1,2 @@ --- -refs/heads/master: 71a5d027c90dd7e14ddaaf22358ff5138ba89ec9 +refs/heads/master: 71030994a77e7689a7a792128b131ef7a10b9f74 diff --git a/trunk/include/asm-ia64/sn/addrs.h b/trunk/include/asm-ia64/sn/addrs.h index 1bfdfb4d7b01..103d745dc5f2 100644 --- a/trunk/include/asm-ia64/sn/addrs.h +++ b/trunk/include/asm-ia64/sn/addrs.h @@ -216,6 +216,10 @@ #define TIO_SWIN_WIDGETNUM(x) (((x) >> TIO_SWIN_SIZE_BITS) & TIO_SWIN_WIDGET_MASK) +#define TIO_IOSPACE_ADDR(n,x) \ + /* Move in the Chiplet ID for TIO Local Block MMR */ \ + (REMOTE_ADDR(n,x) | 1UL << (NASID_SHIFT - 2)) + /* * The following macros produce the correct base virtual address for * the hub registers. The REMOTE_HUB_* macro produce @@ -233,13 +237,16 @@ #define REMOTE_HUB_ADDR(n,x) \ ((n & 1) ? \ /* TIO: */ \ - ((volatile u64 *)(GLOBAL_MMR_ADDR(n,x))) \ - : /* SHUB: */ \ - (((x) & BWIN_TOP) ? ((volatile u64 *)(GLOBAL_MMR_ADDR(n,x)))\ + (is_shub2() ? \ + /* TIO on Shub2 */ \ + (volatile u64 *)(TIO_IOSPACE_ADDR(n,x)) \ + : /* TIO on shub1 */ \ + (volatile u64 *)(GLOBAL_MMR_ADDR(n,x))) \ + \ + : /* SHUB1 and SHUB2 MMRs: */ \ + (((x) & BWIN_TOP) ? ((volatile u64 *)(GLOBAL_MMR_ADDR(n,x))) \ : ((volatile u64 *)(NODE_SWIN_BASE(n,1) + 0x800000 + (x))))) - - #define HUB_L(x) (*((volatile typeof(*x) *)x)) #define HUB_S(x,d) (*((volatile typeof(*x) *)x) = (d))