\r
**/\r
\r
+#include <BaseLibInternals.h>\r
+\r
/**\r
Transfers control to a function starting with a new stack.\r
\r
EFIAPI\r
SwitchStack (\r
IN SWITCH_STACK_ENTRY_POINT EntryPoint,\r
- IN VOID *Context1, OPTIONAL\r
- IN VOID *Context2, OPTIONAL\r
+ IN VOID *Context1,\r
+ IN VOID *Context2,\r
IN VOID *NewStack\r
)\r
{\r
- //\r
- // This version of this function does not actually change the stack pointer\r
- // This is to support compilation of CPU types that do not support assemblers\r
- // such as EBC\r
- //\r
- EntryPoint (Context1, Context2);\r
+ ASSERT (EntryPoint != NULL && NewStack != NULL);\r
+\r
+ InternalSwitchStack (EntryPoint, Context1, Context2, NewStack);\r
}\r