Skip to content

Commit

Permalink
x86, uv: uv_global_gru_mmr_address() macro fix
Browse files Browse the repository at this point in the history
Fix bug in uv_global_gru_mmr_address macro.  Macro failed
to cast an int value to a long prior to a left shift > 32.

Signed-off-by: Jack Steiner <steiner@sgi.com>
LKML-Reference: <20100107161240.GA2610@sgi.com>
Cc: <stable@kernel.org>
Signed-off-by: H. Peter Anvin <hpa@zytor.com>
  • Loading branch information
Jack Steiner authored and H. Peter Anvin committed Jan 7, 2010
1 parent b76365a commit e1e0138
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion arch/x86/include/asm/uv/uv_hub.h
Original file line number Diff line number Diff line change
Expand Up @@ -335,7 +335,8 @@ static inline unsigned long uv_read_global_mmr64(int pnode,
*/
static inline unsigned long uv_global_gru_mmr_address(int pnode, unsigned long offset)
{
return UV_GLOBAL_GRU_MMR_BASE | offset | (pnode << uv_hub_info->m_val);
return UV_GLOBAL_GRU_MMR_BASE | offset |
((unsigned long)pnode << uv_hub_info->m_val);
}

/*
Expand Down

0 comments on commit e1e0138

Please sign in to comment.