clean ECC issue

git-svn-id: https://edk2.svn.sourceforge.net/svnroot/edk2/trunk/edk2@8580 6f19259b-4bc3-4df7-8a09-765794883524
diff --git a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/CommPs2.c b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/CommPs2.c
index 60614fb..b5d1679 100644
--- a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/CommPs2.c
+++ b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/CommPs2.c
@@ -1,5 +1,5 @@
-/**@file

-  PS2 Mouse Communication Interface 

+/** @file

+  PS2 Mouse Communication Interface.

   

 Copyright (c) 2006 - 2007, Intel Corporation

 All rights reserved. This program and the accompanying materials

@@ -341,7 +341,7 @@
 /**

   Get mouse packet . Only care first 3 bytes

 

-  @param MouseDev  Pointer of PS2 Mouse Private Data Structure 

+  @param MouseAbsolutePointerDev  Pointer to PS2 Absolute Pointer Simulation Device Private Data Structure 

 

   @retval EFI_NOT_READY  Mouse Device not ready to input data packet, or some error happened during getting the packet

   @retval EFI_SUCCESS    The data packet is gotten successfully.

@@ -589,7 +589,7 @@
   )

 {

   EFI_STATUS  Status;

-  UINT8       temp;

+  UINT8       Temp;

   //

   // Wait keyboard controller input buffer empty

   //

@@ -598,8 +598,8 @@
     return Status;

   }

 

-  temp = Data;

-  IsaIo->Io.Write (IsaIo, EfiIsaIoWidthUint8, KBC_DATA_PORT, 1, &temp);

+  Temp = Data;

+  IsaIo->Io.Write (IsaIo, EfiIsaIoWidthUint8, KBC_DATA_PORT, 1, &Temp);

 

   Status = WaitInputEmpty (IsaIo, TIMEOUT);

   if (EFI_ERROR (Status)) {

@@ -625,23 +625,23 @@
   )

 {

   UINTN Delay;

-  UINT8 temp;

+  UINT8 Temp;

 

   Delay = TIMEOUT / 50;

 

   do {

-    IsaIo->Io.Read (IsaIo, EfiIsaIoWidthUint8, KBC_CMD_STS_PORT, 1, &temp);

+    IsaIo->Io.Read (IsaIo, EfiIsaIoWidthUint8, KBC_CMD_STS_PORT, 1, &Temp);

 

     //

     // Check keyboard controller status bit 0(output buffer status)

     //

-    if ((temp & KBC_OUTB) == KBC_OUTB) {

+    if ((Temp & KBC_OUTB) == KBC_OUTB) {

       break;

     }

 

     gBS->Stall (50);

     Delay--;

-  } while (Delay);

+  } while (Delay != 0);

 

   if (Delay == 0) {

     return EFI_TIMEOUT;

@@ -738,9 +738,9 @@
   I/O work flow of outing 8042 Aux data.

   

   @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL

-  @param Command Aux I/O command

+  @param Data    Buffer holding return value  

   

-  @retval EFI_SUCCESS Success to excute I/O work flow

+  @retval EFI_SUCCESS Success to excute I/O work flow.

   @retval EFI_TIMEOUT Keyboard controller time out.

 **/

 EFI_STATUS

@@ -812,7 +812,7 @@
 

 

 /**

-  Check keyboard controller status, if it is output buffer full and for auxiliary device

+  Check keyboard controller status, if it is output buffer full and for auxiliary device.

   

   @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL

   

@@ -870,7 +870,7 @@
 

     gBS->Stall (50);

     Delay--;

-  } while (Delay);

+  } while (Delay != 0);

 

   if (Delay == 0) {

     return EFI_TIMEOUT;

@@ -893,23 +893,6 @@
   IN EFI_ISA_IO_PROTOCOL                  *IsaIo,

   IN UINTN                                Timeout

   )

-/**

-

-Routine Description:

-

-  GC_TODO: Add function description

-

-Arguments:

-

-  IsaIo   - GC_TODO: add argument description

-  Timeout - GC_TODO: add argument description

-

-Returns:

-

-  EFI_TIMEOUT - GC_TODO: Add description for return value

-  EFI_SUCCESS - GC_TODO: Add description for return value

-

-**/

 {

   UINTN Delay;

   UINT8 Data;

@@ -929,7 +912,7 @@
 

     gBS->Stall (50);

     Delay--;

-  } while (Delay);

