Skip to content

Commit

Permalink
[IA64] workaround tiger ia64_sal_get_physical_id_info hang
Browse files Browse the repository at this point in the history
This fixes regression introduced in 113134f

Intel Tiger platforms hang when calling SAL_GET_PHYSICAL_ID_INFO
instead of properly returning -1 for unimplemented, so add a
version check.

SGI Altix platforms have an incorrect SAL version hard-coded into
their prom -- they encode 2.9, but actually implement 3.2 -- so
fix it up and allow ia64_sal_get_physical_id_info to keep
working.

Signed-off-by: Alex Chiang <achiang@hp.com>
Acked-by: Russ Anderson <rja@sgi.com>
Signed-off-by: Tony Luck <tony.luck@intel.com>
  • Loading branch information
Alex Chiang authored and Tony Luck committed Mar 4, 2008
1 parent 022f926 commit 6ed0dc5
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 0 deletions.
7 changes: 7 additions & 0 deletions arch/ia64/kernel/sal.c
Original file line number Diff line number Diff line change
Expand Up @@ -109,6 +109,13 @@ check_versions (struct ia64_sal_systab *systab)
sal_revision = SAL_VERSION_CODE(2, 8);
sal_version = SAL_VERSION_CODE(0, 0);
}

if (ia64_platform_is("sn2") && (sal_revision == SAL_VERSION_CODE(2, 9)))
/*
* SGI Altix has hard-coded version 2.9 in their prom
* but they actually implement 3.2, so let's fix it here.
*/
sal_revision = SAL_VERSION_CODE(3, 2);
}

static void __init
Expand Down
4 changes: 4 additions & 0 deletions include/asm-ia64/sal.h
Original file line number Diff line number Diff line change
Expand Up @@ -807,6 +807,10 @@ static inline s64
ia64_sal_physical_id_info(u16 *splid)
{
struct ia64_sal_retval isrv;

if (sal_revision < SAL_VERSION_CODE(3,2))
return -1;

SAL_CALL(isrv, SAL_PHYSICAL_ID_INFO, 0, 0, 0, 0, 0, 0, 0);
if (splid)
*splid = isrv.v0;
Expand Down

0 comments on commit 6ed0dc5

Please sign in to comment.