aboutsummaryrefslogtreecommitdiffstats
path: root/src/util
diff options
context:
space:
mode:
authorMichael Brown <mcb30@ipxe.org>2013-04-19 13:34:13 +0100
committerMichael Brown <mcb30@ipxe.org>2013-04-19 13:34:13 +0100
commit73480352315a12fdef467402ea41be9ac285e4e7 (patch)
tree340080bc152462a85305d007c7af21e07bdfb556 /src/util
parente42bc3aa37698941be20cccde599af39c69227e2 (diff)
downloadipxe-73480352315a12fdef467402ea41be9ac285e4e7.tar.gz
[libc] Redefine low 8 bits of error code as "platform error code"
The low 8 bits of an iPXE error code are currently defined as the closest equivalent PXE error code. Generalise this scheme to platforms other than PC-BIOS by extending this definition to "closest equivalent platform error code". This allows for the possibility of returning meaningful errors via EFI APIs. Signed-off-by: Michael Brown <mcb30@ipxe.org>
Diffstat (limited to 'src/util')
-rw-r--r--src/util/einfo.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/util/einfo.c b/src/util/einfo.c
index 354d475f..d2155898 100644
--- a/src/util/einfo.c
+++ b/src/util/einfo.c
@@ -38,10 +38,15 @@ struct options {
/** Error usage information */
struct einfo {
+ /** Size of error information record */
uint32_t size;
+ /** Error number */
uint32_t error;
+ /** Offset to error description (NUL-terminated) */
uint32_t desc;
+ /** Offset to file name (NUL-terminated) */
uint32_t file;
+ /** Line number */
uint32_t line;
} __attribute__ (( packed ));