summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--UnixPkg/CpuRuntimeDxe/Cpu.c5
-rw-r--r--UnixPkg/CpuRuntimeDxe/Cpu.inf1
-rw-r--r--UnixPkg/Include/Protocol/UnixIo.h12
-rw-r--r--UnixPkg/Include/Protocol/UnixThunk.h68
-rw-r--r--UnixPkg/Include/Protocol/UnixUgaIo.h65
-rw-r--r--UnixPkg/Library/UnixBaseLib/X64/SwitchStack.S5
-rw-r--r--UnixPkg/Library/UnixBdsLib/PlatformData.c12
-rw-r--r--UnixPkg/Sec/Gasket.c80
-rw-r--r--UnixPkg/Sec/Gasket.h131
-rw-r--r--UnixPkg/Sec/Ia32/Gasket.S55
-rw-r--r--UnixPkg/Sec/Ia32/GasketTemplate.c13
-rw-r--r--UnixPkg/Sec/SecMain.c35
-rw-r--r--UnixPkg/Sec/SecMain.h6
-rw-r--r--UnixPkg/Sec/SecMain.inf4
-rw-r--r--UnixPkg/Sec/UgaX11.c357
-rw-r--r--UnixPkg/Sec/UnixThunk.c93
-rw-r--r--UnixPkg/Sec/X64/Gasket.S8870
-rw-r--r--UnixPkg/Sec/X64/GasketTemplate.c154
-rw-r--r--UnixPkg/Sec/X64/MangleGasket.S1072
-rw-r--r--UnixPkg/Sec/X64/SwitchStack.S13
-rw-r--r--UnixPkg/UnixBusDriverDxe/UnixBusDriver.c44
-rw-r--r--UnixPkg/UnixBusDriverDxe/UnixBusDriver.inf4
-rw-r--r--UnixPkg/UnixGopDxe/ComponentName.c251
-rw-r--r--UnixPkg/UnixGopDxe/UnixGop.h377
-rw-r--r--UnixPkg/UnixGopDxe/UnixGop.inf73
-rw-r--r--UnixPkg/UnixGopDxe/UnixGopDriver.c396
-rw-r--r--UnixPkg/UnixGopDxe/UnixGopInput.c885
-rw-r--r--UnixPkg/UnixGopDxe/UnixGopScreen.c404
-rw-r--r--UnixPkg/UnixPkg.dec5
-rw-r--r--UnixPkg/UnixPkg.dsc5
-rw-r--r--UnixPkg/UnixPkg.fdf27
-rw-r--r--UnixPkg/UnixPkgX64.dsc7
-rw-r--r--UnixPkg/UnixPkgX64.fdf43
-rw-r--r--UnixPkg/UnixSnpDxe/ComponentName.c318
-rw-r--r--UnixPkg/UnixSnpDxe/UnixSnp.c1791
-rw-r--r--UnixPkg/UnixSnpDxe/UnixSnp.h156
-rw-r--r--UnixPkg/UnixSnpDxe/UnixSnpDxe.inf58
-rw-r--r--UnixPkg/UnixUgaDxe/UnixUga.h28
-rw-r--r--UnixPkg/UnixUgaDxe/UnixUga.inf1
-rw-r--r--UnixPkg/UnixUgaDxe/UnixUgaDriver.c4
-rw-r--r--UnixPkg/UnixUgaDxe/UnixUgaInput.c209
-rw-r--r--UnixPkg/UnixUgaDxe/UnixUgaScreen.c2
-rwxr-xr-xUnixPkg/Xcode/xcode_project/XcodeBuild.sh2
-rwxr-xr-xUnixPkg/Xcode/xcode_project64/XcodeBuild.sh2
44 files changed, 6568 insertions, 9575 deletions
diff --git a/UnixPkg/CpuRuntimeDxe/Cpu.c b/UnixPkg/CpuRuntimeDxe/Cpu.c
index 0cc913abfb..d4926c3707 100644
--- a/UnixPkg/CpuRuntimeDxe/Cpu.c
+++ b/UnixPkg/CpuRuntimeDxe/Cpu.c
@@ -28,6 +28,7 @@ Abstract:
#include <Guid/DataHubRecords.h>
#include <Protocol/CpuIo2.h>
#include <Protocol/FrameworkHii.h>
+#include <Protocol/UnixThunk.h>
#include <Library/BaseLib.h>
#include <Library/DebugLib.h>
@@ -37,6 +38,8 @@ Abstract:
#include <Library/BaseMemoryLib.h>
#include <Library/MemoryAllocationLib.h>
#include <Library/UefiBootServicesTableLib.h>
+#include <Library/UnixLib.h>
+
#include "CpuDriver.h"
#include "UnixDxe.h"
#include <Protocol/UnixIo.h>
@@ -151,6 +154,7 @@ Returns:
Private = CPU_ARCH_PROTOCOL_PRIVATE_DATA_FROM_THIS (This);
Private->InterruptState = TRUE;
+ gUnix->EnableInterrupt ();
return EFI_SUCCESS;
}
@@ -184,6 +188,7 @@ Returns:
Private = CPU_ARCH_PROTOCOL_PRIVATE_DATA_FROM_THIS (This);
Private->InterruptState = FALSE;
+ gUnix->DisableInterrupt ();
return EFI_SUCCESS;
}
diff --git a/UnixPkg/CpuRuntimeDxe/Cpu.inf b/UnixPkg/CpuRuntimeDxe/Cpu.inf
index 1c2e9d2f5c..ea49064cea 100644
--- a/UnixPkg/CpuRuntimeDxe/Cpu.inf
+++ b/UnixPkg/CpuRuntimeDxe/Cpu.inf
@@ -52,6 +52,7 @@
HiiLib
DebugLib
BaseLib
+ UnixLib
[Protocols]
gEfiUnixIoProtocolGuid # PROTOCOL_NOTIFY SOMETIMES_CONSUMED
diff --git a/UnixPkg/Include/Protocol/UnixIo.h b/UnixPkg/Include/Protocol/UnixIo.h
index 7bb9a46554..c9b91ef366 100644
--- a/UnixPkg/Include/Protocol/UnixIo.h
+++ b/UnixPkg/Include/Protocol/UnixIo.h
@@ -20,6 +20,8 @@ Abstract:
#ifndef _UNIX_IO_H_
#define _UNIX_IO_H_
+#include <Protocol/UnixThunk.h>
+
#define EFI_UNIX_IO_PROTOCOL_GUID \
{ \
0xf2e23f54, 0x8985, 0x11db, {0xac, 0x79, 0x00, 0x40, 0xd0, 0x2b, 0x18, 0x35 } \
@@ -139,4 +141,14 @@ extern EFI_GUID gEfiUnixCPUModelGuid;
extern EFI_GUID gEfiUnixCPUSpeedGuid;
+//
+// EFI_UNIX_NETWORK
+//
+#define EFI_UNIX_NETWORK_GUID \
+ { \
+ 0x081603B4, 0x0F1D, 0x4022, {0xB6, 0xFD, 0x4C, 0xE3, 0x5E, 0x09, 0xA1, 0xA6 } \
+ }
+
+extern EFI_GUID gEfiUnixNetworkGuid;
+
#endif
diff --git a/UnixPkg/Include/Protocol/UnixThunk.h b/UnixPkg/Include/Protocol/UnixThunk.h
index 307da1fa7f..a5383be29e 100644
--- a/UnixPkg/Include/Protocol/UnixThunk.h
+++ b/UnixPkg/Include/Protocol/UnixThunk.h
@@ -1,7 +1,7 @@
/*++
Copyright (c) 2004 - 2009, Intel Corporation. All rights reserved.<BR>
-Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
+Portions copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -51,10 +51,21 @@ Abstract:
#include <stdlib.h>
#include <sys/ioctl.h>
+#include <sys/socket.h>
+#include <netdb.h>
+#include <netinet/in.h>
+#include <net/if.h>
+#include <net/if_dl.h>
+#include <ifaddrs.h>
+#include <net/bpf.h>
+
#ifdef __APPLE__
#include <sys/param.h>
#include <sys/mount.h>
#define _XOPEN_SOURCE
+#ifndef _Bool
+ #define _Bool char // for clang debug
+#endif
#else
#include <termio.h>
#include <sys/vfs.h>
@@ -76,7 +87,15 @@ Abstract:
#pragma pack(4)
#endif
-#if __DARWIN_64_BIT_INO_T
+#if defined(__DARWIN_64_BIT_INO_T)
+
+
+typedef struct {
+ UINTN tv_sec; /* seconds */
+ UINTN tv_nsec; /* and nanoseconds */
+} EFI_timespec;
+
+
typedef struct stat_fix { \
dev_t st_dev; /* [XSI] ID of device containing file */
@@ -86,7 +105,15 @@ typedef struct stat_fix { \
uid_t st_uid; /* [XSI] User ID of the file */
gid_t st_gid; /* [XSI] Group ID of the file */
dev_t st_rdev; /* [XSI] Device ID */
- __DARWIN_STRUCT_STAT64_TIMES
+
+ // clang for X64 ABI follows Windows and a long is 32-bits
+ // this breaks system inlcude files so that is why we need
+ // to redefine timespec as EFI_timespec
+ EFI_timespec st_atimespec;
+ EFI_timespec st_mtimespec;
+ EFI_timespec st_ctimespec;
+ EFI_timespec st_birthtimespec;
+
off_t st_size; /* [XSI] file size, in bytes */
blkcnt_t st_blocks; /* [XSI] blocks allocated for file */
blksize_t st_blksize; /* [XSI] optimal blocksize for I/O */
@@ -358,6 +385,35 @@ VOID
IN OUT PE_COFF_LOADER_IMAGE_CONTEXT *ImageContext
);
+typedef
+int
+(EFIAPI *UnixGetIfAddrs) (
+ struct ifaddrs **ifap
+ );
+
+typedef
+void
+(EFIAPI *UnixFreeIfAddrs) (
+ struct ifaddrs *ifap
+ );
+
+typedef
+int
+(EFIAPI *UnixSocket) (
+ int domain,
+ int type,
+ int protocol
+ );
+
+typedef
+void
+(EFIAPI *UnixDisableInterruptEmulation) (void);
+
+typedef
+void
+(EFIAPI *UnixEnableInterruptEmulation) (void);
+
+
#define EFI_UNIX_THUNK_PROTOCOL_SIGNATURE SIGNATURE_32 ('L', 'N', 'X', 'T')
@@ -407,8 +463,12 @@ typedef struct _EFI_UNIX_THUNK_PROTOCOL {
UnixPeCoffGetEntryPoint PeCoffGetEntryPoint;
UnixPeCoffRelocateImageExtraAction PeCoffRelocateImageExtraAction;
UnixPeCoffLoaderUnloadImageExtraAction PeCoffUnloadImageExtraAction;
+ UnixEnableInterruptEmulation EnableInterrupt;
+ UnixDisableInterruptEmulation DisableInterrupt;
-
+ UnixGetIfAddrs GetIfAddrs;
+ UnixFreeIfAddrs FreeIfAddrs;
+ UnixSocket Socket;
} EFI_UNIX_THUNK_PROTOCOL;
extern EFI_GUID gEfiUnixThunkProtocolGuid;
diff --git a/UnixPkg/Include/Protocol/UnixUgaIo.h b/UnixPkg/Include/Protocol/UnixUgaIo.h
index 3b32795219..5200e4c4e0 100644
--- a/UnixPkg/Include/Protocol/UnixUgaIo.h
+++ b/UnixPkg/Include/Protocol/UnixUgaIo.h
@@ -20,19 +20,24 @@ Abstract:
#ifndef _UNIX_UGA_IO_H_
#define _UNIX_UGA_IO_H_
+#include <Protocol/SimplePointer.h>
+#include <Protocol/SimpleTextIn.h>
+#include <Protocol/SimpleTextInEx.h>
+#include <Protocol/UgaDraw.h>
+
#define EFI_UNIX_UGA_IO_PROTOCOL_GUID {0xf2e5e2c6, 0x8985, 0x11db, {0xa1, 0x91, 0x00, 0x40, 0xd0, 0x2b, 0x18, 0x35 } }
typedef struct _EFI_UNIX_UGA_IO_PROTOCOL EFI_UNIX_UGA_IO_PROTOCOL;
typedef
EFI_STATUS
-(*UGAClose)(
+(EFIAPI *UGAClose)(
EFI_UNIX_UGA_IO_PROTOCOL *Uga
);
typedef
EFI_STATUS
-(*UGASize)(
+(EFIAPI *UGASize)(
EFI_UNIX_UGA_IO_PROTOCOL *Uga,
UINT32 Width,
UINT32 Height
@@ -40,15 +45,38 @@ EFI_STATUS
typedef
EFI_STATUS
-(*UGACheckKey)(
+(EFIAPI *UGACheckKey)(
EFI_UNIX_UGA_IO_PROTOCOL *Uga
);
typedef
EFI_STATUS
-(*UGAGetKey)(
+(EFIAPI *UGAGetKey)(
EFI_UNIX_UGA_IO_PROTOCOL *Uga,
- EFI_INPUT_KEY *key
+ EFI_KEY_DATA *key
+ );
+
+typedef
+EFI_STATUS
+(EFIAPI *UGAKeySetState) (
+ IN EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
+ IN EFI_KEY_TOGGLE_STATE *KeyToggleState
+ );
+
+
+typedef
+VOID
+(EFIAPI *UGA_REGISTER_KEY_NOTIFY_CALLBACK) (
+ IN VOID *Context,
+ IN EFI_KEY_DATA *KeyData
+ );
+
+typedef
+EFI_STATUS
+(EFIAPI *UGARegisterKeyNotify) (
+ IN EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
+ IN UGA_REGISTER_KEY_NOTIFY_CALLBACK CallBack,
+ IN VOID *Context
);
@@ -64,20 +92,45 @@ typedef struct {
typedef
EFI_STATUS
-(*UGABlt)(
+(EFIAPI *UGABlt)(
IN EFI_UNIX_UGA_IO_PROTOCOL *Uga,
IN EFI_UGA_PIXEL *BltBuffer OPTIONAL,
IN EFI_UGA_BLT_OPERATION BltOperation,
IN UGA_BLT_ARGS *Args
);
+typedef
+BOOLEAN
+(EFIAPI *UGAIsKeyPressed) (
+ IN EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
+ IN EFI_KEY_DATA *KeyData
+ );
+
+typedef
+EFI_STATUS
+(EFIAPI *UGACheckPointer)(
+ EFI_UNIX_UGA_IO_PROTOCOL *Uga
+ );
+
+typedef
+EFI_STATUS
+(EFIAPI *UGAGetPointerState)(
+ EFI_UNIX_UGA_IO_PROTOCOL *Uga,
+ EFI_SIMPLE_POINTER_STATE *state
+ );
+
struct _EFI_UNIX_UGA_IO_PROTOCOL {
VOID *Private;
UGAClose UgaClose;
UGASize UgaSize;
UGACheckKey UgaCheckKey;
+ UGAKeySetState UgaKeySetState;
UGAGetKey UgaGetKey;
+ UGARegisterKeyNotify UgaRegisterKeyNotify;
UGABlt UgaBlt;
+ UGAIsKeyPressed UgaIsKeyPressed;
+ UGACheckPointer UgaCheckPointer;
+ UGAGetPointerState UgaGetPointerState;
};
diff --git a/UnixPkg/Library/UnixBaseLib/X64/SwitchStack.S b/UnixPkg/Library/UnixBaseLib/X64/SwitchStack.S
index 3a84b0d22f..fd7ba6e717 100644
--- a/UnixPkg/Library/UnixBaseLib/X64/SwitchStack.S
+++ b/UnixPkg/Library/UnixBaseLib/X64/SwitchStack.S
@@ -40,12 +40,9 @@ ASM_PFX(InternalSwitchStack):
movq %rcx, %rax
movq %rdx, %rcx
movq %r8, %rdx
- movq %r9, %rsp
-
#
# Reserve space for register parameters (rcx, rdx, r8 & r9) on the stack,
# in case the callee wishes to spill them.
#
- subq $40, %rsp // 32-byte shadow space plus alignment pad
-
+ lea -0x20(%r9), %rsp
call *%rax
diff --git a/UnixPkg/Library/UnixBdsLib/PlatformData.c b/UnixPkg/Library/UnixBdsLib/PlatformData.c
index bbeeb81721..449ad52e16 100644
--- a/UnixPkg/Library/UnixBdsLib/PlatformData.c
+++ b/UnixPkg/Library/UnixBdsLib/PlatformData.c
@@ -30,7 +30,7 @@ UINT16 gPlatformBootTimeOutDefault = 10;
//
// Platform specific keyboard device path
//
-UNIX_PLATFORM_UGA_DEVICE_PATH gUgaDevicePath0 =
+UNIX_PLATFORM_UGA_DEVICE_PATH gUgaDevicePath =
{
{
HARDWARE_DEVICE_PATH,
@@ -54,7 +54,7 @@ UNIX_PLATFORM_UGA_DEVICE_PATH gUgaDevicePath0 =
gEndEntire
};
-UNIX_PLATFORM_UGA_DEVICE_PATH gUgaDevicePath1 = {
+UNIX_PLATFORM_UGA_DEVICE_PATH gGopDevicePath = {
{
HARDWARE_DEVICE_PATH,
HW_VENDOR_DP,
@@ -71,8 +71,8 @@ UNIX_PLATFORM_UGA_DEVICE_PATH gUgaDevicePath1 = {
(UINT8) (sizeof (UNIX_VENDOR_DEVICE_PATH_NODE)),
(UINT8) ((sizeof (UNIX_VENDOR_DEVICE_PATH_NODE)) >> 8)
},
- EFI_UNIX_UGA_GUID,
- 1
+ EFI_UNIX_GOP_GUID,
+ 0
},
gEndEntire
};
@@ -108,11 +108,11 @@ BDS_CONSOLE_CONNECT_ENTRY gPlatformConsole[] = {
(CONSOLE_OUT | CONSOLE_IN)
},
{
- (EFI_DEVICE_PATH_PROTOCOL *) &gUgaDevicePath0,
+ (EFI_DEVICE_PATH_PROTOCOL *) &gUgaDevicePath,
(CONSOLE_OUT | CONSOLE_IN)
},
{
- (EFI_DEVICE_PATH_PROTOCOL *) &gUgaDevicePath1,
+ (EFI_DEVICE_PATH_PROTOCOL *) &gGopDevicePath,
(CONSOLE_OUT | CONSOLE_IN)
},
{
diff --git a/UnixPkg/Sec/Gasket.c b/UnixPkg/Sec/Gasket.c
index 826e13bad3..3c7ef80097 100644
--- a/UnixPkg/Sec/Gasket.c
+++ b/UnixPkg/Sec/Gasket.c
@@ -1,6 +1,6 @@
/** @file
- Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
+ Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
@@ -369,28 +369,88 @@ GasketUgaCheckKey (EFI_UNIX_UGA_IO_PROTOCOL *UgaIo)
EFI_STATUS
EFIAPI
-GasketUgaGetKey (EFI_UNIX_UGA_IO_PROTOCOL *UgaIo, EFI_INPUT_KEY *key)
+GasketUgaKeySetState (EFI_UNIX_UGA_IO_PROTOCOL *UgaIo, EFI_KEY_TOGGLE_STATE *KeyToggleState)
+{
+ return GasketUintnUintn (UgaGetKey, (UINTN)UgaIo, (UINTN)KeyToggleState);
+}
+
+EFI_STATUS
+EFIAPI
+GasketUgaGetKey (EFI_UNIX_UGA_IO_PROTOCOL *UgaIo, EFI_KEY_DATA *key)
{
return GasketUintnUintn (UgaGetKey, (UINTN)UgaIo, (UINTN)key);
}
EFI_STATUS
EFIAPI
+GasketUgaRegisterKeyNotify (
+ IN EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
+ IN UGA_REGISTER_KEY_NOTIFY_CALLBACK CallBack,
+ IN VOID *Context
+ )
+{
+ return GasketUintnUintnUintn (UgaRegisterKeyNotify, (UINTN)UgaIo, (UINTN)CallBack, (UINTN)Context);
+}
+
+EFI_STATUS
+EFIAPI
GasketUgaBlt (
EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
IN EFI_UGA_PIXEL *BltBuffer OPTIONAL,
IN EFI_UGA_BLT_OPERATION BltOperation,
- IN UINTN SourceX,
- IN UINTN SourceY,
- IN UINTN DestinationX,
- IN UINTN DestinationY,
- IN UINTN Width,
- IN UINTN Height,
- IN UINTN Delta OPTIONAL
+ IN UGA_BLT_ARGS *Args
)
{
- return GasketUintn10Args (UgaBlt, (UINTN)UgaIo, (UINTN)BltBuffer, BltOperation, SourceX, SourceY, DestinationX, DestinationY, Width, Height, Delta);
+ return GasketUintnUintnUintnUintn (UgaBlt, (UINTN)UgaIo, (UINTN)BltBuffer, (UINTN)BltOperation, (UINTN)Args);
+}
+
+EFI_STATUS
+EFIAPI
+GasketUgaCheckPointer (EFI_UNIX_UGA_IO_PROTOCOL *UgaIo)
+{
+ return GasketUintn (UgaCheckPointer, (UINTN)UgaIo);
+}
+
+EFI_STATUS
+EFIAPI
+GasketUgaGetPointerState (EFI_UNIX_UGA_IO_PROTOCOL *UgaIo, EFI_SIMPLE_POINTER_STATE *state)
+{
+ return GasketUintnUintn (UgaGetPointerState, (UINTN)UgaIo, (UINTN)state);
+}
+
+void
+GasketUnixEnableInterrupt (void)
+{
+ GasketVoid (UnixEnableInterrupt);
+}
+
+void
+GasketUnixDisableInterrupt (void)
+{
+ GasketVoid (UnixDisableInterrupt);
+}
+
+
+int
+Gasketgetifaddrs (struct ifaddrs **ifap)
+{
+ return( GasketUintn( getifaddrs, ( UINTN ) ifap ) );
+}
+
+
+void
+Gasketfreeifaddrs (struct ifaddrs *ifap)
+{
+ GasketUintn( freeifaddrs, ( UINTN ) ifap );
}
+
+int
+Gasketsocket (int domain, int type, int protocol )
+{
+ return( GasketUintnUintnUintn( socket, domain, type, protocol ) );
+}
+
+
#endif
diff --git a/UnixPkg/Sec/Gasket.h b/UnixPkg/Sec/Gasket.h
index 1b7187035a..4c75d8abcc 100644
--- a/UnixPkg/Sec/Gasket.h
+++ b/UnixPkg/Sec/Gasket.h
@@ -1,6 +1,6 @@
/** @file
- Copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
+ Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
@@ -19,6 +19,7 @@
#include <Protocol/UgaDraw.h>
#include <Protocol/SimpleTextIn.h>
+#include <Protocol/SimpleTextInEx.h>
#include <Protocol/UnixUgaIo.h>
@@ -177,11 +178,17 @@ Gasketclosedir (
int
EFIAPI
-Gasketstat (const char *path, STAT_FIX *buf);
+Gasketstat (
+ const char *path,
+ STAT_FIX *buf)
+ ;
int
EFIAPI
-Gasketstatfs (const char *path, struct statfs *buf);
+Gasketstatfs (
+ const char *path,
+ struct statfs *buf
+ );
int
EFIAPI
@@ -293,6 +300,34 @@ Gasketsigaction (
struct sigaction *oact
);
+int
+EFIAPI
+Gasketgetifaddrs (
+ struct ifaddrs **ifap
+ );
+
+void
+EFIAPI
+Gasketfreeifaddrs (
+ struct ifaddrs *ifap
+ );
+
+int
+EFIAPI
+Gasketsocket (
+ int domain,
+ int type,
+ int protocol
+ );
+
+void
+EFIAPI
+GasketUnixEnableInterrupt (void);
+
+void
+EFIAPI
+GasketUnixDisableInterrupt (void);
+
RETURN_STATUS
EFIAPI
GasketUnixPeCoffGetEntryPoint (
@@ -406,6 +441,13 @@ ReverseGasketUint64 (
UINT64 a
);
+UINTN
+ReverseGasketUint64Uint64 (
+ VOID *CallBack,
+ VOID *Context,
+ VOID *Key
+ );
+
//
// Gasket functions for EFI_UNIX_UGA_IO_PROTOCOL
//
@@ -435,35 +477,59 @@ EFI_STATUS
EFIAPI
GasketUgaGetKey (
EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
- EFI_INPUT_KEY *key
+ EFI_KEY_DATA *key
);
EFI_STATUS
EFIAPI
-GasketUgaBlt (
+GasketUgaKeySetState (
EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
+ EFI_KEY_TOGGLE_STATE *KeyToggleState
+ );
+
+EFI_STATUS
+EFIAPI
+GasketUgaRegisterKeyNotify (
+ IN EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
+ IN UGA_REGISTER_KEY_NOTIFY_CALLBACK CallBack,
+ IN VOID *Context
+ );
+
+EFI_STATUS
+EFIAPI
+GasketUgaBlt (
+ IN EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
IN EFI_UGA_PIXEL *BltBuffer OPTIONAL,
IN EFI_UGA_BLT_OPERATION BltOperation,
- IN UINTN SourceX,
- IN UINTN SourceY,
- IN UINTN DestinationX,
- IN UINTN DestinationY,
- IN UINTN Width,
- IN UINTN Height,
- IN UINTN Delta OPTIONAL
+ IN UGA_BLT_ARGS *Args
);
EFI_STATUS
EFIAPI
-UgaCreate (
- EFI_UNIX_UGA_IO_PROTOCOL **Uga,
- CONST CHAR16 *Title
+GasketUgaCheckPointer (
+ EFI_UNIX_UGA_IO_PROTOCOL *UgaIo
+ );
+
+EFI_STATUS
+EFIAPI
+GasketUgaGetPointerState (
+ EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
+ EFI_SIMPLE_POINTER_STATE *state
);
//
-// Gasket functions for EFI_UNIX_UGA_IO_PROTOCOL
+// Gasket functions for EFI_UNIX_UGA_IO_PROTOCOL C calls
//
+
+
+EFI_STATUS
+EFIAPI
+UgaCreate (
+ EFI_UNIX_UGA_IO_PROTOCOL **Uga,
+ CONST CHAR16 *Title
+ );
+
EFI_STATUS
EFIAPI
UgaClose (
@@ -488,24 +554,39 @@ EFI_STATUS
EFIAPI
UgaGetKey (
EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
- EFI_INPUT_KEY *key
+ EFI_KEY_DATA *key
);
EFI_STATUS
EFIAPI
+UgaRegisterKeyNotify (
+ IN EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
+ IN UGA_REGISTER_KEY_NOTIFY_CALLBACK CallBack,
+ IN VOID *Context
+ );
+
+
+EFI_STATUS
+EFIAPI
UgaBlt (
- EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
+ IN EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
IN EFI_UGA_PIXEL *BltBuffer OPTIONAL,
IN EFI_UGA_BLT_OPERATION BltOperation,
- IN UINTN SourceX,
- IN UINTN SourceY,
- IN UINTN DestinationX,
- IN UINTN DestinationY,
- IN UINTN Width,
- IN UINTN Height,
- IN UINTN Delta OPTIONAL
+ IN UGA_BLT_ARGS *Args
);
+EFI_STATUS
+EFIAPI
+UgaCheckPointer (
+ IN EFI_UNIX_UGA_IO_PROTOCOL *UgaIo
+ );
+
+EFI_STATUS
+EFIAPI
+UgaGetPointerState (
+ IN EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
+ IN EFI_SIMPLE_POINTER_STATE *State
+ );
#endif
diff --git a/UnixPkg/Sec/Ia32/Gasket.S b/UnixPkg/Sec/Ia32/Gasket.S
index 93d92b50de..440e73d6df 100644
--- a/UnixPkg/Sec/Ia32/Gasket.S
+++ b/UnixPkg/Sec/Ia32/Gasket.S
@@ -129,6 +129,31 @@ _GasketUintnUintnUintnUintn:
#------------------------------------------------------------------------------
#------------------------------------------------------------------------------
+.globl _GasketUintnUintnUintnUintnUintn
+_GasketUintnUintnUintnUintnUintn:
+ pushl %ebp
+ movl %esp, %ebp
+ subl $50, %esp # sub extra 0x10 from the stack for the AND
+ and $-16, %esp # stack needs to end in 0xFFFFFFF0 before call
+ movl 8(%ebp), %eax
+ movl %eax, -12(%ebp)
+ movl 28(%ebp), %eax
+ movl %eax, 16(%esp)
+ movl 24(%ebp), %eax
+ movl %eax, 12(%esp)
+ movl 20(%ebp), %eax
+ movl %eax, 8(%esp)
+ movl 16(%ebp), %eax
+ movl %eax, 4(%esp)
+ movl 12(%ebp), %eax
+ movl %eax, (%esp)
+ movl -12(%ebp), %eax
+ call *%eax
+ leave
+ ret
+
+#------------------------------------------------------------------------------
+#------------------------------------------------------------------------------
.globl _GasketUintn10Args
_GasketUintn10Args:
pushl %ebp
@@ -256,6 +281,35 @@ _ReverseGasketUint64:
ret
+.globl _ReverseGasketUint64Uint64
+_ReverseGasketUint64Uint64:
+ pushl %ebp
+ movl %esp, %ebp
+ subl $56, %esp
+ movl 12(%ebp), %eax
+ movl %eax, -32(%ebp)
+ movl 16(%ebp), %eax
+ movl %eax, -28(%ebp)
+ movl 20(%ebp), %eax
+ movl %eax, -40(%ebp)
+ movl 24(%ebp), %eax
+ movl %eax, -36(%ebp)
+ movl 8(%ebp), %eax
+ movl %eax, -12(%ebp)
+ movl -40(%ebp), %eax
+ movl -36(%ebp), %edx
+ movl %eax, 8(%esp)
+ movl %edx, 12(%esp)
+ movl -32(%ebp), %eax
+ movl -28(%ebp), %edx
+ movl %eax, (%esp)
+ movl %edx, 4(%esp)
+ movl -12(%ebp), %eax
+ call *%eax
+ leave
+ ret
+
+
// Sec PPI Callbacks
.globl _GasketSecUnixPeiLoadFile
@@ -288,4 +342,3 @@ _GasketSecTemporaryRamSupport:
jmp _SecTemporaryRamSupport
#endif
-
diff --git a/UnixPkg/Sec/Ia32/GasketTemplate.c b/UnixPkg/Sec/Ia32/GasketTemplate.c
index bb703bf631..d85a26a53e 100644
--- a/UnixPkg/Sec/Ia32/GasketTemplate.c
+++ b/UnixPkg/Sec/Ia32/GasketTemplate.c
@@ -7,7 +7,7 @@
the assembly functions.
Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
-Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
+Portions copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -36,6 +36,7 @@ typedef UINT32 UINTN;
typedef int (*GASKET_VOID) ();
typedef int (*GASKET_UINTN) (UINTN);
typedef int (*GASKET_UINT64) (UINT64);
+typedef int (*GASKET_UINT64UINT64) (UINT64, UINT64);
typedef int (*GASKET_UINTN_UINTN) (UINTN, UINTN);
typedef int (*GASKET_UINTN_UINTN_UINTN) (UINTN, UINTN, UINTN);
typedef int (*GASKET_UINTN_UINTN_UINTN_UINTN) (UINTN, UINTN, UINTN, UINTN);
@@ -149,4 +150,14 @@ ReverseGasketUint64 (void *api, UINT64 a)
return;
}
+void
+ReverseGasketUint64UINT64 (void *api, UINT64 a, UINT64 b)
+{
+ GASKET_UINT64UINT64 func;
+
+ func = (GASKET_UINT64UINT64)api;
+ func (a, b);
+ return;
+}
+
diff --git a/UnixPkg/Sec/SecMain.c b/UnixPkg/Sec/SecMain.c
index da83e3fa5c..dc4b14c00f 100644
--- a/UnixPkg/Sec/SecMain.c
+++ b/UnixPkg/Sec/SecMain.c
@@ -1,7 +1,7 @@
/*++
Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
-Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
+Portions copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -1114,6 +1114,18 @@ SecPeCoffRelocateImageExtraAction (
{
#ifdef __APPLE__
+ BOOLEAN EnabledOnEntry;
+
+ //
+ // Make sure writting of the file is an atomic operation
+ //
+ if (UnixInterruptEanbled ()) {
+ UnixDisableInterrupt ();
+ EnabledOnEntry = TRUE;
+ } else {
+ EnabledOnEntry = FALSE;
+ }
+
PrintLoadAddress (ImageContext);
//
@@ -1165,10 +1177,17 @@ SecPeCoffRelocateImageExtraAction (
// Hey what can you say scripting in gdb is not that great....
//
SecGdbScriptBreak ();
+ } else {
+ ASSERT (FALSE);
}
AddHandle (ImageContext, ImageContext->PdbPointer);
+ if (EnabledOnEntry) {
+ UnixEnableInterrupt ();
+ }
+
+
}
#else
@@ -1223,12 +1242,20 @@ SecPeCoffLoaderUnloadImageExtraAction (
#ifdef __APPLE__
FILE *GdbTempFile;
+ BOOLEAN EnabledOnEntry;
if (Handle != NULL) {
//
// Need to skip .PDB files created from VC++
//
if (!IsPdbFile (ImageContext->PdbPointer)) {
+ if (UnixInterruptEanbled ()) {
+ UnixDisableInterrupt ();
+ EnabledOnEntry = TRUE;
+ } else {
+ EnabledOnEntry = FALSE;
+ }
+
//
// Write the file we need for the gdb script
//
@@ -1242,6 +1269,12 @@ SecPeCoffLoaderUnloadImageExtraAction (
// Hey what can you say scripting in gdb is not that great....
//
SecGdbScriptBreak ();
+ } else {
+ ASSERT (FALSE);
+ }
+
+ if (EnabledOnEntry) {
+ UnixEnableInterrupt ();
}
}
}
diff --git a/UnixPkg/Sec/SecMain.h b/UnixPkg/Sec/SecMain.h
index 408a761965..dc857d8fb0 100644
--- a/UnixPkg/Sec/SecMain.h
+++ b/UnixPkg/Sec/SecMain.h
@@ -1,7 +1,7 @@
/*++
Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
-Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
+Portions copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -585,7 +585,6 @@ SecPeCoffLoaderUnloadImageExtraAction (
);
-
VOID SetTimer (UINT64 PeriodMs, VOID (*CallBack)(UINT64 DeltaMs));
void msSleep (unsigned long Milliseconds);
void GetLocalTime (EFI_TIME *Time);
@@ -593,6 +592,9 @@ void TzSet (void);
long GetTimeZone(void);
int GetDayLight(void);
int GetErrno(void);
+void UnixEnableInterrupt (void);
+void UnixDisableInterrupt (void);
+BOOLEAN UnixInterruptEanbled (void);
diff --git a/UnixPkg/Sec/SecMain.inf b/UnixPkg/Sec/SecMain.inf
index 94d2d95fb7..abee48519c 100644
--- a/UnixPkg/Sec/SecMain.inf
+++ b/UnixPkg/Sec/SecMain.inf
@@ -3,7 +3,7 @@
#
# Main executable file of Unix Emulator that loads PEI core after initialization finished.
# Copyright (c) 2008 - 2010, Intel Corporation. All rights reserved.<BR>
-# Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
+# Portions copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
@@ -42,7 +42,7 @@
Ia32/SwitchStack.c
[Sources.X64]
-# X64/Gasket.S # pure UINX x86_64 ABI also need to fix issues in BaseLib
+# X64/Gasket.S # pure UNIX x86_64 ABI also need to fix issues in BaseLib
X64/MangleGasket.S # convert between UNIX x86_64 ABI and EFI X64 ABI
X64/SwitchStack.S
diff --git a/UnixPkg/Sec/UgaX11.c b/UnixPkg/Sec/UgaX11.c
index c8b9451328..c1a2b2d7a5 100644
--- a/UnixPkg/Sec/UgaX11.c
+++ b/UnixPkg/Sec/UgaX11.c
@@ -1,7 +1,7 @@
/*++
Copyright (c) 2004 - 2009, Intel Corporation. All rights reserved.<BR>
-Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
+Portions copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -17,16 +17,20 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#include <stdio.h>
#include <stdlib.h>
-#include "PiPei.h"
-#include "Protocol/UnixThunk.h"
-#include "Protocol/SimpleTextIn.h"
-#include "Protocol/UgaDraw.h"
-#include "Protocol/UnixUgaIo.h"
+#include <PiPei.h>
+#include <Protocol/SimplePointer.h>
+#include <Protocol/SimpleTextIn.h>
+#include <Protocol/SimpleTextInEx.h>
+#include <Protocol/UgaDraw.h>
#include <X11/Xlib.h>
#include <X11/Xutil.h>
#include <X11/Xos.h>
#include <X11/extensions/XShm.h>
#include <X11/keysym.h>
+#include <X11/cursorfont.h>
+
+#include <Protocol/UnixThunk.h>
+#include <Protocol/UnixUgaIo.h>
#include <Ppi/StatusCode.h>
@@ -37,20 +41,22 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#include <Library/PcdLib.h>
#include <Library/DebugLib.h>
+#include "Gasket.h"
+#include "SecMain.h"
+
+
extern void msSleep (unsigned long Milliseconds);
/* XQueryPointer */
-struct uga_drv_shift_mask
-{
+struct uga_drv_shift_mask {
unsigned char shift;
unsigned char size;
unsigned char csize;
};
#define NBR_KEYS 32
-typedef struct
-{
+typedef struct {
EFI_UNIX_UGA_IO_PROTOCOL UgaIo;
Display *display;
@@ -75,7 +81,17 @@ typedef struct
unsigned int key_rd;
unsigned int key_wr;
unsigned int key_count;
- EFI_INPUT_KEY keys[NBR_KEYS];
+ EFI_KEY_DATA keys[NBR_KEYS];
+
+ EFI_KEY_STATE KeyState;
+
+ UGA_REGISTER_KEY_NOTIFY_CALLBACK RegisterdKeyCallback;
+ VOID *RegisterdKeyCallbackContext;
+
+ int previous_x;
+ int previous_y;
+ EFI_SIMPLE_POINTER_STATE pointer_state;
+ int pointer_state_changed;
} UGA_IO_PRIVATE;
void
@@ -246,49 +262,165 @@ handleKeyEvent(UGA_IO_PRIVATE *drv, XEvent *ev)
{
KeySym keysym;
char str[4];
- EFI_INPUT_KEY Key;
+ EFI_KEY_DATA KeyData;
int res;
if (drv->key_count == NBR_KEYS)
return;
res = XLookupString(&ev->xkey, str, sizeof(str), &keysym, NULL);
- Key.ScanCode = 0;
- Key.UnicodeChar = 0;
+ KeyData.Key.ScanCode = 0;
+ KeyData.Key.UnicodeChar = 0;
+ KeyData.KeyState.KeyShiftState = 0;
+
+ //
+ // KeyRelease is not supported (on Mac) so we can not easily implement Ex functions.
+ // If a modifier key is hit by its self we get a keysym. If a modfifier and key is hit
+ // we get the state bit set and keysym is the modified key.
+ //
+ // We use lack of state bits being set to clear ToggleState and KeyShiftState. We can
+ // also use the stat bits to set ToggleState and KeyShiftState.
+ // Skipping EFI_SCROLL_LOCK_ACTIVE & EFI_NUM_LOCK_ACTIVE since they are not on Macs
+ //
+ if ((ev->xkey.state & LockMask) == 0) {
+ drv->KeyState.KeyToggleState &= ~EFI_CAPS_LOCK_ACTIVE;
+ } else {
+ drv->KeyState.KeyToggleState |= EFI_CAPS_LOCK_ACTIVE;
+ }
+
+ if ((ev->xkey.state & ControlMask) == 0) {
+ drv->KeyState.KeyShiftState &= ~(EFI_RIGHT_CONTROL_PRESSED | EFI_LEFT_CONTROL_PRESSED);
+ } else if ((drv->KeyState.KeyShiftState & EFI_RIGHT_CONTROL_PRESSED) == 0) {
+ drv->KeyState.KeyShiftState |= EFI_LEFT_CONTROL_PRESSED;
+ }
+
+ if ((ev->xkey.state & ShiftMask) == 0) {
+ drv->KeyState.KeyShiftState &= ~(EFI_RIGHT_SHIFT_PRESSED | EFI_LEFT_SHIFT_PRESSED);
+ } else if ((drv->KeyState.KeyShiftState & EFI_RIGHT_SHIFT_PRESSED) == 0) {
+ drv->KeyState.KeyShiftState |= EFI_LEFT_SHIFT_PRESSED;
+ }
+
+ if ((ev->xkey.state & Mod2Mask) == 0) {
+ drv->KeyState.KeyShiftState &= ~(EFI_RIGHT_LOGO_PRESSED | EFI_LEFT_LOGO_PRESSED);
+ } else if ((drv->KeyState.KeyShiftState & EFI_RIGHT_LOGO_PRESSED) == 0) {
+ drv->KeyState.KeyShiftState |= EFI_LEFT_LOGO_PRESSED;
+ }
+
+ if ((ev->xkey.state & 0x2000) == 0) {
+ drv->KeyState.KeyShiftState &= ~(EFI_LEFT_ALT_PRESSED);
+ } else {
+ drv->KeyState.KeyShiftState |= EFI_LEFT_ALT_PRESSED;
+ }
+
+
switch (keysym) {
- case XK_Home: Key.ScanCode = SCAN_HOME; break;
- case XK_End: Key.ScanCode = SCAN_END; break;
- case XK_Left: Key.ScanCode = SCAN_LEFT; break;
- case XK_Right: Key.ScanCode = SCAN_RIGHT; break;
- case XK_Up: Key.ScanCode = SCAN_UP; break;
- case XK_Down: Key.ScanCode = SCAN_DOWN; break;
- case XK_Delete: Key.ScanCode = SCAN_DELETE; break;
- case XK_Insert: Key.ScanCode = SCAN_INSERT; break;
- case XK_Page_Up: Key.ScanCode = SCAN_PAGE_UP; break;
- case XK_Page_Down: Key.ScanCode = SCAN_PAGE_DOWN; break;
- case XK_Escape: Key.ScanCode = SCAN_ESC; break;
-
- case XK_F1: Key.ScanCode = SCAN_F1; break;
- case XK_F2: Key.ScanCode = SCAN_F2; break;
- case XK_F3: Key.ScanCode = SCAN_F3; break;
- case XK_F4: Key.ScanCode = SCAN_F4; break;
- case XK_F5: Key.ScanCode = SCAN_F5; break;
- case XK_F6: Key.ScanCode = SCAN_F6; break;
- case XK_F7: Key.ScanCode = SCAN_F7; break;
- case XK_F8: Key.ScanCode = SCAN_F8; break;
- case XK_F9: Key.ScanCode = SCAN_F9; break;
+ case XK_Control_R:
+ drv->KeyState.KeyShiftState |= EFI_RIGHT_CONTROL_PRESSED;
+ break;
+ case XK_Control_L:
+ drv->KeyState.KeyShiftState |= EFI_LEFT_CONTROL_PRESSED;
+ break;
+
+ case XK_Shift_R:
+ drv->KeyState.KeyShiftState |= EFI_RIGHT_SHIFT_PRESSED;
+ break;
+ case XK_Shift_L:
+ drv->KeyState.KeyShiftState |= EFI_LEFT_SHIFT_PRESSED;
+ break;
+
+ case XK_Mode_switch:
+ drv->KeyState.KeyShiftState |= EFI_LEFT_ALT_PRESSED;
+ break;
+
+ case XK_Meta_R:
+ drv->KeyState.KeyShiftState |= EFI_RIGHT_LOGO_PRESSED;
+ break;
+ case XK_Meta_L:
+ drv->KeyState.KeyShiftState |= EFI_LEFT_LOGO_PRESSED;
+ break;
+
+ case XK_Home: KeyData.Key.ScanCode = SCAN_HOME; break;
+ case XK_End: KeyData.Key.ScanCode = SCAN_END; break;
+ case XK_Left: KeyData.Key.ScanCode = SCAN_LEFT; break;
+ case XK_Right: KeyData.Key.ScanCode = SCAN_RIGHT; break;
+ case XK_Up: KeyData.Key.ScanCode = SCAN_UP; break;
+ case XK_Down: KeyData.Key.ScanCode = SCAN_DOWN; break;
+ case XK_Delete: KeyData.Key.ScanCode = SCAN_DELETE; break;
+ case XK_Insert: KeyData.Key.ScanCode = SCAN_INSERT; break;
+ case XK_Page_Up: KeyData.Key.ScanCode = SCAN_PAGE_UP; break;
+ case XK_Page_Down: KeyData.Key.ScanCode = SCAN_PAGE_DOWN; break;
+ case XK_Escape: KeyData.Key.ScanCode = SCAN_ESC; break;
+
+ case XK_F1: KeyData.Key.ScanCode = SCAN_F1; break;
+ case XK_F2: KeyData.Key.ScanCode = SCAN_F2; break;
+ case XK_F3: KeyData.Key.ScanCode = SCAN_F3; break;
+ case XK_F4: KeyData.Key.ScanCode = SCAN_F4; break;
+ case XK_F5: KeyData.Key.ScanCode = SCAN_F5; break;
+ case XK_F6: KeyData.Key.ScanCode = SCAN_F6; break;
+ case XK_F7: KeyData.Key.ScanCode = SCAN_F7; break;
+ case XK_F8: KeyData.Key.ScanCode = SCAN_F8; break;
+ case XK_F9: KeyData.Key.ScanCode = SCAN_F9; break;
default:
if (res == 1) {
- Key.UnicodeChar = str[0];
+ KeyData.Key.UnicodeChar = str[0];
} else {
return;
}
}
- drv->keys[drv->key_wr] = Key;
+ // The global state is our state
+ KeyData.KeyState.KeyShiftState = drv->KeyState.KeyShiftState;
+ KeyData.KeyState.KeyToggleState = drv->KeyState.KeyToggleState;
+
+ CopyMem (&drv->keys[drv->key_wr], &KeyData, sizeof (EFI_KEY_DATA));
drv->key_wr = (drv->key_wr + 1) % NBR_KEYS;
drv->key_count++;
+
+
+#if defined(__APPLE__) || defined(MDE_CPU_X64)
+ ReverseGasketUint64Uint64 (drv->RegisterdKeyCallback ,drv->RegisterdKeyCallbackContext, &KeyData);
+#else
+ drv->RegisterdKeyCallback (drv->RegisterdKeyCallbackContext, &KeyData);
+#endif
+
+
+}
+
+
+void
+handleMouseMoved(UGA_IO_PRIVATE *drv, XEvent *ev)
+{
+ if ( ev->xmotion.x != drv->previous_x )
+ {
+ drv->pointer_state.RelativeMovementX += ( ev->xmotion.x - drv->previous_x );
+ drv->previous_x = ev->xmotion.x;
+ drv->pointer_state_changed = 1;
+ }
+
+ if ( ev->xmotion.y != drv->previous_y )
+ {
+ drv->pointer_state.RelativeMovementY += ( ev->xmotion.y - drv->previous_y );
+ drv->previous_y = ev->xmotion.y;
+ drv->pointer_state_changed = 1;
+ }
+
+ drv->pointer_state.RelativeMovementZ = 0;
+}
+
+void
+handleMouseDown(UGA_IO_PRIVATE *drv, XEvent *ev, BOOLEAN Pressed)
+{
+ if ( ev->xbutton.button == Button1 )
+ {
+ drv->pointer_state_changed = ( drv->pointer_state.LeftButton != Pressed );
+ drv->pointer_state.LeftButton = Pressed;
+ }
+ if ( ev->xbutton.button == Button2 )
+ {
+ drv->pointer_state_changed = ( drv->pointer_state.RightButton != Pressed );
+ drv->pointer_state.RightButton = Pressed;
+ }
}
void
@@ -319,9 +451,20 @@ HandleEvent(UGA_IO_PRIVATE *drv, XEvent *ev)
case KeyPress:
handleKeyEvent(drv, ev);
break;
+ case KeyRelease:
+ break;
case MappingNotify:
XRefreshKeyboardMapping(&ev->xmapping);
break;
+ case MotionNotify:
+ handleMouseMoved(drv, ev);
+ break;
+ case ButtonPress:
+ handleMouseDown(drv, ev, TRUE);
+ break;
+ case ButtonRelease:
+ handleMouseDown(drv, ev, FALSE);
+ break;
#if 0
case DestroyNotify:
XCloseDisplay (drv->display);
@@ -368,37 +511,87 @@ UgaColorToPixel (UGA_IO_PRIVATE *drv, unsigned long val)
return res;
}
-EFI_STATUS
-UgaCheckKey(EFI_UNIX_UGA_IO_PROTOCOL *UgaIo)
+STATIC EFI_STATUS
+CheckKeyInternal( UGA_IO_PRIVATE *drv, BOOLEAN delay )
{
- UGA_IO_PRIVATE *drv = (UGA_IO_PRIVATE *)UgaIo;
HandleEvents(drv);
-
- if (drv->key_count != 0) {
+ if (drv->key_count != 0)
return EFI_SUCCESS;
- } else {
- /* EFI is certainly polling. Be CPU-friendly. */
+ if ( delay )
+ /* EFI is polling. Be CPU-friendly. */
msSleep (20);
return EFI_NOT_READY;
}
+
+EFI_STATUS
+UgaCheckKey(EFI_UNIX_UGA_IO_PROTOCOL *UgaIo)
+{
+ UGA_IO_PRIVATE *drv = (UGA_IO_PRIVATE *)UgaIo;
+ return( CheckKeyInternal( drv, TRUE ) );
}
EFI_STATUS
-UgaGetKey (EFI_UNIX_UGA_IO_PROTOCOL *UgaIo, EFI_INPUT_KEY *key)
+EFIAPI
+UgaGetKey (
+ IN EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
+ IN EFI_KEY_DATA *KeyData
+ )
{
UGA_IO_PRIVATE *drv = (UGA_IO_PRIVATE *)UgaIo;
EFI_STATUS status;
- status = UgaCheckKey(UgaIo);
+ status = CheckKeyInternal(drv, FALSE);
if (status != EFI_SUCCESS)
return status;
- *key = drv->keys[drv->key_rd];
+ CopyMem (KeyData, &drv->keys[drv->key_rd], sizeof (EFI_KEY_DATA));
drv->key_rd = (drv->key_rd + 1) % NBR_KEYS;
drv->key_count--;
return EFI_SUCCESS;
}
+
+EFI_STATUS
+EFIAPI
+UgaKeySetState (
+ IN EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
+ IN EFI_KEY_TOGGLE_STATE *KeyToggleState
+ )
+{
+ UGA_IO_PRIVATE *drv = (UGA_IO_PRIVATE *)UgaIo;
+// XKeyEvent event;
+
+ if (*KeyToggleState & EFI_CAPS_LOCK_ACTIVE) {
+ if ((drv->KeyState.KeyToggleState & EFI_CAPS_LOCK_ACTIVE) == 0) {
+ //
+ // We could create an XKeyEvent and send a XK_Caps_Lock to
+ // the UGA/GOP Window
+ //
+ }
+ }
+
+ drv->KeyState.KeyToggleState = *KeyToggleState;
+ return EFI_SUCCESS;
+}
+
+
+EFI_STATUS
+EFIAPI
+UgaRegisterKeyNotify (
+ IN EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
+ IN UGA_REGISTER_KEY_NOTIFY_CALLBACK CallBack,
+ IN VOID *Context
+ )
+{
+ UGA_IO_PRIVATE *drv = (UGA_IO_PRIVATE *)UgaIo;
+
+ drv->RegisterdKeyCallback = CallBack;
+ drv->RegisterdKeyCallbackContext = Context;
+
+ return EFI_SUCCESS;
+}
+
+
EFI_STATUS
UgaBlt(
IN EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
@@ -545,6 +738,44 @@ UgaBlt(
return EFI_SUCCESS;
}
+STATIC EFI_STATUS
+CheckPointerInternal( UGA_IO_PRIVATE *drv, BOOLEAN delay )
+{
+ HandleEvents(drv);
+ if (drv->pointer_state_changed != 0)
+ return EFI_SUCCESS;
+ if ( delay )
+ /* EFI is polling. Be CPU-friendly. */
+ msSleep (20);
+ return EFI_NOT_READY;
+}
+
+EFI_STATUS
+UgaCheckPointer(EFI_UNIX_UGA_IO_PROTOCOL *UgaIo)
+{
+ UGA_IO_PRIVATE *drv = (UGA_IO_PRIVATE *)UgaIo;
+ return( CheckPointerInternal( drv, TRUE ) );
+}
+
+EFI_STATUS
+UgaGetPointerState (EFI_UNIX_UGA_IO_PROTOCOL *UgaIo, EFI_SIMPLE_POINTER_STATE *state)
+{
+ UGA_IO_PRIVATE *drv = (UGA_IO_PRIVATE *)UgaIo;
+ EFI_STATUS status;
+
+ status = CheckPointerInternal( drv, FALSE );
+ if (status != EFI_SUCCESS)
+ return status;
+
+ memcpy( state, &drv->pointer_state, sizeof( EFI_SIMPLE_POINTER_STATE ) );
+
+ drv->pointer_state.RelativeMovementX = 0;
+ drv->pointer_state.RelativeMovementY = 0;
+ drv->pointer_state.RelativeMovementZ = 0;
+ drv->pointer_state_changed = 0;
+ return EFI_SUCCESS;
+}
+
EFI_STATUS
UgaCreate (EFI_UNIX_UGA_IO_PROTOCOL **Uga, CONST CHAR16 *Title)
{
@@ -557,32 +788,29 @@ UgaCreate (EFI_UNIX_UGA_IO_PROTOCOL **Uga, CONST CHAR16 *Title)
if (drv == NULL)
return EFI_OUT_OF_RESOURCES;
-#ifdef __APPLE__
+#if defined(__APPLE__) || defined(MDE_CPU_X64)
//
//
//
-EFI_STATUS EFIAPI GasketUgaClose (EFI_UNIX_UGA_IO_PROTOCOL *UgaIo);
-EFI_STATUS EFIAPI GasketUgaSize (EFI_UNIX_UGA_IO_PROTOCOL *UgaIo, UINT32 Width, UINT32 Height);
-EFI_STATUS EFIAPI GasketUgaCheckKey (EFI_UNIX_UGA_IO_PROTOCOL *UgaIo);
-EFI_STATUS EFIAPI GasketUgaGetKey (EFI_UNIX_UGA_IO_PROTOCOL *UgaIo, EFI_INPUT_KEY *key);
-EFI_STATUS EFIAPI GasketUgaBlt (
- EFI_UNIX_UGA_IO_PROTOCOL *UgaIo,
- IN EFI_UGA_PIXEL *BltBuffer OPTIONAL,
- IN EFI_UGA_BLT_OPERATION BltOperation,
- IN UGA_BLT_ARGS *Args
- );
-
drv->UgaIo.UgaClose = GasketUgaClose;
drv->UgaIo.UgaSize = GasketUgaSize;
drv->UgaIo.UgaCheckKey = GasketUgaCheckKey;
drv->UgaIo.UgaGetKey = GasketUgaGetKey;
+ drv->UgaIo.UgaKeySetState = GasketUgaKeySetState;
+ drv->UgaIo.UgaRegisterKeyNotify = GasketUgaRegisterKeyNotify;
drv->UgaIo.UgaBlt = GasketUgaBlt;
+ drv->UgaIo.UgaCheckPointer = GasketUgaCheckPointer;
+ drv->UgaIo.UgaGetPointerState = GasketUgaGetPointerState;
#else
drv->UgaIo.UgaClose = UgaClose;
drv->UgaIo.UgaSize = UgaSize;
drv->UgaIo.UgaCheckKey = UgaCheckKey;
drv->UgaIo.UgaGetKey = UgaGetKey;
+ drv->UgaIo.UgaKeySetState = UgaKeySetState;
+ drv->UgaIo.UgaRegisterKeyNotify = UgaRegisterKeyNotify;
drv->UgaIo.UgaBlt = UgaBlt;
+ drv->UgaIo.UgaCheckPointer = UgaCheckPointer;
+ drv->UgaIo.UgaGetPointerState = UgaGetPointerState;
#endif
@@ -590,6 +818,12 @@ EFI_STATUS EFIAPI GasketUgaBlt (
drv->key_count = 0;
drv->key_rd = 0;
drv->key_wr = 0;
+ drv->KeyState.KeyShiftState = EFI_SHIFT_STATE_VALID;
+ drv->KeyState.KeyToggleState = EFI_TOGGLE_STATE_VALID;
+ drv->RegisterdKeyCallback = NULL;
+ drv->RegisterdKeyCallbackContext = NULL;
+
+
drv->display = XOpenDisplay (display_name);
if (drv->display == NULL)
{
@@ -607,6 +841,7 @@ EFI_STATUS EFIAPI GasketUgaBlt (
BlackPixel (drv->display, drv->screen));
drv->depth = DefaultDepth (drv->display, drv->screen);
+ XDefineCursor (drv->display, drv->win, XCreateFontCursor (drv->display, XC_pirate));
/* Compute title len and convert to Ascii. */
for (title_len = 0; Title[title_len] != 0; title_len++)
@@ -621,8 +856,8 @@ EFI_STATUS EFIAPI GasketUgaBlt (
XStoreName (drv->display, drv->win, title);
}
- XSelectInput (drv->display, drv->win, ExposureMask | KeyPressMask);
-
+ XSelectInput (drv->display, drv->win,
+ ExposureMask | KeyPressMask | PointerMotionMask | ButtonPressMask | ButtonReleaseMask );
drv->gc = DefaultGC (drv->display, drv->screen);
*Uga = (EFI_UNIX_UGA_IO_PROTOCOL *)drv;
diff --git a/UnixPkg/Sec/UnixThunk.c b/UnixPkg/Sec/UnixThunk.c
index 874f26fa89..f65acab100 100644
--- a/UnixPkg/Sec/UnixThunk.c
+++ b/UnixPkg/Sec/UnixThunk.c
@@ -1,14 +1,14 @@
/*++
Copyright (c) 2004 - 2009, Intel Corporation. All rights reserved.<BR>
-Portions copyright (c) 2008 - 2009, Apple Inc. All rights reserved.<BR>
-This program and the accompanying materials
-are licensed and made available under the terms and conditions of the BSD License
-which accompanies this distribution. The full text of the license may be found at
-http://opensource.org/licenses/bsd-license.php
-
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+Portions copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
+This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
Module Name:
@@ -16,7 +16,7 @@ Module Name:
Abstract:
- Since the SEC is the only program in our emulation we
+ Since the SEC is the only program in our emulation we
must use a Tiano mechanism to export APIs to other modules.
This is the role of the EFI_UNIX_THUNK_PROTOCOL.
@@ -25,7 +25,7 @@ Abstract:
are not added. It looks like adding a element to end and not initializing
it may cause the table to be initaliized with the members at the end being
set to zero. This is bad as jumping to zero will crash.
-
+
gUnix is a a public exported global that contains the initialized
data.
@@ -44,6 +44,9 @@ int settimer_initialized;
struct timeval settimer_timeval;
void (*settimer_callback)(UINT64 delta);
+BOOLEAN gEmulatorInterruptEnabled = FALSE;
+
+
void
settimer_handler (int sig)
{
@@ -52,15 +55,15 @@ settimer_handler (int sig)
gettimeofday (&timeval, NULL);
delta = ((UINT64)timeval.tv_sec * 1000) + (timeval.tv_usec / 1000)
- - ((UINT64)settimer_timeval.tv_sec * 1000)
+ - ((UINT64)settimer_timeval.tv_sec * 1000)
- (settimer_timeval.tv_usec / 1000);
settimer_timeval = timeval;
-
+
if (settimer_callback) {
#if defined(__APPLE__) || defined(MDE_CPU_X64)
ReverseGasketUint64 (settimer_callback, delta);
#else
- (*settimer_callback)(delta);
+ (*settimer_callback)(delta);
#endif
}
}
@@ -78,6 +81,7 @@ SetTimer (UINT64 PeriodMs, VOID (*CallBack)(UINT64 DeltaMs))
act.sa_handler = settimer_handler;
act.sa_flags = 0;
sigemptyset (&act.sa_mask);
+ gEmulatorInterruptEnabled = TRUE;
if (sigaction (SIGALRM, &act, NULL) != 0) {
printf ("SetTimer: sigaction error %s\n", strerror (errno));
}
@@ -90,13 +94,50 @@ SetTimer (UINT64 PeriodMs, VOID (*CallBack)(UINT64 DeltaMs))
timerval.it_value.tv_usec = remainder * 1000;
timerval.it_value.tv_sec = DivU64x32(PeriodMs, 1000);
timerval.it_interval = timerval.it_value;
-
+
if (setitimer (ITIMER_REAL, &timerval, NULL) != 0) {
printf ("SetTimer: setitimer error %s\n", strerror (errno));
}
settimer_callback = CallBack;
}
+
+void
+UnixEnableInterrupt (void)
+{
+ sigset_t sigset;
+
+ gEmulatorInterruptEnabled = TRUE;
+ // Since SetTimer() uses SIGALRM we emulate turning on and off interrupts
+ // by enabling/disabling SIGALRM.
+ sigemptyset (&sigset);
+ sigaddset (&sigset, SIGALRM);
+ sigprocmask (SIG_UNBLOCK, &sigset, NULL);
+}
+
+
+void
+UnixDisableInterrupt (void)
+{
+ sigset_t sigset;
+
+ // Since SetTimer() uses SIGALRM we emulate turning on and off interrupts
+ // by enabling/disabling SIGALRM.
+ sigemptyset (&sigset);
+ sigaddset (&sigset, SIGALRM);
+ sigprocmask (SIG_BLOCK, &sigset, NULL);
+ gEmulatorInterruptEnabled = FALSE;
+}
+
+
+BOOLEAN
+UnixInterruptEanbled (void)
+{
+ return gEmulatorInterruptEnabled;
+}
+
+
+
void
msSleep (unsigned long Milliseconds)
{
@@ -110,7 +151,7 @@ msSleep (unsigned long Milliseconds)
break;
}
rq = rm;
- }
+ }
}
@@ -174,7 +215,7 @@ EFI_UNIX_THUNK_PROTOCOL mUnixThunkTable = {
#if defined(__APPLE__) || defined(MDE_CPU_X64)
//
// Mac OS X requires the stack to be 16-byte aligned for IA-32. So on an OS X build
-// we add an assembly wrapper that makes sure the stack ges aligned.
+// we add an assembly wrapper that makes sure the stack ges aligned.
// This has the nice benfit of being able to run EFI ABI code, like the EFI shell
// that is checked in to source control in the OS X version of the emulator
//
@@ -217,9 +258,16 @@ EFI_UNIX_THUNK_PROTOCOL mUnixThunkTable = {
Gasketcfsetospeed,
Gaskettcgetattr,
Gaskettcsetattr,
- GasketUnixPeCoffGetEntryPoint,
- GasketUnixPeCoffRelocateImageExtraAction,
- GasketUnixPeCoffUnloadImageExtraAction
+ GasketUnixPeCoffGetEntryPoint,
+ GasketUnixPeCoffRelocateImageExtraAction,
+ GasketUnixPeCoffUnloadImageExtraAction,
+
+ GasketUnixEnableInterrupt,
+ GasketUnixDisableInterrupt,
+
+ Gasketgetifaddrs,
+ Gasketfreeifaddrs,
+ Gasketsocket,
#else
msSleep, /* Sleep */
@@ -263,7 +311,12 @@ EFI_UNIX_THUNK_PROTOCOL mUnixThunkTable = {
tcsetattr,
SecPeCoffGetEntryPoint,
SecPeCoffRelocateImageExtraAction,
- SecPeCoffLoaderUnloadImageExtraAction
+ SecPeCoffLoaderUnloadImageExtraAction,
+ UnixEnableInterrupt,
+ UnixDisableInterrupt,
+ getifaddrs,
+ freeifaddrs,
+ socket
#endif
};
diff --git a/UnixPkg/Sec/X64/Gasket.S b/UnixPkg/Sec/X64/Gasket.S
deleted file mode 100644
index 4d6123f555..0000000000
--- a/UnixPkg/Sec/X64/Gasket.S
+++ /dev/null
@@ -1,8870 +0,0 @@
-#------------------------------------------------------------------------------
-#
-# This template was generated from GasketEfiTemplate.c Unix x86_64 ABI
-#
-# Efi Prefix means it has been ported to gasket EFIABI to Unix x86_64 ABI
-#
-# The EFI_UNIX_THUNK_PROTOCOL member functions call these these generic assembly
-# routines.
-#
-# Some OS X POSIX calls get name mangled in C code and we need to fill in a C global
-# to get the correct binding (does not work from assembly). So we have 4 functions
-# that do an indirect call, while the others call POSIX APIs directly
-#
-# movq _gUnixRmDir@GOTPCREL(%rip), %rax
-#
-#
-# UNIX Arg passing: RCX, RDX, R8, R9
-# EFI Arg passing: RDI, RDI, RDX, RCX, R8, R9
-#
-# RSI, RDI calle-save on EFI, scatch on UNIX callign
-#
-#
-# Copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-# This program and the accompanying materials
-# are licensed and made available under the terms and conditions of the BSD License
-# which accompanies this distribution. The full text of the license may be found at
-# http://opensource.org/licenses/bsd-license.php
-#
-# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-#
-#------------------------------------------------------------------------------
-#ifdef __APPLE__
- .section __DWARF,__debug_frame,regular,debug
-Lsection__debug_frame:
- .section __DWARF,__debug_info,regular,debug
-Lsection__debug_info:
- .section __DWARF,__debug_abbrev,regular,debug
-Lsection__debug_abbrev:
- .section __DWARF,__debug_aranges,regular,debug
-Lsection__debug_aranges:
- .section __DWARF,__debug_macinfo,regular,debug
-Lsection__debug_macinfo:
- .section __DWARF,__debug_line,regular,debug
-Lsection__debug_line:
- .section __DWARF,__debug_loc,regular,debug
-Lsection__debug_loc:
- .section __DWARF,__debug_pubnames,regular,debug
-Lsection__debug_pubnames:
- .section __DWARF,__debug_pubtypes,regular,debug
-Lsection__debug_pubtypes:
- .section __DWARF,__debug_inlined,regular,debug
-Lsection__debug_inlined:
- .section __DWARF,__debug_str,regular,debug
-Lsection__debug_str:
- .section __DWARF,__debug_ranges,regular,debug
-Lsection__debug_ranges:
- .section __DWARF,__debug_abbrev,regular,debug
-Ldebug_abbrev0:
- .section __DWARF,__debug_info,regular,debug
-Ldebug_info0:
- .section __DWARF,__debug_line,regular,debug
-Ldebug_line0:
-#endif
-
- .text
-Ltext0:
-.globl _Gasketrmdir
-_Gasketrmdir:
-LFB16:
- .file 1 "/Users/fish/work/edk2/UnixPkg/Sec/X64/GasketEfiTemplate.c"
- .loc 1 35 0
- pushq %rbp
-LCFI0:
- movq %rsp, %rbp
-LCFI1:
- subq $16, %rsp
-LCFI2:
- movq %rdi, -8(%rbp)
- .loc 1 36 0
- movq _gUnixRmDir@GOTPCREL(%rip), %rax
- movq (%rax), %rax
- movq -8(%rbp), %rdi
- call *%rax
- .loc 1 37 0
- leave
- ret
-
-LFE16:
-.globl _Gasketopendir
-_Gasketopendir:
-LFB17:
- .loc 1 42 0
- pushq %rbp
-LCFI3:
- movq %rsp, %rbp
-LCFI4:
- subq $16, %rsp
-LCFI5:
- movq %rdi, -8(%rbp)
- .loc 1 43 0
- movq _gUnixOpenDir@GOTPCREL(%rip), %rax
- movq (%rax), %rax
- movq -8(%rbp), %rdi
- call *%rax
- .loc 1 44 0
- leave
- ret
-LFE17:
-.globl _Gasketstat
-_Gasketstat:
-LFB18:
- .loc 1 49 0
- pushq %rbp
-LCFI6:
- movq %rsp, %rbp
-LCFI7:
- subq $16, %rsp
-LCFI8:
- movq %rdi, -8(%rbp)
- movq %rsi, -16(%rbp)
- .loc 1 50 0
- movq _gUnixStat@GOTPCREL(%rip), %rax
- movq (%rax), %rax
- movq -16(%rbp), %rsi
- movq -8(%rbp), %rdi
- call *%rax
- .loc 1 51 0
- leave
- ret
-LFE18:
-.globl _Gasketstatfs
-_Gasketstatfs:
-LFB19:
- .loc 1 56 0
- pushq %rbp
-LCFI9:
- movq %rsp, %rbp
-LCFI10:
- subq $16, %rsp
-LCFI11:
- movq %rdi, -8(%rbp)
- movq %rsi, -16(%rbp)
- .loc 1 57 0
- movq _gUnixStatFs@GOTPCREL(%rip), %rax
- movq (%rax), %rax
- movq -16(%rbp), %rsi
- movq -8(%rbp), %rdi
- call *%rax
- .loc 1 58 0
- leave
- ret
-LFE19:
-.globl _GasketmsSleep
-_GasketmsSleep:
-LFB20:
- .loc 1 65 0
- pushq %rbp
-LCFI12:
- movq %rsp, %rbp
-LCFI13:
- subq $16, %rsp
-LCFI14:
- movq %rdi, -8(%rbp)
- .loc 1 66 0
- movq -8(%rbp), %rdi
- call _msSleep
- .loc 1 68 0
- leave
- ret
-LFE20:
-.globl _Gasketexit
-_Gasketexit:
-LFB21:
- .loc 1 72 0
- pushq %rbp
-LCFI15:
- movq %rsp, %rbp
-LCFI16:
- subq $16, %rsp
-LCFI17:
- movl %edi, -4(%rbp)
- .loc 1 73 0
- movl -4(%rbp), %edi
- call _exit
-LFE21:
-.globl _GasketSetTimer
-_GasketSetTimer:
-LFB22:
- .loc 1 80 0
- pushq %rbp
-LCFI18:
- movq %rsp, %rbp
-LCFI19:
- subq $16, %rsp
-LCFI20:
- movq %rdi, -8(%rbp)
- movq %rsi, -16(%rbp)
- .loc 1 81 0
- movq -16(%rbp), %rsi
- movq -8(%rbp), %rdi
- call _SetTimer
- .loc 1 83 0
- leave
- ret
-LFE22:
-.globl _GasketGetLocalTime
-_GasketGetLocalTime:
-LFB23:
- .loc 1 88 0
- pushq %rbp
-LCFI21:
- movq %rsp, %rbp
-LCFI22:
- subq $16, %rsp
-LCFI23:
- movq %rdi, -8(%rbp)
- .loc 1 89 0
- movq -8(%rbp), %rdi
- call _GetLocalTime
- .loc 1 91 0
- leave
- ret
-LFE23:
-.globl _Gasketgmtime
-_Gasketgmtime:
-LFB24:
- .loc 1 96 0
- pushq %rbp
-LCFI24:
- movq %rsp, %rbp
-LCFI25:
- subq $16, %rsp
-LCFI26:
- movq %rdi, -8(%rbp)
- .loc 1 97 0
- movq -8(%rbp), %rdi
- call _localtime
- .loc 1 98 0
- leave
- ret
-LFE24:
-.globl _GasketGetTimeZone
-_GasketGetTimeZone:
-LFB25:
- .loc 1 103 0
- pushq %rbp
-LCFI27:
- movq %rsp, %rbp
-LCFI28:
- .loc 1 104 0
- call _GetTimeZone
- .loc 1 105 0
- leave
- ret
-LFE25:
-.globl _GasketGetDayLight
-_GasketGetDayLight:
-LFB26:
- .loc 1 110 0
- pushq %rbp
-LCFI29:
- movq %rsp, %rbp
-LCFI30:
- .loc 1 111 0
- call _GetDayLight
- .loc 1 112 0
- leave
- ret
-LFE26:
-.globl _Gasketpoll
-_Gasketpoll:
-LFB27:
- .loc 1 117 0
- pushq %rbp
-LCFI31:
- movq %rsp, %rbp
-LCFI32:
- subq $16, %rsp
-LCFI33:
- movq %rdi, -8(%rbp)
- movl %esi, -12(%rbp)
- movl %edx, -16(%rbp)
- .loc 1 118 0
- movl -16(%rbp), %edx
- movl -12(%rbp), %esi
- movq -8(%rbp), %rdi
- call _poll
- .loc 1 119 0
- leave
- ret
-LFE27:
-.globl _Gasketread
-_Gasketread:
-LFB28:
- .loc 1 124 0
- pushq %rbp
-LCFI34:
- movq %rsp, %rbp
-LCFI35:
- subq $32, %rsp
-LCFI36:
- movl %edi, -4(%rbp)
- movq %rsi, -16(%rbp)
- movl %edx, -20(%rbp)
- .loc 1 125 0
- movl -20(%rbp), %eax
- movslq %eax,%rdx
- movq -16(%rbp), %rsi
- movl -4(%rbp), %edi
- call _read
- .loc 1 126 0
- leave
- ret
-LFE28:
-.globl _Gasketwrite
-_Gasketwrite:
-LFB29:
- .loc 1 131 0
- pushq %rbp
-LCFI37:
- movq %rsp, %rbp
-LCFI38:
- subq $32, %rsp
-LCFI39:
- movl %edi, -4(%rbp)
- movq %rsi, -16(%rbp)
- movl %edx, -20(%rbp)
- .loc 1 132 0
- movl -20(%rbp), %eax
- movslq %eax,%rdx
- movq -16(%rbp), %rsi
- movl -4(%rbp), %edi
- call _write
- .loc 1 133 0
- leave
- ret
-LFE29:
-.globl _Gasketgetenv
-_Gasketgetenv:
-LFB30:
- .loc 1 138 0
- pushq %rbp
-LCFI40:
- movq %rsp, %rbp
-LCFI41:
- subq $16, %rsp
-LCFI42:
- movq %rdi, -8(%rbp)
- .loc 1 139 0
- movq -8(%rbp), %rdi
- call _getenv
- .loc 1 140 0
- leave
- ret
-LFE30:
-.globl _Gasketopen
-_Gasketopen:
-LFB31:
- .loc 1 145 0
- pushq %rbp
-LCFI43:
- movq %rsp, %rbp
-LCFI44:
- subq $16, %rsp
-LCFI45:
- movq %rdi, -8(%rbp)
- movl %esi, -12(%rbp)
- movl %edx, -16(%rbp)
- .loc 1 146 0
- movl -16(%rbp), %edx
- movl -12(%rbp), %esi
- movq -8(%rbp), %rdi
- movl $0, %eax
- call _open
- .loc 1 147 0
- leave
- ret
-LFE31:
-.globl _Gasketlseek
-_Gasketlseek:
-LFB32:
- .loc 1 152 0
- pushq %rbp
-LCFI46:
- movq %rsp, %rbp
-LCFI47:
- subq $32, %rsp
-LCFI48:
- movl %edi, -4(%rbp)
- movq %rsi, -16(%rbp)
- movl %edx, -20(%rbp)
- .loc 1 153 0
- movl -20(%rbp), %edx
- movq -16(%rbp), %rsi
- movl -4(%rbp), %edi
- call _lseek
- .loc 1 154 0
- leave
- ret
-LFE32:
-.globl _Gasketftruncate
-_Gasketftruncate:
-LFB33:
- .loc 1 159 0
- pushq %rbp
-LCFI49:
- movq %rsp, %rbp
-LCFI50:
- subq $16, %rsp
-LCFI51:
- movl %edi, -4(%rbp)
- movq %rsi, -16(%rbp)
- .loc 1 160 0
- movq -16(%rbp), %rsi
- movl -4(%rbp), %edi
- call _ftruncate
- .loc 1 161 0
- leave
- ret
-LFE33:
-.globl _Gasketclose
-_Gasketclose:
-LFB34:
- .loc 1 166 0
- pushq %rbp
-LCFI52:
- movq %rsp, %rbp
-LCFI53:
- subq $16, %rsp
-LCFI54:
- movl %edi, -4(%rbp)
- .loc 1 167 0
- movl -4(%rbp), %edi
- call _close
- .loc 1 168 0
- leave
- ret
-LFE34:
-.globl _Gasketmkdir
-_Gasketmkdir:
-LFB35:
- .loc 1 173 0
- pushq %rbp
-LCFI55:
- movq %rsp, %rbp
-LCFI56:
- subq $16, %rsp
-LCFI57:
- movq %rdi, -8(%rbp)
- movw %si, -12(%rbp)
- .loc 1 174 0
- movzwl -12(%rbp), %esi
- movq -8(%rbp), %rdi
- call _mkdir
- .loc 1 175 0
- leave
- ret
-LFE35:
-.globl _Gasketunlink
-_Gasketunlink:
-LFB36:
- .loc 1 180 0
- pushq %rbp
-LCFI58:
- movq %rsp, %rbp
-LCFI59:
- subq $16, %rsp
-LCFI60:
- movq %rdi, -8(%rbp)
- .loc 1 181 0
- movq -8(%rbp), %rdi
- call _unlink
- .loc 1 182 0
- leave
- ret
-LFE36:
-.globl _GasketGetErrno
-_GasketGetErrno:
-LFB37:
- .loc 1 187 0
- pushq %rbp
-LCFI61:
- movq %rsp, %rbp
-LCFI62:
- .loc 1 188 0
- call _GetErrno
- .loc 1 189 0
- leave
- ret
-LFE37:
-.globl _Gasketrewinddir
-_Gasketrewinddir:
-LFB38:
- .loc 1 194 0
- pushq %rbp
-LCFI63:
- movq %rsp, %rbp
-LCFI64:
- subq $16, %rsp
-LCFI65:
- movq %rdi, -8(%rbp)
- .loc 1 195 0
- movq -8(%rbp), %rdi
- call _rewinddir$INODE64
- .loc 1 197 0
- leave
- ret
-LFE38:
-.globl _Gasketreaddir
-_Gasketreaddir:
-LFB39:
- .loc 1 202 0
- pushq %rbp
-LCFI66:
- movq %rsp, %rbp
-LCFI67:
- subq $16, %rsp
-LCFI68:
- movq %rdi, -8(%rbp)
- .loc 1 203 0
- movq -8(%rbp), %rdi
- call _readdir$INODE64
- .loc 1 204 0
- leave
- ret
-LFE39:
-.globl _Gasketclosedir
-_Gasketclosedir:
-LFB40:
- .loc 1 209 0
- pushq %rbp
-LCFI69:
- movq %rsp, %rbp
-LCFI70:
- subq $16, %rsp
-LCFI71:
- movq %rdi, -8(%rbp)
- .loc 1 210 0
- movq -8(%rbp), %rdi
- call _closedir
- .loc 1 211 0
- leave
- ret
-LFE40:
-.globl _Gasketrename
-_Gasketrename:
-LFB41:
- .loc 1 216 0
- pushq %rbp
-LCFI72:
- movq %rsp, %rbp
-LCFI73:
- subq $16, %rsp
-LCFI74:
- movq %rdi, -8(%rbp)
- movq %rsi, -16(%rbp)
- .loc 1 217 0
- movq -16(%rbp), %rsi
- movq -8(%rbp), %rdi
- call _rename
- .loc 1 218 0
- leave
- ret
-LFE41:
-.globl _Gasketmktime
-_Gasketmktime:
-LFB42:
- .loc 1 223 0
- pushq %rbp
-LCFI75:
- movq %rsp, %rbp
-LCFI76:
- subq $16, %rsp
-LCFI77:
- movq %rdi, -8(%rbp)
- .loc 1 224 0
- movq -8(%rbp), %rdi
- call _mktime
- .loc 1 225 0
- leave
- ret
-LFE42:
-.globl _Gasketfsync
-_Gasketfsync:
-LFB43:
- .loc 1 230 0
- pushq %rbp
-LCFI78:
- movq %rsp, %rbp
-LCFI79:
- subq $16, %rsp
-LCFI80:
- movl %edi, -4(%rbp)
- .loc 1 231 0
- movl -4(%rbp), %edi
- call _fsync
- .loc 1 232 0
- leave
- ret
-LFE43:
-.globl _Gasketchmod
-_Gasketchmod:
-LFB44:
- .loc 1 237 0
- pushq %rbp
-LCFI81:
- movq %rsp, %rbp
-LCFI82:
- subq $16, %rsp
-LCFI83:
- movq %rdi, -8(%rbp)
- movw %si, -12(%rbp)
- .loc 1 238 0
- movzwl -12(%rbp), %esi
- movq -8(%rbp), %rdi
- call _chmod
- .loc 1 239 0
- leave
- ret
-LFE44:
-.globl _Gasketutime
-_Gasketutime:
-LFB45:
- .loc 1 244 0
- pushq %rbp
-LCFI84:
- movq %rsp, %rbp
-LCFI85:
- subq $16, %rsp
-LCFI86:
- movq %rdi, -8(%rbp)
- movq %rsi, -16(%rbp)
- .loc 1 245 0
- movq -16(%rbp), %rsi
- movq -8(%rbp), %rdi
- call _utime
- .loc 1 246 0
- leave
- ret
-LFE45:
-.globl _Gaskettcflush
-_Gaskettcflush:
-LFB46:
- .loc 1 251 0
- pushq %rbp
-LCFI87:
- movq %rsp, %rbp
-LCFI88:
- subq $16, %rsp
-LCFI89:
- movl %edi, -4(%rbp)
- movl %esi, -8(%rbp)
- .loc 1 252 0
- movl -8(%rbp), %esi
- movl -4(%rbp), %edi
- call _tcflush
- .loc 1 253 0
- leave
- ret
-LFE46:
-.globl _GasketUgaCreate
-_GasketUgaCreate:
-LFB47:
- .loc 1 258 0
- pushq %rbp
-LCFI90:
- movq %rsp, %rbp
-LCFI91:
- subq $16, %rsp
-LCFI92:
- movq %rdi, -8(%rbp)
- movq %rsi, -16(%rbp)
- .loc 1 259 0
- movq -16(%rbp), %rsi
- movq -8(%rbp), %rdi
- call _UgaCreate
- .loc 1 260 0
- leave
- ret
-LFE47:
-.globl _Gasketperror
-_Gasketperror:
-LFB48:
- .loc 1 265 0
- pushq %rbp
-LCFI93:
- movq %rsp, %rbp
-LCFI94:
- subq $16, %rsp
-LCFI95:
- movq %rdi, -8(%rbp)
- .loc 1 266 0
- movq -8(%rbp), %rdi
- call _perror
- .loc 1 268 0
- leave
- ret
-LFE48:
-.globl _Gasketioctl
-_Gasketioctl:
-LFB49:
- .loc 1 277 0
- pushq %rbp
-LCFI96:
- movq %rsp, %rbp
-LCFI97:
- subq $240, %rsp
-LCFI98:
- movl %edi, -212(%rbp)
- movq %rdx, -160(%rbp)
- movq %rcx, -152(%rbp)
- movq %r8, -144(%rbp)
- movq %r9, -136(%rbp)
- movzbl %al, %eax
- movq %rax, -240(%rbp)
- movq -240(%rbp), %rdx
- leaq 0(,%rdx,4), %rax
- leaq L68(%rip), %rdx
- movq %rdx, -240(%rbp)
- subq %rax, -240(%rbp)
- leaq -1(%rbp), %rax
- movq -240(%rbp), %rdx
- jmp *%rdx
- movaps %xmm7, -15(%rax)
- movaps %xmm6, -31(%rax)
- movaps %xmm5, -47(%rax)
- movaps %xmm4, -63(%rax)
- movaps %xmm3, -79(%rax)
- movaps %xmm2, -95(%rax)
- movaps %xmm1, -111(%rax)
- movaps %xmm0, -127(%rax)
-L68:
- movq %rsi, -224(%rbp)
- .loc 1 280 0
- leaq -208(%rbp), %rax
- movl $16, (%rax)
- leaq -208(%rbp), %rax
- movl $48, 4(%rax)
- leaq -208(%rbp), %rax
- leaq 16(%rbp), %rdx
- movq %rdx, 8(%rax)
- leaq -208(%rbp), %rax
- leaq -176(%rbp), %rdx
- movq %rdx, 16(%rax)
- .loc 1 281 0
- movl -208(%rbp), %eax
- cmpl $48, %eax
- jae L69
- movq -192(%rbp), %rdx
- movl -208(%rbp), %eax
- mov %eax, %eax
- addq %rax, %rdx
- movq %rdx, -232(%rbp)
- movl -208(%rbp), %eax
- addl $8, %eax
- movl %eax, -208(%rbp)
- jmp L71
-L69:
- movq -200(%rbp), %rax
- movq %rax, -232(%rbp)
- addq $8, %rax
- movq %rax, -200(%rbp)
-L71:
- movq -232(%rbp), %rax
- movq (%rax), %rdx
- movq -224(%rbp), %rsi
- movl -212(%rbp), %edi
- movl $0, %eax
- call _ioctl
- .loc 1 282 0
- leave
- ret
-LFE49:
-.globl _Gasketfcntl
-_Gasketfcntl:
-LFB50:
- .loc 1 287 0
- pushq %rbp
-LCFI99:
- movq %rsp, %rbp
-LCFI100:
- subq $240, %rsp
-LCFI101:
- movl %edi, -212(%rbp)
- movq %rdx, -160(%rbp)
- movq %rcx, -152(%rbp)
- movq %r8, -144(%rbp)
- movq %r9, -136(%rbp)
- movzbl %al, %eax
- movq %rax, -232(%rbp)
- movq -232(%rbp), %rdx
- leaq 0(,%rdx,4), %rax
- leaq L74(%rip), %rdx
- movq %rdx, -232(%rbp)
- subq %rax, -232(%rbp)
- leaq -1(%rbp), %rax
- movq -232(%rbp), %rdx
- jmp *%rdx
- movaps %xmm7, -15(%rax)
- movaps %xmm6, -31(%rax)
- movaps %xmm5, -47(%rax)
- movaps %xmm4, -63(%rax)
- movaps %xmm3, -79(%rax)
- movaps %xmm2, -95(%rax)
- movaps %xmm1, -111(%rax)
- movaps %xmm0, -127(%rax)
-L74:
- movl %esi, -216(%rbp)
- .loc 1 290 0
- leaq -208(%rbp), %rax
- movl $16, (%rax)
- leaq -208(%rbp), %rax
- movl $48, 4(%rax)
- leaq -208(%rbp), %rax
- leaq 16(%rbp), %rdx
- movq %rdx, 8(%rax)
- leaq -208(%rbp), %rax
- leaq -176(%rbp), %rdx
- movq %rdx, 16(%rax)
- .loc 1 291 0
- movl -208(%rbp), %eax
- cmpl $48, %eax
- jae L75
- movq -192(%rbp), %rdx
- movl -208(%rbp), %eax
- mov %eax, %eax
- addq %rax, %rdx
- movq %rdx, -224(%rbp)
- movl -208(%rbp), %eax
- addl $8, %eax
- movl %eax, -208(%rbp)
- jmp L77
-L75:
- movq -200(%rbp), %rax
- movq %rax, -224(%rbp)
- addq $8, %rax
- movq %rax, -200(%rbp)
-L77:
- movq -224(%rbp), %rax
- movq (%rax), %rdx
- movl -216(%rbp), %esi
- movl -212(%rbp), %edi
- movl $0, %eax
- call _fcntl
- .loc 1 292 0
- leave
- ret
-LFE50:
-.globl _Gasketcfsetispeed
-_Gasketcfsetispeed:
-LFB51:
- .loc 1 298 0
- pushq %rbp
-LCFI102:
- movq %rsp, %rbp
-LCFI103:
- subq $16, %rsp
-LCFI104:
- movq %rdi, -8(%rbp)
- movq %rsi, -16(%rbp)
- .loc 1 299 0
- movq -16(%rbp), %rsi
- movq -8(%rbp), %rdi
- call _cfsetispeed
- .loc 1 300 0
- leave
- ret
-LFE51:
-.globl _Gasketcfsetospeed
-_Gasketcfsetospeed:
-LFB52:
- .loc 1 305 0
- pushq %rbp
-LCFI105:
- movq %rsp, %rbp
-LCFI106:
- subq $16, %rsp
-LCFI107:
- movq %rdi, -8(%rbp)
- movq %rsi, -16(%rbp)
- .loc 1 306 0
- movq -16(%rbp), %rsi
- movq -8(%rbp), %rdi
- call _cfsetospeed
- .loc 1 307 0
- leave
- ret
-LFE52:
-.globl _Gaskettcgetattr
-_Gaskettcgetattr:
-LFB53:
- .loc 1 312 0
- pushq %rbp
-LCFI108:
- movq %rsp, %rbp
-LCFI109:
- subq $16, %rsp
-LCFI110:
- movl %edi, -4(%rbp)
- movq %rsi, -16(%rbp)
- .loc 1 313 0
- movq -16(%rbp), %rsi
- movl -4(%rbp), %edi
- call _tcgetattr
- .loc 1 314 0
- leave
- ret
-LFE53:
-.globl _Gaskettcsetattr
-_Gaskettcsetattr:
-LFB54:
- .loc 1 319 0
- pushq %rbp
-LCFI111:
- movq %rsp, %rbp
-LCFI112:
- subq $16, %rsp
-LCFI113:
- movl %edi, -4(%rbp)
- movl %esi, -8(%rbp)
- movq %rdx, -16(%rbp)
- .loc 1 320 0
- movq -16(%rbp), %rdx
- movl -8(%rbp), %esi
- movl -4(%rbp), %edi
- call _tcsetattr
- .loc 1 321 0
- leave
- ret
-LFE54:
-.globl _GasketUnixPeCoffGetEntryPoint
-_GasketUnixPeCoffGetEntryPoint:
-LFB55:
- .loc 1 331 0
- pushq %rbp
-LCFI114:
- movq %rsp, %rbp
-LCFI115:
- subq $16, %rsp
-LCFI116:
- movq %rdi, -8(%rbp)
- movq %rsi, -16(%rbp)
- .loc 1 332 0
- movq -16(%rbp), %rsi
- movq -8(%rbp), %rdi
- call _SecPeCoffGetEntryPoint
- .loc 1 333 0
- leave
- ret
-LFE55:
-.globl _GasketUnixPeCoffRelocateImageExtraAction
-_GasketUnixPeCoffRelocateImageExtraAction:
-LFB56:
- .loc 1 341 0
- pushq %rbp
-LCFI117:
- movq %rsp, %rbp
-LCFI118:
- subq $16, %rsp
-LCFI119:
- movq %rdi, -8(%rbp)
- .loc 1 342 0
- movq -8(%rbp), %rdi
- call _SecPeCoffRelocateImageExtraAction
- .loc 1 344 0
- leave
- ret
-LFE56:
-.globl _GasketUnixPeCoffUnloadImageExtraAction
-_GasketUnixPeCoffUnloadImageExtraAction:
-LFB57:
- .loc 1 352 0
- pushq %rbp
-LCFI120:
- movq %rsp, %rbp
-LCFI121:
- subq $16, %rsp
-LCFI122:
- movq %rdi, -8(%rbp)
- .loc 1 353 0
- movq -8(%rbp), %rdi
- call _SecPeCoffLoaderUnloadImageExtraAction
- .loc 1 355 0
- leave
- ret
-LFE57:
-.globl _GasketUgaClose
-_GasketUgaClose:
-LFB58:
- .loc 1 365 0
- pushq %rbp
-LCFI123:
- movq %rsp, %rbp
-LCFI124:
- subq $16, %rsp
-LCFI125:
- movq %rdi, -8(%rbp)
- .loc 1 366 0
- movq -8(%rbp), %rdi
- call _UgaClose
- .loc 1 367 0
- leave
- ret
-LFE58:
-.globl _GasketUgaSize
-_GasketUgaSize:
-LFB59:
- .loc 1 372 0
- pushq %rbp
-LCFI126:
- movq %rsp, %rbp
-LCFI127:
- subq $16, %rsp
-LCFI128:
- movq %rdi, -8(%rbp)
- movl %esi, -12(%rbp)
- movl %edx, -16(%rbp)
- .loc 1 373 0
- movl -16(%rbp), %edx
- movl -12(%rbp), %esi
- movq -8(%rbp), %rdi
- call _UgaSize
- .loc 1 374 0
- leave
- ret
-LFE59:
-.globl _GasketUgaCheckKey
-_GasketUgaCheckKey:
-LFB60:
- .loc 1 379 0
- pushq %rbp
-LCFI129:
- movq %rsp, %rbp
-LCFI130:
- subq $16, %rsp
-LCFI131:
- movq %rdi, -8(%rbp)
- .loc 1 380 0
- movq -8(%rbp), %rdi
- call _UgaCheckKey
- .loc 1 381 0
- leave
- ret
-LFE60:
-.globl _GasketUgaGetKey
-_GasketUgaGetKey:
-LFB61:
- .loc 1 386 0
- pushq %rbp
-LCFI132:
- movq %rsp, %rbp
-LCFI133:
- subq $16, %rsp
-LCFI134:
- movq %rdi, -8(%rbp)
- movq %rsi, -16(%rbp)
- .loc 1 387 0
- movq -16(%rbp), %rsi
- movq -8(%rbp), %rdi
- call _UgaGetKey
- .loc 1 388 0
- leave
- ret
-LFE61:
-.globl _GasketUgaBlt
-_GasketUgaBlt:
-LFB62:
- .loc 1 404 0
- pushq %rbp
-LCFI135:
- movq %rsp, %rbp
-LCFI136:
- subq $80, %rsp
-LCFI137:
- movq %rdi, -8(%rbp)
- movq %rsi, -16(%rbp)
- movl %edx, -20(%rbp)
- movq %rcx, -32(%rbp)
- movq %r8, -40(%rbp)
- movq %r9, -48(%rbp)
- .loc 1 405 0
- movq -48(%rbp), %rdx
- movq -40(%rbp), %rcx
- movq -32(%rbp), %rsi
- movl -20(%rbp), %edi
- movq -16(%rbp), %r10
- movq -8(%rbp), %r11
- movq 40(%rbp), %rax
- movq %rax, 24(%rsp)
- movq 32(%rbp), %rax
- movq %rax, 16(%rsp)
- movq 24(%rbp), %rax
- movq %rax, 8(%rsp)
- movq 16(%rbp), %rax
- movq %rax, (%rsp)
- movq %rdx, %r9
- movq %rcx, %r8
- movq %rsi, %rcx
- movl %edi, %edx
- movq %r10, %rsi
- movq %r11, %rdi
- call _UgaBlt
- .loc 1 406 0
- leave
- ret
-LFE62:
-
-.globl _ReverseGasketUint64
-_ReverseGasketUint64:
-LFB63:
- .loc 1 413 0
- pushq %rbp
-LCFI138:
- movq %rsp, %rbp
-LCFI139:
- subq $32, %rsp
-LCFI140:
- movq %rdi, -24(%rbp)
- movq %rsi, -32(%rbp)
- .loc 1 414 0
- movq -24(%rbp), %rax
- movq %rax, -8(%rbp)
- .loc 1 416 0
- movq -32(%rbp), %rdi
- movq -8(%rbp), %rax
- call *%rax
- .loc 1 417 0
- movl $0, %eax
- .loc 1 418 0
- leave
- ret
-
-.globl _EfiReverseGasketUint64
-_EfiReverseGasketUint64:
- pushq %rbp
- movq %rsp, %rbp
- subq $64, %rsp
- movq %rdi, -24(%rbp)
- movq %rsi, -32(%rbp)
- movq -24(%rbp), %rax
- movq %rax, -8(%rbp)
- movq -32(%rbp), %rcx
- movq -8(%rbp), %rax
- call *%rax
- leave
- ret
-
-// Sec PPI Callbacks
-
-.globl _GasketSecUnixPeiLoadFile
-_GasketSecUnixPeiLoadFile:
- jmp _SecUnixPeiLoadFile
-
-
-.globl _GasketSecUnixPeiAutoScan
-_GasketSecUnixPeiAutoScan:
- jmp _SecUnixPeiAutoScan
-
-
-.globl _GasketSecUnixUnixThunkAddress
-_GasketSecUnixUnixThunkAddress:
- jmp _SecUnixUnixThunkAddress
-
-
-.globl _GasketSecPeiReportStatusCode
-_GasketSecPeiReportStatusCode:
- jmp _SecPeiReportStatusCode
-
-
-.globl _GasketSecUnixFdAddress
-_GasketSecUnixFdAddress:
- jmp _SecUnixFdAddress
-
-
-.globl _GasketSecTemporaryRamSupport
-_GasketSecTemporaryRamSupport:
- jmp _SecTemporaryRamSupport
-
-
-
-#if __APPLE__
-
-LFE63:
- .section __DWARF,__debug_frame,regular,debug
-Lframe0:
- .set L$set$0,LECIE0-LSCIE0
- .long L$set$0
-LSCIE0:
- .long 0xffffffff
- .byte 0x1
- .ascii "\0"
- .byte 0x1
- .byte 0x78
- .byte 0x10
- .byte 0xc
- .byte 0x7
- .byte 0x8
- .byte 0x90
- .byte 0x1
- .align 3
-LECIE0:
-LSFDE0:
- .set L$set$1,LEFDE0-LASFDE0
- .long L$set$1
-LASFDE0:
- .set L$set$2,Lframe0-Lsection__debug_frame
- .long L$set$2
- .quad LFB16
- .set L$set$3,LFE16-LFB16
- .quad L$set$3
- .byte 0x4
- .set L$set$4,LCFI0-LFB16
- .long L$set$4
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$5,LCFI1-LCFI0
- .long L$set$5
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE0:
-LSFDE2:
- .set L$set$6,LEFDE2-LASFDE2
- .long L$set$6
-LASFDE2:
- .set L$set$7,Lframe0-Lsection__debug_frame
- .long L$set$7
- .quad LFB17
- .set L$set$8,LFE17-LFB17
- .quad L$set$8
- .byte 0x4
- .set L$set$9,LCFI3-LFB17
- .long L$set$9
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$10,LCFI4-LCFI3
- .long L$set$10
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE2:
-LSFDE4:
- .set L$set$11,LEFDE4-LASFDE4
- .long L$set$11
-LASFDE4:
- .set L$set$12,Lframe0-Lsection__debug_frame
- .long L$set$12
- .quad LFB18
- .set L$set$13,LFE18-LFB18
- .quad L$set$13
- .byte 0x4
- .set L$set$14,LCFI6-LFB18
- .long L$set$14
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$15,LCFI7-LCFI6
- .long L$set$15
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE4:
-LSFDE6:
- .set L$set$16,LEFDE6-LASFDE6
- .long L$set$16
-LASFDE6:
- .set L$set$17,Lframe0-Lsection__debug_frame
- .long L$set$17
- .quad LFB19
- .set L$set$18,LFE19-LFB19
- .quad L$set$18
- .byte 0x4
- .set L$set$19,LCFI9-LFB19
- .long L$set$19
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$20,LCFI10-LCFI9
- .long L$set$20
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE6:
-LSFDE8:
- .set L$set$21,LEFDE8-LASFDE8
- .long L$set$21
-LASFDE8:
- .set L$set$22,Lframe0-Lsection__debug_frame
- .long L$set$22
- .quad LFB20
- .set L$set$23,LFE20-LFB20
- .quad L$set$23
- .byte 0x4
- .set L$set$24,LCFI12-LFB20
- .long L$set$24
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$25,LCFI13-LCFI12
- .long L$set$25
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE8:
-LSFDE10:
- .set L$set$26,LEFDE10-LASFDE10
- .long L$set$26
-LASFDE10:
- .set L$set$27,Lframe0-Lsection__debug_frame
- .long L$set$27
- .quad LFB21
- .set L$set$28,LFE21-LFB21
- .quad L$set$28
- .byte 0x4
- .set L$set$29,LCFI15-LFB21
- .long L$set$29
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$30,LCFI16-LCFI15
- .long L$set$30
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE10:
-LSFDE12:
- .set L$set$31,LEFDE12-LASFDE12
- .long L$set$31
-LASFDE12:
- .set L$set$32,Lframe0-Lsection__debug_frame
- .long L$set$32
- .quad LFB22
- .set L$set$33,LFE22-LFB22
- .quad L$set$33
- .byte 0x4
- .set L$set$34,LCFI18-LFB22
- .long L$set$34
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$35,LCFI19-LCFI18
- .long L$set$35
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE12:
-LSFDE14:
- .set L$set$36,LEFDE14-LASFDE14
- .long L$set$36
-LASFDE14:
- .set L$set$37,Lframe0-Lsection__debug_frame
- .long L$set$37
- .quad LFB23
- .set L$set$38,LFE23-LFB23
- .quad L$set$38
- .byte 0x4
- .set L$set$39,LCFI21-LFB23
- .long L$set$39
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$40,LCFI22-LCFI21
- .long L$set$40
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE14:
-LSFDE16:
- .set L$set$41,LEFDE16-LASFDE16
- .long L$set$41
-LASFDE16:
- .set L$set$42,Lframe0-Lsection__debug_frame
- .long L$set$42
- .quad LFB24
- .set L$set$43,LFE24-LFB24
- .quad L$set$43
- .byte 0x4
- .set L$set$44,LCFI24-LFB24
- .long L$set$44
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$45,LCFI25-LCFI24
- .long L$set$45
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE16:
-LSFDE18:
- .set L$set$46,LEFDE18-LASFDE18
- .long L$set$46
-LASFDE18:
- .set L$set$47,Lframe0-Lsection__debug_frame
- .long L$set$47
- .quad LFB25
- .set L$set$48,LFE25-LFB25
- .quad L$set$48
- .byte 0x4
- .set L$set$49,LCFI27-LFB25
- .long L$set$49
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$50,LCFI28-LCFI27
- .long L$set$50
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE18:
-LSFDE20:
- .set L$set$51,LEFDE20-LASFDE20
- .long L$set$51
-LASFDE20:
- .set L$set$52,Lframe0-Lsection__debug_frame
- .long L$set$52
- .quad LFB26
- .set L$set$53,LFE26-LFB26
- .quad L$set$53
- .byte 0x4
- .set L$set$54,LCFI29-LFB26
- .long L$set$54
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$55,LCFI30-LCFI29
- .long L$set$55
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE20:
-LSFDE22:
- .set L$set$56,LEFDE22-LASFDE22
- .long L$set$56
-LASFDE22:
- .set L$set$57,Lframe0-Lsection__debug_frame
- .long L$set$57
- .quad LFB27
- .set L$set$58,LFE27-LFB27
- .quad L$set$58
- .byte 0x4
- .set L$set$59,LCFI31-LFB27
- .long L$set$59
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$60,LCFI32-LCFI31
- .long L$set$60
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE22:
-LSFDE24:
- .set L$set$61,LEFDE24-LASFDE24
- .long L$set$61
-LASFDE24:
- .set L$set$62,Lframe0-Lsection__debug_frame
- .long L$set$62
- .quad LFB28
- .set L$set$63,LFE28-LFB28
- .quad L$set$63
- .byte 0x4
- .set L$set$64,LCFI34-LFB28
- .long L$set$64
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$65,LCFI35-LCFI34
- .long L$set$65
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE24:
-LSFDE26:
- .set L$set$66,LEFDE26-LASFDE26
- .long L$set$66
-LASFDE26:
- .set L$set$67,Lframe0-Lsection__debug_frame
- .long L$set$67
- .quad LFB29
- .set L$set$68,LFE29-LFB29
- .quad L$set$68
- .byte 0x4
- .set L$set$69,LCFI37-LFB29
- .long L$set$69
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$70,LCFI38-LCFI37
- .long L$set$70
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE26:
-LSFDE28:
- .set L$set$71,LEFDE28-LASFDE28
- .long L$set$71
-LASFDE28:
- .set L$set$72,Lframe0-Lsection__debug_frame
- .long L$set$72
- .quad LFB30
- .set L$set$73,LFE30-LFB30
- .quad L$set$73
- .byte 0x4
- .set L$set$74,LCFI40-LFB30
- .long L$set$74
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$75,LCFI41-LCFI40
- .long L$set$75
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE28:
-LSFDE30:
- .set L$set$76,LEFDE30-LASFDE30
- .long L$set$76
-LASFDE30:
- .set L$set$77,Lframe0-Lsection__debug_frame
- .long L$set$77
- .quad LFB31
- .set L$set$78,LFE31-LFB31
- .quad L$set$78
- .byte 0x4
- .set L$set$79,LCFI43-LFB31
- .long L$set$79
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$80,LCFI44-LCFI43
- .long L$set$80
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE30:
-LSFDE32:
- .set L$set$81,LEFDE32-LASFDE32
- .long L$set$81
-LASFDE32:
- .set L$set$82,Lframe0-Lsection__debug_frame
- .long L$set$82
- .quad LFB32
- .set L$set$83,LFE32-LFB32
- .quad L$set$83
- .byte 0x4
- .set L$set$84,LCFI46-LFB32
- .long L$set$84
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$85,LCFI47-LCFI46
- .long L$set$85
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE32:
-LSFDE34:
- .set L$set$86,LEFDE34-LASFDE34
- .long L$set$86
-LASFDE34:
- .set L$set$87,Lframe0-Lsection__debug_frame
- .long L$set$87
- .quad LFB33
- .set L$set$88,LFE33-LFB33
- .quad L$set$88
- .byte 0x4
- .set L$set$89,LCFI49-LFB33
- .long L$set$89
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$90,LCFI50-LCFI49
- .long L$set$90
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE34:
-LSFDE36:
- .set L$set$91,LEFDE36-LASFDE36
- .long L$set$91
-LASFDE36:
- .set L$set$92,Lframe0-Lsection__debug_frame
- .long L$set$92
- .quad LFB34
- .set L$set$93,LFE34-LFB34
- .quad L$set$93
- .byte 0x4
- .set L$set$94,LCFI52-LFB34
- .long L$set$94
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$95,LCFI53-LCFI52
- .long L$set$95
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE36:
-LSFDE38:
- .set L$set$96,LEFDE38-LASFDE38
- .long L$set$96
-LASFDE38:
- .set L$set$97,Lframe0-Lsection__debug_frame
- .long L$set$97
- .quad LFB35
- .set L$set$98,LFE35-LFB35
- .quad L$set$98
- .byte 0x4
- .set L$set$99,LCFI55-LFB35
- .long L$set$99
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$100,LCFI56-LCFI55
- .long L$set$100
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE38:
-LSFDE40:
- .set L$set$101,LEFDE40-LASFDE40
- .long L$set$101
-LASFDE40:
- .set L$set$102,Lframe0-Lsection__debug_frame
- .long L$set$102
- .quad LFB36
- .set L$set$103,LFE36-LFB36
- .quad L$set$103
- .byte 0x4
- .set L$set$104,LCFI58-LFB36
- .long L$set$104
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$105,LCFI59-LCFI58
- .long L$set$105
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE40:
-LSFDE42:
- .set L$set$106,LEFDE42-LASFDE42
- .long L$set$106
-LASFDE42:
- .set L$set$107,Lframe0-Lsection__debug_frame
- .long L$set$107
- .quad LFB37
- .set L$set$108,LFE37-LFB37
- .quad L$set$108
- .byte 0x4
- .set L$set$109,LCFI61-LFB37
- .long L$set$109
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$110,LCFI62-LCFI61
- .long L$set$110
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE42:
-LSFDE44:
- .set L$set$111,LEFDE44-LASFDE44
- .long L$set$111
-LASFDE44:
- .set L$set$112,Lframe0-Lsection__debug_frame
- .long L$set$112
- .quad LFB38
- .set L$set$113,LFE38-LFB38
- .quad L$set$113
- .byte 0x4
- .set L$set$114,LCFI63-LFB38
- .long L$set$114
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$115,LCFI64-LCFI63
- .long L$set$115
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE44:
-LSFDE46:
- .set L$set$116,LEFDE46-LASFDE46
- .long L$set$116
-LASFDE46:
- .set L$set$117,Lframe0-Lsection__debug_frame
- .long L$set$117
- .quad LFB39
- .set L$set$118,LFE39-LFB39
- .quad L$set$118
- .byte 0x4
- .set L$set$119,LCFI66-LFB39
- .long L$set$119
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$120,LCFI67-LCFI66
- .long L$set$120
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE46:
-LSFDE48:
- .set L$set$121,LEFDE48-LASFDE48
- .long L$set$121
-LASFDE48:
- .set L$set$122,Lframe0-Lsection__debug_frame
- .long L$set$122
- .quad LFB40
- .set L$set$123,LFE40-LFB40
- .quad L$set$123
- .byte 0x4
- .set L$set$124,LCFI69-LFB40
- .long L$set$124
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$125,LCFI70-LCFI69
- .long L$set$125
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE48:
-LSFDE50:
- .set L$set$126,LEFDE50-LASFDE50
- .long L$set$126
-LASFDE50:
- .set L$set$127,Lframe0-Lsection__debug_frame
- .long L$set$127
- .quad LFB41
- .set L$set$128,LFE41-LFB41
- .quad L$set$128
- .byte 0x4
- .set L$set$129,LCFI72-LFB41
- .long L$set$129
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$130,LCFI73-LCFI72
- .long L$set$130
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE50:
-LSFDE52:
- .set L$set$131,LEFDE52-LASFDE52
- .long L$set$131
-LASFDE52:
- .set L$set$132,Lframe0-Lsection__debug_frame
- .long L$set$132
- .quad LFB42
- .set L$set$133,LFE42-LFB42
- .quad L$set$133
- .byte 0x4
- .set L$set$134,LCFI75-LFB42
- .long L$set$134
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$135,LCFI76-LCFI75
- .long L$set$135
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE52:
-LSFDE54:
- .set L$set$136,LEFDE54-LASFDE54
- .long L$set$136
-LASFDE54:
- .set L$set$137,Lframe0-Lsection__debug_frame
- .long L$set$137
- .quad LFB43
- .set L$set$138,LFE43-LFB43
- .quad L$set$138
- .byte 0x4
- .set L$set$139,LCFI78-LFB43
- .long L$set$139
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$140,LCFI79-LCFI78
- .long L$set$140
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE54:
-LSFDE56:
- .set L$set$141,LEFDE56-LASFDE56
- .long L$set$141
-LASFDE56:
- .set L$set$142,Lframe0-Lsection__debug_frame
- .long L$set$142
- .quad LFB44
- .set L$set$143,LFE44-LFB44
- .quad L$set$143
- .byte 0x4
- .set L$set$144,LCFI81-LFB44
- .long L$set$144
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$145,LCFI82-LCFI81
- .long L$set$145
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE56:
-LSFDE58:
- .set L$set$146,LEFDE58-LASFDE58
- .long L$set$146
-LASFDE58:
- .set L$set$147,Lframe0-Lsection__debug_frame
- .long L$set$147
- .quad LFB45
- .set L$set$148,LFE45-LFB45
- .quad L$set$148
- .byte 0x4
- .set L$set$149,LCFI84-LFB45
- .long L$set$149
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$150,LCFI85-LCFI84
- .long L$set$150
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE58:
-LSFDE60:
- .set L$set$151,LEFDE60-LASFDE60
- .long L$set$151
-LASFDE60:
- .set L$set$152,Lframe0-Lsection__debug_frame
- .long L$set$152
- .quad LFB46
- .set L$set$153,LFE46-LFB46
- .quad L$set$153
- .byte 0x4
- .set L$set$154,LCFI87-LFB46
- .long L$set$154
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$155,LCFI88-LCFI87
- .long L$set$155
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE60:
-LSFDE62:
- .set L$set$156,LEFDE62-LASFDE62
- .long L$set$156
-LASFDE62:
- .set L$set$157,Lframe0-Lsection__debug_frame
- .long L$set$157
- .quad LFB47
- .set L$set$158,LFE47-LFB47
- .quad L$set$158
- .byte 0x4
- .set L$set$159,LCFI90-LFB47
- .long L$set$159
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$160,LCFI91-LCFI90
- .long L$set$160
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE62:
-LSFDE64:
- .set L$set$161,LEFDE64-LASFDE64
- .long L$set$161
-LASFDE64:
- .set L$set$162,Lframe0-Lsection__debug_frame
- .long L$set$162
- .quad LFB48
- .set L$set$163,LFE48-LFB48
- .quad L$set$163
- .byte 0x4
- .set L$set$164,LCFI93-LFB48
- .long L$set$164
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$165,LCFI94-LCFI93
- .long L$set$165
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE64:
-LSFDE66:
- .set L$set$166,LEFDE66-LASFDE66
- .long L$set$166
-LASFDE66:
- .set L$set$167,Lframe0-Lsection__debug_frame
- .long L$set$167
- .quad LFB49
- .set L$set$168,LFE49-LFB49
- .quad L$set$168
- .byte 0x4
- .set L$set$169,LCFI96-LFB49
- .long L$set$169
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$170,LCFI97-LCFI96
- .long L$set$170
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE66:
-LSFDE68:
- .set L$set$171,LEFDE68-LASFDE68
- .long L$set$171
-LASFDE68:
- .set L$set$172,Lframe0-Lsection__debug_frame
- .long L$set$172
- .quad LFB50
- .set L$set$173,LFE50-LFB50
- .quad L$set$173
- .byte 0x4
- .set L$set$174,LCFI99-LFB50
- .long L$set$174
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$175,LCFI100-LCFI99
- .long L$set$175
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE68:
-LSFDE70:
- .set L$set$176,LEFDE70-LASFDE70
- .long L$set$176
-LASFDE70:
- .set L$set$177,Lframe0-Lsection__debug_frame
- .long L$set$177
- .quad LFB51
- .set L$set$178,LFE51-LFB51
- .quad L$set$178
- .byte 0x4
- .set L$set$179,LCFI102-LFB51
- .long L$set$179
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$180,LCFI103-LCFI102
- .long L$set$180
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE70:
-LSFDE72:
- .set L$set$181,LEFDE72-LASFDE72
- .long L$set$181
-LASFDE72:
- .set L$set$182,Lframe0-Lsection__debug_frame
- .long L$set$182
- .quad LFB52
- .set L$set$183,LFE52-LFB52
- .quad L$set$183
- .byte 0x4
- .set L$set$184,LCFI105-LFB52
- .long L$set$184
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$185,LCFI106-LCFI105
- .long L$set$185
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE72:
-LSFDE74:
- .set L$set$186,LEFDE74-LASFDE74
- .long L$set$186
-LASFDE74:
- .set L$set$187,Lframe0-Lsection__debug_frame
- .long L$set$187
- .quad LFB53
- .set L$set$188,LFE53-LFB53
- .quad L$set$188
- .byte 0x4
- .set L$set$189,LCFI108-LFB53
- .long L$set$189
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$190,LCFI109-LCFI108
- .long L$set$190
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE74:
-LSFDE76:
- .set L$set$191,LEFDE76-LASFDE76
- .long L$set$191
-LASFDE76:
- .set L$set$192,Lframe0-Lsection__debug_frame
- .long L$set$192
- .quad LFB54
- .set L$set$193,LFE54-LFB54
- .quad L$set$193
- .byte 0x4
- .set L$set$194,LCFI111-LFB54
- .long L$set$194
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$195,LCFI112-LCFI111
- .long L$set$195
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE76:
-LSFDE78:
- .set L$set$196,LEFDE78-LASFDE78
- .long L$set$196
-LASFDE78:
- .set L$set$197,Lframe0-Lsection__debug_frame
- .long L$set$197
- .quad LFB55
- .set L$set$198,LFE55-LFB55
- .quad L$set$198
- .byte 0x4
- .set L$set$199,LCFI114-LFB55
- .long L$set$199
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$200,LCFI115-LCFI114
- .long L$set$200
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE78:
-LSFDE80:
- .set L$set$201,LEFDE80-LASFDE80
- .long L$set$201
-LASFDE80:
- .set L$set$202,Lframe0-Lsection__debug_frame
- .long L$set$202
- .quad LFB56
- .set L$set$203,LFE56-LFB56
- .quad L$set$203
- .byte 0x4
- .set L$set$204,LCFI117-LFB56
- .long L$set$204
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$205,LCFI118-LCFI117
- .long L$set$205
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE80:
-LSFDE82:
- .set L$set$206,LEFDE82-LASFDE82
- .long L$set$206
-LASFDE82:
- .set L$set$207,Lframe0-Lsection__debug_frame
- .long L$set$207
- .quad LFB57
- .set L$set$208,LFE57-LFB57
- .quad L$set$208
- .byte 0x4
- .set L$set$209,LCFI120-LFB57
- .long L$set$209
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$210,LCFI121-LCFI120
- .long L$set$210
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE82:
-LSFDE84:
- .set L$set$211,LEFDE84-LASFDE84
- .long L$set$211
-LASFDE84:
- .set L$set$212,Lframe0-Lsection__debug_frame
- .long L$set$212
- .quad LFB58
- .set L$set$213,LFE58-LFB58
- .quad L$set$213
- .byte 0x4
- .set L$set$214,LCFI123-LFB58
- .long L$set$214
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$215,LCFI124-LCFI123
- .long L$set$215
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE84:
-LSFDE86:
- .set L$set$216,LEFDE86-LASFDE86
- .long L$set$216
-LASFDE86:
- .set L$set$217,Lframe0-Lsection__debug_frame
- .long L$set$217
- .quad LFB59
- .set L$set$218,LFE59-LFB59
- .quad L$set$218
- .byte 0x4
- .set L$set$219,LCFI126-LFB59
- .long L$set$219
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$220,LCFI127-LCFI126
- .long L$set$220
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE86:
-LSFDE88:
- .set L$set$221,LEFDE88-LASFDE88
- .long L$set$221
-LASFDE88:
- .set L$set$222,Lframe0-Lsection__debug_frame
- .long L$set$222
- .quad LFB60
- .set L$set$223,LFE60-LFB60
- .quad L$set$223
- .byte 0x4
- .set L$set$224,LCFI129-LFB60
- .long L$set$224
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$225,LCFI130-LCFI129
- .long L$set$225
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE88:
-LSFDE90:
- .set L$set$226,LEFDE90-LASFDE90
- .long L$set$226
-LASFDE90:
- .set L$set$227,Lframe0-Lsection__debug_frame
- .long L$set$227
- .quad LFB61
- .set L$set$228,LFE61-LFB61
- .quad L$set$228
- .byte 0x4
- .set L$set$229,LCFI132-LFB61
- .long L$set$229
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$230,LCFI133-LCFI132
- .long L$set$230
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE90:
-LSFDE92:
- .set L$set$231,LEFDE92-LASFDE92
- .long L$set$231
-LASFDE92:
- .set L$set$232,Lframe0-Lsection__debug_frame
- .long L$set$232
- .quad LFB62
- .set L$set$233,LFE62-LFB62
- .quad L$set$233
- .byte 0x4
- .set L$set$234,LCFI135-LFB62
- .long L$set$234
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$235,LCFI136-LCFI135
- .long L$set$235
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE92:
-LSFDE94:
- .set L$set$236,LEFDE94-LASFDE94
- .long L$set$236
-LASFDE94:
- .set L$set$237,Lframe0-Lsection__debug_frame
- .long L$set$237
- .quad LFB63
- .set L$set$238,LFE63-LFB63
- .quad L$set$238
- .byte 0x4
- .set L$set$239,LCFI138-LFB63
- .long L$set$239
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$240,LCFI139-LCFI138
- .long L$set$240
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE94:
- .section __TEXT,__eh_frame,coalesced,no_toc+strip_static_syms+live_support
-EH_frame1:
- .set L$set$241,LECIE1-LSCIE1
- .long L$set$241
-LSCIE1:
- .long 0x0
- .byte 0x1
- .ascii "zR\0"
- .byte 0x1
- .byte 0x78
- .byte 0x10
- .byte 0x1
- .byte 0x10
- .byte 0xc
- .byte 0x7
- .byte 0x8
- .byte 0x90
- .byte 0x1
- .align 3
-LECIE1:
-.globl _Gasketrmdir.eh
-_Gasketrmdir.eh:
-LSFDE1:
- .set L$set$242,LEFDE1-LASFDE1
- .long L$set$242
-LASFDE1:
- .long LASFDE1-EH_frame1
- .quad LFB16-.
- .set L$set$243,LFE16-LFB16
- .quad L$set$243
- .byte 0x0
- .byte 0x4
- .set L$set$244,LCFI0-LFB16
- .long L$set$244
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$245,LCFI1-LCFI0
- .long L$set$245
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE1:
-.globl _Gasketopendir.eh
-_Gasketopendir.eh:
-LSFDE3:
- .set L$set$246,LEFDE3-LASFDE3
- .long L$set$246
-LASFDE3:
- .long LASFDE3-EH_frame1
- .quad LFB17-.
- .set L$set$247,LFE17-LFB17
- .quad L$set$247
- .byte 0x0
- .byte 0x4
- .set L$set$248,LCFI3-LFB17
- .long L$set$248
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$249,LCFI4-LCFI3
- .long L$set$249
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE3:
-.globl _Gasketstat.eh
-_Gasketstat.eh:
-LSFDE5:
- .set L$set$250,LEFDE5-LASFDE5
- .long L$set$250
-LASFDE5:
- .long LASFDE5-EH_frame1
- .quad LFB18-.
- .set L$set$251,LFE18-LFB18
- .quad L$set$251
- .byte 0x0
- .byte 0x4
- .set L$set$252,LCFI6-LFB18
- .long L$set$252
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$253,LCFI7-LCFI6
- .long L$set$253
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE5:
-.globl _Gasketstatfs.eh
-_Gasketstatfs.eh:
-LSFDE7:
- .set L$set$254,LEFDE7-LASFDE7
- .long L$set$254
-LASFDE7:
- .long LASFDE7-EH_frame1
- .quad LFB19-.
- .set L$set$255,LFE19-LFB19
- .quad L$set$255
- .byte 0x0
- .byte 0x4
- .set L$set$256,LCFI9-LFB19
- .long L$set$256
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$257,LCFI10-LCFI9
- .long L$set$257
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE7:
-.globl _GasketmsSleep.eh
-_GasketmsSleep.eh:
-LSFDE9:
- .set L$set$258,LEFDE9-LASFDE9
- .long L$set$258
-LASFDE9:
- .long LASFDE9-EH_frame1
- .quad LFB20-.
- .set L$set$259,LFE20-LFB20
- .quad L$set$259
- .byte 0x0
- .byte 0x4
- .set L$set$260,LCFI12-LFB20
- .long L$set$260
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$261,LCFI13-LCFI12
- .long L$set$261
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE9:
-.globl _Gasketexit.eh
-_Gasketexit.eh:
-LSFDE11:
- .set L$set$262,LEFDE11-LASFDE11
- .long L$set$262
-LASFDE11:
- .long LASFDE11-EH_frame1
- .quad LFB21-.
- .set L$set$263,LFE21-LFB21
- .quad L$set$263
- .byte 0x0
- .byte 0x4
- .set L$set$264,LCFI15-LFB21
- .long L$set$264
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$265,LCFI16-LCFI15
- .long L$set$265
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE11:
-.globl _GasketSetTimer.eh
-_GasketSetTimer.eh:
-LSFDE13:
- .set L$set$266,LEFDE13-LASFDE13
- .long L$set$266
-LASFDE13:
- .long LASFDE13-EH_frame1
- .quad LFB22-.
- .set L$set$267,LFE22-LFB22
- .quad L$set$267
- .byte 0x0
- .byte 0x4
- .set L$set$268,LCFI18-LFB22
- .long L$set$268
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$269,LCFI19-LCFI18
- .long L$set$269
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE13:
-.globl _GasketGetLocalTime.eh
-_GasketGetLocalTime.eh:
-LSFDE15:
- .set L$set$270,LEFDE15-LASFDE15
- .long L$set$270
-LASFDE15:
- .long LASFDE15-EH_frame1
- .quad LFB23-.
- .set L$set$271,LFE23-LFB23
- .quad L$set$271
- .byte 0x0
- .byte 0x4
- .set L$set$272,LCFI21-LFB23
- .long L$set$272
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$273,LCFI22-LCFI21
- .long L$set$273
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE15:
-.globl _Gasketgmtime.eh
-_Gasketgmtime.eh:
-LSFDE17:
- .set L$set$274,LEFDE17-LASFDE17
- .long L$set$274
-LASFDE17:
- .long LASFDE17-EH_frame1
- .quad LFB24-.
- .set L$set$275,LFE24-LFB24
- .quad L$set$275
- .byte 0x0
- .byte 0x4
- .set L$set$276,LCFI24-LFB24
- .long L$set$276
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$277,LCFI25-LCFI24
- .long L$set$277
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE17:
-.globl _GasketGetTimeZone.eh
-_GasketGetTimeZone.eh:
-LSFDE19:
- .set L$set$278,LEFDE19-LASFDE19
- .long L$set$278
-LASFDE19:
- .long LASFDE19-EH_frame1
- .quad LFB25-.
- .set L$set$279,LFE25-LFB25
- .quad L$set$279
- .byte 0x0
- .byte 0x4
- .set L$set$280,LCFI27-LFB25
- .long L$set$280
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$281,LCFI28-LCFI27
- .long L$set$281
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE19:
-.globl _GasketGetDayLight.eh
-_GasketGetDayLight.eh:
-LSFDE21:
- .set L$set$282,LEFDE21-LASFDE21
- .long L$set$282
-LASFDE21:
- .long LASFDE21-EH_frame1
- .quad LFB26-.
- .set L$set$283,LFE26-LFB26
- .quad L$set$283
- .byte 0x0
- .byte 0x4
- .set L$set$284,LCFI29-LFB26
- .long L$set$284
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$285,LCFI30-LCFI29
- .long L$set$285
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE21:
-.globl _Gasketpoll.eh
-_Gasketpoll.eh:
-LSFDE23:
- .set L$set$286,LEFDE23-LASFDE23
- .long L$set$286
-LASFDE23:
- .long LASFDE23-EH_frame1
- .quad LFB27-.
- .set L$set$287,LFE27-LFB27
- .quad L$set$287
- .byte 0x0
- .byte 0x4
- .set L$set$288,LCFI31-LFB27
- .long L$set$288
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$289,LCFI32-LCFI31
- .long L$set$289
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE23:
-.globl _Gasketread.eh
-_Gasketread.eh:
-LSFDE25:
- .set L$set$290,LEFDE25-LASFDE25
- .long L$set$290
-LASFDE25:
- .long LASFDE25-EH_frame1
- .quad LFB28-.
- .set L$set$291,LFE28-LFB28
- .quad L$set$291
- .byte 0x0
- .byte 0x4
- .set L$set$292,LCFI34-LFB28
- .long L$set$292
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$293,LCFI35-LCFI34
- .long L$set$293
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE25:
-.globl _Gasketwrite.eh
-_Gasketwrite.eh:
-LSFDE27:
- .set L$set$294,LEFDE27-LASFDE27
- .long L$set$294
-LASFDE27:
- .long LASFDE27-EH_frame1
- .quad LFB29-.
- .set L$set$295,LFE29-LFB29
- .quad L$set$295
- .byte 0x0
- .byte 0x4
- .set L$set$296,LCFI37-LFB29
- .long L$set$296
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$297,LCFI38-LCFI37
- .long L$set$297
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE27:
-.globl _Gasketgetenv.eh
-_Gasketgetenv.eh:
-LSFDE29:
- .set L$set$298,LEFDE29-LASFDE29
- .long L$set$298
-LASFDE29:
- .long LASFDE29-EH_frame1
- .quad LFB30-.
- .set L$set$299,LFE30-LFB30
- .quad L$set$299
- .byte 0x0
- .byte 0x4
- .set L$set$300,LCFI40-LFB30
- .long L$set$300
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$301,LCFI41-LCFI40
- .long L$set$301
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE29:
-.globl _Gasketopen.eh
-_Gasketopen.eh:
-LSFDE31:
- .set L$set$302,LEFDE31-LASFDE31
- .long L$set$302
-LASFDE31:
- .long LASFDE31-EH_frame1
- .quad LFB31-.
- .set L$set$303,LFE31-LFB31
- .quad L$set$303
- .byte 0x0
- .byte 0x4
- .set L$set$304,LCFI43-LFB31
- .long L$set$304
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$305,LCFI44-LCFI43
- .long L$set$305
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE31:
-.globl _Gasketlseek.eh
-_Gasketlseek.eh:
-LSFDE33:
- .set L$set$306,LEFDE33-LASFDE33
- .long L$set$306
-LASFDE33:
- .long LASFDE33-EH_frame1
- .quad LFB32-.
- .set L$set$307,LFE32-LFB32
- .quad L$set$307
- .byte 0x0
- .byte 0x4
- .set L$set$308,LCFI46-LFB32
- .long L$set$308
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$309,LCFI47-LCFI46
- .long L$set$309
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE33:
-.globl _Gasketftruncate.eh
-_Gasketftruncate.eh:
-LSFDE35:
- .set L$set$310,LEFDE35-LASFDE35
- .long L$set$310
-LASFDE35:
- .long LASFDE35-EH_frame1
- .quad LFB33-.
- .set L$set$311,LFE33-LFB33
- .quad L$set$311
- .byte 0x0
- .byte 0x4
- .set L$set$312,LCFI49-LFB33
- .long L$set$312
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$313,LCFI50-LCFI49
- .long L$set$313
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE35:
-.globl _Gasketclose.eh
-_Gasketclose.eh:
-LSFDE37:
- .set L$set$314,LEFDE37-LASFDE37
- .long L$set$314
-LASFDE37:
- .long LASFDE37-EH_frame1
- .quad LFB34-.
- .set L$set$315,LFE34-LFB34
- .quad L$set$315
- .byte 0x0
- .byte 0x4
- .set L$set$316,LCFI52-LFB34
- .long L$set$316
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$317,LCFI53-LCFI52
- .long L$set$317
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE37:
-.globl _Gasketmkdir.eh
-_Gasketmkdir.eh:
-LSFDE39:
- .set L$set$318,LEFDE39-LASFDE39
- .long L$set$318
-LASFDE39:
- .long LASFDE39-EH_frame1
- .quad LFB35-.
- .set L$set$319,LFE35-LFB35
- .quad L$set$319
- .byte 0x0
- .byte 0x4
- .set L$set$320,LCFI55-LFB35
- .long L$set$320
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$321,LCFI56-LCFI55
- .long L$set$321
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE39:
-.globl _Gasketunlink.eh
-_Gasketunlink.eh:
-LSFDE41:
- .set L$set$322,LEFDE41-LASFDE41
- .long L$set$322
-LASFDE41:
- .long LASFDE41-EH_frame1
- .quad LFB36-.
- .set L$set$323,LFE36-LFB36
- .quad L$set$323
- .byte 0x0
- .byte 0x4
- .set L$set$324,LCFI58-LFB36
- .long L$set$324
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$325,LCFI59-LCFI58
- .long L$set$325
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE41:
-.globl _GasketGetErrno.eh
-_GasketGetErrno.eh:
-LSFDE43:
- .set L$set$326,LEFDE43-LASFDE43
- .long L$set$326
-LASFDE43:
- .long LASFDE43-EH_frame1
- .quad LFB37-.
- .set L$set$327,LFE37-LFB37
- .quad L$set$327
- .byte 0x0
- .byte 0x4
- .set L$set$328,LCFI61-LFB37
- .long L$set$328
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$329,LCFI62-LCFI61
- .long L$set$329
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE43:
-.globl _Gasketrewinddir.eh
-_Gasketrewinddir.eh:
-LSFDE45:
- .set L$set$330,LEFDE45-LASFDE45
- .long L$set$330
-LASFDE45:
- .long LASFDE45-EH_frame1
- .quad LFB38-.
- .set L$set$331,LFE38-LFB38
- .quad L$set$331
- .byte 0x0
- .byte 0x4
- .set L$set$332,LCFI63-LFB38
- .long L$set$332
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$333,LCFI64-LCFI63
- .long L$set$333
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE45:
-.globl _Gasketreaddir.eh
-_Gasketreaddir.eh:
-LSFDE47:
- .set L$set$334,LEFDE47-LASFDE47
- .long L$set$334
-LASFDE47:
- .long LASFDE47-EH_frame1
- .quad LFB39-.
- .set L$set$335,LFE39-LFB39
- .quad L$set$335
- .byte 0x0
- .byte 0x4
- .set L$set$336,LCFI66-LFB39
- .long L$set$336
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$337,LCFI67-LCFI66
- .long L$set$337
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE47:
-.globl _Gasketclosedir.eh
-_Gasketclosedir.eh:
-LSFDE49:
- .set L$set$338,LEFDE49-LASFDE49
- .long L$set$338
-LASFDE49:
- .long LASFDE49-EH_frame1
- .quad LFB40-.
- .set L$set$339,LFE40-LFB40
- .quad L$set$339
- .byte 0x0
- .byte 0x4
- .set L$set$340,LCFI69-LFB40
- .long L$set$340
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$341,LCFI70-LCFI69
- .long L$set$341
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE49:
-.globl _Gasketrename.eh
-_Gasketrename.eh:
-LSFDE51:
- .set L$set$342,LEFDE51-LASFDE51
- .long L$set$342
-LASFDE51:
- .long LASFDE51-EH_frame1
- .quad LFB41-.
- .set L$set$343,LFE41-LFB41
- .quad L$set$343
- .byte 0x0
- .byte 0x4
- .set L$set$344,LCFI72-LFB41
- .long L$set$344
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$345,LCFI73-LCFI72
- .long L$set$345
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE51:
-.globl _Gasketmktime.eh
-_Gasketmktime.eh:
-LSFDE53:
- .set L$set$346,LEFDE53-LASFDE53
- .long L$set$346
-LASFDE53:
- .long LASFDE53-EH_frame1
- .quad LFB42-.
- .set L$set$347,LFE42-LFB42
- .quad L$set$347
- .byte 0x0
- .byte 0x4
- .set L$set$348,LCFI75-LFB42
- .long L$set$348
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$349,LCFI76-LCFI75
- .long L$set$349
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE53:
-.globl _Gasketfsync.eh
-_Gasketfsync.eh:
-LSFDE55:
- .set L$set$350,LEFDE55-LASFDE55
- .long L$set$350
-LASFDE55:
- .long LASFDE55-EH_frame1
- .quad LFB43-.
- .set L$set$351,LFE43-LFB43
- .quad L$set$351
- .byte 0x0
- .byte 0x4
- .set L$set$352,LCFI78-LFB43
- .long L$set$352
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$353,LCFI79-LCFI78
- .long L$set$353
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE55:
-.globl _Gasketchmod.eh
-_Gasketchmod.eh:
-LSFDE57:
- .set L$set$354,LEFDE57-LASFDE57
- .long L$set$354
-LASFDE57:
- .long LASFDE57-EH_frame1
- .quad LFB44-.
- .set L$set$355,LFE44-LFB44
- .quad L$set$355
- .byte 0x0
- .byte 0x4
- .set L$set$356,LCFI81-LFB44
- .long L$set$356
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$357,LCFI82-LCFI81
- .long L$set$357
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE57:
-.globl _Gasketutime.eh
-_Gasketutime.eh:
-LSFDE59:
- .set L$set$358,LEFDE59-LASFDE59
- .long L$set$358
-LASFDE59:
- .long LASFDE59-EH_frame1
- .quad LFB45-.
- .set L$set$359,LFE45-LFB45
- .quad L$set$359
- .byte 0x0
- .byte 0x4
- .set L$set$360,LCFI84-LFB45
- .long L$set$360
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$361,LCFI85-LCFI84
- .long L$set$361
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE59:
-.globl _Gaskettcflush.eh
-_Gaskettcflush.eh:
-LSFDE61:
- .set L$set$362,LEFDE61-LASFDE61
- .long L$set$362
-LASFDE61:
- .long LASFDE61-EH_frame1
- .quad LFB46-.
- .set L$set$363,LFE46-LFB46
- .quad L$set$363
- .byte 0x0
- .byte 0x4
- .set L$set$364,LCFI87-LFB46
- .long L$set$364
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$365,LCFI88-LCFI87
- .long L$set$365
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE61:
-.globl _GasketUgaCreate.eh
-_GasketUgaCreate.eh:
-LSFDE63:
- .set L$set$366,LEFDE63-LASFDE63
- .long L$set$366
-LASFDE63:
- .long LASFDE63-EH_frame1
- .quad LFB47-.
- .set L$set$367,LFE47-LFB47
- .quad L$set$367
- .byte 0x0
- .byte 0x4
- .set L$set$368,LCFI90-LFB47
- .long L$set$368
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$369,LCFI91-LCFI90
- .long L$set$369
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE63:
-.globl _Gasketperror.eh
-_Gasketperror.eh:
-LSFDE65:
- .set L$set$370,LEFDE65-LASFDE65
- .long L$set$370
-LASFDE65:
- .long LASFDE65-EH_frame1
- .quad LFB48-.
- .set L$set$371,LFE48-LFB48
- .quad L$set$371
- .byte 0x0
- .byte 0x4
- .set L$set$372,LCFI93-LFB48
- .long L$set$372
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$373,LCFI94-LCFI93
- .long L$set$373
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE65:
-.globl _Gasketioctl.eh
-_Gasketioctl.eh:
-LSFDE67:
- .set L$set$374,LEFDE67-LASFDE67
- .long L$set$374
-LASFDE67:
- .long LASFDE67-EH_frame1
- .quad LFB49-.
- .set L$set$375,LFE49-LFB49
- .quad L$set$375
- .byte 0x0
- .byte 0x4
- .set L$set$376,LCFI96-LFB49
- .long L$set$376
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$377,LCFI97-LCFI96
- .long L$set$377
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE67:
-.globl _Gasketfcntl.eh
-_Gasketfcntl.eh:
-LSFDE69:
- .set L$set$378,LEFDE69-LASFDE69
- .long L$set$378
-LASFDE69:
- .long LASFDE69-EH_frame1
- .quad LFB50-.
- .set L$set$379,LFE50-LFB50
- .quad L$set$379
- .byte 0x0
- .byte 0x4
- .set L$set$380,LCFI99-LFB50
- .long L$set$380
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$381,LCFI100-LCFI99
- .long L$set$381
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE69:
-.globl _Gasketcfsetispeed.eh
-_Gasketcfsetispeed.eh:
-LSFDE71:
- .set L$set$382,LEFDE71-LASFDE71
- .long L$set$382
-LASFDE71:
- .long LASFDE71-EH_frame1
- .quad LFB51-.
- .set L$set$383,LFE51-LFB51
- .quad L$set$383
- .byte 0x0
- .byte 0x4
- .set L$set$384,LCFI102-LFB51
- .long L$set$384
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$385,LCFI103-LCFI102
- .long L$set$385
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE71:
-.globl _Gasketcfsetospeed.eh
-_Gasketcfsetospeed.eh:
-LSFDE73:
- .set L$set$386,LEFDE73-LASFDE73
- .long L$set$386
-LASFDE73:
- .long LASFDE73-EH_frame1
- .quad LFB52-.
- .set L$set$387,LFE52-LFB52
- .quad L$set$387
- .byte 0x0
- .byte 0x4
- .set L$set$388,LCFI105-LFB52
- .long L$set$388
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$389,LCFI106-LCFI105
- .long L$set$389
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE73:
-.globl _Gaskettcgetattr.eh
-_Gaskettcgetattr.eh:
-LSFDE75:
- .set L$set$390,LEFDE75-LASFDE75
- .long L$set$390
-LASFDE75:
- .long LASFDE75-EH_frame1
- .quad LFB53-.
- .set L$set$391,LFE53-LFB53
- .quad L$set$391
- .byte 0x0
- .byte 0x4
- .set L$set$392,LCFI108-LFB53
- .long L$set$392
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$393,LCFI109-LCFI108
- .long L$set$393
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE75:
-.globl _Gaskettcsetattr.eh
-_Gaskettcsetattr.eh:
-LSFDE77:
- .set L$set$394,LEFDE77-LASFDE77
- .long L$set$394
-LASFDE77:
- .long LASFDE77-EH_frame1
- .quad LFB54-.
- .set L$set$395,LFE54-LFB54
- .quad L$set$395
- .byte 0x0
- .byte 0x4
- .set L$set$396,LCFI111-LFB54
- .long L$set$396
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$397,LCFI112-LCFI111
- .long L$set$397
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE77:
-.globl _GasketUnixPeCoffGetEntryPoint.eh
-_GasketUnixPeCoffGetEntryPoint.eh:
-LSFDE79:
- .set L$set$398,LEFDE79-LASFDE79
- .long L$set$398
-LASFDE79:
- .long LASFDE79-EH_frame1
- .quad LFB55-.
- .set L$set$399,LFE55-LFB55
- .quad L$set$399
- .byte 0x0
- .byte 0x4
- .set L$set$400,LCFI114-LFB55
- .long L$set$400
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$401,LCFI115-LCFI114
- .long L$set$401
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE79:
-.globl _GasketUnixPeCoffRelocateImageExtraAction.eh
-_GasketUnixPeCoffRelocateImageExtraAction.eh:
-LSFDE81:
- .set L$set$402,LEFDE81-LASFDE81
- .long L$set$402
-LASFDE81:
- .long LASFDE81-EH_frame1
- .quad LFB56-.
- .set L$set$403,LFE56-LFB56
- .quad L$set$403
- .byte 0x0
- .byte 0x4
- .set L$set$404,LCFI117-LFB56
- .long L$set$404
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$405,LCFI118-LCFI117
- .long L$set$405
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE81:
-.globl _GasketUnixPeCoffUnloadImageExtraAction.eh
-_GasketUnixPeCoffUnloadImageExtraAction.eh:
-LSFDE83:
- .set L$set$406,LEFDE83-LASFDE83
- .long L$set$406
-LASFDE83:
- .long LASFDE83-EH_frame1
- .quad LFB57-.
- .set L$set$407,LFE57-LFB57
- .quad L$set$407
- .byte 0x0
- .byte 0x4
- .set L$set$408,LCFI120-LFB57
- .long L$set$408
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$409,LCFI121-LCFI120
- .long L$set$409
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE83:
-.globl _GasketUgaClose.eh
-_GasketUgaClose.eh:
-LSFDE85:
- .set L$set$410,LEFDE85-LASFDE85
- .long L$set$410
-LASFDE85:
- .long LASFDE85-EH_frame1
- .quad LFB58-.
- .set L$set$411,LFE58-LFB58
- .quad L$set$411
- .byte 0x0
- .byte 0x4
- .set L$set$412,LCFI123-LFB58
- .long L$set$412
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$413,LCFI124-LCFI123
- .long L$set$413
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE85:
-.globl _GasketUgaSize.eh
-_GasketUgaSize.eh:
-LSFDE87:
- .set L$set$414,LEFDE87-LASFDE87
- .long L$set$414
-LASFDE87:
- .long LASFDE87-EH_frame1
- .quad LFB59-.
- .set L$set$415,LFE59-LFB59
- .quad L$set$415
- .byte 0x0
- .byte 0x4
- .set L$set$416,LCFI126-LFB59
- .long L$set$416
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$417,LCFI127-LCFI126
- .long L$set$417
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE87:
-.globl _GasketUgaCheckKey.eh
-_GasketUgaCheckKey.eh:
-LSFDE89:
- .set L$set$418,LEFDE89-LASFDE89
- .long L$set$418
-LASFDE89:
- .long LASFDE89-EH_frame1
- .quad LFB60-.
- .set L$set$419,LFE60-LFB60
- .quad L$set$419
- .byte 0x0
- .byte 0x4
- .set L$set$420,LCFI129-LFB60
- .long L$set$420
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$421,LCFI130-LCFI129
- .long L$set$421
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE89:
-.globl _GasketUgaGetKey.eh
-_GasketUgaGetKey.eh:
-LSFDE91:
- .set L$set$422,LEFDE91-LASFDE91
- .long L$set$422
-LASFDE91:
- .long LASFDE91-EH_frame1
- .quad LFB61-.
- .set L$set$423,LFE61-LFB61
- .quad L$set$423
- .byte 0x0
- .byte 0x4
- .set L$set$424,LCFI132-LFB61
- .long L$set$424
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$425,LCFI133-LCFI132
- .long L$set$425
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE91:
-.globl _GasketUgaBlt.eh
-_GasketUgaBlt.eh:
-LSFDE93:
- .set L$set$426,LEFDE93-LASFDE93
- .long L$set$426
-LASFDE93:
- .long LASFDE93-EH_frame1
- .quad LFB62-.
- .set L$set$427,LFE62-LFB62
- .quad L$set$427
- .byte 0x0
- .byte 0x4
- .set L$set$428,LCFI135-LFB62
- .long L$set$428
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$429,LCFI136-LCFI135
- .long L$set$429
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE93:
-.globl _ReverseGasketUint64.eh
-_ReverseGasketUint64.eh:
-LSFDE95:
- .set L$set$430,LEFDE95-LASFDE95
- .long L$set$430
-LASFDE95:
- .long LASFDE95-EH_frame1
- .quad LFB63-.
- .set L$set$431,LFE63-LFB63
- .quad L$set$431
- .byte 0x0
- .byte 0x4
- .set L$set$432,LCFI138-LFB63
- .long L$set$432
- .byte 0xe
- .byte 0x10
- .byte 0x86
- .byte 0x2
- .byte 0x4
- .set L$set$433,LCFI139-LCFI138
- .long L$set$433
- .byte 0xd
- .byte 0x6
- .align 3
-LEFDE95:
- .text
-Letext0:
- .section __DWARF,__debug_loc,regular,debug
-Ldebug_loc0:
-LLST0:
- .set L$set$434,LFB16-Ltext0
- .quad L$set$434
- .set L$set$435,LCFI0-Ltext0
- .quad L$set$435
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$436,LCFI0-Ltext0
- .quad L$set$436
- .set L$set$437,LCFI1-Ltext0
- .quad L$set$437
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$438,LCFI1-Ltext0
- .quad L$set$438
- .set L$set$439,LFE16-Ltext0
- .quad L$set$439
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST1:
- .set L$set$440,LFB17-Ltext0
- .quad L$set$440
- .set L$set$441,LCFI3-Ltext0
- .quad L$set$441
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$442,LCFI3-Ltext0
- .quad L$set$442
- .set L$set$443,LCFI4-Ltext0
- .quad L$set$443
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$444,LCFI4-Ltext0
- .quad L$set$444
- .set L$set$445,LFE17-Ltext0
- .quad L$set$445
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST2:
- .set L$set$446,LFB18-Ltext0
- .quad L$set$446
- .set L$set$447,LCFI6-Ltext0
- .quad L$set$447
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$448,LCFI6-Ltext0
- .quad L$set$448
- .set L$set$449,LCFI7-Ltext0
- .quad L$set$449
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$450,LCFI7-Ltext0
- .quad L$set$450
- .set L$set$451,LFE18-Ltext0
- .quad L$set$451
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST3:
- .set L$set$452,LFB19-Ltext0
- .quad L$set$452
- .set L$set$453,LCFI9-Ltext0
- .quad L$set$453
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$454,LCFI9-Ltext0
- .quad L$set$454
- .set L$set$455,LCFI10-Ltext0
- .quad L$set$455
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$456,LCFI10-Ltext0
- .quad L$set$456
- .set L$set$457,LFE19-Ltext0
- .quad L$set$457
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST4:
- .set L$set$458,LFB20-Ltext0
- .quad L$set$458
- .set L$set$459,LCFI12-Ltext0
- .quad L$set$459
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$460,LCFI12-Ltext0
- .quad L$set$460
- .set L$set$461,LCFI13-Ltext0
- .quad L$set$461
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$462,LCFI13-Ltext0
- .quad L$set$462
- .set L$set$463,LFE20-Ltext0
- .quad L$set$463
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST5:
- .set L$set$464,LFB21-Ltext0
- .quad L$set$464
- .set L$set$465,LCFI15-Ltext0
- .quad L$set$465
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$466,LCFI15-Ltext0
- .quad L$set$466
- .set L$set$467,LCFI16-Ltext0
- .quad L$set$467
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$468,LCFI16-Ltext0
- .quad L$set$468
- .set L$set$469,LFE21-Ltext0
- .quad L$set$469
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST6:
- .set L$set$470,LFB22-Ltext0
- .quad L$set$470
- .set L$set$471,LCFI18-Ltext0
- .quad L$set$471
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$472,LCFI18-Ltext0
- .quad L$set$472
- .set L$set$473,LCFI19-Ltext0
- .quad L$set$473
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$474,LCFI19-Ltext0
- .quad L$set$474
- .set L$set$475,LFE22-Ltext0
- .quad L$set$475
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST7:
- .set L$set$476,LFB23-Ltext0
- .quad L$set$476
- .set L$set$477,LCFI21-Ltext0
- .quad L$set$477
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$478,LCFI21-Ltext0
- .quad L$set$478
- .set L$set$479,LCFI22-Ltext0
- .quad L$set$479
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$480,LCFI22-Ltext0
- .quad L$set$480
- .set L$set$481,LFE23-Ltext0
- .quad L$set$481
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST8:
- .set L$set$482,LFB24-Ltext0
- .quad L$set$482
- .set L$set$483,LCFI24-Ltext0
- .quad L$set$483
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$484,LCFI24-Ltext0
- .quad L$set$484
- .set L$set$485,LCFI25-Ltext0
- .quad L$set$485
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$486,LCFI25-Ltext0
- .quad L$set$486
- .set L$set$487,LFE24-Ltext0
- .quad L$set$487
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST9:
- .set L$set$488,LFB25-Ltext0
- .quad L$set$488
- .set L$set$489,LCFI27-Ltext0
- .quad L$set$489
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$490,LCFI27-Ltext0
- .quad L$set$490
- .set L$set$491,LCFI28-Ltext0
- .quad L$set$491
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$492,LCFI28-Ltext0
- .quad L$set$492
- .set L$set$493,LFE25-Ltext0
- .quad L$set$493
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST10:
- .set L$set$494,LFB26-Ltext0
- .quad L$set$494
- .set L$set$495,LCFI29-Ltext0
- .quad L$set$495
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$496,LCFI29-Ltext0
- .quad L$set$496
- .set L$set$497,LCFI30-Ltext0
- .quad L$set$497
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$498,LCFI30-Ltext0
- .quad L$set$498
- .set L$set$499,LFE26-Ltext0
- .quad L$set$499
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST11:
- .set L$set$500,LFB27-Ltext0
- .quad L$set$500
- .set L$set$501,LCFI31-Ltext0
- .quad L$set$501
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$502,LCFI31-Ltext0
- .quad L$set$502
- .set L$set$503,LCFI32-Ltext0
- .quad L$set$503
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$504,LCFI32-Ltext0
- .quad L$set$504
- .set L$set$505,LFE27-Ltext0
- .quad L$set$505
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST12:
- .set L$set$506,LFB28-Ltext0
- .quad L$set$506
- .set L$set$507,LCFI34-Ltext0
- .quad L$set$507
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$508,LCFI34-Ltext0
- .quad L$set$508
- .set L$set$509,LCFI35-Ltext0
- .quad L$set$509
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$510,LCFI35-Ltext0
- .quad L$set$510
- .set L$set$511,LFE28-Ltext0
- .quad L$set$511
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST13:
- .set L$set$512,LFB29-Ltext0
- .quad L$set$512
- .set L$set$513,LCFI37-Ltext0
- .quad L$set$513
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$514,LCFI37-Ltext0
- .quad L$set$514
- .set L$set$515,LCFI38-Ltext0
- .quad L$set$515
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$516,LCFI38-Ltext0
- .quad L$set$516
- .set L$set$517,LFE29-Ltext0
- .quad L$set$517
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST14:
- .set L$set$518,LFB30-Ltext0
- .quad L$set$518
- .set L$set$519,LCFI40-Ltext0
- .quad L$set$519
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$520,LCFI40-Ltext0
- .quad L$set$520
- .set L$set$521,LCFI41-Ltext0
- .quad L$set$521
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$522,LCFI41-Ltext0
- .quad L$set$522
- .set L$set$523,LFE30-Ltext0
- .quad L$set$523
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST15:
- .set L$set$524,LFB31-Ltext0
- .quad L$set$524
- .set L$set$525,LCFI43-Ltext0
- .quad L$set$525
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$526,LCFI43-Ltext0
- .quad L$set$526
- .set L$set$527,LCFI44-Ltext0
- .quad L$set$527
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$528,LCFI44-Ltext0
- .quad L$set$528
- .set L$set$529,LFE31-Ltext0
- .quad L$set$529
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST16:
- .set L$set$530,LFB32-Ltext0
- .quad L$set$530
- .set L$set$531,LCFI46-Ltext0
- .quad L$set$531
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$532,LCFI46-Ltext0
- .quad L$set$532
- .set L$set$533,LCFI47-Ltext0
- .quad L$set$533
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$534,LCFI47-Ltext0
- .quad L$set$534
- .set L$set$535,LFE32-Ltext0
- .quad L$set$535
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST17:
- .set L$set$536,LFB33-Ltext0
- .quad L$set$536
- .set L$set$537,LCFI49-Ltext0
- .quad L$set$537
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$538,LCFI49-Ltext0
- .quad L$set$538
- .set L$set$539,LCFI50-Ltext0
- .quad L$set$539
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$540,LCFI50-Ltext0
- .quad L$set$540
- .set L$set$541,LFE33-Ltext0
- .quad L$set$541
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST18:
- .set L$set$542,LFB34-Ltext0
- .quad L$set$542
- .set L$set$543,LCFI52-Ltext0
- .quad L$set$543
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$544,LCFI52-Ltext0
- .quad L$set$544
- .set L$set$545,LCFI53-Ltext0
- .quad L$set$545
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$546,LCFI53-Ltext0
- .quad L$set$546
- .set L$set$547,LFE34-Ltext0
- .quad L$set$547
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST19:
- .set L$set$548,LFB35-Ltext0
- .quad L$set$548
- .set L$set$549,LCFI55-Ltext0
- .quad L$set$549
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$550,LCFI55-Ltext0
- .quad L$set$550
- .set L$set$551,LCFI56-Ltext0
- .quad L$set$551
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$552,LCFI56-Ltext0
- .quad L$set$552
- .set L$set$553,LFE35-Ltext0
- .quad L$set$553
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST20:
- .set L$set$554,LFB36-Ltext0
- .quad L$set$554
- .set L$set$555,LCFI58-Ltext0
- .quad L$set$555
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$556,LCFI58-Ltext0
- .quad L$set$556
- .set L$set$557,LCFI59-Ltext0
- .quad L$set$557
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$558,LCFI59-Ltext0
- .quad L$set$558
- .set L$set$559,LFE36-Ltext0
- .quad L$set$559
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST21:
- .set L$set$560,LFB37-Ltext0
- .quad L$set$560
- .set L$set$561,LCFI61-Ltext0
- .quad L$set$561
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$562,LCFI61-Ltext0
- .quad L$set$562
- .set L$set$563,LCFI62-Ltext0
- .quad L$set$563
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$564,LCFI62-Ltext0
- .quad L$set$564
- .set L$set$565,LFE37-Ltext0
- .quad L$set$565
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST22:
- .set L$set$566,LFB38-Ltext0
- .quad L$set$566
- .set L$set$567,LCFI63-Ltext0
- .quad L$set$567
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$568,LCFI63-Ltext0
- .quad L$set$568
- .set L$set$569,LCFI64-Ltext0
- .quad L$set$569
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$570,LCFI64-Ltext0
- .quad L$set$570
- .set L$set$571,LFE38-Ltext0
- .quad L$set$571
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST23:
- .set L$set$572,LFB39-Ltext0
- .quad L$set$572
- .set L$set$573,LCFI66-Ltext0
- .quad L$set$573
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$574,LCFI66-Ltext0
- .quad L$set$574
- .set L$set$575,LCFI67-Ltext0
- .quad L$set$575
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$576,LCFI67-Ltext0
- .quad L$set$576
- .set L$set$577,LFE39-Ltext0
- .quad L$set$577
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST24:
- .set L$set$578,LFB40-Ltext0
- .quad L$set$578
- .set L$set$579,LCFI69-Ltext0
- .quad L$set$579
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$580,LCFI69-Ltext0
- .quad L$set$580
- .set L$set$581,LCFI70-Ltext0
- .quad L$set$581
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$582,LCFI70-Ltext0
- .quad L$set$582
- .set L$set$583,LFE40-Ltext0
- .quad L$set$583
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST25:
- .set L$set$584,LFB41-Ltext0
- .quad L$set$584
- .set L$set$585,LCFI72-Ltext0
- .quad L$set$585
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$586,LCFI72-Ltext0
- .quad L$set$586
- .set L$set$587,LCFI73-Ltext0
- .quad L$set$587
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$588,LCFI73-Ltext0
- .quad L$set$588
- .set L$set$589,LFE41-Ltext0
- .quad L$set$589
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST26:
- .set L$set$590,LFB42-Ltext0
- .quad L$set$590
- .set L$set$591,LCFI75-Ltext0
- .quad L$set$591
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$592,LCFI75-Ltext0
- .quad L$set$592
- .set L$set$593,LCFI76-Ltext0
- .quad L$set$593
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$594,LCFI76-Ltext0
- .quad L$set$594
- .set L$set$595,LFE42-Ltext0
- .quad L$set$595
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST27:
- .set L$set$596,LFB43-Ltext0
- .quad L$set$596
- .set L$set$597,LCFI78-Ltext0
- .quad L$set$597
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$598,LCFI78-Ltext0
- .quad L$set$598
- .set L$set$599,LCFI79-Ltext0
- .quad L$set$599
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$600,LCFI79-Ltext0
- .quad L$set$600
- .set L$set$601,LFE43-Ltext0
- .quad L$set$601
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST28:
- .set L$set$602,LFB44-Ltext0
- .quad L$set$602
- .set L$set$603,LCFI81-Ltext0
- .quad L$set$603
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$604,LCFI81-Ltext0
- .quad L$set$604
- .set L$set$605,LCFI82-Ltext0
- .quad L$set$605
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$606,LCFI82-Ltext0
- .quad L$set$606
- .set L$set$607,LFE44-Ltext0
- .quad L$set$607
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST29:
- .set L$set$608,LFB45-Ltext0
- .quad L$set$608
- .set L$set$609,LCFI84-Ltext0
- .quad L$set$609
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$610,LCFI84-Ltext0
- .quad L$set$610
- .set L$set$611,LCFI85-Ltext0
- .quad L$set$611
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$612,LCFI85-Ltext0
- .quad L$set$612
- .set L$set$613,LFE45-Ltext0
- .quad L$set$613
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST30:
- .set L$set$614,LFB46-Ltext0
- .quad L$set$614
- .set L$set$615,LCFI87-Ltext0
- .quad L$set$615
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$616,LCFI87-Ltext0
- .quad L$set$616
- .set L$set$617,LCFI88-Ltext0
- .quad L$set$617
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$618,LCFI88-Ltext0
- .quad L$set$618
- .set L$set$619,LFE46-Ltext0
- .quad L$set$619
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST31:
- .set L$set$620,LFB47-Ltext0
- .quad L$set$620
- .set L$set$621,LCFI90-Ltext0
- .quad L$set$621
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$622,LCFI90-Ltext0
- .quad L$set$622
- .set L$set$623,LCFI91-Ltext0
- .quad L$set$623
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$624,LCFI91-Ltext0
- .quad L$set$624
- .set L$set$625,LFE47-Ltext0
- .quad L$set$625
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST32:
- .set L$set$626,LFB48-Ltext0
- .quad L$set$626
- .set L$set$627,LCFI93-Ltext0
- .quad L$set$627
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$628,LCFI93-Ltext0
- .quad L$set$628
- .set L$set$629,LCFI94-Ltext0
- .quad L$set$629
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$630,LCFI94-Ltext0
- .quad L$set$630
- .set L$set$631,LFE48-Ltext0
- .quad L$set$631
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST33:
- .set L$set$632,LFB49-Ltext0
- .quad L$set$632
- .set L$set$633,LCFI96-Ltext0
- .quad L$set$633
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$634,LCFI96-Ltext0
- .quad L$set$634
- .set L$set$635,LCFI97-Ltext0
- .quad L$set$635
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$636,LCFI97-Ltext0
- .quad L$set$636
- .set L$set$637,LFE49-Ltext0
- .quad L$set$637
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST34:
- .set L$set$638,LFB50-Ltext0
- .quad L$set$638
- .set L$set$639,LCFI99-Ltext0
- .quad L$set$639
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$640,LCFI99-Ltext0
- .quad L$set$640
- .set L$set$641,LCFI100-Ltext0
- .quad L$set$641
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$642,LCFI100-Ltext0
- .quad L$set$642
- .set L$set$643,LFE50-Ltext0
- .quad L$set$643
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST35:
- .set L$set$644,LFB51-Ltext0
- .quad L$set$644
- .set L$set$645,LCFI102-Ltext0
- .quad L$set$645
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$646,LCFI102-Ltext0
- .quad L$set$646
- .set L$set$647,LCFI103-Ltext0
- .quad L$set$647
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$648,LCFI103-Ltext0
- .quad L$set$648
- .set L$set$649,LFE51-Ltext0
- .quad L$set$649
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST36:
- .set L$set$650,LFB52-Ltext0
- .quad L$set$650
- .set L$set$651,LCFI105-Ltext0
- .quad L$set$651
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$652,LCFI105-Ltext0
- .quad L$set$652
- .set L$set$653,LCFI106-Ltext0
- .quad L$set$653
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$654,LCFI106-Ltext0
- .quad L$set$654
- .set L$set$655,LFE52-Ltext0
- .quad L$set$655
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST37:
- .set L$set$656,LFB53-Ltext0
- .quad L$set$656
- .set L$set$657,LCFI108-Ltext0
- .quad L$set$657
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$658,LCFI108-Ltext0
- .quad L$set$658
- .set L$set$659,LCFI109-Ltext0
- .quad L$set$659
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$660,LCFI109-Ltext0
- .quad L$set$660
- .set L$set$661,LFE53-Ltext0
- .quad L$set$661
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST38:
- .set L$set$662,LFB54-Ltext0
- .quad L$set$662
- .set L$set$663,LCFI111-Ltext0
- .quad L$set$663
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$664,LCFI111-Ltext0
- .quad L$set$664
- .set L$set$665,LCFI112-Ltext0
- .quad L$set$665
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$666,LCFI112-Ltext0
- .quad L$set$666
- .set L$set$667,LFE54-Ltext0
- .quad L$set$667
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST39:
- .set L$set$668,LFB55-Ltext0
- .quad L$set$668
- .set L$set$669,LCFI114-Ltext0
- .quad L$set$669
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$670,LCFI114-Ltext0
- .quad L$set$670
- .set L$set$671,LCFI115-Ltext0
- .quad L$set$671
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$672,LCFI115-Ltext0
- .quad L$set$672
- .set L$set$673,LFE55-Ltext0
- .quad L$set$673
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST40:
- .set L$set$674,LFB56-Ltext0
- .quad L$set$674
- .set L$set$675,LCFI117-Ltext0
- .quad L$set$675
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$676,LCFI117-Ltext0
- .quad L$set$676
- .set L$set$677,LCFI118-Ltext0
- .quad L$set$677
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$678,LCFI118-Ltext0
- .quad L$set$678
- .set L$set$679,LFE56-Ltext0
- .quad L$set$679
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST41:
- .set L$set$680,LFB57-Ltext0
- .quad L$set$680
- .set L$set$681,LCFI120-Ltext0
- .quad L$set$681
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$682,LCFI120-Ltext0
- .quad L$set$682
- .set L$set$683,LCFI121-Ltext0
- .quad L$set$683
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$684,LCFI121-Ltext0
- .quad L$set$684
- .set L$set$685,LFE57-Ltext0
- .quad L$set$685
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST42:
- .set L$set$686,LFB58-Ltext0
- .quad L$set$686
- .set L$set$687,LCFI123-Ltext0
- .quad L$set$687
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$688,LCFI123-Ltext0
- .quad L$set$688
- .set L$set$689,LCFI124-Ltext0
- .quad L$set$689
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$690,LCFI124-Ltext0
- .quad L$set$690
- .set L$set$691,LFE58-Ltext0
- .quad L$set$691
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST43:
- .set L$set$692,LFB59-Ltext0
- .quad L$set$692
- .set L$set$693,LCFI126-Ltext0
- .quad L$set$693
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$694,LCFI126-Ltext0
- .quad L$set$694
- .set L$set$695,LCFI127-Ltext0
- .quad L$set$695
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$696,LCFI127-Ltext0
- .quad L$set$696
- .set L$set$697,LFE59-Ltext0
- .quad L$set$697
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST44:
- .set L$set$698,LFB60-Ltext0
- .quad L$set$698
- .set L$set$699,LCFI129-Ltext0
- .quad L$set$699
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$700,LCFI129-Ltext0
- .quad L$set$700
- .set L$set$701,LCFI130-Ltext0
- .quad L$set$701
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$702,LCFI130-Ltext0
- .quad L$set$702
- .set L$set$703,LFE60-Ltext0
- .quad L$set$703
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST45:
- .set L$set$704,LFB61-Ltext0
- .quad L$set$704
- .set L$set$705,LCFI132-Ltext0
- .quad L$set$705
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$706,LCFI132-Ltext0
- .quad L$set$706
- .set L$set$707,LCFI133-Ltext0
- .quad L$set$707
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$708,LCFI133-Ltext0
- .quad L$set$708
- .set L$set$709,LFE61-Ltext0
- .quad L$set$709
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST46:
- .set L$set$710,LFB62-Ltext0
- .quad L$set$710
- .set L$set$711,LCFI135-Ltext0
- .quad L$set$711
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$712,LCFI135-Ltext0
- .quad L$set$712
- .set L$set$713,LCFI136-Ltext0
- .quad L$set$713
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$714,LCFI136-Ltext0
- .quad L$set$714
- .set L$set$715,LFE62-Ltext0
- .quad L$set$715
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
-LLST47:
- .set L$set$716,LFB63-Ltext0
- .quad L$set$716
- .set L$set$717,LCFI138-Ltext0
- .quad L$set$717
- .word 0x2
- .byte 0x77
- .byte 0x8
- .set L$set$718,LCFI138-Ltext0
- .quad L$set$718
- .set L$set$719,LCFI139-Ltext0
- .quad L$set$719
- .word 0x2
- .byte 0x77
- .byte 0x10
- .set L$set$720,LCFI139-Ltext0
- .quad L$set$720
- .set L$set$721,LFE63-Ltext0
- .quad L$set$721
- .word 0x2
- .byte 0x76
- .byte 0x10
- .quad 0x0
- .quad 0x0
- .file 2 "/Users/fish/work/edk2/MdePkg/Include/X64/ProcessorBind.h"
- .file 3 "/Users/fish/work/edk2/MdePkg/Include/Base.h"
- .file 4 "<built-in>"
- .file 5 "/Users/fish/work/edk2/MdePkg/Include/Uefi/UefiBaseType.h"
- .file 6 "/usr/include/sys/termios.h"
- .file 7 "/usr/include/i386/_types.h"
- .file 8 "/usr/include/sys/_types.h"
- .file 9 "/usr/include/stdio.h"
- .file 10 "/usr/include/sys/_structs.h"
- .file 11 "/usr/include/sys/time.h"
- .file 12 "/usr/include/time.h"
- .file 13 "/usr/include/sys/dirent.h"
- .file 14 "/usr/include/dirent.h"
- .file 15 "/usr/include/unistd.h"
- .file 16 "/usr/include/sys/poll.h"
- .file 17 "/usr/include/i386/types.h"
- .file 18 "/usr/include/sys/types.h"
- .file 19 "/usr/lib/gcc/i686-apple-darwin10/4.2.1/include/stdint.h"
- .file 20 "/usr/include/sys/mount.h"
- .file 21 "/usr/include/utime.h"
- .file 22 "/Users/fish/work/edk2/MdePkg/Include/Library/PeCoffLib.h"
- .file 23 "/Users/fish/work/edk2/UnixPkg/Include/Protocol/UnixThunk.h"
- .file 24 "/Users/fish/work/edk2/UnixPkg/Include/Protocol/UnixUgaIo.h"
- .file 25 "/Users/fish/work/edk2/MdePkg/Include/Protocol/UgaDraw.h"
- .file 26 "/Users/fish/work/edk2/MdePkg/Include/Protocol/SimpleTextIn.h"
- .section __DWARF,__debug_info,regular,debug
- .long 0x20dc
- .word 0x2
- .set L$set$722,Ldebug_abbrev0-Lsection__debug_abbrev
- .long L$set$722
- .byte 0x8
- .byte 0x1
- .ascii "GNU C 4.2.1 (Apple Inc. build 5664)\0"
- .byte 0x1
- .ascii "/Users/fish/work/edk2/UnixPkg/Sec/X64/GasketEfiTemplate.c\0"
- .quad Ltext0
- .quad Letext0
- .set L$set$723,Ldebug_line0-Lsection__debug_line
- .long L$set$723
- .byte 0x2
- .ascii "UINT64\0"
- .byte 0x2
- .byte 0x9b
- .long 0x8d
- .byte 0x3
- .byte 0x8
- .byte 0x7
- .ascii "long long unsigned int\0"
- .byte 0x3
- .byte 0x8
- .byte 0x5
- .ascii "long long int\0"
- .byte 0x2
- .ascii "UINT32\0"
- .byte 0x2
- .byte 0xa3
- .long 0xc6
- .byte 0x3
- .byte 0x4
- .byte 0x7
- .ascii "unsigned int\0"
- .byte 0x3
- .byte 0x4
- .byte 0x5
- .ascii "int\0"
- .byte 0x2
- .ascii "UINT16\0"
- .byte 0x2
- .byte 0xab
- .long 0xeb
- .byte 0x3
- .byte 0x2
- .byte 0x7
- .ascii "short unsigned int\0"
- .byte 0x2
- .ascii "CHAR16\0"
- .byte 0x2
- .byte 0xb0
- .long 0xeb
- .byte 0x2
- .ascii "INT16\0"
- .byte 0x2
- .byte 0xb4
- .long 0x11c
- .byte 0x3
- .byte 0x2
- .byte 0x5
- .ascii "short int\0"
- .byte 0x2
- .ascii "BOOLEAN\0"
- .byte 0x2
- .byte 0xb9
- .long 0x138
- .byte 0x3
- .byte 0x1
- .byte 0x8
- .ascii "unsigned char\0"
- .byte 0x2
- .ascii "UINT8\0"
- .byte 0x2
- .byte 0xbd
- .long 0x138
- .byte 0x2
- .ascii "CHAR8\0"
- .byte 0x2
- .byte 0xc1
- .long 0x163
- .byte 0x3
- .byte 0x1
- .byte 0x6
- .ascii "char\0"
- .byte 0x2
- .ascii "UINTN\0"
- .byte 0x2
- .byte 0xcc
- .long 0x7f
- .byte 0x4
- .byte 0x8
- .byte 0x7
- .byte 0x2
- .ascii "PHYSICAL_ADDRESS\0"
- .byte 0x3
- .byte 0x84
- .long 0x7f
- .byte 0x5
- .ascii "VA_LIST\0"
- .byte 0x3
- .word 0x1d2
- .long 0x1a3
- .byte 0x6
- .long 0x1b3
- .long 0x1b3
- .byte 0x7
- .long 0x178
- .byte 0x0
- .byte 0x0
- .byte 0x8
- .ascii "__va_list_tag\0"
- .byte 0x18
- .byte 0x4
- .byte 0x0
- .long 0x226
- .byte 0x9
- .ascii "gp_offset\0"
- .byte 0x4
- .byte 0x0
- .long 0xc6
- .byte 0x2
- .byte 0x23
- .byte 0x0
- .byte 0x9
- .ascii "fp_offset\0"
- .byte 0x4
- .byte 0x0
- .long 0xc6
- .byte 0x2
- .byte 0x23
- .byte 0x4
- .byte 0x9
- .ascii "overflow_arg_area\0"
- .byte 0x4
- .byte 0x0
- .long 0x226
- .byte 0x2
- .byte 0x23
- .byte 0x8
- .byte 0x9
- .ascii "reg_save_area\0"
- .byte 0x4
- .byte 0x0
- .long 0x226
- .byte 0x2
- .byte 0x23
- .byte 0x10
- .byte 0x0
- .byte 0xa
- .byte 0x8
- .byte 0xb
- .byte 0x8
- .long 0x16b
- .byte 0x5
- .ascii "RETURN_STATUS\0"
- .byte 0x3
- .word 0x2a6
- .long 0x16b
- .byte 0x2
- .ascii "EFI_STATUS\0"
- .byte 0x5
- .byte 0x1f
- .long 0x22e
- .byte 0xc
- .byte 0x10
- .byte 0x5
- .byte 0x46
- .long 0x316
- .byte 0x9
- .ascii "Year\0"
- .byte 0x5
- .byte 0x47
- .long 0xdd
- .byte 0x2
- .byte 0x23
- .byte 0x0
- .byte 0x9
- .ascii "Month\0"
- .byte 0x5
- .byte 0x48
- .long 0x149
- .byte 0x2
- .byte 0x23
- .byte 0x2
- .byte 0x9
- .ascii "Day\0"
- .byte 0x5
- .byte 0x49
- .long 0x149
- .byte 0x2
- .byte 0x23
- .byte 0x3
- .byte 0x9
- .ascii "Hour\0"
- .byte 0x5
- .byte 0x4a
- .long 0x149
- .byte 0x2
- .byte 0x23
- .byte 0x4
- .byte 0x9
- .ascii "Minute\0"
- .byte 0x5
- .byte 0x4b
- .long 0x149
- .byte 0x2
- .byte 0x23
- .byte 0x5
- .byte 0x9
- .ascii "Second\0"
- .byte 0x5
- .byte 0x4c
- .long 0x149
- .byte 0x2
- .byte 0x23
- .byte 0x6
- .byte 0x9
- .ascii "Pad1\0"
- .byte 0x5
- .byte 0x4d
- .long 0x149
- .byte 0x2
- .byte 0x23
- .byte 0x7
- .byte 0x9
- .ascii "Nanosecond\0"
- .byte 0x5
- .byte 0x4e
- .long 0xb8
- .byte 0x2
- .byte 0x23
- .byte 0x8
- .byte 0x9
- .ascii "TimeZone\0"
- .byte 0x5
- .byte 0x4f
- .long 0x10f
- .byte 0x2
- .byte 0x23
- .byte 0xc
- .byte 0x9
- .ascii "Daylight\0"
- .byte 0x5
- .byte 0x50
- .long 0x149
- .byte 0x2
- .byte 0x23
- .byte 0xe
- .byte 0x9
- .ascii "Pad2\0"
- .byte 0x5
- .byte 0x51
- .long 0x149
- .byte 0x2
- .byte 0x23
- .byte 0xf
- .byte 0x0
- .byte 0x2
- .ascii "EFI_TIME\0"
- .byte 0x5
- .byte 0x52
- .long 0x256
- .byte 0xb
- .byte 0x8
- .long 0x226
- .byte 0x5
- .ascii "tcflag_t\0"
- .byte 0x6
- .word 0x109
- .long 0x33d
- .byte 0x3
- .byte 0x8
- .byte 0x7
- .ascii "long unsigned int\0"
- .byte 0x5
- .ascii "cc_t\0"
- .byte 0x6
- .word 0x10a
- .long 0x138
- .byte 0x5
- .ascii "speed_t\0"
- .byte 0x6
- .word 0x10b
- .long 0x33d
- .byte 0xd
- .ascii "termios\0"
- .byte 0x48
- .byte 0x6
- .word 0x10d
- .long 0x405
- .byte 0xe
- .ascii "c_iflag\0"
- .byte 0x6
- .word 0x10e
- .long 0x32c
- .byte 0x2
- .byte 0x23
- .byte 0x0
- .byte 0xe
- .ascii "c_oflag\0"
- .byte 0x6
- .word 0x10f
- .long 0x32c
- .byte 0x2
- .byte 0x23
- .byte 0x8
- .byte 0xe
- .ascii "c_cflag\0"
- .byte 0x6
- .word 0x110
- .long 0x32c
- .byte 0x2
- .byte 0x23
- .byte 0x10
- .byte 0xe
- .ascii "c_lflag\0"
- .byte 0x6
- .word 0x111
- .long 0x32c
- .byte 0x2
- .byte 0x23
- .byte 0x18
- .byte 0xe
- .ascii "c_cc\0"
- .byte 0x6
- .word 0x112
- .long 0x405
- .byte 0x2
- .byte 0x23
- .byte 0x20
- .byte 0xe
- .ascii "c_ispeed\0"
- .byte 0x6
- .word 0x113
- .long 0x35f
- .byte 0x2
- .byte 0x23
- .byte 0x38
- .byte 0xe
- .ascii "c_ospeed\0"
- .byte 0x6
- .word 0x114
- .long 0x35f
- .byte 0x2
- .byte 0x23
- .byte 0x40
- .byte 0x0
- .byte 0x6
- .long 0x352
- .long 0x415
- .byte 0x7
- .long 0x178
- .byte 0x13
- .byte 0x0
- .byte 0x3
- .byte 0x1
- .byte 0x6
- .ascii "signed char\0"
- .byte 0x2
- .ascii "__uint8_t\0"
- .byte 0x7
- .byte 0x29
- .long 0x138
- .byte 0x2
- .ascii "__uint16_t\0"
- .byte 0x7
- .byte 0x2b
- .long 0xeb
- .byte 0x2
- .ascii "__int32_t\0"
- .byte 0x7
- .byte 0x2c
- .long 0xd6
- .byte 0x2
- .ascii "__uint32_t\0"
- .byte 0x7
- .byte 0x2d
- .long 0xc6
- .byte 0x2
- .ascii "__int64_t\0"
- .byte 0x7
- .byte 0x2e
- .long 0xa7
- .byte 0x2
- .ascii "__uint64_t\0"
- .byte 0x7
- .byte 0x2f
- .long 0x8d
- .byte 0x3
- .byte 0x8
- .byte 0x5
- .ascii "long int\0"
- .byte 0x2
- .ascii "__darwin_time_t\0"
- .byte 0x7
- .byte 0x76
- .long 0x48d
- .byte 0x6
- .long 0x163
- .long 0x4c0
- .byte 0x7
- .long 0x178
- .byte 0x37
- .byte 0x0
- .byte 0x8
- .ascii "_opaque_pthread_mutex_t\0"
- .byte 0x40
- .byte 0x8
- .byte 0x43
- .long 0x504
- .byte 0x9
- .ascii "__sig\0"
- .byte 0x8
- .byte 0x43
- .long 0x48d
- .byte 0x2
- .byte 0x23
- .byte 0x0
- .byte 0x9
- .ascii "__opaque\0"
- .byte 0x8
- .byte 0x43
- .long 0x4b0
- .byte 0x2
- .byte 0x23
- .byte 0x8
- .byte 0x0
- .byte 0x6
- .long 0x163
- .long 0x514
- .byte 0x7
- .long 0x178
- .byte 0xf
- .byte 0x0
- .byte 0x2
- .ascii "__darwin_blkcnt_t\0"
- .byte 0x8
- .byte 0x5e
- .long 0x46a
- .byte 0x2
- .ascii "__darwin_blksize_t\0"
- .byte 0x8
- .byte 0x5f
- .long 0x447
- .byte 0x2
- .ascii "__darwin_dev_t\0"
- .byte 0x8
- .byte 0x60
- .long 0x447
- .byte 0x2
- .ascii "__darwin_gid_t\0"
- .byte 0x8
- .byte 0x63
- .long 0x458
- .byte 0x2
- .ascii "__darwin_ino64_t\0"
- .byte 0x8
- .byte 0x65
- .long 0x47b
- .byte 0x2
- .ascii "__darwin_mode_t\0"
- .byte 0x8
- .byte 0x6d
- .long 0x435
- .byte 0x2
- .ascii "__darwin_off_t\0"
- .byte 0x8
- .byte 0x6e
- .long 0x46a
- .byte 0x2
- .ascii "__darwin_pthread_mutex_t\0"
- .byte 0x8
- .byte 0x78
- .long 0x4c0
- .byte 0x2
- .ascii "__darwin_uid_t\0"
- .byte 0x8
- .byte 0x85
- .long 0x458
- .byte 0x2
- .ascii "off_t\0"
- .byte 0x9
- .byte 0x4b
- .long 0x5a2
- .byte 0xb
- .byte 0x8
- .long 0x163
- .byte 0xb
- .byte 0x8
- .long 0x607
- .byte 0xf
- .long 0x163
- .byte 0x8
- .ascii "timespec\0"
- .byte 0x10
- .byte 0xa
- .byte 0x59
- .long 0x641
- .byte 0x9
- .ascii "tv_sec\0"
- .byte 0xa
- .byte 0x5a
- .long 0x499
- .byte 0x2
- .byte 0x23
- .byte 0x0
- .byte 0x9
- .ascii "tv_nsec\0"
- .byte 0xa
- .byte 0x5b
- .long 0x48d
- .byte 0x2
- .byte 0x23
- .byte 0x8
- .byte 0x0
- .byte 0x2
- .ascii "time_t\0"
- .byte 0xb
- .byte 0x51
- .long 0x499
- .byte 0x8
- .ascii "tm\0"
- .byte 0x38
- .byte 0xc
- .byte 0x5a
- .long 0x721
- .byte 0x9
- .ascii "tm_sec\0"
- .byte 0xc
- .byte 0x5b
- .long 0xd6
- .byte 0x2
- .byte 0x23
- .byte 0x0
- .byte 0x9
- .ascii "tm_min\0"
- .byte 0xc
- .byte 0x5c
- .long 0xd6
- .byte 0x2
- .byte 0x23
- .byte 0x4
- .byte 0x9
- .ascii "tm_hour\0"
- .byte 0xc
- .byte 0x5d
- .long 0xd6
- .byte 0x2
- .byte 0x23
- .byte 0x8
- .byte 0x9
- .ascii "tm_mday\0"
- .byte 0xc
- .byte 0x5e
- .long 0xd6
- .byte 0x2
- .byte 0x23
- .byte 0xc
- .byte 0x9
- .ascii "tm_mon\0"
- .byte 0xc
- .byte 0x5f
- .long 0xd6
- .byte 0x2
- .byte 0x23
- .byte 0x10
- .byte 0x9
- .ascii "tm_year\0"
- .byte 0xc
- .byte 0x60
- .long 0xd6
- .byte 0x2
- .byte 0x23
- .byte 0x14
- .byte 0x9
- .ascii "tm_wday\0"
- .byte 0xc
- .byte 0x61
- .long 0xd6
- .byte 0x2
- .byte 0x23
- .byte 0x18
- .byte 0x9
- .ascii "tm_yday\0"
- .byte 0xc
- .byte 0x62
- .long 0xd6
- .byte 0x2
- .byte 0x23
- .byte 0x1c
- .byte 0x9
- .ascii "tm_isdst\0"
- .byte 0xc
- .byte 0x63
- .long 0xd6
- .byte 0x2
- .byte 0x23
- .byte 0x20
- .byte 0x9
- .ascii "tm_gmtoff\0"
- .byte 0xc
- .byte 0x64
- .long 0x48d
- .byte 0x2
- .byte 0x23
- .byte 0x28
- .byte 0x9
- .ascii "tm_zone\0"
- .byte 0xc
- .byte 0x65
- .long 0x5fb
- .byte 0x2
- .byte 0x23
- .byte 0x30
- .byte 0x0
- .byte 0x10
- .ascii "dirent\0"
- .word 0x418
- .byte 0xd
- .byte 0x73
- .long 0x79e
- .byte 0x9
- .ascii "d_ino\0"
- .byte 0xd
- .byte 0x73
- .long 0x47b
- .byte 0x2
- .byte 0x23
- .byte 0x0
- .byte 0x9
- .ascii "d_seekoff\0"
- .byte 0xd
- .byte 0x73
- .long 0x47b
- .byte 0x2
- .byte 0x23
- .byte 0x8
- .byte 0x9
- .ascii "d_reclen\0"
- .byte 0xd
- .byte 0x73
- .long 0x435
- .byte 0x2
- .byte 0x23
- .byte 0x10
- .byte 0x9
- .ascii "d_namlen\0"
- .byte 0xd
- .byte 0x73
- .long 0x435
- .byte 0x2
- .byte 0x23
- .byte 0x12
- .byte 0x9
- .ascii "d_type\0"
- .byte 0xd
- .byte 0x73
- .long 0x424
- .byte 0x2
- .byte 0x23
- .byte 0x14
- .byte 0x9
- .ascii "d_name\0"
- .byte 0xd
- .byte 0x73
- .long 0x79e
- .byte 0x2
- .byte 0x23
- .byte 0x15
- .byte 0x0
- .byte 0x6
- .long 0x163
- .long 0x7af
- .byte 0x11
- .long 0x178
- .word 0x3ff
- .byte 0x0
- .byte 0xc
- .byte 0x88
- .byte 0xe
- .byte 0x47
- .long 0x87d
- .byte 0x9
- .ascii "__dd_fd\0"
- .byte 0xe
- .byte 0x48
- .long 0xd6
- .byte 0x2
- .byte 0x23
- .byte 0x0
- .byte 0x9
- .ascii "__dd_loc\0"
- .byte 0xe
- .byte 0x49
- .long 0x48d
- .byte 0x2
- .byte 0x23
- .byte 0x8
- .byte 0x9
- .ascii "__dd_size\0"
- .byte 0xe
- .byte 0x4a
- .long 0x48d
- .byte 0x2
- .byte 0x23
- .byte 0x10
- .byte 0x9
- .ascii "__dd_buf\0"
- .byte 0xe
- .byte 0x4b
- .long 0x5fb
- .byte 0x2
- .byte 0x23
- .byte 0x18
- .byte 0x9
- .ascii "__dd_len\0"
- .byte 0xe
- .byte 0x4c
- .long 0xd6
- .byte 0x2
- .byte 0x23
- .byte 0x20
- .byte 0x9
- .ascii "__dd_seek\0"
- .byte 0xe
- .byte 0x4d
- .long 0x48d
- .byte 0x2
- .byte 0x23
- .byte 0x28
- .byte 0x9
- .ascii "__dd_rewind\0"
- .byte 0xe
- .byte 0x4e
- .long 0x48d
- .byte 0x2
- .byte 0x23
- .byte 0x30
- .byte 0x9
- .ascii "__dd_flags\0"
- .byte 0xe
- .byte 0x4f
- .long 0xd6
- .byte 0x2
- .byte 0x23
- .byte 0x38
- .byte 0x9
- .ascii "__dd_lock\0"
- .byte 0xe
- .byte 0x50
- .long 0x5b8
- .byte 0x2
- .byte 0x23
- .byte 0x40
- .byte 0x9
- .ascii "__dd_td\0"
- .byte 0xe
- .byte 0x51
- .long 0x888
- .byte 0x3
- .byte 0x23
- .byte 0x80,0x1
- .byte 0x0
- .byte 0x12
- .ascii "_telldir\0"
- .byte 0x1
- .byte 0xb
- .byte 0x8
- .long 0x87d
- .byte 0x2
- .ascii "DIR\0"
- .byte 0xe
- .byte 0x52
- .long 0x7af
- .byte 0x2
- .ascii "dev_t\0"
- .byte 0xf
- .byte 0x4d
- .long 0x547
- .byte 0x2
- .ascii "gid_t\0"
- .byte 0xf
- .byte 0x53
- .long 0x55d
- .byte 0x2
- .ascii "mode_t\0"
- .byte 0xf
- .byte 0x5e
- .long 0x58b
- .byte 0x2
- .ascii "uid_t\0"
- .byte 0xf
- .byte 0x7a
- .long 0x5d8
- .byte 0x8
- .ascii "pollfd\0"
- .byte 0x8
- .byte 0x10
- .byte 0x61
- .long 0x90e
- .byte 0x9
- .ascii "fd\0"
- .byte 0x10
- .byte 0x62
- .long 0xd6
- .byte 0x2
- .byte 0x23
- .byte 0x0
- .byte 0x9
- .ascii "events\0"
- .byte 0x10
- .byte 0x63
- .long 0x11c
- .byte 0x2
- .byte 0x23
- .byte 0x4
- .byte 0x9
- .ascii "revents\0"
- .byte 0x10
- .byte 0x64
- .long 0x11c
- .byte 0x2
- .byte 0x23
- .byte 0x6
- .byte 0x0
- .byte 0x2
- .ascii "int32_t\0"
- .byte 0x11
- .byte 0x58
- .long 0xd6
- .byte 0x2
- .ascii "blkcnt_t\0"
- .byte 0x12
- .byte 0x6e
- .long 0x514
- .byte 0x2
- .ascii "blksize_t\0"
- .byte 0x12
- .byte 0x73
- .long 0x52d
- .byte 0x2
- .ascii "nlink_t\0"
- .byte 0x12
- .byte 0x9d
- .long 0x435
- .byte 0x6
- .long 0x46a
- .long 0x95d
- .byte 0x7
- .long 0x178
- .byte 0x1
- .byte 0x0
- .byte 0x2
- .ascii "uint32_t\0"
- .byte 0x13
- .byte 0x32
- .long 0xc6
- .byte 0x2
- .ascii "uint64_t\0"
- .byte 0x13
- .byte 0x37
- .long 0x8d
- .byte 0x8
- .ascii "fsid\0"
- .byte 0x8
- .byte 0x14
- .byte 0x53
- .long 0x999
- .byte 0x9
- .ascii "val\0"
- .byte 0x14
- .byte 0x53
- .long 0x999
- .byte 0x2
- .byte 0x23
- .byte 0x0
- .byte 0x0
- .byte 0x6
- .long 0x90e
- .long 0x9a9
- .byte 0x7
- .long 0x178
- .byte 0x1
- .byte 0x0
- .byte 0x2
- .ascii "fsid_t\0"
- .byte 0x14
- .byte 0x53
- .long 0x97d
- .byte 0x6
- .long 0x95d
- .long 0x9c7
- .byte 0x7
- .long 0x178
- .byte 0x7
- .byte 0x0
- .byte 0x10
- .ascii "statfs\0"
- .word 0x878
- .byte 0x14
- .byte 0x7d
- .long 0xb11
- .byte 0x9
- .ascii "f_bsize\0"
- .byte 0x14
- .byte 0x7d
- .long 0x95d
- .byte 0x2
- .byte 0x23
- .byte 0x0
- .byte 0x9
- .ascii "f_iosize\0"
- .byte 0x14
- .byte 0x7d
- .long 0x90e
- .byte 0x2
- .byte 0x23
- .byte 0x4
- .byte 0x9
- .ascii "f_blocks\0"
- .byte 0x14
- .byte 0x7d
- .long 0x96d
- .byte 0x2
- .byte 0x23
- .byte 0x8
- .byte 0x9
- .ascii "f_bfree\0"
- .byte 0x14
- .byte 0x7d
- .long 0x96d
- .byte 0x2
- .byte 0x23
- .byte 0x10
- .byte 0x9
- .ascii "f_bavail\0"
- .byte 0x14
- .byte 0x7d
- .long 0x96d
- .byte 0x2
- .byte 0x23
- .byte 0x18
- .byte 0x9
- .ascii "f_files\0"
- .byte 0x14
- .byte 0x7d
- .long 0x96d
- .byte 0x2
- .byte 0x23
- .byte 0x20
- .byte 0x9
- .ascii "f_ffree\0"
- .byte 0x14
- .byte 0x7d
- .long 0x96d
- .byte 0x2
- .byte 0x23
- .byte 0x28
- .byte 0x9
- .ascii "f_fsid\0"
- .byte 0x14
- .byte 0x7d
- .long 0x9a9
- .byte 0x2
- .byte 0x23
- .byte 0x30
- .byte 0x9
- .ascii "f_owner\0"
- .byte 0x14
- .byte 0x7d
- .long 0x8c1
- .byte 0x2
- .byte 0x23
- .byte 0x38
- .byte 0x9
- .ascii "f_type\0"
- .byte 0x14
- .byte 0x7d
- .long 0x95d
- .byte 0x2
- .byte 0x23
- .byte 0x3c
- .byte 0x9
- .ascii "f_flags\0"
- .byte 0x14
- .byte 0x7d
- .long 0x95d
- .byte 0x2
- .byte 0x23
- .byte 0x40
- .byte 0x9
- .ascii "f_fssubtype\0"
- .byte 0x14
- .byte 0x7d
- .long 0x95d
- .byte 0x2
- .byte 0x23
- .byte 0x44
- .byte 0x9
- .ascii "f_fstypename\0"
- .byte 0x14
- .byte 0x7d
- .long 0x504
- .byte 0x2
- .byte 0x23
- .byte 0x48
- .byte 0x9
- .ascii "f_mntonname\0"
- .byte 0x14
- .byte 0x7d
- .long 0x79e
- .byte 0x2
- .byte 0x23
- .byte 0x58
- .byte 0x9
- .ascii "f_mntfromname\0"
- .byte 0x14
- .byte 0x7d
- .long 0x79e
- .byte 0x3
- .byte 0x23
- .byte 0xd8,0x8
- .byte 0x9
- .ascii "f_reserved\0"
- .byte 0x14
- .byte 0x7d
- .long 0x9b7
- .byte 0x3
- .byte 0x23
- .byte 0xd8,0x10
- .byte 0x0
- .byte 0x8
- .ascii "utimbuf\0"
- .byte 0x10
- .byte 0x15
- .byte 0x44
- .long 0xb45
- .byte 0x9
- .ascii "actime\0"
- .byte 0x15
- .byte 0x45
- .long 0x641
- .byte 0x2
- .byte 0x23
- .byte 0x0
- .byte 0x9
- .ascii "modtime\0"
- .byte 0x15
- .byte 0x46
- .long 0x641
- .byte 0x2
- .byte 0x23
- .byte 0x8
- .byte 0x0
- .byte 0x2
- .ascii "PE_COFF_LOADER_READ_FILE\0"
- .byte 0x16
- .byte 0x4b
- .long 0xb65
- .byte 0xb
- .byte 0x8
- .long 0xb6b
- .byte 0x13
- .byte 0x1
- .long 0x22e
- .long 0xb8a
- .byte 0x14
- .long 0x226
- .byte 0x14
- .long 0x16b
- .byte 0x14
- .long 0x228
- .byte 0x14
- .long 0x226
- .byte 0x0
- .byte 0xc
- .byte 0x90
- .byte 0x16
- .byte 0x50
- .long 0xdaa
- .byte 0x9
- .ascii "ImageAddress\0"
- .byte 0x16
- .byte 0x54
- .long 0x17b
- .byte 0x2
- .byte 0x23
- .byte 0x0
- .byte 0x9
- .ascii "ImageSize\0"
- .byte 0x16
- .byte 0x59
- .long 0x7f
- .byte 0x2
- .byte 0x23
- .byte 0x8
- .byte 0x9
- .ascii "DestinationAddress\0"
- .byte 0x16
- .byte 0x60
- .long 0x17b
- .byte 0x2
- .byte 0x23
- .byte 0x10
- .byte 0x15
- .set L$set$724,LASF0-Lsection__debug_str
- .long L$set$724
- .byte 0x16
- .byte 0x64
- .long 0x17b
- .byte 0x2
- .byte 0x23
- .byte 0x18
- .byte 0x9
- .ascii "ImageRead\0"
- .byte 0x16
- .byte 0x69
- .long 0xb45
- .byte 0x2
- .byte 0x23
- .byte 0x20
- .byte 0x9
- .ascii "Handle\0"
- .byte 0x16
- .byte 0x6d
- .long 0x226
- .byte 0x2
- .byte 0x23
- .byte 0x28
- .byte 0x9
- .ascii "FixupData\0"
- .byte 0x16
- .byte 0x74
- .long 0x226
- .byte 0x2
- .byte 0x23
- .byte 0x30
- .byte 0x9
- .ascii "SectionAlignment\0"
- .byte 0x16
- .byte 0x79
- .long 0xb8
- .byte 0x2
- .byte 0x23
- .byte 0x38
- .byte 0x9
- .ascii "PeCoffHeaderOffset\0"
- .byte 0x16
- .byte 0x7f
- .long 0xb8
- .byte 0x2
- .byte 0x23
- .byte 0x3c
- .byte 0x9
- .ascii "DebugDirectoryEntryRva\0"
- .byte 0x16
- .byte 0x84
- .long 0xb8
- .byte 0x2
- .byte 0x23
- .byte 0x40
- .byte 0x9
- .ascii "CodeView\0"
- .byte 0x16
- .byte 0x88
- .long 0x226
- .byte 0x2
- .byte 0x23
- .byte 0x48
- .byte 0x9
- .ascii "PdbPointer\0"
- .byte 0x16
- .byte 0x8e
- .long 0xdaa
- .byte 0x2
- .byte 0x23
- .byte 0x50
- .byte 0x9
- .ascii "SizeOfHeaders\0"
- .byte 0x16
- .byte 0x92
- .long 0x16b
- .byte 0x2
- .byte 0x23
- .byte 0x58
- .byte 0x9
- .ascii "ImageCodeMemoryType\0"
- .byte 0x16
- .byte 0x99
- .long 0xb8
- .byte 0x2
- .byte 0x23
- .byte 0x60
- .byte 0x9
- .ascii "ImageDataMemoryType\0"
- .byte 0x16
- .byte 0xa0
- .long 0xb8
- .byte 0x2
- .byte 0x23
- .byte 0x64
- .byte 0x9
- .ascii "ImageError\0"
- .byte 0x16
- .byte 0xa4
- .long 0xb8
- .byte 0x2
- .byte 0x23
- .byte 0x68
- .byte 0x9
- .ascii "FixupDataSize\0"
- .byte 0x16
- .byte 0xa9
- .long 0x16b
- .byte 0x2
- .byte 0x23
- .byte 0x70
- .byte 0x9
- .ascii "Machine\0"
- .byte 0x16
- .byte 0xad
- .long 0xdd
- .byte 0x2
- .byte 0x23
- .byte 0x78
- .byte 0x9
- .ascii "ImageType\0"
- .byte 0x16
- .byte 0xb1
- .long 0xdd
- .byte 0x2
- .byte 0x23
- .byte 0x7a
- .byte 0x9
- .ascii "RelocationsStripped\0"
- .byte 0x16
- .byte 0xb6
- .long 0x129
- .byte 0x2
- .byte 0x23
- .byte 0x7c
- .byte 0x9
- .ascii "IsTeImage\0"
- .byte 0x16
- .byte 0xbc
- .long 0x129
- .byte 0x2
- .byte 0x23
- .byte 0x7d
- .byte 0x9
- .ascii "HiiResourceData\0"
- .byte 0x16
- .byte 0xc2
- .long 0x17b
- .byte 0x3
- .byte 0x23
- .byte 0x80,0x1
- .byte 0x9
- .ascii "Context\0"
- .byte 0x16
- .byte 0xc6
- .long 0x7f
- .byte 0x3
- .byte 0x23
- .byte 0x88,0x1
- .byte 0x0
- .byte 0xb
- .byte 0x8
- .long 0x156
- .byte 0x2
- .ascii "PE_COFF_LOADER_IMAGE_CONTEXT\0"
- .byte 0x16
- .byte 0xc7
- .long 0xb8a
- .byte 0x8
- .ascii "stat_fix\0"
- .byte 0x90
- .byte 0x17
- .byte 0x53
- .long 0xf49
- .byte 0x9
- .ascii "st_dev\0"
- .byte 0x17
- .byte 0x53
- .long 0x899
- .byte 0x2
- .byte 0x23
- .byte 0x0
- .byte 0x9
- .ascii "st_mode\0"
- .byte 0x17
- .byte 0x55
- .long 0x8b3
- .byte 0x2
- .byte 0x23
- .byte 0x4
- .byte 0x9
- .ascii "st_nlink\0"
- .byte 0x17
- .byte 0x56
- .long 0x93e
- .byte 0x2
- .byte 0x23
- .byte 0x6
- .byte 0x9
- .ascii "st_ino\0"
- .byte 0x17
- .byte 0x57
- .long 0x573
- .byte 0x2
- .byte 0x23
- .byte 0x8
- .byte 0x9
- .ascii "st_uid\0"
- .byte 0x17
- .byte 0x58
- .long 0x8c1
- .byte 0x2
- .byte 0x23
- .byte 0x10
- .byte 0x9
- .ascii "st_gid\0"
- .byte 0x17
- .byte 0x59
- .long 0x8a6
- .byte 0x2
- .byte 0x23
- .byte 0x14
- .byte 0x9
- .ascii "st_rdev\0"
- .byte 0x17
- .byte 0x5a
- .long 0x899
- .byte 0x2
- .byte 0x23
- .byte 0x18
- .byte 0x9
- .ascii "st_atimespec\0"
- .byte 0x17
- .byte 0x5b
- .long 0x60c
- .byte 0x2
- .byte 0x23
- .byte 0x20
- .byte 0x9
- .ascii "st_mtimespec\0"
- .byte 0x17
- .byte 0x5b
- .long 0x60c
- .byte 0x2
- .byte 0x23
- .byte 0x30
- .byte 0x9
- .ascii "st_ctimespec\0"
- .byte 0x17
- .byte 0x5b
- .long 0x60c
- .byte 0x2
- .byte 0x23
- .byte 0x40
- .byte 0x9
- .ascii "st_birthtimespec\0"
- .byte 0x17
- .byte 0x5b
- .long 0x60c
- .byte 0x2
- .byte 0x23
- .byte 0x50
- .byte 0x9
- .ascii "st_size\0"
- .byte 0x17
- .byte 0x5c
- .long 0x5ee
- .byte 0x2
- .byte 0x23
- .byte 0x60
- .byte 0x9
- .ascii "st_blocks\0"
- .byte 0x17
- .byte 0x5d
- .long 0x91d
- .byte 0x2
- .byte 0x23
- .byte 0x68
- .byte 0x9
- .ascii "st_blksize\0"
- .byte 0x17
- .byte 0x5e
- .long 0x92d
- .byte 0x2
- .byte 0x23
- .byte 0x70
- .byte 0x9
- .ascii "st_flags\0"
- .byte 0x17
- .byte 0x5f
- .long 0x458
- .byte 0x2
- .byte 0x23
- .byte 0x74
- .byte 0x9
- .ascii "st_gen\0"
- .byte 0x17
- .byte 0x60
- .long 0x458
- .byte 0x2
- .byte 0x23
- .byte 0x78
- .byte 0x9
- .ascii "st_lspare\0"
- .byte 0x17
- .byte 0x61
- .long 0x447
- .byte 0x2
- .byte 0x23
- .byte 0x7c
- .byte 0x9
- .ascii "st_qspare\0"
- .byte 0x17
- .byte 0x62
- .long 0x94d
- .byte 0x3
- .byte 0x23
- .byte 0x80,0x1
- .byte 0x0
- .byte 0x2
- .ascii "STAT_FIX\0"
- .byte 0x17
- .byte 0x63
- .long 0xdd4
- .byte 0xb
- .byte 0x8
- .long 0xf5f
- .byte 0x16
- .byte 0x1
- .long 0xf6b
- .byte 0x14
- .long 0x7f
- .byte 0x0
- .byte 0xb
- .byte 0x8
- .long 0x316
- .byte 0xb
- .byte 0x8
- .long 0x64f
- .byte 0xb
- .byte 0x8
- .long 0xf7d
- .byte 0xf
- .long 0x641
- .byte 0xb
- .byte 0x8
- .long 0x8ce
- .byte 0xb
- .byte 0x8
- .long 0xf8e
- .byte 0x17
- .byte 0x2
- .ascii "UnixRmDir\0"
- .byte 0x17
- .byte 0xf2
- .long 0xfa0
- .byte 0xb
- .byte 0x8
- .long 0xfa6
- .byte 0x13
- .byte 0x1
- .long 0xd6
- .long 0xfb6
- .byte 0x14
- .long 0x601
- .byte 0x0
- .byte 0x2
- .ascii "UnixOpenDir\0"
- .byte 0x17
- .byte 0xfe
- .long 0xfc9
- .byte 0xb
- .byte 0x8
- .long 0xfcf
- .byte 0x13
- .byte 0x1
- .long 0xfdf
- .long 0xfdf
- .byte 0x14
- .long 0x601
- .byte 0x0
- .byte 0xb
- .byte 0x8
- .long 0x88e
- .byte 0xb
- .byte 0x8
- .long 0x721
- .byte 0x5
- .ascii "UnixStat\0"
- .byte 0x17
- .word 0x10e
- .long 0xffc
- .byte 0xb
- .byte 0x8
- .long 0x1002
- .byte 0x13
- .byte 0x1
- .long 0xd6
- .long 0x1017
- .byte 0x14
- .long 0x601
- .byte 0x14
- .long 0x1017
- .byte 0x0
- .byte 0xb
- .byte 0x8
- .long 0xf49
- .byte 0x5
- .ascii "UnixStatFs\0"
- .byte 0x17
- .word 0x112
- .long 0x1030
- .byte 0xb
- .byte 0x8
- .long 0x1036
- .byte 0x13
- .byte 0x1
- .long 0xd6
- .long 0x104b
- .byte 0x14
- .long 0x601
- .byte 0x14
- .long 0x104b
- .byte 0x0
- .byte 0xb
- .byte 0x8
- .long 0x9c7
- .byte 0xb
- .byte 0x8
- .long 0x1057
- .byte 0x18
- .ascii "utimbuf\0"
- .long 0xb11
- .byte 0xb
- .byte 0x8
- .long 0x106a
- .byte 0xb
- .byte 0x8
- .long 0x1070
- .byte 0xd
- .ascii "_EFI_UNIX_UGA_IO_PROTOCOL\0"
- .byte 0x30
- .byte 0x17
- .word 0x128
- .long 0x1106
- .byte 0x9
- .ascii "Private\0"
- .byte 0x18
- .byte 0x46
- .long 0x226
- .byte 0x2
- .byte 0x23
- .byte 0x0
- .byte 0x9
- .ascii "UgaClose\0"
- .byte 0x18
- .byte 0x47
- .long 0x128f
- .byte 0x2
- .byte 0x23
- .byte 0x8
- .byte 0x9
- .ascii "UgaSize\0"
- .byte 0x18
- .byte 0x48
- .long 0x12bb
- .byte 0x2
- .byte 0x23
- .byte 0x10
- .byte 0x9
- .ascii "UgaCheckKey\0"
- .byte 0x18
- .byte 0x49
- .long 0x12ea
- .byte 0x2
- .byte 0x23
- .byte 0x18
- .byte 0x9
- .ascii "UgaGetKey\0"
- .byte 0x18
- .byte 0x4a
- .long 0x12fd
- .byte 0x2
- .byte 0x23
- .byte 0x20
- .byte 0x9
- .ascii "UgaBlt\0"
- .byte 0x18
- .byte 0x4b
- .long 0x1329
- .byte 0x2
- .byte 0x23
- .byte 0x28
- .byte 0x0
- .byte 0xb
- .byte 0x8
- .long 0x110c
- .byte 0xf
- .long 0x101
- .byte 0xb
- .byte 0x8
- .long 0x36f
- .byte 0xb
- .byte 0x8
- .long 0x111d
- .byte 0x18
- .ascii "termios\0"
- .long 0x36f
- .byte 0xb
- .byte 0x8
- .long 0xdb0
- .byte 0xc
- .byte 0x4
- .byte 0x19
- .byte 0x4b
- .long 0x1179
- .byte 0x9
- .ascii "Blue\0"
- .byte 0x19
- .byte 0x4c
- .long 0x149
- .byte 0x2
- .byte 0x23
- .byte 0x0
- .byte 0x9
- .ascii "Green\0"
- .byte 0x19
- .byte 0x4d
- .long 0x149
- .byte 0x2
- .byte 0x23
- .byte 0x1
- .byte 0x9
- .ascii "Red\0"
- .byte 0x19
- .byte 0x4e
- .long 0x149
- .byte 0x2
- .byte 0x23
- .byte 0x2
- .byte 0x9
- .ascii "Reserved\0"
- .byte 0x19
- .byte 0x4f
- .long 0x149
- .byte 0x2
- .byte 0x23
- .byte 0x3
- .byte 0x0
- .byte 0x2
- .ascii "EFI_UGA_PIXEL\0"
- .byte 0x19
- .byte 0x50
- .long 0x1130
- .byte 0x19
- .byte 0x4
- .byte 0x19
- .byte 0x5a
- .long 0x11ff
- .byte 0x1a
- .ascii "EfiUgaVideoFill\0"
- .byte 0x0
- .byte 0x1a
- .ascii "EfiUgaVideoToBltBuffer\0"
- .byte 0x1
- .byte 0x1a
- .ascii "EfiUgaBltBufferToVideo\0"
- .byte 0x2
- .byte 0x1a
- .ascii "EfiUgaVideoToVideo\0"
- .byte 0x3
- .byte 0x1a
- .ascii "EfiUgaBltMax\0"
- .byte 0x4
- .byte 0x0
- .byte 0x2
- .ascii "EFI_UGA_BLT_OPERATION\0"
- .byte 0x19
- .byte 0x75
- .long 0x118e
- .byte 0xb
- .byte 0x8
- .long 0x1179
- .byte 0xc
- .byte 0x4
- .byte 0x1a
- .byte 0x29
- .long 0x1254
- .byte 0x9
- .ascii "ScanCode\0"
- .byte 0x1a
- .byte 0x2a
- .long 0xdd
- .byte 0x2
- .byte 0x23
- .byte 0x0
- .byte 0x9
- .ascii "UnicodeChar\0"
- .byte 0x1a
- .byte 0x2b
- .long 0x101
- .byte 0x2
- .byte 0x23
- .byte 0x2
- .byte 0x0
- .byte 0x2
- .ascii "EFI_INPUT_KEY\0"
- .byte 0x1a
- .byte 0x2c
- .long 0x1222
- .byte 0xb
- .byte 0x8
- .long 0x1254
- .byte 0x2
- .ascii "EFI_UNIX_UGA_IO_PROTOCOL\0"
- .byte 0x18
- .byte 0x19
- .long 0x1070
- .byte 0x2
- .ascii "UGAClose\0"
- .byte 0x18
- .byte 0x1f
- .long 0x129f
- .byte 0xb
- .byte 0x8
- .long 0x12a5
- .byte 0x13
- .byte 0x1
- .long 0x244
- .long 0x12b5
- .byte 0x14
- .long 0x12b5
- .byte 0x0
- .byte 0xb
- .byte 0x8
- .long 0x126f
- .byte 0x2
- .ascii "UGASize\0"
- .byte 0x18
- .byte 0x27
- .long 0x12ca
- .byte 0xb
- .byte 0x8
- .long 0x12d0
- .byte 0x13
- .byte 0x1
- .long 0x244
- .long 0x12ea
- .byte 0x14
- .long 0x12b5
- .byte 0x14
- .long 0xb8
- .byte 0x14
- .long 0xb8
- .byte 0x0
- .byte 0x2
- .ascii "UGACheckKey\0"
- .byte 0x18
- .byte 0x2d
- .long 0x129f
- .byte 0x2
- .ascii "UGAGetKey\0"
- .byte 0x18
- .byte 0x34
- .long 0x130e
- .byte 0xb
- .byte 0x8
- .long 0x1314
- .byte 0x13
- .byte 0x1
- .long 0x244
- .long 0x1329
- .byte 0x14
- .long 0x12b5
- .byte 0x14
- .long 0x1269
- .byte 0x0
- .byte 0x2
- .ascii "UGABlt\0"
- .byte 0x18
- .byte 0x43
- .long 0x1337
- .byte 0xb
- .byte 0x8
- .long 0x133d
- .byte 0x13
- .byte 0x1
- .long 0x244
- .long 0x137a
- .byte 0x14
- .long 0x12b5
- .byte 0x14
- .long 0x121c
- .byte 0x14
- .long 0x11ff
- .byte 0x14
- .long 0x16b
- .byte 0x14
- .long 0x16b
- .byte 0x14
- .long 0x16b
- .byte 0x14
- .long 0x16b
- .byte 0x14
- .long 0x16b
- .byte 0x14
- .long 0x16b
- .byte 0x14
- .long 0x16b
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$725,LASF1-Lsection__debug_str
- .long L$set$725
- .byte 0x1
- .byte 0x23
- .byte 0x1
- .long 0xd6
- .quad LFB16
- .quad LFE16
- .set L$set$726,LLST0-Lsection__debug_loc
- .long L$set$726
- .long 0x13ae
- .byte 0x1c
- .set L$set$727,LASF3-Lsection__debug_str
- .long L$set$727
- .byte 0x1
- .byte 0x22
- .long 0x601
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$728,LASF2-Lsection__debug_str
- .long L$set$728
- .byte 0x1
- .byte 0x2a
- .byte 0x1
- .long 0xfdf
- .quad LFB17
- .quad LFE17
- .set L$set$729,LLST1-Lsection__debug_loc
- .long L$set$729
- .long 0x13e2
- .byte 0x1c
- .set L$set$730,LASF3-Lsection__debug_str
- .long L$set$730
- .byte 0x1
- .byte 0x29
- .long 0x601
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$731,LASF4-Lsection__debug_str
- .long L$set$731
- .byte 0x1
- .byte 0x31
- .byte 0x1
- .long 0xd6
- .quad LFB18
- .quad LFE18
- .set L$set$732,LLST2-Lsection__debug_loc
- .long L$set$732
- .long 0x1425
- .byte 0x1d
- .ascii "path\0"
- .byte 0x1
- .byte 0x30
- .long 0x601
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x1d
- .ascii "buf\0"
- .byte 0x1
- .byte 0x30
- .long 0x1017
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$733,LASF5-Lsection__debug_str
- .long L$set$733
- .byte 0x1
- .byte 0x38
- .byte 0x1
- .long 0xd6
- .quad LFB19
- .quad LFE19
- .set L$set$734,LLST3-Lsection__debug_loc
- .long L$set$734
- .long 0x1468
- .byte 0x1d
- .ascii "path\0"
- .byte 0x1
- .byte 0x37
- .long 0x601
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x1d
- .ascii "buf\0"
- .byte 0x1
- .byte 0x37
- .long 0x104b
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x0
- .byte 0x1e
- .byte 0x1
- .set L$set$735,LASF6-Lsection__debug_str
- .long L$set$735
- .byte 0x1
- .byte 0x41
- .byte 0x1
- .quad LFB20
- .quad LFE20
- .set L$set$736,LLST4-Lsection__debug_loc
- .long L$set$736
- .long 0x14a1
- .byte 0x1d
- .ascii "Milliseconds\0"
- .byte 0x1
- .byte 0x40
- .long 0x33d
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x1e
- .byte 0x1
- .set L$set$737,LASF7-Lsection__debug_str
- .long L$set$737
- .byte 0x1
- .byte 0x48
- .byte 0x1
- .quad LFB21
- .quad LFE21
- .set L$set$738,LLST5-Lsection__debug_loc
- .long L$set$738
- .long 0x14d4
- .byte 0x1d
- .ascii "status\0"
- .byte 0x1
- .byte 0x47
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x6c
- .byte 0x0
- .byte 0x1e
- .byte 0x1
- .set L$set$739,LASF8-Lsection__debug_str
- .long L$set$739
- .byte 0x1
- .byte 0x50
- .byte 0x1
- .quad LFB22
- .quad LFE22
- .set L$set$740,LLST6-Lsection__debug_loc
- .long L$set$740
- .long 0x151c
- .byte 0x1d
- .ascii "PeriodMs\0"
- .byte 0x1
- .byte 0x4f
- .long 0x7f
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x1d
- .ascii "CallBack\0"
- .byte 0x1
- .byte 0x4f
- .long 0xf59
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x0
- .byte 0x1e
- .byte 0x1
- .set L$set$741,LASF9-Lsection__debug_str
- .long L$set$741
- .byte 0x1
- .byte 0x58
- .byte 0x1
- .quad LFB23
- .quad LFE23
- .set L$set$742,LLST7-Lsection__debug_loc
- .long L$set$742
- .long 0x154d
- .byte 0x1d
- .ascii "Time\0"
- .byte 0x1
- .byte 0x57
- .long 0xf6b
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$743,LASF10-Lsection__debug_str
- .long L$set$743
- .byte 0x1
- .byte 0x60
- .byte 0x1
- .long 0xf71
- .quad LFB24
- .quad LFE24
- .set L$set$744,LLST8-Lsection__debug_loc
- .long L$set$744
- .long 0x1583
- .byte 0x1d
- .ascii "clock\0"
- .byte 0x1
- .byte 0x5f
- .long 0xf77
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x1f
- .byte 0x1
- .set L$set$745,LASF11-Lsection__debug_str
- .long L$set$745
- .byte 0x1
- .byte 0x67
- .byte 0x1
- .long 0x48d
- .quad LFB25
- .quad LFE25
- .set L$set$746,LLST9-Lsection__debug_loc
- .long L$set$746
- .byte 0x1f
- .byte 0x1
- .set L$set$747,LASF12-Lsection__debug_str
- .long L$set$747
- .byte 0x1
- .byte 0x6e
- .byte 0x1
- .long 0xd6
- .quad LFB26
- .quad LFE26
- .set L$set$748,LLST10-Lsection__debug_loc
- .long L$set$748
- .byte 0x1b
- .byte 0x1
- .set L$set$749,LASF13-Lsection__debug_str
- .long L$set$749
- .byte 0x1
- .byte 0x75
- .byte 0x1
- .long 0xd6
- .quad LFB27
- .quad LFE27
- .set L$set$750,LLST11-Lsection__debug_loc
- .long L$set$750
- .long 0x161a
- .byte 0x1d
- .ascii "pfd\0"
- .byte 0x1
- .byte 0x74
- .long 0xf82
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x1d
- .ascii "nfds\0"
- .byte 0x1
- .byte 0x74
- .long 0xc6
- .byte 0x2
- .byte 0x91
- .byte 0x64
- .byte 0x1d
- .ascii "timeout\0"
- .byte 0x1
- .byte 0x74
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$751,LASF14-Lsection__debug_str
- .long L$set$751
- .byte 0x1
- .byte 0x7c
- .byte 0x1
- .long 0x48d
- .quad LFB28
- .quad LFE28
- .set L$set$752,LLST12-Lsection__debug_loc
- .long L$set$752
- .long 0x166b
- .byte 0x1d
- .ascii "fd\0"
- .byte 0x1
- .byte 0x7b
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x6c
- .byte 0x1d
- .ascii "buf\0"
- .byte 0x1
- .byte 0x7b
- .long 0x226
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x1d
- .ascii "count\0"
- .byte 0x1
- .byte 0x7b
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x5c
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$753,LASF15-Lsection__debug_str
- .long L$set$753
- .byte 0x1
- .byte 0x83
- .byte 0x1
- .long 0x48d
- .quad LFB29
- .quad LFE29
- .set L$set$754,LLST13-Lsection__debug_loc
- .long L$set$754
- .long 0x16bc
- .byte 0x1d
- .ascii "fd\0"
- .byte 0x1
- .byte 0x82
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x6c
- .byte 0x1d
- .ascii "buf\0"
- .byte 0x1
- .byte 0x82
- .long 0xf88
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x1d
- .ascii "count\0"
- .byte 0x1
- .byte 0x82
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x5c
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$755,LASF16-Lsection__debug_str
- .long L$set$755
- .byte 0x1
- .byte 0x8a
- .byte 0x1
- .long 0x5fb
- .quad LFB30
- .quad LFE30
- .set L$set$756,LLST14-Lsection__debug_loc
- .long L$set$756
- .long 0x16f1
- .byte 0x1d
- .ascii "name\0"
- .byte 0x1
- .byte 0x89
- .long 0x601
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$757,LASF17-Lsection__debug_str
- .long L$set$757
- .byte 0x1
- .byte 0x91
- .byte 0x1
- .long 0xd6
- .quad LFB31
- .quad LFE31
- .set L$set$758,LLST15-Lsection__debug_loc
- .long L$set$758
- .long 0x1745
- .byte 0x1d
- .ascii "name\0"
- .byte 0x1
- .byte 0x90
- .long 0x601
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x1d
- .ascii "flags\0"
- .byte 0x1
- .byte 0x90
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x64
- .byte 0x1d
- .ascii "mode\0"
- .byte 0x1
- .byte 0x90
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$759,LASF18-Lsection__debug_str
- .long L$set$759
- .byte 0x1
- .byte 0x98
- .byte 0x1
- .long 0x5ee
- .quad LFB32
- .quad LFE32
- .set L$set$760,LLST16-Lsection__debug_loc
- .long L$set$760
- .long 0x1797
- .byte 0x1d
- .ascii "fd\0"
- .byte 0x1
- .byte 0x97
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x6c
- .byte 0x1d
- .ascii "off\0"
- .byte 0x1
- .byte 0x97
- .long 0x5ee
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x1d
- .ascii "whence\0"
- .byte 0x1
- .byte 0x97
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x5c
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$761,LASF19-Lsection__debug_str
- .long L$set$761
- .byte 0x1
- .byte 0x9f
- .byte 0x1
- .long 0xd6
- .quad LFB33
- .quad LFE33
- .set L$set$762,LLST17-Lsection__debug_loc
- .long L$set$762
- .long 0x17d8
- .byte 0x1d
- .ascii "fd\0"
- .byte 0x1
- .byte 0x9e
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x6c
- .byte 0x1d
- .ascii "len\0"
- .byte 0x1
- .byte 0x9e
- .long 0x48d
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$763,LASF20-Lsection__debug_str
- .long L$set$763
- .byte 0x1
- .byte 0xa6
- .byte 0x1
- .long 0xd6
- .quad LFB34
- .quad LFE34
- .set L$set$764,LLST18-Lsection__debug_loc
- .long L$set$764
- .long 0x180b
- .byte 0x1d
- .ascii "fd\0"
- .byte 0x1
- .byte 0xa5
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x6c
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$765,LASF21-Lsection__debug_str
- .long L$set$765
- .byte 0x1
- .byte 0xad
- .byte 0x1
- .long 0xd6
- .quad LFB35
- .quad LFE35
- .set L$set$766,LLST19-Lsection__debug_loc
- .long L$set$766
- .long 0x184e
- .byte 0x1c
- .set L$set$767,LASF3-Lsection__debug_str
- .long L$set$767
- .byte 0x1
- .byte 0xac
- .long 0x601
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x1d
- .ascii "mode\0"
- .byte 0x1
- .byte 0xac
- .long 0x8b3
- .byte 0x2
- .byte 0x91
- .byte 0x64
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$768,LASF22-Lsection__debug_str
- .long L$set$768
- .byte 0x1
- .byte 0xb4
- .byte 0x1
- .long 0xd6
- .quad LFB36
- .quad LFE36
- .set L$set$769,LLST20-Lsection__debug_loc
- .long L$set$769
- .long 0x1882
- .byte 0x1c
- .set L$set$770,LASF3-Lsection__debug_str
- .long L$set$770
- .byte 0x1
- .byte 0xb3
- .long 0x601
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x1f
- .byte 0x1
- .set L$set$771,LASF23-Lsection__debug_str
- .long L$set$771
- .byte 0x1
- .byte 0xbb
- .byte 0x1
- .long 0xd6
- .quad LFB37
- .quad LFE37
- .set L$set$772,LLST21-Lsection__debug_loc
- .long L$set$772
- .byte 0x1e
- .byte 0x1
- .set L$set$773,LASF24-Lsection__debug_str
- .long L$set$773
- .byte 0x1
- .byte 0xc2
- .byte 0x1
- .quad LFB38
- .quad LFE38
- .set L$set$774,LLST22-Lsection__debug_loc
- .long L$set$774
- .long 0x18d3
- .byte 0x1d
- .ascii "dir\0"
- .byte 0x1
- .byte 0xc1
- .long 0xfdf
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$775,LASF25-Lsection__debug_str
- .long L$set$775
- .byte 0x1
- .byte 0xca
- .byte 0x1
- .long 0xfe5
- .quad LFB39
- .quad LFE39
- .set L$set$776,LLST23-Lsection__debug_loc
- .long L$set$776
- .long 0x1907
- .byte 0x1d
- .ascii "dir\0"
- .byte 0x1
- .byte 0xc9
- .long 0xfdf
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$777,LASF26-Lsection__debug_str
- .long L$set$777
- .byte 0x1
- .byte 0xd1
- .byte 0x1
- .long 0xd6
- .quad LFB40
- .quad LFE40
- .set L$set$778,LLST24-Lsection__debug_loc
- .long L$set$778
- .long 0x193b
- .byte 0x1d
- .ascii "dir\0"
- .byte 0x1
- .byte 0xd0
- .long 0xfdf
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$779,LASF27-Lsection__debug_str
- .long L$set$779
- .byte 0x1
- .byte 0xd8
- .byte 0x1
- .long 0xd6
- .quad LFB41
- .quad LFE41
- .set L$set$780,LLST25-Lsection__debug_loc
- .long L$set$780
- .long 0x1985
- .byte 0x1d
- .ascii "oldpath\0"
- .byte 0x1
- .byte 0xd7
- .long 0x601
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x1d
- .ascii "newpath\0"
- .byte 0x1
- .byte 0xd7
- .long 0x601
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$781,LASF28-Lsection__debug_str
- .long L$set$781
- .byte 0x1
- .byte 0xdf
- .byte 0x1
- .long 0x641
- .quad LFB42
- .quad LFE42
- .set L$set$782,LLST26-Lsection__debug_loc
- .long L$set$782
- .long 0x19b8
- .byte 0x1d
- .ascii "tm\0"
- .byte 0x1
- .byte 0xde
- .long 0xf71
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$783,LASF29-Lsection__debug_str
- .long L$set$783
- .byte 0x1
- .byte 0xe6
- .byte 0x1
- .long 0xd6
- .quad LFB43
- .quad LFE43
- .set L$set$784,LLST27-Lsection__debug_loc
- .long L$set$784
- .long 0x19eb
- .byte 0x1d
- .ascii "fd\0"
- .byte 0x1
- .byte 0xe5
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x6c
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$785,LASF30-Lsection__debug_str
- .long L$set$785
- .byte 0x1
- .byte 0xed
- .byte 0x1
- .long 0xd6
- .quad LFB44
- .quad LFE44
- .set L$set$786,LLST28-Lsection__debug_loc
- .long L$set$786
- .long 0x1a2f
- .byte 0x1d
- .ascii "path\0"
- .byte 0x1
- .byte 0xec
- .long 0x601
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x1d
- .ascii "mode\0"
- .byte 0x1
- .byte 0xec
- .long 0x8b3
- .byte 0x2
- .byte 0x91
- .byte 0x64
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$787,LASF31-Lsection__debug_str
- .long L$set$787
- .byte 0x1
- .byte 0xf4
- .byte 0x1
- .long 0xd6
- .quad LFB45
- .quad LFE45
- .set L$set$788,LLST29-Lsection__debug_loc
- .long L$set$788
- .long 0x1a76
- .byte 0x1d
- .ascii "filename\0"
- .byte 0x1
- .byte 0xf3
- .long 0x601
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x1d
- .ascii "buf\0"
- .byte 0x1
- .byte 0xf3
- .long 0x1051
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x0
- .byte 0x1b
- .byte 0x1
- .set L$set$789,LASF32-Lsection__debug_str
- .long L$set$789
- .byte 0x1
- .byte 0xfb
- .byte 0x1
- .long 0xd6
- .quad LFB46
- .quad LFE46
- .set L$set$790,LLST30-Lsection__debug_loc
- .long L$set$790
- .long 0x1ac6
- .byte 0x1d
- .ascii "fildes\0"
- .byte 0x1
- .byte 0xfa
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x6c
- .byte 0x1d
- .ascii "queue_selector\0"
- .byte 0x1
- .byte 0xfa
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x20
- .byte 0x1
- .set L$set$791,LASF33-Lsection__debug_str
- .long L$set$791
- .byte 0x1
- .word 0x102
- .byte 0x1
- .long 0x244
- .quad LFB47
- .quad LFE47
- .set L$set$792,LLST31-Lsection__debug_loc
- .long L$set$792
- .long 0x1b0d
- .byte 0x21
- .set L$set$793,LASF34-Lsection__debug_str
- .long L$set$793
- .byte 0x1
- .word 0x101
- .long 0x1064
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x22
- .ascii "Title\0"
- .byte 0x1
- .word 0x101
- .long 0x1106
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x0
- .byte 0x23
- .byte 0x1
- .set L$set$794,LASF35-Lsection__debug_str
- .long L$set$794
- .byte 0x1
- .word 0x109
- .byte 0x1
- .quad LFB48
- .quad LFE48
- .set L$set$795,LLST32-Lsection__debug_loc
- .long L$set$795
- .long 0x1b3f
- .byte 0x22
- .ascii "__s\0"
- .byte 0x1
- .word 0x108
- .long 0x601
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x20
- .byte 0x1
- .set L$set$796,LASF36-Lsection__debug_str
- .long L$set$796
- .byte 0x1
- .word 0x115
- .byte 0x1
- .long 0xd6
- .quad LFB49
- .quad LFE49
- .set L$set$797,LLST33-Lsection__debug_loc
- .long L$set$797
- .long 0x1b9f
- .byte 0x22
- .ascii "fd\0"
- .byte 0x1
- .word 0x114
- .long 0xd6
- .byte 0x3
- .byte 0x91
- .byte 0x9c,0x7e
- .byte 0x22
- .ascii "__request\0"
- .byte 0x1
- .word 0x114
- .long 0x33d
- .byte 0x3
- .byte 0x91
- .byte 0x90,0x7e
- .byte 0x24
- .byte 0x25
- .ascii "Marker\0"
- .byte 0x1
- .word 0x116
- .long 0x193
- .byte 0x3
- .byte 0x91
- .byte 0xa0,0x7e
- .byte 0x0
- .byte 0x20
- .byte 0x1
- .set L$set$798,LASF37-Lsection__debug_str
- .long L$set$798
- .byte 0x1
- .word 0x11f
- .byte 0x1
- .long 0xd6
- .quad LFB50
- .quad LFE50
- .set L$set$799,LLST34-Lsection__debug_loc
- .long L$set$799
- .long 0x1bfd
- .byte 0x22
- .ascii "__fd\0"
- .byte 0x1
- .word 0x11e
- .long 0xd6
- .byte 0x3
- .byte 0x91
- .byte 0x9c,0x7e
- .byte 0x22
- .ascii "__cmd\0"
- .byte 0x1
- .word 0x11e
- .long 0xd6
- .byte 0x3
- .byte 0x91
- .byte 0x98,0x7e
- .byte 0x24
- .byte 0x25
- .ascii "Marker\0"
- .byte 0x1
- .word 0x120
- .long 0x193
- .byte 0x3
- .byte 0x91
- .byte 0xa0,0x7e
- .byte 0x0
- .byte 0x20
- .byte 0x1
- .set L$set$800,LASF38-Lsection__debug_str
- .long L$set$800
- .byte 0x1
- .word 0x12a
- .byte 0x1
- .long 0xd6
- .quad LFB51
- .quad LFE51
- .set L$set$801,LLST35-Lsection__debug_loc
- .long L$set$801
- .long 0x1c46
- .byte 0x21
- .set L$set$802,LASF39-Lsection__debug_str
- .long L$set$802
- .byte 0x1
- .word 0x129
- .long 0x1111
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x22
- .ascii "__speed\0"
- .byte 0x1
- .word 0x129
- .long 0x35f
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x0
- .byte 0x20
- .byte 0x1
- .set L$set$803,LASF40-Lsection__debug_str
- .long L$set$803
- .byte 0x1
- .word 0x131
- .byte 0x1
- .long 0xd6
- .quad LFB52
- .quad LFE52
- .set L$set$804,LLST36-Lsection__debug_loc
- .long L$set$804
- .long 0x1c8f
- .byte 0x21
- .set L$set$805,LASF39-Lsection__debug_str
- .long L$set$805
- .byte 0x1
- .word 0x130
- .long 0x1111
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x22
- .ascii "__speed\0"
- .byte 0x1
- .word 0x130
- .long 0x35f
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x0
- .byte 0x20
- .byte 0x1
- .set L$set$806,LASF41-Lsection__debug_str
- .long L$set$806
- .byte 0x1
- .word 0x138
- .byte 0x1
- .long 0xd6
- .quad LFB53
- .quad LFE53
- .set L$set$807,LLST37-Lsection__debug_loc
- .long L$set$807
- .long 0x1cd5
- .byte 0x22
- .ascii "__fd\0"
- .byte 0x1
- .word 0x137
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x6c
- .byte 0x21
- .set L$set$808,LASF39-Lsection__debug_str
- .long L$set$808
- .byte 0x1
- .word 0x137
- .long 0x1111
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x0
- .byte 0x20
- .byte 0x1
- .set L$set$809,LASF42-Lsection__debug_str
- .long L$set$809
- .byte 0x1
- .word 0x13f
- .byte 0x1
- .long 0xd6
- .quad LFB54
- .quad LFE54
- .set L$set$810,LLST38-Lsection__debug_loc
- .long L$set$810
- .long 0x1d39
- .byte 0x22
- .ascii "__fd\0"
- .byte 0x1
- .word 0x13e
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x6c
- .byte 0x22
- .ascii "__optional_actions\0"
- .byte 0x1
- .word 0x13e
- .long 0xd6
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x21
- .set L$set$811,LASF39-Lsection__debug_str
- .long L$set$811
- .byte 0x1
- .word 0x13e
- .long 0x1117
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x0
- .byte 0x20
- .byte 0x1
- .set L$set$812,LASF43-Lsection__debug_str
- .long L$set$812
- .byte 0x1
- .word 0x14b
- .byte 0x1
- .long 0x22e
- .quad LFB55
- .quad LFE55
- .set L$set$813,LLST39-Lsection__debug_loc
- .long L$set$813
- .long 0x1d83
- .byte 0x22
- .ascii "Pe32Data\0"
- .byte 0x1
- .word 0x148
- .long 0x226
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x21
- .set L$set$814,LASF0-Lsection__debug_str
- .long L$set$814
- .byte 0x1
- .word 0x14a
- .long 0x326
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x0
- .byte 0x23
- .byte 0x1
- .set L$set$815,LASF44-Lsection__debug_str
- .long L$set$815
- .byte 0x1
- .word 0x155
- .byte 0x1
- .quad LFB56
- .quad LFE56
- .set L$set$816,LLST40-Lsection__debug_loc
- .long L$set$816
- .long 0x1db5
- .byte 0x21
- .set L$set$817,LASF45-Lsection__debug_str
- .long L$set$817
- .byte 0x1
- .word 0x154
- .long 0x112a
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x23
- .byte 0x1
- .set L$set$818,LASF46-Lsection__debug_str
- .long L$set$818
- .byte 0x1
- .word 0x160
- .byte 0x1
- .quad LFB57
- .quad LFE57
- .set L$set$819,LLST41-Lsection__debug_loc
- .long L$set$819
- .long 0x1de7
- .byte 0x21
- .set L$set$820,LASF45-Lsection__debug_str
- .long L$set$820
- .byte 0x1
- .word 0x15f
- .long 0x112a
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x20
- .byte 0x1
- .set L$set$821,LASF47-Lsection__debug_str
- .long L$set$821
- .byte 0x1
- .word 0x16d
- .byte 0x1
- .long 0x244
- .quad LFB58
- .quad LFE58
- .set L$set$822,LLST42-Lsection__debug_loc
- .long L$set$822
- .long 0x1e1d
- .byte 0x21
- .set L$set$823,LASF34-Lsection__debug_str
- .long L$set$823
- .byte 0x1
- .word 0x16c
- .long 0x12b5
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x20
- .byte 0x1
- .set L$set$824,LASF48-Lsection__debug_str
- .long L$set$824
- .byte 0x1
- .word 0x174
- .byte 0x1
- .long 0x244
- .quad LFB59
- .quad LFE59
- .set L$set$825,LLST43-Lsection__debug_loc
- .long L$set$825
- .long 0x1e76
- .byte 0x21
- .set L$set$826,LASF34-Lsection__debug_str
- .long L$set$826
- .byte 0x1
- .word 0x173
- .long 0x12b5
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x22
- .ascii "Width\0"
- .byte 0x1
- .word 0x173
- .long 0xb8
- .byte 0x2
- .byte 0x91
- .byte 0x64
- .byte 0x22
- .ascii "Height\0"
- .byte 0x1
- .word 0x173
- .long 0xb8
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x0
- .byte 0x20
- .byte 0x1
- .set L$set$827,LASF49-Lsection__debug_str
- .long L$set$827
- .byte 0x1
- .word 0x17b
- .byte 0x1
- .long 0x244
- .quad LFB60
- .quad LFE60
- .set L$set$828,LLST44-Lsection__debug_loc
- .long L$set$828
- .long 0x1eac
- .byte 0x21
- .set L$set$829,LASF34-Lsection__debug_str
- .long L$set$829
- .byte 0x1
- .word 0x17a
- .long 0x12b5
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x20
- .byte 0x1
- .set L$set$830,LASF50-Lsection__debug_str
- .long L$set$830
- .byte 0x1
- .word 0x182
- .byte 0x1
- .long 0x244
- .quad LFB61
- .quad LFE61
- .set L$set$831,LLST45-Lsection__debug_loc
- .long L$set$831
- .long 0x1ef1
- .byte 0x21
- .set L$set$832,LASF34-Lsection__debug_str
- .long L$set$832
- .byte 0x1
- .word 0x181
- .long 0x12b5
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x22
- .ascii "key\0"
- .byte 0x1
- .word 0x181
- .long 0x1269
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x0
- .byte 0x20
- .byte 0x1
- .set L$set$833,LASF51-Lsection__debug_str
- .long L$set$833
- .byte 0x1
- .word 0x194
- .byte 0x1
- .long 0x244
- .quad LFB62
- .quad LFE62
- .set L$set$834,LLST46-Lsection__debug_loc
- .long L$set$834
- .long 0x1fde
- .byte 0x21
- .set L$set$835,LASF34-Lsection__debug_str
- .long L$set$835
- .byte 0x1
- .word 0x189
- .long 0x12b5
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x22
- .ascii "BltBuffer\0"
- .byte 0x1
- .word 0x18a
- .long 0x121c
- .byte 0x2
- .byte 0x91
- .byte 0x60
- .byte 0x22
- .ascii "BltOperation\0"
- .byte 0x1
- .word 0x18b
- .long 0x11ff
- .byte 0x2
- .byte 0x91
- .byte 0x5c
- .byte 0x22
- .ascii "SourceX\0"
- .byte 0x1
- .word 0x18c
- .long 0x16b
- .byte 0x2
- .byte 0x91
- .byte 0x50
- .byte 0x22
- .ascii "SourceY\0"
- .byte 0x1
- .word 0x18d
- .long 0x16b
- .byte 0x2
- .byte 0x91
- .byte 0x48
- .byte 0x22
- .ascii "DestinationX\0"
- .byte 0x1
- .word 0x18e
- .long 0x16b
- .byte 0x2
- .byte 0x91
- .byte 0x40
- .byte 0x22
- .ascii "DestinationY\0"
- .byte 0x1
- .word 0x18f
- .long 0x16b
- .byte 0x2
- .byte 0x91
- .byte 0x0
- .byte 0x22
- .ascii "Width\0"
- .byte 0x1
- .word 0x190
- .long 0x16b
- .byte 0x2
- .byte 0x91
- .byte 0x8
- .byte 0x22
- .ascii "Height\0"
- .byte 0x1
- .word 0x191
- .long 0x16b
- .byte 0x2
- .byte 0x91
- .byte 0x10
- .byte 0x22
- .ascii "Delta\0"
- .byte 0x1
- .word 0x193
- .long 0x16b
- .byte 0x2
- .byte 0x91
- .byte 0x18
- .byte 0x0
- .byte 0x5
- .ascii "SET_TIMER_CALLBACK\0"
- .byte 0x1
- .word 0x198
- .long 0xf59
- .byte 0x20
- .byte 0x1
- .set L$set$836,LASF52-Lsection__debug_str
- .long L$set$836
- .byte 0x1
- .word 0x19d
- .byte 0x1
- .long 0x16b
- .quad LFB63
- .quad LFE63
- .set L$set$837,LLST47-Lsection__debug_loc
- .long L$set$837
- .long 0x2059
- .byte 0x22
- .ascii "api\0"
- .byte 0x1
- .word 0x19c
- .long 0x226
- .byte 0x2
- .byte 0x91
- .byte 0x58
- .byte 0x22
- .ascii "a\0"
- .byte 0x1
- .word 0x19c
- .long 0x7f
- .byte 0x2
- .byte 0x91
- .byte 0x50
- .byte 0x25
- .ascii "settimer_callback\0"
- .byte 0x1
- .word 0x19e
- .long 0x1fde
- .byte 0x2
- .byte 0x91
- .byte 0x68
- .byte 0x0
- .byte 0x6
- .long 0xd6
- .long 0x2064
- .byte 0x26
- .byte 0x0
- .byte 0x27
- .ascii "__CFConstantStringClassReference\0"
- .long 0x2059
- .byte 0x1
- .byte 0x1
- .byte 0x1
- .byte 0x28
- .ascii "gUnixRmDir\0"
- .byte 0x1
- .byte 0x18
- .long 0xf8f
- .byte 0x1
- .byte 0x1
- .byte 0x28
- .ascii "gUnixOpenDir\0"
- .byte 0x1
- .byte 0x19
- .long 0xfb6
- .byte 0x1
- .byte 0x1
- .byte 0x28
- .ascii "gUnixStat\0"
- .byte 0x1
- .byte 0x1a
- .long 0xfeb
- .byte 0x1
- .byte 0x1
- .byte 0x28
- .ascii "gUnixStatFs\0"
- .byte 0x1
- .byte 0x1b
- .long 0x101d
- .byte 0x1
- .byte 0x1
- .byte 0x0
- .section __DWARF,__debug_abbrev,regular,debug
- .byte 0x1
- .byte 0x11
- .byte 0x1
- .byte 0x25
- .byte 0x8
- .byte 0x13
- .byte 0xb
- .byte 0x3
- .byte 0x8
- .byte 0x11
- .byte 0x1
- .byte 0x12
- .byte 0x1
- .byte 0x10
- .byte 0x6
- .byte 0x0
- .byte 0x0
- .byte 0x2
- .byte 0x16
- .byte 0x0
- .byte 0x3
- .byte 0x8
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0xb
- .byte 0x49
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0x3
- .byte 0x24
- .byte 0x0
- .byte 0xb
- .byte 0xb
- .byte 0x3e
- .byte 0xb
- .byte 0x3
- .byte 0x8
- .byte 0x0
- .byte 0x0
- .byte 0x4
- .byte 0x24
- .byte 0x0
- .byte 0xb
- .byte 0xb
- .byte 0x3e
- .byte 0xb
- .byte 0x0
- .byte 0x0
- .byte 0x5
- .byte 0x16
- .byte 0x0
- .byte 0x3
- .byte 0x8
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0x5
- .byte 0x49
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0x6
- .byte 0x1
- .byte 0x1
- .byte 0x49
- .byte 0x13
- .byte 0x1
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0x7
- .byte 0x21
- .byte 0x0
- .byte 0x49
- .byte 0x13
- .byte 0x2f
- .byte 0xb
- .byte 0x0
- .byte 0x0
- .byte 0x8
- .byte 0x13
- .byte 0x1
- .byte 0x3
- .byte 0x8
- .byte 0xb
- .byte 0xb
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0xb
- .byte 0x1
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0x9
- .byte 0xd
- .byte 0x0
- .byte 0x3
- .byte 0x8
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0xb
- .byte 0x49
- .byte 0x13
- .byte 0x38
- .byte 0xa
- .byte 0x0
- .byte 0x0
- .byte 0xa
- .byte 0xf
- .byte 0x0
- .byte 0xb
- .byte 0xb
- .byte 0x0
- .byte 0x0
- .byte 0xb
- .byte 0xf
- .byte 0x0
- .byte 0xb
- .byte 0xb
- .byte 0x49
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0xc
- .byte 0x13
- .byte 0x1
- .byte 0xb
- .byte 0xb
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0xb
- .byte 0x1
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0xd
- .byte 0x13
- .byte 0x1
- .byte 0x3
- .byte 0x8
- .byte 0xb
- .byte 0xb
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0x5
- .byte 0x1
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0xe
- .byte 0xd
- .byte 0x0
- .byte 0x3
- .byte 0x8
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0x5
- .byte 0x49
- .byte 0x13
- .byte 0x38
- .byte 0xa
- .byte 0x0
- .byte 0x0
- .byte 0xf
- .byte 0x26
- .byte 0x0
- .byte 0x49
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0x10
- .byte 0x13
- .byte 0x1
- .byte 0x3
- .byte 0x8
- .byte 0xb
- .byte 0x5
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0xb
- .byte 0x1
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0x11
- .byte 0x21
- .byte 0x0
- .byte 0x49
- .byte 0x13
- .byte 0x2f
- .byte 0x5
- .byte 0x0
- .byte 0x0
- .byte 0x12
- .byte 0x13
- .byte 0x0
- .byte 0x3
- .byte 0x8
- .byte 0x3c
- .byte 0xc
- .byte 0x0
- .byte 0x0
- .byte 0x13
- .byte 0x15
- .byte 0x1
- .byte 0x27
- .byte 0xc
- .byte 0x49
- .byte 0x13
- .byte 0x1
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0x14
- .byte 0x5
- .byte 0x0
- .byte 0x49
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0x15
- .byte 0xd
- .byte 0x0
- .byte 0x3
- .byte 0xe
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0xb
- .byte 0x49
- .byte 0x13
- .byte 0x38
- .byte 0xa
- .byte 0x0
- .byte 0x0
- .byte 0x16
- .byte 0x15
- .byte 0x1
- .byte 0x27
- .byte 0xc
- .byte 0x1
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0x17
- .byte 0x26
- .byte 0x0
- .byte 0x0
- .byte 0x0
- .byte 0x18
- .byte 0x26
- .byte 0x0
- .byte 0x3
- .byte 0x8
- .byte 0x49
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0x19
- .byte 0x4
- .byte 0x1
- .byte 0xb
- .byte 0xb
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0xb
- .byte 0x1
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0x1a
- .byte 0x28
- .byte 0x0
- .byte 0x3
- .byte 0x8
- .byte 0x1c
- .byte 0xd
- .byte 0x0
- .byte 0x0
- .byte 0x1b
- .byte 0x2e
- .byte 0x1
- .byte 0x3f
- .byte 0xc
- .byte 0x3
- .byte 0xe
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0xb
- .byte 0x27
- .byte 0xc
- .byte 0x49
- .byte 0x13
- .byte 0x11
- .byte 0x1
- .byte 0x12
- .byte 0x1
- .byte 0x40
- .byte 0x6
- .byte 0x1
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0x1c
- .byte 0x5
- .byte 0x0
- .byte 0x3
- .byte 0xe
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0xb
- .byte 0x49
- .byte 0x13
- .byte 0x2
- .byte 0xa
- .byte 0x0
- .byte 0x0
- .byte 0x1d
- .byte 0x5
- .byte 0x0
- .byte 0x3
- .byte 0x8
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0xb
- .byte 0x49
- .byte 0x13
- .byte 0x2
- .byte 0xa
- .byte 0x0
- .byte 0x0
- .byte 0x1e
- .byte 0x2e
- .byte 0x1
- .byte 0x3f
- .byte 0xc
- .byte 0x3
- .byte 0xe
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0xb
- .byte 0x27
- .byte 0xc
- .byte 0x11
- .byte 0x1
- .byte 0x12
- .byte 0x1
- .byte 0x40
- .byte 0x6
- .byte 0x1
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0x1f
- .byte 0x2e
- .byte 0x0
- .byte 0x3f
- .byte 0xc
- .byte 0x3
- .byte 0xe
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0xb
- .byte 0x27
- .byte 0xc
- .byte 0x49
- .byte 0x13
- .byte 0x11
- .byte 0x1
- .byte 0x12
- .byte 0x1
- .byte 0x40
- .byte 0x6
- .byte 0x0
- .byte 0x0
- .byte 0x20
- .byte 0x2e
- .byte 0x1
- .byte 0x3f
- .byte 0xc
- .byte 0x3
- .byte 0xe
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0x5
- .byte 0x27
- .byte 0xc
- .byte 0x49
- .byte 0x13
- .byte 0x11
- .byte 0x1
- .byte 0x12
- .byte 0x1
- .byte 0x40
- .byte 0x6
- .byte 0x1
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0x21
- .byte 0x5
- .byte 0x0
- .byte 0x3
- .byte 0xe
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0x5
- .byte 0x49
- .byte 0x13
- .byte 0x2
- .byte 0xa
- .byte 0x0
- .byte 0x0
- .byte 0x22
- .byte 0x5
- .byte 0x0
- .byte 0x3
- .byte 0x8
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0x5
- .byte 0x49
- .byte 0x13
- .byte 0x2
- .byte 0xa
- .byte 0x0
- .byte 0x0
- .byte 0x23
- .byte 0x2e
- .byte 0x1
- .byte 0x3f
- .byte 0xc
- .byte 0x3
- .byte 0xe
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0x5
- .byte 0x27
- .byte 0xc
- .byte 0x11
- .byte 0x1
- .byte 0x12
- .byte 0x1
- .byte 0x40
- .byte 0x6
- .byte 0x1
- .byte 0x13
- .byte 0x0
- .byte 0x0
- .byte 0x24
- .byte 0x18
- .byte 0x0
- .byte 0x0
- .byte 0x0
- .byte 0x25
- .byte 0x34
- .byte 0x0
- .byte 0x3
- .byte 0x8
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0x5
- .byte 0x49
- .byte 0x13
- .byte 0x2
- .byte 0xa
- .byte 0x0
- .byte 0x0
- .byte 0x26
- .byte 0x21
- .byte 0x0
- .byte 0x0
- .byte 0x0
- .byte 0x27
- .byte 0x34
- .byte 0x0
- .byte 0x3
- .byte 0x8
- .byte 0x49
- .byte 0x13
- .byte 0x3f
- .byte 0xc
- .byte 0x34
- .byte 0xc
- .byte 0x3c
- .byte 0xc
- .byte 0x0
- .byte 0x0
- .byte 0x28
- .byte 0x34
- .byte 0x0
- .byte 0x3
- .byte 0x8
- .byte 0x3a
- .byte 0xb
- .byte 0x3b
- .byte 0xb
- .byte 0x49
- .byte 0x13
- .byte 0x3f
- .byte 0xc
- .byte 0x3c
- .byte 0xc
- .byte 0x0
- .byte 0x0
- .byte 0x0
- .section __DWARF,__debug_pubnames,regular,debug
- .long 0x3b6
- .word 0x2
- .set L$set$838,Ldebug_info0-Lsection__debug_info
- .long L$set$838
- .long 0x20e0
- .long 0x137a
- .ascii "Gasketrmdir\0"
- .long 0x13ae
- .ascii "Gasketopendir\0"
- .long 0x13e2
- .ascii "Gasketstat\0"
- .long 0x1425
- .ascii "Gasketstatfs\0"
- .long 0x1468
- .ascii "GasketmsSleep\0"
- .long 0x14a1
- .ascii "Gasketexit\0"
- .long 0x14d4
- .ascii "GasketSetTimer\0"
- .long 0x151c
- .ascii "GasketGetLocalTime\0"
- .long 0x154d
- .ascii "Gasketgmtime\0"
- .long 0x1583
- .ascii "GasketGetTimeZone\0"
- .long 0x15a4
- .ascii "GasketGetDayLight\0"
- .long 0x15c5
- .ascii "Gasketpoll\0"
- .long 0x161a
- .ascii "Gasketread\0"
- .long 0x166b
- .ascii "Gasketwrite\0"
- .long 0x16bc
- .ascii "Gasketgetenv\0"
- .long 0x16f1
- .ascii "Gasketopen\0"
- .long 0x1745
- .ascii "Gasketlseek\0"
- .long 0x1797
- .ascii "Gasketftruncate\0"
- .long 0x17d8
- .ascii "Gasketclose\0"
- .long 0x180b
- .ascii "Gasketmkdir\0"
- .long 0x184e
- .ascii "Gasketunlink\0"
- .long 0x1882
- .ascii "GasketGetErrno\0"
- .long 0x18a3
- .ascii "Gasketrewinddir\0"
- .long 0x18d3
- .ascii "Gasketreaddir\0"
- .long 0x1907
- .ascii "Gasketclosedir\0"
- .long 0x193b
- .ascii "Gasketrename\0"
- .long 0x1985
- .ascii "Gasketmktime\0"
- .long 0x19b8
- .ascii "Gasketfsync\0"
- .long 0x19eb
- .ascii "Gasketchmod\0"
- .long 0x1a2f
- .ascii "Gasketutime\0"
- .long 0x1a76
- .ascii "Gaskettcflush\0"
- .long 0x1ac6
- .ascii "GasketUgaCreate\0"
- .long 0x1b0d
- .ascii "Gasketperror\0"
- .long 0x1b3f
- .ascii "Gasketioctl\0"
- .long 0x1b9f
- .ascii "Gasketfcntl\0"
- .long 0x1bfd
- .ascii "Gasketcfsetispeed\0"
- .long 0x1c46
- .ascii "Gasketcfsetospeed\0"
- .long 0x1c8f
- .ascii "Gaskettcgetattr\0"
- .long 0x1cd5
- .ascii "Gaskettcsetattr\0"
- .long 0x1d39
- .ascii "GasketUnixPeCoffGetEntryPoint\0"
- .long 0x1d83
- .ascii "GasketUnixPeCoffRelocateImageExtraAction\0"
- .long 0x1db5
- .ascii "GasketUnixPeCoffUnloadImageExtraAction\0"
- .long 0x1de7
- .ascii "GasketUgaClose\0"
- .long 0x1e1d
- .ascii "GasketUgaSize\0"
- .long 0x1e76
- .ascii "GasketUgaCheckKey\0"
- .long 0x1eac
- .ascii "GasketUgaGetKey\0"
- .long 0x1ef1
- .ascii "GasketUgaBlt\0"
- .long 0x1ff9
- .ascii "ReverseGasketUint64\0"
- .long 0x0
- .section __DWARF,__debug_pubtypes,regular,debug
- .long 0x472
- .word 0x2
- .set L$set$839,Ldebug_info0-Lsection__debug_info
- .long L$set$839
- .long 0x20e0
- .long 0x7f
- .ascii "UINT64\0"
- .long 0xb8
- .ascii "UINT32\0"
- .long 0xdd
- .ascii "UINT16\0"
- .long 0x101
- .ascii "CHAR16\0"
- .long 0x10f
- .ascii "INT16\0"
- .long 0x129
- .ascii "BOOLEAN\0"
- .long 0x149
- .ascii "UINT8\0"
- .long 0x156
- .ascii "CHAR8\0"
- .long 0x16b
- .ascii "UINTN\0"
- .long 0x17b
- .ascii "PHYSICAL_ADDRESS\0"
- .long 0x1b3
- .ascii "__va_list_tag\0"
- .long 0x193
- .ascii "VA_LIST\0"
- .long 0x22e
- .ascii "RETURN_STATUS\0"
- .long 0x244
- .ascii "EFI_STATUS\0"
- .long 0x316
- .ascii "EFI_TIME\0"
- .long 0x32c
- .ascii "tcflag_t\0"
- .long 0x352
- .ascii "cc_t\0"
- .long 0x35f
- .ascii "speed_t\0"
- .long 0x36f
- .ascii "termios\0"
- .long 0x424
- .ascii "__uint8_t\0"
- .long 0x435
- .ascii "__uint16_t\0"
- .long 0x447
- .ascii "__int32_t\0"
- .long 0x458
- .ascii "__uint32_t\0"
- .long 0x46a
- .ascii "__int64_t\0"
- .long 0x47b
- .ascii "__uint64_t\0"
- .long 0x499
- .ascii "__darwin_time_t\0"
- .long 0x4c0
- .ascii "_opaque_pthread_mutex_t\0"
- .long 0x514
- .ascii "__darwin_blkcnt_t\0"
- .long 0x52d
- .ascii "__darwin_blksize_t\0"
- .long 0x547
- .ascii "__darwin_dev_t\0"
- .long 0x55d
- .ascii "__darwin_gid_t\0"
- .long 0x573
- .ascii "__darwin_ino64_t\0"
- .long 0x58b
- .ascii "__darwin_mode_t\0"
- .long 0x5a2
- .ascii "__darwin_off_t\0"
- .long 0x5b8
- .ascii "__darwin_pthread_mutex_t\0"
- .long 0x5d8
- .ascii "__darwin_uid_t\0"
- .long 0x5ee
- .ascii "off_t\0"
- .long 0x60c
- .ascii "timespec\0"
- .long 0x641
- .ascii "time_t\0"
- .long 0x64f
- .ascii "tm\0"
- .long 0x721
- .ascii "dirent\0"
- .long 0x88e
- .ascii "DIR\0"
- .long 0x899
- .ascii "dev_t\0"
- .long 0x8a6
- .ascii "gid_t\0"
- .long 0x8b3
- .ascii "mode_t\0"
- .long 0x8c1
- .ascii "uid_t\0"
- .long 0x8ce
- .ascii "pollfd\0"
- .long 0x90e
- .ascii "int32_t\0"
- .long 0x91d
- .ascii "blkcnt_t\0"
- .long 0x92d
- .ascii "blksize_t\0"
- .long 0x93e
- .ascii "nlink_t\0"
- .long 0x95d
- .ascii "uint32_t\0"
- .long 0x96d
- .ascii "uint64_t\0"
- .long 0x97d
- .ascii "fsid\0"
- .long 0x9a9
- .ascii "fsid_t\0"
- .long 0x9c7
- .ascii "statfs\0"
- .long 0xb11
- .ascii "utimbuf\0"
- .long 0xb45
- .ascii "PE_COFF_LOADER_READ_FILE\0"
- .long 0xdb0
- .ascii "PE_COFF_LOADER_IMAGE_CONTEXT\0"
- .long 0xdd4
- .ascii "stat_fix\0"
- .long 0xf49
- .ascii "STAT_FIX\0"
- .long 0xf8f
- .ascii "UnixRmDir\0"
- .long 0xfb6
- .ascii "UnixOpenDir\0"
- .long 0xfeb
- .ascii "UnixStat\0"
- .long 0x101d
- .ascii "UnixStatFs\0"
- .long 0x1179
- .ascii "EFI_UGA_PIXEL\0"
- .long 0x11ff
- .ascii "EFI_UGA_BLT_OPERATION\0"
- .long 0x1254
- .ascii "EFI_INPUT_KEY\0"
- .long 0x128f
- .ascii "UGAClose\0"
- .long 0x12bb
- .ascii "UGASize\0"
- .long 0x12ea
- .ascii "UGACheckKey\0"
- .long 0x12fd
- .ascii "UGAGetKey\0"
- .long 0x1329
- .ascii "UGABlt\0"
- .long 0x1070
- .ascii "_EFI_UNIX_UGA_IO_PROTOCOL\0"
- .long 0x1fde
- .ascii "SET_TIMER_CALLBACK\0"
- .long 0x0
- .section __DWARF,__debug_aranges,regular,debug
- .long 0x2c
- .word 0x2
- .set L$set$840,Ldebug_info0-Lsection__debug_info
- .long L$set$840
- .byte 0x8
- .byte 0x0
- .word 0x0
- .word 0x0
- .quad Ltext0
- .set L$set$841,Letext0-Ltext0
- .quad L$set$841
- .quad 0x0
- .quad 0x0
- .section __DWARF,__debug_str,regular,debug
-LASF17:
- .ascii "Gasketopen\0"
-LASF18:
- .ascii "Gasketlseek\0"
-LASF48:
- .ascii "GasketUgaSize\0"
-LASF52:
- .ascii "ReverseGasketUint64\0"
-LASF40:
- .ascii "Gasketcfsetospeed\0"
-LASF31:
- .ascii "Gasketutime\0"
-LASF41:
- .ascii "Gaskettcgetattr\0"
-LASF38:
- .ascii "Gasketcfsetispeed\0"
-LASF42:
- .ascii "Gaskettcsetattr\0"
-LASF15:
- .ascii "Gasketwrite\0"
-LASF1:
- .ascii "Gasketrmdir\0"
-LASF43:
- .ascii "GasketUnixPeCoffGetEntryPoint\0"
-LASF36:
- .ascii "Gasketioctl\0"
-LASF39:
- .ascii "__termios_p\0"
-LASF23:
- .ascii "GasketGetErrno\0"
-LASF26:
- .ascii "Gasketclosedir\0"
-LASF44:
- .ascii "GasketUnixPeCoffRelocateImageExtraAction\0"
-LASF13:
- .ascii "Gasketpoll\0"
-LASF49:
- .ascii "GasketUgaCheckKey\0"
-LASF50:
- .ascii "GasketUgaGetKey\0"
-LASF11:
- .ascii "GasketGetTimeZone\0"
-LASF25:
- .ascii "Gasketreaddir\0"
-LASF46:
- .ascii "GasketUnixPeCoffUnloadImageExtraAction\0"
-LASF34:
- .ascii "UgaIo\0"
-LASF12:
- .ascii "GasketGetDayLight\0"
-LASF6:
- .ascii "GasketmsSleep\0"
-LASF51:
- .ascii "GasketUgaBlt\0"
-LASF32:
- .ascii "Gaskettcflush\0"
-LASF22:
- .ascii "Gasketunlink\0"
-LASF27:
- .ascii "Gasketrename\0"
-LASF8:
- .ascii "GasketSetTimer\0"
-LASF24:
- .ascii "Gasketrewinddir\0"
-LASF21:
- .ascii "Gasketmkdir\0"
-LASF4:
- .ascii "Gasketstat\0"
-LASF7:
- .ascii "Gasketexit\0"
-LASF9:
- .ascii "GasketGetLocalTime\0"
-LASF20:
- .ascii "Gasketclose\0"
-LASF35:
- .ascii "Gasketperror\0"
-LASF45:
- .ascii "ImageContext\0"
-LASF2:
- .ascii "Gasketopendir\0"
-LASF28:
- .ascii "Gasketmktime\0"
-LASF30:
- .ascii "Gasketchmod\0"
-LASF37:
- .ascii "Gasketfcntl\0"
-LASF3:
- .ascii "pathname\0"
-LASF0:
- .ascii "EntryPoint\0"
-LASF5:
- .ascii "Gasketstatfs\0"
-LASF33:
- .ascii "GasketUgaCreate\0"
-LASF19:
- .ascii "Gasketftruncate\0"
-LASF16:
- .ascii "Gasketgetenv\0"
-LASF47:
- .ascii "GasketUgaClose\0"
-LASF14:
- .ascii "Gasketread\0"
-LASF10:
- .ascii "Gasketgmtime\0"
-LASF29:
- .ascii "Gasketfsync\0"
- .subsections_via_symbols
-
-#endif
-
diff --git a/UnixPkg/Sec/X64/GasketTemplate.c b/UnixPkg/Sec/X64/GasketTemplate.c
deleted file mode 100644
index 7345e23126..0000000000
--- a/UnixPkg/Sec/X64/GasketTemplate.c
+++ /dev/null
@@ -1,154 +0,0 @@
-/** @file
- Template file used to create Gasket.S
-
- This file is built on the command line via gcc GasketTemplate.c -S
- and it will create GasketTemplate.s and this was used to create
- Gasket.S. This builds code for Unix ABI on both sides. To convert
- to EFI ABI will require changing the code by hand
-
-Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
-Portions copyright (c) 2008 - 2010, Apple Inc. All rights reserved.<BR>
-This program and the accompanying materials
-are licensed and made available under the terms and conditions of the BSD License
-which accompanies this distribution. The full text of the license may be found at
-http://opensource.org/licenses/bsd-license.php
-
-THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
-WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
-
-**/
-
-
-#include <stdint.h>
-#include <sys/stat.h>
-
-typedef int8_t INT8;
-typedef uint8_t UINT8;
-typedef int16_t INT16;
-typedef uint16_t UINT16;
-typedef int32_t INT32;
-typedef uint32_t UINT32;
-typedef int64_t INT64;
-typedef uint64_t UINT64;
-typedef UINT64 UINTN;
-
-
-typedef UINTN (*GASKET_VOID) ();
-typedef UINTN (*GASKET_UINTN) (UINTN);
-typedef UINTN (*GASKET_UINT64) (UINT64);
-typedef UINTN (*GASKET_UINTN_UINTN) (UINTN, UINTN);
-typedef UINTN (*GASKET_UINTN_UINTN_UINTN) (UINTN, UINTN, UINTN);
-typedef UINTN (*GASKET_UINTN_UINTN_UINTN_UINTN) (UINTN, UINTN, UINTN, UINTN);
-typedef UINTN (*GASKET_UINTN_10ARGS) (UINTN, UINTN, UINTN, UINTN, UINTN, UINTN, UINTN, UINTN, UINTN, UINTN);
-typedef UINTN (*GASKET_UINT64_UINTN) (UINT64, UINTN);
-typedef UINT64 (*GASKET_UINTN_UINT64_UINTN) (UINTN, UINT64, UINTN);
-typedef UINTN (*GASKET_UINTN_UINT16) (UINTN, UINT16);
-
-UINTN GasketVoid (void *api);
-UINTN GasketUintn (void *api, UINTN a);
-UINTN GasketUintnUintn (void *api, UINTN a, UINTN b);
-UINTN GasketUintnUintnUintn (void *api, UINTN a, UINTN b, UINTN c);
-UINTN GasketUintnUintnUintnUintn (void *api, UINTN a, UINTN b, UINTN c, UINTN d);
-UINTN GasketUintn10Args (void *api, UINTN a, UINTN b, UINTN c, UINTN d, UINTN e, UINTN f, UINTN g, UINTN h, UINTN i, UINTN j);
-UINTN GasketUint64Uintn (void *api, UINT64 a, UINTN b);
-UINT64 GasketUintnUiny64Uintn (void *api, UINTN a, UINT64 b, UINTN c);
-UINTN GasketUintnUint16 (void *api, UINTN a, UINT16 b);
-
-
-
-UINTN
-GasketVoid (void *api)
-{
- GASKET_VOID func;
-
- func = (GASKET_VOID)api;
- return func ();
-}
-
-UINTN
-GasketUintn (void *api, UINTN a)
-{
- GASKET_UINTN func;
-
- func = (GASKET_UINTN)api;
- return func (a);
-}
-
-UINTN
-GasketUintnUintn (void *api, UINTN a, UINTN b)
-{
- GASKET_UINTN_UINTN func;
-
- func = (GASKET_UINTN_UINTN)api;
- return func (a, b);
-}
-
-
-UINTN
-GasketUintnUintnUintn (void *api, UINTN a, UINTN b, UINTN c)
-{
- GASKET_UINTN_UINTN_UINTN func;
-
- func = (GASKET_UINTN_UINTN_UINTN)api;
- return func (a, b, c);
-}
-
-UINTN
-GasketUintnUintnUintnUintn (void *api, UINTN a, UINTN b, UINTN c, UINTN d)
-{
- GASKET_UINTN_UINTN_UINTN_UINTN func;
-
- func = (GASKET_UINTN_UINTN_UINTN_UINTN)api;
- return func (a, b, c, d);
-}
-
-UINTN
-GasketUintn10Args (void *api, UINTN a, UINTN b, UINTN c, UINTN d, UINTN e, UINTN f, UINTN g, UINTN h, UINTN i, UINTN j)
-{
- GASKET_UINTN_10ARGS func;
-
- func = (GASKET_UINTN_10ARGS)api;
- return func (a, b, c, d, e, f, g, h, i, j);
-}
-
-
-UINTN
-GasketUint64Uintn (void *api, UINT64 a, UINTN b)
-{
- GASKET_UINT64_UINTN func;
-
- func = (GASKET_UINT64_UINTN)api;
- return func (a, b);
-}
-
-UINT64
-GasketUintnUint64Uintn (void *api, UINTN a, UINT64 b, UINTN c)
-{
- GASKET_UINTN_UINT64_UINTN func;
-
- func = (GASKET_UINTN_UINT64_UINTN)api;
- return func (a, b, c);
-}
-
-UINTN
-GasketUintnUint16 (void *api, UINTN a, UINT16 b)
-{
- GASKET_UINTN_UINT16 func;
-
- func = (GASKET_UINTN_UINT16)api;
- return func (a, b);
-}
-
-void
-ReverseGasketUint64 (void *api, UINT64 a)
-{
- GASKET_UINT64 func;
-
- func = (GASKET_UINT64)api;
- func (a);
- return;
-}
-
-
-
-
diff --git a/UnixPkg/Sec/X64/MangleGasket.S b/UnixPkg/Sec/X64/MangleGasket.S
index 383a8830da..532585b608 100644
--- a/UnixPkg/Sec/X64/MangleGasket.S
+++ b/UnixPkg/Sec/X64/MangleGasket.S
@@ -2,14 +2,14 @@
#
# This template was generated from GasketEfiTemplate.c Unix x86_64 ABI
#
-# The EFI_UNIX_THUNK_PROTOCOL member functions call these these generic assembly
-# routines.
+# The EFI_UNIX_THUNK_PROTOCOL member functions call these these generic assembly
+# routines.
#
# Some OS X POSIX calls get name mangled in C code and we need to fill in a C global
# to get the correct binding (does not work from assembly). So we have 4 functions
# that do an indirect call, while the others call POSIX APIs directly
#
-# movq _gUnixRmDir@GOTPCREL(%rip), %rax
+# movq _gUnixRmDir@GOTPCREL(%rip), %rax
#
#
# UNIX Arg passing: RCX, RDX, R8, R9
@@ -38,12 +38,12 @@
// 32 byte shadow to spill rcx-r9, 8 bytes to align stack on 16 byte boundry
// Any call with 0 - 4 arguments allocates 40 bytes on the stack.
-// For more than 4 args you always have to increase in quanta of 16 so 5 or 6 args is 56,
+// For more than 4 args you always have to increase in quanta of 16 so 5 or 6 args is 56,
// 7 or 8 args is 72, and 9 or 10 args is 88
-#define EFI_STACK_SHADOW_SPACE 40
-#define EFI_STACK_SHADOW_SPACE_5_6 56
-#define EFI_STACK_SHADOW_SPACE_7_8 72
-#define EFI_STACK_SHADOW_SPACE_9_10 88
+#define EFI_STACK_SHADOW_SPACE 40
+#define EFI_STACK_SHADOW_SPACE_5_6 56
+#define EFI_STACK_SHADOW_SPACE_7_8 72
+#define EFI_STACK_SHADOW_SPACE_9_10 88
@@ -52,118 +52,148 @@
ASM_GLOBAL ASM_PFX(Gasketrmdir)
ASM_PFX(Gasketrmdir):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
pushq %rdi
- movq %rcx, %rdi // Swizzle args
+ movq %rcx, %rdi // Swizzle args
movq ASM_PFX(gUnixRmDir)@GOTPCREL(%rip), %rax // Get function name mangled by C
movq (%rax), %rax
call *%rax
- pushq %rdi // restore state
- pushq %rsi
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketopendir)
ASM_PFX(Gasketopendir):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
pushq %rdi
- movq %rcx, %rdi // Swizzle args
+ movq %rcx, %rdi // Swizzle args
movq ASM_PFX(gUnixOpenDir)@GOTPCREL(%rip), %rax // Get function name mangled by C
movq (%rax), %rax
call *%rax
-
+
popq %rdi // restore state
popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketstat)
ASM_PFX(Gasketstat):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq ASM_PFX(gUnixStat)@GOTPCREL(%rip), %rax // Get function name mangled by C
movq (%rax), %rax
call *%rax
+
popq %rdi // restore state
popq %rsi
+ popq %rbp
ret
-
-
+
+
ASM_GLOBAL ASM_PFX(Gasketstatfs)
ASM_PFX(Gasketstatfs):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq ASM_PFX(gUnixStatFs)@GOTPCREL(%rip), %rax // Get function name mangled by C
movq (%rax), %rax
call *%rax
-
+
popq %rdi // restore state
popq %rsi
+ popq %rbp
ret
-
+
ASM_GLOBAL ASM_PFX(Gasketrewinddir)
ASM_PFX(Gasketrewinddir):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
movq ASM_PFX(gUnixRewinddir)@GOTPCREL(%rip), %rax // Get function name mangled by C
movq (%rax), %rax
call *%rax
-
+
popq %rdi // restore state
popq %rsi
+ popq %rbp
ret
-
+
ASM_GLOBAL ASM_PFX(Gasketreaddir)
ASM_PFX(Gasketreaddir):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
movq ASM_PFX(gUnixReaddir)@GOTPCREL(%rip), %rax // Get function name mangled by C
movq (%rax), %rax
call *%rax
-
+
popq %rdi // restore state
popq %rsi
+ popq %rbp
ret
-
+
ASM_GLOBAL ASM_PFX(GasketmsSleep)
ASM_PFX(GasketmsSleep):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
pushq %rdi
- movq %rcx, %rdi // Swizzle args
+ movq %rcx, %rdi // Swizzle args
call ASM_PFX(msSleep)
-
+
popq %rdi // restore state
popq %rsi
+ popq %rbp
ret
-
-
+
+
ASM_GLOBAL ASM_PFX(Gasketexit)
ASM_PFX(Gasketexit):
- movq %rcx, %rdi // Swizzle args
+ movq %rcx, %rdi // Swizzle args
call ASM_PFX(exit) // Less to do as we will never return to EFI ABI world
LDEAD_LOOP:
jmp LDEAD_LOOP // _exit should never return
@@ -172,695 +202,1071 @@ LDEAD_LOOP:
ASM_GLOBAL ASM_PFX(GasketSetTimer)
ASM_PFX(GasketSetTimer):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
call ASM_PFX(SetTimer)
-
+
popq %rdi // restore state
popq %rsi
+ popq %rbp
ret
-
+
ASM_GLOBAL ASM_PFX(GasketGetLocalTime)
ASM_PFX(GasketGetLocalTime):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- movq %rcx, %rdi // Swizzle args
+ movq %rcx, %rdi // Swizzle args
call ASM_PFX(GetLocalTime)
- popq %rdi // restore state
- popq %rsi
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
-
+
ASM_GLOBAL ASM_PFX(Gasketgmtime)
ASM_PFX(Gasketgmtime):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
call ASM_PFX(localtime)
- popq %rdi // restore state
- popq %rsi
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(GasketGetTimeZone)
ASM_PFX(GasketGetTimeZone):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
call ASM_PFX(GetTimeZone)
- popq %rdi // restore state
- popq %rsi
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
-
+
ASM_GLOBAL ASM_PFX(GasketGetDayLight)
ASM_PFX(GasketGetDayLight):
-LFB26:
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
call ASM_PFX(GetDayLight)
- popq %rdi // restore state
- popq %rsi
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketpoll)
ASM_PFX(Gasketpoll):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq %r8, %rdx
call ASM_PFX(poll)
- popq %rdi // restore state
- popq %rsi
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketread)
ASM_PFX(Gasketread):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq %r8, %rdx
call ASM_PFX(read)
- popq %rdi // restore state
- popq %rsi
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketwrite)
ASM_PFX(Gasketwrite):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq %r8, %rdx
call ASM_PFX(write)
- popq %rdi // restore state
- popq %rsi
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketgetenv)
ASM_PFX(Gasketgetenv):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- call ASM_PFX(getenv)
+ movq %rcx, %rdi // Swizzle args
- popq %rdi // restore state
- popq %rsi
+ call ASM_PFX(getenv)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketopen)
ASM_PFX(Gasketopen):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq %r8, %rdx
call ASM_PFX(open)
-
- popq %rdi // restore state
- popq %rsi
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketlseek)
ASM_PFX(Gasketlseek):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq %r8, %rdx
call ASM_PFX(lseek)
-
- popq %rdi // restore state
- popq %rsi
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketftruncate)
ASM_PFX(Gasketftruncate):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq %r8, %rdx
call ASM_PFX(ftruncate)
- popq %rdi // restore state
- popq %rsi
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketclose)
ASM_PFX(Gasketclose):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- call ASM_PFX(close)
+ movq %rcx, %rdi // Swizzle args
- popq %rdi // restore state
- popq %rsi
+ call ASM_PFX(close)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketmkdir)
ASM_PFX(Gasketmkdir):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
call ASM_PFX(mkdir)
- popq %rdi // restore state
- popq %rsi
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketunlink)
ASM_PFX(Gasketunlink):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- call ASM_PFX(unlink)
+ movq %rcx, %rdi // Swizzle args
- popq %rdi // restore state
- popq %rsi
+ call ASM_PFX(unlink)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(GasketGetErrno)
ASM_PFX(GasketGetErrno):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- call ASM_PFX(GetErrno)
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- popq %rdi // restore state
- popq %rsi
+ call ASM_PFX(GetErrno)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketclosedir)
ASM_PFX(Gasketclosedir):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
call ASM_PFX(closedir)
- popq %rdi // restore state
- popq %rsi
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketrename)
ASM_PFX(Gasketrename):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
call ASM_PFX(rename)
- popq %rdi // restore state
- popq %rsi
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketmktime)
ASM_PFX(Gasketmktime):
-LFB42:
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
call ASM_PFX(mktime)
- popq %rdi // restore state
- popq %rsi
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketfsync)
ASM_PFX(Gasketfsync):
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
call ASM_PFX(fsync)
- popq %rdi // restore state
- popq %rsi
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketchmod)
ASM_PFX(Gasketchmod):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
call ASM_PFX(chmod)
- popq %rdi // restore state
- popq %rsi
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketutime)
ASM_PFX(Gasketutime):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- call ASM_PFX(utime)
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
- popq %rdi // restore state
- popq %rsi
+ call ASM_PFX(utime)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gaskettcflush)
ASM_PFX(Gaskettcflush):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- call ASM_PFX(tcflush)
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
- popq %rdi // restore state
- popq %rsi
+ call ASM_PFX(tcflush)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(GasketUgaCreate)
ASM_PFX(GasketUgaCreate):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- call ASM_PFX(UgaCreate)
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
- popq %rdi // restore state
- popq %rsi
+ call ASM_PFX(UgaCreate)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketperror)
ASM_PFX(Gasketperror):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- call ASM_PFX(perror)
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
- popq %rdi // restore state
- popq %rsi
+ call ASM_PFX(perror)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketioctl)
ASM_PFX(Gasketioctl):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq %r8, %rdx
call ASM_PFX(UnixIoCtl1)
-
- popq %rdi // restore state
- popq %rsi
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketfcntl)
ASM_PFX(Gasketfcntl):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq %r8, %rdx
call ASM_PFX(UnixFcntl1)
-
- popq %rdi // restore state
- popq %rsi
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketcfsetispeed)
ASM_PFX(Gasketcfsetispeed):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- call ASM_PFX(cfsetispeed)
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
- popq %rdi // restore state
- popq %rsi
+ call ASM_PFX(cfsetispeed)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gasketcfsetospeed)
ASM_PFX(Gasketcfsetospeed):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- call ASM_PFX(cfsetospeed)
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
- popq %rdi // restore state
- popq %rsi
+ call ASM_PFX(cfsetospeed)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gaskettcgetattr)
ASM_PFX(Gaskettcgetattr):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq %r8, %rdx
call ASM_PFX(tcgetattr)
-
- popq %rdi // restore state
- popq %rsi
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(Gaskettcsetattr)
ASM_PFX(Gaskettcsetattr):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq %r8, %rdx
call ASM_PFX(tcsetattr)
-
- popq %rdi // restore state
- popq %rsi
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(GasketUnixPeCoffGetEntryPoint)
ASM_PFX(GasketUnixPeCoffGetEntryPoint):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- call ASM_PFX(SecPeCoffGetEntryPoint)
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
- popq %rdi // restore state
- popq %rsi
+ call ASM_PFX(SecPeCoffGetEntryPoint)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(GasketUnixPeCoffRelocateImageExtraAction)
ASM_PFX(GasketUnixPeCoffRelocateImageExtraAction):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- call ASM_PFX(SecPeCoffRelocateImageExtraAction)
+ movq %rcx, %rdi // Swizzle args
- popq %rdi // restore state
- popq %rsi
+ call ASM_PFX(SecPeCoffRelocateImageExtraAction)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(GasketUnixPeCoffUnloadImageExtraAction)
ASM_PFX(GasketUnixPeCoffUnloadImageExtraAction):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
call ASM_PFX(SecPeCoffLoaderUnloadImageExtraAction)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
+ ret
- popq %rdi // restore state
- popq %rsi
+
+
+
+
+ASM_GLOBAL ASM_PFX(Gasketsocket)
+ASM_PFX(Gasketsocket):
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
+ movq %r8, %rdx
+
+ call ASM_PFX(socket)
+
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
+ ret
+
+
+
+ASM_GLOBAL ASM_PFX(Gasketgetifaddrs)
+ASM_PFX(Gasketgetifaddrs):
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
+
+ call ASM_PFX(getifaddrs)
+
+
+ popq %rbp
+ popq %rsi
+ popq %rbp
ret
+
+ASM_GLOBAL _Gasketfreeifaddrs
+_Gasketfreeifaddrs:
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
+
+ call _freeifaddrs
+
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
+ ret
+
+
+
+
+
ASM_GLOBAL ASM_PFX(GasketUgaClose)
ASM_PFX(GasketUgaClose):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- call ASM_PFX(UgaClose)
+ movq %rcx, %rdi // Swizzle args
- popq %rdi // restore state
- popq %rsi
+ call ASM_PFX(UgaClose)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
+
+
ASM_GLOBAL ASM_PFX(GasketUgaSize)
ASM_PFX(GasketUgaSize):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq %r8, %rdx
call ASM_PFX(UgaSize)
-
- popq %rdi // restore state
- popq %rsi
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(GasketUgaCheckKey)
ASM_PFX(GasketUgaCheckKey):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- call ASM_PFX(UgaCheckKey)
+ movq %rcx, %rdi // Swizzle args
- popq %rdi // restore state
- popq %rsi
+ call ASM_PFX(UgaCheckKey)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(GasketUgaGetKey)
ASM_PFX(GasketUgaGetKey):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
call ASM_PFX(UgaGetKey)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
+ ret
- popq %rdi // restore state
- popq %rsi
+ASM_GLOBAL ASM_PFX(GasketUgaKeySetState)
+ASM_PFX(GasketUgaKeySetState):
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
+
+ call ASM_PFX(UgaKeySetState)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
+ ret
+
+
+ASM_GLOBAL ASM_PFX(GasketUgaRegisterKeyNotify)
+ASM_PFX(GasketUgaRegisterKeyNotify):
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
+ movq %r8, %rdx
+
+ call ASM_PFX(UgaRegisterKeyNotify)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
+
+
+
ASM_GLOBAL ASM_PFX(GasketUgaBlt)
ASM_PFX(GasketUgaBlt):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq %r8, %rdx
movq %r9, %rcx
call ASM_PFX(UgaBlt)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
+ ret
- popq %rdi // restore state
- popq %rsi
+
+ASM_GLOBAL ASM_PFX(GasketUgaCheckPointer)
+ASM_PFX(GasketUgaCheckPointer):
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
+
+ call ASM_PFX(UgaCheckPointer)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
+ASM_GLOBAL ASM_PFX(GasketUgaGetPointerState)
+ASM_PFX(GasketUgaGetPointerState):
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
+
+ call ASM_PFX(UgaGetPointerState)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
+ ret
+
+
+ASM_GLOBAL ASM_PFX(GasketUnixEnableInterrupt)
+ASM_PFX(GasketUnixEnableInterrupt):
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ call ASM_PFX(UnixEnableInterrupt)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
+ ret
+
+ASM_GLOBAL ASM_PFX(GasketUnixDisableInterrupt)
+ASM_PFX(GasketUnixDisableInterrupt):
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ call ASM_PFX(UnixDisableInterrupt)
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
+ ret
+
//
// UNIX ABI to EFI ABI call
//
// UINTN
// ReverseGasketUint64 (
// void *Api,
-// UINTN Arg1,
-// UINTN Arg2,
-// UINTN Arg3
+// UINTN Arg1
// );
ASM_GLOBAL ASM_PFX(ReverseGasketUint64)
ASM_PFX(ReverseGasketUint64):
- movq %rdi, %rax // Swizzle args
- movq %rsi, %r9
-// movq %rdx, %rdx
- movq %rcx, %r8
- movq %r9, %rcx
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- subq $40, %rsp // 32-byte shadow space plus alignment pad
- call *%rax
- addq $40, %rsp
+ movq %rdi, %rax // Swizzle args
+ movq %rsi, %rcx
- ret
+ subq $32, %rsp // 32-byte shadow space
+ call *%rax
+ addq $32, %rsp
+ popq %rbp
+ ret
+
+//
+// UNIX ABI to EFI ABI call
+//
+// UINTN
+// ReverseGasketUint64Uint64 (
+// void *Api,
+// UINTN Arg1
+// UINTN Arg2
+// );
+ASM_GLOBAL ASM_PFX(ReverseGasketUint64Uint64)
+ASM_PFX(ReverseGasketUint64Uint64):
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ movq %rdi, %rax // Swizzle args
+ movq %rsi, %rcx
+
+ subq $32, %rsp // 32-byte shadow space
+ call *%rax
+ addq $32, %rsp
+
+ popq %rbp
+ ret
+
// Sec PPI Callbacks
ASM_GLOBAL ASM_PFX(GasketSecUnixPeiLoadFile)
ASM_PFX(GasketSecUnixPeiLoadFile):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq %r8, %rdx
movq %r9, %rcx
call ASM_PFX(SecUnixPeiLoadFile)
-
- popq %rdi // restore state
- popq %rsi
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(GasketSecUnixPeiAutoScan)
ASM_PFX(GasketSecUnixPeiAutoScan):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq %r8, %rdx
call ASM_PFX(SecUnixPeiAutoScan)
-
- popq %rdi // restore state
- popq %rsi
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(GasketSecUnixUnixThunkAddress)
ASM_PFX(GasketSecUnixUnixThunkAddress):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
call ASM_PFX(SecUnixUnixThunkAddress)
+
- popq %rdi // restore state
+ popq %rdi
popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(GasketSecPeiReportStatusCode)
ASM_PFX(GasketSecPeiReportStatusCode):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq %r8, %rdx
movq %r9, %rcx
movq $0, %r8 // BugBug: This should come from the stack
movq $0, %r9 // But we can cheat since they are optional for bringup....
call ASM_PFX(SecPeiReportStatusCode)
-
- popq %rdi // restore state
- popq %rsi
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
ASM_GLOBAL ASM_PFX(GasketSecUnixFdAddress)
ASM_PFX(GasketSecUnixFdAddress):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
+
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq %r8, %rdx
movq %r9, %rcx
call ASM_PFX(SecUnixFdAddress)
- popq %rdi // restore state
- popq %rsi
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
@@ -868,18 +1274,22 @@ ASM_PFX(GasketSecUnixFdAddress):
ASM_GLOBAL ASM_PFX(GasketSecTemporaryRamSupport)
ASM_PFX(GasketSecTemporaryRamSupport):
- pushq %rsi // %rsi & %rdi are volatie in Unix and callee-save in EFI ABI
- pushq %rdi
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
+ pushq %rsi // %rsi & %rdi are volatile in Unix and callee-save in EFI ABI
+ pushq %rdi
- movq %rcx, %rdi // Swizzle args
- movq %rdx, %rsi
+ movq %rcx, %rdi // Swizzle args
+ movq %rdx, %rsi
movq %r8, %rdx
movq %r9, %rcx
call ASM_PFX(SecTemporaryRamSupport)
-
- popq %rdi // restore state
- popq %rsi
+
+ popq %rdi // restore state
+ popq %rsi
+ popq %rbp
ret
diff --git a/UnixPkg/Sec/X64/SwitchStack.S b/UnixPkg/Sec/X64/SwitchStack.S
index dfb618b395..e964e4d178 100644
--- a/UnixPkg/Sec/X64/SwitchStack.S
+++ b/UnixPkg/Sec/X64/SwitchStack.S
@@ -39,7 +39,9 @@
#------------------------------------------------------------------------------
ASM_GLOBAL ASM_PFX(PeiSwitchStacks)
ASM_PFX(PeiSwitchStacks):
-// movq %rdx, %rdx
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
movq %r8, %rsp
movq %rdi, %rax
@@ -50,7 +52,7 @@ ASM_PFX(PeiSwitchStacks):
# Reserve space for register parameters (rcx, rdx, r8 & r9) on the stack,
# in case the callee wishes to spill them.
#
- subq $40, %rsp // 32-byte shadow space plus alignment pad
+ subq $32, %rsp // 32-byte shadow space plus alignment pad
call *%rax
@@ -74,6 +76,9 @@ ASM_PFX(PeiSwitchStacks):
#------------------------------------------------------------------------------
ASM_GLOBAL ASM_PFX(UnixPeiSwitchStacks)
ASM_PFX(UnixPeiSwitchStacks):
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
+
mov %rdi, %rax
mov %rsi, %rdi
mov %rdx, %rsi
@@ -100,12 +105,16 @@ ASM_PFX(UnixPeiSwitchStacks):
#------------------------------------------------------------------------------
ASM_GLOBAL ASM_PFX(SecSwitchStack)
ASM_PFX(SecSwitchStack):
+ pushq %rbp // stack frame is for the debugger
+ movq %rsp, %rbp
mov %rsp, %rax
sub %rdi, %rax
add %rsi, %rax
mov (%rip), %r10
mov %r10, (%rax)
+
+ popq %rbp
ret
\ No newline at end of file
diff --git a/UnixPkg/UnixBusDriverDxe/UnixBusDriver.c b/UnixPkg/UnixBusDriverDxe/UnixBusDriver.c
index 00c0414211..52618d73a0 100644
--- a/UnixPkg/UnixBusDriverDxe/UnixBusDriver.c
+++ b/UnixPkg/UnixBusDriverDxe/UnixBusDriver.c
@@ -15,7 +15,7 @@ Module Name:
Abstract:
-This following section documents the envirnoment variables for the Win UNIX
+This following section documents the environment variables for the UNIX
build. These variables are used to define the (virtual) hardware
configuration of the UNIX environment
@@ -118,15 +118,17 @@ EFI_DRIVER_BINDING_PROTOCOL gUnixBusDriverBinding = {
// device path.
//
UNIX_PCD_ENTRY mPcdEnvironment[] = {
- {PcdToken(PcdUnixConsole), &gEfiUnixConsoleGuid},
- {PcdToken(PcdUnixUga), &gEfiUnixUgaGuid},
- {PcdToken(PcdUnixFileSystem), &gEfiUnixFileSystemGuid},
- {PcdToken(PcdUnixSerialPort), &gEfiUnixSerialPortGuid},
- {PcdToken(PcdUnixVirtualDisk), &gEfiUnixVirtualDisksGuid},
- {PcdToken(PcdUnixPhysicalDisk), &gEfiUnixPhysicalDisksGuid},
- {PcdToken(PcdUnixCpuModel), &gEfiUnixCPUModelGuid},
- {PcdToken(PcdUnixCpuSpeed), &gEfiUnixCPUSpeedGuid},
- {PcdToken(PcdUnixMemorySize), &gEfiUnixMemoryGuid}
+ {PcdToken(PcdUnixConsole), &gEfiUnixConsoleGuid},
+ {PcdToken(PcdUnixUga), &gEfiUnixUgaGuid},
+ {PcdToken(PcdUnixGop), &gEfiUnixGopGuid},
+ {PcdToken(PcdUnixFileSystem), &gEfiUnixFileSystemGuid},
+ {PcdToken(PcdUnixSerialPort), &gEfiUnixSerialPortGuid},
+ {PcdToken(PcdUnixVirtualDisk), &gEfiUnixVirtualDisksGuid},
+ {PcdToken(PcdUnixPhysicalDisk), &gEfiUnixPhysicalDisksGuid},
+ {PcdToken(PcdUnixCpuModel), &gEfiUnixCPUModelGuid},
+ {PcdToken(PcdUnixCpuSpeed), &gEfiUnixCPUSpeedGuid},
+ {PcdToken(PcdUnixMemorySize), &gEfiUnixMemoryGuid},
+ {PcdToken(PcdUnixNetworkInterface), &gEfiUnixNetworkGuid}
};
VOID *
@@ -168,13 +170,6 @@ Returns:
None
--*/
-// TODO: This - add argument and description to function comment
-// TODO: ControllerHandle - add argument and description to function comment
-// TODO: RemainingDevicePath - add argument and description to function comment
-// TODO: EFI_UNSUPPORTED - add return value to function comment
-// TODO: EFI_UNSUPPORTED - add return value to function comment
-// TODO: EFI_SUCCESS - add return value to function comment
-// TODO: EFI_SUCCESS - add return value to function comment
{
EFI_STATUS Status;
EFI_DEVICE_PATH_PROTOCOL *ParentDevicePath;
@@ -300,12 +295,6 @@ Returns:
None
--*/
-// TODO: This - add argument and description to function comment
-// TODO: ControllerHandle - add argument and description to function comment
-// TODO: RemainingDevicePath - add argument and description to function comment
-// TODO: EFI_OUT_OF_RESOURCES - add return value to function comment
-// TODO: EFI_OUT_OF_RESOURCES - add return value to function comment
-// TODO: EFI_SUCCESS - add return value to function comment
{
EFI_STATUS Status;
EFI_STATUS InstallStatus;
@@ -403,7 +392,7 @@ Returns:
StartString = TempStr;
//
- // Parse the envirnment variable into sub strings using '!' as a delimator.
+ // Parse the environment variable into sub strings using '!' as a delimator.
// Each substring needs it's own handle to be added to the system. This code
// does not understand the sub string. Thats the device drivers job.
//
@@ -566,13 +555,6 @@ Returns:
None
--*/
-// TODO: This - add argument and description to function comment
-// TODO: ControllerHandle - add argument and description to function comment
-// TODO: NumberOfChildren - add argument and description to function comment
-// TODO: ChildHandleBuffer - add argument and description to function comment
-// TODO: EFI_SUCCESS - add return value to function comment
-// TODO: EFI_DEVICE_ERROR - add return value to function comment
-// TODO: EFI_SUCCESS - add return value to function comment
{
EFI_STATUS Status;
UINTN Index;
diff --git a/UnixPkg/UnixBusDriverDxe/UnixBusDriver.inf b/UnixPkg/UnixBusDriverDxe/UnixBusDriver.inf
index bf83906cb2..b5eb940f42 100644
--- a/UnixPkg/UnixBusDriverDxe/UnixBusDriver.inf
+++ b/UnixPkg/UnixBusDriverDxe/UnixBusDriver.inf
@@ -61,6 +61,7 @@
[Guids]
gEfiUnixConsoleGuid # ALWAYS_CONSUMED
gEfiUnixUgaGuid # ALWAYS_CONSUMED
+ gEfiUnixGopGuid # ALWAYS_CONSUMED
gEfiUnixSerialPortGuid # ALWAYS_CONSUMED
gEfiUnixFileSystemGuid # ALWAYS_CONSUMED
gEfiUnixPhysicalDisksGuid # ALWAYS_CONSUMED
@@ -68,6 +69,7 @@
gEfiUnixCPUModelGuid
gEfiUnixCPUSpeedGuid
gEfiUnixMemoryGuid
+ gEfiUnixNetworkGuid
[Protocols]
@@ -86,5 +88,7 @@
gEfiUnixPkgTokenSpaceGuid.PcdUnixVirtualDisk
gEfiUnixPkgTokenSpaceGuid.PcdUnixFileSystem
gEfiUnixPkgTokenSpaceGuid.PcdUnixUga
+ gEfiUnixPkgTokenSpaceGuid.PcdUnixGop
gEfiUnixPkgTokenSpaceGuid.PcdUnixConsole
+ gEfiUnixPkgTokenSpaceGuid.PcdUnixNetworkInterface
diff --git a/UnixPkg/UnixGopDxe/ComponentName.c b/UnixPkg/UnixGopDxe/ComponentName.c
new file mode 100644
index 0000000000..e57e85d159
--- /dev/null
+++ b/UnixPkg/UnixGopDxe/ComponentName.c
@@ -0,0 +1,251 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation. All rights reserved.<BR>
+Portions copyright (c) 2010, Apple, Inc. All rights reserved.
+This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ ComponentName.c
+
+Abstract:
+
+--*/
+
+#include "UnixGop.h"
+
+//
+// EFI Component Name Functions
+//
+EFI_STATUS
+EFIAPI
+UnixGopComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+EFI_STATUS
+EFIAPI
+UnixGopComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
+//
+// EFI Component Name Protocol
+//
+EFI_COMPONENT_NAME_PROTOCOL gUnixGopComponentName = {
+ UnixGopComponentNameGetDriverName,
+ UnixGopComponentNameGetControllerName,
+ "eng"
+};
+
+//
+// EFI Component Name 2 Protocol
+//
+GLOBAL_REMOVE_IF_UNREFERENCED EFI_COMPONENT_NAME2_PROTOCOL gUnixGopComponentName2 = {
+ (EFI_COMPONENT_NAME2_GET_DRIVER_NAME) UnixGopComponentNameGetDriverName,
+ (EFI_COMPONENT_NAME2_GET_CONTROLLER_NAME) UnixGopComponentNameGetControllerName,
+ "en"
+};
+
+
+EFI_UNICODE_STRING_TABLE mUnixGopDriverNameTable[] = {
+ { "eng", L"Unix GOP Driver" },
+ { NULL , NULL }
+};
+
+
+/**
+ Retrieves a Unicode string that is the user readable name of the driver.
+
+ This function retrieves the user readable name of a driver in the form of a
+ Unicode string. If the driver specified by This has a user readable name in
+ the language specified by Language, then a pointer to the driver name is
+ returned in DriverName, and EFI_SUCCESS is returned. If the driver specified
+ by This does not support the language specified by Language,
+ then EFI_UNSUPPORTED is returned.
+
+ @param This[in] A pointer to the EFI_COMPONENT_NAME2_PROTOCOL or
+ EFI_COMPONENT_NAME_PROTOCOL instance.
+
+ @param Language[in] A pointer to a Null-terminated ASCII string
+ array indicating the language. This is the
+ language of the driver name that the caller is
+ requesting, and it must match one of the
+ languages specified in SupportedLanguages. The
+ number of languages supported by a driver is up
+ to the driver writer. Language is specified
+ in RFC 4646 or ISO 639-2 language code format.
+
+ @param DriverName[out] A pointer to the Unicode string to return.
+ This Unicode string is the name of the
+ driver specified by This in the language
+ specified by Language.
+
+ @retval EFI_SUCCESS The Unicode string for the Driver specified by
+ This and the language specified by Language was
+ returned in DriverName.
+
+ @retval EFI_INVALID_PARAMETER Language is NULL.
+
+ @retval EFI_INVALID_PARAMETER DriverName is NULL.
+
+ @retval EFI_UNSUPPORTED The driver specified by This does not support
+ the language specified by Language.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixGopComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ )
+{
+ return LookupUnicodeString2 (
+ Language,
+ This->SupportedLanguages,
+ mUnixGopDriverNameTable,
+ DriverName,
+ (BOOLEAN)(This == &gUnixGopComponentName)
+ );
+}
+
+
+/**
+ Retrieves a Unicode string that is the user readable name of the controller
+ that is being managed by a driver.
+
+ This function retrieves the user readable name of the controller specified by
+ ControllerHandle and ChildHandle in the form of a Unicode string. If the
+ driver specified by This has a user readable name in the language specified by
+ Language, then a pointer to the controller name is returned in ControllerName,
+ and EFI_SUCCESS is returned. If the driver specified by This is not currently
+ managing the controller specified by ControllerHandle and ChildHandle,
+ then EFI_UNSUPPORTED is returned. If the driver specified by This does not
+ support the language specified by Language, then EFI_UNSUPPORTED is returned.
+
+ @param This[in] A pointer to the EFI_COMPONENT_NAME2_PROTOCOL or
+ EFI_COMPONENT_NAME_PROTOCOL instance.
+
+ @param ControllerHandle[in] The handle of a controller that the driver
+ specified by This is managing. This handle
+ specifies the controller whose name is to be
+ returned.
+
+ @param ChildHandle[in] The handle of the child controller to retrieve
+ the name of. This is an optional parameter that
+ may be NULL. It will be NULL for device
+ drivers. It will also be NULL for a bus drivers
+ that wish to retrieve the name of the bus
+ controller. It will not be NULL for a bus
+ driver that wishes to retrieve the name of a
+ child controller.
+
+ @param Language[in] A pointer to a Null-terminated ASCII string
+ array indicating the language. This is the
+ language of the driver name that the caller is
+ requesting, and it must match one of the
+ languages specified in SupportedLanguages. The
+ number of languages supported by a driver is up
+ to the driver writer. Language is specified in
+ RFC 4646 or ISO 639-2 language code format.
+
+ @param ControllerName[out] A pointer to the Unicode string to return.
+ This Unicode string is the name of the
+ controller specified by ControllerHandle and
+ ChildHandle in the language specified by
+ Language from the point of view of the driver
+ specified by This.
+
+ @retval EFI_SUCCESS The Unicode string for the user readable name in
+ the language specified by Language for the
+ driver specified by This was returned in
+ DriverName.
+
+ @retval EFI_INVALID_PARAMETER ControllerHandle is not a valid EFI_HANDLE.
+
+ @retval EFI_INVALID_PARAMETER ChildHandle is not NULL and it is not a valid
+ EFI_HANDLE.
+
+ @retval EFI_INVALID_PARAMETER Language is NULL.
+
+ @retval EFI_INVALID_PARAMETER ControllerName is NULL.
+
+ @retval EFI_UNSUPPORTED The driver specified by This is not currently
+ managing the controller specified by
+ ControllerHandle and ChildHandle.
+
+ @retval EFI_UNSUPPORTED The driver specified by This does not support
+ the language specified by Language.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixGopComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ )
+{
+ EFI_STATUS Status;
+ EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput;
+ GOP_PRIVATE_DATA *Private;
+
+ //
+ // This is a device driver, so ChildHandle must be NULL.
+ //
+ if (ChildHandle != NULL) {
+ return EFI_UNSUPPORTED;
+ }
+
+ //
+ // Make sure this driver is currently managing ControllerHandle
+ //
+ Status = EfiTestManagedDevice (
+ ControllerHandle,
+ gUnixGopDriverBinding.DriverBindingHandle,
+ &gEfiUnixIoProtocolGuid
+ );
+ if (EFI_ERROR (Status)) {
+ return EFI_UNSUPPORTED;
+ }
+ //
+ // Get our context back
+ //
+ Status = gBS->OpenProtocol (
+ ControllerHandle,
+ &gEfiGraphicsOutputProtocolGuid,
+ (VOID **)&GraphicsOutput,
+ gUnixGopDriverBinding.DriverBindingHandle,
+ ControllerHandle,
+ EFI_OPEN_PROTOCOL_GET_PROTOCOL
+ );
+ if (EFI_ERROR (Status)) {
+ return EFI_UNSUPPORTED;
+ }
+
+ Private = GOP_PRIVATE_DATA_FROM_THIS (GraphicsOutput);
+
+ return LookupUnicodeString2 (
+ Language,
+ This->SupportedLanguages,
+ Private->ControllerNameTable,
+ ControllerName,
+ (BOOLEAN)(This == &gUnixGopComponentName)
+ );
+
+}
diff --git a/UnixPkg/UnixGopDxe/UnixGop.h b/UnixPkg/UnixGopDxe/UnixGop.h
new file mode 100644
index 0000000000..16232e5446
--- /dev/null
+++ b/UnixPkg/UnixGopDxe/UnixGop.h
@@ -0,0 +1,377 @@
+/*++
+
+Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
+Portions copyright (c) 2010, Apple, Inc. All rights reserved.
+This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ UnixGop.h
+
+Abstract:
+
+ Private data for the Gop driver that is bound to the Unix Thunk protocol
+
+--*/
+
+#ifndef _UNIX_UGA_H_
+#define _UNIX_UGA_H_
+
+#include <PiDxe.h>
+#include "UnixDxe.h"
+#include <Library/DebugLib.h>
+#include <Library/BaseLib.h>
+#include <Library/UefiDriverEntryPoint.h>
+#include <Library/UefiLib.h>
+#include <Library/BaseMemoryLib.h>
+#include <Library/MemoryAllocationLib.h>
+#include <Library/UefiBootServicesTableLib.h>
+
+#include <Protocol/GraphicsOutput.h>
+#include <Protocol/SimpleTextIn.h>
+#include <Protocol/SimpleTextInEx.h>
+#include <Protocol/SimplePointer.h>
+#include "Protocol/UnixUgaIo.h"
+
+#include <Guid/EventGroup.h>
+
+
+
+#define MAX_Q 256
+
+typedef struct {
+ UINTN Front;
+ UINTN Rear;
+ UINTN Count;
+ EFI_INPUT_KEY Q[MAX_Q];
+} GOP_QUEUE_FIXED;
+
+#define UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY_SIGNATURE SIGNATURE_32 ('U', 'g', 'S', 'n')
+typedef struct _UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY {
+ UINTN Signature;
+ EFI_HANDLE NotifyHandle;
+ EFI_KEY_DATA KeyData;
+ EFI_KEY_NOTIFY_FUNCTION KeyNotificationFn;
+ EFI_EVENT Event;
+ LIST_ENTRY NotifyEntry;
+} UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY;
+
+#define GRAPHICS_OUTPUT_INVALIDE_MODE_NUMBER 0xffff
+
+typedef struct {
+ UINT32 HorizontalResolution;
+ UINT32 VerticalResolution;
+ UINT32 ColorDepth;
+ UINT32 RefreshRate;
+} GOP_MODE_DATA;
+
+
+
+extern EFI_DRIVER_BINDING_PROTOCOL gUnixGopDriverBinding;
+extern EFI_COMPONENT_NAME_PROTOCOL gUnixGopComponentName;
+
+#define UNIX_UGA_CLASS_NAME L"UnixGopWindow"
+
+#define GOP_PRIVATE_DATA_SIGNATURE SIGNATURE_32 ('G', 'o', 'p', 'N')
+typedef struct {
+ UINT64 Signature;
+
+ EFI_HANDLE Handle;
+ EFI_GRAPHICS_OUTPUT_PROTOCOL GraphicsOutput;
+ EFI_SIMPLE_TEXT_INPUT_PROTOCOL SimpleTextIn;
+ EFI_SIMPLE_POINTER_PROTOCOL SimplePointer;
+
+ EFI_UNIX_THUNK_PROTOCOL *UnixThunk;
+ EFI_UNIX_UGA_IO_PROTOCOL *UgaIo;
+
+ EFI_UNICODE_STRING_TABLE *ControllerNameTable;
+
+ EFI_SIMPLE_POINTER_MODE PointerMode;
+ //
+ // GOP Private Data for QueryMode ()
+ //
+ GOP_MODE_DATA *ModeData;
+
+
+ //
+ // UGA Private Data knowing when to start hardware
+ //
+ BOOLEAN HardwareNeedsStarting;
+
+ CHAR16 *WindowName;
+
+ GOP_QUEUE_FIXED Queue;
+
+ EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL SimpleTextInEx;
+ EFI_KEY_STATE KeyState;
+ LIST_ENTRY NotifyList;
+
+
+} GOP_PRIVATE_DATA;
+
+
+#define GOP_PRIVATE_DATA_FROM_THIS(a) \
+ CR(a, GOP_PRIVATE_DATA, GraphicsOutput, GOP_PRIVATE_DATA_SIGNATURE)
+
+#define GOP_PRIVATE_DATA_FROM_TEXT_IN_THIS(a) \
+ CR(a, GOP_PRIVATE_DATA, SimpleTextIn, GOP_PRIVATE_DATA_SIGNATURE)
+
+#define GOP_PRIVATE_DATA_FROM_TEXT_IN_EX_THIS(a) \
+ CR(a, GOP_PRIVATE_DATA, SimpleTextInEx, GOP_PRIVATE_DATA_SIGNATURE)
+
+#define GOP_PRIVATE_DATA_FROM_POINTER_MODE_THIS(a) \
+ CR(a, GOP_PRIVATE_DATA, SimplePointer, GOP_PRIVATE_DATA_SIGNATURE)
+
+
+//
+// Global Protocol Variables
+//
+extern EFI_DRIVER_BINDING_PROTOCOL gUnixGopDriverBinding;
+extern EFI_COMPONENT_NAME_PROTOCOL gUnixGopComponentName;
+extern EFI_COMPONENT_NAME2_PROTOCOL gUnixGopComponentName2;
+
+//
+// Gop Hardware abstraction internal worker functions
+//
+EFI_STATUS
+UnixGopSupported (
+ IN EFI_UNIX_IO_PROTOCOL *UnixIo
+ )
+/*++
+
+Routine Description:
+
+ TODO: Add function description
+
+Arguments:
+
+ UnixIo - TODO: add argument description
+
+Returns:
+
+ TODO: add return values
+
+--*/
+;
+
+EFI_STATUS
+UnixGopConstructor (
+ IN GOP_PRIVATE_DATA *Private
+ )
+/*++
+
+Routine Description:
+
+ TODO: Add function description
+
+Arguments:
+
+ Private - TODO: add argument description
+
+Returns:
+
+ TODO: add return values
+
+--*/
+;
+
+EFI_STATUS
+UnixGopDestructor (
+ IN GOP_PRIVATE_DATA *Private
+ )
+/*++
+
+Routine Description:
+
+ TODO: Add function description
+
+Arguments:
+
+ Private - TODO: add argument description
+
+Returns:
+
+ TODO: add return values
+
+--*/
+;
+
+//
+// EFI 1.1 driver model prototypes for Win UNIX UGA
+//
+
+EFI_STATUS
+EFIAPI
+UnixGopInitialize (
+ IN EFI_HANDLE ImageHandle,
+ IN EFI_SYSTEM_TABLE *SystemTable
+ )
+/*++
+
+Routine Description:
+
+ TODO: Add function description
+
+Arguments:
+
+ ImageHandle - TODO: add argument description
+ SystemTable - TODO: add argument description
+
+Returns:
+
+ TODO: add return values
+
+--*/
+;
+
+EFI_STATUS
+EFIAPI
+UnixGopDriverBindingSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Handle,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ )
+/*++
+
+Routine Description:
+
+ TODO: Add function description
+
+Arguments:
+
+ This - TODO: add argument description
+ Handle - TODO: add argument description
+ RemainingDevicePath - TODO: add argument description
+
+Returns:
+
+ TODO: add return values
+
+--*/
+;
+
+EFI_STATUS
+EFIAPI
+UnixGopDriverBindingStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Handle,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ )
+/*++
+
+Routine Description:
+
+ TODO: Add function description
+
+Arguments:
+
+ This - TODO: add argument description
+ Handle - TODO: add argument description
+ RemainingDevicePath - TODO: add argument description
+
+Returns:
+
+ TODO: add return values
+
+--*/
+;
+
+EFI_STATUS
+EFIAPI
+UnixGopDriverBindingStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Handle,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ )
+/*++
+
+Routine Description:
+
+ TODO: Add function description
+
+Arguments:
+
+ This - TODO: add argument description
+ Handle - TODO: add argument description
+ NumberOfChildren - TODO: add argument description
+ ChildHandleBuffer - TODO: add argument description
+
+Returns:
+
+ TODO: add return values
+
+--*/
+;
+
+EFI_STATUS
+GopPrivateAddQ (
+ IN GOP_PRIVATE_DATA *Private,
+ IN EFI_INPUT_KEY Key
+ )
+/*++
+
+Routine Description:
+
+ TODO: Add function description
+
+Arguments:
+
+ Private - TODO: add argument description
+ Key - TODO: add argument description
+
+Returns:
+
+ TODO: add return values
+
+--*/
+;
+
+EFI_STATUS
+UnixGopInitializeSimpleTextInForWindow (
+ IN GOP_PRIVATE_DATA *Private
+ )
+/*++
+
+Routine Description:
+
+ TODO: Add function description
+
+Arguments:
+
+ Private - TODO: add argument description
+
+Returns:
+
+ TODO: add return values
+
+--*/
+;
+
+EFI_STATUS
+UnixGopInitializeSimplePointerForWindow (
+ IN GOP_PRIVATE_DATA *Private
+ )
+/*++
+
+Routine Description:
+
+ TODO: Add function description
+
+Arguments:
+
+ Private - TODO: add argument description
+
+Returns:
+
+ TODO: add return values
+
+--*/
+;
+#endif
diff --git a/UnixPkg/UnixGopDxe/UnixGop.inf b/UnixPkg/UnixGopDxe/UnixGop.inf
new file mode 100644
index 0000000000..1dd33bd2e5
--- /dev/null
+++ b/UnixPkg/UnixGopDxe/UnixGop.inf
@@ -0,0 +1,73 @@
+## @file
+# Uga driver
+#
+# UGA is short hand for Universal Graphics Abstraction protocol.
+# This file is a verision of UgaIo the uses UnixThunk system calls as an IO
+# abstraction. For a PCI device UnixIo would be replaced with
+# a PCI IO abstraction that abstracted a specific PCI device.
+# Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+# Portions copyright (c) 2010, Apple, Inc. All rights reserved.
+#
+# This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+#
+#
+##
+
+[Defines]
+ INF_VERSION = 0x00010005
+ BASE_NAME = UnixUga
+ FILE_GUID = f33cad86-8985-11db-8040-0040d02b1835
+ MODULE_TYPE = UEFI_DRIVER
+ VERSION_STRING = 1.0
+
+ ENTRY_POINT = InitializeUnixGop
+
+#
+# The following information is for reference only and not required by the build tools.
+#
+# VALID_ARCHITECTURES = IA32 X64 IPF EBC
+#
+# DRIVER_BINDING = gUnixUgaDriverBinding
+# COMPONENT_NAME = gUnixUgaComponentName
+#
+
+[Sources]
+ ComponentName.c
+ UnixGopScreen.c
+ UnixGopDriver.c
+ UnixGopInput.c
+ UnixGop.h
+
+
+[Packages]
+ MdePkg/MdePkg.dec
+ UnixPkg/UnixPkg.dec
+
+
+[LibraryClasses]
+ UefiBootServicesTableLib
+ MemoryAllocationLib
+ BaseMemoryLib
+ UefiLib
+ UefiDriverEntryPoint
+ BaseLib
+ DebugLib
+
+
+[Guids]
+ gEfiEventExitBootServicesGuid # SOMETIMES_CONSUMED Create Event: EVENT_GROUP_GUID
+ gEfiUnixGopGuid # ALWAYS_CONSUMED
+
+
+[Protocols]
+ gEfiGraphicsOutputProtocolGuid
+ gEfiSimpleTextInProtocolGuid # PROTOCOL BY_START
+ gEfiSimpleTextInputExProtocolGuid # PROTOCOL BY_START
+ gEfiSimplePointerProtocolGuid # PROTOCOL BY_START
+ gEfiUnixIoProtocolGuid # PROTOCOL TO_START
+
diff --git a/UnixPkg/UnixGopDxe/UnixGopDriver.c b/UnixPkg/UnixGopDxe/UnixGopDriver.c
new file mode 100644
index 0000000000..dcc79d97f5
--- /dev/null
+++ b/UnixPkg/UnixGopDxe/UnixGopDriver.c
@@ -0,0 +1,396 @@
+/*++
+
+Copyright (c) 2006, Intel Corporation. All rights reserved.<BR>
+Portions copyright (c) 2010, Apple, Inc. All rights reserved.
+This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ UnixGopDriver.c
+
+Abstract:
+
+ This file implements the EFI 1.1 Device Driver model requirements for UGA
+
+ UGA is short hand for Universal Graphics Abstraction protocol.
+
+ This file is a verision of UgaIo the uses UnixThunk system calls as an IO
+ abstraction. For a PCI device UnixIo would be replaced with
+ a PCI IO abstraction that abstracted a specific PCI device.
+
+--*/
+
+#include "UnixGop.h"
+
+
+EFI_STATUS
+FreeNotifyList (
+ IN OUT LIST_ENTRY *ListHead
+ )
+/*++
+
+Routine Description:
+
+Arguments:
+
+ ListHead - The list head
+
+Returns:
+
+ EFI_SUCCESS - Free the notify list successfully
+ EFI_INVALID_PARAMETER - ListHead is invalid.
+
+--*/
+{
+ UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY *NotifyNode;
+
+ if (ListHead == NULL) {
+ return EFI_INVALID_PARAMETER;
+ }
+ while (!IsListEmpty (ListHead)) {
+ NotifyNode = CR (
+ ListHead->ForwardLink,
+ UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY,
+ NotifyEntry,
+ UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY_SIGNATURE
+ );
+ RemoveEntryList (ListHead->ForwardLink);
+ gBS->FreePool (NotifyNode);
+ }
+
+ return EFI_SUCCESS;
+}
+
+
+EFI_STATUS
+EFIAPI
+UnixGopDriverBindingSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Handle,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ )
+/*++
+
+Routine Description:
+
+Arguments:
+
+Returns:
+
+ None
+
+--*/
+// TODO: This - add argument and description to function comment
+// TODO: Handle - add argument and description to function comment
+// TODO: RemainingDevicePath - add argument and description to function comment
+{
+ EFI_STATUS Status;
+ EFI_UNIX_IO_PROTOCOL *UnixIo;
+
+ //
+ // Open the IO Abstraction(s) needed to perform the supported test
+ //
+ Status = gBS->OpenProtocol (
+ Handle,
+ &gEfiUnixIoProtocolGuid,
+ (VOID **)&UnixIo,
+ This->DriverBindingHandle,
+ Handle,
+ EFI_OPEN_PROTOCOL_BY_DRIVER
+ );
+ if (EFI_ERROR (Status)) {
+ return Status;
+ }
+
+ Status = UnixGopSupported (UnixIo);
+
+ //
+ // Close the I/O Abstraction(s) used to perform the supported test
+ //
+ gBS->CloseProtocol (
+ Handle,
+ &gEfiUnixIoProtocolGuid,
+ This->DriverBindingHandle,
+ Handle
+ );
+
+ return Status;
+}
+
+EFI_STATUS
+EFIAPI
+UnixGopDriverBindingStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Handle,
+ IN EFI_DEVICE_PATH_PROTOCOL *RemainingDevicePath
+ )
+/*++
+
+Routine Description:
+
+Arguments:
+
+Returns:
+
+ None
+
+--*/
+// TODO: This - add argument and description to function comment
+// TODO: Handle - add argument and description to function comment
+// TODO: RemainingDevicePath - add argument and description to function comment
+// TODO: EFI_UNSUPPORTED - add return value to function comment
+{
+ EFI_UNIX_IO_PROTOCOL *UnixIo;
+ EFI_STATUS Status;
+ GOP_PRIVATE_DATA *Private;
+
+ //
+ // Grab the protocols we need
+ //
+ Status = gBS->OpenProtocol (
+ Handle,
+ &gEfiUnixIoProtocolGuid,
+ (VOID **)&UnixIo,
+ This->DriverBindingHandle,
+ Handle,
+ EFI_OPEN_PROTOCOL_BY_DRIVER
+ );
+ if (EFI_ERROR (Status)) {
+ return EFI_UNSUPPORTED;
+ }
+
+ //
+ // Allocate Private context data for SGO inteface.
+ //
+ Private = NULL;
+ Status = gBS->AllocatePool (
+ EfiBootServicesData,
+ sizeof (GOP_PRIVATE_DATA),
+ (VOID **)&Private
+ );
+ if (EFI_ERROR (Status)) {
+ goto Done;
+ }
+ //
+ // Set up context record
+ //
+ Private->Signature = GOP_PRIVATE_DATA_SIGNATURE;
+ Private->Handle = Handle;
+ Private->UnixThunk = UnixIo->UnixThunk;
+
+ Private->ControllerNameTable = NULL;
+
+ AddUnicodeString (
+ "eng",
+ gUnixGopComponentName.SupportedLanguages,
+ &Private->ControllerNameTable,
+ UnixIo->EnvString
+ );
+ AddUnicodeString2 (
+ "en",
+ gUnixGopComponentName2.SupportedLanguages,
+ &Private->ControllerNameTable,
+ UnixIo->EnvString,
+ FALSE
+ );
+
+ Private->WindowName = UnixIo->EnvString;
+
+ Status = UnixGopConstructor (Private);
+ if (EFI_ERROR (Status)) {
+ goto Done;
+ }
+ //
+ // Publish the Gop interface to the world
+ //
+ Status = gBS->InstallMultipleProtocolInterfaces (
+ &Private->Handle,
+ &gEfiGraphicsOutputProtocolGuid, &Private->GraphicsOutput,
+ &gEfiSimpleTextInProtocolGuid, &Private->SimpleTextIn,
+ &gEfiSimplePointerProtocolGuid, &Private->SimplePointer,
+// &gEfiSimpleTextInputExProtocolGuid, &Private->SimpleTextInEx,
+ NULL
+ );
+
+Done:
+ if (EFI_ERROR (Status)) {
+
+ gBS->CloseProtocol (
+ Handle,
+ &gEfiUnixIoProtocolGuid,
+ This->DriverBindingHandle,
+ Handle
+ );
+
+ if (Private != NULL) {
+ //
+ // On Error Free back private data
+ //
+ if (Private->ControllerNameTable != NULL) {
+ FreeUnicodeStringTable (Private->ControllerNameTable);
+ }
+ if (Private->SimpleTextIn.WaitForKey != NULL) {
+ gBS->CloseEvent (Private->SimpleTextIn.WaitForKey);
+ }
+ if (Private->SimpleTextInEx.WaitForKeyEx != NULL) {
+ gBS->CloseEvent (Private->SimpleTextInEx.WaitForKeyEx);
+ }
+ FreeNotifyList (&Private->NotifyList);
+
+ gBS->FreePool (Private);
+ }
+ }
+
+ return Status;
+}
+
+EFI_STATUS
+EFIAPI
+UnixGopDriverBindingStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE Handle,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ )
+/*++
+
+Routine Description:
+
+Arguments:
+
+Returns:
+
+ None
+
+--*/
+// TODO: This - add argument and description to function comment
+// TODO: Handle - add argument and description to function comment
+// TODO: NumberOfChildren - add argument and description to function comment
+// TODO: ChildHandleBuffer - add argument and description to function comment
+// TODO: EFI_NOT_STARTED - add return value to function comment
+// TODO: EFI_DEVICE_ERROR - add return value to function comment
+{
+ EFI_GRAPHICS_OUTPUT_PROTOCOL *GraphicsOutput;
+ EFI_STATUS Status;
+ GOP_PRIVATE_DATA *Private;
+
+ Status = gBS->OpenProtocol (
+ Handle,
+ &gEfiGraphicsOutputProtocolGuid,
+ (VOID **)&GraphicsOutput,
+ This->DriverBindingHandle,
+ Handle,
+ EFI_OPEN_PROTOCOL_GET_PROTOCOL
+ );
+ if (EFI_ERROR (Status)) {
+ //
+ // If the GOP interface does not exist the driver is not started
+ //
+ return EFI_NOT_STARTED;
+ }
+
+ //
+ // Get our private context information
+ //
+ Private = GOP_PRIVATE_DATA_FROM_THIS (GraphicsOutput);
+
+ //
+ // Remove the SGO interface from the system
+ //
+ Status = gBS->UninstallMultipleProtocolInterfaces (
+ Private->Handle,
+ &gEfiGraphicsOutputProtocolGuid, &Private->GraphicsOutput,
+ &gEfiSimpleTextInProtocolGuid, &Private->SimpleTextIn,
+ &gEfiSimplePointerProtocolGuid, &Private->SimplePointer,
+// &gEfiSimpleTextInputExProtocolGuid, &Private->SimpleTextInEx,
+ NULL
+ );
+ if (!EFI_ERROR (Status)) {
+ //
+ // Shutdown the hardware
+ //
+ Status = UnixGopDestructor (Private);
+ if (EFI_ERROR (Status)) {
+ return EFI_DEVICE_ERROR;
+ }
+
+ gBS->CloseProtocol (
+ Handle,
+ &gEfiUnixIoProtocolGuid,
+ This->DriverBindingHandle,
+ Handle
+ );
+
+ //
+ // Free our instance data
+ //
+ FreeUnicodeStringTable (Private->ControllerNameTable);
+
+ Status = gBS->CloseEvent (Private->SimpleTextIn.WaitForKey);
+ ASSERT_EFI_ERROR (Status);
+
+ Status = gBS->CloseEvent (Private->SimpleTextInEx.WaitForKeyEx);
+ ASSERT_EFI_ERROR (Status);
+
+ FreeNotifyList (&Private->NotifyList);
+
+ gBS->FreePool (Private);
+
+ }
+
+ return Status;
+}
+
+
+
+
+EFI_DRIVER_BINDING_PROTOCOL gUnixGopDriverBinding = {
+ UnixGopDriverBindingSupported,
+ UnixGopDriverBindingStart,
+ UnixGopDriverBindingStop,
+ 0xa,
+ NULL,
+ NULL
+};
+
+
+
+/**
+ The user Entry Point for module UnixGop. The user code starts with this function.
+
+ @param[in] ImageHandle The firmware allocated handle for the EFI image.
+ @param[in] SystemTable A pointer to the EFI System Table.
+
+ @retval EFI_SUCCESS The entry point is executed successfully.
+ @retval other Some error occurs when executing this entry point.
+
+**/
+EFI_STATUS
+EFIAPI
+InitializeUnixGop (
+ IN EFI_HANDLE ImageHandle,
+ IN EFI_SYSTEM_TABLE *SystemTable
+ )
+{
+ EFI_STATUS Status;
+
+ Status = EfiLibInstallDriverBindingComponentName2 (
+ ImageHandle,
+ SystemTable,
+ &gUnixGopDriverBinding,
+ ImageHandle,
+ &gUnixGopComponentName,
+ &gUnixGopComponentName2
+ );
+ ASSERT_EFI_ERROR (Status);
+
+
+ return Status;
+}
+
diff --git a/UnixPkg/UnixGopDxe/UnixGopInput.c b/UnixPkg/UnixGopDxe/UnixGopInput.c
new file mode 100644
index 0000000000..e681fc9ce4
--- /dev/null
+++ b/UnixPkg/UnixGopDxe/UnixGopInput.c
@@ -0,0 +1,885 @@
+/*++
+
+Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+Portions copyright (c) 2010, Apple, Inc. All rights reserved.
+Portions copyright (c) 2010, Apple Inc. All rights reserved.
+This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+
+--*/
+
+#include "UnixGop.h"
+
+
+BOOLEAN
+GopPrivateIsKeyRegistered (
+ IN EFI_KEY_DATA *RegsiteredData,
+ IN EFI_KEY_DATA *InputData
+ )
+/*++
+
+Routine Description:
+
+Arguments:
+
+ RegsiteredData - A pointer to a buffer that is filled in with the keystroke
+ state data for the key that was registered.
+ InputData - A pointer to a buffer that is filled in with the keystroke
+ state data for the key that was pressed.
+
+Returns:
+ TRUE - Key be pressed matches a registered key.
+ FLASE - Match failed.
+
+--*/
+{
+ ASSERT (RegsiteredData != NULL && InputData != NULL);
+
+ if ((RegsiteredData->Key.ScanCode != InputData->Key.ScanCode) ||
+ (RegsiteredData->Key.UnicodeChar != InputData->Key.UnicodeChar)) {
+ return FALSE;
+ }
+
+ //
+ // Assume KeyShiftState/KeyToggleState = 0 in Registered key data means these state could be ignored.
+ //
+ if (RegsiteredData->KeyState.KeyShiftState != 0 &&
+ RegsiteredData->KeyState.KeyShiftState != InputData->KeyState.KeyShiftState) {
+ return FALSE;
+ }
+ if (RegsiteredData->KeyState.KeyToggleState != 0 &&
+ RegsiteredData->KeyState.KeyToggleState != InputData->KeyState.KeyToggleState) {
+ return FALSE;
+ }
+
+ return TRUE;
+
+}
+
+
+VOID
+EFIAPI
+GopPrivateInvokeRegisteredFunction (
+ IN VOID *Context,
+ IN EFI_KEY_DATA *KeyData
+ )
+{
+ LIST_ENTRY *Link;
+ UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY *CurrentNotify;
+ GOP_PRIVATE_DATA *Private = (GOP_PRIVATE_DATA *)Context;
+
+ for (Link = Private->NotifyList.ForwardLink; Link != &Private->NotifyList; Link = Link->ForwardLink) {
+ CurrentNotify = CR (
+ Link,
+ UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY,
+ NotifyEntry,
+ UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY_SIGNATURE
+ );
+ if (GopPrivateIsKeyRegistered (&CurrentNotify->KeyData, KeyData)) {
+ // We could be called at a high TPL so signal an event to call the registered function
+ // at a lower TPL.
+ gBS->SignalEvent (CurrentNotify->Event);
+ }
+ }
+}
+
+
+
+//
+// Simple Text In implementation.
+//
+
+/**
+ Reset the input device and optionally run diagnostics
+
+ @param This Protocol instance pointer.
+ @param ExtendedVerification Driver may perform diagnostics on reset.
+
+ @retval EFI_SUCCESS The device was reset.
+ @retval EFI_DEVICE_ERROR The device is not functioning properly and could not be reset.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixGopSimpleTextInReset (
+ IN EFI_SIMPLE_TEXT_INPUT_PROTOCOL *This,
+ IN BOOLEAN ExtendedVerification
+ )
+{
+ GOP_PRIVATE_DATA *Private;
+ EFI_KEY_DATA KeyData;
+ EFI_TPL OldTpl;
+
+ Private = GOP_PRIVATE_DATA_FROM_TEXT_IN_THIS (This);
+ if (Private->UgaIo == NULL) {
+ return EFI_SUCCESS;
+ }
+
+ //
+ // Enter critical section
+ //
+ OldTpl = gBS->RaiseTPL (TPL_NOTIFY);
+
+ //
+ // A reset is draining the Queue
+ //
+ while (Private->UgaIo->UgaGetKey (Private->UgaIo, &KeyData) == EFI_SUCCESS)
+ ;
+
+ //
+ // Leave critical section and return
+ //
+ gBS->RestoreTPL (OldTpl);
+ return EFI_SUCCESS;
+}
+
+
+/**
+ Reads the next keystroke from the input device. The WaitForKey Event can
+ be used to test for existence of a keystroke via WaitForEvent () call.
+
+ @param This Protocol instance pointer.
+ @param Key A pointer to a buffer that is filled in with the keystroke
+ information for the key that was pressed.
+
+ @retval EFI_SUCCESS The keystroke information was returned.
+ @retval EFI_NOT_READY There was no keystroke data available.
+ @retval EFI_DEVICE_ERROR The keystroke information was not returned due to
+ hardware errors.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixGopSimpleTextInReadKeyStroke (
+ IN EFI_SIMPLE_TEXT_INPUT_PROTOCOL *This,
+ OUT EFI_INPUT_KEY *Key
+ )
+{
+ GOP_PRIVATE_DATA *Private;
+ EFI_STATUS Status;
+ EFI_TPL OldTpl;
+ EFI_KEY_DATA KeyData;
+
+ Private = GOP_PRIVATE_DATA_FROM_TEXT_IN_THIS (This);
+ if (Private->UgaIo == NULL) {
+ return EFI_NOT_READY;
+ }
+
+ //
+ // Enter critical section
+ //
+ OldTpl = gBS->RaiseTPL (TPL_NOTIFY);
+
+ Status = Private->UgaIo->UgaGetKey(Private->UgaIo, &KeyData);
+ CopyMem (Key, &KeyData.Key, sizeof (EFI_INPUT_KEY));
+
+ //
+ // Leave critical section and return
+ //
+ gBS->RestoreTPL (OldTpl);
+
+ return Status;
+}
+
+
+
+/**
+ SimpleTextIn and SimpleTextInEx Notify Wait Event
+
+ @param Event Event whose notification function is being invoked.
+ @param Context Pointer to GOP_PRIVATE_DATA.
+
+**/
+VOID
+EFIAPI
+UnixGopSimpleTextInWaitForKey (
+ IN EFI_EVENT Event,
+ IN VOID *Context
+ )
+{
+ GOP_PRIVATE_DATA *Private;
+ EFI_STATUS Status;
+ EFI_TPL OldTpl;
+
+ Private = (GOP_PRIVATE_DATA *) Context;
+ if (Private->UgaIo == NULL) {
+ return;
+ }
+
+ //
+ // Enter critical section
+ //
+ OldTpl = gBS->RaiseTPL (TPL_NOTIFY);
+
+ Status = Private->UgaIo->UgaCheckKey (Private->UgaIo);
+ if (!EFI_ERROR (Status)) {
+ //
+ // If a there is a key in the queue signal our event.
+ //
+ gBS->SignalEvent (Event);
+ }
+ //
+ // Leave critical section and return
+ //
+ gBS->RestoreTPL (OldTpl);
+}
+
+
+//
+// Simple Text Input Ex protocol functions
+//
+
+
+/**
+ The Reset() function resets the input device hardware. As part
+ of initialization process, the firmware/device will make a quick
+ but reasonable attempt to verify that the device is functioning.
+ If the ExtendedVerification flag is TRUE the firmware may take
+ an extended amount of time to verify the device is operating on
+ reset. Otherwise the reset operation is to occur as quickly as
+ possible. The hardware verification process is not defined by
+ this specification and is left up to the platform firmware or
+ driver to implement.
+
+ @param This A pointer to the EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL instance.
+
+ @param ExtendedVerification Indicates that the driver may
+ perform a more exhaustive
+ verification operation of the
+ device during reset.
+
+
+ @retval EFI_SUCCESS The device was reset.
+
+ @retval EFI_DEVICE_ERROR The device is not functioning
+ correctly and could not be reset.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixGopSimpleTextInExResetEx (
+ IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
+ IN BOOLEAN ExtendedVerification
+ )
+/*++
+
+ Routine Description:
+ Reset the input device and optionaly run diagnostics
+
+ Arguments:
+ This - Protocol instance pointer.
+ ExtendedVerification - Driver may perform diagnostics on reset.
+
+ Returns:
+ EFI_SUCCESS - The device was reset.
+
+--*/
+{
+ GOP_PRIVATE_DATA *Private;
+
+ Private = GOP_PRIVATE_DATA_FROM_TEXT_IN_EX_THIS (This);
+
+ return EFI_SUCCESS;
+}
+
+
+
+/**
+ The function reads the next keystroke from the input device. If
+ there is no pending keystroke the function returns
+ EFI_NOT_READY. If there is a pending keystroke, then
+ KeyData.Key.ScanCode is the EFI scan code defined in Error!
+ Reference source not found. The KeyData.Key.UnicodeChar is the
+ actual printable character or is zero if the key does not
+ represent a printable character (control key, function key,
+ etc.). The KeyData.KeyState is shift state for the character
+ reflected in KeyData.Key.UnicodeChar or KeyData.Key.ScanCode .
+ When interpreting the data from this function, it should be
+ noted that if a class of printable characters that are
+ normally adjusted by shift modifiers (e.g. Shift Key + "f"
+ key) would be presented solely as a KeyData.Key.UnicodeChar
+ without the associated shift state. So in the previous example
+ of a Shift Key + "f" key being pressed, the only pertinent
+ data returned would be KeyData.Key.UnicodeChar with the value
+ of "F". This of course would not typically be the case for
+ non-printable characters such as the pressing of the Right
+ Shift Key + F10 key since the corresponding returned data
+ would be reflected both in the KeyData.KeyState.KeyShiftState
+ and KeyData.Key.ScanCode values. UEFI drivers which implement
+ the EFI_SIMPLE_TEXT_INPUT_EX protocol are required to return
+ KeyData.Key and KeyData.KeyState values. These drivers must
+ always return the most current state of
+ KeyData.KeyState.KeyShiftState and
+ KeyData.KeyState.KeyToggleState. It should also be noted that
+ certain input devices may not be able to produce shift or toggle
+ state information, and in those cases the high order bit in the
+ respective Toggle and Shift state fields should not be active.
+
+
+ @param This A pointer to the EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL instance.
+
+ @param KeyData A pointer to a buffer that is filled in with
+ the keystroke state data for the key that was
+ pressed.
+
+
+ @retval EFI_SUCCESS The keystroke information was
+ returned.
+
+ @retval EFI_NOT_READY There was no keystroke data available.
+ EFI_DEVICE_ERROR The keystroke
+ information was not returned due to
+ hardware errors.
+
+
+**/
+EFI_STATUS
+EFIAPI
+UnixGopSimpleTextInExReadKeyStrokeEx (
+ IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
+ OUT EFI_KEY_DATA *KeyData
+ )
+/*++
+
+ Routine Description:
+ Reads the next keystroke from the input device. The WaitForKey Event can
+ be used to test for existance of a keystroke via WaitForEvent () call.
+
+ Arguments:
+ This - Protocol instance pointer.
+ KeyData - A pointer to a buffer that is filled in with the keystroke
+ state data for the key that was pressed.
+
+ Returns:
+ EFI_SUCCESS - The keystroke information was returned.
+ EFI_NOT_READY - There was no keystroke data availiable.
+ EFI_DEVICE_ERROR - The keystroke information was not returned due to
+ hardware errors.
+ EFI_INVALID_PARAMETER - KeyData is NULL.
+
+--*/
+{
+ EFI_STATUS Status;
+ GOP_PRIVATE_DATA *Private;
+ EFI_TPL OldTpl;
+
+
+ if (KeyData == NULL) {
+ return EFI_INVALID_PARAMETER;
+ }
+
+ Private = GOP_PRIVATE_DATA_FROM_TEXT_IN_THIS (This);
+ if (Private->UgaIo == NULL) {
+ return EFI_NOT_READY;
+ }
+
+ //
+ // Enter critical section
+ //
+ OldTpl = gBS->RaiseTPL (TPL_NOTIFY);
+
+ Status = Private->UgaIo->UgaGetKey(Private->UgaIo, KeyData);
+
+ //
+ // Leave critical section and return
+ //
+ gBS->RestoreTPL (OldTpl);
+
+ return Status;
+}
+
+
+
+/**
+ The SetState() function allows the input device hardware to
+ have state settings adjusted.
+
+ @param This A pointer to the EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL instance.
+
+ @param KeyToggleState Pointer to the EFI_KEY_TOGGLE_STATE to
+ set the state for the input device.
+
+
+ @retval EFI_SUCCESS The device state was set appropriately.
+
+ @retval EFI_DEVICE_ERROR The device is not functioning
+ correctly and could not have the
+ setting adjusted.
+
+ @retval EFI_UNSUPPORTED The device does not support the
+ ability to have its state set.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixGopSimpleTextInExSetState (
+ IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
+ IN EFI_KEY_TOGGLE_STATE *KeyToggleState
+ )
+{
+ GOP_PRIVATE_DATA *Private;
+ EFI_STATUS Status;
+ EFI_TPL OldTpl;
+
+ Private = GOP_PRIVATE_DATA_FROM_TEXT_IN_THIS (This);
+ if (Private->UgaIo == NULL) {
+ return EFI_NOT_READY;
+ }
+
+ //
+ // Enter critical section
+ //
+ OldTpl = gBS->RaiseTPL (TPL_NOTIFY);
+
+ Status = Private->UgaIo->UgaKeySetState (Private->UgaIo, KeyToggleState);
+ //
+ // Leave critical section and return
+ //
+ gBS->RestoreTPL (OldTpl);
+
+ return Status;
+}
+
+
+/**
+ SimpleTextIn and SimpleTextInEx Notify Wait Event
+
+ @param Event Event whose notification function is being invoked.
+ @param Context Pointer to GOP_PRIVATE_DATA.
+
+**/
+VOID
+EFIAPI
+UnixGopRegisterKeyCallback (
+ IN EFI_EVENT Event,
+ IN VOID *Context
+ )
+{
+ UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY *ExNotify = (UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY *)Context;
+
+ ExNotify->KeyNotificationFn (&ExNotify->KeyData);
+}
+
+
+
+/**
+ The RegisterKeystrokeNotify() function registers a function
+ which will be called when a specified keystroke will occur.
+
+ @param This A pointer to the EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL instance.
+
+ @param KeyData A pointer to a buffer that is filled in with
+ the keystroke information for the key that was
+ pressed.
+
+ @param KeyNotificationFunction Points to the function to be
+ called when the key sequence
+ is typed specified by KeyData.
+
+
+ @param NotifyHandle Points to the unique handle assigned to
+ the registered notification.
+
+ @retval EFI_SUCCESS The device state was set
+ appropriately.
+
+ @retval EFI_OUT_OF_RESOURCES Unable to allocate necessary
+ data structures.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixGopSimpleTextInExRegisterKeyNotify (
+ IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
+ IN EFI_KEY_DATA *KeyData,
+ IN EFI_KEY_NOTIFY_FUNCTION KeyNotificationFunction,
+ OUT EFI_HANDLE *NotifyHandle
+ )
+{
+ EFI_STATUS Status;
+ GOP_PRIVATE_DATA *Private;
+ UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY *CurrentNotify;
+ LIST_ENTRY *Link;
+ UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY *NewNotify;
+
+ if (KeyData == NULL || KeyNotificationFunction == NULL || NotifyHandle == NULL) {
+ return EFI_INVALID_PARAMETER;
+ }
+
+ Private = GOP_PRIVATE_DATA_FROM_TEXT_IN_EX_THIS (This);
+
+ //
+ // Return EFI_SUCCESS if the (KeyData, NotificationFunction) is already registered.
+ //
+ for (Link = Private->NotifyList.ForwardLink; Link != &Private->NotifyList; Link = Link->ForwardLink) {
+ CurrentNotify = CR (
+ Link,
+ UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY,
+ NotifyEntry,
+ UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY_SIGNATURE
+ );
+ if (GopPrivateIsKeyRegistered (&CurrentNotify->KeyData, KeyData)) {
+ if (CurrentNotify->KeyNotificationFn == KeyNotificationFunction) {
+ *NotifyHandle = CurrentNotify->NotifyHandle;
+ return EFI_SUCCESS;
+ }
+ }
+ }
+
+ //
+ // Allocate resource to save the notification function
+ //
+ NewNotify = (UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY *) AllocateZeroPool (sizeof (UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY));
+ if (NewNotify == NULL) {
+ return EFI_OUT_OF_RESOURCES;
+ }
+
+ NewNotify->Signature = UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY_SIGNATURE;
+ NewNotify->KeyNotificationFn = KeyNotificationFunction;
+ NewNotify->NotifyHandle = (EFI_HANDLE) NewNotify;
+ CopyMem (&NewNotify->KeyData, KeyData, sizeof (KeyData));
+ InsertTailList (&Private->NotifyList, &NewNotify->NotifyEntry);
+
+ Status = gBS->CreateEvent (
+ EVT_NOTIFY_SIGNAL,
+ TPL_NOTIFY,
+ UnixGopRegisterKeyCallback,
+ NewNotify,
+ NewNotify->Event
+ );
+ ASSERT_EFI_ERROR (Status);
+
+
+ *NotifyHandle = NewNotify->NotifyHandle;
+
+ return EFI_SUCCESS;
+
+}
+
+
+/**
+ The UnregisterKeystrokeNotify() function removes the
+ notification which was previously registered.
+
+ @param This A pointer to the EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL instance.
+
+ @param NotificationHandle The handle of the notification
+ function being unregistered.
+
+ @retval EFI_SUCCESS The device state was set appropriately.
+
+ @retval EFI_INVALID_PARAMETER The NotificationHandle is
+ invalid.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixGopSimpleTextInExUnregisterKeyNotify (
+ IN EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL *This,
+ IN EFI_HANDLE NotificationHandle
+ )
+/*++
+
+ Routine Description:
+ Remove a registered notification function from a particular keystroke.
+
+ Arguments:
+ This - Protocol instance pointer.
+ NotificationHandle - The handle of the notification function being unregistered.
+
+ Returns:
+ EFI_SUCCESS - The notification function was unregistered successfully.
+ EFI_INVALID_PARAMETER - The NotificationHandle is invalid.
+
+--*/
+{
+ GOP_PRIVATE_DATA *Private;
+ LIST_ENTRY *Link;
+ UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY *CurrentNotify;
+
+ if (NotificationHandle == NULL) {
+ return EFI_INVALID_PARAMETER;
+ }
+
+ if (((UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY *) NotificationHandle)->Signature != UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY_SIGNATURE) {
+ return EFI_INVALID_PARAMETER;
+ }
+
+ Private = GOP_PRIVATE_DATA_FROM_TEXT_IN_EX_THIS (This);
+
+ for (Link = Private->NotifyList.ForwardLink; Link != &Private->NotifyList; Link = Link->ForwardLink) {
+ CurrentNotify = CR (
+ Link,
+ UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY,
+ NotifyEntry,
+ UNIX_GOP_SIMPLE_TEXTIN_EX_NOTIFY_SIGNATURE
+ );
+ if (CurrentNotify->NotifyHandle == NotificationHandle) {
+ //
+ // Remove the notification function from NotifyList and free resources
+ //
+ RemoveEntryList (&CurrentNotify->NotifyEntry);
+
+ gBS->CloseEvent (CurrentNotify->Event);
+
+ gBS->FreePool (CurrentNotify);
+ return EFI_SUCCESS;
+ }
+ }
+
+ //
+ // Can not find the specified Notification Handle
+ //
+ return EFI_INVALID_PARAMETER;
+}
+
+
+
+/**
+ Initialize SimplelTextIn and SimpleTextInEx protocols in the Private
+ context structure.
+
+ @param Private Context structure to fill in.
+
+ @return EFI_SUCCESS Initialization was a success
+
+**/
+EFI_STATUS
+UnixGopInitializeSimpleTextInForWindow (
+ IN GOP_PRIVATE_DATA *Private
+ )
+{
+ EFI_STATUS Status;
+
+ //
+ // Initialize Simple Text In protoocol
+ //
+ Private->SimpleTextIn.Reset = UnixGopSimpleTextInReset;
+ Private->SimpleTextIn.ReadKeyStroke = UnixGopSimpleTextInReadKeyStroke;
+
+ Status = gBS->CreateEvent (
+ EVT_NOTIFY_WAIT,
+ TPL_NOTIFY,
+ UnixGopSimpleTextInWaitForKey,
+ Private,
+ &Private->SimpleTextIn.WaitForKey
+ );
+ ASSERT_EFI_ERROR (Status);
+
+
+ //
+ // Initialize Simple Text In Ex
+ //
+
+ Private->SimpleTextInEx.Reset = UnixGopSimpleTextInExResetEx;
+ Private->SimpleTextInEx.ReadKeyStrokeEx = UnixGopSimpleTextInExReadKeyStrokeEx;
+ Private->SimpleTextInEx.SetState = UnixGopSimpleTextInExSetState;
+ Private->SimpleTextInEx.RegisterKeyNotify = UnixGopSimpleTextInExRegisterKeyNotify;
+ Private->SimpleTextInEx.UnregisterKeyNotify = UnixGopSimpleTextInExUnregisterKeyNotify;
+
+ Private->SimpleTextInEx.Reset (&Private->SimpleTextInEx, FALSE);
+
+ InitializeListHead (&Private->NotifyList);
+
+ Status = gBS->CreateEvent (
+ EVT_NOTIFY_WAIT,
+ TPL_NOTIFY,
+ UnixGopSimpleTextInWaitForKey,
+ Private,
+ &Private->SimpleTextInEx.WaitForKeyEx
+ );
+ ASSERT_EFI_ERROR (Status);
+
+
+ return Status;
+}
+
+
+
+
+
+
+
+//
+// Simple Pointer implementation.
+//
+
+
+/**
+ Resets the pointer device hardware.
+
+ @param This A pointer to the EFI_SIMPLE_POINTER_PROTOCOL
+ instance.
+ @param ExtendedVerification Indicates that the driver may perform a more exhaustive
+ verification operation of the device during reset.
+
+ @retval EFI_SUCCESS The device was reset.
+ @retval EFI_DEVICE_ERROR The device is not functioning correctly and could not be reset.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixGopSimplePointerReset (
+ IN EFI_SIMPLE_POINTER_PROTOCOL *This,
+ IN BOOLEAN ExtendedVerification
+ )
+{
+ GOP_PRIVATE_DATA *Private;
+ EFI_SIMPLE_POINTER_STATE State;
+ EFI_TPL OldTpl;
+
+ Private = GOP_PRIVATE_DATA_FROM_POINTER_MODE_THIS (This);
+ if (Private->UgaIo == NULL) {
+ return EFI_SUCCESS;
+ }
+
+ //
+ // Enter critical section
+ //
+ OldTpl = gBS->RaiseTPL (TPL_NOTIFY);
+
+ //
+ // A reset is draining the Queue
+ //
+ while (Private->UgaIo->UgaGetPointerState (Private->UgaIo, &State) == EFI_SUCCESS)
+ ;
+
+ //
+ // Leave critical section and return
+ //
+ gBS->RestoreTPL (OldTpl);
+ return EFI_SUCCESS;
+}
+
+
+/**
+ Retrieves the current state of a pointer device.
+
+ @param This A pointer to the EFI_SIMPLE_POINTER_PROTOCOL
+ instance.
+ @param State A pointer to the state information on the pointer device.
+
+ @retval EFI_SUCCESS The state of the pointer device was returned in State.
+ @retval EFI_NOT_READY The state of the pointer device has not changed since the last call to
+ GetState().
+ @retval EFI_DEVICE_ERROR A device error occurred while attempting to retrieve the pointer device's
+ current state.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixGopSimplePointerGetState (
+ IN EFI_SIMPLE_POINTER_PROTOCOL *This,
+ IN OUT EFI_SIMPLE_POINTER_STATE *State
+ )
+{
+ GOP_PRIVATE_DATA *Private;
+ EFI_STATUS Status;
+ EFI_TPL OldTpl;
+
+ Private = GOP_PRIVATE_DATA_FROM_POINTER_MODE_THIS (This);
+ if (Private->UgaIo == NULL) {
+ return EFI_NOT_READY;
+ }
+
+ //
+ // Enter critical section
+ //
+ OldTpl = gBS->RaiseTPL (TPL_NOTIFY);
+
+ Status = Private->UgaIo->UgaGetPointerState (Private->UgaIo, State);
+ //
+ // Leave critical section and return
+ //
+ gBS->RestoreTPL (OldTpl);
+
+ return Status;
+}
+
+
+/**
+ SimplePointer Notify Wait Event
+
+ @param Event Event whose notification function is being invoked.
+ @param Context Pointer to GOP_PRIVATE_DATA.
+
+**/
+VOID
+EFIAPI
+UnixGopSimplePointerWaitForInput (
+ IN EFI_EVENT Event,
+ IN VOID *Context
+ )
+{
+ GOP_PRIVATE_DATA *Private;
+ EFI_STATUS Status;
+ EFI_TPL OldTpl;
+
+ Private = (GOP_PRIVATE_DATA *) Context;
+ if (Private->UgaIo == NULL) {
+ return;
+ }
+
+ //
+ // Enter critical section
+ //
+ OldTpl = gBS->RaiseTPL (TPL_NOTIFY);
+
+ Status = Private->UgaIo->UgaCheckPointer (Private->UgaIo);
+ if (!EFI_ERROR (Status)) {
+ //
+ // If the pointer state has changed, signal our event.
+ //
+ gBS->SignalEvent (Event);
+ }
+ //
+ // Leave critical section and return
+ //
+ gBS->RestoreTPL (OldTpl);
+}
+
+
+/**
+ SimplePointer constructor
+
+ @param Private Context structure to fill in.
+
+ @retval EFI_SUCCESS Constructor had success
+
+**/
+EFI_STATUS
+UnixGopInitializeSimplePointerForWindow (
+ IN GOP_PRIVATE_DATA *Private
+ )
+{
+ EFI_STATUS Status;
+
+ //
+ // Initialize Simple Pointer protoocol
+ //
+ Private->PointerMode.ResolutionX = 1;
+ Private->PointerMode.ResolutionY = 1;
+ Private->PointerMode.ResolutionZ = 1;
+ Private->PointerMode.LeftButton = TRUE;
+ Private->PointerMode.RightButton = TRUE;
+
+ Private->SimplePointer.Reset = UnixGopSimplePointerReset;
+ Private->SimplePointer.GetState = UnixGopSimplePointerGetState;
+ Private->SimplePointer.Mode = &Private->PointerMode;
+
+ Status = gBS->CreateEvent (
+ EVT_NOTIFY_WAIT,
+ TPL_NOTIFY,
+ UnixGopSimplePointerWaitForInput,
+ Private,
+ &Private->SimplePointer.WaitForInput
+ );
+
+ return Status;
+}
diff --git a/UnixPkg/UnixGopDxe/UnixGopScreen.c b/UnixPkg/UnixGopDxe/UnixGopScreen.c
new file mode 100644
index 0000000000..943cc83c32
--- /dev/null
+++ b/UnixPkg/UnixGopDxe/UnixGopScreen.c
@@ -0,0 +1,404 @@
+/*++
+
+Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+Portions copyright (c) 2010, Apple, Inc. All rights reserved.
+This program and the accompanying materials
+are licensed and made available under the terms and conditions of the BSD License
+which accompanies this distribution. The full text of the license may be found at
+http://opensource.org/licenses/bsd-license.php
+
+THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ UnixGopScreen.c
+
+Abstract:
+
+ This file produces the graphics abstration of UGA. It is called by
+ UnixGopDriver.c file which deals with the EFI 1.1 driver model.
+ This file just does graphics.
+
+--*/
+
+#include "UnixGop.h"
+
+EFI_UNIX_THUNK_PROTOCOL *mUnix;
+EFI_EVENT mGopScreenExitBootServicesEvent;
+
+GOP_MODE_DATA mGopModeData[] = {
+ { 800, 600, 0, 0 },
+ { 640, 480, 0, 0 },
+ { 720, 400, 0, 0 },
+ {1024, 768, 0, 0 },
+ {1280, 1024, 0, 0 }
+ };
+
+
+EFI_STATUS
+UnixGopStartWindow (
+ IN GOP_PRIVATE_DATA *Private,
+ IN UINT32 HorizontalResolution,
+ IN UINT32 VerticalResolution,
+ IN UINT32 ColorDepth,
+ IN UINT32 RefreshRate
+ );
+
+VOID
+EFIAPI
+KillUgaGopThread (
+ IN EFI_EVENT Event,
+ IN VOID *Context
+ );
+
+//
+// UGA Protocol Member Functions
+//
+
+EFI_STATUS
+EFIAPI
+UnixGopQuerytMode (
+ IN EFI_GRAPHICS_OUTPUT_PROTOCOL *This,
+ IN UINT32 ModeNumber,
+ OUT UINTN *SizeOfInfo,
+ OUT EFI_GRAPHICS_OUTPUT_MODE_INFORMATION **Info
+ )
+{
+ GOP_PRIVATE_DATA *Private;
+
+ Private = GOP_PRIVATE_DATA_FROM_THIS (This);
+
+ if (Info == NULL || SizeOfInfo == NULL || (UINTN) ModeNumber >= This->Mode->MaxMode) {
+ return EFI_INVALID_PARAMETER;
+ }
+
+ *Info = AllocatePool (sizeof (EFI_GRAPHICS_OUTPUT_MODE_INFORMATION));
+ if (*Info == NULL) {
+ return EFI_OUT_OF_RESOURCES;
+ }
+
+ *SizeOfInfo = sizeof (EFI_GRAPHICS_OUTPUT_MODE_INFORMATION);
+
+ (*Info)->Version = 0;
+ (*Info)->HorizontalResolution = Private->ModeData[ModeNumber].HorizontalResolution;
+ (*Info)->VerticalResolution = Private->ModeData[ModeNumber].VerticalResolution;
+ (*Info)->PixelFormat = PixelBltOnly;
+ (*Info)->PixelsPerScanLine = (*Info)->HorizontalResolution;
+
+ return EFI_SUCCESS;
+}
+
+
+
+EFI_STATUS
+EFIAPI
+UnixGopSetMode (
+ IN EFI_GRAPHICS_OUTPUT_PROTOCOL *This,
+ IN UINT32 ModeNumber
+ )
+{
+ EFI_STATUS Status;
+ GOP_PRIVATE_DATA *Private;
+ GOP_MODE_DATA *ModeData;
+ EFI_GRAPHICS_OUTPUT_BLT_PIXEL Fill;
+
+ Private = GOP_PRIVATE_DATA_FROM_THIS (This);
+
+ if (ModeNumber >= This->Mode->MaxMode) {
+ return EFI_UNSUPPORTED;
+ }
+
+ ModeData = &Private->ModeData[ModeNumber];
+ This->Mode->Mode = ModeNumber;
+ Private->GraphicsOutput.Mode->Info->HorizontalResolution = ModeData->HorizontalResolution;
+ Private->GraphicsOutput.Mode->Info->VerticalResolution = ModeData->VerticalResolution;
+ Private->GraphicsOutput.Mode->Info->PixelsPerScanLine = ModeData->HorizontalResolution;
+
+ if (Private->HardwareNeedsStarting) {
+ Status = UnixGopStartWindow (
+ Private,
+ ModeData->HorizontalResolution,
+ ModeData->VerticalResolution,
+ ModeData->ColorDepth,
+ ModeData->RefreshRate
+ );
+ if (EFI_ERROR (Status)) {
+ return EFI_DEVICE_ERROR;
+ }
+
+ Private->HardwareNeedsStarting = FALSE;
+ }
+
+
+ Status = Private->UgaIo->UgaSize(
+ Private->UgaIo,
+ ModeData->HorizontalResolution,
+ ModeData->VerticalResolution
+ );
+
+
+ Fill.Red = 0x7f;
+ Fill.Green = 0x7F;
+ Fill.Blue = 0x7f;
+ This->Blt (
+ This,
+ &Fill,
+ EfiBltVideoFill,
+ 0,
+ 0,
+ 0,
+ 0,
+ ModeData->HorizontalResolution,
+ ModeData->VerticalResolution,
+ ModeData->HorizontalResolution * sizeof (EFI_GRAPHICS_OUTPUT_BLT_PIXEL)
+ );
+ return EFI_SUCCESS;
+}
+
+
+
+EFI_STATUS
+EFIAPI
+UnixGopBlt (
+ IN EFI_GRAPHICS_OUTPUT_PROTOCOL *This,
+ IN EFI_GRAPHICS_OUTPUT_BLT_PIXEL *BltBuffer, OPTIONAL
+ IN EFI_GRAPHICS_OUTPUT_BLT_OPERATION BltOperation,
+ IN UINTN SourceX,
+ IN UINTN SourceY,
+ IN UINTN DestinationX,
+ IN UINTN DestinationY,
+ IN UINTN Width,
+ IN UINTN Height,
+ IN UINTN Delta OPTIONAL
+ )
+{
+ GOP_PRIVATE_DATA *Private;
+ EFI_TPL OriginalTPL;
+ EFI_STATUS Status;
+ UGA_BLT_ARGS GopBltArgs;
+
+ Private = GOP_PRIVATE_DATA_FROM_THIS (This);
+
+ if ((BltOperation < 0) || (BltOperation >= EfiGraphicsOutputBltOperationMax)) {
+ return EFI_INVALID_PARAMETER;
+ }
+
+ if (Width == 0 || Height == 0) {
+ return EFI_INVALID_PARAMETER;
+ }
+ //
+ // If Delta is zero, then the entire BltBuffer is being used, so Delta
+ // is the number of bytes in each row of BltBuffer. Since BltBuffer is Width pixels size,
+ // the number of bytes in each row can be computed.
+ //
+ if (Delta == 0) {
+ Delta = Width * sizeof (EFI_UGA_PIXEL);
+ }
+
+ //
+ // We have to raise to TPL Notify, so we make an atomic write the frame buffer.
+ // We would not want a timer based event (Cursor, ...) to come in while we are
+ // doing this operation.
+ //
+ OriginalTPL = gBS->RaiseTPL (TPL_NOTIFY);
+
+ //
+ // Pack UGA Draw protocol parameters to UGA_BLT_ARGS structure to adapt to
+ // GopBlt() API of Unix UGA IO protocol.
+ //
+ GopBltArgs.DestinationX = DestinationX;
+ GopBltArgs.DestinationY = DestinationY;
+ GopBltArgs.Height = Height;
+ GopBltArgs.Width = Width;
+ GopBltArgs.SourceX = SourceX;
+ GopBltArgs.SourceY = SourceY;
+ GopBltArgs.Delta = Delta;
+ Status = Private->UgaIo->UgaBlt (
+ Private->UgaIo,
+ (EFI_UGA_PIXEL *)BltBuffer,
+ BltOperation,
+ &GopBltArgs
+ );
+
+ gBS->RestoreTPL (OriginalTPL);
+
+ return Status;
+}
+
+
+//
+// Construction and Destruction functions
+//
+
+EFI_STATUS
+UnixGopSupported (
+ IN EFI_UNIX_IO_PROTOCOL *UnixIo
+ )
+/*++
+
+Routine Description:
+
+Arguments:
+
+Returns:
+
+ None
+
+--*/
+// TODO: UnixIo - add argument and description to function comment
+// TODO: EFI_UNSUPPORTED - add return value to function comment
+// TODO: EFI_SUCCESS - add return value to function comment
+{
+ //
+ // Check to see if the IO abstraction represents a device type we support.
+ //
+ // This would be replaced a check of PCI subsystem ID, etc.
+ //
+ if (!CompareGuid (UnixIo->TypeGuid, &gEfiUnixGopGuid)) {
+ return EFI_UNSUPPORTED;
+ }
+
+ return EFI_SUCCESS;
+}
+
+
+VOID
+EFIAPI
+GopPrivateInvokeRegisteredFunction (
+ IN VOID *Context,
+ IN EFI_KEY_DATA *KeyData
+ );
+
+
+EFI_STATUS
+UnixGopStartWindow (
+ IN GOP_PRIVATE_DATA *Private,
+ IN UINT32 HorizontalResolution,
+ IN UINT32 VerticalResolution,
+ IN UINT32 ColorDepth,
+ IN UINT32 RefreshRate
+ )
+{
+ EFI_STATUS Status;
+
+ mUnix = Private->UnixThunk;
+
+ //
+ // Register to be notified on exit boot services so we can destroy the window.
+ //
+ Status = gBS->CreateEvent (
+ EVT_SIGNAL_EXIT_BOOT_SERVICES,
+ TPL_CALLBACK,
+ KillUgaGopThread,
+ Private,
+ &mGopScreenExitBootServicesEvent
+ );
+
+ Status = Private->UnixThunk->UgaCreate (&Private->UgaIo, Private->WindowName);
+ if (!EFI_ERROR (Status)) {
+ // Register callback to support RegisterKeyNotify()
+ Status = Private->UgaIo->UgaRegisterKeyNotify (Private->UgaIo, GopPrivateInvokeRegisteredFunction, Private);
+ ASSERT_EFI_ERROR (Status);
+ }
+ return Status;
+}
+
+EFI_STATUS
+UnixGopConstructor (
+ GOP_PRIVATE_DATA *Private
+ )
+{
+ Private->ModeData = mGopModeData;
+
+ Private->GraphicsOutput.QueryMode = UnixGopQuerytMode;
+ Private->GraphicsOutput.SetMode = UnixGopSetMode;
+ Private->GraphicsOutput.Blt = UnixGopBlt;
+
+ //
+ // Allocate buffer for Graphics Output Protocol mode information
+ //
+ Private->GraphicsOutput.Mode = AllocatePool (sizeof (EFI_GRAPHICS_OUTPUT_PROTOCOL_MODE));
+ if (Private->GraphicsOutput.Mode == NULL) {
+ return EFI_OUT_OF_RESOURCES;
+ }
+ Private->GraphicsOutput.Mode->Info = AllocatePool (sizeof (EFI_GRAPHICS_OUTPUT_MODE_INFORMATION));
+ if (Private->GraphicsOutput.Mode->Info == NULL) {
+ return EFI_OUT_OF_RESOURCES;
+ }
+
+ Private->GraphicsOutput.Mode->MaxMode = sizeof(mGopModeData) / sizeof(GOP_MODE_DATA);
+ //
+ // Till now, we have no idea about the window size.
+ //
+ Private->GraphicsOutput.Mode->Mode = GRAPHICS_OUTPUT_INVALIDE_MODE_NUMBER;
+ Private->GraphicsOutput.Mode->Info->Version = 0;
+ Private->GraphicsOutput.Mode->Info->HorizontalResolution = 0;
+ Private->GraphicsOutput.Mode->Info->VerticalResolution = 0;
+ Private->GraphicsOutput.Mode->Info->PixelFormat = PixelBltOnly;
+ Private->GraphicsOutput.Mode->SizeOfInfo = sizeof (EFI_GRAPHICS_OUTPUT_MODE_INFORMATION);
+ Private->GraphicsOutput.Mode->FrameBufferBase = (EFI_PHYSICAL_ADDRESS) (UINTN) NULL;
+ Private->GraphicsOutput.Mode->FrameBufferSize = 0;
+
+ Private->HardwareNeedsStarting = TRUE;
+ Private->UgaIo = NULL;
+
+ UnixGopInitializeSimpleTextInForWindow (Private);
+
+ UnixGopInitializeSimplePointerForWindow (Private);
+
+ return EFI_SUCCESS;
+}
+
+
+
+EFI_STATUS
+UnixGopDestructor (
+ GOP_PRIVATE_DATA *Private
+ )
+{
+ if (!Private->HardwareNeedsStarting) {
+ Private->UgaIo->UgaClose (Private->UgaIo);
+ Private->UgaIo = NULL;
+ }
+
+ //
+ // Free graphics output protocol occupied resource
+ //
+ if (Private->GraphicsOutput.Mode != NULL) {
+ if (Private->GraphicsOutput.Mode->Info != NULL) {
+ FreePool (Private->GraphicsOutput.Mode->Info);
+ }
+ FreePool (Private->GraphicsOutput.Mode);
+ }
+
+ return EFI_SUCCESS;
+}
+
+VOID
+EFIAPI
+KillUgaGopThread (
+ IN EFI_EVENT Event,
+ IN VOID *Context
+ )
+/*++
+
+Routine Description:
+
+ This is the UGA screen's callback notification function for exit-boot-services.
+ All we do here is call UnixGopDestructor().
+
+Arguments:
+
+ Event - not used
+ Context - pointer to the Private structure.
+
+Returns:
+
+ None.
+
+--*/
+{
+ EFI_STATUS Status;
+ Status = UnixGopDestructor (Context);
+}
diff --git a/UnixPkg/UnixPkg.dec b/UnixPkg/UnixPkg.dec
index f803cd7418..eca2d9d55d 100644
--- a/UnixPkg/UnixPkg.dec
+++ b/UnixPkg/UnixPkg.dec
@@ -47,12 +47,15 @@
gEfiUnixPhysicalDisksGuid = {0xf2bdcc96, 0x8985, 0x11db, {0x87, 0x19, 0x00, 0x40, 0xd0, 0x2b, 0x18, 0x35}}
gEfiUnixFileSystemGuid = {0xf2c16b9e, 0x8985, 0x11db, {0x92, 0xc8, 0x00, 0x40, 0xd0, 0x2b, 0x18, 0x35}}
gEfiUnixUgaGuid = {0xf2c8b80e, 0x8985, 0x11db, {0x93, 0xf1, 0x00, 0x40, 0xd0, 0x2b, 0x18, 0x35}}
+ gEfiUnixGopGuid = {0xbace07c2, 0x8987, 0x11db, {0xa5, 0x9a, 0x00, 0x40, 0xd0, 0x2b, 0x18, 0x35}}
+
gEfiUnixConsoleGuid = {0xf2cc5d06, 0x8985, 0x11db, {0xbb, 0x19, 0x00, 0x40, 0xd0, 0x2b, 0x18, 0x35}}
gEfiUnixMemoryGuid = {0xf2d006cc, 0x8985, 0x11db, {0xa4, 0x72, 0x00, 0x40, 0xd0, 0x2b, 0x18, 0x35}}
gEfiUnixCPUModelGuid = {0xf2d3b330, 0x8985, 0x11db, {0x8a, 0xa3, 0x00, 0x40, 0xd0, 0x2b, 0x18, 0x35}}
gEfiUnixCPUSpeedGuid = {0xf2d74e5a, 0x8985, 0x11db, {0x97, 0x05, 0x00, 0x40, 0xd0, 0x2b, 0x18, 0x35}}
gEfiUnixSerialPortGuid = {0x6d3a727d, 0x66c8, 0x4d19, {0x87, 0xe6, 0x02, 0x15, 0x86, 0x14, 0x90, 0xf3}}
gEfiUnixSystemConfigGuid = {0x375ea976, 0x3ccd, 0x4e74, {0xa8, 0x45, 0x26, 0xb9, 0xb3, 0x24, 0xb1, 0x3c}}
+ gEfiUnixNetworkGuid = {0x081603B4, 0x0F1D, 0x4022, {0xB6, 0xFD, 0x4C, 0xE3, 0x5E, 0x09, 0xA1, 0xA6}}
[PcdsFixedAtBuild]
gEfiUnixPkgTokenSpaceGuid.PcdUnixBootMode|1|UINT32|0x00001006
@@ -79,12 +82,14 @@
gEfiUnixPkgTokenSpaceGuid.PcdUnixPhysicalDisk|L"E:RW;245760;512"|VOID*|0x00001000
gEfiUnixPkgTokenSpaceGuid.PcdUnixVirtualDisk|L"FW;40960;512"|VOID*|0x00001001
gEfiUnixPkgTokenSpaceGuid.PcdUnixUga|L"UGA Window"|VOID*|0x00001003
+ gEfiUnixPkgTokenSpaceGuid.PcdUnixGop|L"GOP Window"|VOID*|0x0000100e
gEfiUnixPkgTokenSpaceGuid.PcdUnixFileSystem|L".!..\\..\\..\\..\\..\\EdkShellBinPkg\\bin\\ia32\\Apps"|VOID*|0x00001004
gEfiUnixPkgTokenSpaceGuid.PcdUnixMemorySize|L"64!64"|VOID*|0x00001005
gEfiUnixPkgTokenSpaceGuid.PcdUnixCpuModel|L"Intel(R) Processor Model"|VOID*|0x00001007
gEfiUnixPkgTokenSpaceGuid.PcdUnixCpuSpeed|L"3000"|VOID*|0x00001008
gEfiUnixPkgTokenSpaceGuid.PcdUnixConsole|L"Bus Driver Console Window"|VOID*|0x0000100a
gEfiUnixPkgTokenSpaceGuid.PcdUnixSerialPort|L"/dev/ttyS0"|VOID*|0x00001002
+ gEfiUnixPkgTokenSpaceGuid.PcdUnixNetworkInterface|L"en0"|VOID*|0x0000100d
[PcdsPatchableInModule]
diff --git a/UnixPkg/UnixPkg.dsc b/UnixPkg/UnixPkg.dsc
index c76ea25c79..db57dc1a77 100644
--- a/UnixPkg/UnixPkg.dsc
+++ b/UnixPkg/UnixPkg.dsc
@@ -199,6 +199,7 @@
gEfiUnixPkgTokenSpaceGuid.PcdUnixCpuSpeed|L"3000"
gEfiUnixPkgTokenSpaceGuid.PcdUnixMemorySize|L"128!128"
gEfiUnixPkgTokenSpaceGuid.PcdUnixSerialPort|L"/dev/ttyS0!/dev/ttyS1"
+ gEfiUnixPkgTokenSpaceGuid.PcdUnixNetworkInterface|L"en0"
[PcdsDynamicHii.common.DEFAULT]
gEfiMdeModulePkgTokenSpaceGuid.PcdConOutColumn|L"Setup"|gEfiUnixSystemConfigGuid|0x0|80
@@ -295,14 +296,16 @@
UnixPkg/UnixBlockIoDxe/UnixBlockIo.inf
UnixPkg/UnixSerialIoDxe/UnixSerialIo.inf
UnixPkg/UnixUgaDxe/UnixUga.inf
+ UnixPkg/UnixGopDxe/UnixGop.inf
+
UnixPkg/UnixConsoleDxe/UnixConsole.inf
UnixPkg/UnixSimpleFileSystemDxe/UnixSimpleFileSystem.inf
MdeModulePkg/Application/HelloWorld/HelloWorld.inf
#
# Network stack drivers
- # To test network drivers, need network Io driver(SnpNt32Io.dll), please refer to NETWORK-IO Subproject.
#
+ UnixPkg/UnixSnpDxe/UnixSnpDxe.inf
MdeModulePkg/Universal/Network/DpcDxe/DpcDxe.inf
MdeModulePkg/Universal/Network/ArpDxe/ArpDxe.inf
MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Dxe.inf
diff --git a/UnixPkg/UnixPkg.fdf b/UnixPkg/UnixPkg.fdf
index 81929cfc59..22c134f9a0 100644
--- a/UnixPkg/UnixPkg.fdf
+++ b/UnixPkg/UnixPkg.fdf
@@ -217,7 +217,9 @@ INF UnixPkg/UnixBusDriverDxe/UnixBusDriver.inf
INF MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.inf
INF UnixPkg/UnixBlockIoDxe/UnixBlockIo.inf
INF UnixPkg/UnixSerialIoDxe/UnixSerialIo.inf
-INF UnixPkg/UnixUgaDxe/UnixUga.inf
+#INF UnixPkg/UnixUgaDxe/UnixUga.inf
+INF UnixPkg/UnixGopDxe/UnixGop.inf
+
#INF UnixPkg/UnixConsoleDxe/UnixConsole.inf
INF MdeModulePkg/Universal/HiiDatabaseDxe/HiiDatabaseDxe.inf
INF MdeModulePkg/Universal/SetupBrowserDxe/SetupBrowserDxe.inf
@@ -229,19 +231,18 @@ INF MdeModulePkg/Application/HelloWorld/HelloWorld.inf
#
# Network stack drivers
-# To test network drivers, need network Io driver(SnpNt32Io.dll), please refer to NETWORK-IO Subproject.
#
-#INF MdeModulePkg/Universal/Network/DpcDxe/DpcDxe.inf
-#INF MdeModulePkg/Universal/Network/ArpDxe/ArpDxe.inf
-#INF MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Dxe.inf
-#INF MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDxe.inf
-#INF MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Dxe.inf
-#INF MdeModulePkg/Universal/Network/MnpDxe/MnpDxe.inf
-#INF MdeModulePkg/Universal/Network/VlanConfigDxe/VlanConfigDxe.inf
-#INF MdeModulePkg/Universal/Network/Mtftp4Dxe/Mtftp4Dxe.inf
-#INF MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Dxe.inf
-#INF MdeModulePkg/Universal/Network/Udp4Dxe/Udp4Dxe.inf
-#INF UnixPkg/SnpUnixDxe/SnpUnixDxe.inf
+INF MdeModulePkg/Universal/Network/DpcDxe/DpcDxe.inf
+INF MdeModulePkg/Universal/Network/ArpDxe/ArpDxe.inf
+INF MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Dxe.inf
+INF MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDxe.inf
+INF MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Dxe.inf
+INF MdeModulePkg/Universal/Network/MnpDxe/MnpDxe.inf
+INF MdeModulePkg/Universal/Network/VlanConfigDxe/VlanConfigDxe.inf
+INF MdeModulePkg/Universal/Network/Mtftp4Dxe/Mtftp4Dxe.inf
+INF MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Dxe.inf
+INF MdeModulePkg/Universal/Network/Udp4Dxe/Udp4Dxe.inf
+INF UnixPkg/UnixSnpDxe/UnixSnpDxe.inf
#
# Build from source or use checked in binary
diff --git a/UnixPkg/UnixPkgX64.dsc b/UnixPkg/UnixPkgX64.dsc
index c4470cc27a..90f8ac1ae7 100644
--- a/UnixPkg/UnixPkgX64.dsc
+++ b/UnixPkg/UnixPkgX64.dsc
@@ -5,6 +5,7 @@
# The Emulation Platform can be used to debug individual modules, prior to creating
# a real platform. This also provides an example for how an DSC is created.
# Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
+# Portions copywrite (c) 2010, Apple, Inc. All rights reserved.
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
@@ -199,6 +200,7 @@
gEfiUnixPkgTokenSpaceGuid.PcdUnixCpuSpeed|L"3000"
gEfiUnixPkgTokenSpaceGuid.PcdUnixMemorySize|L"128!128"
gEfiUnixPkgTokenSpaceGuid.PcdUnixSerialPort|L"/dev/ttyS0!/dev/ttyS1"
+ gEfiUnixPkgTokenSpaceGuid.PcdUnixNetworkInterface|L"en0"
[PcdsDynamicHii.common.DEFAULT]
gEfiMdeModulePkgTokenSpaceGuid.PcdConOutColumn|L"Setup"|gEfiUnixSystemConfigGuid|0x0|80
@@ -223,7 +225,7 @@
# generated for it, but the binary will not be put into any firmware volume.
#
###################################################################################################
-[Components.common]
+[Components]
!if $(SEC_ONLY)
##
# SEC Phase modules
@@ -296,14 +298,15 @@
UnixPkg/UnixBlockIoDxe/UnixBlockIo.inf
UnixPkg/UnixSerialIoDxe/UnixSerialIo.inf
UnixPkg/UnixUgaDxe/UnixUga.inf
+ UnixPkg/UnixGopDxe/UnixGop.inf
UnixPkg/UnixConsoleDxe/UnixConsole.inf
UnixPkg/UnixSimpleFileSystemDxe/UnixSimpleFileSystem.inf
MdeModulePkg/Application/HelloWorld/HelloWorld.inf
#
# Network stack drivers
- # To test network drivers, need network Io driver(SnpNt32Io.dll), please refer to NETWORK-IO Subproject.
#
+ UnixPkg/UnixSnpDxe/UnixSnpDxe.inf
MdeModulePkg/Universal/Network/DpcDxe/DpcDxe.inf
MdeModulePkg/Universal/Network/ArpDxe/ArpDxe.inf
MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Dxe.inf
diff --git a/UnixPkg/UnixPkgX64.fdf b/UnixPkg/UnixPkgX64.fdf
index 9f677464e1..a38a46155b 100644
--- a/UnixPkg/UnixPkgX64.fdf
+++ b/UnixPkg/UnixPkgX64.fdf
@@ -2,6 +2,7 @@
# This is Unix FDF file with UEFI HII features enabled
#
# Copyright (c) 2008 - 2010, Intel Corporation. All rights reserved.<BR>
+# Portions copyright (c) 2009 - 2010, Apple Inc. All rights reserved.
#
# This program and the accompanying materials
# are licensed and made available under the terms and conditions of the BSD License
@@ -32,10 +33,10 @@
# relocated in place (works, but not a great idea).
#
BaseAddress = 0x102000000|gEfiUnixPkgTokenSpaceGuid.PcdUnixFdBaseAddress #The base address of the FLASH Device.
-Size = 0x004a0000|gEfiUnixPkgTokenSpaceGuid.PcdUnixFirmwareFdSize #The size in bytes of the FLASH Device
+Size = 0x005a0000|gEfiUnixPkgTokenSpaceGuid.PcdUnixFirmwareFdSize #The size in bytes of the FLASH Device
ErasePolarity = 1
BlockSize = 0x10000
-NumBlocks = 0x4a
+NumBlocks = 0x5a
################################################################################
#
@@ -52,11 +53,11 @@ NumBlocks = 0x4a
# RegionType <FV, DATA, or FILE>
#
################################################################################
-0x00000000|0x00480000
+0x00000000|0x00580000
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashFvRecoveryBase|gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashFvRecoverySize
FV = FvRecovery
-0x00480000|0x0000c000
+0x00580000|0x0000c000
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageVariableBase|gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageVariableSize
#NV_VARIABLE_STORE
DATA = {
@@ -90,11 +91,11 @@ DATA = {
0x5A, 0xFE, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
}
-0x0048c000|0x00002000
+0x0058c000|0x00002000
#NV_EVENT_LOG
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageEventLogBase|gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageEventLogSize
-0x0048e000|0x00002000
+0x0058e000|0x00002000
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageFtwWorkingBase|gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwWorkingSize
#NV_FTW_WORKING
DATA = {
@@ -108,7 +109,7 @@ DATA = {
0xE0, 0x1F, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00
}
-0x00490000|0x00010000
+0x00590000|0x00010000
#NV_FTW_SPARE
gEfiUnixPkgTokenSpaceGuid.PcdUnixFlashNvStorageFtwSpareBase|gEfiMdeModulePkgTokenSpaceGuid.PcdFlashNvStorageFtwSpareSize
@@ -217,7 +218,8 @@ INF UnixPkg/UnixBusDriverDxe/UnixBusDriver.inf
INF MdeModulePkg/Universal/SmbiosDxe/SmbiosDxe.inf
INF UnixPkg/UnixBlockIoDxe/UnixBlockIo.inf
INF UnixPkg/UnixSerialIoDxe/UnixSerialIo.inf
-INF UnixPkg/UnixUgaDxe/UnixUga.inf
+#INF UnixPkg/UnixUgaDxe/UnixUga.inf
+INF UnixPkg/UnixGopDxe/UnixGop.inf
#INF UnixPkg/UnixConsoleDxe/UnixConsole.inf
INF MdeModulePkg/Universal/HiiDatabaseDxe/HiiDatabaseDxe.inf
INF MdeModulePkg/Universal/SetupBrowserDxe/SetupBrowserDxe.inf
@@ -228,21 +230,20 @@ INF MdeModulePkg/Universal/DriverSampleDxe/DriverSampleDxe.inf
INF MdeModulePkg/Application/HelloWorld/HelloWorld.inf
#
-# Need to port this to UnixPkg
# Network stack drivers
-# To test network drivers, need network Io driver(SnpNt32Io.dll), please refer to NETWORK-IO Subproject.
#
-#INF MdeModulePkg/Universal/Network/DpcDxe/DpcDxe.inf
-#INF MdeModulePkg/Universal/Network/ArpDxe/ArpDxe.inf
-#INF MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Dxe.inf
-#INF MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDxe.inf
-#INF MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Dxe.inf
-#INF MdeModulePkg/Universal/Network/MnpDxe/MnpDxe.inf
-#INF MdeModulePkg/Universal/Network/VlanConfigDxe/VlanConfigDxe.inf
-#INF MdeModulePkg/Universal/Network/Mtftp4Dxe/Mtftp4Dxe.inf
-#INF MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Dxe.inf
-#INF MdeModulePkg/Universal/Network/Udp4Dxe/Udp4Dxe.inf
-#INF UnixPkg/SnpUnixDxe/SnpUnixDxe.inf
+INF UnixPkg/UnixSnpDxe/UnixSnpDxe.inf
+INF MdeModulePkg/Universal/Network/DpcDxe/DpcDxe.inf
+INF MdeModulePkg/Universal/Network/ArpDxe/ArpDxe.inf
+INF MdeModulePkg/Universal/Network/Dhcp4Dxe/Dhcp4Dxe.inf
+INF MdeModulePkg/Universal/Network/Ip4ConfigDxe/Ip4ConfigDxe.inf
+INF MdeModulePkg/Universal/Network/Ip4Dxe/Ip4Dxe.inf
+INF MdeModulePkg/Universal/Network/MnpDxe/MnpDxe.inf
+INF MdeModulePkg/Universal/Network/VlanConfigDxe/VlanConfigDxe.inf
+INF MdeModulePkg/Universal/Network/Mtftp4Dxe/Mtftp4Dxe.inf
+INF MdeModulePkg/Universal/Network/Tcp4Dxe/Tcp4Dxe.inf
+INF MdeModulePkg/Universal/Network/Udp4Dxe/Udp4Dxe.inf
+
!if $(COMPILE_BINS)
INF FatPkg/EnhancedFatDxe/Fat.inf
diff --git a/UnixPkg/UnixSnpDxe/ComponentName.c b/UnixPkg/UnixSnpDxe/ComponentName.c
new file mode 100644
index 0000000000..560a313ba7
--- /dev/null
+++ b/UnixPkg/UnixSnpDxe/ComponentName.c
@@ -0,0 +1,318 @@
+/** @file
+
+ Copyright (c) 2010, Apple, Inc. All rights reserved.
+
+ This program and the accompanying materials
+ are licensed and made available under the terms and conditions of the BSD License
+ which accompanies this distribution. The full text of the license may be found at
+ http://opensource.org/licenses/bsd-license.php
+
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ ComponentName.c
+
+Abstract:
+
+-**/
+
+#include "UnixSnp.h"
+
+//
+// EFI Component Name Functions
+//
+/**
+ Retrieves a Unicode string that is the user readable name of the driver.
+
+ This function retrieves the user readable name of a driver in the form of a
+ Unicode string. If the driver specified by This has a user readable name in
+ the language specified by Language, then a pointer to the driver name is
+ returned in DriverName, and EFI_SUCCESS is returned. If the driver specified
+ by This does not support the language specified by Language,
+ then EFI_UNSUPPORTED is returned.
+
+ @param This[in] A pointer to the EFI_COMPONENT_NAME2_PROTOCOL or
+ EFI_COMPONENT_NAME_PROTOCOL instance.
+
+ @param Language[in] A pointer to a Null-terminated ASCII string
+ array indicating the language. This is the
+ language of the driver name that the caller is
+ requesting, and it must match one of the
+ languages specified in SupportedLanguages. The
+ number of languages supported by a driver is up
+ to the driver writer. Language is specified
+ in RFC 4646 or ISO 639-2 language code format.
+
+ @param DriverName[out] A pointer to the Unicode string to return.
+ This Unicode string is the name of the
+ driver specified by This in the language
+ specified by Language.
+
+ @retval EFI_SUCCESS The Unicode string for the Driver specified by
+ This and the language specified by Language was
+ returned in DriverName.
+
+ @retval EFI_INVALID_PARAMETER Language is NULL.
+
+ @retval EFI_INVALID_PARAMETER DriverName is NULL.
+
+ @retval EFI_UNSUPPORTED The driver specified by This does not support
+ the language specified by Language.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpDriverComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ );
+
+
+/**
+ Retrieves a Unicode string that is the user readable name of the controller
+ that is being managed by a driver.
+
+ This function retrieves the user readable name of the controller specified by
+ ControllerHandle and ChildHandle in the form of a Unicode string. If the
+ driver specified by This has a user readable name in the language specified by
+ Language, then a pointer to the controller name is returned in ControllerName,
+ and EFI_SUCCESS is returned. If the driver specified by This is not currently
+ managing the controller specified by ControllerHandle and ChildHandle,
+ then EFI_UNSUPPORTED is returned. If the driver specified by This does not
+ support the language specified by Language, then EFI_UNSUPPORTED is returned.
+
+ @param This[in] A pointer to the EFI_COMPONENT_NAME2_PROTOCOL or
+ EFI_COMPONENT_NAME_PROTOCOL instance.
+
+ @param ControllerHandle[in] The handle of a controller that the driver
+ specified by This is managing. This handle
+ specifies the controller whose name is to be
+ returned.
+
+ @param ChildHandle[in] The handle of the child controller to retrieve
+ the name of. This is an optional parameter that
+ may be NULL. It will be NULL for device
+ drivers. It will also be NULL for a bus drivers
+ that wish to retrieve the name of the bus
+ controller. It will not be NULL for a bus
+ driver that wishes to retrieve the name of a
+ child controller.
+
+ @param Language[in] A pointer to a Null-terminated ASCII string
+ array indicating the language. This is the
+ language of the driver name that the caller is
+ requesting, and it must match one of the
+ languages specified in SupportedLanguages. The
+ number of languages supported by a driver is up
+ to the driver writer. Language is specified in
+ RFC 4646 or ISO 639-2 language code format.
+
+ @param ControllerName[out] A pointer to the Unicode string to return.
+ This Unicode string is the name of the
+ controller specified by ControllerHandle and
+ ChildHandle in the language specified by
+ Language from the point of view of the driver
+ specified by This.
+
+ @retval EFI_SUCCESS The Unicode string for the user readable name in
+ the language specified by Language for the
+ driver specified by This was returned in
+ DriverName.
+
+ @retval EFI_INVALID_PARAMETER ControllerHandle is not a valid EFI_HANDLE.
+
+ @retval EFI_INVALID_PARAMETER ChildHandle is not NULL and it is not a valid
+ EFI_HANDLE.
+
+ @retval EFI_INVALID_PARAMETER Language is NULL.
+
+ @retval EFI_INVALID_PARAMETER ControllerName is NULL.
+
+ @retval EFI_UNSUPPORTED The driver specified by This is not currently
+ managing the controller specified by
+ ControllerHandle and ChildHandle.
+
+ @retval EFI_UNSUPPORTED The driver specified by This does not support
+ the language specified by Language.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpDriverComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ );
+
+
+//
+// EFI Component Name Protocol
+//
+GLOBAL_REMOVE_IF_UNREFERENCED EFI_COMPONENT_NAME_PROTOCOL gUnixSnpDriverComponentName = {
+ UnixSnpDriverComponentNameGetDriverName,
+ UnixSnpDriverComponentNameGetControllerName,
+ "eng"
+};
+
+//
+// EFI Component Name 2 Protocol
+//
+GLOBAL_REMOVE_IF_UNREFERENCED EFI_COMPONENT_NAME2_PROTOCOL gUnixSnpDriverComponentName2 = {
+ (EFI_COMPONENT_NAME2_GET_DRIVER_NAME) UnixSnpDriverComponentNameGetDriverName,
+ (EFI_COMPONENT_NAME2_GET_CONTROLLER_NAME) UnixSnpDriverComponentNameGetControllerName,
+ "en"
+};
+
+
+GLOBAL_REMOVE_IF_UNREFERENCED EFI_UNICODE_STRING_TABLE mUnixSnpDriverNameTable[] = {
+ {
+ "eng;en",
+ L"Unix SNP Driver"
+ },
+ {
+ NULL,
+ NULL
+ }
+};
+
+/**
+ Retrieves a Unicode string that is the user readable name of the driver.
+
+ This function retrieves the user readable name of a driver in the form of a
+ Unicode string. If the driver specified by This has a user readable name in
+ the language specified by Language, then a pointer to the driver name is
+ returned in DriverName, and EFI_SUCCESS is returned. If the driver specified
+ by This does not support the language specified by Language,
+ then EFI_UNSUPPORTED is returned.
+
+ @param This[in] A pointer to the EFI_COMPONENT_NAME2_PROTOCOL or
+ EFI_COMPONENT_NAME_PROTOCOL instance.
+
+ @param Language[in] A pointer to a Null-terminated ASCII string
+ array indicating the language. This is the
+ language of the driver name that the caller is
+ requesting, and it must match one of the
+ languages specified in SupportedLanguages. The
+ number of languages supported by a driver is up
+ to the driver writer. Language is specified
+ in RFC 4646 or ISO 639-2 language code format.
+
+ @param DriverName[out] A pointer to the Unicode string to return.
+ This Unicode string is the name of the
+ driver specified by This in the language
+ specified by Language.
+
+ @retval EFI_SUCCESS The Unicode string for the Driver specified by
+ This and the language specified by Language was
+ returned in DriverName.
+
+ @retval EFI_INVALID_PARAMETER Language is NULL.
+
+ @retval EFI_INVALID_PARAMETER DriverName is NULL.
+
+ @retval EFI_UNSUPPORTED The driver specified by This does not support
+ the language specified by Language.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpDriverComponentNameGetDriverName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN CHAR8 *Language,
+ OUT CHAR16 **DriverName
+ )
+{
+ return LookupUnicodeString2 (
+ Language,
+ This->SupportedLanguages,
+ mUnixSnpDriverNameTable,
+ DriverName,
+ (BOOLEAN)(This == &gUnixSnpDriverComponentName)
+ );
+}
+
+/**
+ Retrieves a Unicode string that is the user readable name of the controller
+ that is being managed by a driver.
+
+ This function retrieves the user readable name of the controller specified by
+ ControllerHandle and ChildHandle in the form of a Unicode string. If the
+ driver specified by This has a user readable name in the language specified by
+ Language, then a pointer to the controller name is returned in ControllerName,
+ and EFI_SUCCESS is returned. If the driver specified by This is not currently
+ managing the controller specified by ControllerHandle and ChildHandle,
+ then EFI_UNSUPPORTED is returned. If the driver specified by This does not
+ support the language specified by Language, then EFI_UNSUPPORTED is returned.
+
+ @param This[in] A pointer to the EFI_COMPONENT_NAME2_PROTOCOL or
+ EFI_COMPONENT_NAME_PROTOCOL instance.
+
+ @param ControllerHandle[in] The handle of a controller that the driver
+ specified by This is managing. This handle
+ specifies the controller whose name is to be
+ returned.
+
+ @param ChildHandle[in] The handle of the child controller to retrieve
+ the name of. This is an optional parameter that
+ may be NULL. It will be NULL for device
+ drivers. It will also be NULL for a bus drivers
+ that wish to retrieve the name of the bus
+ controller. It will not be NULL for a bus
+ driver that wishes to retrieve the name of a
+ child controller.
+
+ @param Language[in] A pointer to a Null-terminated ASCII string
+ array indicating the language. This is the
+ language of the driver name that the caller is
+ requesting, and it must match one of the
+ languages specified in SupportedLanguages. The
+ number of languages supported by a driver is up
+ to the driver writer. Language is specified in
+ RFC 4646 or ISO 639-2 language code format.
+
+ @param ControllerName[out] A pointer to the Unicode string to return.
+ This Unicode string is the name of the
+ controller specified by ControllerHandle and
+ ChildHandle in the language specified by
+ Language from the point of view of the driver
+ specified by This.
+
+ @retval EFI_SUCCESS The Unicode string for the user readable name in
+ the language specified by Language for the
+ driver specified by This was returned in
+ DriverName.
+
+ @retval EFI_INVALID_PARAMETER ControllerHandle is not a valid EFI_HANDLE.
+
+ @retval EFI_INVALID_PARAMETER ChildHandle is not NULL and it is not a valid
+ EFI_HANDLE.
+
+ @retval EFI_INVALID_PARAMETER Language is NULL.
+
+ @retval EFI_INVALID_PARAMETER ControllerName is NULL.
+
+ @retval EFI_UNSUPPORTED The driver specified by This is not currently
+ managing the controller specified by
+ ControllerHandle and ChildHandle.
+
+ @retval EFI_UNSUPPORTED The driver specified by This does not support
+ the language specified by Language.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpDriverComponentNameGetControllerName (
+ IN EFI_COMPONENT_NAME_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_HANDLE ChildHandle OPTIONAL,
+ IN CHAR8 *Language,
+ OUT CHAR16 **ControllerName
+ )
+{
+ return EFI_UNSUPPORTED;
+}
diff --git a/UnixPkg/UnixSnpDxe/UnixSnp.c b/UnixPkg/UnixSnpDxe/UnixSnp.c
new file mode 100644
index 0000000000..56a014e40a
--- /dev/null
+++ b/UnixPkg/UnixSnpDxe/UnixSnp.c
@@ -0,0 +1,1791 @@
+/** @file
+
+ Copyright (c) 2010, Apple, Inc. All rigths reserved.
+
+ This program and the accompanying materials
+ are licensed and made available under the terms and conditions of the BSD License
+ which accompanies this distribution. The full text of the license may be found at
+ http://opensource.org/licenses/bsd-license.php
+
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ UnixSnp.c
+
+Abstract:
+
+-**/
+
+#include <Library/PrintLib.h>
+
+#include "UnixSnp.h"
+
+EFI_DRIVER_BINDING_PROTOCOL gUnixSnpDriverBinding =
+{
+ UnixSnpDriverBindingSupported,
+ UnixSnpDriverBindingStart,
+ UnixSnpDriverBindingStop,
+ 0xA,
+ NULL,
+ NULL
+};
+
+/**
+ Changes the state of a network interface from "stopped" to "started".
+
+ @param This Protocol instance pointer.
+
+ @retval EFI_SUCCESS Always succeeds.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpStart(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This
+ );
+
+/**
+ Changes the state of a network interface from "started" to "stopped".
+
+ @param This Protocol instance pointer.
+
+ @retval EFI_SUCCESS Always succeeds.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpStop(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This
+ );
+
+/**
+ Resets a network adapter and allocates the transmit and receive buffers
+ required by the network interface; optionally, also requests allocation
+ of additional transmit and receive buffers.
+
+ @param This Protocol instance pointer.
+ @param ExtraRxBufferSize The size, in bytes, of the extra receive buffer space
+ that the driver should allocate for the network interface.
+ Some network interfaces will not be able to use the extra
+ buffer, and the caller will not know if it is actually
+ being used.
+ @param ExtraTxBufferSize The size, in bytes, of the extra transmit buffer space
+ that the driver should allocate for the network interface.
+ Some network interfaces will not be able to use the extra
+ buffer, and the caller will not know if it is actually
+ being used.
+
+ @retval EFI_SUCCESS Always succeeds.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpInitialize(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ IN UINTN ExtraRxBufferSize OPTIONAL,
+ IN UINTN ExtraTxBufferSize OPTIONAL
+ );
+
+/**
+ Resets a network adapter and re-initializes it with the parameters that were
+ provided in the previous call to Initialize().
+
+ @param This Protocol instance pointer.
+ @param ExtendedVerification Indicates that the driver may perform a more
+ exhaustive verification operation of the device
+ during reset.
+
+ @retval EFI_SUCCESS Always succeeds.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpReset(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ IN BOOLEAN ExtendedVerification
+ );
+
+/**
+ Resets a network adapter and leaves it in a state that is safe for
+ another driver to initialize.
+
+ @param This Protocol instance pointer.
+
+ @retval EFI_SUCCESS Always succeeds.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpShutdown(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This
+ );
+
+/**
+ Manages the multicast receive filters of a network interface.
+
+ @param This Protocol instance pointer.
+ @param EnableBits A bit mask of receive filters to enable on the network interface.
+ @param DisableBits A bit mask of receive filters to disable on the network interface.
+ @param ResetMcastFilter Set to TRUE to reset the contents of the multicast receive
+ filters on the network interface to their default values.
+ @param McastFilterCount Number of multicast HW MAC addresses in the new
+ MCastFilter list. This value must be less than or equal to
+ the MCastFilterCnt field of EFI_SIMPLE_NETWORK_MODE. This
+ field is optional if ResetMCastFilter is TRUE.
+ @param McastFilter A pointer to a list of new multicast receive filter HW MAC
+ addresses. This list will replace any existing multicast
+ HW MAC address list. This field is optional if
+ ResetMCastFilter is TRUE.
+
+ @retval EFI_SUCCESS The multicast receive filter list was updated.
+ @retval EFI_DEVICE_ERROR The command could not be sent to the network interface.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpReceiveFilters(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ IN UINT32 EnableBits,
+ IN UINT32 DisableBits,
+ IN BOOLEAN ResetMcastFilter,
+ IN UINTN McastFilterCount OPTIONAL,
+ IN EFI_MAC_ADDRESS* McastFilter OPTIONAL
+ );
+
+/**
+ Modifies or resets the current station address, if supported.
+
+ @param This Protocol instance pointer.
+ @param Reset Flag used to reset the station address to the network interfaces
+ permanent address.
+ @param NewMacAddr New station address to be used for the network interface.
+
+ @retval EFI_UNSUPPORTED Not supported yet.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpStationAddress(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ IN BOOLEAN Reset,
+ IN EFI_MAC_ADDRESS* NewMacAddr OPTIONAL
+ );
+
+/**
+ Resets or collects the statistics on a network interface.
+
+ @param This Protocol instance pointer.
+ @param Reset Set to TRUE to reset the statistics for the network interface.
+ @param StatisticsSize On input the size, in bytes, of StatisticsTable. On
+ output the size, in bytes, of the resulting table of
+ statistics.
+ @param StatisticsTable A pointer to the EFI_NETWORK_STATISTICS structure that
+ contains the statistics.
+
+ @retval EFI_SUCCESS The statistics were collected from the network interface.
+ @retval EFI_NOT_STARTED The network interface has not been started.
+ @retval EFI_BUFFER_TOO_SMALL The Statistics buffer was too small. The current buffer
+ size needed to hold the statistics is returned in
+ StatisticsSize.
+ @retval EFI_UNSUPPORTED Not supported yet.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpStatistics(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ IN BOOLEAN Reset,
+ IN OUT UINTN* StatisticsSize OPTIONAL,
+ OUT EFI_NETWORK_STATISTICS* StatisticsTable OPTIONAL
+ );
+
+/**
+ Converts a multicast IP address to a multicast HW MAC address.
+
+ @param This Protocol instance pointer.
+ @param Ipv6 Set to TRUE if the multicast IP address is IPv6 [RFC 2460]. Set
+ to FALSE if the multicast IP address is IPv4 [RFC 791].
+ @param Ip The multicast IP address that is to be converted to a multicast
+ HW MAC address.
+ @param Mac The multicast HW MAC address that is to be generated from IP.
+
+ @retval EFI_SUCCESS The multicast IP address was mapped to the multicast
+ HW MAC address.
+ @retval EFI_NOT_STARTED The network interface has not been started.
+ @retval EFI_BUFFER_TOO_SMALL The Statistics buffer was too small. The current buffer
+ size needed to hold the statistics is returned in
+ StatisticsSize.
+ @retval EFI_UNSUPPORTED Not supported yet.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpMcastIptoMac(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ IN BOOLEAN Ipv6,
+ IN EFI_IP_ADDRESS* Ip,
+ OUT EFI_MAC_ADDRESS* Mac
+ );
+
+/**
+ Performs read and write operations on the NVRAM device attached to a
+ network interface.
+
+ @param This Protocol instance pointer.
+ @param ReadOrWrite TRUE for read operations, FALSE for write operations.
+ @param Offset Byte offset in the NVRAM device at which to start the read or
+ write operation. This must be a multiple of NvRamAccessSize and
+ less than NvRamSize.
+ @param BufferSize The number of bytes to read or write from the NVRAM device.
+ This must also be a multiple of NvramAccessSize.
+ @param Buffer A pointer to the data buffer.
+
+ @retval EFI_UNSUPPORTED Not supported yet.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpNvdata(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ IN BOOLEAN ReadOrWrite,
+ IN UINTN Offset,
+ IN UINTN BufferSize,
+ IN OUT VOID* Buffer
+ );
+
+/**
+ Reads the current interrupt status and recycled transmit buffer status from
+ a network interface.
+
+ @param This Protocol instance pointer.
+ @param InterruptStatus A pointer to the bit mask of the currently active interrupts
+ If this is NULL, the interrupt status will not be read from
+ the device. If this is not NULL, the interrupt status will
+ be read from the device. When the interrupt status is read,
+ it will also be cleared. Clearing the transmit interrupt
+ does not empty the recycled transmit buffer array.
+ @param TxBuffer Recycled transmit buffer address. The network interface will
+ not transmit if its internal recycled transmit buffer array
+ is full. Reading the transmit buffer does not clear the
+ transmit interrupt. If this is NULL, then the transmit buffer
+ status will not be read. If there are no transmit buffers to
+ recycle and TxBuf is not NULL, * TxBuf will be set to NULL.
+
+ @retval EFI_SUCCESS Always succeeds.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpGetStatus(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ OUT UINT32* InterruptStatus,
+ OUT VOID** TxBuffer
+ );
+
+/**
+ Places a packet in the transmit queue of a network interface.
+
+ @param This Protocol instance pointer.
+ @param HeaderSize The size, in bytes, of the media header to be filled in by
+ the Transmit() function. If HeaderSize is non-zero, then it
+ must be equal to This->Mode->MediaHeaderSize and the DestAddr
+ and Protocol parameters must not be NULL.
+ @param BufferSize The size, in bytes, of the entire packet (media header and
+ data) to be transmitted through the network interface.
+ @param Buffer A pointer to the packet (media header followed by data) to be
+ transmitted. This parameter cannot be NULL. If HeaderSize is zero,
+ then the media header in Buffer must already be filled in by the
+ caller. If HeaderSize is non-zero, then the media header will be
+ filled in by the Transmit() function.
+ @param SrcAddr The source HW MAC address. If HeaderSize is zero, then this parameter
+ is ignored. If HeaderSize is non-zero and SrcAddr is NULL, then
+ This->Mode->CurrentAddress is used for the source HW MAC address.
+ @param DestAddr The destination HW MAC address. If HeaderSize is zero, then this
+ parameter is ignored.
+ @param Protocol The type of header to build. If HeaderSize is zero, then this
+ parameter is ignored. See RFC 1700, section "Ether Types", for
+ examples.
+
+ @retval EFI_SUCCESS The packet was placed on the transmit queue.
+ @retval EFI_DEVICE_ERROR The command could not be sent to the network interface.
+ @retval EFI_ACCESS_DENIED Error acquire global lock for operation.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpTransmit(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ IN UINTN HeaderSize,
+ IN UINTN BufferSize,
+ IN VOID* Buffer,
+ IN EFI_MAC_ADDRESS* SrcAddr OPTIONAL,
+ IN EFI_MAC_ADDRESS* DestAddr OPTIONAL,
+ IN UINT16* Protocol OPTIONAL
+ );
+
+/**
+ Receives a packet from a network interface.
+
+ @param This Protocol instance pointer.
+ @param HeaderSize The size, in bytes, of the media header received on the network
+ interface. If this parameter is NULL, then the media header size
+ will not be returned.
+ @param BuffSize On entry, the size, in bytes, of Buffer. On exit, the size, in
+ bytes, of the packet that was received on the network interface.
+ @param Buffer A pointer to the data buffer to receive both the media header and
+ the data.
+ @param SourceAddr The source HW MAC address. If this parameter is NULL, the
+ HW MAC source address will not be extracted from the media
+ header.
+ @param DestinationAddr The destination HW MAC address. If this parameter is NULL,
+ the HW MAC destination address will not be extracted from the
+ media header.
+ @param Protocol The media header type. If this parameter is NULL, then the
+ protocol will not be extracted from the media header. See
+ RFC 1700 section "Ether Types" for examples.
+
+ @retval EFI_SUCCESS The received data was stored in Buffer, and BufferSize has
+ been updated to the number of bytes received.
+ @retval EFI_NOT_READY The network interface is too busy to accept this transmit
+ request.
+ @retval EFI_BUFFER_TOO_SMALL The BufferSize parameter is too small.
+ @retval EFI_DEVICE_ERROR The command could not be sent to the network interface.
+ @retval EFI_ACCESS_DENIED Error acquire global lock for operation.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpReceive(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ OUT UINTN* HeaderSize OPTIONAL,
+ IN OUT UINTN* BuffSize,
+ OUT VOID* Buffer,
+ OUT EFI_MAC_ADDRESS* SourceAddr OPTIONAL,
+ OUT EFI_MAC_ADDRESS* DestinationAddr OPTIONAL,
+ OUT UINT16* Protocol OPTIONAL
+ );
+
+VOID
+EFIAPI
+UnixSnpWaitForPacketNotify(
+ IN EFI_EVENT Event,
+ IN VOID* Private
+ );
+
+//
+// Strange, but there doesn't appear to be any structure for the Ethernet header in edk2...
+//
+
+typedef struct
+{
+ UINT8 DstAddr[ NET_ETHER_ADDR_LEN ];
+ UINT8 SrcAddr[ NET_ETHER_ADDR_LEN ];
+ UINT16 Type;
+} EthernetHeader;
+
+UNIX_SNP_PRIVATE_DATA gUnixSnpPrivateTemplate =
+{
+ UNIX_SNP_PRIVATE_DATA_SIGNATURE, // Signature
+ NULL, // UnixThunk
+ NULL, // DeviceHandle
+ NULL, // DevicePath
+ { 0 }, // MacAddress
+ NULL, // InterfaceName
+ 0, // ReadBufferSize
+ NULL, // ReadBuffer
+ NULL, // CurrentReadPointer
+ NULL, // EndReadPointer
+ 0, // BpfFd
+ { // Snp
+ EFI_SIMPLE_NETWORK_PROTOCOL_REVISION, // Revision
+ UnixSnpStart, // Start
+ UnixSnpStop, // Stop
+ UnixSnpInitialize, // Initialize
+ UnixSnpReset, // Reset
+ UnixSnpShutdown, // Shutdown
+ UnixSnpReceiveFilters, // ReceiveFilters
+ UnixSnpStationAddress, // StationAddress
+ UnixSnpStatistics, // Statistics
+ UnixSnpMcastIptoMac, // MCastIpToMac
+ UnixSnpNvdata, // NvData
+ UnixSnpGetStatus, // GetStatus
+ UnixSnpTransmit, // Transmit
+ UnixSnpReceive, // Receive
+ NULL, // WaitForPacket
+ NULL // Mode
+ },
+ { // Mode
+ EfiSimpleNetworkStopped, // State
+ NET_ETHER_ADDR_LEN, // HwAddressSize
+ NET_ETHER_HEADER_SIZE, // MediaHeaderSize
+ 1500, // MaxPacketSize
+ 0, // NvRamSize
+ 0, // NvRamAccessSize
+ 0, // ReceiveFilterMask
+ 0, // ReceiveFilterSetting
+ MAX_MCAST_FILTER_CNT, // MaxMCastFilterCount
+ 0, // MCastFilterCount
+ {
+ 0
+ }, // MCastFilter
+ {
+ 0
+ }, // CurrentAddress
+ {
+ 0
+ }, // BroadcastAddress
+ {
+ 0
+ }, // PermanentAddress
+ NET_IFTYPE_ETHERNET, // IfType
+ FALSE, // MacAddressChangeable
+ FALSE, // MultipleTxSupported
+ FALSE, // MediaPresentSupported
+ TRUE // MediaPresent
+ }
+};
+
+STATIC EFI_STATUS
+GetInterfaceMacAddr(
+ IN UNIX_SNP_PRIVATE_DATA* Private,
+ IN EFI_UNIX_IO_PROTOCOL* UnixIo
+ )
+{
+ struct ifaddrs* IfAddrs;
+ struct ifaddrs* If;
+ struct sockaddr_dl* IfSdl;
+ EFI_STATUS Status;
+ INTN Result;
+
+ Result = UnixIo->UnixThunk->GetIfAddrs( &IfAddrs );
+ if ( Result != 0 )
+ {
+ return( EFI_UNSUPPORTED );
+ }
+
+ //
+ // Convert the interface name to ASCII so we can find it.
+ //
+ Private->InterfaceName = AllocateZeroPool( StrLen( UnixIo->EnvString ) );
+
+ if ( !Private->InterfaceName )
+ {
+ Status = EFI_OUT_OF_RESOURCES;
+ goto Exit;
+ }
+
+ UnicodeStrToAsciiStr( UnixIo->EnvString, Private->InterfaceName );
+
+ If = IfAddrs;
+
+ while ( If != NULL )
+ {
+ IfSdl = ( struct sockaddr_dl * ) If->ifa_addr;
+
+ if ( IfSdl->sdl_family == AF_LINK )
+ {
+ if ( !AsciiStrCmp( Private->InterfaceName, If->ifa_name ) )
+ {
+ CopyMem( &Private->MacAddress, LLADDR( IfSdl ), NET_ETHER_ADDR_LEN );
+
+ Status = EFI_SUCCESS;
+ break;
+ }
+ }
+
+ If = If->ifa_next;
+ }
+
+Exit:
+ ( VOID ) UnixIo->UnixThunk->FreeIfAddrs( IfAddrs );
+
+ return( Status );
+}
+
+
+STATIC EFI_STATUS
+OpenBpfFileDescriptor(
+ IN UNIX_SNP_PRIVATE_DATA* Private,
+ OUT INTN* Fd
+ )
+{
+ CHAR8 BfpDeviceName[ 256 ];
+ INTN Index;
+ EFI_STATUS Status = EFI_OUT_OF_RESOURCES;
+ INTN Result;
+
+ //
+ // Open a Berkeley Packet Filter device. This must be done as root, so this is probably
+ // the place which is most likely to fail...
+ //
+ for ( Index = 0; TRUE; Index++ )
+ {
+ AsciiSPrint( BfpDeviceName, sizeof( BfpDeviceName ), "/dev/bpf%d", Index );
+
+ *Fd = Private->UnixThunk->Open( BfpDeviceName, O_RDWR, 0 );
+
+ if ( *Fd >= 0 )
+ {
+ Status = EFI_SUCCESS;
+ break;
+ }
+
+ Result = Private->UnixThunk->GetErrno();
+ if ( Result == EACCES )
+ {
+ DEBUG( ( EFI_D_ERROR, "Permissions on '%a' are incorrect. Fix with 'sudo chmod 666 %a'.\n",
+ BfpDeviceName, BfpDeviceName ) );
+ }
+ if ( Result != EBUSY )
+ {
+ break;
+ }
+ }
+
+ return( Status );
+}
+
+
+/**
+ Test to see if this driver supports ControllerHandle. This service
+ is called by the EFI boot service ConnectController(). In
+ order to make drivers as small as possible, there are a few calling
+ restrictions for this service. ConnectController() must
+ follow these calling restrictions. If any other agent wishes to call
+ Supported() it must also follow these calling restrictions.
+
+ @param This Protocol instance pointer.
+ @param ControllerHandle Handle of device to test
+ @param RemainingDevicePath Optional parameter use to pick a specific child
+ device to start.
+
+ @retval EFI_SUCCESS This driver supports this device
+ @retval EFI_UNSUPPORTED This driver does not support this device
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpDriverBindingSupported(
+ IN EFI_DRIVER_BINDING_PROTOCOL* This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_DEVICE_PATH_PROTOCOL* RemainingDevicePath OPTIONAL
+ )
+{
+ EFI_STATUS Status;
+ EFI_UNIX_IO_PROTOCOL* UnixIo;
+
+ //
+ // Open the I/O abstraction needed to perform the supported test.
+ //
+ Status = gBS->OpenProtocol(
+ ControllerHandle,
+ &gEfiUnixIoProtocolGuid,
+ ( VOID ** ) &UnixIo,
+ This->DriverBindingHandle,
+ ControllerHandle,
+ EFI_OPEN_PROTOCOL_BY_DRIVER
+ );
+
+ if ( EFI_ERROR( Status ) )
+ {
+ return( Status );
+ }
+
+ //
+ // Validate GUID
+ //
+ Status = EFI_UNSUPPORTED;
+ if ( CompareGuid( UnixIo->TypeGuid, &gEfiUnixNetworkGuid ) )
+ {
+ Status = EFI_SUCCESS;
+ }
+
+ //
+ // Close the I/O abstraction used to perform the supported test.
+ //
+ gBS->CloseProtocol(
+ ControllerHandle,
+ &gEfiUnixIoProtocolGuid,
+ This->DriverBindingHandle,
+ ControllerHandle
+ );
+
+ return( Status );
+}
+
+
+/**
+ Start this driver on ControllerHandle. This service is called by the
+ EFI boot service ConnectController(). In order to make
+ drivers as small as possible, there are a few calling restrictions for
+ this service. ConnectController() must follow these
+ calling restrictions. If any other agent wishes to call Start() it
+ must also follow these calling restrictions.
+
+ @param This Protocol instance pointer.
+ @param ControllerHandle Handle of device to bind driver to
+ @param RemainingDevicePath Optional parameter use to pick a specific child
+ device to start.
+
+ @retval EFI_SUCCESS Always succeeds.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpDriverBindingStart(
+ IN EFI_DRIVER_BINDING_PROTOCOL* This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_DEVICE_PATH_PROTOCOL* RemainingDevicePath OPTIONAL
+ )
+{
+ MAC_ADDR_DEVICE_PATH Node;
+ EFI_DEVICE_PATH_PROTOCOL* ParentDevicePath = NULL;
+ EFI_UNIX_IO_PROTOCOL* UnixIo;
+ UNIX_SNP_PRIVATE_DATA* Private = NULL;
+ EFI_STATUS Status;
+ BOOLEAN CreateDevice;
+
+ //
+ // Grab the protocols we need.
+ //
+ Status = gBS->OpenProtocol(
+ ControllerHandle,
+ &gEfiDevicePathProtocolGuid,
+ ( VOID ** ) &ParentDevicePath,
+ This->DriverBindingHandle,
+ ControllerHandle,
+ EFI_OPEN_PROTOCOL_BY_DRIVER
+ );
+ if ( EFI_ERROR( Status ) )
+ {
+ goto ErrorExit;
+ }
+
+ //
+ // Open the I/O abstraction needed to perform the supported test.
+ //
+ Status = gBS->OpenProtocol(
+ ControllerHandle,
+ &gEfiUnixIoProtocolGuid,
+ ( VOID ** ) &UnixIo,
+ This->DriverBindingHandle,
+ ControllerHandle,
+ EFI_OPEN_PROTOCOL_BY_DRIVER
+ );
+ if ( EFI_ERROR( Status ) )
+ {
+ goto ErrorExit;
+ }
+
+ //
+ // Validate GUID
+ //
+ if ( !CompareGuid( UnixIo->TypeGuid, &gEfiUnixNetworkGuid ) )
+ {
+ Status = EFI_UNSUPPORTED;
+ goto ErrorExit;
+ }
+
+ CreateDevice = TRUE;
+ if ( ( RemainingDevicePath != NULL ) && IsDevicePathEnd( RemainingDevicePath ) )
+ {
+ CreateDevice = FALSE;
+ }
+
+ if ( CreateDevice )
+ {
+ //
+ // Allocate the private data.
+ //
+ Private = AllocateCopyPool( sizeof( UNIX_SNP_PRIVATE_DATA ), &gUnixSnpPrivateTemplate );
+ if ( Private == NULL )
+ {
+ Status = EFI_OUT_OF_RESOURCES;
+ goto ErrorExit;
+ }
+
+ Status = GetInterfaceMacAddr( Private, UnixIo );
+ if ( EFI_ERROR( Status ) )
+ {
+ goto ErrorExit;
+ }
+
+ Private->UnixThunk = UnixIo->UnixThunk;
+
+ Private->Snp.Mode = &Private->Mode;
+
+ //
+ // Set the broadcast address.
+ //
+ SetMem( &Private->Mode.BroadcastAddress, sizeof( EFI_MAC_ADDRESS ), 0xFF );
+
+ CopyMem( &Private->Mode.CurrentAddress, &Private->MacAddress, sizeof( EFI_MAC_ADDRESS ) );
+ CopyMem( &Private->Mode.PermanentAddress, &Private->MacAddress, sizeof( EFI_MAC_ADDRESS ) );
+
+ //
+ // Since the fake SNP is based on a real NIC, to avoid conflict with the host NIC
+ // network stack, we use a different MAC address.
+ // So just change the last byte of the MAC address for the real NIC.
+ //
+ Private->Mode.CurrentAddress.Addr[ NET_ETHER_ADDR_LEN - 1 ]++;
+
+ //
+ // Build the device path by appending the MAC node to the ParentDevicePath
+ // from the UnixIo handle.
+ //
+ ZeroMem( &Node, sizeof( MAC_ADDR_DEVICE_PATH ) );
+
+ Node.Header.Type = MESSAGING_DEVICE_PATH;
+ Node.Header.SubType = MSG_MAC_ADDR_DP;
+ Node.IfType = Private->Mode.IfType;
+
+ SetDevicePathNodeLength( ( EFI_DEVICE_PATH_PROTOCOL * ) &Node, sizeof( MAC_ADDR_DEVICE_PATH ) );
+
+ CopyMem( &Node.MacAddress, &Private->Mode.CurrentAddress, sizeof( EFI_MAC_ADDRESS ) );
+
+ //
+ // Build the device path by appending the MAC node to the ParentDevicePath from the UnixIo handle.
+ //
+ Private->DevicePath = AppendDevicePathNode( ParentDevicePath, ( EFI_DEVICE_PATH_PROTOCOL * ) &Node );
+ if ( Private->DevicePath == NULL )
+ {
+ Status = EFI_OUT_OF_RESOURCES;
+ goto ErrorExit;
+ }
+
+ Status = gBS->InstallMultipleProtocolInterfaces(
+ &Private->DeviceHandle,
+ &gEfiSimpleNetworkProtocolGuid,
+ &Private->Snp,
+ &gEfiDevicePathProtocolGuid,
+ Private->DevicePath,
+ NULL
+ );
+ if ( EFI_ERROR( Status ) )
+ {
+ goto ErrorExit;
+ }
+
+ Status = gBS->OpenProtocol(
+ ControllerHandle,
+ &gEfiUnixIoProtocolGuid,
+ ( VOID ** ) &UnixIo,
+ This->DriverBindingHandle,
+ Private->DeviceHandle,
+ EFI_OPEN_PROTOCOL_BY_CHILD_CONTROLLER
+ );
+ if ( EFI_ERROR( Status ) )
+ {
+ goto ErrorExit;
+ }
+ }
+ return( Status );
+
+ErrorExit:
+ if ( Private->InterfaceName != NULL )
+ {
+ FreePool( Private->InterfaceName );
+ Private->InterfaceName = NULL;
+ }
+ if ( Private != NULL )
+ {
+ FreePool( Private );
+ }
+ if ( ParentDevicePath != NULL )
+ {
+ gBS->CloseProtocol(
+ ControllerHandle,
+ &gEfiDevicePathProtocolGuid,
+ This->DriverBindingHandle,
+ ControllerHandle
+ );
+ }
+
+ return( Status );
+}
+
+/**
+ Stop this driver on ControllerHandle. This service is called by the
+ EFI boot service DisconnectController(). In order to
+ make drivers as small as possible, there are a few calling
+ restrictions for this service. DisconnectController()
+ must follow these calling restrictions. If any other agent wishes
+ to call Stop() it must also follow these calling restrictions.
+
+ @param This Protocol instance pointer.
+ @param ControllerHandle Handle of device to stop driver on
+ @param NumberOfChildren Number of Handles in ChildHandleBuffer. If number of
+ children is zero stop the entire bus driver.
+ @param ChildHandleBuffer List of Child Handles to Stop.
+
+ @retval EFI_SUCCESS Always succeeds.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpDriverBindingStop(
+ IN EFI_DRIVER_BINDING_PROTOCOL* This,
+ IN EFI_HANDLE ControllerHandle,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE* ChildHandleBuffer
+ )
+{
+ UNIX_SNP_PRIVATE_DATA* Private = NULL;
+ EFI_SIMPLE_NETWORK_PROTOCOL* Snp;
+ EFI_STATUS Status;
+
+ //
+ // Get our context back.
+ //
+ Status = gBS->OpenProtocol(
+ ControllerHandle,
+ &gEfiSimpleNetworkProtocolGuid,
+ ( VOID ** ) &Snp,
+ This->DriverBindingHandle,
+ ControllerHandle,
+ EFI_OPEN_PROTOCOL_GET_PROTOCOL
+ );
+ if ( EFI_ERROR( Status ) )
+ {
+ return( EFI_UNSUPPORTED );
+ }
+
+ Private = UNIX_SNP_PRIVATE_DATA_FROM_SNP_THIS( Snp );
+
+ Status = gBS->CloseProtocol(
+ ControllerHandle,
+ &gEfiUnixIoProtocolGuid,
+ This->DriverBindingHandle,
+ Private->DeviceHandle
+ );
+
+ Status = gBS->UninstallMultipleProtocolInterfaces(
+ Private->DeviceHandle,
+ &gEfiSimpleNetworkProtocolGuid,
+ &Private->Snp,
+ &gEfiDevicePathProtocolGuid,
+ Private->DevicePath,
+ NULL
+ );
+
+ FreePool( Private->InterfaceName );
+ FreePool( Private->DevicePath );
+ FreePool( Private );
+
+ return( EFI_SUCCESS );
+}
+
+
+/**
+ Changes the state of a network interface from "stopped" to "started".
+
+ @param This Protocol instance pointer.
+
+ @retval EFI_SUCCESS Always succeeds.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpStart(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This
+ )
+{
+ STATIC struct bpf_insn FilterInstructionTemplate[] =
+ {
+ // Load 4 bytes from the destination MAC address.
+ BPF_STMT( BPF_LD + BPF_W + BPF_ABS, OFFSET_OF( EthernetHeader, DstAddr[ 0 ] ) ),
+
+ // Compare to first 4 bytes of fake MAC address.
+ BPF_JUMP( BPF_JMP + BPF_JEQ + BPF_K, 0x12345678, 0, 3 ),
+
+ // Load remaining 2 bytes from the destination MAC address.
+ BPF_STMT( BPF_LD + BPF_H + BPF_ABS, OFFSET_OF( EthernetHeader, DstAddr[ 4 ] ) ),
+
+ // Compare to remaining 2 bytes of fake MAC address.
+ BPF_JUMP( BPF_JMP + BPF_JEQ + BPF_K, 0x9ABC, 5, 0 ),
+
+ // Load 4 bytes from the destination MAC address.
+ BPF_STMT( BPF_LD + BPF_W + BPF_ABS, OFFSET_OF( EthernetHeader, DstAddr[ 0 ] ) ),
+
+ // Compare to first 4 bytes of broadcast MAC address.
+ BPF_JUMP( BPF_JMP + BPF_JEQ + BPF_K, 0xFFFFFFFF, 0, 2 ),
+
+ // Load remaining 2 bytes from the destination MAC address.
+ BPF_STMT( BPF_LD + BPF_H + BPF_ABS, OFFSET_OF( EthernetHeader, DstAddr[ 4 ] ) ),
+
+ // Compare to remaining 2 bytes of broadcast MAC address.
+ BPF_JUMP( BPF_JMP + BPF_JEQ + BPF_K, 0xFFFF, 1, 0 ),
+
+ // Reject packet.
+ BPF_STMT( BPF_RET + BPF_K, 0 ),
+
+ // Receive entire packet.
+ BPF_STMT( BPF_RET + BPF_K, -1 )
+ };
+ struct ifreq BoundIf;
+ struct bpf_program BpfProgram;
+ struct bpf_insn* FilterProgram;
+ UNIX_SNP_PRIVATE_DATA* Private;
+ EFI_STATUS Status;
+ UINT32 Temp32;
+ INTN Fd;
+ INTN Result;
+ INTN Value;
+ UINT16 Temp16;
+
+ Private = UNIX_SNP_PRIVATE_DATA_FROM_SNP_THIS( This );
+
+ switch ( Private->Snp.Mode->State )
+ {
+ case EfiSimpleNetworkStopped:
+ break;
+
+ case EfiSimpleNetworkStarted:
+ case EfiSimpleNetworkInitialized:
+ return( EFI_ALREADY_STARTED );
+ break;
+
+ default:
+ return( EFI_DEVICE_ERROR );
+ break;
+ }
+
+ if ( Private->BpfFd == 0 )
+ {
+ Status = OpenBpfFileDescriptor( Private, &Fd );
+
+ if ( EFI_ERROR( Status ) )
+ {
+ goto ErrorExit;
+ }
+
+ Private->BpfFd = Fd;
+
+ //
+ // Associate our interface with this BPF file descriptor.
+ //
+ AsciiStrCpy( BoundIf.ifr_name, Private->InterfaceName );
+ Result = Private->UnixThunk->IoCtl( Private->BpfFd, BIOCSETIF, &BoundIf );
+
+ if ( Result < 0 )
+ {
+ goto DeviceErrorExit;
+ }
+
+ //
+ // Enable immediate mode and find out the buffer size.
+ //
+ Value = 1;
+ Result = Private->UnixThunk->IoCtl( Private->BpfFd, BIOCIMMEDIATE, &Value );
+
+ if ( Result < 0 )
+ {
+ goto DeviceErrorExit;
+ }
+
+ //
+ // Enable non-blocking I/O.
+ //
+
+ Value = Private->UnixThunk->Fcntl( Private->BpfFd, F_GETFL, 0 );
+
+ if ( Value == -1 )
+ {
+ goto DeviceErrorExit;
+ }
+
+ Value |= O_NONBLOCK;
+
+ Result = Private->UnixThunk->Fcntl( Private->BpfFd, F_SETFL, (void *) Value );
+
+ if ( Result == -1 )
+ {
+ goto DeviceErrorExit;
+ }
+
+ //
+ // Disable "header complete" flag. This means the supplied source MAC address is
+ // what goes on the wire.
+ //
+ Value = 1;
+ Result = Private->UnixThunk->IoCtl( Private->BpfFd, BIOCSHDRCMPLT, &Value );
+
+ if ( Result < 0 )
+ {
+ goto DeviceErrorExit;
+ }
+
+ Result = Private->UnixThunk->IoCtl( Private->BpfFd, BIOCGBLEN, &Value );
+
+ if ( Result < 0 )
+ {
+ goto DeviceErrorExit;
+ }
+
+ //
+ // Allocate read buffer.
+ //
+ Private->ReadBufferSize = Value;
+ Private->ReadBuffer = AllocateZeroPool( Private->ReadBufferSize );
+ if ( Private->ReadBuffer == NULL )
+ {
+ Status = EFI_OUT_OF_RESOURCES;
+ goto ErrorExit;
+ }
+
+ Private->CurrentReadPointer = Private->EndReadPointer = Private->ReadBuffer;
+
+ //
+ // Install our packet filter: successful reads should only produce broadcast or unitcast
+ // packets directed to our fake MAC address.
+ //
+ FilterProgram = AllocateCopyPool( sizeof( FilterInstructionTemplate ), &FilterInstructionTemplate );
+ if ( FilterProgram == NULL )
+ {
+ goto ErrorExit;
+ }
+
+ //
+ // Insert out fake MAC address into the filter. The data has to be host endian.
+ //
+ CopyMem( &Temp32, &Private->Mode.CurrentAddress.Addr[ 0 ], sizeof( UINT32 ) );
+ FilterProgram[ 1 ].k = NTOHL( Temp32 );
+ CopyMem( &Temp16, &Private->Mode.CurrentAddress.Addr[ 4 ], sizeof( UINT16 ) );
+ FilterProgram[ 3 ].k = NTOHS( Temp16 );
+
+ BpfProgram.bf_len = sizeof( FilterInstructionTemplate ) / sizeof( struct bpf_insn );
+ BpfProgram.bf_insns = FilterProgram;
+
+ Result = Private->UnixThunk->IoCtl( Private->BpfFd, BIOCSETF, &BpfProgram );
+
+ if ( Result < 0 )
+ {
+ goto DeviceErrorExit;
+ }
+
+ FreePool( FilterProgram );
+
+ //
+ // Enable promiscuous mode.
+ //
+
+ Result = Private->UnixThunk->IoCtl( Private->BpfFd, BIOCPROMISC, 0 );
+
+ if ( Result < 0 )
+ {
+ goto DeviceErrorExit;
+ }
+
+
+ Private->Snp.Mode->State = EfiSimpleNetworkStarted;
+ }
+
+ return( Status );
+
+DeviceErrorExit:
+ Status = EFI_DEVICE_ERROR;
+ErrorExit:
+ if ( Private->ReadBuffer != NULL )
+ {
+ FreePool( Private->ReadBuffer );
+ Private->ReadBuffer = NULL;
+ }
+ return( Status );
+}
+
+
+/**
+ Changes the state of a network interface from "started" to "stopped".
+
+ @param This Protocol instance pointer.
+
+ @retval EFI_SUCCESS Always succeeds.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpStop(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This
+ )
+{
+ UNIX_SNP_PRIVATE_DATA* Private = EFI_SUCCESS;
+ EFI_STATUS Status;
+
+ Private = UNIX_SNP_PRIVATE_DATA_FROM_SNP_THIS( This );
+
+ switch ( Private->Snp.Mode->State )
+ {
+ case EfiSimpleNetworkStarted:
+ break;
+
+ case EfiSimpleNetworkStopped:
+ return( EFI_NOT_STARTED );
+ break;
+
+ default:
+ return( EFI_DEVICE_ERROR );
+ break;
+ }
+
+ if ( Private->BpfFd != 0 )
+ {
+ Private->UnixThunk->Close( Private->BpfFd );
+ Private->BpfFd = 0;
+ }
+
+ if ( Private->ReadBuffer != NULL )
+ {
+ FreePool( Private->ReadBuffer );
+ Private->CurrentReadPointer = Private->EndReadPointer = Private->ReadBuffer = NULL;
+ }
+
+ Private->Snp.Mode->State = EfiSimpleNetworkStopped;
+
+ return( Status );
+}
+
+
+/**
+ Resets a network adapter and allocates the transmit and receive buffers
+ required by the network interface; optionally, also requests allocation
+ of additional transmit and receive buffers.
+
+ @param This Protocol instance pointer.
+ @param ExtraRxBufferSize The size, in bytes, of the extra receive buffer space
+ that the driver should allocate for the network interface.
+ Some network interfaces will not be able to use the extra
+ buffer, and the caller will not know if it is actually
+ being used.
+ @param ExtraTxBufferSize The size, in bytes, of the extra transmit buffer space
+ that the driver should allocate for the network interface.
+ Some network interfaces will not be able to use the extra
+ buffer, and the caller will not know if it is actually
+ being used.
+
+ @retval EFI_SUCCESS Always succeeds.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpInitialize(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ IN UINTN ExtraRxBufferSize OPTIONAL,
+ IN UINTN ExtraTxBufferSize OPTIONAL
+ )
+{
+ UNIX_SNP_PRIVATE_DATA* Private = EFI_SUCCESS;
+ EFI_STATUS Status;
+
+ Private = UNIX_SNP_PRIVATE_DATA_FROM_SNP_THIS( This );
+
+ switch ( Private->Snp.Mode->State )
+ {
+ case EfiSimpleNetworkStarted:
+ break;
+
+ case EfiSimpleNetworkStopped:
+ return( EFI_NOT_STARTED );
+ break;
+
+ default:
+ return( EFI_DEVICE_ERROR );
+ break;
+ }
+
+#if 0
+ Status = gBS->CreateEvent(
+ EVT_NOTIFY_WAIT,
+ TPL_NOTIFY,
+ UnixSnpWaitForPacketNotify,
+ Private,
+ &Private->Snp.WaitForPacket
+ );
+#endif
+
+ if ( !EFI_ERROR( Status ) )
+ {
+ Private->Mode.MCastFilterCount = 0;
+ Private->Mode.ReceiveFilterSetting = 0;
+ ZeroMem( Private->Mode.MCastFilter, sizeof( Private->Mode.MCastFilter ) );
+
+ Private->Snp.Mode->State = EfiSimpleNetworkInitialized;
+ }
+
+ return( Status );
+}
+
+/**
+ Resets a network adapter and re-initializes it with the parameters that were
+ provided in the previous call to Initialize().
+
+ @param This Protocol instance pointer.
+ @param ExtendedVerification Indicates that the driver may perform a more
+ exhaustive verification operation of the device
+ during reset.
+
+ @retval EFI_SUCCESS Always succeeds.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpReset(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ IN BOOLEAN ExtendedVerification
+ )
+{
+ UNIX_SNP_PRIVATE_DATA* Private;
+ EFI_STATUS Success = EFI_SUCCESS;
+
+ Private = UNIX_SNP_PRIVATE_DATA_FROM_SNP_THIS( This );
+
+ switch ( Private->Snp.Mode->State )
+ {
+ case EfiSimpleNetworkInitialized:
+ break;
+
+ case EfiSimpleNetworkStopped:
+ return( EFI_NOT_STARTED );
+ break;
+
+ default:
+ return( EFI_DEVICE_ERROR );
+ break;
+ }
+
+ return( Success );
+}
+
+/**
+ Resets a network adapter and leaves it in a state that is safe for
+ another driver to initialize.
+
+ @param This Protocol instance pointer.
+
+ @retval EFI_SUCCESS Always succeeds.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpShutdown(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This
+ )
+{
+ UNIX_SNP_PRIVATE_DATA* Private;
+ EFI_STATUS Success = EFI_SUCCESS;
+
+ Private = UNIX_SNP_PRIVATE_DATA_FROM_SNP_THIS( This );
+
+ switch ( Private->Snp.Mode->State )
+ {
+ case EfiSimpleNetworkInitialized:
+ break;
+
+ case EfiSimpleNetworkStopped:
+ return( EFI_NOT_STARTED );
+ break;
+
+ default:
+ return( EFI_DEVICE_ERROR );
+ break;
+ }
+
+ Private->Snp.Mode->State = EfiSimpleNetworkStarted;
+
+ Private->Mode.ReceiveFilterSetting = 0;
+ Private->Mode.MCastFilterCount = 0;
+ ZeroMem( Private->Mode.MCastFilter, sizeof( Private->Mode.MCastFilter ) );
+
+ if ( Private->Snp.WaitForPacket != NULL )
+ {
+ gBS->CloseEvent( Private->Snp.WaitForPacket );
+ Private->Snp.WaitForPacket = NULL;
+ }
+
+ if ( Private->BpfFd != 0 )
+ {
+ Private->UnixThunk->Close( Private->BpfFd );
+ Private->BpfFd = 0;
+ }
+
+ if ( Private->ReadBuffer != NULL )
+ {
+ FreePool( Private->ReadBuffer );
+ Private->CurrentReadPointer = Private->EndReadPointer = Private->ReadBuffer = NULL;
+ }
+
+ return( Success );
+}
+
+/**
+ Manages the multicast receive filters of a network interface.
+
+ @param This Protocol instance pointer.
+ @param EnableBits A bit mask of receive filters to enable on the network interface.
+ @param DisableBits A bit mask of receive filters to disable on the network interface.
+ @param ResetMcastFilter Set to TRUE to reset the contents of the multicast receive
+ filters on the network interface to their default values.
+ @param McastFilterCount Number of multicast HW MAC addresses in the new
+ MCastFilter list. This value must be less than or equal to
+ the MCastFilterCnt field of EFI_SIMPLE_NETWORK_MODE. This
+ field is optional if ResetMCastFilter is TRUE.
+ @param McastFilter A pointer to a list of new multicast receive filter HW MAC
+ addresses. This list will replace any existing multicast
+ HW MAC address list. This field is optional if
+ ResetMCastFilter is TRUE.
+
+ @retval EFI_SUCCESS The multicast receive filter list was updated.
+ @retval EFI_DEVICE_ERROR The command could not be sent to the network interface.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpReceiveFilters(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ IN UINT32 EnableBits,
+ IN UINT32 DisableBits,
+ IN BOOLEAN ResetMcastFilter,
+ IN UINTN McastFilterCount OPTIONAL,
+ IN EFI_MAC_ADDRESS* McastFilter OPTIONAL
+ )
+{
+ UNIX_SNP_PRIVATE_DATA* Private;
+
+ Private = UNIX_SNP_PRIVATE_DATA_FROM_SNP_THIS( This );
+
+// ReturnValue = GlobalData->NtNetUtilityTable.SetReceiveFilter (
+// Instance->InterfaceInfo.InterfaceIndex,
+// EnableBits,
+// McastFilterCount,
+// McastFilter
+// );
+
+ // For now, just succeed...
+ return( EFI_SUCCESS );
+}
+
+/**
+ Modifies or resets the current station address, if supported.
+
+ @param This Protocol instance pointer.
+ @param Reset Flag used to reset the station address to the network interfaces
+ permanent address.
+ @param NewMacAddr New station address to be used for the network interface.
+
+ @retval EFI_UNSUPPORTED Not supported yet.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpStationAddress(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ IN BOOLEAN Reset,
+ IN EFI_MAC_ADDRESS* NewMacAddr OPTIONAL
+ )
+{
+ return( EFI_UNSUPPORTED );
+}
+
+/**
+ Resets or collects the statistics on a network interface.
+
+ @param This Protocol instance pointer.
+ @param Reset Set to TRUE to reset the statistics for the network interface.
+ @param StatisticsSize On input the size, in bytes, of StatisticsTable. On
+ output the size, in bytes, of the resulting table of
+ statistics.
+ @param StatisticsTable A pointer to the EFI_NETWORK_STATISTICS structure that
+ contains the statistics.
+
+ @retval EFI_SUCCESS The statistics were collected from the network interface.
+ @retval EFI_NOT_STARTED The network interface has not been started.
+ @retval EFI_BUFFER_TOO_SMALL The Statistics buffer was too small. The current buffer
+ size needed to hold the statistics is returned in
+ StatisticsSize.
+ @retval EFI_UNSUPPORTED Not supported yet.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpStatistics(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ IN BOOLEAN Reset,
+ IN OUT UINTN* StatisticsSize OPTIONAL,
+ OUT EFI_NETWORK_STATISTICS* StatisticsTable OPTIONAL
+ )
+{
+ return( EFI_UNSUPPORTED );
+}
+
+/**
+ Converts a multicast IP address to a multicast HW MAC address.
+
+ @param This Protocol instance pointer.
+ @param Ipv6 Set to TRUE if the multicast IP address is IPv6 [RFC 2460]. Set
+ to FALSE if the multicast IP address is IPv4 [RFC 791].
+ @param Ip The multicast IP address that is to be converted to a multicast
+ HW MAC address.
+ @param Mac The multicast HW MAC address that is to be generated from IP.
+
+ @retval EFI_SUCCESS The multicast IP address was mapped to the multicast
+ HW MAC address.
+ @retval EFI_NOT_STARTED The network interface has not been started.
+ @retval EFI_BUFFER_TOO_SMALL The Statistics buffer was too small. The current buffer
+ size needed to hold the statistics is returned in
+ StatisticsSize.
+ @retval EFI_UNSUPPORTED Not supported yet.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpMcastIptoMac(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ IN BOOLEAN Ipv6,
+ IN EFI_IP_ADDRESS* Ip,
+ OUT EFI_MAC_ADDRESS* Mac
+ )
+{
+ return( EFI_UNSUPPORTED );
+}
+
+
+/**
+ Performs read and write operations on the NVRAM device attached to a
+ network interface.
+
+ @param This Protocol instance pointer.
+ @param ReadOrWrite TRUE for read operations, FALSE for write operations.
+ @param Offset Byte offset in the NVRAM device at which to start the read or
+ write operation. This must be a multiple of NvRamAccessSize and
+ less than NvRamSize.
+ @param BufferSize The number of bytes to read or write from the NVRAM device.
+ This must also be a multiple of NvramAccessSize.
+ @param Buffer A pointer to the data buffer.
+
+ @retval EFI_UNSUPPORTED Not supported yet.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpNvdata(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ IN BOOLEAN ReadOrWrite,
+ IN UINTN Offset,
+ IN UINTN BufferSize,
+ IN OUT VOID* Buffer
+ )
+{
+ return( EFI_UNSUPPORTED );
+}
+
+
+/**
+ Reads the current interrupt status and recycled transmit buffer status from
+ a network interface.
+
+ @param This Protocol instance pointer.
+ @param InterruptStatus A pointer to the bit mask of the currently active interrupts
+ If this is NULL, the interrupt status will not be read from
+ the device. If this is not NULL, the interrupt status will
+ be read from the device. When the interrupt status is read,
+ it will also be cleared. Clearing the transmit interrupt
+ does not empty the recycled transmit buffer array.
+ @param TxBuffer Recycled transmit buffer address. The network interface will
+ not transmit if its internal recycled transmit buffer array
+ is full. Reading the transmit buffer does not clear the
+ transmit interrupt. If this is NULL, then the transmit buffer
+ status will not be read. If there are no transmit buffers to
+ recycle and TxBuf is not NULL, * TxBuf will be set to NULL.
+
+ @retval EFI_SUCCESS Always succeeds.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpGetStatus(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ OUT UINT32* InterruptStatus,
+ OUT VOID** TxBuffer
+ )
+{
+ if ( TxBuffer != NULL )
+ {
+ *( ( UINT8 ** ) TxBuffer ) = ( UINT8 * ) 1;
+ }
+
+ if ( InterruptStatus != NULL )
+ {
+ *InterruptStatus = EFI_SIMPLE_NETWORK_TRANSMIT_INTERRUPT;
+ }
+
+ return( EFI_SUCCESS );
+}
+
+
+/**
+ Places a packet in the transmit queue of a network interface.
+
+ @param This Protocol instance pointer.
+ @param HeaderSize The size, in bytes, of the media header to be filled in by
+ the Transmit() function. If HeaderSize is non-zero, then it
+ must be equal to This->Mode->MediaHeaderSize and the DestAddr
+ and Protocol parameters must not be NULL.
+ @param BufferSize The size, in bytes, of the entire packet (media header and
+ data) to be transmitted through the network interface.
+ @param Buffer A pointer to the packet (media header followed by data) to be
+ transmitted. This parameter cannot be NULL. If HeaderSize is zero,
+ then the media header in Buffer must already be filled in by the
+ caller. If HeaderSize is non-zero, then the media header will be
+ filled in by the Transmit() function.
+ @param SrcAddr The source HW MAC address. If HeaderSize is zero, then this parameter
+ is ignored. If HeaderSize is non-zero and SrcAddr is NULL, then
+ This->Mode->CurrentAddress is used for the source HW MAC address.
+ @param DestAddr The destination HW MAC address. If HeaderSize is zero, then this
+ parameter is ignored.
+ @param Protocol The type of header to build. If HeaderSize is zero, then this
+ parameter is ignored. See RFC 1700, section "Ether Types", for
+ examples.
+
+ @retval EFI_SUCCESS The packet was placed on the transmit queue.
+ @retval EFI_DEVICE_ERROR The command could not be sent to the network interface.
+ @retval EFI_INVALID_PARAMETER One or more of the parameters has an unsupported value.
+ @retval EFI_NOT_STARTED The network interface has not been started.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpTransmit(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ IN UINTN HeaderSize,
+ IN UINTN BufferSize,
+ IN VOID* Buffer,
+ IN EFI_MAC_ADDRESS* SrcAddr OPTIONAL,
+ IN EFI_MAC_ADDRESS* DestAddr OPTIONAL,
+ IN UINT16* Protocol OPTIONAL
+ )
+{
+ UNIX_SNP_PRIVATE_DATA* Private;
+ EthernetHeader* EnetHeader;
+ INTN Result;
+
+ Private = UNIX_SNP_PRIVATE_DATA_FROM_SNP_THIS( This );
+
+ if ( This->Mode->State < EfiSimpleNetworkStarted )
+ {
+ return( EFI_NOT_STARTED );
+ }
+
+ if ( HeaderSize != 0 )
+ {
+ if ( ( DestAddr == NULL ) || ( Protocol == NULL ) || ( HeaderSize != This->Mode->MediaHeaderSize ) )
+ {
+ return( EFI_INVALID_PARAMETER );
+ }
+
+ if ( SrcAddr == NULL )
+ {
+ SrcAddr = &This->Mode->CurrentAddress;
+ }
+
+ EnetHeader = ( EthernetHeader * ) Buffer;
+
+ CopyMem( EnetHeader->DstAddr, DestAddr, NET_ETHER_ADDR_LEN );
+ CopyMem( EnetHeader->SrcAddr, SrcAddr, NET_ETHER_ADDR_LEN );
+
+ EnetHeader->Type = HTONS( *Protocol );
+ }
+
+ Result = Private->UnixThunk->Write( Private->BpfFd, Buffer, BufferSize );
+
+ if ( Result < 0 )
+ {
+ return( EFI_DEVICE_ERROR );
+ }
+ else
+ {
+ return( EFI_SUCCESS );
+ }
+}
+
+/**
+ Receives a packet from a network interface.
+
+ @param This Protocol instance pointer.
+ @param HeaderSize The size, in bytes, of the media header received on the network
+ interface. If this parameter is NULL, then the media header size
+ will not be returned.
+ @param BuffSize On entry, the size, in bytes, of Buffer. On exit, the size, in
+ bytes, of the packet that was received on the network interface.
+ @param Buffer A pointer to the data buffer to receive both the media header and
+ the data.
+ @param SourceAddr The source HW MAC address. If this parameter is NULL, the
+ HW MAC source address will not be extracted from the media
+ header.
+ @param DestinationAddr The destination HW MAC address. If this parameter is NULL,
+ the HW MAC destination address will not be extracted from the
+ media header.
+ @param Protocol The media header type. If this parameter is NULL, then the
+ protocol will not be extracted from the media header. See
+ RFC 1700 section "Ether Types" for examples.
+
+ @retval EFI_SUCCESS The received data was stored in Buffer, and BufferSize has
+ been updated to the number of bytes received.
+ @retval EFI_NOT_READY The network interface is too busy to accept this transmit
+ request.
+ @retval EFI_NOT_STARTED The network interface has not been started.
+ @retval EFI_BUFFER_TOO_SMALL The BufferSize parameter is too small.
+ @retval EFI_DEVICE_ERROR The command could not be sent to the network interface.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpReceive(
+ IN EFI_SIMPLE_NETWORK_PROTOCOL* This,
+ OUT UINTN* HeaderSize OPTIONAL,
+ IN OUT UINTN* BuffSize,
+ OUT VOID* Buffer,
+ OUT EFI_MAC_ADDRESS* SourceAddr OPTIONAL,
+ OUT EFI_MAC_ADDRESS* DestinationAddr OPTIONAL,
+ OUT UINT16* Protocol OPTIONAL
+ )
+{
+ UNIX_SNP_PRIVATE_DATA* Private;
+ struct bpf_hdr* BpfHeader;
+ EthernetHeader* EnetHeader;
+ EFI_STATUS Status = EFI_SUCCESS;
+ INTN Result;
+
+ if ( This->Mode->State < EfiSimpleNetworkStarted )
+ {
+ return( EFI_NOT_STARTED );
+ }
+
+ Private = UNIX_SNP_PRIVATE_DATA_FROM_SNP_THIS( This );
+
+ //
+ // Do we have any remaining packets from the previous read?
+ //
+ if ( Private->CurrentReadPointer >= Private->EndReadPointer )
+ {
+ Result = Private->UnixThunk->Read( Private->BpfFd, Private->ReadBuffer, Private->ReadBufferSize );
+
+ if ( Result < 0 )
+ {
+ Result = Private->UnixThunk->GetErrno();
+
+ //
+ // EAGAIN means that there's no I/O outstanding against this file descriptor.
+ //
+ if ( Result == EAGAIN )
+ {
+ return( EFI_NOT_READY );
+ }
+ else
+ {
+ return( EFI_DEVICE_ERROR );
+ }
+ }
+
+ if ( Result == 0 )
+ {
+ return( EFI_NOT_READY );
+ }
+
+ Private->CurrentReadPointer = Private->ReadBuffer;
+ Private->EndReadPointer = Private->CurrentReadPointer + Result;
+ }
+
+ BpfHeader = Private->CurrentReadPointer;
+ EnetHeader = Private->CurrentReadPointer + BpfHeader->bh_hdrlen;
+
+ if ( BpfHeader->bh_caplen > *BuffSize )
+ {
+ *BuffSize = BpfHeader->bh_caplen;
+ return( EFI_BUFFER_TOO_SMALL );
+ }
+
+ CopyMem( Buffer, EnetHeader, BpfHeader->bh_caplen );
+ *BuffSize = BpfHeader->bh_caplen;
+
+ if ( HeaderSize != NULL )
+ {
+ *HeaderSize = sizeof( EthernetHeader );
+ }
+
+ if ( DestinationAddr != NULL )
+ {
+ ZeroMem( DestinationAddr, sizeof( EFI_MAC_ADDRESS ) );
+ CopyMem( DestinationAddr, EnetHeader->DstAddr, NET_ETHER_ADDR_LEN );
+ }
+
+ if ( SourceAddr != NULL )
+ {
+ ZeroMem( SourceAddr, sizeof( EFI_MAC_ADDRESS ) );
+ CopyMem( SourceAddr, EnetHeader->SrcAddr, NET_ETHER_ADDR_LEN );
+ }
+
+ if ( Protocol != NULL )
+ {
+ *Protocol = NTOHS( EnetHeader->Type );
+ }
+
+ Private->CurrentReadPointer += BPF_WORDALIGN( BpfHeader->bh_hdrlen + BpfHeader->bh_caplen );
+
+ return( Status );
+}
+
+
+VOID
+EFIAPI
+UnixSnpWaitForPacketNotify(
+ IN EFI_EVENT Event,
+ IN VOID* Context
+ )
+{
+ UNIX_SNP_PRIVATE_DATA* Private;
+
+ Private = UNIX_SNP_PRIVATE_DATA_FROM_SNP_THIS( Context );
+
+ if ( Private->Snp.Mode->State < EfiSimpleNetworkStarted )
+ {
+ return;
+ }
+}
+
+
+/**
+ This is the declaration of an EFI image entry point. This entry point is
+ the same for UEFI Applications, UEFI OS Loaders, and UEFI Drivers including
+ both device drivers and bus drivers.
+
+ @param ImageHandle The firmware allocated handle for the UEFI image.
+ @param SystemTable A pointer to the EFI System Table.
+
+ @retval EFI_SUCCESS The operation completed successfully.
+ @retval EFI_OUT_OF_RESOURCES The request could not be completed due to a lack of resources.
+
+**/
+EFI_STATUS
+InitializeUnixSnpDriver(
+ IN EFI_HANDLE ImageHandle,
+ IN EFI_SYSTEM_TABLE* SystemTable
+ )
+{
+ EFI_STATUS Status;
+
+ //
+ // Install the Driver Protocols
+ //
+
+ Status = EfiLibInstallDriverBindingComponentName2(
+ ImageHandle,
+ SystemTable,
+ &gUnixSnpDriverBinding,
+ ImageHandle,
+ &gUnixSnpDriverComponentName,
+ &gUnixSnpDriverComponentName2
+ );
+
+ return( Status );
+}
diff --git a/UnixPkg/UnixSnpDxe/UnixSnp.h b/UnixPkg/UnixSnpDxe/UnixSnp.h
new file mode 100644
index 0000000000..de0b0aeaf2
--- /dev/null
+++ b/UnixPkg/UnixSnpDxe/UnixSnp.h
@@ -0,0 +1,156 @@
+/** @file
+
+ Copyright (c) 2010, Apple, Inc. All rights reserved.
+
+ This program and the accompanying materials
+ are licensed and made available under the terms and conditions of the BSD License
+ which accompanies this distribution. The full text of the license may be found at
+ http://opensource.org/licenses/bsd-license.php
+
+ THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+
+Module Name:
+
+ UnixSnp.h
+
+Abstract:
+
+-**/
+
+#ifndef _UNIX_SNP_H_
+#define _UNIX_SNP_H_
+
+#include <Uefi.h>
+
+#include <Protocol/SimpleNetwork.h>
+#include <Protocol/DevicePath.h>
+#include <Protocol/UnixIo.h>
+
+
+#include <Library/BaseLib.h>
+#include <Library/DebugLib.h>
+#include <Library/BaseMemoryLib.h>
+#include <Library/UefiBootServicesTableLib.h>
+#include <Library/UefiLib.h>
+#include <Library/DevicePathLib.h>
+#include <Library/MemoryAllocationLib.h>
+#include <Library/NetLib.h>
+
+#define NET_ETHER_HEADER_SIZE 14
+
+//
+// Private data for driver.
+//
+#define UNIX_SNP_PRIVATE_DATA_SIGNATURE SIGNATURE_32( 'U', 'S', 'N', 'P' )
+
+typedef struct
+{
+ UINT32 Signature;
+
+ EFI_UNIX_THUNK_PROTOCOL* UnixThunk;
+
+ EFI_HANDLE DeviceHandle;
+ EFI_DEVICE_PATH_PROTOCOL* DevicePath;
+
+ EFI_MAC_ADDRESS MacAddress;
+
+ CHAR8* InterfaceName;
+ INTN ReadBufferSize;
+ VOID* ReadBuffer;
+ //
+ // Two walking pointers to manage the multiple packets that can be returned
+ // in a single read.
+ //
+ VOID* CurrentReadPointer;
+ VOID* EndReadPointer;
+
+ INTN BpfFd;
+
+ EFI_SIMPLE_NETWORK_PROTOCOL Snp;
+ EFI_SIMPLE_NETWORK_MODE Mode;
+} UNIX_SNP_PRIVATE_DATA;
+
+#define UNIX_SNP_PRIVATE_DATA_FROM_SNP_THIS(a) \
+ CR( a, UNIX_SNP_PRIVATE_DATA, Snp, UNIX_SNP_PRIVATE_DATA_SIGNATURE )
+
+extern EFI_DRIVER_BINDING_PROTOCOL gUnixSnpDriverBinding;
+extern EFI_COMPONENT_NAME_PROTOCOL gUnixSnpDriverComponentName;
+extern EFI_COMPONENT_NAME2_PROTOCOL gUnixSnpDriverComponentName2;
+
+/**
+ Test to see if this driver supports ControllerHandle. This service
+ is called by the EFI boot service ConnectController(). In
+ order to make drivers as small as possible, there are a few calling
+ restrictions for this service. ConnectController() must
+ follow these calling restrictions. If any other agent wishes to call
+ Supported() it must also follow these calling restrictions.
+
+ @param This Protocol instance pointer.
+ @param ControllerHandle Handle of device to test
+ @param RemainingDevicePath Optional parameter use to pick a specific child
+ device to start.
+
+ @retval EFI_SUCCESS This driver supports this device
+ @retval EFI_UNSUPPORTED This driver does not support this device
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpDriverBindingSupported (
+ IN EFI_DRIVER_BINDING_PROTOCOL * This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_DEVICE_PATH_PROTOCOL * RemainingDevicePath OPTIONAL
+ );
+
+/**
+ Start this driver on ControllerHandle. This service is called by the
+ EFI boot service ConnectController(). In order to make
+ drivers as small as possible, there are a few calling restrictions for
+ this service. ConnectController() must follow these
+ calling restrictions. If any other agent wishes to call Start() it
+ must also follow these calling restrictions.
+
+ @param This Protocol instance pointer.
+ @param ControllerHandle Handle of device to bind driver to
+ @param RemainingDevicePath Optional parameter use to pick a specific child
+ device to start.
+
+ @retval EFI_SUCCESS Always succeeds.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpDriverBindingStart (
+ IN EFI_DRIVER_BINDING_PROTOCOL * This,
+ IN EFI_HANDLE ControllerHandle,
+ IN EFI_DEVICE_PATH_PROTOCOL * RemainingDevicePath OPTIONAL
+ );
+
+/**
+ Stop this driver on ControllerHandle. This service is called by the
+ EFI boot service DisconnectController(). In order to
+ make drivers as small as possible, there are a few calling
+ restrictions for this service. DisconnectController()
+ must follow these calling restrictions. If any other agent wishes
+ to call Stop() it must also follow these calling restrictions.
+
+ @param This Protocol instance pointer.
+ @param ControllerHandle Handle of device to stop driver on
+ @param NumberOfChildren Number of Handles in ChildHandleBuffer. If number of
+ children is zero stop the entire bus driver.
+ @param ChildHandleBuffer List of Child Handles to Stop.
+
+ @retval EFI_SUCCESS Always succeeds.
+
+**/
+EFI_STATUS
+EFIAPI
+UnixSnpDriverBindingStop (
+ IN EFI_DRIVER_BINDING_PROTOCOL *This,
+ IN EFI_HANDLE ControllerHandle,
+ IN UINTN NumberOfChildren,
+ IN EFI_HANDLE *ChildHandleBuffer
+ );
+
+#endif // _UNIX_SNP_H_
diff --git a/UnixPkg/UnixSnpDxe/UnixSnpDxe.inf b/UnixPkg/UnixSnpDxe/UnixSnpDxe.inf
new file mode 100644
index 0000000000..430cea5310
--- /dev/null
+++ b/UnixPkg/UnixSnpDxe/UnixSnpDxe.inf
@@ -0,0 +1,58 @@
+#/** @file
+# Component name for module UnixSnpDxe
+#
+# Copyright (c) 2010, Apple, Inc. All rights reserved
+#
+# All rights reserved. This program and the accompanying materials
+# are licensed and made available under the terms and conditions of the BSD License
+# which accompanies this distribution. The full text of the license may be found at
+# http://opensource.org/licenses/bsd-license.php
+#
+# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
+# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
+#
+#**/
+
+[Defines]
+ INF_VERSION = 0x00010005
+ BASE_NAME = UnixSnpDxe
+ FILE_GUID = 20BAF49B-036D-4CA6-8FAF-583ED2737F95
+ MODULE_TYPE = UEFI_DRIVER
+ VERSION_STRING = 1.0
+ EDK_RELEASE_VERSION = 0x00020000
+ EFI_SPECIFICATION_VERSION = 0x00020000
+
+ ENTRY_POINT = InitializeUnixSnpDriver
+# UNLOAD_IMAGE = UnixSnpUnload
+#
+# The following information is for reference only and not required by the build tools.
+#
+# VALID_ARCHITECTURES = IA32 X64 IPF EBC
+#
+
+[Sources.common]
+ ComponentName.c
+ UnixSnp.h
+ UnixSnp.c
+
+[Packages]
+ MdePkg/MdePkg.dec
+ MdeModulePkg/MdeModulePkg.dec
+ UnixPkg/UnixPkg.dec
+
+[LibraryClasses]
+ DevicePathLib
+ UefiLib
+ UefiBootServicesTableLib
+ BaseMemoryLib
+ DebugLib
+ UefiDriverEntryPoint
+ NetLib
+
+[Protocols]
+ gEfiSimpleNetworkProtocolGuid # PROTOCOL ALWAYS_CONSUMED
+ gEfiDevicePathProtocolGuid # PROTOCOL ALWAYS_CONSUMED
+ gEfiUnixIoProtocolGuid # PROTOCOL ALWAYS_CONSUMED
+
+[Guids]
+ gEfiUnixNetworkGuid # GUID ALWAYS_CONSUMED
diff --git a/UnixPkg/UnixUgaDxe/UnixUga.h b/UnixPkg/UnixUgaDxe/UnixUga.h
index b6d2a30853..e1e61f72f9 100644
--- a/UnixPkg/UnixUgaDxe/UnixUga.h
+++ b/UnixPkg/UnixUgaDxe/UnixUga.h
@@ -25,6 +25,7 @@ Abstract:
#include "PiDxe.h"
#include <Guid/EventGroup.h>
#include <Protocol/SimpleTextIn.h>
+#include <Protocol/SimplePointer.h>
#include <Protocol/UgaDraw.h>
#include "Protocol/UnixUgaIo.h"
#include <Library/DebugLib.h>
@@ -48,6 +49,7 @@ typedef struct {
EFI_HANDLE Handle;
EFI_UGA_DRAW_PROTOCOL UgaDraw;
EFI_SIMPLE_TEXT_INPUT_PROTOCOL SimpleTextIn;
+ EFI_SIMPLE_POINTER_PROTOCOL SimplePointer;
EFI_UNIX_THUNK_PROTOCOL *UnixThunk;
@@ -61,6 +63,8 @@ typedef struct {
UINT32 ColorDepth;
UINT32 RefreshRate;
+ EFI_SIMPLE_POINTER_MODE PointerMode;
+
//
// UGA Private Data knowing when to start hardware
//
@@ -78,6 +82,9 @@ typedef struct {
#define UGA_PRIVATE_DATA_FROM_TEXT_IN_THIS(a) \
CR(a, UGA_PRIVATE_DATA, SimpleTextIn, UGA_PRIVATE_DATA_SIGNATURE)
+#define UGA_PRIVATE_DATA_FROM_POINTER_THIS(a) \
+ CR(a, UGA_PRIVATE_DATA, SimplePointer, UGA_PRIVATE_DATA_SIGNATURE)
+
//
// Global Protocol Variables
//
@@ -301,4 +308,25 @@ Returns:
--*/
;
+
+EFI_STATUS
+UnixUgaInitializeSimplePointerForWindow (
+ IN UGA_PRIVATE_DATA *Private
+ )
+/*++
+
+Routine Description:
+
+ TODO: Add function description
+
+Arguments:
+
+ Private - TODO: add argument description
+
+Returns:
+
+ TODO: add return values
+
+--*/
+;
#endif
diff --git a/UnixPkg/UnixUgaDxe/UnixUga.inf b/UnixPkg/UnixUgaDxe/UnixUga.inf
index 707b64cefd..5cba6580da 100644
--- a/UnixPkg/UnixUgaDxe/UnixUga.inf
+++ b/UnixPkg/UnixUgaDxe/UnixUga.inf
@@ -66,6 +66,7 @@
[Protocols]
gEfiSimpleTextInProtocolGuid # PROTOCOL BY_START
+ gEfiSimplePointerProtocolGuid # PROTOCOL BY_START
gEfiUnixUgaIoProtocolGuid # PROTOCOL BY_START
gEfiUgaDrawProtocolGuid # PROTOCOL BY_START
gEfiUnixIoProtocolGuid # PROTOCOL TO_START
diff --git a/UnixPkg/UnixUgaDxe/UnixUgaDriver.c b/UnixPkg/UnixUgaDxe/UnixUgaDriver.c
index 4d3148baa3..99aa115038 100644
--- a/UnixPkg/UnixUgaDxe/UnixUgaDriver.c
+++ b/UnixPkg/UnixUgaDxe/UnixUgaDriver.c
@@ -177,6 +177,8 @@ Returns:
&Private->UgaDraw,
&gEfiSimpleTextInProtocolGuid,
&Private->SimpleTextIn,
+ &gEfiSimplePointerProtocolGuid,
+ &Private->SimplePointer,
NULL
);
@@ -264,6 +266,8 @@ Returns:
&Private->UgaDraw,
&gEfiSimpleTextInProtocolGuid,
&Private->SimpleTextIn,
+ &gEfiSimplePointerProtocolGuid,
+ &Private->SimplePointer,
NULL
);
if (!EFI_ERROR (Status)) {
diff --git a/UnixPkg/UnixUgaDxe/UnixUgaInput.c b/UnixPkg/UnixUgaDxe/UnixUgaInput.c
index f37c086cbc..4415e04b44 100644
--- a/UnixPkg/UnixUgaDxe/UnixUgaInput.c
+++ b/UnixPkg/UnixUgaDxe/UnixUgaInput.c
@@ -1,6 +1,7 @@
/*++
Copyright (c) 2006, Intel Corporation. All rights reserved.<BR>
+Portions copyright (c) 2010, Apple, Inc. All rights reserved.
This program and the accompanying materials
are licensed and made available under the terms and conditions of the BSD License
which accompanies this distribution. The full text of the license may be found at
@@ -57,7 +58,7 @@ Returns:
--*/
{
UGA_PRIVATE_DATA *Private;
- EFI_INPUT_KEY Key;
+ EFI_KEY_DATA Key;
EFI_TPL OldTpl;
Private = UGA_PRIVATE_DATA_FROM_TEXT_IN_THIS (This);
@@ -73,7 +74,7 @@ Returns:
//
// A reset is draining the Queue
//
- while (Private->UgaIo->UgaGetKey(Private->UgaIo, &Key) == EFI_SUCCESS)
+ while (Private->UgaIo->UgaGetKey (Private->UgaIo, &Key) == EFI_SUCCESS)
;
//
@@ -87,7 +88,7 @@ EFI_STATUS
EFIAPI
UnixUgaSimpleTextInReadKeyStroke (
IN EFI_SIMPLE_TEXT_INPUT_PROTOCOL *This,
- OUT EFI_INPUT_KEY *Key
+ OUT EFI_INPUT_KEY *Key
)
/*++
@@ -109,7 +110,8 @@ Returns:
UGA_PRIVATE_DATA *Private;
EFI_STATUS Status;
EFI_TPL OldTpl;
-
+ EFI_KEY_DATA KeyData;
+
Private = UGA_PRIVATE_DATA_FROM_TEXT_IN_THIS (This);
if (Private->UgaIo == NULL) {
return EFI_NOT_READY;
@@ -120,7 +122,9 @@ Returns:
//
OldTpl = gBS->RaiseTPL (TPL_NOTIFY);
- Status = Private->UgaIo->UgaGetKey(Private->UgaIo, Key);
+ Status = Private->UgaIo->UgaGetKey(Private->UgaIo, &KeyData);
+ CopyMem (Key, &KeyData, sizeof (EFI_INPUT_KEY));
+
//
// Leave critical section and return
//
@@ -179,6 +183,156 @@ Returns:
gBS->RestoreTPL (OldTpl);
}
+//
+// Simple Pointer implementation.
+//
+
+EFI_STATUS
+EFIAPI
+UnixUgaSimplePointerReset (
+ IN EFI_SIMPLE_POINTER_PROTOCOL *This,
+ IN BOOLEAN ExtendedVerification
+ )
+/*++
+
+Routine Description:
+
+ TODO: Add function description
+
+Arguments:
+
+ This - TODO: add argument description
+ ExtendedVerification - TODO: add argument description
+
+Returns:
+
+ EFI_SUCCESS - TODO: Add description for return value
+
+--*/
+{
+ UGA_PRIVATE_DATA *Private;
+ EFI_SIMPLE_POINTER_STATE State;
+ EFI_TPL OldTpl;
+
+ Private = UGA_PRIVATE_DATA_FROM_POINTER_THIS (This);
+ if (Private->UgaIo == NULL) {
+ return EFI_SUCCESS;
+ }
+
+ //
+ // Enter critical section
+ //
+ OldTpl = gBS->RaiseTPL (TPL_NOTIFY);
+
+ //
+ // A reset is draining the Queue
+ //
+ while (Private->UgaIo->UgaGetPointerState(Private->UgaIo, &State) == EFI_SUCCESS)
+ ;
+
+ //
+ // Leave critical section and return
+ //
+ gBS->RestoreTPL (OldTpl);
+ return EFI_SUCCESS;
+}
+
+EFI_STATUS
+EFIAPI
+UnixUgaSimplePointerGetState (
+ IN EFI_SIMPLE_POINTER_PROTOCOL *This,
+ IN OUT EFI_SIMPLE_POINTER_STATE *State
+ )
+/*++
+
+Routine Description:
+
+ TODO: Add function description
+
+Arguments:
+
+ This - TODO: add argument description
+ Key - TODO: add argument description
+
+Returns:
+
+ TODO: add return values
+
+--*/
+{
+ UGA_PRIVATE_DATA *Private;
+ EFI_STATUS Status;
+ EFI_TPL OldTpl;
+
+ Private = UGA_PRIVATE_DATA_FROM_POINTER_THIS (This);
+ if (Private->UgaIo == NULL) {
+ return EFI_NOT_READY;
+ }
+
+ //
+ // Enter critical section
+ //
+ OldTpl = gBS->RaiseTPL (TPL_NOTIFY);
+
+ Status = Private->UgaIo->UgaGetPointerState(Private->UgaIo, State);
+ //
+ // Leave critical section and return
+ //
+ gBS->RestoreTPL (OldTpl);
+
+ return Status;
+}
+
+VOID
+EFIAPI
+UnixUgaSimplePointerWaitForInput (
+ IN EFI_EVENT Event,
+ IN VOID *Context
+ )
+/*++
+
+Routine Description:
+
+ TODO: Add function description
+
+Arguments:
+
+ Event - TODO: add argument description
+ Context - TODO: add argument description
+
+Returns:
+
+ TODO: add return values
+
+--*/
+{
+ UGA_PRIVATE_DATA *Private;
+ EFI_STATUS Status;
+ EFI_TPL OldTpl;
+
+ Private = (UGA_PRIVATE_DATA *) Context;
+ if (Private->UgaIo == NULL) {
+ return;
+ }
+
+ //
+ // Enter critical section
+ //
+ OldTpl = gBS->RaiseTPL (TPL_NOTIFY);
+
+ Status = Private->UgaIo->UgaCheckPointer(Private->UgaIo);
+ if (!EFI_ERROR (Status)) {
+ //
+ // If the pointer state has changed, signal our event.
+ //
+ gBS->SignalEvent (Event);
+ }
+ //
+ // Leave critical section and return
+ //
+ gBS->RestoreTPL (OldTpl);
+}
+
EFI_STATUS
UnixUgaInitializeSimpleTextInForWindow (
IN UGA_PRIVATE_DATA *Private
@@ -217,3 +371,48 @@ Returns:
return Status;
}
+
+EFI_STATUS
+UnixUgaInitializeSimplePointerForWindow (
+ IN UGA_PRIVATE_DATA *Private
+ )
+/*++
+
+Routine Description:
+
+ TODO: Add function description
+
+Arguments:
+
+ Private - TODO: add argument description
+
+Returns:
+
+ TODO: add return values
+
+--*/
+{
+ EFI_STATUS Status;
+
+ //
+ // Initialize Simple Pointer protoocol
+ //
+ Private->PointerMode.ResolutionX = 1;
+ Private->PointerMode.ResolutionY = 1;
+ Private->PointerMode.LeftButton = TRUE;
+ Private->PointerMode.RightButton = TRUE;
+
+ Private->SimplePointer.Reset = UnixUgaSimplePointerReset;
+ Private->SimplePointer.GetState = UnixUgaSimplePointerGetState;
+ Private->SimplePointer.Mode = &Private->PointerMode;
+
+ Status = gBS->CreateEvent (
+ EVT_NOTIFY_WAIT,
+ TPL_NOTIFY,
+ UnixUgaSimplePointerWaitForInput,
+ Private,
+ &Private->SimplePointer.WaitForInput
+ );
+
+ return Status;
+}
diff --git a/UnixPkg/UnixUgaDxe/UnixUgaScreen.c b/UnixPkg/UnixUgaDxe/UnixUgaScreen.c
index 45e84b0f25..470a788a10 100644
--- a/UnixPkg/UnixUgaDxe/UnixUgaScreen.c
+++ b/UnixPkg/UnixUgaDxe/UnixUgaScreen.c
@@ -394,6 +394,8 @@ Returns:
UnixUgaInitializeSimpleTextInForWindow (Private);
+ UnixUgaInitializeSimplePointerForWindow (Private);
+
return EFI_SUCCESS;
}
diff --git a/UnixPkg/Xcode/xcode_project/XcodeBuild.sh b/UnixPkg/Xcode/xcode_project/XcodeBuild.sh
index 096233b60f..453aac1896 100755
--- a/UnixPkg/Xcode/xcode_project/XcodeBuild.sh
+++ b/UnixPkg/Xcode/xcode_project/XcodeBuild.sh
@@ -7,7 +7,7 @@
set -e
#
-# Source the workspace and set up the environment varaibles we need
+# Source the workspace and set up the environment variables we need
#
cd ../..
./build.sh $1 $2 $3 $4 $5 $6 $8
diff --git a/UnixPkg/Xcode/xcode_project64/XcodeBuild.sh b/UnixPkg/Xcode/xcode_project64/XcodeBuild.sh
index 644c6e1e0f..0ccda8f9ef 100755
--- a/UnixPkg/Xcode/xcode_project64/XcodeBuild.sh
+++ b/UnixPkg/Xcode/xcode_project64/XcodeBuild.sh
@@ -7,7 +7,7 @@
set -e
#
-# Source the workspace and set up the environment varaibles we need
+# Source the workspace and set up the environment variables we need
#
cd ../..
echo `pwd`