summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@ppc970.osdl.org>2004-09-29 20:41:20 -0700
committerLinus Torvalds <torvalds@ppc970.osdl.org>2004-09-29 20:41:20 -0700
commitd85fe8aca556714f3abe5ccf3f245d6bed8793bd (patch)
tree546f71ed2238ede2fe80894cea4fa769a9b6489f /include
parent237827056d5d9c86aab9e1f1d66eb4c9d0b6422c (diff)
parent8731cfe5617b2323be5d131a98e131f6346bd48b (diff)
Merge http://lia64.bkbits.net/linux-ia64-release-2.6.9
into ppc970.osdl.org:/home/torvalds/v2.6/linux
Diffstat (limited to 'include')
-rw-r--r--include/asm-ia64/sn/sn_sal.h36
1 files changed, 33 insertions, 3 deletions
diff --git a/include/asm-ia64/sn/sn_sal.h b/include/asm-ia64/sn/sn_sal.h
index 5a0490b4cda1..3d3d324a229a 100644
--- a/include/asm-ia64/sn/sn_sal.h
+++ b/include/asm-ia64/sn/sn_sal.h
@@ -34,6 +34,7 @@
#define SN_SAL_NO_FAULT_ZONE_PHYSICAL 0x02000011
#define SN_SAL_PRINT_ERROR 0x02000012
#define SN_SAL_SET_ERROR_HANDLING_FEATURES 0x0200001a // reentrant
+#define SN_SAL_GET_FIT_COMPT 0x0200001b // reentrant
#define SN_SAL_CONSOLE_PUTC 0x02000021
#define SN_SAL_CONSOLE_GETC 0x02000022
#define SN_SAL_CONSOLE_PUTS 0x02000023
@@ -107,12 +108,13 @@
/*
- * SN_SAL_GET_PARTITION_ADDR return constants
+ * SAL Error Codes
*/
#define SALRET_MORE_PASSES 1
#define SALRET_OK 0
-#define SALRET_INVALID_ARG -2
-#define SALRET_ERROR -3
+#define SALRET_NOT_IMPLEMENTED (-1)
+#define SALRET_INVALID_ARG (-2)
+#define SALRET_ERROR (-3)
/*
* SN_SAL_SET_ERROR_HANDLING_FEATURES bit settings
@@ -829,6 +831,34 @@ ia64_sn_irtr_intr_disable(nasid_t nasid, int subch, u64 intr)
return (int) rv.v0;
}
+/**
+ * ia64_sn_get_fit_compt - read a FIT entry from the PROM header
+ * @nasid: NASID of node to read
+ * @index: FIT entry index to be retrieved (0..n)
+ * @fitentry: 16 byte buffer where FIT entry will be stored.
+ * @banbuf: optional buffer for retrieving banner
+ * @banlen: length of banner buffer
+ *
+ * Access to the physical PROM chips needs to be serialized since reads and
+ * writes can't occur at the same time, so we need to call into the SAL when
+ * we want to look at the FIT entries on the chips.
+ *
+ * Returns:
+ * %SALRET_OK if ok
+ * %SALRET_INVALID_ARG if index too big
+ * %SALRET_NOT_IMPLEMENTED if running on older PROM
+ * ??? if nasid invalid OR banner buffer not large enough
+ */
+static inline int
+ia64_sn_get_fit_compt(u64 nasid, u64 index, void *fitentry, void *banbuf,
+ u64 banlen)
+{
+ struct ia64_sal_retval rv;
+ SAL_CALL_NOLOCK(rv, SN_SAL_GET_FIT_COMPT, nasid, index, fitentry,
+ banbuf, banlen, 0, 0);
+ return (int) rv.status;
+}
+
/*
* Initialize the SAL components of the system controller
* communication driver; specifically pass in a sizable buffer that