+  } while (Delay != 0);

 

   if (Delay == 0) {

     return EFI_TIMEOUT;

diff --git a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/CommPs2.h b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/CommPs2.h
index fb2bbac..294aace 100644
--- a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/CommPs2.h
+++ b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/CommPs2.h
@@ -1,5 +1,5 @@
-/**@file

-  PS2 Mouse Communication Interface 

+/** @file

+  Using PS2 Mouse to simulation Absolution Pointer Device.

   

 Copyright (c) 2006 - 2007, Intel Corporation

 All rights reserved. This program and the accompanying materials

@@ -12,8 +12,8 @@
 

 **/

 

-#ifndef _COMMPS2_H_

-#define _COMMPS2_H_

+#ifndef __COMMPS2_H__

+#define __COMMPS2_H__

 

 #define PS2_PACKET_LENGTH       3

 #define PS2_SYNC_MASK           0xc

@@ -246,7 +246,7 @@
 /**

   Get mouse packet . Only care first 3 bytes

 

-  @param MouseDev  Pointer of PS2 Mouse Private Data Structure 

+  @param MouseAbsolutePointerDev  Pointer to PS2 Absolute Pointer Simulation Device Private Data Structure

 

   @retval EFI_NOT_READY  Mouse Device not ready to input data packet, or some error happened during getting the packet

   @retval EFI_SUCCESS    The data packet is gotten successfully.

@@ -359,7 +359,7 @@
   I/O work flow of outing 8042 Aux data.

   

   @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL

-  @param Command Aux I/O command

+  @param Data    Buffer holding return value.

   

   @retval EFI_SUCCESS Success to excute I/O work flow

   @retval EFI_TIMEOUT Keyboard controller time out.

@@ -371,7 +371,7 @@
   );

 

 /**

-  Check keyboard controller status, if it is output buffer full and for auxiliary device

+  Check keyboard controller status, if it is output buffer full and for auxiliary device.

   

   @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL

   

@@ -413,4 +413,4 @@
   IN UINTN                                Timeout

   );

 

-#endif // _COMMPS2_H_

+#endif // __COMMPS2_H__

diff --git a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/ComponentName.c b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/ComponentName.c
index 39505ac..5c0b038 100644
--- a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/ComponentName.c
+++ b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/ComponentName.c
@@ -1,4 +1,5 @@
-/**@file

+/** @file

+  UEFI Component Name(2) protocol implementation for Ps2 Absolute Pointer Simulation Dxe driver.

 

 Copyright (c) 2006 - 2007, Intel Corporation

 All rights reserved. This program and the accompanying materials

diff --git a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/Ps2MouseAbsolutePointer.c b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/Ps2MouseAbsolutePointer.c
index 55ebf95..89f6d1d 100644
--- a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/Ps2MouseAbsolutePointer.c
+++ b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/Ps2MouseAbsolutePointer.c
@@ -1,5 +1,5 @@
-/**@file

-  A faked PS/2 Touchpad driver. Routines that interacts with callers,

+/** @file

+  A faked PS/2 Absolute Pointer driver. Routines that interacts with callers,

   conforming to EFI driver model

   

 Copyright (c) 2006 - 2007, Intel Corporation

@@ -486,7 +486,7 @@
 }

 

 /**

-  Reset the Mouse and do BAT test for it, if ExtendedVerification isTRUE and there is a mouse device connectted to system

+  Reset the Mouse and do BAT test for it, if ExtendedVerification isTRUE and there is a mouse device connectted to system.

 

   @param This                 - Pointer of simple pointer Protocol.

   @param ExtendedVerification - Whether configure mouse parameters. True: do; FALSE: skip.

@@ -604,7 +604,7 @@
 /**

   Check whether there is Ps/2 mouse device in system

 

-  @param PS2_MOUSE_DEV - Mouse Private Data Structure

+  @param MouseAbsolutePointerDev - Absolute Pointer Device Private Data Structure

 

   @retval TRUE                - Keyboard in System.

   @retval FALSE               - Keyboard not in System.

@@ -674,22 +674,19 @@
 

 /**

 

-  Event notification function for SIMPLE_POINTER.WaitForInput event

-  Signal the event if there is input from mouse

+  Event notification function for SIMPLE_POINTER.WaitForInput event.

+  Signal the event if there is input from mouse.

 

   @param Event    event object

   @param Context  event context

 

 **/

-

 VOID

 EFIAPI

 MouseAbsolutePointerWaitForInput (

   IN  EFI_EVENT               Event,

   IN  VOID                    *Context

   )

-// GC_TODO:    Event - add argument and description to function comment

-// GC_TODO:    Context - add argument and description to function comment

 {

   PS2_MOUSE_ABSOLUTE_POINTER_DEV *MouseAbsolutePointerDev;

 

@@ -706,8 +703,8 @@
 }

 

 /**

-  Event notification function for TimerEvent event

-  If mouse device is connected to system, try to get the mouse packet data

+  Event notification function for TimerEvent event.

+  If mouse device is connected to system, try to get the mouse packet data.

 

   @param Event      -  TimerEvent in PS2_MOUSE_DEV

   @param Context    -  Pointer to PS2_MOUSE_DEV structure

diff --git a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/Ps2MouseAbsolutePointer.h b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/Ps2MouseAbsolutePointer.h
index e8266f8..7a111f3 100644
--- a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/Ps2MouseAbsolutePointer.h
+++ b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/Ps2MouseAbsolutePointer.h
@@ -1,4 +1,4 @@
-/**@file

+/** @file

   A Ps2MouseAbsolutePointer driver header file

   

 Copyright (c) 2006 - 2007, Intel Corporation

@@ -12,8 +12,8 @@
 

 **/

 

-#ifndef _PS2MOUSEABSOLUTEPOINTER_H

-#define _PS2MOUSEABSOLUTEPOINTER_H

+#ifndef __PS2MOUSEABSOLUTEPOINTER_H__

+#define __PS2MOUSEABSOLUTEPOINTER_H__

 

 #include <PiDxe.h>

 #include <Framework/StatusCode.h>

@@ -105,6 +105,20 @@
 //

 // Function prototypes

 //

+/**

+  Test to see if this driver supports ControllerHandle. Any ControllerHandle

+  than contains a IsaIo protocol can be supported.

+

+  @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_ALREADY_STARTED This driver is already running on this device

+  @retval other               This driver does not support this device

+

+**/

 EFI_STATUS

 EFIAPI

 PS2MouseAbsolutePointerDriverSupported (

@@ -113,6 +127,21 @@
   IN EFI_DEVICE_PATH_PROTOCOL       *RemainingDevicePath

   );

 

+/**

+  Start this driver on ControllerHandle by opening a IsaIo

+  protocol, creating PS2_MOUSE_ABSOLUTE_POINTER_DEV device and install gEfiAbsolutePointerProtocolGuid

+  finnally.

+

+  @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          This driver is added to ControllerHandle

+  @retval EFI_ALREADY_STARTED  This driver is already running on ControllerHandle

+  @retval other                This driver does not support this device

+

+**/

 EFI_STATUS

 EFIAPI

 PS2MouseAbsolutePointerDriverStart (

@@ -121,6 +150,20 @@
   IN EFI_DEVICE_PATH_PROTOCOL       *RemainingDevicePath

   );

 

+/**

+  Stop this driver on ControllerHandle. Support stoping any child handles

+  created by this driver.

+

+  @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       This driver is removed ControllerHandle

+  @retval other             This driver was not removed from this device

+

+**/

 EFI_STATUS

 EFIAPI

 PS2MouseAbsolutePointerDriverStop (

@@ -259,7 +302,17 @@
   OUT CHAR16                                          **ControllerName

   );

 

+/**

+  Reset the Mouse and do BAT test for it, if ExtendedVerification isTRUE and there is a mouse device connectted to system.

 

+  @param This                 - Pointer of simple pointer Protocol.

+  @param ExtendedVerification - Whether configure mouse parameters. True: do; FALSE: skip.

+

+

+  @retval EFI_SUCCESS         - The command byte is written successfully.

+  @retval EFI_DEVICE_ERROR    - Errors occurred during reseting keyboard.

+

+**/

 EFI_STATUS

 EFIAPI

 MouseAbsolutePointerReset (

@@ -267,6 +320,16 @@
   IN BOOLEAN                        ExtendedVerification

   );

 

+/**

+  Get and Clear mouse status.

+  

+  @param This                 - Pointer of simple pointer Protocol.

+  @param State                - Output buffer holding status.

+

+  @retval EFI_INVALID_PARAMETER Output buffer is invalid.

+  @retval EFI_NOT_READY         Mouse is not changed status yet.

+  @retval EFI_SUCCESS           Mouse status is changed and get successful.

+**/

 EFI_STATUS

 EFIAPI

 MouseAbsolutePointerGetState (

@@ -274,6 +337,15 @@
   IN OUT EFI_ABSOLUTE_POINTER_STATE   *State

   );

 

+/**

+

+  Event notification function for SIMPLE_POINTER.WaitForInput event.

+  Signal the event if there is input from mouse.

+

+  @param Event    event object

+  @param Context  event context

+

+**/

 VOID

 EFIAPI

 MouseAbsolutePointerWaitForInput (

@@ -281,6 +353,14 @@
   IN  VOID                    *Context

   );

 

+/**

+  Event notification function for TimerEvent event.

+  If mouse device is connected to system, try to get the mouse packet data.

+

+  @param Event      -  TimerEvent in PS2_MOUSE_DEV

+  @param Context    -  Pointer to PS2_MOUSE_DEV structure

+

+**/

 VOID

 EFIAPI

 PollMouseAbsolutePointer (

@@ -288,11 +368,30 @@
   IN VOID       *Context

   );

 

+/**

+  I/O work flow of in 8042 data.

+  

+  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL

+  @param Data    Data value

+  

+  @retval EFI_SUCCESS Success to excute I/O work flow

+  @retval EFI_TIMEOUT Keyboard controller time out.

+**/

 EFI_STATUS

 In8042Data (

   IN EFI_ISA_IO_PROTOCOL                  *IsaIo,

   IN OUT UINT8                            *Data

   );

+

+/**

+  Check whether there is Ps/2 mouse device in system

+

+  @param MouseAbsolutePointerDev - Absolute Pointer Device Private Data Structure

+

+  @retval TRUE                - Keyboard in System.

+  @retval FALSE               - Keyboard not in System.

+

+**/

 BOOLEAN

 CheckMouseAbsolutePointerConnect (

   IN  PS2_MOUSE_ABSOLUTE_POINTER_DEV     *MouseAbsolutePointerDev

diff --git a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseDxe/Ps2Mouse.c b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseDxe/Ps2Mouse.c
index b0dc309..600f031 100644
--- a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseDxe/Ps2Mouse.c
+++ b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseDxe/Ps2Mouse.c
@@ -716,8 +716,8 @@
 }

 

 /**

-  Event notification function for TimerEvent event

-  If mouse device is connected to system, try to get the mouse packet data

+  Event notification function for TimerEvent event.

+  If mouse device is connected to system, try to get the mouse packet data.

 

   @param Event      -  TimerEvent in PS2_MOUSE_DEV

   @param Context    -  Pointer to PS2_MOUSE_DEV structure

diff --git a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseDxe/Ps2Mouse.h b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseDxe/Ps2Mouse.h
index ae6720a..aadfd6a 100644
--- a/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseDxe/Ps2Mouse.h
+++ b/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseDxe/Ps2Mouse.h
@@ -354,8 +354,8 @@
   );

 

 /**

-  Event notification function for TimerEvent event

-  If mouse device is connected to system, try to get the mouse packet data

+  Event notification function for TimerEvent event.

+  If mouse device is connected to system, try to get the mouse packet data.

 

   @param Event      -  TimerEvent in PS2_MOUSE_DEV

   @param Context    -  Pointer to PS2_MOUSE_DEV structure