summaryrefslogtreecommitdiff
path: root/IntelFrameworkModulePkg/Bus/Isa
diff options
context:
space:
mode:
authorgikidy <gikidy@6f19259b-4bc3-4df7-8a09-765794883524>2009-04-24 07:30:54 +0000
committergikidy <gikidy@6f19259b-4bc3-4df7-8a09-765794883524>2009-04-24 07:30:54 +0000
commit9f6531d14d145918079d03926ff827f6c1a274a4 (patch)
treeecbc4f73f2e538769cf0b4ea1137555bd7af00b4 /IntelFrameworkModulePkg/Bus/Isa
parent14d59fa188194a6199a04677352d9d47b26ad632 (diff)
downloadedk2-platforms-9f6531d14d145918079d03926ff827f6c1a274a4.tar.xz
Adjust the code so that global variable placed at beginning of file.
git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8172 6f19259b-4bc3-4df7-8a09-765794883524
Diffstat (limited to 'IntelFrameworkModulePkg/Bus/Isa')
-rw-r--r--IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/InternalIsaBus.h15
-rw-r--r--IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/Serial.h4
-rw-r--r--IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KbdCtrller.c116
-rw-r--r--IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2Keyboard.h15
-rw-r--r--IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/Ps2MouseAbsolutePointer.h14
-rw-r--r--IntelFrameworkModulePkg/Bus/Isa/Ps2MouseDxe/Ps2Mouse.h14
6 files changed, 86 insertions, 92 deletions
diff --git a/IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/InternalIsaBus.h b/IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/InternalIsaBus.h
index 66bd00ad86..9bfd065b1a 100644
--- a/IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/InternalIsaBus.h
+++ b/IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/InternalIsaBus.h
@@ -41,6 +41,13 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#include "ComponentName.h"
//
+// Global Variables
+//
+extern EFI_DRIVER_BINDING_PROTOCOL gIsaBusControllerDriver;
+
+extern EFI_ISA_IO_PROTOCOL IsaIoInterface;
+
+//
// 8237 DMA registers
//
#define R_8237_DMA_BASE_CA_CH0 0x00
@@ -106,9 +113,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#define R_8237_DMA_WRMSK_CH0_3 0x0f
#define R_8237_DMA_WRMSK_CH4_7 0xde
-
-extern EFI_ISA_IO_PROTOCOL IsaIoInterface;
-
typedef enum {
IsaAccessTypeUnknown,
IsaAccessTypeIo,
@@ -147,11 +151,6 @@ typedef struct {
#define ISA_IO_DEVICE_FROM_ISA_IO_THIS(a) CR (a, ISA_IO_DEVICE, IsaIo, ISA_IO_DEVICE_SIGNATURE)
//
-// Global Variables
-//
-extern EFI_DRIVER_BINDING_PROTOCOL gIsaBusControllerDriver;
-
-//
// Mapping structure for performing ISA DMA to a buffer above 16 MB
//
typedef struct {
diff --git a/IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/Serial.h b/IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/Serial.h
index 2d3f71c136..af4428a996 100644
--- a/IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/Serial.h
+++ b/IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/Serial.h
@@ -114,10 +114,6 @@ typedef struct {
#define SERIAL_DEV_FROM_THIS(a) CR (a, SERIAL_DEV, SerialIo, SERIAL_DEV_SIGNATURE)
-//
-// Globale Variables
-//
-extern EFI_DRIVER_BINDING_PROTOCOL gSerialControllerDriver;
//
// Serial Driver Defaults
diff --git a/IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KbdCtrller.c b/IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KbdCtrller.c
index 973cf24afb..3662340149 100644
--- a/IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KbdCtrller.c
+++ b/IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KbdCtrller.c
@@ -15,64 +15,6 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#include "Ps2Keyboard.h"
-//
-// Function declarations
-//
-UINT8
-KeyReadDataRegister (
- IN KEYBOARD_CONSOLE_IN_DEV *ConsoleIn
- );
-
-VOID
-KeyWriteDataRegister (
- IN KEYBOARD_CONSOLE_IN_DEV *ConsoleIn,
- IN UINT8 Data
- );
-
-VOID
-KeyWriteCommandRegister (
- IN KEYBOARD_CONSOLE_IN_DEV *ConsoleIn,
- IN UINT8 Data
- );
-
-VOID
-KeyboardError (
- IN KEYBOARD_CONSOLE_IN_DEV*ConsoleIn,
- IN CHAR16 *ErrMsg // should be a unicode string
- );
-
-EFI_STATUS
-GetScancodeBufHead (
- KEYBOARD_CONSOLE_IN_DEV *ConsoleIn,
- IN UINT32 Count,
- OUT UINT8 *Buf
- );
-
-EFI_STATUS
-PopScancodeBufHead (
- KEYBOARD_CONSOLE_IN_DEV *ConsoleIn,
- IN UINT32 Count,
- OUT UINT8 *Buf
- );
-
-EFI_STATUS
-KeyboardWrite (
- IN KEYBOARD_CONSOLE_IN_DEV *ConsoleIn,
- IN UINT8 Data
- );
-
-EFI_STATUS
-KeyboardCommand (
- IN KEYBOARD_CONSOLE_IN_DEV *ConsoleIn,
- IN UINT8 Data
- );
-
-EFI_STATUS
-KeyboardWaitForValue (
- IN KEYBOARD_CONSOLE_IN_DEV *ConsoleIn,
- IN UINT8 Value
- );
-
struct {
UINT8 ScanCode;
UINT16 EfiScanCode;
@@ -625,6 +567,64 @@ UINTN mWaitForValueTimeOut = KEYBOARD_WAITFORVALUE_TIMEOUT;
BOOLEAN mEnableMouseInterface;
+//
+// Function declarations
+//
+UINT8
+KeyReadDataRegister (
+ IN KEYBOARD_CONSOLE_IN_DEV *ConsoleIn
+ );
+
+VOID
+KeyWriteDataRegister (
+ IN KEYBOARD_CONSOLE_IN_DEV *ConsoleIn,
+ IN UINT8 Data
+ );
+
+VOID
+KeyWriteCommandRegister (
+ IN KEYBOARD_CONSOLE_IN_DEV *ConsoleIn,
+ IN UINT8 Data
+ );
+
+VOID
+KeyboardError (
+ IN KEYBOARD_CONSOLE_IN_DEV*ConsoleIn,
+ IN CHAR16 *ErrMsg // should be a unicode string
+ );
+
+EFI_STATUS
+GetScancodeBufHead (
+ KEYBOARD_CONSOLE_IN_DEV *ConsoleIn,
+ IN UINT32 Count,
+ OUT UINT8 *Buf
+ );
+
+EFI_STATUS
+PopScancodeBufHead (
+ KEYBOARD_CONSOLE_IN_DEV *ConsoleIn,
+ IN UINT32 Count,
+ OUT UINT8 *Buf
+ );
+
+EFI_STATUS
+KeyboardWrite (
+ IN KEYBOARD_CONSOLE_IN_DEV *ConsoleIn,
+ IN UINT8 Data
+ );
+
+EFI_STATUS
+KeyboardCommand (
+ IN KEYBOARD_CONSOLE_IN_DEV *ConsoleIn,
+ IN UINT8 Data
+ );
+
+EFI_STATUS
+KeyboardWaitForValue (
+ IN KEYBOARD_CONSOLE_IN_DEV *ConsoleIn,
+ IN UINT8 Value
+ );
+
/**
Read data register
diff --git a/IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2Keyboard.h b/IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2Keyboard.h
index a029ef910f..cbfbbda768 100644
--- a/IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2Keyboard.h
+++ b/IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2Keyboard.h
@@ -35,6 +35,13 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#include <Library/BaseMemoryLib.h>
//
+// Global Variables
+//
+extern EFI_DRIVER_BINDING_PROTOCOL gKeyboardControllerDriver;
+extern EFI_COMPONENT_NAME_PROTOCOL gPs2KeyboardComponentName;
+extern EFI_COMPONENT_NAME2_PROTOCOL gPs2KeyboardComponentName2;
+
+//
// Driver Private Data
//
#define KEYBOARD_BUFFER_MAX_COUNT 32
@@ -120,14 +127,6 @@ typedef struct {
#define TABLE_END 0x0
//
-// Global Variables
-//
-extern EFI_DRIVER_BINDING_PROTOCOL gKeyboardControllerDriver;
-extern EFI_COMPONENT_NAME_PROTOCOL gPs2KeyboardComponentName;
-extern EFI_COMPONENT_NAME2_PROTOCOL gPs2KeyboardComponentName2;
-
-
-//
// Driver entry point
//
/**
diff --git a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/Ps2MouseAbsolutePointer.h b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/Ps2MouseAbsolutePointer.h
index d7041a40ae..8f6c43591a 100644
--- a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/Ps2MouseAbsolutePointer.h
+++ b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/Ps2MouseAbsolutePointer.h
@@ -31,6 +31,13 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#include <Library/ReportStatusCodeLib.h>
//
+// Global Variables
+//
+extern EFI_DRIVER_BINDING_PROTOCOL gPS2MouseAbsolutePointerDriver;
+extern EFI_COMPONENT_NAME_PROTOCOL gPs2MouseAbsolutePointerComponentName;
+extern EFI_COMPONENT_NAME2_PROTOCOL gPs2MouseAbsolutePointerComponentName2;
+
+//
// PS/2 mouse sample rate
//
typedef enum {
@@ -96,13 +103,6 @@ typedef struct {
#define PS2_MOUSE_ABSOLUTE_POINTER_DEV_FROM_THIS(a) CR (a, PS2_MOUSE_ABSOLUTE_POINTER_DEV, AbsolutePointerProtocol, PS2_MOUSE_ABSOLUTE_POINTER_DEV_SIGNATURE)
//
-// Global Variables
-//
-extern EFI_DRIVER_BINDING_PROTOCOL gPS2MouseAbsolutePointerDriver;
-extern EFI_COMPONENT_NAME_PROTOCOL gPs2MouseAbsolutePointerComponentName;
-extern EFI_COMPONENT_NAME2_PROTOCOL gPs2MouseAbsolutePointerComponentName2;
-
-//
// Function prototypes
//
EFI_STATUS
diff --git a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseDxe/Ps2Mouse.h b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseDxe/Ps2Mouse.h
index 5102d34307..b4454b1842 100644
--- a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseDxe/Ps2Mouse.h
+++ b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseDxe/Ps2Mouse.h
@@ -31,6 +31,13 @@ WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
#include <Library/ReportStatusCodeLib.h>
//
+// Global Variables
+//
+extern EFI_DRIVER_BINDING_PROTOCOL gPS2MouseDriver;
+extern EFI_COMPONENT_NAME_PROTOCOL gPs2MouseComponentName;
+extern EFI_COMPONENT_NAME2_PROTOCOL gPs2MouseComponentName2;
+
+//
// PS/2 mouse sample rate
//
typedef enum {
@@ -96,13 +103,6 @@ typedef struct {
#define PS2_MOUSE_DEV_FROM_THIS(a) CR (a, PS2_MOUSE_DEV, SimplePointerProtocol, PS2_MOUSE_DEV_SIGNATURE)
//
-// Global Variables
-//
-extern EFI_DRIVER_BINDING_PROTOCOL gPS2MouseDriver;
-extern EFI_COMPONENT_NAME_PROTOCOL gPs2MouseComponentName;
-extern EFI_COMPONENT_NAME2_PROTOCOL gPs2MouseComponentName2;
-
-//
// Function prototypes
//
EFI_STATUS