summaryrefslogtreecommitdiffstats
path: root/src/arch/i386/include
diff options
context:
space:
mode:
authorJoshua Oreman2009-10-07 01:15:06 +0200
committerMarty Connor2010-01-20 23:23:37 +0100
commitfa4aec8f034f4999cf933161810b96de83ce31a7 (patch)
tree73348c8a175d5b76763d692e662d5179479e976d /src/arch/i386/include
parent[pxe] Support cached DHCP packets in .kkpxe images (diff)
downloadipxe-fa4aec8f034f4999cf933161810b96de83ce31a7.tar.gz
ipxe-fa4aec8f034f4999cf933161810b96de83ce31a7.tar.xz
ipxe-fa4aec8f034f4999cf933161810b96de83ce31a7.zip
[config] Make PXE stack a compile-time option
For extremely tight space requirements and specific applications, it is sometimes desirable to create gPXE images that cannot provide the PXE API functionality to client programs. Add a configuration header option, PXE_STACK, that can be removed to remove this stack. Also add PXE_MENU to control the PXE boot menu, which most uses of gPXE do not need. Signed-off-by: Marty Connor <mdc@etherboot.org>
Diffstat (limited to 'src/arch/i386/include')
-rw-r--r--src/arch/i386/include/pxe_call.h19
1 files changed, 19 insertions, 0 deletions
diff --git a/src/arch/i386/include/pxe_call.h b/src/arch/i386/include/pxe_call.h
index 50667e62d..4d2456169 100644
--- a/src/arch/i386/include/pxe_call.h
+++ b/src/arch/i386/include/pxe_call.h
@@ -34,5 +34,24 @@ extern void pxe_activate ( struct net_device *netdev );
extern int pxe_deactivate ( void );
extern int pxe_start_nbp ( void );
extern __asmcall void pxe_api_call ( struct i386_all_regs *ix86 );
+extern int _pxe_api_call_weak ( struct i386_all_regs *ix86 )
+ __attribute__ (( weak ));
+
+/**
+ * Dispatch PXE API call weakly
+ *
+ * @v ix86 Registers for PXE call
+ * @ret present Zero if the PXE stack is present, nonzero if not
+ *
+ * A successful return only indicates that the PXE stack was available
+ * for dispatching the call; it says nothing about the success of
+ * whatever the call asked for.
+ */
+static inline int pxe_api_call_weak ( struct i386_all_regs *ix86 )
+{
+ if ( _pxe_api_call_weak != NULL )
+ return _pxe_api_call_weak ( ix86 );
+ return -1;
+}
#endif /* _PXE_CALL_H */