VirtualBox

Ignore:
Timestamp:
Oct 29, 2015 4:30:44 AM (9 years ago)
Author:
vboxsync
Message:

EFI/Firmware: Merged in the svn:eol-style, svn:mime-type and trailing whitespace cleanup that was done after the initial UDK2014.SP1 import: svn merge /vendor/edk2/UDK2014.SP1 /vendor/edk2/current .

Location:
trunk/src/VBox/Devices/EFI/Firmware
Files:
202 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/VBox/Devices/EFI/Firmware

  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/InternalIsaBus.h

    r48674 r58466  
    11/** @file
    22  The header file for ISA bus driver
    3  
     3
    44Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
    55This program and the accompanying materials
     
    158158//
    159159
    160 /** 
    161   Tests to see if a controller can be managed by the ISA Bus Driver. If a child device is provided, 
     160/**
     161  Tests to see if a controller can be managed by the ISA Bus Driver. If a child device is provided,
    162162  it further tests to see if this driver supports creating a handle for the specified child device.
    163163
     
    165165  How the Start() function of a driver is implemented can affect how the Supported() function is implemented.
    166166
    167   @param[in] This                 A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance. 
     167  @param[in] This                 A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    168168  @param[in] Controller           The handle of the controller to test.
    169169  @param[in] RemainingDevicePath  A pointer to the remaining portion of a device path.
    170  
     170
    171171  @retval EFI_SUCCESS             The device is supported by this driver.
    172172  @retval EFI_ALREADY_STARTED     The device is already being managed by this driver.
    173   @retval EFI_ACCESS_DENIED       The device is already being managed by a different driver 
     173  @retval EFI_ACCESS_DENIED       The device is already being managed by a different driver
    174174                                  or an application that requires exclusive access.
    175175  @retval EFI_UNSUPPORTED         The device is is not supported by this driver.
     
    185185
    186186/**
    187   Start this driver on ControllerHandle. 
    188  
     187  Start this driver on ControllerHandle.
     188
    189189  Note that the ISA Bus driver always creates all of its child handles on the first call to Start().
    190   The Start() function is designed to be invoked from the EFI boot service ConnectController(). 
    191   As a result, much of the error checking on the parameters to Start() has been moved into this 
    192   common boot service. It is legal to call Start() from other locations, but the following calling 
     190  The Start() function is designed to be invoked from the EFI boot service ConnectController().
     191  As a result, much of the error checking on the parameters to Start() has been moved into this
     192  common boot service. It is legal to call Start() from other locations, but the following calling
    193193  restrictions must be followed or the system behavior will not be deterministic.
    194194  1. ControllerHandle must be a valid EFI_HANDLE.
     
    196196     EFI_DEVICE_PATH_PROTOCOL.
    197197  3. Prior to calling Start(), the Supported() function for the driver specified by This must
    198      have been called with the same calling parameters, and Supported() must have returned EFI_SUCCESS. 
     198     have been called with the same calling parameters, and Supported() must have returned EFI_SUCCESS.
    199199
    200200  @param[in]  This                 A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    201   @param[in]  ControllerHandle     The handle of the controller to start. This handle 
    202                                    must support a protocol interface that supplies 
     201  @param[in]  ControllerHandle     The handle of the controller to start. This handle
     202                                   must support a protocol interface that supplies
    203203                                   an I/O abstraction to the driver.
    204   @param[in]  RemainingDevicePath  A pointer to the remaining portion of a device path. 
     204  @param[in]  RemainingDevicePath  A pointer to the remaining portion of a device path.
    205205                                   This parameter is ignored by device drivers, and is optional for bus drivers.
    206206
     
    220220
    221221/**
    222   Stop this driver on ControllerHandle. 
    223  
    224   The Stop() function is designed to be invoked from the EFI boot service DisconnectController(). 
    225   As a result, much of the error checking on the parameters to Stop() has been moved 
    226   into this common boot service. It is legal to call Stop() from other locations, 
     222  Stop this driver on ControllerHandle.
     223
     224  The Stop() function is designed to be invoked from the EFI boot service DisconnectController().
     225  As a result, much of the error checking on the parameters to Stop() has been moved
     226  into this common boot service. It is legal to call Stop() from other locations,
    227227  but the following calling restrictions must be followed or the system behavior will not be deterministic.
    228228  1. ControllerHandle must be a valid EFI_HANDLE that was used on a previous call to this
     
    232232     Start() function, and the Start() function must have called OpenProtocol() on
    233233     ControllerHandle with an Attribute of EFI_OPEN_PROTOCOL_BY_CHILD_CONTROLLER.
    234  
     234
    235235  @param[in]  This              A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    236   @param[in]  ControllerHandle  A handle to the device being stopped. The handle must 
    237                                 support a bus specific I/O protocol for the driver 
     236  @param[in]  ControllerHandle  A handle to the device being stopped. The handle must
     237                                support a bus specific I/O protocol for the driver
    238238                                to use to stop the device.
    239239  @param[in]  NumberOfChildren  The number of child device handles in ChildHandleBuffer.
    240   @param[in]  ChildHandleBuffer An array of child handles to be freed. May be NULL 
     240  @param[in]  ChildHandleBuffer An array of child handles to be freed. May be NULL
    241241                                if NumberOfChildren is 0.
    242242
     
    258258
    259259/**
    260   Create EFI Handle for a ISA device found via ISA ACPI Protocol 
     260  Create EFI Handle for a ISA device found via ISA ACPI Protocol
    261261
    262262  @param[in] This                   The EFI_DRIVER_BINDING_PROTOCOL instance.
    263263  @param[in] Controller             The handle of ISA bus controller(PCI to ISA bridge)
    264   @param[in] PciIo                  The Pointer to the PCI protocol 
     264  @param[in] PciIo                  The Pointer to the PCI protocol
    265265  @param[in] ParentDevicePath       Device path of the ISA bus controller
    266266  @param[in] IsaDeviceResourceList  The resource list of the ISA device
     
    286286  @param[in] IsaIoDevice            The iso device to be initialized.
    287287  @param[in] IsaDeviceResourceList  The resource list.
    288  
     288
    289289**/
    290290VOID
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/InternalIsaIo.h

    r48674 r58466  
    11/** @file
    22  The header file for EFI_ISA_IO protocol implementation.
    3  
     3
    44Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
    55This program and the accompanying materials
     
    3535  @param[in] Type                The Access type. The input must be either IsaAccessTypeMem or IsaAccessTypeIo.
    3636  @param[in] Width               The width of the memory operation.
    37   @param[in] Count               The number of memory operations to perform. 
    38   @param[in] Offset              The offset in ISA memory space to start the memory operation. 
    39  
     37  @param[in] Count               The number of memory operations to perform.
     38  @param[in] Offset              The offset in ISA memory space to start the memory operation.
     39
    4040  @retval EFI_SUCCESS            Verify success.
    4141  @retval EFI_INVALID_PARAMETER  One of the parameters has an invalid value.
     
    5050  IN UINT32                     Offset
    5151  );
    52  
     52
    5353/**
    5454  Performs an ISA I/O Read Cycle
     
    5656  @param[in]  This              A pointer to the EFI_ISA_IO_PROTOCOL instance.
    5757  @param[in]  Width             Specifies the width of the I/O operation.
    58   @param[in]  Offset            The offset in ISA I/O space to start the I/O operation. 
    59   @param[in]  Count             The number of I/O operations to perform. 
     58  @param[in]  Offset            The offset in ISA I/O space to start the I/O operation.
     59  @param[in]  Count             The number of I/O operations to perform.
    6060  @param[out] Buffer            The destination buffer to store the results
    6161
     
    8080  @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance.
    8181  @param[in] Width               Specifies the width of the I/O operation.
    82   @param[in] Offset              The offset in ISA I/O space to start the I/O operation. 
    83   @param[in] Count               The number of I/O operations to perform. 
     82  @param[in] Offset              The offset in ISA I/O space to start the I/O operation.
     83  @param[in] Count               The number of I/O operations to perform.
    8484  @param[in] Buffer              The source buffer to write data from
    8585
     
    103103
    104104  @param This                    A pointer to the EFI_ISA_IO_PROTOCOL instance.
    105   @param Operation               Indicates the type of DMA (slave or bus master), and if 
    106                                  the DMA operation is going to read or write to system memory. 
    107   @param ChannelNumber           The slave channel number to use for this DMA operation. 
    108                                  If Operation and ChannelAttributes shows that this device 
    109                                  performs bus mastering DMA, then this field is ignored. 
    110                                  The legal range for this field is 0..7. 
     105  @param Operation               Indicates the type of DMA (slave or bus master), and if
     106                                 the DMA operation is going to read or write to system memory.
     107  @param ChannelNumber           The slave channel number to use for this DMA operation.
     108                                 If Operation and ChannelAttributes shows that this device
     109                                 performs bus mastering DMA, then this field is ignored.
     110                                 The legal range for this field is 0..7.
    111111  @param ChannelAttributes       The attributes of the DMA channel to use for this DMA operation
    112   @param HostAddress             The system memory address to map to the device. 
    113   @param NumberOfBytes           On input the number of bytes to map.  On output the number 
     112  @param HostAddress             The system memory address to map to the device.
     113  @param NumberOfBytes           On input the number of bytes to map.  On output the number
    114114                                 of bytes that were mapped.
    115   @param DeviceAddress           The resulting map address for the bus master device to use 
    116                                  to access the hosts HostAddress. 
     115  @param DeviceAddress           The resulting map address for the bus master device to use
     116                                 to access the hosts HostAddress.
    117117  @param Mapping                 A resulting value to pass to EFI_ISA_IO.Unmap().
    118118
     
    174174  @param[in] CountOffset         The count's offset.
    175175  @param[in] BaseAddress         The base address.
    176   @param[in] Count               The number of I/O operations to perform. 
    177  
     176  @param[in] Count               The number of I/O operations to perform.
     177
    178178  @retval EFI_SUCCESS            Success.
    179179  @retval EFI_INVALID_PARAMETER  Parameter is invalid.
     
    195195
    196196  @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance.
    197   @param[in] Offset              The offset in ISA IO space to start the IO operation. 
     197  @param[in] Offset              The offset in ISA IO space to start the IO operation.
    198198  @param[in] Value               The data to write port.
    199199
     
    208208  IN UINT32               Offset,
    209209  IN UINT8                Value
    210   );   
     210  );
    211211
    212212/**
     
    215215  @param[in]  This               A pointer to the EFI_ISA_IO_PROTOCOL instance.
    216216  @param[in]  Width              Specifies the width of the memory operation.
    217   @param[in]  Offset             The offset in ISA memory space to start the memory operation. 
    218   @param[in]  Count              The number of memory operations to perform. 
     217  @param[in]  Offset             The offset in ISA memory space to start the memory operation.
     218  @param[in]  Count              The number of memory operations to perform.
    219219  @param[out] Buffer             The destination buffer to store the results
    220  
     220
    221221  @retval EFI_SUCCESS            The data was read from the device successfully.
    222222  @retval EFI_UNSUPPORTED        The Offset is not valid for this device.
     
    238238  Performs an ISA Memory Write Cycle
    239239
    240   @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance. 
     240  @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance.
    241241  @param[in] Width               Specifies the width of the memory operation.
    242   @param[in] Offset              The offset in ISA memory space to start the memory operation. 
    243   @param[in] Count               The number of memory operations to perform. 
     242  @param[in] Offset              The offset in ISA memory space to start the memory operation.
     243  @param[in] Count               The number of memory operations to perform.
    244244  @param[in] Buffer              The source buffer to write data from
    245245
     
    264264  @param[in]  This               A pointer to the EFI_ISA_IO_PROTOCOL instance.
    265265  @param[in]  Width              Specifies the width of the memory copy operation.
    266   @param[in]  DestOffset         The offset of the destination 
     266  @param[in]  DestOffset         The offset of the destination
    267267  @param[in]  SrcOffset          The offset of the source
    268268  @param[in]  Count              The number of memory copy  operations to perform
     
    295295  @retval EFI_SUCCESS            The requested memory pages were allocated.
    296296  @retval EFI_INVALID_PARAMETER  Type is invalid or MemoryType is invalid or HostAddress is NULL
    297   @retval EFI_UNSUPPORTED        Attributes is unsupported or the memory range specified 
     297  @retval EFI_UNSUPPORTED        Attributes is unsupported or the memory range specified
    298298                                 by HostAddress, Pages, and Type is not available for common buffer use.
    299299  @retval EFI_OUT_OF_RESOURCES   The memory pages could not be allocated.
     
    311311
    312312/**
    313   Frees memory that was allocated with EFI_ISA_IO.AllocateBuffer(). 
     313  Frees memory that was allocated with EFI_ISA_IO.AllocateBuffer().
    314314
    315315  @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/IsaBus.c

    r58459 r58466  
    22  ISA Bus UEFI driver.
    33
    4   Discovers all the ISA Controllers and their resources by using the ISA ACPI 
    5   Protocol, produces an instance of the ISA I/O Protocol for every ISA 
     4  Discovers all the ISA Controllers and their resources by using the ISA ACPI
     5  Protocol, produces an instance of the ISA I/O Protocol for every ISA
    66  Controller found. This driver is designed to manage a PCI-to-ISA bridge Device
    77  such as LPC bridge.
    8  
     8
    99Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
    1010This program and the accompanying materials
     
    3535  The main entry point for the ISA Bus driver.
    3636
    37   @param[in] ImageHandle        The firmware allocated handle for the EFI image. 
     37  @param[in] ImageHandle        The firmware allocated handle for the EFI image.
    3838  @param[in] SystemTable        A pointer to the EFI System Table.
    39  
     39
    4040  @retval EFI_SUCCESS           The entry point is executed successfully.
    4141  @retval EFI_OUT_OF_RESOURCES  There was not enough memory in pool to install all the protocols.
     
    6666}
    6767
    68 /** 
    69   Tests to see if a controller can be managed by the ISA Bus Driver. If a child device is provided, 
     68/**
     69  Tests to see if a controller can be managed by the ISA Bus Driver. If a child device is provided,
    7070  it further tests to see if this driver supports creating a handle for the specified child device.
    7171
     
    7373  How the Start() function of a driver is implemented can affect how the Supported() function is implemented.
    7474
    75   @param[in] This                 A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance. 
     75  @param[in] This                 A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    7676  @param[in] Controller           The handle of the controller to test.
    7777  @param[in] RemainingDevicePath  A pointer to the remaining portion of a device path.
    78  
     78
    7979  @retval EFI_SUCCESS             The device is supported by this driver.
    8080  @retval EFI_ALREADY_STARTED     The device is already being managed by this driver.
    81   @retval EFI_ACCESS_DENIED       The device is already being managed by a different driver 
     81  @retval EFI_ACCESS_DENIED       The device is already being managed by a different driver
    8282                                  or an application that requires exclusive access.
    8383  @retval EFI_UNSUPPORTED         The device is is not supported by this driver.
     
    9898  //
    9999  // If RemainingDevicePath is not NULL, it should verify that the first device
    100   // path node in RemainingDevicePath is an ACPI Device path node which is a 
     100  // path node in RemainingDevicePath is an ACPI Device path node which is a
    101101  // legal Device Path Node for this bus driver's children.
    102102  //
     
    193193
    194194/**
    195   Start this driver on ControllerHandle. 
    196  
     195  Start this driver on ControllerHandle.
     196
    197197  Note that the ISA Bus driver always creates all of its child handles on the first call to Start().
    198   The Start() function is designed to be invoked from the EFI boot service ConnectController(). 
    199   As a result, much of the error checking on the parameters to Start() has been moved into this 
    200   common boot service. It is legal to call Start() from other locations, but the following calling 
     198  The Start() function is designed to be invoked from the EFI boot service ConnectController().
     199  As a result, much of the error checking on the parameters to Start() has been moved into this
     200  common boot service. It is legal to call Start() from other locations, but the following calling
    201201  restrictions must be followed or the system behavior will not be deterministic.
    202202  1. ControllerHandle must be a valid EFI_HANDLE.
     
    204204     EFI_DEVICE_PATH_PROTOCOL.
    205205  3. Prior to calling Start(), the Supported() function for the driver specified by This must
    206      have been called with the same calling parameters, and Supported() must have returned EFI_SUCCESS. 
     206     have been called with the same calling parameters, and Supported() must have returned EFI_SUCCESS.
    207207
    208208  @param[in]  This                 A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    209   @param[in]  ControllerHandle     The handle of the controller to start. This handle 
    210                                    must support a protocol interface that supplies 
     209  @param[in]  ControllerHandle     The handle of the controller to start. This handle
     210                                   must support a protocol interface that supplies
    211211                                   an I/O abstraction to the driver.
    212   @param[in]  RemainingDevicePath  A pointer to the remaining portion of a device path. 
     212  @param[in]  RemainingDevicePath  A pointer to the remaining portion of a device path.
    213213                                   This parameter is ignored by device drivers, and is optional for bus drivers.
    214214
     
    414414
    415415/**
    416   Stop this driver on ControllerHandle. 
    417  
    418   The Stop() function is designed to be invoked from the EFI boot service DisconnectController(). 
    419   As a result, much of the error checking on the parameters to Stop() has been moved 
    420   into this common boot service. It is legal to call Stop() from other locations, 
     416  Stop this driver on ControllerHandle.
     417
     418  The Stop() function is designed to be invoked from the EFI boot service DisconnectController().
     419  As a result, much of the error checking on the parameters to Stop() has been moved
     420  into this common boot service. It is legal to call Stop() from other locations,
    421421  but the following calling restrictions must be followed or the system behavior will not be deterministic.
    422422  1. ControllerHandle must be a valid EFI_HANDLE that was used on a previous call to this
     
    426426     Start() function, and the Start() function must have called OpenProtocol() on
    427427     ControllerHandle with an Attribute of EFI_OPEN_PROTOCOL_BY_CHILD_CONTROLLER.
    428  
     428
    429429  @param[in]  This              A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    430   @param[in]  ControllerHandle  A handle to the device being stopped. The handle must 
    431                                 support a bus specific I/O protocol for the driver 
     430  @param[in]  ControllerHandle  A handle to the device being stopped. The handle must
     431                                support a bus specific I/O protocol for the driver
    432432                                to use to stop the device.
    433433  @param[in]  NumberOfChildren  The number of child device handles in ChildHandleBuffer.
    434   @param[in]  ChildHandleBuffer An array of child handles to be freed. May be NULL 
     434  @param[in]  ChildHandleBuffer An array of child handles to be freed. May be NULL
    435435                                if NumberOfChildren is 0.
    436436
     
    539539               ChildHandleBuffer[Index],
    540540               EFI_OPEN_PROTOCOL_BY_CHILD_CONTROLLER
    541                );     
     541               );
    542542      }
    543543    }
     
    560560
    561561/**
    562   Create EFI Handle for a ISA device found via ISA ACPI Protocol 
     562  Create EFI Handle for a ISA device found via ISA ACPI Protocol
    563563
    564564  @param[in] This                   The EFI_DRIVER_BINDING_PROTOCOL instance.
    565565  @param[in] Controller             The handle of ISA bus controller(PCI to ISA bridge)
    566   @param[in] PciIo                  The Pointer to the PCI protocol 
     566  @param[in] PciIo                  The Pointer to the PCI protocol
    567567  @param[in] ParentDevicePath       Device path of the ISA bus controller
    568568  @param[in] IsaDeviceResourceList  The resource list of the ISA device
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaBusDxe/IsaIo.c

    r58459 r58466  
    11/** @file
    2   The implementation for EFI_ISA_IO_PROTOCOL. 
    3  
     2  The implementation for EFI_ISA_IO_PROTOCOL.
     3
    44Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
    55This program and the accompanying materials
     
    1919//
    2020EFI_ISA_IO_PROTOCOL mIsaIoInterface = {
    21   {   
     21  {
    2222    IsaIoMemRead,
    2323    IsaIoMemWrite
    2424  },
    25   {   
     25  {
    2626    IsaIoIoRead,
    2727    IsaIoIoWrite
     
    8686  @param[in] IsaIoDevice            The iso device to be initialized.
    8787  @param[in] IsaDeviceResourceList  The resource list.
    88  
     88
    8989**/
    9090VOID
     
    111111  @param[in]  This              A pointer to the EFI_ISA_IO_PROTOCOL instance.
    112112  @param[in]  Width             Specifies the width of the I/O operation.
    113   @param[in]  Offset            The offset in ISA I/O space to start the I/O operation. 
    114   @param[in]  Count             The number of I/O operations to perform. 
     113  @param[in]  Offset            The offset in ISA I/O space to start the I/O operation.
     114  @param[in]  Count             The number of I/O operations to perform.
    115115  @param[out] Buffer            The destination buffer to store the results
    116116
     
    173173  @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance.
    174174  @param[in] Width               Specifies the width of the I/O operation.
    175   @param[in] Offset              The offset in ISA I/O space to start the I/O operation. 
    176   @param[in] Count               The number of I/O operations to perform. 
     175  @param[in] Offset              The offset in ISA I/O space to start the I/O operation.
     176  @param[in] Count               The number of I/O operations to perform.
    177177  @param[in] Buffer              The source buffer to write data from
    178178
     
    234234
    235235  @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance.
    236   @param[in] Offset              The offset in ISA IO space to start the IO operation. 
     236  @param[in] Offset              The offset in ISA IO space to start the IO operation.
    237237  @param[in] Value               The data to write port.
    238238
     
    283283  @param[in] CountOffset         The count's offset.
    284284  @param[in] BaseAddress         The base address.
    285   @param[in] Count               The number of I/O operations to perform. 
    286  
     285  @param[in] Count               The number of I/O operations to perform.
     286
    287287  @retval EFI_SUCCESS            Success.
    288288  @retval EFI_INVALID_PARAMETER  Parameter is invalid.
     
    421421  @param[in] Type                The Access type. The input must be either IsaAccessTypeMem or IsaAccessTypeIo.
    422422  @param[in] Width               The width of the memory operation.
    423   @param[in] Count               The number of memory operations to perform. 
    424   @param[in] Offset              The offset in ISA memory space to start the memory operation. 
    425  
     423  @param[in] Count               The number of memory operations to perform.
     424  @param[in] Offset              The offset in ISA memory space to start the memory operation.
     425
    426426  @retval EFI_SUCCESS            Verify success.
    427427  @retval EFI_INVALID_PARAMETER  One of the parameters has an invalid value.
     
    483483  @param[in]  This               A pointer to the EFI_ISA_IO_PROTOCOL instance.
    484484  @param[in]  Width              Specifies the width of the memory operation.
    485   @param[in]  Offset             The offset in ISA memory space to start the memory operation. 
    486   @param[in]  Count              The number of memory operations to perform. 
     485  @param[in]  Offset             The offset in ISA memory space to start the memory operation.
     486  @param[in]  Count              The number of memory operations to perform.
    487487  @param[out] Buffer             The destination buffer to store the results
    488  
     488
    489489  @retval EFI_SUCCESS            The data was read from the device successfully.
    490490  @retval EFI_UNSUPPORTED        The Offset is not valid for this device.
     
    550550  Performs an ISA Memory Write Cycle
    551551
    552   @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance. 
     552  @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance.
    553553  @param[in] Width               Specifies the width of the memory operation.
    554   @param[in] Offset              The offset in ISA memory space to start the memory operation. 
    555   @param[in] Count               The number of memory operations to perform. 
     554  @param[in] Offset              The offset in ISA memory space to start the memory operation.
     555  @param[in] Count               The number of memory operations to perform.
    556556  @param[in] Buffer              The source buffer to write data from
    557557
     
    621621  @param[in]  This               A pointer to the EFI_ISA_IO_PROTOCOL instance.
    622622  @param[in]  Width              Specifies the width of the memory copy operation.
    623   @param[in]  DestOffset         The offset of the destination 
     623  @param[in]  DestOffset         The offset of the destination
    624624  @param[in]  SrcOffset          The offset of the source
    625625  @param[in]  Count              The number of memory copy  operations to perform
     
    702702
    703703  @param This                    A pointer to the EFI_ISA_IO_PROTOCOL instance.
    704   @param Operation               Indicates the type of DMA (slave or bus master), and if 
    705                                  the DMA operation is going to read or write to system memory. 
    706   @param ChannelNumber           The slave channel number to use for this DMA operation. 
    707                                  If Operation and ChannelAttributes shows that this device 
    708                                  performs bus mastering DMA, then this field is ignored. 
    709                                  The legal range for this field is 0..7. 
     704  @param Operation               Indicates the type of DMA (slave or bus master), and if
     705                                 the DMA operation is going to read or write to system memory.
     706  @param ChannelNumber           The slave channel number to use for this DMA operation.
     707                                 If Operation and ChannelAttributes shows that this device
     708                                 performs bus mastering DMA, then this field is ignored.
     709                                 The legal range for this field is 0..7.
    710710  @param ChannelAttributes       The attributes of the DMA channel to use for this DMA operation
    711   @param HostAddress             The system memory address to map to the device. 
    712   @param NumberOfBytes           On input the number of bytes to map.  On output the number 
     711  @param HostAddress             The system memory address to map to the device.
     712  @param NumberOfBytes           On input the number of bytes to map.  On output the number
    713713                                 of bytes that were mapped.
    714   @param DeviceAddress           The resulting map address for the bus master device to use 
    715                                  to access the hosts HostAddress. 
     714  @param DeviceAddress           The resulting map address for the bus master device to use
     715                                 to access the hosts HostAddress.
    716716  @param Mapping                 A resulting value to pass to EFI_ISA_IO.Unmap().
    717717
     
    744744  UINT8                 DmaClear;
    745745  UINT8                 DmaChannelMode;
    746  
     746
    747747  if ((NULL == This) ||
    748748      (NULL == HostAddress) ||
     
    763763  // Light IsaIo only supports two operations.
    764764  //
    765   if (!(Operation == EfiIsaIoOperationSlaveRead || 
     765  if (!(Operation == EfiIsaIoOperationSlaveRead ||
    766766        Operation == EfiIsaIoOperationSlaveWrite)) {
    767767    return EFI_INVALID_PARAMETER;
     
    849849    *DeviceAddress = PhysicalAddress;
    850850  }
    851  
     851
    852852  //
    853853  // Figure out what to program into the DMA Channel Mode Register
     
    934934
    935935/**
    936   Maps a memory region for DMA. This implementation implement the 
     936  Maps a memory region for DMA. This implementation implement the
    937937  the full mapping support.
    938938
    939939  @param This                    A pointer to the EFI_ISA_IO_PROTOCOL instance.
    940   @param Operation               Indicates the type of DMA (slave or bus master), and if 
    941                                  the DMA operation is going to read or write to system memory. 
    942   @param ChannelNumber           The slave channel number to use for this DMA operation. 
    943                                  If Operation and ChannelAttributes shows that this device 
    944                                  performs bus mastering DMA, then this field is ignored. 
    945                                  The legal range for this field is 0..7. 
     940  @param Operation               Indicates the type of DMA (slave or bus master), and if
     941                                 the DMA operation is going to read or write to system memory.
     942  @param ChannelNumber           The slave channel number to use for this DMA operation.
     943                                 If Operation and ChannelAttributes shows that this device
     944                                 performs bus mastering DMA, then this field is ignored.
     945                                 The legal range for this field is 0..7.
    946946  @param ChannelAttributes       The attributes of the DMA channel to use for this DMA operation
    947   @param HostAddress             The system memory address to map to the device. 
    948   @param NumberOfBytes           On input the number of bytes to map.  On output the number 
     947  @param HostAddress             The system memory address to map to the device.
     948  @param NumberOfBytes           On input the number of bytes to map.  On output the number
    949949                                 of bytes that were mapped.
    950   @param DeviceAddress           The resulting map address for the bus master device to use 
    951                                  to access the hosts HostAddress. 
     950  @param DeviceAddress           The resulting map address for the bus master device to use
     951                                 to access the hosts HostAddress.
    952952  @param Mapping                 A resulting value to pass to EFI_ISA_IO.Unmap().
    953953
     
    12631263
    12641264  @param This                    A pointer to the EFI_ISA_IO_PROTOCOL instance.
    1265   @param Operation               Indicates the type of DMA (slave or bus master), and if 
    1266                                  the DMA operation is going to read or write to system memory. 
    1267   @param ChannelNumber           The slave channel number to use for this DMA operation. 
    1268                                  If Operation and ChannelAttributes shows that this device 
    1269                                  performs bus mastering DMA, then this field is ignored. 
    1270                                  The legal range for this field is 0..7. 
     1265  @param Operation               Indicates the type of DMA (slave or bus master), and if
     1266                                 the DMA operation is going to read or write to system memory.
     1267  @param ChannelNumber           The slave channel number to use for this DMA operation.
     1268                                 If Operation and ChannelAttributes shows that this device
     1269                                 performs bus mastering DMA, then this field is ignored.
     1270                                 The legal range for this field is 0..7.
    12711271  @param ChannelAttributes       The attributes of the DMA channel to use for this DMA operation
    1272   @param HostAddress             The system memory address to map to the device. 
    1273   @param NumberOfBytes           On input the number of bytes to map.  On output the number 
     1272  @param HostAddress             The system memory address to map to the device.
     1273  @param NumberOfBytes           On input the number of bytes to map.  On output the number
    12741274                                 of bytes that were mapped.
    1275   @param DeviceAddress           The resulting map address for the bus master device to use 
    1276                                  to access the hosts HostAddress. 
     1275  @param DeviceAddress           The resulting map address for the bus master device to use
     1276                                 to access the hosts HostAddress.
    12771277  @param Mapping                 A resulting value to pass to EFI_ISA_IO.Unmap().
    12781278
     
    13031303  }
    13041304  //
    1305   // Set Feature Flag PcdIsaBusSupportBusMaster to FALSE to disable support for 
     1305  // Set Feature Flag PcdIsaBusSupportBusMaster to FALSE to disable support for
    13061306  // ISA Bus Master.
    13071307  //
     
    13461346  @retval EFI_SUCCESS            The requested memory pages were allocated.
    13471347  @retval EFI_INVALID_PARAMETER  Type is invalid or MemoryType is invalid or HostAddress is NULL
    1348   @retval EFI_UNSUPPORTED        Attributes is unsupported or the memory range specified 
     1348  @retval EFI_UNSUPPORTED        Attributes is unsupported or the memory range specified
    13491349                                 by HostAddress, Pages, and Type is not available for common buffer use.
    13501350  @retval EFI_OUT_OF_RESOURCES   The memory pages could not be allocated.
     
    13651365
    13661366  //
    1367   // Set Feature Flag PcdIsaBusOnlySupportSlaveDma to FALSE to disable support for 
     1367  // Set Feature Flag PcdIsaBusOnlySupportSlaveDma to FALSE to disable support for
    13681368  // ISA Bus Master.
    13691369  // Or unset Feature Flag PcdIsaBusSupportDma to disable support for ISA DMA.
     
    14191419
    14201420/**
    1421   Frees memory that was allocated with EFI_ISA_IO.AllocateBuffer(). 
     1421  Frees memory that was allocated with EFI_ISA_IO.AllocateBuffer().
    14221422
    14231423  @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance.
     
    14391439
    14401440  //
    1441   // Set Feature Flag PcdIsaBusOnlySupportSlaveDma to FALSE to disable support for 
     1441  // Set Feature Flag PcdIsaBusOnlySupportSlaveDma to FALSE to disable support for
    14421442  // ISA Bus Master.
    14431443  // Or unset Feature Flag PcdIsaBusSupportDma to disable support for ISA DMA.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaFloppyDxe/IsaFloppy.c

    r48674 r58466  
    22  ISA Floppy Disk UEFI Driver conforming to the UEFI driver model
    33
    4   1. Support two types diskette drive 
     4  1. Support two types diskette drive
    55     1.44M drive and 2.88M drive (and now only support 1.44M)
    66  2. Support two diskette drives per floppy disk controller
     
    88  4. Do not use interrupt
    99  5. Support diskette change line signal and write protect
    10  
     10
    1111Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
    1212This program and the accompanying materials
     
    4040  The main Entry Point for this driver.
    4141
    42   @param[in] ImageHandle  The firmware allocated handle for the EFI image. 
     42  @param[in] ImageHandle  The firmware allocated handle for the EFI image.
    4343  @param[in] SystemTable  A pointer to the EFI System Table.
    44  
     44
    4545  @retval EFI_SUCCESS     The entry point is executed successfully.
    4646  @retval other           Some error occurs when executing this entry point.
     
    7373/**
    7474  Test if the controller is a floppy disk drive device
    75  
    76   @param[in] This                 A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance. 
     75
     76  @param[in] This                 A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    7777  @param[in] Controller           The handle of the controller to test.
    7878  @param[in] RemainingDevicePath  A pointer to the remaining portion of a device path.
    79  
     79
    8080  @retval EFI_SUCCESS             The device is supported by this driver.
    8181  @retval EFI_ALREADY_STARTED     The device is already being managed by this driver.
    82   @retval EFI_ACCESS_DENIED       The device is already being managed by a different driver 
     82  @retval EFI_ACCESS_DENIED       The device is already being managed by a different driver
    8383                                  or an application that requires exclusive access.
    8484  @retval EFI_UNSUPPORTED         The device is is not supported by this driver.
     
    160160
    161161  @param[in] This                  A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    162   @param[in] ControllerHandle      The handle of the controller to start. This handle 
    163                                    must support a protocol interface that supplies 
     162  @param[in] ControllerHandle      The handle of the controller to start. This handle
     163                                   must support a protocol interface that supplies
    164164                                   an I/O abstraction to the driver.
    165   @param[in] RemainingDevicePath   A pointer to the remaining portion of a device path. 
     165  @param[in] RemainingDevicePath   A pointer to the remaining portion of a device path.
    166166                                   This parameter is ignored by device drivers, and is optional for bus drivers.
    167167
     
    249249  FdcDev->ControllerNameTable = NULL;
    250250  AddName (FdcDev);
    251  
     251
    252252  //
    253253  // Look up the base address of the Floppy Disk Controller which controls this floppy device
     
    398398
    399399  @param[in] This               A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    400   @param[in] ControllerHandle   A handle to the device being stopped. The handle must 
    401                                 support a bus specific I/O protocol for the driver 
     400  @param[in] ControllerHandle   A handle to the device being stopped. The handle must
     401                                support a bus specific I/O protocol for the driver
    402402                                to use to stop the device.
    403403  @param[in] NumberOfChildren   The number of child device handles in ChildHandleBuffer.
    404   @param[in] ChildHandleBuffer  An array of child handles to be freed. May be NULL 
     404  @param[in] ChildHandleBuffer  An array of child handles to be freed. May be NULL
    405405                                if NumberOfChildren is 0.
    406406
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaFloppyDxe/IsaFloppy.h

    r58459 r58466  
    11/** @file
    22  Include file for ISA Floppy Driver
    3  
     3
    44Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
    55This program and the accompanying materials
     
    483483/**
    484484  Test controller is a floppy disk drive device
    485  
    486   @param[in] This                 A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance. 
     485
     486  @param[in] This                 A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    487487  @param[in] Controller           The handle of the controller to test.
    488488  @param[in] RemainingDevicePath  A pointer to the remaining portion of a device path.
    489  
     489
    490490  @retval EFI_SUCCESS             The device is supported by this driver.
    491491  @retval EFI_ALREADY_STARTED     The device is already being managed by this driver.
    492   @retval EFI_ACCESS_DENIED       The device is already being managed by a different driver 
     492  @retval EFI_ACCESS_DENIED       The device is already being managed by a different driver
    493493                                  or an application that requires exclusive access.
    494494**/
     
    505505
    506506  @param[in]  This                 A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    507   @param[in]  ControllerHandle     The handle of the controller to start. This handle 
    508                                    must support a protocol interface that supplies 
     507  @param[in]  ControllerHandle     The handle of the controller to start. This handle
     508                                   must support a protocol interface that supplies
    509509                                   an I/O abstraction to the driver.
    510   @param[in]  RemainingDevicePath  A pointer to the remaining portion of a device path. 
     510  @param[in]  RemainingDevicePath  A pointer to the remaining portion of a device path.
    511511                                   This parameter is ignored by device drivers, and is optional for bus drivers.
    512512
     
    529529
    530530  @param[in]  This              A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    531   @param[in]  ControllerHandle  A handle to the device being stopped. The handle must 
    532                                 support a bus specific I/O protocol for the driver 
     531  @param[in]  ControllerHandle  A handle to the device being stopped. The handle must
     532                                support a bus specific I/O protocol for the driver
    533533                                to use to stop the device.
    534534  @param[in]  NumberOfChildren  The number of child device handles in ChildHandleBuffer.
    535   @param[in]  ChildHandleBuffer An array of child handles to be freed. May be NULL 
     535  @param[in]  ChildHandleBuffer An array of child handles to be freed. May be NULL
    536536                                if NumberOfChildren is 0.
    537537
     
    553553
    554554/**
    555   Reset the Floppy Logic Drive, call the FddReset function.   
    556  
     555  Reset the Floppy Logic Drive, call the FddReset function.
     556
    557557  @param This EFI_BLOCK_IO *: A pointer to the Block I/O protocol interface
    558   @param ExtendedVerification BOOLEAN: Indicate that the driver may perform a more 
    559                     exhaustive verification operation of the device during 
    560                     reset, now this par is ignored in this driver         
     558  @param ExtendedVerification BOOLEAN: Indicate that the driver may perform a more
     559                    exhaustive verification operation of the device during
     560                    reset, now this par is ignored in this driver
    561561  @retval  EFI_SUCCESS:      The Floppy Logic Drive is reset
    562   @retval  EFI_DEVICE_ERROR: The Floppy Logic Drive is not functioning correctly 
     562  @retval  EFI_DEVICE_ERROR: The Floppy Logic Drive is not functioning correctly
    563563                      and can not be reset
    564564
     
    573573/**
    574574  Flush block via fdd controller.
    575  
     575
    576576  @param  This EFI_BLOCK_IO *: A pointer to the Block I/O protocol interface
    577577  @return EFI_SUCCESS
     
    585585
    586586/**
    587   Read the requested number of blocks from the device.   
    588  
     587  Read the requested number of blocks from the device.
     588
    589589  @param This EFI_BLOCK_IO *: A pointer to the Block I/O protocol interface
    590   @param MediaId UINT32:    The media id that the read request is for   
     590  @param MediaId UINT32:    The media id that the read request is for
    591591  @param  Lba EFI_LBA:     The starting logic block address to read from on the device
    592592  @param  BufferSize UINTN:  The size of the Buffer in bytes
    593593  @param  Buffer VOID *:     A pointer to the destination buffer for the data
    594  
     594
    595595  @retval  EFI_SUCCESS:     The data was read correctly from the device
    596596  @retval  EFI_DEVICE_ERROR:The device reported an error while attempting to perform
     
    598598  @retval  EFI_NO_MEDIA:    There is no media in the device
    599599  @retval  EFI_MEDIA_CHANGED:   The MediaId is not for the current media
    600   @retval  EFI_BAD_BUFFER_SIZE: The BufferSize parameter is not a multiple of the 
     600  @retval  EFI_BAD_BUFFER_SIZE: The BufferSize parameter is not a multiple of the
    601601                         intrinsic block size of the device
    602   @retval  EFI_INVALID_PARAMETER:The read request contains LBAs that are not valid, 
    603                           or the buffer is not on proper alignment 
     602  @retval  EFI_INVALID_PARAMETER:The read request contains LBAs that are not valid,
     603                          or the buffer is not on proper alignment
    604604
    605605**/
     
    615615
    616616/**
    617   Write a specified number of blocks to the device.   
    618  
     617  Write a specified number of blocks to the device.
     618
    619619  @param  This EFI_BLOCK_IO *: A pointer to the Block I/O protocol interface
    620   @param  MediaId UINT32:    The media id that the write request is for   
     620  @param  MediaId UINT32:    The media id that the write request is for
    621621  @param  Lba EFI_LBA:     The starting logic block address to be written
    622622  @param  BufferSize UINTN:  The size in bytes in Buffer
    623623  @param  Buffer VOID *:     A pointer to the source buffer for the data
    624  
     624
    625625  @retval  EFI_SUCCESS:     The data were written correctly to the device
    626   @retval  EFI_WRITE_PROTECTED: The device can not be written to 
     626  @retval  EFI_WRITE_PROTECTED: The device can not be written to
    627627  @retval  EFI_NO_MEDIA:    There is no media in the device
    628628  @retval  EFI_MEDIA_CHANGED:   The MediaId is not for the current media
    629   @retval  EFI_DEVICE_ERROR:  The device reported an error while attempting to perform 
    630                        the write operation 
    631   @retval  EFI_BAD_BUFFER_SIZE: The BufferSize parameter is not a multiple of the 
     629  @retval  EFI_DEVICE_ERROR:  The device reported an error while attempting to perform
     630                       the write operation
     631  @retval  EFI_BAD_BUFFER_SIZE: The BufferSize parameter is not a multiple of the
    632632                         intrinsic block size of the device
    633   @retval  EFI_INVALID_PARAMETER:The write request contains LBAs that are not valid, 
    634                           or the buffer is not on proper alignment 
     633  @retval  EFI_INVALID_PARAMETER:The write request contains LBAs that are not valid,
     634                          or the buffer is not on proper alignment
    635635**/
    636636EFI_STATUS
     
    650650
    651651  Detect the floppy drive is presented or not.
    652  
     652
    653653  @param  FdcDev FDC_BLK_IO_DEV * : A pointer to the Data Structure FDC_BLK_IO_DEV
    654654  @retval EFI_SUCCESS    Drive is presented
     
    665665  Do recalibrate  and see the drive is presented or not.
    666666  Set the media parameters.
    667  
     667
    668668  @param FdcDev FDC_BLK_IO_DEV * : A pointer to the Data Structure FDC_BLK_IO_DEV
    669669  @return the drive is presented or not
     
    678678
    679679  Reset the Floppy Logic Drive.
    680  
     680
    681681  @param  FdcDev FDC_BLK_IO_DEV * : A pointer to the Data Structure FDC_BLK_IO_DEV
    682  
     682
    683683  @retval EFI_SUCCESS:    The Floppy Logic Drive is reset
    684684  @retval EFI_DEVICE_ERROR: The Floppy Logic Drive is not functioning correctly and
     
    695695  Turn the drive's motor on.
    696696  The drive's motor must be on before any command can be executed.
    697  
     697
    698698  @param  FdcDev FDC_BLK_IO_DEV * : A pointer to the Data Structure FDC_BLK_IO_DEV
    699  
     699
    700700  @retval  EFI_SUCCESS:       Turn the drive's motor on successfully
    701701  @retval  EFI_DEVICE_ERROR:    The drive is busy, so can not turn motor on
     
    711711
    712712  Set a Timer and when Timer goes off, turn the motor off.
    713  
    714  
     713
     714
    715715  @param  FdcDev FDC_BLK_IO_DEV * : A pointer to the Data Structure FDC_BLK_IO_DEV
    716  
     716
    717717  @retval  EFI_SUCCESS:       Set the Timer successfully
    718718  @retval  EFI_INVALID_PARAMETER: Fail to Set the timer
     
    726726/**
    727727  Detect the disk in the drive is changed or not.
    728  
    729  
     728
     729
    730730  @param  FdcDev FDC_BLK_IO_DEV *: A pointer to Data Structure FDC_BLK_IO_DEV
    731  
     731
    732732  @retval  EFI_SUCCESS:    No disk media change
    733733  @retval  EFI_DEVICE_ERROR: Fail to do the recalibrate or seek operation
     
    744744  and the initial values for each of the three internal
    745745  times: HUT, SRT and HLT.
    746  
     746
    747747  @param FdcDev    Pointer to instance of FDC_BLK_IO_DEV
    748  
     748
    749749  @retval  EFI_SUCCESS:    Execute the Specify command successfully
    750750  @retval  EFI_DEVICE_ERROR: Fail to execute the command
     
    758758/**
    759759  Set the head of floppy drive to track 0.
    760  
     760
    761761  @param  FdcDev FDC_BLK_IO_DEV *: A pointer to Data Structure FDC_BLK_IO_DEV
    762762  @retval EFI_SUCCESS:    Execute the Recalibrate operation successfully
     
    771771/**
    772772  Set the head of floppy drive to the new cylinder.
    773  
     773
    774774  @param  FdcDev FDC_BLK_IO_DEV *: A pointer to Data Structure FDC_BLK_IO_DEV
    775775  @param  Lba EFI_LBA     : The logic block address want to seek
    776  
     776
    777777  @retval  EFI_SUCCESS:    Execute the Seek operation successfully
    778778  @retval  EFI_DEVICE_ERROR: Fail to execute the Seek operation
     
    787787/**
    788788  Do the Sense Interrupt Status command, this command resets the interrupt signal.
    789  
     789
    790790  @param  FdcDev FDC_BLK_IO_DEV *: A pointer to Data Structure FDC_BLK_IO_DEV
    791791  @param  StatusRegister0 UINT8 *: Be used to save Status Register 0 read from FDC
    792792  @param  PresentCylinderNumber  UINT8 *: Be used to save present cylinder number
    793793                                    read from FDC
    794  
     794
    795795  @retval  EFI_SUCCESS:    Execute the Sense Interrupt Status command successfully
    796796  @retval  EFI_DEVICE_ERROR: Fail to execute the command
     
    806806/**
    807807  Do the Sense Drive Status command.
    808  
     808
    809809  @param  FdcDev FDC_BLK_IO_DEV *: A pointer to Data Structure FDC_BLK_IO_DEV
    810810  @param  Lba EFI_LBA     : Logic block address
    811  
     811
    812812  @retval  EFI_SUCCESS:    Execute the Sense Drive Status command successfully
    813813  @retval  EFI_DEVICE_ERROR: Fail to execute the command
     
    823823/**
    824824  Update the disk media properties and if necessary reinstall Block I/O interface.
    825  
     825
    826826  @param  FdcDev FDC_BLK_IO_DEV *: A pointer to Data Structure FDC_BLK_IO_DEV
    827  
     827
    828828  @retval  EFI_SUCCESS:    Do the operation successfully
    829829  @retval  EFI_DEVICE_ERROR: Fail to the operation
     
    837837/**
    838838  Set the data rate and so on.
    839  
     839
    840840  @param  FdcDev FDC_BLK_IO_DEV *: A pointer to Data Structure FDC_BLK_IO_DEV
    841841
     
    849849/**
    850850  Read or Write a number of blocks in the same cylinder.
    851  
     851
    852852  @param  FdcDev      A pointer to Data Structure FDC_BLK_IO_DEV
    853   @param  HostAddress device address 
     853  @param  HostAddress device address
    854854  @param  Lba         The starting logic block address to read from on the device
    855855  @param  NumberOfBlocks The number of block wanted to be read or write
    856856  @param  Read        Operation type: read or write
    857  
     857
    858858  @retval EFI_SUCCESS Success operate
    859859
     
    870870/**
    871871  Fill in FDD command's parameter.
    872  
     872
    873873  @param FdcDev   Pointer to instance of FDC_BLK_IO_DEV
    874874  @param Lba      The starting logic block address to read from on the device
     
    885885/**
    886886  Read result byte from Data Register of FDC.
    887  
     887
    888888  @param FdcDev   Pointer to instance of FDC_BLK_IO_DEV
    889889  @param Pointer  Buffer to store the byte read from FDC
    890  
     890
    891891  @retval EFI_SUCCESS       Read result byte from FDC successfully
    892892  @retval EFI_DEVICE_ERROR  The FDC is not ready to be read
     
    901901/**
    902902  Write command byte to Data Register of FDC.
    903  
     903
    904904  @param FdcDev  Pointer to instance of FDC_BLK_IO_DEV
    905905  @param Pointer Be used to save command byte written to FDC
    906  
     906
    907907  @retval  EFI_SUCCESS:    Write command byte to FDC successfully
    908908  @retval  EFI_DEVICE_ERROR: The FDC is not ready to be written
     
    917917/**
    918918  Detect the specified floppy logic drive is busy or not within a period of time.
    919  
     919
    920920  @param FdcDev           Indicate it is drive A or drive B
    921921  @param Timeout          The time period for waiting
    922  
     922
    923923  @retval EFI_SUCCESS:  The drive and command are not busy
    924924  @retval EFI_TIMEOUT:  The drive or command is still busy after a period time that
     
    934934/**
    935935  Determine whether FDC is ready to write or read.
    936  
     936
    937937  @param  FdcDev Pointer to instance of FDC_BLK_IO_DEV
    938938  @param  Dio BOOLEAN:      Indicate the FDC is waiting to write or read
    939939  @param  Timeout           The time period for waiting
    940  
     940
    941941  @retval EFI_SUCCESS:  FDC is ready to write or read
    942942  @retval EFI_NOT_READY:  FDC is not ready within the specified time period
     
    970970/**
    971971  Check the drive status information.
    972  
     972
    973973  @param StatusRegister3  the value of Status Register 3
    974  
     974
    975975  @retval EFI_SUCCESS           The disk is not write protected
    976976  @retval EFI_WRITE_PROTECTED:  The disk is write protected
     
    984984/**
    985985  Calculate the number of block in the same cylinder according to Lba.
    986  
     986
    987987  @param FdcDev FDC_BLK_IO_DEV *: A pointer to Data Structure FDC_BLK_IO_DEV
    988988  @param Lba EFI_LBA:      The starting logic block address
    989989  @param NumberOfBlocks UINTN: The number of blocks
    990  
     990
    991991  @return The number of blocks in the same cylinder which the starting
    992992        logic block address is Lba
     
    10021002/**
    10031003  When the Timer(2s) off, turn the drive's motor off.
    1004  
     1004
    10051005  @param Event EFI_EVENT: Event(the timer) whose notification function is being
    10061006                     invoked
     
    10171017/**
    10181018  Read I/O port for FDC.
    1019  
     1019
    10201020  @param FdcDev FDC_BLK_IO_DEV *: A pointer to Data Structure FDC_BLK_IO_DEV
    10211021  @param Offset The offset address of port
     
    10301030/**
    10311031  Write I/O port for FDC.
    1032  
     1032
    10331033  @param FdcDev FDC_BLK_IO_DEV *: A pointer to Data Structure FDC_BLK_IO_DEV
    10341034  @param Offset The offset address of port
    10351035  @param Data   Value written to port
    1036  
     1036
    10371037**/
    10381038VOID
     
    10801080
    10811081/**
    1082   Common interface for free cache. 
    1083  
     1082  Common interface for free cache.
     1083
    10841084  @param FdcDev  Pointer of FDC_BLK_IO_DEV instance
    1085  
     1085
    10861086**/
    10871087VOID
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaFloppyDxe/IsaFloppyBlock.c

    r48674 r58466  
    1 /** @file 
     1/** @file
    22  Implementation of the EFI Block IO Protocol for ISA Floppy driver
    3  
     3
    44Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
    55This program and the accompanying materials
     
    7272/**
    7373  Common report status code interface.
    74  
     74
    7575  @param This  Pointer of FDC_BLK_IO_DEV instance
    7676  @param Read  Read or write operation when error occurrs
     
    108108  @retval EFI_MEDIA_CHANGED     The MediaId does not matched the current device.
    109109  @retval EFI_BAD_BUFFER_SIZE   The Buffer was not a multiple of the block size of the device.
    110   @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid, 
     110  @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid,
    111111                                or the buffer is not on proper alignment.
    112112
     
    149149  @retval EFI_MEDIA_CHNAGED     The MediaId does not matched the current device.
    150150  @retval EFI_BAD_BUFFER_SIZE   The Buffer was not a multiple of the block size of the device.
    151   @retval EFI_INVALID_PARAMETER The write request contains LBAs that are not valid, 
     151  @retval EFI_INVALID_PARAMETER The write request contains LBAs that are not valid,
    152152                                or the buffer is not on proper alignment.
    153153
     
    190190  @retval EFI_MEDIA_CHANGED     The MediaId does not matched the current device.
    191191  @retval EFI_BAD_BUFFER_SIZE   The Buffer was not a multiple of the block size of the device.
    192   @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid, 
     192  @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid,
    193193                                or the buffer is not on proper alignment.
    194194  @retval EFI_WRITE_PROTECTED   The device can not be written to.
     
    360360/**
    361361  Free cache for a floppy disk.
    362  
     362
    363363  @param FdcDev  A Pointer to FDC_BLK_IO_DEV instance
    364  
     364
    365365**/
    366366VOID
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaFloppyDxe/IsaFloppyCtrl.c

    r58459 r58466  
    11/** @file
    22  Internal floppy disk controller programming functions for the floppy driver.
    3  
     3
    44Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
    55This program and the accompanying materials
     
    1717/**
    1818  Detect whether a floppy drive is present or not.
    19  
     19
    2020  @param[in] FdcDev  A pointer to the FDC_BLK_IO_DEV
    2121
     
    5050  Do recalibrate and check if the drive is present or not
    5151  and set the media parameters if the driver is present.
    52  
     52
    5353  @param[in] FdcDev  A pointer to the FDC_BLK_IO_DEV
    5454
     
    124124/**
    125125  Reset the Floppy Logic Drive.
    126  
     126
    127127  @param  FdcDev FDC_BLK_IO_DEV * : A pointer to the FDC_BLK_IO_DEV
    128  
     128
    129129  @retval EFI_SUCCESS:    The Floppy Logic Drive is reset
    130130  @retval EFI_DEVICE_ERROR: The Floppy Logic Drive is not functioning correctly and
     
    223223  Turn the floppy disk drive's motor on.
    224224  The drive's motor must be on before any command can be executed.
    225  
     225
    226226  @param[in] FdcDev  A pointer to the FDC_BLK_IO_DEV
    227  
     227
    228228  @retval  EFI_SUCCESS            The drive's motor was turned on successfully
    229229  @retval  EFI_DEVICE_ERROR       The drive is busy, so can not turn motor on
     
    299299/**
    300300  Set a Timer and when Timer goes off, turn the motor off.
    301  
     301
    302302  @param[in] FdcDev  A pointer to the FDC_BLK_IO_DEV
    303  
     303
    304304  @retval  EFI_SUCCESS            Set the Timer successfully
    305305  @retval  EFI_INVALID_PARAMETER  Fail to Set the timer
     
    318318/**
    319319  Detect whether the disk in the drive is changed or not.
    320  
     320
    321321  @param[in] FdcDev  A pointer to FDC_BLK_IO_DEV
    322  
     322
    323323  @retval  EFI_SUCCESS        No disk media change
    324324  @retval  EFI_DEVICE_ERROR   Fail to do the recalibrate or seek operation
     
    383383  and the initial values for each of the three internal
    384384  times: HUT, SRT and HLT.
    385  
     385
    386386  @param[in] FdcDev  Pointer to instance of FDC_BLK_IO_DEV
    387  
     387
    388388  @retval EFI_SUCCESS       Execute the Specify command successfully
    389389  @retval EFI_DEVICE_ERROR  Fail to execute the command
     
    423423/**
    424424  Set the head of floppy drive to track 0.
    425  
     425
    426426  @param  FdcDev FDC_BLK_IO_DEV *: A pointer to FDC_BLK_IO_DEV
    427427  @retval EFI_SUCCESS:    Execute the Recalibrate operation successfully
     
    497497/**
    498498  Set the head of floppy drive to the new cylinder.
    499  
     499
    500500  @param  FdcDev FDC_BLK_IO_DEV *: A pointer to FDC_BLK_IO_DEV
    501501  @param  Lba EFI_LBA     : The logic block address want to seek
    502  
     502
    503503  @retval  EFI_SUCCESS:    Execute the Seek operation successfully
    504504  @retval  EFI_DEVICE_ERROR: Fail to execute the Seek operation
     
    601601  Do the Sense Interrupt Status command, this command
    602602  resets the interrupt signal.
    603  
     603
    604604  @param  FdcDev FDC_BLK_IO_DEV *: A pointer to FDC_BLK_IO_DEV
    605605  @param  StatusRegister0 UINT8 *: Be used to save Status Register 0 read from FDC
    606606  @param  PresentCylinderNumber  UINT8 *: Be used to save present cylinder number
    607607                                    read from FDC
    608  
     608
    609609  @retval  EFI_SUCCESS:    Execute the Sense Interrupt Status command successfully
    610610  @retval  EFI_DEVICE_ERROR: Fail to execute the command
     
    638638/**
    639639  Do the Sense Drive Status command.
    640  
     640
    641641  @param  FdcDev FDC_BLK_IO_DEV *: A pointer to FDC_BLK_IO_DEV
    642642  @param  Lba EFI_LBA     : Logic block address
    643  
     643
    644644  @retval  EFI_SUCCESS:    Execute the Sense Drive Status command successfully
    645645  @retval  EFI_DEVICE_ERROR: Fail to execute the command
     
    701701/**
    702702  Update the disk media properties and if necessary reinstall Block I/O interface.
    703  
     703
    704704  @param  FdcDev FDC_BLK_IO_DEV *: A pointer to FDC_BLK_IO_DEV
    705  
     705
    706706  @retval  EFI_SUCCESS:    Do the operation successfully
    707707  @retval  EFI_DEVICE_ERROR: Fail to the operation
     
    779779/**
    780780  Set the data rate and so on.
    781  
     781
    782782  @param  FdcDev  A pointer to FDC_BLK_IO_DEV
    783783
     
    812812/**
    813813  Read or Write a number of blocks in the same cylinder.
    814  
     814
    815815  @param  FdcDev      A pointer to FDC_BLK_IO_DEV
    816   @param  HostAddress device address 
     816  @param  HostAddress device address
    817817  @param  Lba         The starting logic block address to read from on the device
    818818  @param  NumberOfBlocks The number of block wanted to be read or write
    819819  @param  Read        Operation type: read or write
    820  
     820
    821821  @retval EFI_SUCCESS Success operate
    822822
     
    962962/**
    963963  Fill in FDD command's parameter.
    964  
     964
    965965  @param FdcDev   Pointer to instance of FDC_BLK_IO_DEV
    966966  @param Lba      The starting logic block address to read from on the device
     
    10031003/**
    10041004  Read result byte from Data Register of FDC.
    1005  
     1005
    10061006  @param FdcDev   Pointer to instance of FDC_BLK_IO_DEV
    10071007  @param Pointer  Buffer to store the byte read from FDC
    1008  
     1008
    10091009  @retval EFI_SUCCESS       Read result byte from FDC successfully
    10101010  @retval EFI_DEVICE_ERROR  The FDC is not ready to be read
     
    10421042/**
    10431043  Write command byte to Data Register of FDC.
    1044  
     1044
    10451045  @param FdcDev  Pointer to instance of FDC_BLK_IO_DEV
    10461046  @param Pointer Be used to save command byte written to FDC
    1047  
     1047
    10481048  @retval  EFI_SUCCESS:    Write command byte to FDC successfully
    10491049  @retval  EFI_DEVICE_ERROR: The FDC is not ready to be written
     
    10821082/**
    10831083  Detect the specified floppy logic drive is busy or not within a period of time.
    1084  
     1084
    10851085  @param FdcDev           Indicate it is drive A or drive B
    10861086  @param Timeout          The time period for waiting
    1087  
     1087
    10881088  @retval EFI_SUCCESS:  The drive and command are not busy
    10891089  @retval EFI_TIMEOUT:  The drive or command is still busy after a period time that
     
    11361136/**
    11371137  Determine whether FDC is ready to write or read.
    1138  
     1138
    11391139  @param  FdcDev Pointer to instance of FDC_BLK_IO_DEV
    11401140  @param  Dio BOOLEAN:      Indicate the FDC is waiting to write or read
    11411141  @param  Timeout           The time period for waiting
    1142  
     1142
    11431143  @retval EFI_SUCCESS:  FDC is ready to write or read
    11441144  @retval EFI_NOT_READY:  FDC is not ready within the specified time period
     
    11971197
    11981198/**
    1199   Set FDC control structure's attribute according to result. 
     1199  Set FDC control structure's attribute according to result.
    12001200
    12011201  @param Result  Point to result structure
     
    12481248/**
    12491249  Check the drive status information.
    1250  
     1250
    12511251  @param StatusRegister3  the value of Status Register 3
    1252  
     1252
    12531253  @retval EFI_SUCCESS           The disk is not write protected
    12541254  @retval EFI_WRITE_PROTECTED:  The disk is write protected
     
    12691269/**
    12701270  Calculate the number of block in the same cylinder according to LBA.
    1271  
     1271
    12721272  @param FdcDev FDC_BLK_IO_DEV *: A pointer to FDC_BLK_IO_DEV
    12731273  @param LBA EFI_LBA:      The starting logic block address
    12741274  @param NumberOfBlocks UINTN: The number of blocks
    1275  
     1275
    12761276  @return The number of blocks in the same cylinder which the starting
    12771277        logic block address is LBA
     
    13051305/**
    13061306  When the Timer(2s) off, turn the drive's motor off.
    1307  
     1307
    13081308  @param Event EFI_EVENT: Event(the timer) whose notification function is being
    13091309                     invoked
     
    13441344/**
    13451345  Read an I/O port of FDC.
    1346  
     1346
    13471347  @param[in] FdcDev  A pointer to FDC_BLK_IO_DEV.
    13481348  @param[in] Offset  The address offset of the I/O port.
     
    13731373/**
    13741374  Write an I/O port of FDC.
    1375  
     1375
    13761376  @param[in] FdcDev  A pointer to FDC_BLK_IO_DEV
    13771377  @param[in] Offset  The address offset of the I/O port
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaFloppyPei/Fdc.h

    r48674 r58466  
    1 /** @file 
     1/** @file
    22Definition of FDC registers and structures.
    33
    44Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
    5  
     5
    66This program and the accompanying materials
    77are licensed and made available under the terms and conditions
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaFloppyPei/FloppyPeim.c

    r58459 r58466  
    33
    44Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
    5  
     5
    66This program and the accompanying materials
    77are licensed and made available under the terms and conditions
     
    153153
    154154//
    155 // Table of diskette parameters of various diskette types 
     155// Table of diskette parameters of various diskette types
    156156//
    157157DISKET_PARA_TABLE  DiskPara[9] = {
     
    293293                            FALSE means output.
    294294  @param  TimeoutInMseconds  Timeout value to wait.
    295  
     295
    296296  @retval EFI_SUCCESS       FDC is ready.
    297297  @retval EFI_NOT_READY     FDC is not ready within the specified time period.
     
    784784    if ((Sts0 & 0xf0) == BIT5 && Pcn == 0) {
    785785      //
    786       // Recalibration is successful. 
     786      // Recalibration is successful.
    787787      //
    788788      Info->Pcn = 0;
     
    10231023    // No diskette in floppy.
    10241024    //
    1025     MediaInfo->MediaPresent = FALSE;   
     1025    MediaInfo->MediaPresent = FALSE;
    10261026  } else if (Status != EFI_MEDIA_CHANGED && Status != EFI_SUCCESS) {
    10271027    //
     
    14401440  Gets the count of block I/O devices that one specific block driver detects.
    14411441
    1442   This function is used for getting the count of block I/O devices that one 
     1442  This function is used for getting the count of block I/O devices that one
    14431443  specific block driver detects.  To the PEI ATAPI driver, it returns the number
    1444   of all the detected ATAPI devices it detects during the enumeration process. 
    1445   To the PEI legacy floppy driver, it returns the number of all the legacy 
    1446   devices it finds during its enumeration process. If no device is detected, 
    1447   then the function will return zero. 
    1448  
    1449   @param[in]  PeiServices          General-purpose services that are available 
     1444  of all the detected ATAPI devices it detects during the enumeration process.
     1445  To the PEI legacy floppy driver, it returns the number of all the legacy
     1446  devices it finds during its enumeration process. If no device is detected,
     1447  then the function will return zero.
     1448
     1449  @param[in]  PeiServices          General-purpose services that are available
    14501450                                   to every PEIM.
    1451   @param[in]  This                 Indicates the EFI_PEI_RECOVERY_BLOCK_IO_PPI 
     1451  @param[in]  This                 Indicates the EFI_PEI_RECOVERY_BLOCK_IO_PPI
    14521452                                   instance.
    14531453  @param[out] NumberBlockDevices   The number of block I/O devices discovered.
     
    14781478  Gets a block device's media information.
    14791479
    1480   This function will provide the caller with the specified block device's media 
    1481   information. If the media changes, calling this function will update the media 
     1480  This function will provide the caller with the specified block device's media
     1481  information. If the media changes, calling this function will update the media
    14821482  information accordingly.
    14831483
     
    14851485                            PEIM
    14861486  @param[in]  This          Indicates the EFI_PEI_RECOVERY_BLOCK_IO_PPI instance.
    1487   @param[in]  DeviceIndex   Specifies the block device to which the function wants 
    1488                             to talk. Because the driver that implements Block I/O 
    1489                             PPIs will manage multiple block devices, the PPIs that 
    1490                             want to talk to a single device must specify the 
     1487  @param[in]  DeviceIndex   Specifies the block device to which the function wants
     1488                            to talk. Because the driver that implements Block I/O
     1489                            PPIs will manage multiple block devices, the PPIs that
     1490                            want to talk to a single device must specify the
    14911491                            device index that was assigned during the enumeration
    1492                             process. This index is a number from one to 
     1492                            process. This index is a number from one to
    14931493                            NumberBlockDevices.
    1494   @param[out] MediaInfo     The media information of the specified block media. 
    1495                             The caller is responsible for the ownership of this 
     1494  @param[out] MediaInfo     The media information of the specified block media.
     1495                            The caller is responsible for the ownership of this
    14961496                            data structure.
    1497  
    1498   @retval EFI_SUCCESS        Media information about the specified block device 
     1497
     1498  @retval EFI_SUCCESS        Media information about the specified block device
    14991499                             was obtained successfully.
    1500   @retval EFI_DEVICE_ERROR   Cannot get the media information due to a hardware 
     1500  @retval EFI_DEVICE_ERROR   Cannot get the media information due to a hardware
    15011501                             error.
    15021502  @retval Others             Other failure occurs.
     
    15601560  Reads the requested number of blocks from the specified block device.
    15611561
    1562   The function reads the requested number of blocks from the device. All the 
     1562  The function reads the requested number of blocks from the device. All the
    15631563  blocks are read, or an error is returned. If there is no media in the device,
    15641564  the function returns EFI_NO_MEDIA.
    15651565
    1566   @param[in]  PeiServices   General-purpose services that are available to 
     1566  @param[in]  PeiServices   General-purpose services that are available to
    15671567                            every PEIM.
    15681568  @param[in]  This          Indicates the EFI_PEI_RECOVERY_BLOCK_IO_PPI instance.
    1569   @param[in]  DeviceIndex   Specifies the block device to which the function wants 
    1570                             to talk. Because the driver that implements Block I/O 
    1571                             PPIs will manage multiple block devices, the PPIs that 
    1572                             want to talk to a single device must specify the device 
    1573                             index that was assigned during the enumeration process. 
     1569  @param[in]  DeviceIndex   Specifies the block device to which the function wants
     1570                            to talk. Because the driver that implements Block I/O
     1571                            PPIs will manage multiple block devices, the PPIs that
     1572                            want to talk to a single device must specify the device
     1573                            index that was assigned during the enumeration process.
    15741574                            This index is a number from one to NumberBlockDevices.
    15751575  @param[in]  StartLBA      The starting logical block address (LBA) to read from
     
    15781578                            a multiple of the intrinsic block size of the device.
    15791579  @param[out] Buffer        A pointer to the destination buffer for the data.
    1580                             The caller is responsible for the ownership of the 
     1580                            The caller is responsible for the ownership of the
    15811581                            buffer.
    1582                          
     1582
    15831583  @retval EFI_SUCCESS             The data was read correctly from the device.
    1584   @retval EFI_DEVICE_ERROR        The device reported an error while attempting 
     1584  @retval EFI_DEVICE_ERROR        The device reported an error while attempting
    15851585                                  to perform the read operation.
    1586   @retval EFI_INVALID_PARAMETER   The read request contains LBAs that are not 
     1586  @retval EFI_INVALID_PARAMETER   The read request contains LBAs that are not
    15871587                                  valid, or the buffer is not properly aligned.
    15881588  @retval EFI_NO_MEDIA            There is no media in the device.
     
    17301730  //
    17311731  // Allocate memory for instance of FDC_BLK_IO_DEV and copy initial value
    1732   // from template to it. 
     1732  // from template to it.
    17331733  //
    17341734  FdcBlkIoDev = AllocatePages (EFI_SIZE_TO_PAGES(sizeof (FDC_BLK_IO_DEV)));
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaFloppyPei/FloppyPeim.h

    r48674 r58466  
    33
    44Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
    5  
     5
    66This program and the accompanying materials
    77are licensed and made available under the terms and conditions
     
    105105/// ISA memory range
    106106///
    107 #define ISA_MAX_MEMORY_ADDRESS  0x1000000 
     107#define ISA_MAX_MEMORY_ADDRESS  0x1000000
    108108
    109109//
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaIoDxe/IsaDriver.c

    r48674 r58466  
    33
    44  Produce an instance of the ISA I/O Protocol for every SIO controller.
    5  
     5
    66Copyright (c) 2010, Intel Corporation. All rights reserved.<BR>
    77This program and the accompanying materials
     
    3232  The main entry point for the IsaIo driver.
    3333
    34   @param[in] ImageHandle        The firmware allocated handle for the EFI image. 
     34  @param[in] ImageHandle        The firmware allocated handle for the EFI image.
    3535  @param[in] SystemTable        A pointer to the EFI System Table.
    36  
     36
    3737  @retval EFI_SUCCESS           The entry point is executed successfully.
    3838  @retval EFI_OUT_OF_RESOURCES  There was not enough memory in pool to install all the protocols.
     
    6363}
    6464
    65 /** 
     65/**
    6666  Tests to see if a controller can be managed by the IsaIo driver.
    6767
    68   @param[in] This                 A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance. 
     68  @param[in] This                 A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    6969  @param[in] Controller           The handle of the controller to test.
    7070  @param[in] RemainingDevicePath  A pointer to the remaining portion of a device path.
    71  
     71
    7272  @retval EFI_SUCCESS             The device is supported by this driver.
    7373  @retval EFI_ALREADY_STARTED     The device is already being managed by this driver.
    74   @retval EFI_ACCESS_DENIED       The device is already being managed by a different driver 
     74  @retval EFI_ACCESS_DENIED       The device is already being managed by a different driver
    7575                                  or an application that requires exclusive access.
    7676  @retval EFI_UNSUPPORTED         The device is is not supported by this driver.
     
    137137
    138138/**
    139   Start this driver on ControllerHandle. 
    140  
    141   The Start() function is designed to be invoked from the EFI boot service ConnectController(). 
    142   As a result, much of the error checking on the parameters to Start() has been moved into this 
    143   common boot service. It is legal to call Start() from other locations, but the following calling 
     139  Start this driver on ControllerHandle.
     140
     141  The Start() function is designed to be invoked from the EFI boot service ConnectController().
     142  As a result, much of the error checking on the parameters to Start() has been moved into this
     143  common boot service. It is legal to call Start() from other locations, but the following calling
    144144  restrictions must be followed or the system behavior will not be deterministic.
    145145  1. ControllerHandle must be a valid EFI_HANDLE.
     
    147147     EFI_DEVICE_PATH_PROTOCOL.
    148148  3. Prior to calling Start(), the Supported() function for the driver specified by This must
    149      have been called with the same calling parameters, and Supported() must have returned EFI_SUCCESS. 
     149     have been called with the same calling parameters, and Supported() must have returned EFI_SUCCESS.
    150150
    151151  @param[in]  This                 A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    152   @param[in]  ControllerHandle     The handle of the controller to start. This handle 
    153                                    must support a protocol interface that supplies 
     152  @param[in]  ControllerHandle     The handle of the controller to start. This handle
     153                                   must support a protocol interface that supplies
    154154                                   an I/O abstraction to the driver.
    155   @param[in]  RemainingDevicePath  A pointer to the remaining portion of a device path. 
     155  @param[in]  RemainingDevicePath  A pointer to the remaining portion of a device path.
    156156                                   This parameter is ignored by device drivers, and is optional for bus drivers.
    157157
     
    255255
    256256/**
    257   Stop this driver on ControllerHandle. 
    258  
    259   The Stop() function is designed to be invoked from the EFI boot service DisconnectController(). 
    260   As a result, much of the error checking on the parameters to Stop() has been moved 
    261   into this common boot service. It is legal to call Stop() from other locations, 
     257  Stop this driver on ControllerHandle.
     258
     259  The Stop() function is designed to be invoked from the EFI boot service DisconnectController().
     260  As a result, much of the error checking on the parameters to Stop() has been moved
     261  into this common boot service. It is legal to call Stop() from other locations,
    262262  but the following calling restrictions must be followed or the system behavior will not be deterministic.
    263263  1. ControllerHandle must be a valid EFI_HANDLE that was used on a previous call to this
     
    267267     Start() function, and the Start() function must have called OpenProtocol() on
    268268     ControllerHandle with an Attribute of EFI_OPEN_PROTOCOL_BY_CHILD_CONTROLLER.
    269  
     269
    270270  @param[in]  This              A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    271   @param[in]  ControllerHandle  A handle to the device being stopped. The handle must 
    272                                 support a bus specific I/O protocol for the driver 
     271  @param[in]  ControllerHandle  A handle to the device being stopped. The handle must
     272                                support a bus specific I/O protocol for the driver
    273273                                to use to stop the device.
    274274  @param[in]  NumberOfChildren  The number of child device handles in ChildHandleBuffer.
    275   @param[in]  ChildHandleBuffer An array of child handles to be freed. May be NULL 
     275  @param[in]  ChildHandleBuffer An array of child handles to be freed. May be NULL
    276276                                if NumberOfChildren is 0.
    277277
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaIoDxe/IsaDriver.h

    r48674 r58466  
    11/** @file
    22  The header file for ISA driver
    3  
     3
    44Copyright (c) 2010, Intel Corporation. All rights reserved.<BR>
    55This program and the accompanying materials
     
    149149//
    150150
    151 /** 
     151/**
    152152  Tests to see if a controller can be managed by the ISA Driver.
    153153
    154154  How the Start() function of a driver is implemented can affect how the Supported() function is implemented.
    155155
    156   @param[in] This                 A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance. 
     156  @param[in] This                 A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    157157  @param[in] Controller           The handle of the controller to test.
    158158  @param[in] RemainingDevicePath  A pointer to the remaining portion of a device path.
    159  
     159
    160160  @retval EFI_SUCCESS             The device is supported by this driver.
    161161  @retval EFI_ALREADY_STARTED     The device is already being managed by this driver.
    162   @retval EFI_ACCESS_DENIED       The device is already being managed by a different driver 
     162  @retval EFI_ACCESS_DENIED       The device is already being managed by a different driver
    163163                                  or an application that requires exclusive access.
    164164  @retval EFI_UNSUPPORTED         The device is is not supported by this driver.
     
    174174
    175175/**
    176   Start this driver on ControllerHandle. 
    177  
    178   The Start() function is designed to be invoked from the EFI boot service ConnectController(). 
    179   As a result, much of the error checking on the parameters to Start() has been moved into this 
    180   common boot service. It is legal to call Start() from other locations, but the following calling 
     176  Start this driver on ControllerHandle.
     177
     178  The Start() function is designed to be invoked from the EFI boot service ConnectController().
     179  As a result, much of the error checking on the parameters to Start() has been moved into this
     180  common boot service. It is legal to call Start() from other locations, but the following calling
    181181  restrictions must be followed or the system behavior will not be deterministic.
    182182  1. ControllerHandle must be a valid EFI_HANDLE.
     
    184184     EFI_DEVICE_PATH_PROTOCOL.
    185185  3. Prior to calling Start(), the Supported() function for the driver specified by This must
    186      have been called with the same calling parameters, and Supported() must have returned EFI_SUCCESS. 
     186     have been called with the same calling parameters, and Supported() must have returned EFI_SUCCESS.
    187187
    188188  @param[in]  This                 A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    189   @param[in]  ControllerHandle     The handle of the controller to start. This handle 
    190                                    must support a protocol interface that supplies 
     189  @param[in]  ControllerHandle     The handle of the controller to start. This handle
     190                                   must support a protocol interface that supplies
    191191                                   an I/O abstraction to the driver.
    192   @param[in]  RemainingDevicePath  A pointer to the remaining portion of a device path. 
     192  @param[in]  RemainingDevicePath  A pointer to the remaining portion of a device path.
    193193                                   This parameter is ignored by device drivers, and is optional for bus drivers.
    194194
     
    208208
    209209/**
    210   Stop this driver on ControllerHandle. 
    211  
    212   The Stop() function is designed to be invoked from the EFI boot service DisconnectController(). 
    213   As a result, much of the error checking on the parameters to Stop() has been moved 
    214   into this common boot service. It is legal to call Stop() from other locations, 
     210  Stop this driver on ControllerHandle.
     211
     212  The Stop() function is designed to be invoked from the EFI boot service DisconnectController().
     213  As a result, much of the error checking on the parameters to Stop() has been moved
     214  into this common boot service. It is legal to call Stop() from other locations,
    215215  but the following calling restrictions must be followed or the system behavior will not be deterministic.
    216216  1. ControllerHandle must be a valid EFI_HANDLE that was used on a previous call to this
     
    220220     Start() function, and the Start() function must have called OpenProtocol() on
    221221     ControllerHandle with an Attribute of EFI_OPEN_PROTOCOL_BY_CHILD_CONTROLLER.
    222  
     222
    223223  @param[in]  This              A pointer to the EFI_DRIVER_BINDING_PROTOCOL instance.
    224   @param[in]  ControllerHandle  A handle to the device being stopped. The handle must 
    225                                 support a bus specific I/O protocol for the driver 
     224  @param[in]  ControllerHandle  A handle to the device being stopped. The handle must
     225                                support a bus specific I/O protocol for the driver
    226226                                to use to stop the device.
    227227  @param[in]  NumberOfChildren  The number of child device handles in ChildHandleBuffer.
    228   @param[in]  ChildHandleBuffer An array of child handles to be freed. May be NULL 
     228  @param[in]  ChildHandleBuffer An array of child handles to be freed. May be NULL
    229229                                if NumberOfChildren is 0.
    230230
     
    251251  @param[in] DevicePath             The device path of the isa device.
    252252  @param[in] Resources              The ACPI resource list.
    253  
     253
    254254**/
    255255VOID
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaIoDxe/IsaIo.c

    r58459 r58466  
    11/** @file
    2   The implementation for EFI_ISA_IO_PROTOCOL. 
    3  
     2  The implementation for EFI_ISA_IO_PROTOCOL.
     3
    44Copyright (c) 2010 - 2012, Intel Corporation. All rights reserved.<BR>
    55This program and the accompanying materials
     
    1919//
    2020EFI_ISA_IO_PROTOCOL mIsaIoInterface = {
    21   {   
     21  {
    2222    IsaIoMemRead,
    2323    IsaIoMemWrite
    2424  },
    25   {   
     25  {
    2626    IsaIoIoRead,
    2727    IsaIoIoWrite
     
    8787  @param[in] Type                The Access type. The input must be either IsaAccessTypeMem or IsaAccessTypeIo.
    8888  @param[in] Width               The width of the memory operation.
    89   @param[in] Count               The number of memory operations to perform. 
    90   @param[in] Offset              The offset in ISA memory space to start the memory operation. 
    91  
     89  @param[in] Count               The number of memory operations to perform.
     90  @param[in] Offset              The offset in ISA memory space to start the memory operation.
     91
    9292  @retval EFI_SUCCESS            Verify success.
    9393  @retval EFI_INVALID_PARAMETER  One of the parameters has an invalid value.
     
    164164      Attribute |= EFI_ISA_ACPI_IO_DECODE_16_BITS;
    165165      break;
    166      
     166
    167167    case EFI_ACPI_IO_DECODE_10_BIT:
    168168      Attribute |= EFI_ISA_ACPI_IO_DECODE_10_BITS;
     
    245245
    246246  Attribute = EFI_ISA_IO_SLAVE_DMA_ATTRIBUTE_SINGLE_MODE;
    247  
     247
    248248  switch (Information & EFI_ACPI_DMA_SPEED_TYPE_MASK) {
    249249    case EFI_ACPI_DMA_SPEED_TYPE_COMPATIBILITY:
     
    425425  @param[in] DevicePath             The device path of the isa device.
    426426  @param[in] Resources              The ACPI resource list.
    427  
     427
    428428**/
    429429VOID
     
    453453  Index       = 0;
    454454  while (ResourcePtr.SmallHeader->Byte != ACPI_END_TAG_DESCRIPTOR) {
    455    
     455
    456456    Index += AcpiResourceToIsaResource (ResourcePtr, NULL);
    457457
     
    499499    }
    500500  }
    501  
     501
    502502  //
    503503  // Convert the ACPI End Tag
     
    511511  @param[in]  This              A pointer to the EFI_ISA_IO_PROTOCOL instance.
    512512  @param[in]  Width             Specifies the width of the I/O operation.
    513   @param[in]  Offset            The offset in ISA I/O space to start the I/O operation. 
    514   @param[in]  Count             The number of I/O operations to perform. 
     513  @param[in]  Offset            The offset in ISA I/O space to start the I/O operation.
     514  @param[in]  Count             The number of I/O operations to perform.
    515515  @param[out] Buffer            The destination buffer to store the results
    516516
     
    573573  @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance.
    574574  @param[in] Width               Specifies the width of the I/O operation.
    575   @param[in] Offset              The offset in ISA I/O space to start the I/O operation. 
    576   @param[in] Count               The number of I/O operations to perform. 
     575  @param[in] Offset              The offset in ISA I/O space to start the I/O operation.
     576  @param[in] Count               The number of I/O operations to perform.
    577577  @param[in] Buffer              The source buffer to write data from
    578578
     
    634634
    635635  @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance.
    636   @param[in] Offset              The offset in ISA IO space to start the IO operation. 
     636  @param[in] Offset              The offset in ISA IO space to start the IO operation.
    637637  @param[in] Value               The data to write port.
    638638
     
    686686  @param[in] CountOffset         The count's offset.
    687687  @param[in] BaseAddress         The base address.
    688   @param[in] Count               The number of I/O operations to perform. 
    689  
     688  @param[in] Count               The number of I/O operations to perform.
     689
    690690  @retval EFI_SUCCESS            Success.
    691691  @retval EFI_INVALID_PARAMETER  Parameter is invalid.
     
    823823  @param[in]  This               A pointer to the EFI_ISA_IO_PROTOCOL instance.
    824824  @param[in]  Width              Specifies the width of the memory operation.
    825   @param[in]  Offset             The offset in ISA memory space to start the memory operation. 
    826   @param[in]  Count              The number of memory operations to perform. 
     825  @param[in]  Offset             The offset in ISA memory space to start the memory operation.
     826  @param[in]  Count              The number of memory operations to perform.
    827827  @param[out] Buffer             The destination buffer to store the results
    828  
     828
    829829  @retval EFI_SUCCESS            The data was read from the device successfully.
    830830  @retval EFI_UNSUPPORTED        The Offset is not valid for this device.
     
    890890  Performs an ISA Memory Write Cycle
    891891
    892   @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance. 
     892  @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance.
    893893  @param[in] Width               Specifies the width of the memory operation.
    894   @param[in] Offset              The offset in ISA memory space to start the memory operation. 
    895   @param[in] Count               The number of memory operations to perform. 
     894  @param[in] Offset              The offset in ISA memory space to start the memory operation.
     895  @param[in] Count               The number of memory operations to perform.
    896896  @param[in] Buffer              The source buffer to write data from
    897897
     
    961961  @param[in]  This               A pointer to the EFI_ISA_IO_PROTOCOL instance.
    962962  @param[in]  Width              Specifies the width of the memory copy operation.
    963   @param[in]  DestOffset         The offset of the destination 
     963  @param[in]  DestOffset         The offset of the destination
    964964  @param[in]  SrcOffset          The offset of the source
    965965  @param[in]  Count              The number of memory copy  operations to perform
     
    10421042
    10431043  @param This                    A pointer to the EFI_ISA_IO_PROTOCOL instance.
    1044   @param Operation               Indicates the type of DMA (slave or bus master), and if 
    1045                                  the DMA operation is going to read or write to system memory. 
    1046   @param ChannelNumber           The slave channel number to use for this DMA operation. 
    1047                                  If Operation and ChannelAttributes shows that this device 
    1048                                  performs bus mastering DMA, then this field is ignored. 
    1049                                  The legal range for this field is 0..7. 
     1044  @param Operation               Indicates the type of DMA (slave or bus master), and if
     1045                                 the DMA operation is going to read or write to system memory.
     1046  @param ChannelNumber           The slave channel number to use for this DMA operation.
     1047                                 If Operation and ChannelAttributes shows that this device
     1048                                 performs bus mastering DMA, then this field is ignored.
     1049                                 The legal range for this field is 0..7.
    10501050  @param ChannelAttributes       The attributes of the DMA channel to use for this DMA operation
    1051   @param HostAddress             The system memory address to map to the device. 
    1052   @param NumberOfBytes           On input the number of bytes to map.  On output the number 
     1051  @param HostAddress             The system memory address to map to the device.
     1052  @param NumberOfBytes           On input the number of bytes to map.  On output the number
    10531053                                 of bytes that were mapped.
    1054   @param DeviceAddress           The resulting map address for the bus master device to use 
    1055                                  to access the hosts HostAddress. 
     1054  @param DeviceAddress           The resulting map address for the bus master device to use
     1055                                 to access the hosts HostAddress.
    10561056  @param Mapping                 A resulting value to pass to EFI_ISA_IO.Unmap().
    10571057
     
    10841084  UINT8                 DmaClear;
    10851085  UINT8                 DmaChannelMode;
    1086  
     1086
    10871087  if ((NULL == This) ||
    10881088      (NULL == HostAddress) ||
     
    11031103  // Light IsaIo only supports two operations.
    11041104  //
    1105   if (!(Operation == EfiIsaIoOperationSlaveRead || 
     1105  if (!(Operation == EfiIsaIoOperationSlaveRead ||
    11061106        Operation == EfiIsaIoOperationSlaveWrite)) {
    11071107    return EFI_INVALID_PARAMETER;
     
    11891189    *DeviceAddress = PhysicalAddress;
    11901190  }
    1191  
     1191
    11921192  //
    11931193  // Figure out what to program into the DMA Channel Mode Register
     
    12741274
    12751275/**
    1276   Maps a memory region for DMA. This implementation implement the 
     1276  Maps a memory region for DMA. This implementation implement the
    12771277  the full mapping support.
    12781278
    12791279  @param This                    A pointer to the EFI_ISA_IO_PROTOCOL instance.
    1280   @param Operation               Indicates the type of DMA (slave or bus master), and if 
    1281                                  the DMA operation is going to read or write to system memory. 
    1282   @param ChannelNumber           The slave channel number to use for this DMA operation. 
    1283                                  If Operation and ChannelAttributes shows that this device 
    1284                                  performs bus mastering DMA, then this field is ignored. 
    1285                                  The legal range for this field is 0..7. 
     1280  @param Operation               Indicates the type of DMA (slave or bus master), and if
     1281                                 the DMA operation is going to read or write to system memory.
     1282  @param ChannelNumber           The slave channel number to use for this DMA operation.
     1283                                 If Operation and ChannelAttributes shows that this device
     1284                                 performs bus mastering DMA, then this field is ignored.
     1285                                 The legal range for this field is 0..7.
    12861286  @param ChannelAttributes       The attributes of the DMA channel to use for this DMA operation
    1287   @param HostAddress             The system memory address to map to the device. 
    1288   @param NumberOfBytes           On input the number of bytes to map.  On output the number 
     1287  @param HostAddress             The system memory address to map to the device.
     1288  @param NumberOfBytes           On input the number of bytes to map.  On output the number
    12891289                                 of bytes that were mapped.
    1290   @param DeviceAddress           The resulting map address for the bus master device to use 
    1291                                  to access the hosts HostAddress. 
     1290  @param DeviceAddress           The resulting map address for the bus master device to use
     1291                                 to access the hosts HostAddress.
    12921292  @param Mapping                 A resulting value to pass to EFI_ISA_IO.Unmap().
    12931293
     
    16031603
    16041604  @param This                    A pointer to the EFI_ISA_IO_PROTOCOL instance.
    1605   @param Operation               Indicates the type of DMA (slave or bus master), and if 
    1606                                  the DMA operation is going to read or write to system memory. 
    1607   @param ChannelNumber           The slave channel number to use for this DMA operation. 
    1608                                  If Operation and ChannelAttributes shows that this device 
    1609                                  performs bus mastering DMA, then this field is ignored. 
    1610                                  The legal range for this field is 0..7. 
     1605  @param Operation               Indicates the type of DMA (slave or bus master), and if
     1606                                 the DMA operation is going to read or write to system memory.
     1607  @param ChannelNumber           The slave channel number to use for this DMA operation.
     1608                                 If Operation and ChannelAttributes shows that this device
     1609                                 performs bus mastering DMA, then this field is ignored.
     1610                                 The legal range for this field is 0..7.
    16111611  @param ChannelAttributes       The attributes of the DMA channel to use for this DMA operation
    1612   @param HostAddress             The system memory address to map to the device. 
    1613   @param NumberOfBytes           On input the number of bytes to map.  On output the number 
     1612  @param HostAddress             The system memory address to map to the device.
     1613  @param NumberOfBytes           On input the number of bytes to map.  On output the number
    16141614                                 of bytes that were mapped.
    1615   @param DeviceAddress           The resulting map address for the bus master device to use 
    1616                                  to access the hosts HostAddress. 
     1615  @param DeviceAddress           The resulting map address for the bus master device to use
     1616                                 to access the hosts HostAddress.
    16171617  @param Mapping                 A resulting value to pass to EFI_ISA_IO.Unmap().
    16181618
     
    16431643  }
    16441644  //
    1645   // Set Feature Flag PcdIsaBusSupportBusMaster to FALSE to disable support for 
     1645  // Set Feature Flag PcdIsaBusSupportBusMaster to FALSE to disable support for
    16461646  // ISA Bus Master.
    16471647  //
     
    16861686  @retval EFI_SUCCESS            The requested memory pages were allocated.
    16871687  @retval EFI_INVALID_PARAMETER  Type is invalid or MemoryType is invalid or HostAddress is NULL
    1688   @retval EFI_UNSUPPORTED        Attributes is unsupported or the memory range specified 
     1688  @retval EFI_UNSUPPORTED        Attributes is unsupported or the memory range specified
    16891689                                 by HostAddress, Pages, and Type is not available for common buffer use.
    16901690  @retval EFI_OUT_OF_RESOURCES   The memory pages could not be allocated.
     
    17051705
    17061706  //
    1707   // Set Feature Flag PcdIsaBusOnlySupportSlaveDma to FALSE to disable support for 
     1707  // Set Feature Flag PcdIsaBusOnlySupportSlaveDma to FALSE to disable support for
    17081708  // ISA Bus Master.
    17091709  // Or unset Feature Flag PcdIsaBusSupportDma to disable support for ISA DMA.
     
    17591759
    17601760/**
    1761   Frees memory that was allocated with EFI_ISA_IO.AllocateBuffer(). 
     1761  Frees memory that was allocated with EFI_ISA_IO.AllocateBuffer().
    17621762
    17631763  @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance.
     
    17791779
    17801780  //
    1781   // Set Feature Flag PcdIsaBusOnlySupportSlaveDma to FALSE to disable support for 
     1781  // Set Feature Flag PcdIsaBusOnlySupportSlaveDma to FALSE to disable support for
    17821782  // ISA Bus Master.
    17831783  // Or unset Feature Flag PcdIsaBusSupportDma to disable support for ISA DMA.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaIoDxe/IsaIo.h

    r48674 r58466  
    11/** @file
    22  The header file for EFI_ISA_IO protocol implementation.
    3  
     3
    44Copyright (c) 2010, Intel Corporation. All rights reserved.<BR>
    55This program and the accompanying materials
     
    3535  @param[in] Type                The Access type. The input must be either IsaAccessTypeMem or IsaAccessTypeIo.
    3636  @param[in] Width               The width of the memory operation.
    37   @param[in] Count               The number of memory operations to perform. 
    38   @param[in] Offset              The offset in ISA memory space to start the memory operation. 
    39  
     37  @param[in] Count               The number of memory operations to perform.
     38  @param[in] Offset              The offset in ISA memory space to start the memory operation.
     39
    4040  @retval EFI_SUCCESS            Verify success.
    4141  @retval EFI_INVALID_PARAMETER  One of the parameters has an invalid value.
     
    5050  IN UINT32                     Offset
    5151  );
    52  
     52
    5353/**
    5454  Performs an ISA I/O Read Cycle
     
    5656  @param[in]  This              A pointer to the EFI_ISA_IO_PROTOCOL instance.
    5757  @param[in]  Width             Specifies the width of the I/O operation.
    58   @param[in]  Offset            The offset in ISA I/O space to start the I/O operation. 
    59   @param[in]  Count             The number of I/O operations to perform. 
     58  @param[in]  Offset            The offset in ISA I/O space to start the I/O operation.
     59  @param[in]  Count             The number of I/O operations to perform.
    6060  @param[out] Buffer            The destination buffer to store the results
    6161
     
    8080  @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance.
    8181  @param[in] Width               Specifies the width of the I/O operation.
    82   @param[in] Offset              The offset in ISA I/O space to start the I/O operation. 
    83   @param[in] Count               The number of I/O operations to perform. 
     82  @param[in] Offset              The offset in ISA I/O space to start the I/O operation.
     83  @param[in] Count               The number of I/O operations to perform.
    8484  @param[in] Buffer              The source buffer to write data from
    8585
     
    103103
    104104  @param This                    A pointer to the EFI_ISA_IO_PROTOCOL instance.
    105   @param Operation               Indicates the type of DMA (slave or bus master), and if 
    106                                  the DMA operation is going to read or write to system memory. 
    107   @param ChannelNumber           The slave channel number to use for this DMA operation. 
    108                                  If Operation and ChannelAttributes shows that this device 
    109                                  performs bus mastering DMA, then this field is ignored. 
    110                                  The legal range for this field is 0..7. 
     105  @param Operation               Indicates the type of DMA (slave or bus master), and if
     106                                 the DMA operation is going to read or write to system memory.
     107  @param ChannelNumber           The slave channel number to use for this DMA operation.
     108                                 If Operation and ChannelAttributes shows that this device
     109                                 performs bus mastering DMA, then this field is ignored.
     110                                 The legal range for this field is 0..7.
    111111  @param ChannelAttributes       The attributes of the DMA channel to use for this DMA operation
    112   @param HostAddress             The system memory address to map to the device. 
    113   @param NumberOfBytes           On input the number of bytes to map.  On output the number 
     112  @param HostAddress             The system memory address to map to the device.
     113  @param NumberOfBytes           On input the number of bytes to map.  On output the number
    114114                                 of bytes that were mapped.
    115   @param DeviceAddress           The resulting map address for the bus master device to use 
    116                                  to access the hosts HostAddress. 
     115  @param DeviceAddress           The resulting map address for the bus master device to use
     116                                 to access the hosts HostAddress.
    117117  @param Mapping                 A resulting value to pass to EFI_ISA_IO.Unmap().
    118118
     
    174174  @param[in] CountOffset         The count's offset.
    175175  @param[in] BaseAddress         The base address.
    176   @param[in] Count               The number of I/O operations to perform. 
    177  
     176  @param[in] Count               The number of I/O operations to perform.
     177
    178178  @retval EFI_SUCCESS            Success.
    179179  @retval EFI_INVALID_PARAMETER  Parameter is invalid.
     
    195195
    196196  @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance.
    197   @param[in] Offset              The offset in ISA IO space to start the IO operation. 
     197  @param[in] Offset              The offset in ISA IO space to start the IO operation.
    198198  @param[in] Value               The data to write port.
    199199
     
    208208  IN UINT32               Offset,
    209209  IN UINT8                Value
    210   );   
     210  );
    211211
    212212/**
     
    215215  @param[in]  This               A pointer to the EFI_ISA_IO_PROTOCOL instance.
    216216  @param[in]  Width              Specifies the width of the memory operation.
    217   @param[in]  Offset             The offset in ISA memory space to start the memory operation. 
    218   @param[in]  Count              The number of memory operations to perform. 
     217  @param[in]  Offset             The offset in ISA memory space to start the memory operation.
     218  @param[in]  Count              The number of memory operations to perform.
    219219  @param[out] Buffer             The destination buffer to store the results
    220  
     220
    221221  @retval EFI_SUCCESS            The data was read from the device successfully.
    222222  @retval EFI_UNSUPPORTED        The Offset is not valid for this device.
     
    238238  Performs an ISA Memory Write Cycle
    239239
    240   @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance. 
     240  @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance.
    241241  @param[in] Width               Specifies the width of the memory operation.
    242   @param[in] Offset              The offset in ISA memory space to start the memory operation. 
    243   @param[in] Count               The number of memory operations to perform. 
     242  @param[in] Offset              The offset in ISA memory space to start the memory operation.
     243  @param[in] Count               The number of memory operations to perform.
    244244  @param[in] Buffer              The source buffer to write data from
    245245
     
    264264  @param[in]  This               A pointer to the EFI_ISA_IO_PROTOCOL instance.
    265265  @param[in]  Width              Specifies the width of the memory copy operation.
    266   @param[in]  DestOffset         The offset of the destination 
     266  @param[in]  DestOffset         The offset of the destination
    267267  @param[in]  SrcOffset          The offset of the source
    268268  @param[in]  Count              The number of memory copy  operations to perform
     
    295295  @retval EFI_SUCCESS            The requested memory pages were allocated.
    296296  @retval EFI_INVALID_PARAMETER  Type is invalid or MemoryType is invalid or HostAddress is NULL
    297   @retval EFI_UNSUPPORTED        Attributes is unsupported or the memory range specified 
     297  @retval EFI_UNSUPPORTED        Attributes is unsupported or the memory range specified
    298298                                 by HostAddress, Pages, and Type is not available for common buffer use.
    299299  @retval EFI_OUT_OF_RESOURCES   The memory pages could not be allocated.
     
    311311
    312312/**
    313   Frees memory that was allocated with EFI_ISA_IO.AllocateBuffer(). 
     313  Frees memory that was allocated with EFI_ISA_IO.AllocateBuffer().
    314314
    315315  @param[in] This                A pointer to the EFI_ISA_IO_PROTOCOL instance.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/IsaSerialDxe.inf

    r58459 r58466  
    3131#  VALID_ARCHITECTURES           = IA32 X64 IPF EBC
    3232#
    33 #  DRIVER_BINDING                =  gSerialControllerDriver                     
    34 #  COMPONENT_NAME                =  gIsaSerialComponentName                     
     33#  DRIVER_BINDING                =  gSerialControllerDriver
     34#  COMPONENT_NAME                =  gIsaSerialComponentName
    3535#  COMPONENT_NAME2               =  gIsaSerialComponentName2
    3636#
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/Serial.c

    r58459 r58466  
    9191
    9292  @param[in] FlowControl    The device path node to be checked.
    93  
     93
    9494  @retval TRUE              It's the Flow Control node.
    9595  @retval FALSE             It's not.
     
    112112
    113113  @param[in] DevicePath     The device path to be checked.
    114  
     114
    115115  @retval TRUE              It contains the Flow Control node.
    116116  @retval FALSE             It doesn't.
     
    135135  The user Entry Point for module IsaSerial. The user code starts with this function.
    136136
    137   @param[in] ImageHandle    The firmware allocated handle for the EFI image. 
     137  @param[in] ImageHandle    The firmware allocated handle for the EFI image.
    138138  @param[in] SystemTable    A pointer to the EFI System Table.
    139  
     139
    140140  @retval EFI_SUCCESS       The entry point is executed successfully.
    141141  @retval other             Some error occurs when executing this entry point.
     
    214214  if (RemainingDevicePath != NULL) {
    215215    //
    216     // Check if RemainingDevicePath is the End of Device Path Node, 
     216    // Check if RemainingDevicePath is the End of Device Path Node,
    217217    // if yes, go on checking other conditions
    218218    //
     
    231231        goto Error;
    232232      }
    233  
     233
    234234      if (UartNode->BaudRate > SERIAL_PORT_MAX_BAUD_RATE) {
    235235        goto Error;
    236236      }
    237  
     237
    238238      if (UartNode->Parity < NoParity || UartNode->Parity > SpaceParity) {
    239239        goto Error;
    240240      }
    241  
     241
    242242      if (UartNode->DataBits < 5 || UartNode->DataBits > 8) {
    243243        goto Error;
    244244      }
    245  
     245
    246246      if (UartNode->StopBits < OneStopBit || UartNode->StopBits > TwoStopBits) {
    247247        goto Error;
    248248      }
    249  
     249
    250250      if ((UartNode->DataBits == 5) && (UartNode->StopBits == TwoStopBits)) {
    251251        goto Error;
    252252      }
    253  
     253
    254254      if ((UartNode->DataBits >= 6) && (UartNode->DataBits <= 8) && (UartNode->StopBits == OneFiveStopBits)) {
    255255        goto Error;
     
    511511              //
    512512              Control &= (EFI_SERIAL_REQUEST_TO_SEND | EFI_SERIAL_DATA_TERMINAL_READY |
    513                           EFI_SERIAL_HARDWARE_LOOPBACK_ENABLE | EFI_SERIAL_SOFTWARE_LOOPBACK_ENABLE | 
     513                          EFI_SERIAL_HARDWARE_LOOPBACK_ENABLE | EFI_SERIAL_SOFTWARE_LOOPBACK_ENABLE |
    514514                          EFI_SERIAL_HARDWARE_FLOW_CONTROL_ENABLE);
    515515              Status = SerialIo->SetControl (SerialIo, Control);
     
    530530      // If RemainingDevicePath is the End of Device Path Node,
    531531      // skip enumerate any device and return EFI_SUCESSS
    532       // 
     532      //
    533533      return EFI_SUCCESS;
    534534    }
     
    551551
    552552  //
    553   // Check if RemainingDevicePath is NULL, 
     553  // Check if RemainingDevicePath is NULL,
    554554  // if yes, use the values from the gSerialDevTempate as no remaining device path was
    555555  // passed in.
     
    557557  if (RemainingDevicePath != NULL) {
    558558    //
    559     // If RemainingDevicePath isn't NULL, 
     559    // If RemainingDevicePath isn't NULL,
    560560    // match the configuration of the RemainingDevicePath. IsHandleSupported()
    561561    // already checked to make sure the RemainingDevicePath contains settings
     
    578578    }
    579579  }
    580  
     580
    581581  SerialDevice->HardwareFlowControl = (BOOLEAN) (FlowControlMap == UART_FLOW_CONTROL_HARDWARE);
    582582
     
    602602  //
    603603  // Build the device path by appending the UART node to the ParentDevicePath.
    604   // The Uart setings are zero here, since  SetAttribute() will update them to match 
     604  // The Uart setings are zero here, since  SetAttribute() will update them to match
    605605  // the default setings.
    606606  //
     
    854854/**
    855855  Detect whether specific FIFO is empty or not.
    856  
     856
    857857  @param  Fifo    A pointer to the Data Structure SERIAL_DEV_FIFO
    858858
     
    10231023
    10241024          IsaSerialFifoAdd (&SerialDevice->Receive, Data);
    1025          
     1025
    10261026          //
    10271027          // For full handshake flow control, if receive buffer full
     
    15721572  //
    15731573  if ((Control & (~(EFI_SERIAL_REQUEST_TO_SEND | EFI_SERIAL_DATA_TERMINAL_READY |
    1574                     EFI_SERIAL_HARDWARE_LOOPBACK_ENABLE | EFI_SERIAL_SOFTWARE_LOOPBACK_ENABLE | 
     1574                    EFI_SERIAL_HARDWARE_LOOPBACK_ENABLE | EFI_SERIAL_SOFTWARE_LOOPBACK_ENABLE |
    15751575                    EFI_SERIAL_HARDWARE_FLOW_CONTROL_ENABLE))) != 0) {
    15761576    return EFI_UNSUPPORTED;
     
    17841784  // Compute the number of bits in a single character.  This is a start bit,
    17851785  // followed by the number of data bits, followed by the number of stop bits.
    1786   // The number of stop bits is specified by an enumeration that includes 
     1786  // The number of stop bits is specified by an enumeration that includes
    17871787  // support for 1.5 stop bits.  Treat 1.5 stop bits as 2 stop bits.
    17881788  //
    1789   BitsPerCharacter = 
    1790     1 + 
    1791     This->Mode->DataBits + 
     1789  BitsPerCharacter =
     1790    1 +
     1791    This->Mode->DataBits +
    17921792    ((This->Mode->StopBits == TwoStopBits) ? 2 : This->Mode->StopBits);
    17931793
    17941794  //
    1795   // Compute the timeout in microseconds to wait for a single byte to be 
    1796   // transmitted.  The Mode structure contans a Timeout field that is the 
    1797   // maximum time to transmit or receive a character.  However, many UARTs 
     1795  // Compute the timeout in microseconds to wait for a single byte to be
     1796  // transmitted.  The Mode structure contans a Timeout field that is the
     1797  // maximum time to transmit or receive a character.  However, many UARTs
    17981798  // have a FIFO for transmits, so the time required to add one new character
    1799   // to the transmit FIFO may be the time required to flush a full FIFO.  If 
     1799  // to the transmit FIFO may be the time required to flush a full FIFO.  If
    18001800  // the Timeout in the Mode structure is smaller than the time required to
    18011801  // flush a full FIFO at the current baud rate, then use a timeout value that
     
    18101810                )
    18111811              );
    1812  
     1812
    18131813  for (Index = 0; Index < *BufferSize; Index++) {
    18141814    IsaSerialFifoAdd (&SerialDevice->Transmit, CharBuffer[Index]);
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/IsaSerialDxe/Serial.h

    r48674 r58466  
    11/** @file
    22  Include for Serial Driver
    3  
     3
    44Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
    55This program and the accompanying materials
     
    610610/**
    611611  Detect whether specific FIFO is empty or not.
    612  
     612
    613613  @param  Fifo    A pointer to the Data Structure SERIAL_DEV_FIFO
    614614
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/ComponentName.c

    r48674 r58466  
    11/** @file
    22  Routines related Component Name protocol.
    3  
     3
    44Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
    55This program and the accompanying materials
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KbdCtrller.c

    r58459 r58466  
    15601560        goto Done;
    15611561      }
    1562      
     1562
    15631563      Status = KeyboardRead (ConsoleIn, &CommandByte);
    15641564      if (EFI_ERROR (Status)) {
     
    15761576    } else {
    15771577      mEnableMouseInterface = FALSE;
    1578     } 
     1578    }
    15791579  } else {
    15801580    //
     
    15921592        goto Done;
    15931593      }
    1594      
     1594
    15951595      Status = KeyboardCommand (ConsoleIn, KEYBOARD_8042_COMMAND_DISABLE_MOUSE_INTERFACE);
    15961596      if (EFI_ERROR (Status)) {
     
    15981598        goto Done;
    15991599      }
    1600      
     1600
    16011601      REPORT_STATUS_CODE_WITH_DEVICE_PATH (
    16021602        EFI_PROGRESS_CODE,
     
    16121612        goto Done;
    16131613      }
    1614      
     1614
    16151615      Status = KeyboardWaitForValue (ConsoleIn, 0x55);
    16161616      if (EFI_ERROR (Status)) {
     
    18821882               KEYBOARD_KBEN
    18831883               );
    1884    
     1884
    18851885    if (EFI_ERROR (Status)) {
    18861886      return FALSE;
     
    18961896               );
    18971897    mWaitForValueTimeOut = WaitForValueTimeOutBcakup;
    1898    
     1898
    18991899    if (EFI_ERROR (Status)) {
    19001900      return FALSE;
    19011901    }
    1902    
     1902
    19031903    return TRUE;
    19041904  } else {
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2KbdTextIn.c

    r58459 r58466  
    269269
    270270  ConsoleIn = KEYBOARD_CONSOLE_IN_DEV_FROM_THIS (This);
    271  
     271
    272272  //
    273273  // Considering if the partial keystroke is enabled, there maybe a partial
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2Keyboard.c

    r58459 r58466  
    2222/**
    2323  Test controller is a keyboard Controller.
    24  
     24
    2525  @param This                 Pointer of EFI_DRIVER_BINDING_PROTOCOL
    2626  @param Controller           driver's controller
    2727  @param RemainingDevicePath  children device path
    28  
     28
    2929  @retval EFI_UNSUPPORTED controller is not floppy disk
    3030  @retval EFI_SUCCESS     controller is floppy disk
     
    4040/**
    4141  Create KEYBOARD_CONSOLE_IN_DEV instance on controller.
    42  
     42
    4343  @param This         Pointer of EFI_DRIVER_BINDING_PROTOCOL
    4444  @param Controller   driver controller handle
    4545  @param RemainingDevicePath Children's device path
    46  
     46
    4747  @retval whether success to create floppy control instance.
    4848**/
     
    8080/**
    8181  Free the waiting key notify list.
    82  
     82
    8383  @param ListHead  Pointer to list head
    84  
     84
    8585  @retval EFI_INVALID_PARAMETER  ListHead is NULL
    8686  @retval EFI_SUCCESS            Sucess to free NotifyList
     
    8989KbdFreeNotifyList (
    9090  IN OUT LIST_ENTRY           *ListHead
    91   ); 
     91  );
    9292
    9393//
     
    105105/**
    106106  Test controller is a keyboard Controller.
    107  
     107
    108108  @param This                 Pointer of EFI_DRIVER_BINDING_PROTOCOL
    109109  @param Controller           driver's controller
    110110  @param RemainingDevicePath  children device path
    111  
     111
    112112  @retval EFI_UNSUPPORTED controller is not floppy disk
    113113  @retval EFI_SUCCESS     controller is floppy disk
     
    159159/**
    160160  Create KEYBOARD_CONSOLE_IN_DEV instance on controller.
    161  
     161
    162162  @param This         Pointer of EFI_DRIVER_BINDING_PROTOCOL
    163163  @param Controller   driver controller handle
    164164  @param RemainingDevicePath Children's device path
    165  
     165
    166166  @retval whether success to create floppy control instance.
    167167**/
     
    250250  ConsoleIn->ConInEx.SetState            = KeyboardSetState;
    251251  ConsoleIn->ConInEx.RegisterKeyNotify   = KeyboardRegisterKeyNotify;
    252   ConsoleIn->ConInEx.UnregisterKeyNotify = KeyboardUnregisterKeyNotify; 
    253  
     252  ConsoleIn->ConInEx.UnregisterKeyNotify = KeyboardUnregisterKeyNotify;
     253
    254254  InitializeListHead (&ConsoleIn->NotifyList);
    255255
    256256  //
    257257  // Fix for random hangs in System waiting for the Key if no KBC is present in BIOS.
    258   // When KBC decode (IO port 0x60/0x64 decode) is not enabled, 
     258  // When KBC decode (IO port 0x60/0x64 decode) is not enabled,
    259259  // KeyboardRead will read back as 0xFF and return status is EFI_SUCCESS.
    260260  // So instead we read status register to detect after read if KBC decode is enabled.
    261261  //
    262  
     262
    263263  //
    264264  // Return code is ignored on purpose.
     
    276276    }
    277277  }
    278  
     278
    279279  //
    280280  // Setup the WaitForKey event
     
    294294  //
    295295  // Setup the WaitForKeyEx event
    296   // 
     296  //
    297297  Status = gBS->CreateEvent (
    298298                  EVT_NOTIFY_WAIT,
     
    426426    }
    427427  }
    428  
     428
    429429  if (ConsoleIn != NULL) {
    430430    gBS->FreePool (ConsoleIn);
     
    501501    return Status;
    502502  }
    503  
     503
    504504  ConsoleIn = KEYBOARD_CONSOLE_IN_DEV_FROM_THIS (ConIn);
    505505
     
    575575/**
    576576  Free the waiting key notify list.
    577  
     577
    578578  @param ListHead  Pointer to list head
    579  
     579
    580580  @retval EFI_INVALID_PARAMETER  ListHead is NULL
    581581  @retval EFI_SUCCESS            Sucess to free NotifyList
     
    593593  while (!IsListEmpty (ListHead)) {
    594594    NotifyNode = CR (
    595                    ListHead->ForwardLink, 
    596                    KEYBOARD_CONSOLE_IN_EX_NOTIFY, 
    597                    NotifyEntry, 
     595                   ListHead->ForwardLink,
     596                   KEYBOARD_CONSOLE_IN_EX_NOTIFY,
     597                   NotifyEntry,
    598598                   KEYBOARD_CONSOLE_IN_EX_NOTIFY_SIGNATURE
    599599                   );
     
    601601    gBS->FreePool (NotifyNode);
    602602  }
    603  
     603
    604604  return EFI_SUCCESS;
    605605}
    606606
    607607/**
    608   The module Entry Point for module Ps2Keyboard. 
    609 
    610   @param[in] ImageHandle    The firmware allocated handle for the EFI image. 
     608  The module Entry Point for module Ps2Keyboard.
     609
     610  @param[in] ImageHandle    The firmware allocated handle for the EFI image.
    611611  @param[in] SystemTable    A pointer to the EFI System Table.
    612  
     612
    613613  @retval EFI_SUCCESS       The entry point is executed successfully.
    614614  @retval other             Some error occurs when executing this entry point.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/Ps2KeyboardDxe/Ps2keyboardDxe.inf

    r58459 r58466  
    5959  TimerLib
    6060  PcdLib
    61  
     61
    6262[Protocols]
    6363  gEfiSimpleTextInProtocolGuid                  ## BY_START
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/CommPs2.c

    r48674 r58466  
    11/** @file
    22  PS2 Mouse Communication Interface.
    3  
     3
    44Copyright (c) 2006 - 2007, Intel Corporation. All rights reserved.<BR>
    55This program and the accompanying materials
     
    2222/**
    2323  Issue self test command via IsaIo interface.
    24  
     24
    2525  @param IsaIo Pointer to instance of EFI_ISA_IO_PROTOCOL
    26  
     26
    2727  @return EFI_SUCCESS  Success to do keyboard self testing.
    2828  @return others       Fail to do keyboard self testing.
     
    8383/**
    8484  Issue command to enable keyboard AUX functionality.
    85  
     85
    8686  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    87  
     87
    8888  @return Status of command issuing.
    8989**/
     
    101101/**
    102102  Issue command to disable keyboard AUX functionality.
    103  
     103
    104104  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    105  
     105
    106106  @return Status of command issuing.
    107107**/
     
    119119/**
    120120  Issue command to enable keyboard.
    121  
     121
    122122  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    123  
     123
    124124  @return Status of command issuing.
    125125**/
     
    137137/**
    138138  Issue command to disable keyboard.
    139  
     139
    140140  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    141  
     141
    142142  @return Status of command issuing.
    143143**/
     
    155155/**
    156156  Issue command to check keyboard status.
    157  
     157
    158158  @param IsaIo          Pointer to instance of EFI_ISA_IO_PROTOCOL
    159159  @param KeyboardEnable return whether keyboard is enable.
    160  
     160
    161161  @return Status of command issuing.
    162162**/
     
    196196/**
    197197  Issue command to reset keyboard.
    198  
     198
    199199  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    200  
     200
    201201  @return Status of command issuing.
    202202**/
     
    241241/**
    242242  Issue command to set mouse's sample rate
    243  
     243
    244244  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    245   @param SampleRate value of sample rate 
    246  
     245  @param SampleRate value of sample rate
     246
    247247  @return Status of command issuing.
    248248**/
     
    270270/**
    271271  Issue command to set mouse's resolution.
    272  
     272
    273273  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    274274  @param Resolution value of resolution
    275  
     275
    276276  @return Status of command issuing.
    277277**/
     
    299299/**
    300300  Issue command to set mouse's scaling.
    301  
     301
    302302  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    303303  @param Scaling value of scaling
    304  
     304
    305305  @return Status of command issuing.
    306306**/
     
    323323/**
    324324  Issue command to enable Ps2 mouse.
    325  
     325
    326326  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    327  
     327
    328328  @return Status of command issuing.
    329329**/
     
    342342  Get mouse packet . Only care first 3 bytes
    343343
    344   @param MouseAbsolutePointerDev  Pointer to PS2 Absolute Pointer Simulation Device Private Data Structure 
     344  @param MouseAbsolutePointerDev  Pointer to PS2 Absolute Pointer Simulation Device Private Data Structure
    345345
    346346  @retval EFI_NOT_READY  Mouse Device not ready to input data packet, or some error happened during getting the packet
     
    433433      RelativeMovementY = Packet[2];
    434434      //
    435       //               Bit 7   |    Bit 6   |    Bit 5   |   Bit 4    |   Bit 3  |   Bit 2    |   Bit 1   |   Bit 0 
    436       //  Byte 0  | Y overflow | X overflow | Y sign bit | X sign bit | Always 1 | Middle Btn | Right Btn | Left Btn 
    437       //  Byte 1  |                                           8 bit X Movement 
    438       //  Byte 2  |                                           8 bit Y Movement 
    439       // 
     435      //               Bit 7   |    Bit 6   |    Bit 5   |   Bit 4    |   Bit 3  |   Bit 2    |   Bit 1   |   Bit 0
     436      //  Byte 0  | Y overflow | X overflow | Y sign bit | X sign bit | Always 1 | Middle Btn | Right Btn | Left Btn
     437      //  Byte 1  |                                           8 bit X Movement
     438      //  Byte 2  |                                           8 bit Y Movement
     439      //
    440440      // X sign bit + 8 bit X Movement : 9-bit signed twos complement integer that presents the relative displacement of the device in the X direction since the last data transmission.
    441441      // Y sign bit + 8 bit Y Movement : Same as X sign bit + 8 bit X Movement.
     
    444444      // First, Clear X and Y high 8 bits
    445445      //
    446       RelativeMovementX = (INT16) (RelativeMovementX & 0xFF); 
    447       RelativeMovementY = (INT16) (RelativeMovementY & 0xFF); 
     446      RelativeMovementX = (INT16) (RelativeMovementX & 0xFF);
     447      RelativeMovementY = (INT16) (RelativeMovementY & 0xFF);
    448448      //
    449449      // Second, if the 9-bit signed twos complement integer is negative, set the high 8 bit 0xff
     
    456456      }
    457457
    458      
     458
    459459      RButton           = (UINT8) (Packet[0] & 0x2);
    460460      LButton           = (UINT8) (Packet[0] & 0x1);
     
    476476/**
    477477  Read data via IsaIo protocol with given number.
    478  
     478
    479479  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    480480  @param Buffer  Buffer receive data of mouse
    481481  @param BufSize The size of buffer
    482482  @param State   Check input or read data
    483  
     483
    484484  @return status of reading mouse data.
    485485**/
     
    537537/**
    538538  I/O work flow of outing 8042 command.
    539  
     539
    540540  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    541541  @param Command I/O command.
    542  
     542
    543543  @retval EFI_SUCCESS Success to excute I/O work flow
    544544  @retval EFI_TIMEOUT Keyboard controller time out.
     
    576576/**
    577577  I/O work flow of outing 8042 data.
    578  
     578
    579579  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    580580  @param Data    Data value
    581  
     581
    582582  @retval EFI_SUCCESS Success to excute I/O work flow
    583583  @retval EFI_TIMEOUT Keyboard controller time out.
     
    612612/**
    613613  I/O work flow of in 8042 data.
    614  
     614
    615615  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    616616  @param Data    Data value
    617  
     617
    618618  @retval EFI_SUCCESS Success to excute I/O work flow
    619619  @retval EFI_TIMEOUT Keyboard controller time out.
     
    655655/**
    656656  I/O work flow of outing 8042 Aux command.
    657  
     657
    658658  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    659659  @param Command Aux I/O command
    660660  @param Resend  Whether need resend the Aux command.
    661  
     661
    662662  @retval EFI_SUCCESS Success to excute I/O work flow
    663663  @retval EFI_TIMEOUT Keyboard controller time out.
     
    737737/**
    738738  I/O work flow of outing 8042 Aux data.
    739  
     739
    740740  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    741   @param Data    Buffer holding return value 
    742  
     741  @param Data    Buffer holding return value
     742
    743743  @retval EFI_SUCCESS Success to excute I/O work flow.
    744744  @retval EFI_TIMEOUT Keyboard controller time out.
     
    783783/**
    784784  I/O work flow of in 8042 Aux data.
    785  
     785
    786786  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    787787  @param Data    Buffer holding return value.
    788  
     788
    789789  @retval EFI_SUCCESS Success to excute I/O work flow
    790790  @retval EFI_TIMEOUT Keyboard controller time out.
     
    814814/**
    815815  Check keyboard controller status, if it is output buffer full and for auxiliary device.
    816  
     816
    817817  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    818  
     818
    819819  @retval EFI_SUCCESS   Keyboard controller is ready
    820820  @retval EFI_NOT_READY Keyboard controller is not ready
     
    841841/**
    842842  I/O work flow to wait input buffer empty in given time.
    843  
     843
    844844  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    845845  @param Timeout Wating time.
    846  
     846
    847847  @retval EFI_TIMEOUT if input is still not empty in given time.
    848848  @retval EFI_SUCCESS input is empty.
     
    882882/**
    883883  I/O work flow to wait output buffer full in given time.
    884  
     884
    885885  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    886886  @param Timeout given time
    887  
     887
    888888  @retval EFI_TIMEOUT  output is not full in given time
    889889  @retval EFI_SUCCESS  output is full in given time.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/CommPs2.h

    r48674 r58466  
    11/** @file
    22  Using PS2 Mouse to simulation Absolution Pointer Device.
    3  
     3
    44Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
    55This program and the accompanying materials
     
    7979/// Parity Error
    8080///
    81 #define KBC_PARE  0x80 
     81#define KBC_PARE  0x80
    8282///
    8383/// General Time Out
    8484///
    85 #define KBC_TIM   0x40 
     85#define KBC_TIM   0x40
    8686///
    8787/// Output buffer for auxiliary device (PS/2):
     
    8989///    1 - Holds data for auxiliary device
    9090///
    91 #define KBC_AUXB  0x20 
     91#define KBC_AUXB  0x20
    9292///
    9393/// Keyboard lock status:
     
    9595///    1 - keyboard free
    9696///
    97 #define KBC_KEYL  0x10 
     97#define KBC_KEYL  0x10
    9898///
    9999/// Command/Data:
     
    107107///    1 - self-test successful
    108108///
    109 #define KBC_SYSF  0x04 
     109#define KBC_SYSF  0x04
    110110///
    111111/// Input Buffer Status :
     
    113113///    1 - CPU data in input buffer
    114114///
    115 #define KBC_INPB  0x02 
     115#define KBC_INPB  0x02
    116116///
    117117/// Output Buffer Status :
     
    119119///    1 - keyboard controller data in output buffer
    120120///
    121 #define KBC_OUTB  0x01 
     121#define KBC_OUTB  0x01
    122122
    123123/**
    124124  Issue self test command via IsaIo interface.
    125  
     125
    126126  @param IsaIo Pointer to instance of EFI_ISA_IO_PROTOCOL
    127  
     127
    128128  @return EFI_SUCCESS  Success to do keyboard self testing.
    129129  @return others       Fail to do keyboard self testing.
     
    136136/**
    137137  Issue command to enable keyboard AUX functionality.
    138  
    139   @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    140  
     138
     139  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
     140
    141141  @return Status of command issuing.
    142142**/
     
    148148/**
    149149  Issue command to disable keyboard AUX functionality.
    150  
    151   @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    152  
     150
     151  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
     152
    153153  @return Status of command issuing.
    154154**/
     
    160160/**
    161161  Issue command to enable keyboard.
    162  
    163   @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    164  
     162
     163  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
     164
    165165  @return Status of command issuing.
    166166**/
     
    172172/**
    173173  Issue command to disable keyboard.
    174  
    175   @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    176  
     174
     175  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
     176
    177177  @return Status of command issuing.
    178178**/
     
    184184/**
    185185  Issue command to check keyboard status.
    186  
     186
    187187  @param IsaIo          Pointer to instance of EFI_ISA_IO_PROTOCOL
    188188  @param KeyboardEnable return whether keyboard is enable.
    189  
     189
    190190  @return Status of command issuing.
    191191**/
     
    198198/**
    199199  Issue command to reset keyboard.
    200  
    201   @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    202  
     200
     201  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
     202
    203203  @return Status of command issuing.
    204204**/
     
    210210/**
    211211  Issue command to set mouse's sample rate
    212  
    213   @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    214   @param SampleRate value of sample rate 
    215  
     212
     213  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
     214  @param SampleRate value of sample rate
     215
    216216  @return Status of command issuing.
    217217**/
     
    224224/**
    225225  Issue command to set mouse's resolution.
    226  
     226
    227227  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    228228  @param Resolution value of resolution
    229  
     229
    230230  @return Status of command issuing.
    231231**/
     
    238238/**
    239239  Issue command to set mouse's scaling.
    240  
     240
    241241  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    242242  @param Scaling value of scaling
    243  
     243
    244244  @return Status of command issuing.
    245245**/
     
    252252/**
    253253  Issue command to enable Ps2 mouse.
    254  
    255   @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    256  
     254
     255  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
     256
    257257  @return Status of command issuing.
    258258**/
     
    278278/**
    279279  Read data via IsaIo protocol with given number.
    280  
     280
    281281  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    282282  @param Buffer  Buffer receive data of mouse
    283283  @param BufSize The size of buffer
    284284  @param State   Check input or read data
    285  
     285
    286286  @return status of reading mouse data.
    287287**/
     
    299299/**
    300300  I/O work flow of outing 8042 command.
    301  
     301
    302302  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    303303  @param Command I/O command.
    304  
     304
    305305  @retval EFI_SUCCESS Success to excute I/O work flow
    306306  @retval EFI_TIMEOUT Keyboard controller time out.
     
    314314/**
    315315  I/O work flow of in 8042 data.
    316  
     316
    317317  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    318318  @param Data    Data value
    319  
     319
    320320  @retval EFI_SUCCESS Success to excute I/O work flow
    321321  @retval EFI_TIMEOUT Keyboard controller time out.
     
    329329/**
    330330  I/O work flow of outing 8042 data.
    331  
     331
    332332  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    333333  @param Data    Data value
    334  
     334
    335335  @retval EFI_SUCCESS Success to excute I/O work flow
    336336  @retval EFI_TIMEOUT Keyboard controller time out.
     
    344344/**
    345345  I/O work flow of outing 8042 Aux command.
    346  
     346
    347347  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    348348  @param Command Aux I/O command
    349349  @param Resend  Whether need resend the Aux command.
    350  
     350
    351351  @retval EFI_SUCCESS Success to excute I/O work flow
    352352  @retval EFI_TIMEOUT Keyboard controller time out.
     
    361361/**
    362362  I/O work flow of in 8042 Aux data.
    363  
     363
    364364  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    365365  @param Data    Buffer holding return value.
    366  
     366
    367367  @retval EFI_SUCCESS Success to excute I/O work flow
    368368  @retval EFI_TIMEOUT Keyboard controller time out.
     
    376376/**
    377377  I/O work flow of outing 8042 Aux data.
    378  
     378
    379379  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    380380  @param Data    Buffer holding return value.
    381  
     381
    382382  @retval EFI_SUCCESS Success to excute I/O work flow
    383383  @retval EFI_TIMEOUT Keyboard controller time out.
     
    391391/**
    392392  Check keyboard controller status, if it is output buffer full and for auxiliary device.
    393  
    394   @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    395  
     393
     394  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
     395
    396396  @retval EFI_SUCCESS   Keyboard controller is ready
    397397  @retval EFI_NOT_READY Keyboard controller is not ready
     
    404404/**
    405405  I/O work flow to wait input buffer empty in given time.
    406  
     406
    407407  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    408408  @param Timeout Wating time.
    409  
     409
    410410  @retval EFI_TIMEOUT if input is still not empty in given time.
    411411  @retval EFI_SUCCESS input is empty.
     
    419419/**
    420420  I/O work flow to wait output buffer full in given time.
    421  
     421
    422422  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    423423  @param Timeout given time
    424  
     424
    425425  @retval EFI_TIMEOUT  output is not full in given time
    426426  @retval EFI_SUCCESS  output is full in given time.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/Ps2MouseAbsolutePointer.c

    r58459 r58466  
    22  A faked PS/2 Absolute Pointer driver. Routines that interacts with callers,
    33  conforming to EFI driver model
    4  
     4
    55Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
    66This program and the accompanying materials
     
    231231  // Initialize keyboard controller if necessary
    232232  //
    233   REPORT_STATUS_CODE_WITH_DEVICE_PATH ( 
     233  REPORT_STATUS_CODE_WITH_DEVICE_PATH (
    234234    EFI_PROGRESS_CODE,
    235235    EFI_PERIPHERAL_MOUSE | EFI_P_MOUSE_PC_SELF_TEST,
     
    641641/**
    642642  Get and Clear mouse status.
    643  
     643
    644644  @param This                 - Pointer of simple pointer Protocol.
    645645  @param State                - Output buffer holding status.
     
    744744  The user Entry Point for module Ps2MouseAbsolutePointer. The user code starts with this function.
    745745
    746   @param[in] ImageHandle    The firmware allocated handle for the EFI image. 
     746  @param[in] ImageHandle    The firmware allocated handle for the EFI image.
    747747  @param[in] SystemTable    A pointer to the EFI System Table.
    748  
     748
    749749  @retval EFI_SUCCESS       The entry point is executed successfully.
    750750  @retval other             Some error occurs when executing this entry point.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseAbsolutePointerDxe/Ps2MouseAbsolutePointer.h

    r48674 r58466  
    11/** @file
    22  A Ps2MouseAbsolutePointer driver header file
    3  
     3
    44Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
    55This program and the accompanying materials
     
    323323/**
    324324  Get and Clear mouse status.
    325  
     325
    326326  @param This                 - Pointer of simple pointer Protocol.
    327327  @param State                - Output buffer holding status.
     
    371371/**
    372372  I/O work flow of in 8042 data.
    373  
     373
    374374  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    375375  @param Data    Data value
    376  
     376
    377377  @retval EFI_SUCCESS Success to excute I/O work flow
    378378  @retval EFI_TIMEOUT Keyboard controller time out.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseDxe/CommPs2.c

    r48674 r58466  
    11/** @file
    22  PS2 Mouse Communication Interface.
    3  
     3
    44Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
    55This program and the accompanying materials
     
    2222/**
    2323  Issue self test command via IsaIo interface.
    24  
     24
    2525  @param IsaIo Pointer to instance of EFI_ISA_IO_PROTOCOL
    26  
     26
    2727  @return EFI_SUCCESS  Success to do keyboard self testing.
    2828  @return others       Fail to do keyboard self testing.
     
    8383/**
    8484  Issue command to enable keyboard AUX functionality.
    85  
     85
    8686  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    87  
     87
    8888  @return Status of command issuing.
    8989**/
     
    101101/**
    102102  Issue command to disable keyboard AUX functionality.
    103  
     103
    104104  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    105  
     105
    106106  @return Status of command issuing.
    107107**/
     
    119119/**
    120120  Issue command to enable keyboard.
    121  
     121
    122122  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    123  
     123
    124124  @return Status of command issuing.
    125125**/
     
    137137/**
    138138  Issue command to disable keyboard.
    139  
     139
    140140  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    141  
     141
    142142  @return Status of command issuing.
    143143**/
     
    155155/**
    156156  Issue command to check keyboard status.
    157  
     157
    158158  @param IsaIo          Pointer to instance of EFI_ISA_IO_PROTOCOL
    159159  @param KeyboardEnable return whether keyboard is enable.
    160  
     160
    161161  @return Status of command issuing.
    162162**/
     
    196196/**
    197197  Issue command to reset keyboard.
    198  
     198
    199199  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    200  
     200
    201201  @return Status of command issuing.
    202202**/
     
    241241/**
    242242  Issue command to set mouse's sample rate
    243  
     243
    244244  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    245   @param SampleRate value of sample rate 
    246  
     245  @param SampleRate value of sample rate
     246
    247247  @return Status of command issuing.
    248248**/
     
    270270/**
    271271  Issue command to set mouse's resolution.
    272  
     272
    273273  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    274274  @param Resolution value of resolution
    275  
     275
    276276  @return Status of command issuing.
    277277**/
     
    299299/**
    300300  Issue command to set mouse's scaling.
    301  
     301
    302302  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    303303  @param Scaling value of scaling
    304  
     304
    305305  @return Status of command issuing.
    306306**/
     
    323323/**
    324324  Issue command to enable Ps2 mouse.
    325  
     325
    326326  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    327  
     327
    328328  @return Status of command issuing.
    329329**/
     
    342342  Get mouse packet . Only care first 3 bytes
    343343
    344   @param MouseDev  Pointer of PS2 Mouse Private Data Structure 
     344  @param MouseDev  Pointer of PS2 Mouse Private Data Structure
    345345
    346346  @retval EFI_NOT_READY  Mouse Device not ready to input data packet, or some error happened during getting the packet
     
    433433      RelativeMovementY = Packet[2];
    434434      //
    435       //               Bit 7   |    Bit 6   |    Bit 5   |   Bit 4    |   Bit 3  |   Bit 2    |   Bit 1   |   Bit 0 
    436       //  Byte 0  | Y overflow | X overflow | Y sign bit | X sign bit | Always 1 | Middle Btn | Right Btn | Left Btn 
    437       //  Byte 1  |                                           8 bit X Movement 
    438       //  Byte 2  |                                           8 bit Y Movement 
    439       // 
     435      //               Bit 7   |    Bit 6   |    Bit 5   |   Bit 4    |   Bit 3  |   Bit 2    |   Bit 1   |   Bit 0
     436      //  Byte 0  | Y overflow | X overflow | Y sign bit | X sign bit | Always 1 | Middle Btn | Right Btn | Left Btn
     437      //  Byte 1  |                                           8 bit X Movement
     438      //  Byte 2  |                                           8 bit Y Movement
     439      //
    440440      // X sign bit + 8 bit X Movement : 9-bit signed twos complement integer that presents the relative displacement of the device in the X direction since the last data transmission.
    441441      // Y sign bit + 8 bit Y Movement : Same as X sign bit + 8 bit X Movement.
     
    444444      // First, Clear X and Y high 8 bits
    445445      //
    446       RelativeMovementX = (INT16) (RelativeMovementX & 0xFF); 
    447       RelativeMovementY = (INT16) (RelativeMovementY & 0xFF); 
     446      RelativeMovementX = (INT16) (RelativeMovementX & 0xFF);
     447      RelativeMovementY = (INT16) (RelativeMovementY & 0xFF);
    448448      //
    449449      // Second, if the 9-bit signed twos complement integer is negative, set the high 8 bit 0xff
     
    456456      }
    457457
    458      
     458
    459459      RButton           = (UINT8) (Packet[0] & 0x2);
    460460      LButton           = (UINT8) (Packet[0] & 0x1);
     
    476476/**
    477477  Read data via IsaIo protocol with given number.
    478  
     478
    479479  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    480480  @param Buffer  Buffer receive data of mouse
    481481  @param BufSize The size of buffer
    482482  @param State   Check input or read data
    483  
     483
    484484  @return status of reading mouse data.
    485485**/
     
    536536/**
    537537  I/O work flow of outing 8042 command.
    538  
     538
    539539  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    540540  @param Command I/O command.
    541  
     541
    542542  @retval EFI_SUCCESS Success to excute I/O work flow
    543543  @retval EFI_TIMEOUT Keyboard controller time out.
     
    575575/**
    576576  I/O work flow of outing 8042 data.
    577  
     577
    578578  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    579579  @param Data    Data value
    580  
     580
    581581  @retval EFI_SUCCESS Success to excute I/O work flow
    582582  @retval EFI_TIMEOUT Keyboard controller time out.
     
    611611/**
    612612  I/O work flow of in 8042 data.
    613  
     613
    614614  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    615615  @param Data    Data value
    616  
     616
    617617  @retval EFI_SUCCESS Success to excute I/O work flow
    618618  @retval EFI_TIMEOUT Keyboard controller time out.
     
    654654/**
    655655  I/O work flow of outing 8042 Aux command.
    656  
     656
    657657  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    658658  @param Command Aux I/O command
    659659  @param Resend  Whether need resend the Aux command.
    660  
     660
    661661  @retval EFI_SUCCESS Success to excute I/O work flow
    662662  @retval EFI_TIMEOUT Keyboard controller time out.
     
    736736/**
    737737  I/O work flow of outing 8042 Aux data.
    738  
     738
    739739  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    740740  @param Data    Buffer holding return value
    741  
     741
    742742  @retval EFI_SUCCESS Success to excute I/O work flow
    743743  @retval EFI_TIMEOUT Keyboard controller time out.
     
    782782/**
    783783  I/O work flow of in 8042 Aux data.
    784  
     784
    785785  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    786786  @param Data    Buffer holding return value.
    787  
     787
    788788  @retval EFI_SUCCESS Success to excute I/O work flow
    789789  @retval EFI_TIMEOUT Keyboard controller time out.
     
    813813/**
    814814  Check keyboard controller status, if it is output buffer full and for auxiliary device.
    815  
     815
    816816  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    817  
     817
    818818  @retval EFI_SUCCESS   Keyboard controller is ready
    819819  @retval EFI_NOT_READY Keyboard controller is not ready
     
    840840/**
    841841  I/O work flow to wait input buffer empty in given time.
    842  
     842
    843843  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    844844  @param Timeout Wating time.
    845  
     845
    846846  @retval EFI_TIMEOUT if input is still not empty in given time.
    847847  @retval EFI_SUCCESS input is empty.
     
    881881/**
    882882  I/O work flow to wait output buffer full in given time.
    883  
     883
    884884  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    885885  @param Timeout given time
    886  
     886
    887887  @retval EFI_TIMEOUT  output is not full in given time
    888888  @retval EFI_SUCCESS  output is full in given time.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseDxe/CommPs2.h

    r48674 r58466  
    11/** @file
    2   PS2 Mouse Communication Interface 
     2  PS2 Mouse Communication Interface
    33
    44Copyright (c) 2006 - 2007, Intel Corporation. All rights reserved.<BR>
     
    7979/// Parity Error
    8080///
    81 #define KBC_PARE  0x80 
     81#define KBC_PARE  0x80
    8282///
    8383/// General Time Out
    8484///
    85 #define KBC_TIM   0x40 
     85#define KBC_TIM   0x40
    8686///
    8787/// Output buffer for auxiliary device (PS/2):
     
    8989///    1 - Holds data for auxiliary device
    9090///
    91 #define KBC_AUXB  0x20 
     91#define KBC_AUXB  0x20
    9292///
    9393/// Keyboard lock status:
     
    9595///    1 - keyboard free
    9696///
    97 #define KBC_KEYL  0x10 
     97#define KBC_KEYL  0x10
    9898///
    9999/// Command/Data:
     
    107107///    1 - self-test successful
    108108///
    109 #define KBC_SYSF  0x04 
     109#define KBC_SYSF  0x04
    110110///
    111111/// Input Buffer Status :
     
    113113///    1 - CPU data in input buffer
    114114///
    115 #define KBC_INPB  0x02 
     115#define KBC_INPB  0x02
    116116///
    117117/// Output Buffer Status :
     
    119119///    1 - keyboard controller data in output buffer
    120120///
    121 #define KBC_OUTB  0x01 
     121#define KBC_OUTB  0x01
    122122
    123123/**
    124124  Issue self test command via IsaIo interface.
    125  
     125
    126126  @param IsaIo Pointer to instance of EFI_ISA_IO_PROTOCOL
    127  
     127
    128128  @return EFI_SUCCESS  Success to do keyboard self testing.
    129129  @return others       Fail to do keyboard self testing.
     
    136136/**
    137137  Issue command to enable keyboard AUX functionality.
    138  
    139   @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    140  
     138
     139  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
     140
    141141  @return Status of command issuing.
    142142**/
     
    148148/**
    149149  Issue command to disable keyboard AUX functionality.
    150  
    151   @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    152  
     150
     151  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
     152
    153153  @return Status of command issuing.
    154154**/
     
    160160/**
    161161  Issue command to enable keyboard.
    162  
    163   @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    164  
     162
     163  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
     164
    165165  @return Status of command issuing.
    166166**/
     
    172172/**
    173173  Issue command to disable keyboard.
    174  
    175   @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    176  
     174
     175  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
     176
    177177  @return Status of command issuing.
    178178**/
     
    184184/**
    185185  Issue command to check keyboard status.
    186  
     186
    187187  @param IsaIo          Pointer to instance of EFI_ISA_IO_PROTOCOL
    188188  @param KeyboardEnable return whether keyboard is enable.
    189  
     189
    190190  @return Status of command issuing.
    191191**/
     
    198198/**
    199199  Issue command to reset keyboard.
    200  
    201   @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    202  
     200
     201  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
     202
    203203  @return Status of command issuing.
    204204**/
     
    210210/**
    211211  Issue command to set mouse's sample rate
    212  
    213   @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    214   @param SampleRate value of sample rate 
    215  
     212
     213  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
     214  @param SampleRate value of sample rate
     215
    216216  @return Status of command issuing.
    217217**/
     
    224224/**
    225225  Issue command to set mouse's resolution.
    226  
     226
    227227  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    228228  @param Resolution value of resolution
    229  
     229
    230230  @return Status of command issuing.
    231231**/
     
    238238/**
    239239  Issue command to set mouse's scaling.
    240  
     240
    241241  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    242242  @param Scaling value of scaling
    243  
     243
    244244  @return Status of command issuing.
    245245**/
     
    252252/**
    253253  Issue command to enable Ps2 mouse.
    254  
    255   @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
    256  
     254
     255  @param IsaIo  Pointer to instance of EFI_ISA_IO_PROTOCOL
     256
    257257  @return Status of command issuing.
    258258**/
     
    265265  Get mouse packet . Only care first 3 bytes
    266266
    267   @param MouseDev  Pointer of PS2 Mouse Private Data Structure 
     267  @param MouseDev  Pointer of PS2 Mouse Private Data Structure
    268268
    269269  @retval EFI_NOT_READY  Mouse Device not ready to input data packet, or some error happened during getting the packet
     
    278278/**
    279279  Read data via IsaIo protocol with given number.
    280  
     280
    281281  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    282282  @param Buffer  Buffer receive data of mouse
    283283  @param BufSize The size of buffer
    284284  @param State   Check input or read data
    285  
     285
    286286  @return status of reading mouse data.
    287287**/
     
    299299/**
    300300  I/O work flow of outing 8042 command.
    301  
     301
    302302  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    303303  @param Command I/O command.
    304  
     304
    305305  @retval EFI_SUCCESS Success to excute I/O work flow
    306306  @retval EFI_TIMEOUT Keyboard controller time out.
     
    314314/**
    315315  I/O work flow of in 8042 data.
    316  
     316
    317317  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    318318  @param Data    Data value
    319  
     319
    320320  @retval EFI_SUCCESS Success to excute I/O work flow
    321321  @retval EFI_TIMEOUT Keyboard controller time out.
     
    329329/**
    330330  I/O work flow of outing 8042 data.
    331  
     331
    332332  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    333333  @param Data    Data value
    334  
     334
    335335  @retval EFI_SUCCESS Success to excute I/O work flow
    336336  @retval EFI_TIMEOUT Keyboard controller time out.
     
    344344/**
    345345  I/O work flow of outing 8042 Aux command.
    346  
     346
    347347  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    348348  @param Command Aux I/O command
    349349  @param Resend  Whether need resend the Aux command.
    350  
     350
    351351  @retval EFI_SUCCESS Success to excute I/O work flow
    352352  @retval EFI_TIMEOUT Keyboard controller time out.
     
    361361/**
    362362  I/O work flow of in 8042 Aux data.
    363  
     363
    364364  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    365365  @param Data    Buffer holding return value.
    366  
     366
    367367  @retval EFI_SUCCESS Success to excute I/O work flow
    368368  @retval EFI_TIMEOUT Keyboard controller time out.
     
    376376/**
    377377  I/O work flow of outing 8042 Aux data.
    378  
     378
    379379  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    380380  @param Data    Buffer holding return value
    381  
     381
    382382  @retval EFI_SUCCESS Success to excute I/O work flow
    383383  @retval EFI_TIMEOUT Keyboard controller time out.
     
    391391/**
    392392  Check keyboard controller status, if it is output buffer full and for auxiliary device.
    393  
    394   @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    395  
     393
     394  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
     395
    396396  @retval EFI_SUCCESS   Keyboard controller is ready
    397397  @retval EFI_NOT_READY Keyboard controller is not ready
     
    404404/**
    405405  I/O work flow to wait input buffer empty in given time.
    406  
     406
    407407  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    408408  @param Timeout Wating time.
    409  
     409
    410410  @retval EFI_TIMEOUT if input is still not empty in given time.
    411411  @retval EFI_SUCCESS input is empty.
     
    419419/**
    420420  I/O work flow to wait output buffer full in given time.
    421  
     421
    422422  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    423423  @param Timeout given time
    424  
     424
    425425  @retval EFI_TIMEOUT  output is not full in given time
    426426  @retval EFI_SUCCESS  output is full in given time.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseDxe/Ps2Mouse.c

    r58459 r58466  
    22  PS/2 Mouse driver. Routines that interacts with callers,
    33  conforming to EFI driver model.
    4  
     4
    55Copyright (c) 2006 - 2012, Intel Corporation. All rights reserved.<BR>
    66This program and the accompanying materials
     
    110110
    111111/**
    112   Start this driver on ControllerHandle by opening a IsaIo protocol, creating 
     112  Start this driver on ControllerHandle by opening a IsaIo protocol, creating
    113113  PS2_MOUSE_ABSOLUTE_POINTER_DEV device and install gEfiAbsolutePointerProtocolGuid
    114114  finally.
     
    240240    StatusCode = EFI_PERIPHERAL_MOUSE | EFI_P_EC_NOT_DETECTED;
    241241    goto ErrorExit;
    242   } 
     242  }
    243243
    244244  REPORT_STATUS_CODE_WITH_DEVICE_PATH (
     
    382382    FreeUnicodeStringTable (MouseDev->ControllerNameTable);
    383383  }
    384  
     384
    385385  if (Status != EFI_DEVICE_ERROR) {
    386386    //
     
    656656/**
    657657  Get and Clear mouse status.
    658  
     658
    659659  @param This                 - Pointer of simple pointer Protocol.
    660660  @param State                - Output buffer holding status.
     
    758758  The user Entry Point for module Ps2Mouse. The user code starts with this function.
    759759
    760   @param[in] ImageHandle    The firmware allocated handle for the EFI image. 
     760  @param[in] ImageHandle    The firmware allocated handle for the EFI image.
    761761  @param[in] SystemTable    A pointer to the EFI System Table.
    762  
     762
    763763  @retval EFI_SUCCESS       The entry point is executed successfully.
    764764  @retval other             Some error occurs when executing this entry point.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Isa/Ps2MouseDxe/Ps2Mouse.h

    r48674 r58466  
    11/** @file
    22  PS/2 Mouse driver header file.
    3  
     3
    44Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
    55This program and the accompanying materials
     
    323323/**
    324324  Get and Clear mouse status.
    325  
     325
    326326  @param This                 - Pointer of simple pointer Protocol.
    327327  @param State                - Output buffer holding status.
     
    371371/**
    372372  I/O work flow of in 8042 data.
    373  
     373
    374374  @param IsaIo   Pointer to instance of EFI_ISA_IO_PROTOCOL
    375375  @param Data    Data value
    376  
     376
    377377  @retval EFI_SUCCESS Success to excute I/O work flow
    378378  @retval EFI_TIMEOUT Keyboard controller time out.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/Ata.c

    r48674 r58466  
    11/** @file
    2   This file contains all helper functions on the ATA command 
    3  
     2  This file contains all helper functions on the ATA command
     3
    44  Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
    55  This program and the accompanying materials
     
    3232                all the information of the IDE device.
    3333
    34   @retval EFI_SUCCESS       The disk specified by IdeDev is a Atapi6 supported one and 
     34  @retval EFI_SUCCESS       The disk specified by IdeDev is a Atapi6 supported one and
    3535                            48-bit addressing must be used
    36   @retval EFI_UNSUPPORTED   The disk dosn't not support Atapi6 or it supports but the 
     36  @retval EFI_UNSUPPORTED   The disk dosn't not support Atapi6 or it supports but the
    3737                            capacity is below 120G, 48bit addressing is not needed
    3838  @retval  EFI_DEVICE_ERROR      The identify data in IdeDev is incorrect
     
    111111  Enable SMART of the disk if supported
    112112
    113   @param IdeDev pointer pointing to IDE_BLK_IO_DEV data structure,used to record 
     113  @param IdeDev pointer pointing to IDE_BLK_IO_DEV data structure,used to record
    114114                all the information of the IDE device.
    115115**/
     
    264264  including device type, media block size, media capacity, and etc.
    265265
    266   @param IdeDev  pointer pointing to IDE_BLK_IO_DEV data structure,used to record 
     266  @param IdeDev  pointer pointing to IDE_BLK_IO_DEV data structure,used to record
    267267                 all the information of the IDE device.
    268268
     
    298298  DeviceSelect  = (UINT8) ((IdeDev->Device) << 4);
    299299
    300  
     300
    301301  Retry = 3;
    302   while (Retry > 0) {   
     302  while (Retry > 0) {
    303303    Status = AtaPioDataIn (
    304304              IdeDev,
     
    405405/**
    406406  This function is a helper function used to change the char order in a string. It
    407   is designed specially for the PrintAtaModuleName() function. After the IDE device 
    408   is detected, the IDE driver gets the device module name by sending ATA command 
     407  is designed specially for the PrintAtaModuleName() function. After the IDE device
     408  is detected, the IDE driver gets the device module name by sending ATA command
    409409  called ATA Identify Command or ATAPI Identify Command to the specified IDE device.
    410410  The module name returned is a string of ASCII characters: the first character is bit8--bit15
    411411  of the first word, the second character is BIT0--bit7 of the first word and so on. Thus
    412   the string can not be print directly before it is preprocessed by this func to change 
     412  the string can not be print directly before it is preprocessed by this func to change
    413413  the order of characters in each word in the string.
    414414
     
    456456  This function is used to send out ATA commands conforms to the PIO Data In Protocol.
    457457
    458   @param IdeDev       pointer pointing to IDE_BLK_IO_DEV data structure, used to record 
     458  @param IdeDev       pointer pointing to IDE_BLK_IO_DEV data structure, used to record
    459459                      all the information of the IDE device.
    460460  @param Buffer       buffer contained data transferred from device to host.
     
    466466  @param CylinderLsb  value of the low byte of the Cylinder Register
    467467  @param CylinderMsb  value of the high byte of the Cylinder Register
    468  
     468
    469469  @retval EFI_SUCCESS      send out the ATA command and device send required data successfully.
    470470  @retval EFI_DEVICE_ERROR command sent failed.
     
    753753  Register, the Error Register's value is also be parsed and print out.
    754754
    755   @param IdeDev  pointer pointing to IDE_BLK_IO_DEV data structure, used to 
     755  @param IdeDev  pointer pointing to IDE_BLK_IO_DEV data structure, used to
    756756                 record all the information of the IDE device.
    757757
     
    851851
    852852/**
    853   This function is called by the AtaBlkIoReadBlocks() to perform reading from 
     853  This function is called by the AtaBlkIoReadBlocks() to perform reading from
    854854  media in block unit.
    855855
    856   @param IdeDev         pointer pointing to IDE_BLK_IO_DEV data structure, used to record 
     856  @param IdeDev         pointer pointing to IDE_BLK_IO_DEV data structure, used to record
    857857                        all the information of the IDE device.
    858858  @param DataBuffer     A pointer to the destination buffer for the data.
    859859  @param Lba            The starting logical block address to read from on the device media.
    860860  @param NumberOfBlocks The number of transfer data blocks.
    861  
     861
    862862  @return status is fully dependent on the return status of AtaPioDataIn() function.
    863863
     
    960960
    961961/**
    962   This function is called by the AtaBlkIoWriteBlocks() to perform writing onto 
     962  This function is called by the AtaBlkIoWriteBlocks() to perform writing onto
    963963  media in block unit.
    964964
     
    968968  @param Lba            The starting logical block address to write onto the device media.
    969969  @param NumberOfBlocks The number of transfer data blocks.
    970  
     970
    971971  @return status is fully dependent on the return status of AtaPioDataIn() function.
    972972
     
    10561056/**
    10571057  This function is used to implement the Soft Reset on the specified device. But,
    1058   the ATA Soft Reset mechanism is so strong a reset method that it will force 
     1058  the ATA Soft Reset mechanism is so strong a reset method that it will force
    10591059  resetting on both devices connected to the same cable.
    10601060
     
    11211121}
    11221122/**
    1123   This function is used to send out ATA commands conforms to the PIO Data In 
     1123  This function is used to send out ATA commands conforms to the PIO Data In
    11241124  Protocol, supporting ATA/ATAPI-6 standard
    11251125
     
    16031603                                          &RegisterValue
    16041604                                          );
    1605  
     1605
    16061606  RegisterValue |= (BMIS_INTERRUPT | BMIS_ERROR);
    1607  
     1607
    16081608  IdeDev->PciIo->Io.Write (
    16091609                                          IdeDev->PciIo,
     
    16161616
    16171617  Status = EFI_SUCCESS;
    1618  
     1618
    16191619  RemainBlockNum = NumberOfBlocks;
    16201620  while (RemainBlockNum > 0) {
     
    18991899/**
    19001900  This function is called by the AtaBlkIoReadBlocks() to perform reading from
    1901   media in block unit. The function has been enhanced to support >120GB access 
     1901  media in block unit. The function has been enhanced to support >120GB access
    19021902  and transfer at most 65536 blocks per command
    19031903
    1904   @param IdeDev         pointer pointing to IDE_BLK_IO_DEV data structure, used to record 
     1904  @param IdeDev         pointer pointing to IDE_BLK_IO_DEV data structure, used to record
    19051905                        all the information of the IDE device.
    19061906  @param DataBuffer     A pointer to the destination buffer for the data.
     
    19311931                        on the device media.
    19321932  @param NumberOfBlocks The number of transfer data blocks.
    1933  
     1933
    19341934  @return status depends on the function DoAtaUdma() returns.
    19351935**/
     
    23142314/**
    23152315  This function is called by the AtaBlkIoWriteBlocks() to perform
    2316   writing to media in block unit. 
     2316  writing to media in block unit.
    23172317
    23182318  @param IdeDev         pointer pointing to IDE_BLK_IO_DEV data structure, used
     
    23222322                        on the device media.
    23232323  @param NumberOfBlocks The number of transfer data blocks.
    2324  
     2324
    23252325  @return status depends on the function DoAtaUdma() returns.
    23262326**/
     
    23432343                        to record all the information of the IDE device.
    23442344  @param DataBuffer     A pointer to the source buffer for the data.
    2345   @param StartLba       The starting logical block address to write onto the device 
     2345  @param StartLba       The starting logical block address to write onto the device
    23462346                        media.
    23472347  @param NumberOfBlocks The number of transfer data blocks.
     
    24242424                         of the intrinsic block size of the device.
    24252425  @param Buffer          A pointer to the source buffer for the data.The caller
    2426                          is responsible for either having implicit or explicit 
     2426                         is responsible for either having implicit or explicit
    24272427                         ownership of the memory that data is written from.
    24282428
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/Atapi.c

    r48674 r58466  
    11/** @file
    2    This file contains all helper functions on the ATAPI command 
    3  
     2   This file contains all helper functions on the ATAPI command
     3
    44  Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
    5   This program and the accompanying materials                         
    6   are licensed and made available under the terms and conditions of the BSD License         
    7   which accompanies this distribution.  The full text of the license may be found at       
    8   http://opensource.org/licenses/bsd-license.php                                           
    9 
    10   THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
    11   WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             
     5  This program and the accompanying materials
     6  are licensed and made available under the terms and conditions of the BSD License
     7  which accompanies this distribution.  The full text of the license may be found at
     8  http://opensource.org/licenses/bsd-license.php
     9
     10  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     11  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
    1313**/
     
    1717/**
    1818  This function is used to get the current status of the media residing
    19   in the LS-120 drive or ZIP drive. The media status is returned in the 
     19  in the LS-120 drive or ZIP drive. The media status is returned in the
    2020  Error Status.
    2121
     
    2929  @retval EFI_WRITE_PROTECTED The media is writing protected.
    3030
    31   @note  This function must be called after the LS120EnableMediaStatus() 
    32          with second parameter set to TRUE 
     31  @note  This function must be called after the LS120EnableMediaStatus()
     32         with second parameter set to TRUE
    3333         (means enable media status notification) is called.
    3434**/
     
    190190      IDEReadPortWMultiple (
    191191        IdeDev->PciIo,
    192         IdeDev->IoPort->Data, 
    193         1, 
     192        IdeDev->IoPort->Data,
     193        1,
    194194        &TempWordBuffer
    195195        );
     
    201201
    202202/**
    203   This function is called by either AtapiPacketCommandIn() or AtapiPacketCommandOut(). 
     203  This function is called by either AtapiPacketCommandIn() or AtapiPacketCommandOut().
    204204  It is used to transfer data between host and device. The data direction is specified
    205205  by the fourth parameter.
     
    247247  //
    248248  // for performance, we assert the ByteCount is an even number
    249   // which is actually a resonable assumption 
     249  // which is actually a resonable assumption
    250250  ASSERT((ByteCount%2) == 0);
    251  
     251
    252252  PtrBuffer         = Buffer;
    253253  RequiredWordCount = ByteCount / 2;
     
    258258
    259259  while (ActualWordCount < RequiredWordCount) {
    260    
     260
    261261    //
    262262    // before each data transfer stream, the host should poll DRQ bit ready,
     
    267267      return CheckErrorStatus (IdeDev);
    268268    }
    269    
     269
    270270    //
    271271    // read Status Register will clear interrupt
     
    302302    ActualWordCount += WordCount;
    303303  }
    304  
     304
    305305  if (Read) {
    306306    //
     
    327327
    328328/**
    329   This function is used to send out ATAPI commands conforms to the Packet Command 
     329  This function is used to send out ATAPI commands conforms to the Packet Command
    330330  with PIO Data In Protocol.
    331331
     
    333333                   to record all the information of the IDE device.
    334334  @param Packet    pointer pointing to ATAPI_PACKET_COMMAND data structure
    335                    which contains the contents of the command.     
     335                   which contains the contents of the command.
    336336  @param Buffer    buffer contained data transferred from device to host.
    337337  @param ByteCount data size in byte unit of the buffer.
    338   @param TimeOut   this parameter is used to specify the timeout value for the 
    339                    PioReadWriteData() function. 
     338  @param TimeOut   this parameter is used to specify the timeout value for the
     339                   PioReadWriteData() function.
    340340
    341341  @retval EFI_SUCCESS       send out the ATAPI packet command successfully
     
    438438  @param Buffer      buffer contained data transferred from host to device.
    439439  @param ByteCount   data size in byte unit of the buffer.
    440   @param TimeOut     this parameter is used to specify the timeout value 
    441                      for the PioReadWriteData() function. 
     440  @param TimeOut     this parameter is used to specify the timeout value
     441                     for the PioReadWriteData() function.
    442442  @retval EFI_SUCCESS      send out the ATAPI packet command successfully
    443                            and device received data successfully. 
     443                           and device received data successfully.
    444444  @retval EFI_DEVICE_ERROR the device failed to send data.
    445445
     
    466466    return Status;
    467467  }
    468  
     468
    469469  //
    470470  // Select device via Device/Head Register.
     
    588588
    589589  There are 5 steps to reach such objective:
    590   1. Sends out the ATAPI Identify Command to the specified device. 
     590  1. Sends out the ATAPI Identify Command to the specified device.
    591591  Only ATAPI device responses to this command. If the command succeeds,
    592   it returns the Identify data structure which filled with information 
    593   about the device. Since the ATAPI device contains removable media, 
     592  it returns the Identify data structure which filled with information
     593  about the device. Since the ATAPI device contains removable media,
    594594  the only meaningful information is the device module name.
    595595  2. Sends out ATAPI Inquiry Packet Command to the specified device.
     
    597597  the device type information.
    598598  3. Allocate sense data space for future use. We don't detect the media
    599   presence here to improvement boot performance, especially when CD 
     599  presence here to improvement boot performance, especially when CD
    600600  media is present. The media detection will be performed just before
    601601  each BLK_IO read/write
    602  
     602
    603603  @param IdeDev pointer pointing to IDE_BLK_IO_DEV data structure, used
    604604                 to record all the information of the IDE device.
     
    607607  @retval EFI_DEVICE_ERROR  ATAPI Identify Device Command failed or device type
    608608                            is not supported by this IDE driver.
    609   @retval EFI_OUT_OF_RESOURCES Allocate memory for sense data failed 
     609  @retval EFI_OUT_OF_RESOURCES Allocate memory for sense data failed
    610610
    611611  @note   Parameter "IdeDev" will be updated in this function.
     
    720720  //
    721721  case 0x04:
    722  
     722
    723723  //
    724724  // Optical
     
    759759/**
    760760  Sends out ATAPI Request Sense Packet Command to the specified device. This command
    761   will return all the current Sense data in the device.  This function will pack 
     761  will return all the current Sense data in the device.  This function will pack
    762762  all the Sense data in one single buffer.
    763763
     
    765765                      to record all the information of the IDE device.
    766766  @param SenseCounts  allocated in this function, and freed by the calling function.
    767                       This buffer is used to accommodate all the sense data returned 
     767                      This buffer is used to accommodate all the sense data returned
    768768                      by the device.
    769769
     
    851851/**
    852852  This function is used to parse sense data. Only the first sense data is honoured
    853  
     853
    854854  @param IdeDev     Indicates the calling context.
    855855  @param SenseCount Count of sense data.
     
    937937AtapiTestUnitReady (
    938938  IN  IDE_BLK_IO_DEV  *IdeDev,
    939   OUT SENSE_RESULT    *SResult 
     939  OUT SENSE_RESULT    *SResult
    940940  )
    941941{
     
    975975  Current device status will impact device's response to the Read Capacity
    976976  Command. For example, if the device once reset, the Read Capacity
    977   Command will fail. The Sense data record the current device status, so 
     977  Command will fail. The Sense data record the current device status, so
    978978  if the Read Capacity Command failed, the Sense data must be requested
    979979  and be analyzed to determine if the Read Capacity Command should retry.
     
    989989  @note Parameter "IdeDev" will be updated in this function.
    990990
    991  
     991
    992992**/
    993993EFI_STATUS
    994994AtapiReadCapacity (
    995995  IN  IDE_BLK_IO_DEV  *IdeDev,
    996   OUT SENSE_RESULT        *SResult 
     996  OUT SENSE_RESULT        *SResult
    997997  )
    998998{
     
    10491049
    10501050  if (!EFI_ERROR (SenseStatus)) {
    1051         ParseSenseData (IdeDev, SenseCount, SResult);                   
    1052                                                                                                                          
     1051        ParseSenseData (IdeDev, SenseCount, SResult);
     1052
    10531053        if (!EFI_ERROR (Status) && *SResult == SenseNoSenseKey) {
    10541054      if (IdeDev->Type == IdeCdRom) {
     
    10781078
    10791079          IdeDev->BlkIo.Media->LastBlock =  (FormatData.LastLba3 << 24) |
    1080             (FormatData.LastLba2 << 16) | 
     1080            (FormatData.LastLba2 << 16) |
    10811081            (FormatData.LastLba1 << 8)  |
    10821082            FormatData.LastLba0;
     
    11111111/**
    11121112  This function is used to test the current media write-protected or not residing
    1113   in the LS-120 drive or ZIP drive. 
     1113  in the LS-120 drive or ZIP drive.
    11141114  @param IdeDev          pointer pointing to IDE_BLK_IO_DEV data structure, used
    11151115                         to record all the information of the IDE device.
     
    11601160
    11611161/**
    1162   Used before read/write blocks from/to ATAPI device media. Since ATAPI device 
    1163   media is removable, it is necessary to detect whether media is present and 
     1162  Used before read/write blocks from/to ATAPI device media. Since ATAPI device
     1163  media is removable, it is necessary to detect whether media is present and
    11641164  get current present media's information, and if media has been changed, Block
    11651165  I/O Protocol need to be reinstalled.
     
    14101410  read from media in block unit.
    14111411
    1412   The main command used to access media here is READ(10) Command. 
    1413   READ(10) Command requests that the ATAPI device media transfer 
    1414   specified data to the host. Data is transferred in block(sector) 
     1412  The main command used to access media here is READ(10) Command.
     1413  READ(10) Command requests that the ATAPI device media transfer
     1414  specified data to the host. Data is transferred in block(sector)
    14151415  unit. The maximum number of blocks that can be transferred once is
    1416   65536. This is the main difference between READ(10) and READ(12) 
     1416  65536. This is the main difference between READ(10) and READ(12)
    14171417  Command. The maximum number of blocks in READ(12) is 2 power 32.
    14181418
    14191419  @param IdeDev           pointer pointing to IDE_BLK_IO_DEV data structure, used
    14201420                          to record all the information of the IDE device.
    1421   @param Buffer           A pointer to the destination buffer for the data. 
    1422   @param Lba              The starting logical block address to read from on the 
     1421  @param Buffer           A pointer to the destination buffer for the data.
     1422  @param Lba              The starting logical block address to read from on the
    14231423                          device media.
    14241424  @param NumberOfBlocks   The number of transfer data blocks.
     
    15281528  This function is called by the AtapiBlkIoWriteBlocks() to perform
    15291529  write onto media in block unit.
    1530   The main command used to access media here is Write(10) Command. 
    1531   Write(10) Command requests that the ATAPI device media transfer 
    1532   specified data to the host. Data is transferred in block (sector) 
     1530  The main command used to access media here is Write(10) Command.
     1531  Write(10) Command requests that the ATAPI device media transfer
     1532  specified data to the host. Data is transferred in block (sector)
    15331533  unit. The maximum number of blocks that can be transferred once is
    1534   65536. 
     1534  65536.
    15351535
    15361536  @param IdeDev          pointer pointing to IDE_BLK_IO_DEV data structure, used
    15371537                         to record all the information of the IDE device.
    1538   @param Buffer          A pointer to the source buffer for the data. 
    1539   @param Lba             The starting logical block address to write onto 
     1538  @param Buffer          A pointer to the source buffer for the data.
     1539  @param Lba             The starting logical block address to write onto
    15401540                         the device media.
    15411541  @param NumberOfBlocks  The number of transfer data blocks.
    1542  
     1542
    15431543  @return status is fully dependent on the return status of AtapiPacketCommandOut() function.
    15441544
     
    15951595      SectorCount = (UINT16) BlocksRemaining;
    15961596    }
    1597  
     1597
    15981598    //
    15991599    // Command code is WRITE_10.
     
    16461646  command should be sent without waiting for the BSY clear and DRDY
    16471647  set.
    1648   This function is called by IdeBlkIoReset(), 
     1648  This function is called by IdeBlkIoReset(),
    16491649  a interface function of Block I/O protocol.
    16501650
     
    16841684    return EFI_DEVICE_ERROR;
    16851685  }
    1686  
     1686
    16871687  //
    16881688  // stall 5 seconds to make the device status stable
     
    17031703                        of the intrinsic block size of the device.
    17041704  @param Buffer         A pointer to the destination buffer for the data. The caller
    1705                         is responsible for either having implicit or explicit 
     1705                        is responsible for either having implicit or explicit
    17061706                        ownership of the memory that data is read into.
    1707  
     1707
    17081708  @retval EFI_SUCCESS           Read Blocks successfully.
    17091709  @retval EFI_DEVICE_ERROR      Read Blocks failed.
     
    18051805    return EFI_DEVICE_ERROR;
    18061806  }
    1807  
     1807
    18081808  //
    18091809  // Read blocks succeeded
    18101810  //
    1811  
     1811
    18121812  //
    18131813  // save the first block to the cache for performance
     
    18411841  @retval EFI_MEDIA_CHANGE       The MediaId is not for the current media.
    18421842  @retval EFI_BAD_BUFFER_SIZE    The BufferSize parameter is not a multiple of the
    1843                                  intrinsic block size of the device. 
    1844   @retval EFI_INVALID_PARAMETER  The write request contains LBAs that are not valid, 
     1843                                 intrinsic block size of the device.
     1844  @retval EFI_INVALID_PARAMETER  The write request contains LBAs that are not valid,
    18451845                                 or the data buffer is not valid.
    18461846
     
    18901890    return Status;
    18911891  }
    1892  
     1892
    18931893  //
    18941894  // Get the intrinsic block size
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/ComponentName.c

    r48674 r58466  
    11/** @file
    22  UEFI Component Name(2) protocol implementation for ConPlatform driver.
    3  
     3
    44  Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
    5   This program and the accompanying materials                         
    6   are licensed and made available under the terms and conditions of the BSD License         
    7   which accompanies this distribution.  The full text of the license may be found at       
    8   http://opensource.org/licenses/bsd-license.php                                           
    9 
    10   THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
    11   WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             
     5  This program and the accompanying materials
     6  are licensed and made available under the terms and conditions of the BSD License
     7  which accompanies this distribution.  The full text of the license may be found at
     8  http://opensource.org/licenses/bsd-license.php
     9
     10  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     11  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
    1313**/
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/ComponentName.h

    r48674 r58466  
    11/** @file
    2  
     2
    33  UEFI Component Name(2) protocol implementation header file for IDE Bus driver.
    4  
     4
    55  Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
    66  This program and the accompanying materials
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/DriverConfiguration.c

    r48674 r58466  
    11/** @file
    2   Implementation of UEFI Driver Configuration Protocol for IDE bus driver which 
     2  Implementation of UEFI Driver Configuration Protocol for IDE bus driver which
    33  provides ability to set IDE bus controller specific options.
    4  
     4
    55  Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
    6   This program and the accompanying materials                         
    7   are licensed and made available under the terms and conditions of the BSD License         
    8   which accompanies this distribution.  The full text of the license may be found at       
    9   http://opensource.org/licenses/bsd-license.php                                           
    10 
    11   THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
    12   WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             
     6  This program and the accompanying materials
     7  are licensed and made available under the terms and conditions of the BSD License
     8  which accompanies this distribution.  The full text of the license may be found at
     9  http://opensource.org/licenses/bsd-license.php
     10
     11  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     12  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1313
    1414**/
     
    8181
    8282/**
    83   Allows the user to set controller specific options for a controller that a 
     83  Allows the user to set controller specific options for a controller that a
    8484  driver is currently managing.
    8585
     
    9292                            It will not be NULL for a bus driver that wishes to set
    9393                            options for one of its child controllers.
    94   @param  Language          A pointer to a three character ISO 639-2 language identifier. 
    95                             This is the language of the user interface that should be presented 
    96                             to the user, and it must match one of the languages specified in 
     94  @param  Language          A pointer to a three character ISO 639-2 language identifier.
     95                            This is the language of the user interface that should be presented
     96                            to the user, and it must match one of the languages specified in
    9797                            SupportedLanguages. The number of languages supported by a driver is up to
    9898                            the driver writer.
    99   @param  ActionRequired    A pointer to the action that the calling agent is required 
     99  @param  ActionRequired    A pointer to the action that the calling agent is required
    100100                            to perform when this function returns.
    101  
    102 
    103   @retval  EFI_SUCCESS           The driver specified by This successfully set the configuration 
     101
     102
     103  @retval  EFI_SUCCESS           The driver specified by This successfully set the configuration
    104104                                 options for the controller specified by ControllerHandle..
    105105  @retval  EFI_INVALID_PARAMETER ControllerHandle is not a valid EFI_HANDLE.
    106106  @retval  EFI_INVALID_PARAMETER ChildHandle is not NULL and it is not a valid EFI_HANDLE.
    107107  @retval  EFI_INVALID_PARAMETER ActionRequired is NULL.
    108   @retval  EFI_UNSUPPORTED       The driver specified by This does not support setting configuration options for 
     108  @retval  EFI_UNSUPPORTED       The driver specified by This does not support setting configuration options for
    109109                                 the controller specified by ControllerHandle and ChildHandle.
    110110  @retval  EFI_UNSUPPORTED       The driver specified by This does not support the language specified by Language.
    111   @retval  EFI_DEVICE_ERROR      A device error occurred while attempt to set the configuration options for the 
     111  @retval  EFI_DEVICE_ERROR      A device error occurred while attempt to set the configuration options for the
    112112                                 controller specified by ControllerHandle and ChildHandle.
    113   @retval  EFI_OUT_RESOURCES     There are not enough resources available to set the configuration options for the 
     113  @retval  EFI_OUT_RESOURCES     There are not enough resources available to set the configuration options for the
    114114                                 controller specified by ControllerHandle and ChildHandle
    115115**/
     
    183183
    184184  @param  This             A pointer to the EFI_DRIVER_CONFIGURATION_PROTOCOL instance.
    185   @param  ControllerHandle The handle of the controller to test if it's current configuration options 
     185  @param  ControllerHandle The handle of the controller to test if it's current configuration options
    186186                           are valid.
    187   @param  ChildHandle      The handle of the child controller to test if it's current configuration 
    188                            options are valid.  This is an optional parameter that may be NULL. It will 
     187  @param  ChildHandle      The handle of the child controller to test if it's current configuration
     188                           options are valid.  This is an optional parameter that may be NULL. It will
    189189                           be NULL for device drivers.  It will also be NULL for a bus drivers that
    190                            wish to test the configuration options for the bus controller. It will 
    191                            not be NULL for a bus driver that wishes to test configuration options for 
     190                           wish to test the configuration options for the bus controller. It will
     191                           not be NULL for a bus driver that wishes to test configuration options for
    192192                           one of its child controllers.
    193193  @retval  EFI_SUCCESS           The controller specified by ControllerHandle and ChildHandle that is being
     
    196196  @retval  EFI_INVALID_PARAMETER ControllerHandle is not a valid EFI_HANDLE.
    197197  @retval  EFI_INVALID_PARAMETER ChildHandle is not NULL and it is not a valid EFI_HANDLE.
    198   @retval  EFI_UNSUPPORTED       The driver specified by This is not currently  managing the controller 
     198  @retval  EFI_UNSUPPORTED       The driver specified by This is not currently  managing the controller
    199199                                 specified by ControllerHandle and ChildHandle.
    200200  @retval  EFI_DEVICE_ERROR      The controller specified by ControllerHandle and ChildHandle that is being
     
    237237  @param  This             A pointer to the EFI_DRIVER_CONFIGURATION_ PROTOCOL instance.
    238238  @param  ControllerHandle The handle of the controller to force default configuration options on.
    239   @param  ChildHandle      The handle of the child controller to force default configuration 
    240                            options on  This is an optional parameter that may be NULL.  It 
    241                            will be NULL for device drivers. It will also be NULL for a bus 
     239  @param  ChildHandle      The handle of the child controller to force default configuration
     240                           options on  This is an optional parameter that may be NULL.  It
     241                           will be NULL for device drivers. It will also be NULL for a bus
    242242                           drivers that wish to force default configuration options for the bus
    243243                           controller.  It will not be NULL for a bus driver that wishes to force
    244244                           default configuration options for one of its child controllers.
    245   @param  DefaultType      The type of default configuration options to force on the controller 
    246                            specified by ControllerHandle and ChildHandle. 
    247   @param  ActionRequired   A pointer to the action that the calling agent is required to perform 
     245  @param  DefaultType      The type of default configuration options to force on the controller
     246                           specified by ControllerHandle and ChildHandle.
     247  @param  ActionRequired   A pointer to the action that the calling agent is required to perform
    248248                           when this function returns.
    249249
    250   @retval  EFI_SUCCESS           The driver specified by This successfully forced the 
    251                                  default configuration options on the controller specified by 
     250  @retval  EFI_SUCCESS           The driver specified by This successfully forced the
     251                                 default configuration options on the controller specified by
    252252                                 ControllerHandle and ChildHandle.
    253253  @retval  EFI_INVALID_PARAMETER ControllerHandle is not a valid EFI_HANDLE.
    254254  @retval  EFI_INVALID_PARAMETER ChildHandle is not NULL and it is not a valid EFI_HANDLE.
    255255  @retval  EFI_INVALID_PARAMETER ActionRequired is NULL.
    256   @retval  EFI_UNSUPPORTED       The driver specified by This does not support forcing the default 
     256  @retval  EFI_UNSUPPORTED       The driver specified by This does not support forcing the default
    257257                                 configuration options on the controller specified by ControllerHandle
    258258                                 and ChildHandle.
    259   @retval  EFI_UNSUPPORTED       The driver specified by This does not support the configuration type 
     259  @retval  EFI_UNSUPPORTED       The driver specified by This does not support the configuration type
    260260                                 specified by DefaultType.
    261   @retval  EFI_DEVICE_ERROR      A device error occurred while attempt to force the default configuration 
     261  @retval  EFI_DEVICE_ERROR      A device error occurred while attempt to force the default configuration
    262262                                 options on the controller specified by  ControllerHandle and ChildHandle.
    263   @retval  EFI_OUT_RESOURCES     There are not enough resources available to force the default configuration 
     263  @retval  EFI_OUT_RESOURCES     There are not enough resources available to force the default configuration
    264264                                 options on the controller specified by ControllerHandle and ChildHandle.
    265265**/
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/DriverDiagnostics.c

    r48674 r58466  
    22  Implementation of UEFI driver Dialnostics protocol which to perform diagnostic on the IDE
    33  Bus controller.
    4  
     4
    55  Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
    6   This program and the accompanying materials                         
    7   are licensed and made available under the terms and conditions of the BSD License         
    8   which accompanies this distribution.  The full text of the license may be found at       
    9   http://opensource.org/licenses/bsd-license.php                                           
    10 
    11   THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
    12   WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             
     6  This program and the accompanying materials
     7  are licensed and made available under the terms and conditions of the BSD License
     8  which accompanies this distribution.  The full text of the license may be found at
     9  http://opensource.org/licenses/bsd-license.php
     10
     11  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     12  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1313
    1414**/
     
    4343                           This is an optional parameter that may be NULL.  It will
    4444                           be NULL for device drivers.  It will also be NULL for a
    45                            bus drivers that wish to run diagnostics on the bus controller. 
    46                            It will not be NULL for a bus driver that wishes to run 
     45                           bus drivers that wish to run diagnostics on the bus controller.
     46                           It will not be NULL for a bus driver that wishes to run
    4747                           diagnostics on one of its child controllers.
    4848  @param  DiagnosticType   Indicates type of diagnostics to perform on the controller
    4949                           specified by ControllerHandle and ChildHandle.
    50   @param  Language         A pointer to a three character ISO 639-2 language identifier. 
    51                            This is the language in which the optional error message should 
    52                            be returned in Buffer, and it must match one of the languages 
     50  @param  Language         A pointer to a three character ISO 639-2 language identifier.
     51                           This is the language in which the optional error message should
     52                           be returned in Buffer, and it must match one of the languages
    5353                           specified in SupportedLanguages. The number of languages supported by
    5454                           a driver is up to the driver writer.
     
    5656  @param  BufferSize       The size, in bytes, of the data returned in Buffer.
    5757  @param  Buffer           A buffer that contains a Null-terminated Unicode string
    58                            plus some additional data whose format is defined by ErrorType. 
    59                            Buffer is allocated by this function with AllocatePool(), and 
     58                           plus some additional data whose format is defined by ErrorType.
     59                           Buffer is allocated by this function with AllocatePool(), and
    6060                           it is the caller's responsibility to free it with a call to FreePool().
    6161
    62   @retval  EFI_SUCCESS           The controller specified by ControllerHandle and ChildHandle passed 
     62  @retval  EFI_SUCCESS           The controller specified by ControllerHandle and ChildHandle passed
    6363                                 the diagnostic.
    6464  @retval  EFI_INVALID_PARAMETER ControllerHandle is NULL.
     
    6868  @retval  EFI_INVALID_PARAMETER BufferType is NULL.
    6969  @retval  EFI_INVALID_PARAMETER Buffer is NULL.
    70   @retval  EFI_UNSUPPORTED       The driver specified by This does not support running 
    71                                  diagnostics for the controller specified by ControllerHandle 
     70  @retval  EFI_UNSUPPORTED       The driver specified by This does not support running
     71                                 diagnostics for the controller specified by ControllerHandle
    7272                                 and ChildHandle.
    7373  @retval  EFI_UNSUPPORTED       The driver specified by This does not support the
    7474                                 type of diagnostic specified by DiagnosticType.
    75   @retval  EFI_UNSUPPORTED       The driver specified by This does not support the language 
     75  @retval  EFI_UNSUPPORTED       The driver specified by This does not support the language
    7676                                 specified by Language.
    77   @retval  EFI_OUT_OF_RESOURCES  There are not enough resources available to complete the 
     77  @retval  EFI_OUT_OF_RESOURCES  There are not enough resources available to complete the
    7878                                 diagnostics.
    79   @retval  EFI_OUT_OF_RESOURCES  There are not enough resources available to return the 
     79  @retval  EFI_OUT_OF_RESOURCES  There are not enough resources available to return the
    8080                                 status information in ErrorType, BufferSize,and Buffer.
    81   @retval  EFI_DEVICE_ERROR      The controller specified by ControllerHandle and ChildHandle 
     81  @retval  EFI_DEVICE_ERROR      The controller specified by ControllerHandle and ChildHandle
    8282                                 did not pass the diagnostic.
    8383**/
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/Ide.c

    r48674 r58466  
    11/** @file
    22  The file ontaining the helper functions implement of the Ide Bus driver
    3  
     3
    44  Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
    55  This program and the accompanying materials
     
    2525
    2626  @param  PciIo  The PCI IO protocol instance
    27   @param  Port   the IDE Port number 
     27  @param  Port   the IDE Port number
    2828
    2929  @return  the one-byte data read from IDE port
     
    271271  @param  IdeRegsBaseAddr Pointer to IDE_REGISTERS_BASE_ADDR to
    272272           receive IDE IO port registers' base addresses
    273            
     273
    274274  @retval EFI_UNSUPPORTED return this value when the BARs is not IO type
    275275  @retval EFI_SUCCESS     Get the Base address successfully
     
    352352
    353353  @param  IdeDev The BLK_IO private data which specifies the IDE device
    354  
     354
    355355  @retval EFI_INVALID_PARAMETER return this value when the channel is invalid
    356356  @retval EFI_SUCCESS           reassign the IDE IO resource successfully
     
    371371    return EFI_INVALID_PARAMETER;
    372372  }
    373  
     373
    374374  //
    375375  // Requery IDE IO port registers' base addresses in case of the switch of
     
    594594
    595595  @param  IdeDev The BLK_IO private data which specifies the IDE device.
    596  
     596
    597597  @retval EFI_NOT_FOUND   The device or channel is not found
    598598  @retval EFI_SUCCESS     The device is found
     
    716716  So this function is called after data transfer is finished.
    717717
    718   @param IdeDev                 pointer pointing to IDE_BLK_IO_DEV data structure, used 
     718  @param IdeDev                 pointer pointing to IDE_BLK_IO_DEV data structure, used
    719719                                to record all the information of the IDE device.
    720720  @param TimeoutInMilliSeconds  used to designate the timeout for the DRQ clear.
     
    779779  is finished.
    780780
    781   @param IdeDev                pointer pointing to IDE_BLK_IO_DEV data structure, used 
     781  @param IdeDev                pointer pointing to IDE_BLK_IO_DEV data structure, used
    782782                               to record all the information of the IDE device.
    783783
     
    902902/**
    903903  This function is used to poll for the DRQ bit set in the Alternate Status Register.
    904   DRQ is set when the device is ready to transfer data. So this function is called after 
     904  DRQ is set when the device is ready to transfer data. So this function is called after
    905905  the command is sent to the device and before required data is transferred.
    906906
    907   @param IdeDev                pointer pointing to IDE_BLK_IO_DEV data structure, used to 
     907  @param IdeDev                pointer pointing to IDE_BLK_IO_DEV data structure, used to
    908908                               record all the information of the IDE device.
    909909
     
    967967  is clear when the device is not busy. Every command must be sent after device is not busy.
    968968
    969   @param IdeDev                pointer pointing to IDE_BLK_IO_DEV data structure, used 
     969  @param IdeDev                pointer pointing to IDE_BLK_IO_DEV data structure, used
    970970                               to record all the information of the IDE device.
    971971  @param TimeoutInMilliSeconds used to designate the timeout for the DRQ ready.
     
    10091009}
    10101010/**
    1011   This function is used to poll for the BSY bit clear in the Alternate Status Register. 
    1012   BSY is clear when the device is not busy. Every command must be sent after device is 
     1011  This function is used to poll for the BSY bit clear in the Alternate Status Register.
     1012  BSY is clear when the device is not busy. Every command must be sent after device is
    10131013  not busy.
    10141014
    1015   @param IdeDev               pointer pointing to IDE_BLK_IO_DEV data structure, used to record 
     1015  @param IdeDev               pointer pointing to IDE_BLK_IO_DEV data structure, used to record
    10161016                              all the information of the IDE device.
    10171017  @param TimeoutInMilliSeconds used to designate the timeout for the DRQ ready.
     
    10521052/**
    10531053  This function is used to poll for the DRDY bit set in the Status Register. DRDY
    1054   bit is set when the device is ready to accept command. Most ATA commands must be 
     1054  bit is set when the device is ready to accept command. Most ATA commands must be
    10551055  sent after DRDY set except the ATAPI Packet Command.
    10561056
     
    11041104}
    11051105/**
    1106   This function is used to poll for the DRDY bit set in the Alternate Status Register. 
    1107   DRDY bit is set when the device is ready to accept command. Most ATA commands must 
     1106  This function is used to poll for the DRDY bit set in the Alternate Status Register.
     1107  DRDY bit is set when the device is ready to accept command. Most ATA commands must
    11081108  be sent after DRDY set except the ATAPI Packet Command.
    11091109
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/Ide.h

    r48674 r58466  
    2929
    3030  @param  PciIo  The PCI IO protocol instance
    31   @param  Port   the IDE Port number 
     31  @param  Port   the IDE Port number
    3232
    3333  return  the one-byte data read from IDE port
     
    154154  @param  IdeRegsBaseAddr Pointer to IDE_REGISTERS_BASE_ADDR to
    155155          receive IDE IO port registers' base addresses
    156  
     156
    157157  @retval EFI_UNSUPPORTED return this value when the BARs is not IO type
    158158  @retval EFI_SUCCESS     Get the Base address successfully
     
    188188
    189189  @param  IdeDev The BLK_IO private data which specifies the IDE device.
    190  
     190
    191191  @retval EFI_NOT_FOUND   The device or channel is not found
    192192  @retval EFI_SUCCESS     The device is found
     
    213213  So this function is called after data transfer is finished.
    214214
    215   @param IdeDev                 pointer pointing to IDE_BLK_IO_DEV data structure, used 
     215  @param IdeDev                 pointer pointing to IDE_BLK_IO_DEV data structure, used
    216216                                to record all the information of the IDE device.
    217217  @param TimeoutInMilliSeconds  used to designate the timeout for the DRQ clear.
     
    237237  is finished.
    238238
    239   @param IdeDev                pointer pointing to IDE_BLK_IO_DEV data structure, used 
     239  @param IdeDev                pointer pointing to IDE_BLK_IO_DEV data structure, used
    240240                               to record all the information of the IDE device.
    241241
     
    281281/**
    282282  This function is used to poll for the DRQ bit set in the Alternate Status Register.
    283   DRQ is set when the device is ready to transfer data. So this function is called after 
     283  DRQ is set when the device is ready to transfer data. So this function is called after
    284284  the command is sent to the device and before required data is transferred.
    285285
    286   @param IdeDev                pointer pointing to IDE_BLK_IO_DEV data structure, used to 
     286  @param IdeDev                pointer pointing to IDE_BLK_IO_DEV data structure, used to
    287287                               record all the information of the IDE device.
    288288
     
    305305  is clear when the device is not busy. Every command must be sent after device is not busy.
    306306
    307   @param IdeDev                pointer pointing to IDE_BLK_IO_DEV data structure, used 
     307  @param IdeDev                pointer pointing to IDE_BLK_IO_DEV data structure, used
    308308                               to record all the information of the IDE device.
    309309  @param TimeoutInMilliSeconds used to designate the timeout for the DRQ ready.
     
    321321
    322322/**
    323   This function is used to poll for the BSY bit clear in the Alternate Status Register. 
    324   BSY is clear when the device is not busy. Every command must be sent after device is 
     323  This function is used to poll for the BSY bit clear in the Alternate Status Register.
     324  BSY is clear when the device is not busy. Every command must be sent after device is
    325325  not busy.
    326326
    327   @param IdeDev               pointer pointing to IDE_BLK_IO_DEV data structure, used to record 
     327  @param IdeDev               pointer pointing to IDE_BLK_IO_DEV data structure, used to record
    328328                              all the information of the IDE device.
    329329  @param TimeoutInMilliSeconds used to designate the timeout for the DRQ ready.
     
    342342/**
    343343  This function is used to poll for the DRDY bit set in the Status Register. DRDY
    344   bit is set when the device is ready to accept command. Most ATA commands must be 
     344  bit is set when the device is ready to accept command. Most ATA commands must be
    345345  sent after DRDY set except the ATAPI Packet Command.
    346346
     
    361361
    362362/**
    363   This function is used to poll for the DRDY bit set in the Alternate Status Register. 
    364   DRDY bit is set when the device is ready to accept command. Most ATA commands must 
     363  This function is used to poll for the DRDY bit set in the Alternate Status Register.
     364  DRDY bit is set when the device is ready to accept command. Most ATA commands must
    365365  be sent after DRDY set except the ATAPI Packet Command.
    366366
     
    395395  including device type, media block size, media capacity, and etc.
    396396
    397   @param IdeDev  pointer pointing to IDE_BLK_IO_DEV data structure,used to record 
     397  @param IdeDev  pointer pointing to IDE_BLK_IO_DEV data structure,used to record
    398398                 all the information of the IDE device.
    399399
     
    421421  This function is used to send out ATA commands conforms to the PIO Data In Protocol.
    422422
    423   @param IdeDev       pointer pointing to IDE_BLK_IO_DEV data structure, used to record 
     423  @param IdeDev       pointer pointing to IDE_BLK_IO_DEV data structure, used to record
    424424                      all the information of the IDE device.
    425425  @param Buffer       buffer contained data transferred from device to host.
     
    431431  @param CylinderLsb  value of the low byte of the Cylinder Register
    432432  @param CylinderMsb  value of the high byte of the Cylinder Register
    433  
     433
    434434  @retval EFI_SUCCESS      send out the ATA command and device send required data successfully.
    435435  @retval EFI_DEVICE_ERROR command sent failed.
     
    487487  Register, the Error Register's value is also be parsed and print out.
    488488
    489   @param IdeDev  pointer pointing to IDE_BLK_IO_DEV data structure, used to 
     489  @param IdeDev  pointer pointing to IDE_BLK_IO_DEV data structure, used to
    490490                 record all the information of the IDE device.
    491491
     
    501501/**
    502502  This function is used to implement the Soft Reset on the specified device. But,
    503   the ATA Soft Reset mechanism is so strong a reset method that it will force 
     503  the ATA Soft Reset mechanism is so strong a reset method that it will force
    504504  resetting on both devices connected to the same cable.
    505505
     
    569569                         of the intrinsic block size of the device.
    570570  @param Buffer          A pointer to the source buffer for the data.The caller
    571                          is responsible for either having implicit or explicit 
     571                         is responsible for either having implicit or explicit
    572572                         ownership of the memory that data is written from.
    573573
     
    601601
    602602  There are 5 steps to reach such objective:
    603   1. Sends out the ATAPI Identify Command to the specified device. 
     603  1. Sends out the ATAPI Identify Command to the specified device.
    604604  Only ATAPI device responses to this command. If the command succeeds,
    605   it returns the Identify data structure which filled with information 
    606   about the device. Since the ATAPI device contains removable media, 
     605  it returns the Identify data structure which filled with information
     606  about the device. Since the ATAPI device contains removable media,
    607607  the only meaningful information is the device module name.
    608608  2. Sends out ATAPI Inquiry Packet Command to the specified device.
     
    610610  the device type information.
    611611  3. Allocate sense data space for future use. We don't detect the media
    612   presence here to improvement boot performance, especially when CD 
     612  presence here to improvement boot performance, especially when CD
    613613  media is present. The media detection will be performed just before
    614614  each BLK_IO read/write
    615  
     615
    616616  @param IdeDev pointer pointing to IDE_BLK_IO_DEV data structure, used
    617617                 to record all the information of the IDE device.
     
    620620  @retval EFI_DEVICE_ERROR  ATAPI Identify Device Command failed or device type
    621621                            is not supported by this IDE driver.
    622   @retval EFI_OUT_OF_RESOURCES Allocate memory for sense data failed 
     622  @retval EFI_OUT_OF_RESOURCES Allocate memory for sense data failed
    623623
    624624  @note   Parameter "IdeDev" will be updated in this function.
     
    638638  command should be sent without waiting for the BSY clear and DRDY
    639639  set.
    640   This function is called by IdeBlkIoReset(), 
     640  This function is called by IdeBlkIoReset(),
    641641  a interface function of Block I/O protocol.
    642642
     
    663663                        of the intrinsic block size of the device.
    664664  @param Buffer         A pointer to the destination buffer for the data. The caller
    665                         is responsible for either having implicit or explicit 
     665                        is responsible for either having implicit or explicit
    666666                        ownership of the memory that data is read into.
    667  
     667
    668668  @retval EFI_SUCCESS           Read Blocks successfully.
    669669  @retval EFI_DEVICE_ERROR      Read Blocks failed.
     
    702702  @retval EFI_MEDIA_CHANGE       The MediaId is not for the current media.
    703703  @retval EFI_BAD_BUFFER_SIZE    The BufferSize parameter is not a multiple of the
    704                                  intrinsic block size of the device. 
    705   @retval EFI_INVALID_PARAMETER  The write request contains LBAs that are not valid, 
     704                                 intrinsic block size of the device.
     705  @retval EFI_INVALID_PARAMETER  The write request contains LBAs that are not valid,
    706706                                 or the data buffer is not valid.
    707707
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/IdeBus.c

    r58459 r58466  
    11/** @file
    2   This file implement UEFI driver for IDE Bus which includes device identification, 
    3   Child device(Disk, CDROM, etc) enumeration and child handler installation, and 
     2  This file implement UEFI driver for IDE Bus which includes device identification,
     3  Child device(Disk, CDROM, etc) enumeration and child handler installation, and
    44  driver stop.
    5    
     5
    66  Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
    77  This program and the accompanying materials
     
    155155    Node = (EFI_DEV_PATH *) RemainingDevicePath;
    156156    //
    157     // Check if RemainingDevicePath is the End of Device Path Node, 
     157    // Check if RemainingDevicePath is the End of Device Path Node,
    158158    // if yes, go on checking other conditions
    159159    //
     
    191191    return Status;
    192192  }
    193  
     193
    194194  //
    195195  // Close the I/O Abstraction(s) used to perform the supported test
     
    238238                  EFI_OPEN_PROTOCOL_GET_PROTOCOL
    239239                  );
    240  
     240
    241241  if (EFI_ERROR (Status)) {
    242242    return Status;
    243243  }
    244  
     244
    245245  //
    246246  // Now further check the PCI header: Base class (offset 0x0B) and
     
    259259    // Examine if it is IDE mode by class code
    260260    //
    261     if ((PciData.Hdr.ClassCode[2] != PCI_CLASS_MASS_STORAGE) || (PciData.Hdr.ClassCode[1] != PCI_SUB_CLASS_IDE)) {     
     261    if ((PciData.Hdr.ClassCode[2] != PCI_CLASS_MASS_STORAGE) || (PciData.Hdr.ClassCode[1] != PCI_SUB_CLASS_IDE)) {
    262262      Status = EFI_UNSUPPORTED;
    263     } else {   
     263    } else {
    264264      Status = EFI_SUCCESS;
    265     } 
     265    }
    266266  }
    267267
     
    465465   if (EnumAll || RemainingDevicePath == NULL) {
    466466    //
    467     // If IdeInit->EnumAll is TRUE or RemainingDevicePath is NULL, 
     467    // If IdeInit->EnumAll is TRUE or RemainingDevicePath is NULL,
    468468    // must enumerate all IDE devices anyway
    469469    //
     
    475475  } else if (!IsDevicePathEnd (RemainingDevicePath)) {
    476476    //
    477     // If RemainingDevicePath isn't the End of Device Path Node, 
     477    // If RemainingDevicePath isn't the End of Device Path Node,
    478478    // only scan the specified device by RemainingDevicePath
    479479    //
     
    496496    // If RemainingDevicePath is the End of Device Path Node,
    497497    // skip enumerate any device and return EFI_SUCESSS
    498     // 
     498    //
    499499    BeginningIdeChannel = IdeMaxChannel;
    500500    EndIdeChannel       = IdeMaxChannel - 1;
     
    12991299
    13001300/**
    1301   This function is used by the IDE bus driver to get inquiry data. 
     1301  This function is used by the IDE bus driver to get inquiry data.
    13021302  Data format of Identify data is defined by the Interface GUID.
    13031303
     
    13071307
    13081308  @retval EFI_SUCCESS           The command was accepted without any errors.
    1309   @retval EFI_NOT_FOUND         Device does not support this data class 
    1310   @retval EFI_DEVICE_ERROR      Error reading InquiryData from device 
    1311   @retval EFI_BUFFER_TOO_SMALL  IntquiryDataSize not big enough 
     1309  @retval EFI_NOT_FOUND         Device does not support this data class
     1310  @retval EFI_DEVICE_ERROR      Error reading InquiryData from device
     1311  @retval EFI_BUFFER_TOO_SMALL  IntquiryDataSize not big enough
    13121312
    13131313**/
     
    13401340
    13411341/**
    1342   This function is used by the IDE bus driver to get identify data. 
     1342  This function is used by the IDE bus driver to get identify data.
    13431343  Data format of Identify data is defined by the Interface GUID.
    13441344
     
    13481348
    13491349  @retval EFI_SUCCESS           The command was accepted without any errors.
    1350   @retval EFI_NOT_FOUND         Device does not support this data class 
    1351   @retval EFI_DEVICE_ERROR      Error reading IdentifyData from device 
    1352   @retval EFI_BUFFER_TOO_SMALL  IdentifyDataSize not big enough 
     1350  @retval EFI_NOT_FOUND         Device does not support this data class
     1351  @retval EFI_DEVICE_ERROR      Error reading IdentifyData from device
     1352  @retval EFI_BUFFER_TOO_SMALL  IdentifyDataSize not big enough
    13531353
    13541354**/
     
    13811381
    13821382/**
    1383   This function is used by the IDE bus driver to get sense data. 
     1383  This function is used by the IDE bus driver to get sense data.
    13841384  Data format of Sense data is defined by the Interface GUID.
    13851385
    1386   @param  This                  Pointer to the EFI_DISK_INFO_PROTOCOL instance. 
    1387   @param  SenseData             Pointer to the SenseData. 
    1388   @param  SenseDataSize         Size of SenseData in bytes. 
     1386  @param  This                  Pointer to the EFI_DISK_INFO_PROTOCOL instance.
     1387  @param  SenseData             Pointer to the SenseData.
     1388  @param  SenseDataSize         Size of SenseData in bytes.
    13891389  @param  SenseDataNumber       Pointer to the value for the identify data size.
    13901390
    13911391  @retval EFI_SUCCESS           The command was accepted without any errors.
    1392   @retval EFI_NOT_FOUND         Device does not support this data class 
    1393   @retval EFI_DEVICE_ERROR      Error reading InquiryData from device 
    1394   @retval EFI_BUFFER_TOO_SMALL  SenseDataSize not big enough 
     1392  @retval EFI_NOT_FOUND         Device does not support this data class
     1393  @retval EFI_DEVICE_ERROR      Error reading InquiryData from device
     1394  @retval EFI_BUFFER_TOO_SMALL  SenseDataSize not big enough
    13951395
    13961396**/
     
    14101410  This function is used by the IDE bus driver to get controller information.
    14111411
    1412   @param  This                  Pointer to the EFI_DISK_INFO_PROTOCOL instance. 
     1412  @param  This                  Pointer to the EFI_DISK_INFO_PROTOCOL instance.
    14131413  @param  IdeChannel            Pointer to the Ide Channel number. Primary or secondary.
    14141414  @param  IdeDevice             Pointer to the Ide Device number. Master or slave.
    14151415
    1416   @retval EFI_SUCCESS           IdeChannel and IdeDevice are valid 
    1417   @retval EFI_UNSUPPORTED       This is not an IDE device 
     1416  @retval EFI_SUCCESS           IdeChannel and IdeDevice are valid
     1417  @retval EFI_UNSUPPORTED       This is not an IDE device
    14181418
    14191419**/
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/IdeBus.h

    r58459 r58466  
    182182//
    183183/**
    184   Allows the user to set controller specific options for a controller that a 
     184  Allows the user to set controller specific options for a controller that a
    185185  driver is currently managing.
    186186
     
    193193                            It will not be NULL for a bus driver that wishes to set
    194194                            options for one of its child controllers.
    195   @param  Language          A pointer to a three character ISO 639-2 language identifier. 
    196                             This is the language of the user interface that should be presented 
    197                             to the user, and it must match one of the languages specified in 
     195  @param  Language          A pointer to a three character ISO 639-2 language identifier.
     196                            This is the language of the user interface that should be presented
     197                            to the user, and it must match one of the languages specified in
    198198                            SupportedLanguages. The number of languages supported by a driver is up to
    199199                            the driver writer.
    200   @param  ActionRequired    A pointer to the action that the calling agent is required 
     200  @param  ActionRequired    A pointer to the action that the calling agent is required
    201201                            to perform when this function returns.
    202  
    203 
    204   @retval  EFI_SUCCESS           The driver specified by This successfully set the configuration 
     202
     203
     204  @retval  EFI_SUCCESS           The driver specified by This successfully set the configuration
    205205                                 options for the controller specified by ControllerHandle..
    206206  @retval  EFI_INVALID_PARAMETER ControllerHandle is not a valid EFI_HANDLE.
    207207  @retval  EFI_INVALID_PARAMETER ChildHandle is not NULL and it is not a valid EFI_HANDLE.
    208208  @retval  EFI_INVALID_PARAMETER ActionRequired is NULL.
    209   @retval  EFI_UNSUPPORTED       The driver specified by This does not support setting configuration options for 
     209  @retval  EFI_UNSUPPORTED       The driver specified by This does not support setting configuration options for
    210210                                 the controller specified by ControllerHandle and ChildHandle.
    211211  @retval  EFI_UNSUPPORTED       The driver specified by This does not support the language specified by Language.
    212   @retval  EFI_DEVICE_ERROR      A device error occurred while attempt to set the configuration options for the 
     212  @retval  EFI_DEVICE_ERROR      A device error occurred while attempt to set the configuration options for the
    213213                                 controller specified by ControllerHandle and ChildHandle.
    214   @retval  EFI_OUT_RESOURCES     There are not enough resources available to set the configuration options for the 
     214  @retval  EFI_OUT_RESOURCES     There are not enough resources available to set the configuration options for the
    215215                                 controller specified by ControllerHandle and ChildHandle
    216216**/
     
    229229
    230230  @param  This             A pointer to the EFI_DRIVER_CONFIGURATION_PROTOCOL instance.
    231   @param  ControllerHandle The handle of the controller to test if it's current configuration options 
     231  @param  ControllerHandle The handle of the controller to test if it's current configuration options
    232232                           are valid.
    233   @param  ChildHandle      The handle of the child controller to test if it's current configuration 
    234                            options are valid.  This is an optional parameter that may be NULL. It will 
     233  @param  ChildHandle      The handle of the child controller to test if it's current configuration
     234                           options are valid.  This is an optional parameter that may be NULL. It will
    235235                           be NULL for device drivers.  It will also be NULL for a bus drivers that
    236                            wish to test the configuration options for the bus controller. It will 
    237                            not be NULL for a bus driver that wishes to test configuration options for 
     236                           wish to test the configuration options for the bus controller. It will
     237                           not be NULL for a bus driver that wishes to test configuration options for
    238238                           one of its child controllers.
    239239  @retval  EFI_SUCCESS           The controller specified by ControllerHandle and ChildHandle that is being
     
    242242  @retval  EFI_INVALID_PARAMETER ControllerHandle is not a valid EFI_HANDLE.
    243243  @retval  EFI_INVALID_PARAMETER ChildHandle is not NULL and it is not a valid EFI_HANDLE.
    244   @retval  EFI_UNSUPPORTED       The driver specified by This is not currently  managing the controller 
     244  @retval  EFI_UNSUPPORTED       The driver specified by This is not currently  managing the controller
    245245                                 specified by ControllerHandle and ChildHandle.
    246246  @retval  EFI_DEVICE_ERROR      The controller specified by ControllerHandle and ChildHandle that is being
     
    261261  @param  This             A pointer to the EFI_DRIVER_CONFIGURATION_ PROTOCOL instance.
    262262  @param  ControllerHandle The handle of the controller to force default configuration options on.
    263   @param  ChildHandle      The handle of the child controller to force default configuration 
    264                            options on  This is an optional parameter that may be NULL.  It 
    265                            will be NULL for device drivers. It will also be NULL for a bus 
     263  @param  ChildHandle      The handle of the child controller to force default configuration
     264                           options on  This is an optional parameter that may be NULL.  It
     265                           will be NULL for device drivers. It will also be NULL for a bus
    266266                           drivers that wish to force default configuration options for the bus
    267267                           controller.  It will not be NULL for a bus driver that wishes to force
    268268                           default configuration options for one of its child controllers.
    269   @param  DefaultType      The type of default configuration options to force on the controller 
    270                            specified by ControllerHandle and ChildHandle. 
    271   @param  ActionRequired   A pointer to the action that the calling agent is required to perform 
     269  @param  DefaultType      The type of default configuration options to force on the controller
     270                           specified by ControllerHandle and ChildHandle.
     271  @param  ActionRequired   A pointer to the action that the calling agent is required to perform
    272272                           when this function returns.
    273273
    274   @retval  EFI_SUCCESS           The driver specified by This successfully forced the 
    275                                  default configuration options on the controller specified by 
     274  @retval  EFI_SUCCESS           The driver specified by This successfully forced the
     275                                 default configuration options on the controller specified by
    276276                                 ControllerHandle and ChildHandle.
    277277  @retval  EFI_INVALID_PARAMETER ControllerHandle is not a valid EFI_HANDLE.
    278278  @retval  EFI_INVALID_PARAMETER ChildHandle is not NULL and it is not a valid EFI_HANDLE.
    279279  @retval  EFI_INVALID_PARAMETER ActionRequired is NULL.
    280   @retval  EFI_UNSUPPORTED       The driver specified by This does not support forcing the default 
     280  @retval  EFI_UNSUPPORTED       The driver specified by This does not support forcing the default
    281281                                 configuration options on the controller specified by ControllerHandle
    282282                                 and ChildHandle.
    283   @retval  EFI_UNSUPPORTED       The driver specified by This does not support the configuration type 
     283  @retval  EFI_UNSUPPORTED       The driver specified by This does not support the configuration type
    284284                                 specified by DefaultType.
    285   @retval  EFI_DEVICE_ERROR      A device error occurred while attempt to force the default configuration 
     285  @retval  EFI_DEVICE_ERROR      A device error occurred while attempt to force the default configuration
    286286                                 options on the controller specified by  ControllerHandle and ChildHandle.
    287   @retval  EFI_OUT_RESOURCES     There are not enough resources available to force the default configuration 
     287  @retval  EFI_OUT_RESOURCES     There are not enough resources available to force the default configuration
    288288                                 options on the controller specified by ControllerHandle and ChildHandle.
    289289**/
     
    309309                           This is an optional parameter that may be NULL.  It will
    310310                           be NULL for device drivers.  It will also be NULL for a
    311                            bus drivers that wish to run diagnostics on the bus controller. 
    312                            It will not be NULL for a bus driver that wishes to run 
     311                           bus drivers that wish to run diagnostics on the bus controller.
     312                           It will not be NULL for a bus driver that wishes to run
    313313                           diagnostics on one of its child controllers.
    314314  @param  DiagnosticType   Indicates type of diagnostics to perform on the controller
    315315                           specified by ControllerHandle and ChildHandle.
    316   @param  Language         A pointer to a three character ISO 639-2 language identifier. 
    317                            This is the language in which the optional error message should 
    318                            be returned in Buffer, and it must match one of the languages 
     316  @param  Language         A pointer to a three character ISO 639-2 language identifier.
     317                           This is the language in which the optional error message should
     318                           be returned in Buffer, and it must match one of the languages
    319319                           specified in SupportedLanguages. The number of languages supported by
    320320                           a driver is up to the driver writer.
     
    322322  @param  BufferSize       The size, in bytes, of the data returned in Buffer.
    323323  @param  Buffer           A buffer that contains a Null-terminated Unicode string
    324                            plus some additional data whose format is defined by ErrorType. 
    325                            Buffer is allocated by this function with AllocatePool(), and 
     324                           plus some additional data whose format is defined by ErrorType.
     325                           Buffer is allocated by this function with AllocatePool(), and
    326326                           it is the caller's responsibility to free it with a call to FreePool().
    327327
    328   @retval  EFI_SUCCESS           The controller specified by ControllerHandle and ChildHandle passed 
     328  @retval  EFI_SUCCESS           The controller specified by ControllerHandle and ChildHandle passed
    329329                                 the diagnostic.
    330330  @retval  EFI_INVALID_PARAMETER ControllerHandle is NULL.
     
    334334  @retval  EFI_INVALID_PARAMETER BufferType is NULL.
    335335  @retval  EFI_INVALID_PARAMETER Buffer is NULL.
    336   @retval  EFI_UNSUPPORTED       The driver specified by This does not support running 
    337                                  diagnostics for the controller specified by ControllerHandle 
     336  @retval  EFI_UNSUPPORTED       The driver specified by This does not support running
     337                                 diagnostics for the controller specified by ControllerHandle
    338338                                 and ChildHandle.
    339339  @retval  EFI_UNSUPPORTED       The driver specified by This does not support the
    340340                                 type of diagnostic specified by DiagnosticType.
    341   @retval  EFI_UNSUPPORTED       The driver specified by This does not support the language 
     341  @retval  EFI_UNSUPPORTED       The driver specified by This does not support the language
    342342                                 specified by Language.
    343   @retval  EFI_OUT_OF_RESOURCES  There are not enough resources available to complete the 
     343  @retval  EFI_OUT_OF_RESOURCES  There are not enough resources available to complete the
    344344                                 diagnostics.
    345   @retval  EFI_OUT_OF_RESOURCES  There are not enough resources available to return the 
     345  @retval  EFI_OUT_OF_RESOURCES  There are not enough resources available to return the
    346346                                 status information in ErrorType, BufferSize,and Buffer.
    347   @retval  EFI_DEVICE_ERROR      The controller specified by ControllerHandle and ChildHandle 
     347  @retval  EFI_DEVICE_ERROR      The controller specified by ControllerHandle and ChildHandle
    348348                                 did not pass the diagnostic.
    349349**/
     
    428428  Flushes all modified data to a physical block devices
    429429
    430   @param  This  Indicates a pointer to the calling context which to sepcify a 
     430  @param  This  Indicates a pointer to the calling context which to sepcify a
    431431                sepcific block device
    432432
     
    439439  );
    440440/**
    441   This function is used by the IDE bus driver to get inquiry data. 
     441  This function is used by the IDE bus driver to get inquiry data.
    442442  Data format of Identify data is defined by the Interface GUID.
    443443
     
    447447
    448448  @retval EFI_SUCCESS           The command was accepted without any errors.
    449   @retval EFI_NOT_FOUND         Device does not support this data class 
    450   @retval EFI_DEVICE_ERROR      Error reading InquiryData from device 
    451   @retval EFI_BUFFER_TOO_SMALL  IntquiryDataSize not big enough 
     449  @retval EFI_NOT_FOUND         Device does not support this data class
     450  @retval EFI_DEVICE_ERROR      Error reading InquiryData from device
     451  @retval EFI_BUFFER_TOO_SMALL  IntquiryDataSize not big enough
    452452
    453453**/
     
    461461
    462462/**
    463   This function is used by the IDE bus driver to get identify data. 
     463  This function is used by the IDE bus driver to get identify data.
    464464  Data format of Identify data is defined by the Interface GUID.
    465465
     
    469469
    470470  @retval EFI_SUCCESS           The command was accepted without any errors.
    471   @retval EFI_NOT_FOUND         Device does not support this data class 
    472   @retval EFI_DEVICE_ERROR      Error reading IdentifyData from device 
    473   @retval EFI_BUFFER_TOO_SMALL  IdentifyDataSize not big enough 
     471  @retval EFI_NOT_FOUND         Device does not support this data class
     472  @retval EFI_DEVICE_ERROR      Error reading IdentifyData from device
     473  @retval EFI_BUFFER_TOO_SMALL  IdentifyDataSize not big enough
    474474
    475475**/
     
    483483
    484484/**
    485   This function is used by the IDE bus driver to get sense data. 
     485  This function is used by the IDE bus driver to get sense data.
    486486  Data format of Sense data is defined by the Interface GUID.
    487487
    488   @param  This                  Pointer to the EFI_DISK_INFO_PROTOCOL instance. 
    489   @param  SenseData             Pointer to the SenseData. 
    490   @param  SenseDataSize         Size of SenseData in bytes. 
     488  @param  This                  Pointer to the EFI_DISK_INFO_PROTOCOL instance.
     489  @param  SenseData             Pointer to the SenseData.
     490  @param  SenseDataSize         Size of SenseData in bytes.
    491491  @param  SenseDataNumber       Pointer to the value for the identify data size.
    492492
    493493  @retval EFI_SUCCESS           The command was accepted without any errors.
    494   @retval EFI_NOT_FOUND         Device does not support this data class 
    495   @retval EFI_DEVICE_ERROR      Error reading InquiryData from device 
    496   @retval EFI_BUFFER_TOO_SMALL  SenseDataSize not big enough 
     494  @retval EFI_NOT_FOUND         Device does not support this data class
     495  @retval EFI_DEVICE_ERROR      Error reading InquiryData from device
     496  @retval EFI_BUFFER_TOO_SMALL  SenseDataSize not big enough
    497497
    498498**/
     
    509509  This function is used by the IDE bus driver to get controller information.
    510510
    511   @param  This                  Pointer to the EFI_DISK_INFO_PROTOCOL instance. 
     511  @param  This                  Pointer to the EFI_DISK_INFO_PROTOCOL instance.
    512512  @param  IdeChannel            Pointer to the Ide Channel number. Primary or secondary.
    513513  @param  IdeDevice             Pointer to the Ide Device number. Master or slave.
    514514
    515   @retval EFI_SUCCESS           IdeChannel and IdeDevice are valid 
    516   @retval EFI_UNSUPPORTED       This is not an IDE device 
     515  @retval EFI_SUCCESS           IdeChannel and IdeDevice are valid
     516  @retval EFI_UNSUPPORTED       This is not an IDE device
    517517
    518518**/
     
    525525  );
    526526/**
    527   The is an event(generally the event is exitBootService event) call back function. 
     527  The is an event(generally the event is exitBootService event) call back function.
    528528  Clear pending IDE interrupt before OS loader/kernel take control of the IDE device.
    529529
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/IdeBusDxe.inf

    r58459 r58466  
    3030#  VALID_ARCHITECTURES           = IA32 X64 IPF EBC
    3131#
    32 #  DRIVER_BINDING                =  gIDEBusDriverBinding                         
     32#  DRIVER_BINDING                =  gIDEBusDriverBinding
    3333#  COMPONENT_NAME                =  gIDEBusComponentName
    34 #  COMPONENT_NAME2               =  gIDEBusComponentName2                         
     34#  COMPONENT_NAME2               =  gIDEBusComponentName2
    3535#  Variable Guid C Name: gConfigurationGuid Variable Name: L"Configuration"
    3636#
     
    5454  MdePkg/MdePkg.dec
    5555  IntelFrameworkPkg/IntelFrameworkPkg.dec
    56   IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec 
     56  IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec
    5757
    5858
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Pci/IdeBusDxe/IdeData.h

    r48674 r58466  
    33
    44  Copyright (c) 2006 - 2007, Intel Corporation. All rights reserved.<BR>
    5   This program and the accompanying materials                         
    6   are licensed and made available under the terms and conditions of the BSD License         
    7   which accompanies this distribution.  The full text of the license may be found at       
    8   http://opensource.org/licenses/bsd-license.php                                           
    9 
    10   THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
    11   WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             
     5  This program and the accompanying materials
     6  are licensed and made available under the terms and conditions of the BSD License
     7  which accompanies this distribution.  The full text of the license may be found at
     8  http://opensource.org/licenses/bsd-license.php
     9
     10  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     11  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
    1313**/
     
    143143// 1 second
    144144//
    145 #define ATATIMEOUT  1000 
     145#define ATATIMEOUT  1000
    146146
    147147//
     
    153153// 1 second
    154154//
    155 #define ATAPITIMEOUT  1000 
     155#define ATAPITIMEOUT  1000
    156156
    157157//
     
    163163// 2 seconds
    164164//
    165 #define CDROMLONGTIMEOUT  2000 
     165#define CDROMLONGTIMEOUT  2000
    166166
    167167//
    168168// 5 seconds
    169169//
    170 #define ATAPILONGTIMEOUT  5000 
     170#define ATAPILONGTIMEOUT  5000
    171171
    172172//
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Pci/VgaMiniPortDxe/ComponentName.c

    r48674 r58466  
    11/** @file
    22  Implements EFI Component Name Protocol for VGA Mini Port Driver.
    3  
     3
    44Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
    55This program and the accompanying materials
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Pci/VgaMiniPortDxe/VgaMiniPort.c

    r48674 r58466  
    307307  If ModeNumber exceeds the valid range, then EFI_UNSUPPORTED is returned.
    308308  Otherwise, EFI_SUCCESS is directly returned without real operation.
    309  
     309
    310310  @param This                 Protocol instance pointer.
    311311  @param ModeNumber           Mode number.  0 - 80x25   1-80x50
     
    314314  @retval EFI_UNSUPPORTED     ModeNumber is not supported.
    315315  @retval EFI_DEVICE_ERROR    The device is not functioning properly.
    316  
     316
    317317**/
    318318EFI_STATUS
     
    329329  return EFI_SUCCESS;
    330330}
    331  
     331
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Pci/VgaMiniPortDxe/VgaMiniPort.h

    r48674 r58466  
    253253  If ModeNumber exceeds the valid range, then EFI_UNSUPPORTED is returned.
    254254  Otherwise, EFI_SUCCESS is directly returned without real operation.
    255  
     255
    256256  @param This                 Protocol instance pointer.
    257257  @param ModeNumber           Mode number.  0 - 80x25   1-80x50
     
    260260  @retval EFI_UNSUPPORTED     ModeNumber is not supported.
    261261  @retval EFI_DEVICE_ERROR    The device is not functioning properly.
    262  
     262
    263263**/
    264264EFI_STATUS
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Bus/Pci/VgaMiniPortDxe/VgaMiniPortDxe.inf

    r58459 r58466  
    3030#  DRIVER_BINDING                = gPciVgaMiniPortDriverBinding;
    3131#  COMPONENT_NAME                = gPciVgaMiniPortComponentName;
    32 #  COMPONENT_NAME2               = gPciVgaMiniPortComponentName2; 
     32#  COMPONENT_NAME2               = gPciVgaMiniPortComponentName2;
    3333#
    3434
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/BiosThunk/BlockIoDxe/BiosBlkIo.c

    r48674 r58466  
    157157    return Status;
    158158  }
    159  
     159
    160160  gBS->CloseProtocol (
    161161        Controller,
     
    163163        This->DriverBindingHandle,
    164164        Controller
    165         );     
    166  
     165        );
     166
    167167  //
    168168  // Open the IO Abstraction(s) needed to perform the supported test
     
    244244  PciIo      = NULL;
    245245  PciDevPath = NULL;
    246  
    247   DeviceEnable = FALSE; 
     246
     247  DeviceEnable = FALSE;
    248248
    249249  //
     
    293293    goto Error;
    294294  }
    295  
     295
    296296  DeviceEnable = TRUE;
    297  
     297
    298298  //
    299299  // Check to see if there is a legacy option ROM image associated with this PCI device
     
    636636  EFI_STATUS                  Status;
    637637  BLOCKIO_VENDOR_DEVICE_PATH  VendorNode;
    638  
     638
    639639  Status = EFI_UNSUPPORTED;
    640  
     640
    641641  //
    642642  // BugBug: Check for memory leaks!
     
    648648    Status = BuildEdd30DevicePath (BaseDevicePath, Drive, DevicePath);
    649649  }
    650  
     650
    651651  if (EFI_ERROR (Status)) {
    652652    //
     
    768768        Drive->Parameters.InterfaceType
    769769        )
    770         );     
     770        );
    771771    }
    772772  }
     
    775775    return EFI_UNSUPPORTED;
    776776  }
    777  
     777
    778778  *DevicePath = AppendDevicePathNode (BaseDevicePath, &Node.DevPath);
    779779  return EFI_SUCCESS;
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/BiosThunk/BlockIoDxe/BiosBlkIo.h

    r48674 r58466  
    174174  @retval EFI_MEDIA_CHANGED     The MediaId does not matched the current device.
    175175  @retval EFI_BAD_BUFFER_SIZE   The Buffer was not a multiple of the block size of the device.
    176   @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid, 
     176  @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid,
    177177                                or the buffer is not on proper alignment.
    178178
     
    204204  @retval EFI_MEDIA_CHNAGED     The MediaId does not matched the current device.
    205205  @retval EFI_BAD_BUFFER_SIZE   The Buffer was not a multiple of the block size of the device.
    206   @retval EFI_INVALID_PARAMETER The write request contains LBAs that are not valid, 
     206  @retval EFI_INVALID_PARAMETER The write request contains LBAs that are not valid,
    207207                                or the buffer is not on proper alignment.
    208208
     
    267267  @retval EFI_MEDIA_CHANGED     The MediaId does not matched the current device.
    268268  @retval EFI_BAD_BUFFER_SIZE   The Buffer was not a multiple of the block size of the device.
    269   @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid, 
     269  @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid,
    270270                                or the buffer is not on proper alignment.
    271271
     
    297297  @retval EFI_MEDIA_CHNAGED     The MediaId does not matched the current device.
    298298  @retval EFI_BAD_BUFFER_SIZE   The Buffer was not a multiple of the block size of the device.
    299   @retval EFI_INVALID_PARAMETER The write request contains LBAs that are not valid, 
     299  @retval EFI_INVALID_PARAMETER The write request contains LBAs that are not valid,
    300300                                or the buffer is not on proper alignment.
    301301
     
    326326  @retval EFI_MEDIA_CHANGED     The MediaId does not matched the current device.
    327327  @retval EFI_BAD_BUFFER_SIZE   The Buffer was not a multiple of the block size of the device.
    328   @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid, 
     328  @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid,
    329329                                or the buffer is not on proper alignment.
    330330
     
    356356  @retval EFI_MEDIA_CHNAGED     The MediaId does not matched the current device.
    357357  @retval EFI_BAD_BUFFER_SIZE   The Buffer was not a multiple of the block size of the device.
    358   @retval EFI_INVALID_PARAMETER The write request contains LBAs that are not valid, 
     358  @retval EFI_INVALID_PARAMETER The write request contains LBAs that are not valid,
    359359                                or the buffer is not on proper alignment.
    360360
     
    377377
    378378  @return  Result of device parameter retrieval.
    379  
     379
    380380**/
    381381UINTN
     
    392392
    393393  @return  Result of this extension.
    394  
     394
    395395**/
    396396UINTN
     
    407407
    408408  @return  Result of drive parameter retrieval.
    409  
     409
    410410**/
    411411UINTN
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/BiosThunk/BlockIoDxe/BiosInt13.c

    r48674 r58466  
    131131
    132132  @return  Result of device parameter retrieval.
    133  
     133
    134134**/
    135135UINTN
     
    186186
    187187  @return  Result of this extension.
    188  
     188
    189189**/
    190190UINTN
     
    228228
    229229  @return  Result of drive parameter retrieval.
    230  
     230
    231231**/
    232232UINTN
     
    407407  @retval EFI_MEDIA_CHANGED     The MediaId does not matched the current device.
    408408  @retval EFI_BAD_BUFFER_SIZE   The Buffer was not a multiple of the block size of the device.
    409   @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid, 
     409  @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid,
    410410                                or the buffer is not on proper alignment.
    411411
     
    555555  @retval EFI_MEDIA_CHNAGED     The MediaId does not matched the current device.
    556556  @retval EFI_BAD_BUFFER_SIZE   The Buffer was not a multiple of the block size of the device.
    557   @retval EFI_INVALID_PARAMETER The write request contains LBAs that are not valid, 
     557  @retval EFI_INVALID_PARAMETER The write request contains LBAs that are not valid,
    558558                                or the buffer is not on proper alignment.
    559559
     
    790790  @retval EFI_MEDIA_CHANGED     The MediaId does not matched the current device.
    791791  @retval EFI_BAD_BUFFER_SIZE   The Buffer was not a multiple of the block size of the device.
    792   @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid, 
     792  @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid,
    793793                                or the buffer is not on proper alignment.
    794794
     
    943943  @retval EFI_MEDIA_CHNAGED     The MediaId does not matched the current device.
    944944  @retval EFI_BAD_BUFFER_SIZE   The Buffer was not a multiple of the block size of the device.
    945   @retval EFI_INVALID_PARAMETER The write request contains LBAs that are not valid, 
     945  @retval EFI_INVALID_PARAMETER The write request contains LBAs that are not valid,
    946946                                or the buffer is not on proper alignment.
    947947
     
    11041104  @retval EFI_MEDIA_CHANGED     The MediaId does not matched the current device.
    11051105  @retval EFI_BAD_BUFFER_SIZE   The Buffer was not a multiple of the block size of the device.
    1106   @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid, 
     1106  @retval EFI_INVALID_PARAMETER The read request contains LBAs that are not valid,
    11071107                                or the buffer is not on proper alignment.
    11081108
     
    13061306  @retval EFI_MEDIA_CHNAGED     The MediaId does not matched the current device.
    13071307  @retval EFI_BAD_BUFFER_SIZE   The Buffer was not a multiple of the block size of the device.
    1308   @retval EFI_INVALID_PARAMETER The write request contains LBAs that are not valid, 
     1308  @retval EFI_INVALID_PARAMETER The write request contains LBAs that are not valid,
    13091309                                or the buffer is not on proper alignment.
    13101310
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/BiosThunk/KeyboardDxe/BiosKeyboard.c

    r58459 r58466  
    5959/**
    6060  Dequeue the key.
    61  
     61
    6262  @param  Queue                 The queue to be dequeued.
    6363  @param  KeyData               The key data to be dequeued.
     
    8686/**
    8787  Check whether the queue is empty.
    88  
     88
    8989  @param  Queue                 The queue to be checked.
    9090
     
    270270  BiosKeyboardPrivate->CommandRegisterAddress     = KEYBOARD_8042_COMMAND_REGISTER;
    271271  BiosKeyboardPrivate->ExtendedKeyboard           = TRUE;
    272  
     272
    273273  BiosKeyboardPrivate->Queue.Front                = 0;
    274274  BiosKeyboardPrivate->Queue.Rear                 = 0;
     
    276276  BiosKeyboardPrivate->SimpleTextInputEx.ReadKeyStrokeEx     = BiosKeyboardReadKeyStrokeEx;
    277277  BiosKeyboardPrivate->SimpleTextInputEx.SetState            = BiosKeyboardSetState;
    278   BiosKeyboardPrivate->SimpleTextInputEx.RegisterKeyNotify   = BiosKeyboardRegisterKeyNotify; 
    279   BiosKeyboardPrivate->SimpleTextInputEx.UnregisterKeyNotify = BiosKeyboardUnregisterKeyNotify;   
     278  BiosKeyboardPrivate->SimpleTextInputEx.RegisterKeyNotify   = BiosKeyboardRegisterKeyNotify;
     279  BiosKeyboardPrivate->SimpleTextInputEx.UnregisterKeyNotify = BiosKeyboardUnregisterKeyNotify;
    280280  InitializeListHead (&BiosKeyboardPrivate->NotifyList);
    281281
     
    312312    BiosKeyboardPrivate->SimpleTextInputEx.WaitForKeyEx = NULL;
    313313    goto Done;
    314   } 
     314  }
    315315
    316316  //
     
    340340    goto Done;
    341341  }
    342  
     342
    343343  //
    344344  // Report a Progress Code for an attempt to detect the precense of the keyboard device in the system
     
    357357                                                    );
    358358  if (EFI_ERROR (Status)) {
    359     DEBUG ((EFI_D_ERROR, "[KBD]Reset Failed. Status - %r\n", Status)); 
     359    DEBUG ((EFI_D_ERROR, "[KBD]Reset Failed. Status - %r\n", Status));
    360360    StatusCode = EFI_PERIPHERAL_KEYBOARD | EFI_P_EC_NOT_DETECTED;
    361361    goto Done;
     
    455455  if (EFI_ERROR (Status)) {
    456456
    457     if (BiosKeyboardPrivate != NULL) {   
     457    if (BiosKeyboardPrivate != NULL) {
    458458      if ((BiosKeyboardPrivate->SimpleTextIn).WaitForKey != NULL) {
    459459        gBS->CloseEvent ((BiosKeyboardPrivate->SimpleTextIn).WaitForKey);
     
    461461
    462462      if ((BiosKeyboardPrivate->SimpleTextInputEx).WaitForKeyEx != NULL) {
    463         gBS->CloseEvent ((BiosKeyboardPrivate->SimpleTextInputEx).WaitForKeyEx);   
     463        gBS->CloseEvent ((BiosKeyboardPrivate->SimpleTextInputEx).WaitForKeyEx);
    464464      }
    465465      BiosKeyboardFreeNotifyList (&BiosKeyboardPrivate->NotifyList);
    466466
    467467      if (BiosKeyboardPrivate->TimerEvent != NULL) {
    468         gBS->CloseEvent (BiosKeyboardPrivate->TimerEvent);   
     468        gBS->CloseEvent (BiosKeyboardPrivate->TimerEvent);
    469469      }
    470470
     
    537537    return Status;
    538538  }
    539  
     539
    540540  BiosKeyboardPrivate = BIOS_KEYBOARD_DEV_FROM_THIS (SimpleTextIn);
    541541
     
    908908
    909909/**
    910   Reads the next keystroke from the input device. The WaitForKey Event can 
     910  Reads the next keystroke from the input device. The WaitForKey Event can
    911911  be used to test for existance of a keystroke via WaitForEvent () call.
    912912
    913913  @param  BiosKeyboardPrivate   Bioskeyboard driver private structure.
    914   @param  KeyData               A pointer to a buffer that is filled in with the keystroke 
     914  @param  KeyData               A pointer to a buffer that is filled in with the keystroke
    915915                                state data for the key that was pressed.
    916916
    917917  @retval EFI_SUCCESS           The keystroke information was returned.
    918918  @retval EFI_NOT_READY         There was no keystroke data availiable.
    919   @retval EFI_DEVICE_ERROR      The keystroke information was not returned due to 
     919  @retval EFI_DEVICE_ERROR      The keystroke information was not returned due to
    920920                                hardware errors.
    921   @retval EFI_INVALID_PARAMETER KeyData is NULL.                       
    922    
     921  @retval EFI_INVALID_PARAMETER KeyData is NULL.
     922
    923923**/
    924924EFI_STATUS
     
    937937  // Use TimerEvent callback funciton to check whether there's any key pressed
    938938  //
    939  
     939
    940940  //
    941941  // Stall 1ms to give a chance to let other driver interrupt this routine for their timer event.
    942   // Csm will be used to check whether there is a key pending, but the csm will disable all 
     942  // Csm will be used to check whether there is a key pending, but the csm will disable all
    943943  // interrupt before switch to compatibility16, which mean all the efiCompatibility timer
    944   // event will stop work during the compatibility16. And If a caller recursivly invoke this function, 
    945   // e.g. OS loader, other drivers which are driven by timer event will have a bad performance during this period, 
    946   // e.g. usb keyboard driver. 
     944  // event will stop work during the compatibility16. And If a caller recursivly invoke this function,
     945  // e.g. OS loader, other drivers which are driven by timer event will have a bad performance during this period,
     946  // e.g. usb keyboard driver.
    947947  // Add a stall period can greatly increate other driver performance during the WaitForKey is recursivly invoked.
    948948  // 1ms delay will make little impact to the thunk keyboard driver, and user can not feel the delay at all when input.
     
    10511051                 KBC_CMDREG_VIA64_CMDBYTE_R
    10521052                 );
    1053      
     1053
    10541054      if (EFI_ERROR (Status)) {
    10551055        Status    = EFI_DEVICE_ERROR;
    10561056        goto Exit;
    10571057      }
    1058      
     1058
    10591059      Status = KeyboardRead (
    10601060                 BiosKeyboardPrivate,
    10611061                 &CommandByte
    10621062                 );
    1063      
     1063
    10641064      if (EFI_ERROR (Status)) {
    10651065        Status    = EFI_DEVICE_ERROR;
     
    10821082                 KBC_CMDREG_VIA64_AUX_DISABLE
    10831083                 );
    1084      
     1084
    10851085      if (EFI_ERROR (Status)) {
    10861086        Status    = EFI_DEVICE_ERROR;
    10871087        goto Exit;
    10881088      }
    1089      
     1089
    10901090      Status = KeyboardCommand (
    10911091                 BiosKeyboardPrivate,
    10921092                 KBC_CMDREG_VIA64_KB_DISABLE
    10931093                 );
    1094      
     1094
    10951095      if (EFI_ERROR (Status)) {
    10961096        Status    = EFI_DEVICE_ERROR;
     
    11041104      //
    11051105      // Report a Progress Code for performing a self test on the keyboard controller
    1106       //   
     1106      //
    11071107      REPORT_STATUS_CODE (
    11081108        EFI_PROGRESS_CODE,
    11091109        EFI_PERIPHERAL_KEYBOARD | EFI_P_KEYBOARD_PC_SELF_TEST
    11101110        );
    1111      
     1111
    11121112      Status = KeyboardCommand (
    11131113                 BiosKeyboardPrivate,
     
    11181118        goto Exit;
    11191119      }
    1120      
     1120
    11211121      Status = KeyboardWaitForValue (
    11221122                 BiosKeyboardPrivate,
     
    13281328               KBC_CMDREG_VIA64_KB_ENABLE
    13291329               );
    1330    
     1330
    13311331    if (EFI_ERROR (Status)) {
    13321332      Status    = EFI_DEVICE_ERROR;
     
    14011401  }
    14021402
    1403   CopyMem (Key, &KeyData.Key, sizeof (EFI_INPUT_KEY)); 
     1403  CopyMem (Key, &KeyData.Key, sizeof (EFI_INPUT_KEY));
    14041404
    14051405  return EFI_SUCCESS;
     
    14451445
    14461446  @param  This         Pointer of the protocol EFI_SIMPLE_TEXT_IN_PROTOCOL.
    1447  
     1447
    14481448  @retval EFI_SUCCESS  A key is being pressed now.
    14491449  @retval Other        No key is now pressed.
     
    16201620  @param  ScanCode     Scan code of key.
    16211621
    1622   @return The value of EFI Scancode for the key.   
     1622  @return The value of EFI Scancode for the key.
    16231623  @retval SCAN_NULL   No corresponding value in the EFI convert table is found for the key.
    16241624
     
    16581658  Check whether there is Ps/2 Keyboard device in system by 0xF4 Keyboard Command
    16591659  If Keyboard receives 0xF4, it will respond with 'ACK'. If it doesn't respond, the device
    1660   should not be in system. 
     1660  should not be in system.
    16611661
    16621662  @param  BiosKeyboardPrivate  Keyboard Private Data Struture
     
    17141714/**
    17151715  Timer event handler: read a series of key stroke from 8042
    1716   and put them into memory key buffer. 
     1716  and put them into memory key buffer.
    17171717  It is registered as running under TPL_NOTIFY
    1718  
     1718
    17191719  @param  Event   The timer event
    17201720  @param  Context A BIOS_KEYBOARD_DEV pointer
     
    17611761    gBS->RestoreTPL (OldTpl);
    17621762    return;
    1763   } 
     1763  }
    17641764
    17651765  //
     
    17861786    KeyData.Key.UnicodeChar
    17871787    ));
    1788  
     1788
    17891789  KeyData.KeyState.KeyShiftState  = EFI_SHIFT_STATE_VALID;
    17901790  KeyData.KeyState.KeyToggleState = EFI_TOGGLE_STATE_VALID;
    17911791  //
    1792   // Leagcy Bios use Int 9 which is IRQ1 interrupt handler to get keystroke scancode to KB  buffer in BDA (BIOS DATE AREA),  then 
    1793   // Int 16 depend  KB buffer and some key bits in BDA to translate the scancode to ASCII code, and  return both the scancode and ASCII 
    1794   // code to Int 16 caller. This translation process works well if the Int 9  could response user input in time. But in Tiano enviorment,  the Int 9 
    1795   // will be disabled after the thunk call finish, which means if user crazy input during int 9 being disabled, some keystrokes will be lost when 
    1796   // KB device own hardware buffer overflows. And if the lost keystroke code is CTRL or ALT or SHIFT release code, these function key flags bit 
    1797   // in BDA will not be updated. So the Int 16 will believe the CTRL or ALT or SHIFT is still pressed, and Int 16 will translate later scancode 
    1798   // to wrong ASCII code. We can increase the Thunk frequence to let Int 9 response in time, but this way will much hurt other dirvers 
     1792  // Leagcy Bios use Int 9 which is IRQ1 interrupt handler to get keystroke scancode to KB  buffer in BDA (BIOS DATE AREA),  then
     1793  // Int 16 depend  KB buffer and some key bits in BDA to translate the scancode to ASCII code, and  return both the scancode and ASCII
     1794  // code to Int 16 caller. This translation process works well if the Int 9  could response user input in time. But in Tiano enviorment,  the Int 9
     1795  // will be disabled after the thunk call finish, which means if user crazy input during int 9 being disabled, some keystrokes will be lost when
     1796  // KB device own hardware buffer overflows. And if the lost keystroke code is CTRL or ALT or SHIFT release code, these function key flags bit
     1797  // in BDA will not be updated. So the Int 16 will believe the CTRL or ALT or SHIFT is still pressed, and Int 16 will translate later scancode
     1798  // to wrong ASCII code. We can increase the Thunk frequence to let Int 9 response in time, but this way will much hurt other dirvers
    17991799  // performance, like USB.
    18001800  //
    1801   // 1. If CTRL or ALT release code is missed,  all later input keys will be translated to wrong ASCII codes which the Tiano cannot support. In 
    1802   //     this case, the KB input seems fail to work, and user input is blocked. To solve the problem, we can help to clear the CTRL or ALT flag in BDA 
    1803   //    after every Int 16 finish. Thus persist to press CTRL or ALT has same effection as only press one time. It is Ok, since user not often use the 
     1801  // 1. If CTRL or ALT release code is missed,  all later input keys will be translated to wrong ASCII codes which the Tiano cannot support. In
     1802  //     this case, the KB input seems fail to work, and user input is blocked. To solve the problem, we can help to clear the CTRL or ALT flag in BDA
     1803  //    after every Int 16 finish. Thus persist to press CTRL or ALT has same effection as only press one time. It is Ok, since user not often use the
    18041804  //    CTRL and ALT.
    18051805  //
    1806   // 2. If SHIFT release code is missed, all later lowercase input will become capital. This is ugly, but not block user input. If user press the lost 
     1806  // 2. If SHIFT release code is missed, all later lowercase input will become capital. This is ugly, but not block user input. If user press the lost
    18071807  //     SHIFT again,  the lowercase will come back to normal. Since user often use the SHIFT, it is not reasonable to help to clear the SHIFT flag in BDA,
    1808   //     which will let persist to press SHIFT has same effection as only press one time. 
     1808  //     which will let persist to press SHIFT has same effection as only press one time.
    18091809  //
    18101810  //0040h:0017h - KEYBOARD - STATUS FLAGS 1
     
    18351835      if ((KbFlag1 & KB_SCROLL_LOCK_BIT) == KB_SCROLL_LOCK_BIT) {
    18361836        DEBUG ((EFI_D_INFO, "[KBD]Scroll Lock Key is pressed.\n"));
    1837       } 
     1837      }
    18381838      if ((KbFlag1 & KB_ALT_PRESSED) == KB_ALT_PRESSED) {
    18391839        if ((KbFlag2 & KB_LEFT_ALT_PRESSED) == KB_LEFT_ALT_PRESSED) {
     
    18421842          DEBUG ((EFI_D_INFO, "[KBD]Right Alt Key is pressed.\n"));
    18431843        }
    1844       } 
     1844      }
    18451845      if ((KbFlag1 & KB_CTRL_PRESSED) == KB_CTRL_PRESSED) {
    18461846        if ((KbFlag2 & KB_LEFT_CTRL_PRESSED) == KB_LEFT_CTRL_PRESSED) {
     
    18491849          DEBUG ((EFI_D_INFO, "[KBD]Right Ctrl Key is pressed.\n"));
    18501850        }
    1851       } 
     1851      }
    18521852      if ((KbFlag1 & KB_LEFT_SHIFT_PRESSED) == KB_LEFT_SHIFT_PRESSED) {
    18531853        DEBUG ((EFI_D_INFO, "[KBD]Left Shift Key is pressed.\n"));
     
    18741874  // Record shift state
    18751875  // BUGBUG: Need add Menu key and Left/Right Logo key state in the future
    1876   // 
     1876  //
    18771877  if ((KbFlag1 & KB_ALT_PRESSED) == KB_ALT_PRESSED) {
    18781878    KeyData.KeyState.KeyShiftState  |= ((KbFlag2 & KB_LEFT_ALT_PRESSED) == KB_LEFT_ALT_PRESSED) ? EFI_LEFT_ALT_PRESSED : EFI_RIGHT_ALT_PRESSED;
    1879   } 
     1879  }
    18801880  if ((KbFlag1 & KB_CTRL_PRESSED) == KB_CTRL_PRESSED) {
    18811881    KeyData.KeyState.KeyShiftState  |= ((KbFlag2 & KB_LEFT_CTRL_PRESSED) == KB_LEFT_CTRL_PRESSED) ? EFI_LEFT_CONTROL_PRESSED : EFI_RIGHT_CONTROL_PRESSED;
    1882   } 
     1882  }
    18831883  if ((KbFlag1 & KB_LEFT_SHIFT_PRESSED) == KB_LEFT_SHIFT_PRESSED) {
    18841884    KeyData.KeyState.KeyShiftState  |= EFI_LEFT_SHIFT_PRESSED;
     
    18931893  KbFlag2 &= ~(KB_LEFT_ALT_PRESSED | KB_LEFT_CTRL_PRESSED);
    18941894  *((UINT8 *) (UINTN) 0x418) = KbFlag2;
    1895   KbFlag1 &= ~0x0C;                     
    1896   *((UINT8 *) (UINTN) 0x417) = KbFlag1; 
    1897 
    1898  
     1895  KbFlag1 &= ~0x0C;
     1896  *((UINT8 *) (UINTN) 0x417) = KbFlag1;
     1897
     1898
    18991899  //
    19001900  // Output EFI input key and shift/toggle state
     
    19461946  for (Link = BiosKeyboardPrivate->NotifyList.ForwardLink; Link != &BiosKeyboardPrivate->NotifyList; Link = Link->ForwardLink) {
    19471947    CurrentNotify = CR (
    1948                       Link, 
    1949                       BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY, 
    1950                       NotifyEntry, 
     1948                      Link,
     1949                      BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY,
     1950                      NotifyEntry,
    19511951                      BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY_SIGNATURE
    19521952                      );
    1953     if (IsKeyRegistered (&CurrentNotify->KeyData, &KeyData)) { 
     1953    if (IsKeyRegistered (&CurrentNotify->KeyData, &KeyData)) {
    19541954      CurrentNotify->KeyNotificationFn (&KeyData);
    19551955    }
     
    19621962  gBS->RestoreTPL (OldTpl);
    19631963
    1964   return ; 
     1964  return ;
    19651965}
    19661966
     
    19861986  while (!IsListEmpty (ListHead)) {
    19871987    NotifyNode = CR (
    1988                    ListHead->ForwardLink, 
    1989                    BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY, 
    1990                    NotifyEntry, 
     1988                   ListHead->ForwardLink,
     1989                   BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY,
     1990                   NotifyEntry,
    19911991                   BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY_SIGNATURE
    19921992                   );
     
    20012001  Check if key is registered.
    20022002
    2003   @param  RegsiteredData    A pointer to a buffer that is filled in with the keystroke 
     2003  @param  RegsiteredData    A pointer to a buffer that is filled in with the keystroke
    20042004                            state data for the key that was registered.
    2005   @param  InputData         A pointer to a buffer that is filled in with the keystroke 
     2005  @param  InputData         A pointer to a buffer that is filled in with the keystroke
    20062006                            state data for the key that was pressed.
    20072007
    20082008  @retval TRUE              Key be pressed matches a registered key.
    2009   @retval FLASE             Match failed. 
    2010  
     2009  @retval FLASE             Match failed.
     2010
    20112011**/
    20122012BOOLEAN
     
    20172017{
    20182018  ASSERT (RegsiteredData != NULL && InputData != NULL);
    2019  
     2019
    20202020  if ((RegsiteredData->Key.ScanCode    != InputData->Key.ScanCode) ||
    20212021      (RegsiteredData->Key.UnicodeChar != InputData->Key.UnicodeChar)) {
    2022     return FALSE; 
    2023   }     
    2024  
     2022    return FALSE;
     2023  }
     2024
    20252025  //
    20262026  // Assume KeyShiftState/KeyToggleState = 0 in Registered key data means these state could be ignored.
     
    20282028  if (RegsiteredData->KeyState.KeyShiftState != 0 &&
    20292029      RegsiteredData->KeyState.KeyShiftState != InputData->KeyState.KeyShiftState) {
    2030     return FALSE;   
    2031   }   
     2030    return FALSE;
     2031  }
    20322032  if (RegsiteredData->KeyState.KeyToggleState != 0 &&
    20332033      RegsiteredData->KeyState.KeyToggleState != InputData->KeyState.KeyToggleState) {
    2034     return FALSE;   
    2035   }     
    2036  
     2034    return FALSE;
     2035  }
     2036
    20372037  return TRUE;
    20382038
     
    20442044  @param  Event    The event that be siganlled when any key has been stroked.
    20452045  @param  Context  Pointer of the protocol EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL.
    2046  
     2046
    20472047**/
    20482048VOID
     
    20522052  IN  VOID       *Context
    20532053  )
    2054 { 
     2054{
    20552055  BIOS_KEYBOARD_DEV                     *BiosKeyboardPrivate;
    2056  
    2057   BiosKeyboardPrivate = TEXT_INPUT_EX_BIOS_KEYBOARD_DEV_FROM_THIS (Context); 
     2056
     2057  BiosKeyboardPrivate = TEXT_INPUT_EX_BIOS_KEYBOARD_DEV_FROM_THIS (Context);
    20582058  BiosKeyboardWaitForKey (Event, &BiosKeyboardPrivate->SimpleTextIn);
    20592059
     
    20622062/**
    20632063  Reset the input device and optionaly run diagnostics
    2064  
     2064
    20652065  @param  This                  Protocol instance pointer.
    20662066  @param  ExtendedVerification  Driver may perform diagnostics on reset.
    20672067
    20682068  @retval EFI_SUCCESS           The device was reset.
    2069   @retval EFI_DEVICE_ERROR      The device is not functioning properly and could 
     2069  @retval EFI_DEVICE_ERROR      The device is not functioning properly and could
    20702070                                not be reset.
    20712071
     
    20812081  EFI_STATUS                            Status;
    20822082  EFI_TPL                               OldTpl;
    2083  
    2084   BiosKeyboardPrivate = TEXT_INPUT_EX_BIOS_KEYBOARD_DEV_FROM_THIS (This); 
     2083
     2084  BiosKeyboardPrivate = TEXT_INPUT_EX_BIOS_KEYBOARD_DEV_FROM_THIS (This);
    20852085
    20862086  Status = BiosKeyboardPrivate->SimpleTextIn.Reset (
    2087                                                &BiosKeyboardPrivate->SimpleTextIn, 
     2087                                               &BiosKeyboardPrivate->SimpleTextIn,
    20882088                                               ExtendedVerification
    20892089                                               );
     
    20952095
    20962096  gBS->RestoreTPL (OldTpl);
    2097  
     2097
    20982098  return EFI_SUCCESS;
    20992099
     
    21012101
    21022102/**
    2103   Reads the next keystroke from the input device. The WaitForKey Event can 
     2103  Reads the next keystroke from the input device. The WaitForKey Event can
    21042104  be used to test for existance of a keystroke via WaitForEvent () call.
    21052105
    21062106  @param  This         Protocol instance pointer.
    2107   @param  KeyData      A pointer to a buffer that is filled in with the keystroke 
     2107  @param  KeyData      A pointer to a buffer that is filled in with the keystroke
    21082108                       state data for the key that was pressed.
    2109  
     2109
    21102110  @retval  EFI_SUCCESS           The keystroke information was returned.
    21112111  @retval  EFI_NOT_READY         There was no keystroke data availiable.
    2112   @retval  EFI_DEVICE_ERROR      The keystroke information was not returned due to 
     2112  @retval  EFI_DEVICE_ERROR      The keystroke information was not returned due to
    21132113                                 hardware errors.
    2114   @retval  EFI_INVALID_PARAMETER KeyData is NULL.                       
    2115    
     2114  @retval  EFI_INVALID_PARAMETER KeyData is NULL.
     2115
    21162116**/
    21172117EFI_STATUS
     
    21272127    return EFI_INVALID_PARAMETER;
    21282128  }
    2129  
     2129
    21302130  BiosKeyboardPrivate = TEXT_INPUT_EX_BIOS_KEYBOARD_DEV_FROM_THIS (This);
    21312131
    21322132  return KeyboardReadKeyStrokeWorker (BiosKeyboardPrivate, KeyData);
    2133  
     2133
    21342134}
    21352135
     
    21382138
    21392139  @param  This              Protocol instance pointer.
    2140   @param  KeyToggleState    A pointer to the EFI_KEY_TOGGLE_STATE to set the 
     2140  @param  KeyToggleState    A pointer to the EFI_KEY_TOGGLE_STATE to set the
    21412141                            state for the input device.
    21422142
    21432143  @retval EFI_SUCCESS           The device state was set successfully.
    2144   @retval EFI_DEVICE_ERROR      The device is not functioning correctly and could 
     2144  @retval EFI_DEVICE_ERROR      The device is not functioning correctly and could
    21452145                                not have the setting adjusted.
    21462146  @retval EFI_UNSUPPORTED       The device does not have the ability to set its state.
    2147   @retval EFI_INVALID_PARAMETER KeyToggleState is NULL.                       
    2148 
    2149 **/   
     2147  @retval EFI_INVALID_PARAMETER KeyToggleState is NULL.
     2148
     2149**/
    21502150EFI_STATUS
    21512151EFIAPI
     
    22042204  if (EFI_ERROR (Status)) {
    22052205    return EFI_DEVICE_ERROR;
    2206   } 
     2206  }
    22072207  Status = KeyboardWaitForValue (BiosKeyboardPrivate, 0xfa, KEYBOARD_WAITFORVALUE_TIMEOUT);
    22082208  if (EFI_ERROR (Status)) {
     
    22122212  if (EFI_ERROR (Status)) {
    22132213    return EFI_DEVICE_ERROR;
    2214   } 
     2214  }
    22152215  //
    22162216  // Call Legacy BIOS Protocol to set whatever is necessary
     
    22332233
    22342234  @param  This                    Protocol instance pointer.
    2235   @param  KeyData                 A pointer to a buffer that is filled in with the keystroke 
     2235  @param  KeyData                 A pointer to a buffer that is filled in with the keystroke
    22362236                                  information data for the key that was pressed.
    2237   @param  KeyNotificationFunction Points to the function to be called when the key 
    2238                                   sequence is typed specified by KeyData.                       
    2239   @param  NotifyHandle            Points to the unique handle assigned to the registered notification.                         
    2240 
    2241  
     2237  @param  KeyNotificationFunction Points to the function to be called when the key
     2238                                  sequence is typed specified by KeyData.
     2239  @param  NotifyHandle            Points to the unique handle assigned to the registered notification.
     2240
     2241
    22422242  @retval EFI_SUCCESS             The notification function was registered successfully.
    22432243  @retval EFI_OUT_OF_RESOURCES    Unable to allocate resources for necesssary data structures.
    22442244  @retval EFI_INVALID_PARAMETER   KeyData or NotifyHandle is NULL.
    2245                                                  
    2246 **/   
     2245
     2246**/
    22472247EFI_STATUS
    22482248EFIAPI
     
    22592259  BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY    *NewNotify;
    22602260  LIST_ENTRY                            *Link;
    2261   BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY    *CurrentNotify; 
     2261  BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY    *CurrentNotify;
    22622262
    22632263  if (KeyData == NULL || NotifyHandle == NULL || KeyNotificationFunction == NULL) {
     
    22772277  for (Link = BiosKeyboardPrivate->NotifyList.ForwardLink; Link != &BiosKeyboardPrivate->NotifyList; Link = Link->ForwardLink) {
    22782278    CurrentNotify = CR (
    2279                       Link, 
    2280                       BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY, 
    2281                       NotifyEntry, 
     2279                      Link,
     2280                      BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY,
     2281                      NotifyEntry,
    22822282                      BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY_SIGNATURE
    22832283                      );
    2284     if (IsKeyRegistered (&CurrentNotify->KeyData, KeyData)) { 
     2284    if (IsKeyRegistered (&CurrentNotify->KeyData, KeyData)) {
    22852285      if (CurrentNotify->KeyNotificationFn == KeyNotificationFunction) {
    22862286        *NotifyHandle = CurrentNotify;
     
    22882288        goto Exit;
    22892289      }
    2290     } 
     2290    }
    22912291  }
    22922292
     
    22942294  // Allocate resource to save the notification function
    22952295  //
    2296  
     2296
    22972297  NewNotify = (BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY *) AllocateZeroPool (sizeof (BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY));
    22982298  if (NewNotify == NULL) {
     
    23082308  *NotifyHandle                = NewNotify;
    23092309  Status                       = EFI_SUCCESS;
    2310  
     2310
    23112311Exit:
    23122312  //
     
    23142314  //
    23152315  gBS->RestoreTPL (OldTpl);
    2316   return Status; 
     2316  return Status;
    23172317}
    23182318
     
    23202320  Remove a registered notification function from a particular keystroke.
    23212321
    2322   @param  This                 Protocol instance pointer.   
     2322  @param  This                 Protocol instance pointer.
    23232323  @param  NotificationHandle   The handle of the notification function being unregistered.
    2324  
     2324
    23252325  @retval EFI_SUCCESS             The notification function was unregistered successfully.
    23262326  @retval EFI_INVALID_PARAMETER   The NotificationHandle is invalid.
    2327                              
    2328 **/   
     2327
     2328**/
    23292329EFI_STATUS
    23302330EFIAPI
     
    23492349  if (((BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY *) NotificationHandle)->Signature != BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY_SIGNATURE) {
    23502350    return EFI_INVALID_PARAMETER;
    2351   } 
    2352  
     2351  }
     2352
    23532353  BiosKeyboardPrivate = TEXT_INPUT_EX_BIOS_KEYBOARD_DEV_FROM_THIS (This);
    2354  
     2354
    23552355  //
    23562356  // Enter critical section
     
    23602360  for (Link = BiosKeyboardPrivate->NotifyList.ForwardLink; Link != &BiosKeyboardPrivate->NotifyList; Link = Link->ForwardLink) {
    23612361    CurrentNotify = CR (
    2362                       Link, 
    2363                       BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY, 
    2364                       NotifyEntry, 
     2362                      Link,
     2363                      BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY,
     2364                      NotifyEntry,
    23652365                      BIOS_KEYBOARD_CONSOLE_IN_EX_NOTIFY_SIGNATURE
    2366                       );   
     2366                      );
    23672367    if (CurrentNotify == NotificationHandle) {
    23682368      //
    23692369      // Remove the notification function from NotifyList and free resources
    23702370      //
    2371       RemoveEntryList (&CurrentNotify->NotifyEntry);     
     2371      RemoveEntryList (&CurrentNotify->NotifyEntry);
    23722372
    23732373      Status = EFI_SUCCESS;
     
    23752375    }
    23762376  }
    2377  
     2377
    23782378  //
    23792379  // Can not find the specified Notification Handle
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/BiosThunk/KeyboardDxe/BiosKeyboard.h

    r58459 r58466  
    219219  UINT16                                      CommandRegisterAddress;
    220220  BOOLEAN                                     ExtendedKeyboard;
    221  
     221
    222222  //
    223223  // Buffer storing EFI_KEY_DATA
     
    230230  LIST_ENTRY                                  NotifyList;
    231231  EFI_EVENT                                   TimerEvent;
    232  
     232
    233233} BIOS_KEYBOARD_DEV;
    234234
     
    496496
    497497  @param  This         Pointer of the protocol EFI_SIMPLE_TEXT_IN_PROTOCOL.
    498  
     498
    499499  @retval EFI_SUCCESS  A key is being pressed now.
    500500  @retval Other        No key is now pressed.
     
    513513  @param  ScanCode     Scan code of key.
    514514
    515   @return The value of EFI Scancode for the key.   
     515  @return The value of EFI Scancode for the key.
    516516  @retval SCAN_NULL   No corresponding value in the EFI convert table is found for the key.
    517517
     
    526526  Check whether there is Ps/2 Keyboard device in system by 0xF4 Keyboard Command
    527527  If Keyboard receives 0xF4, it will respond with 'ACK'. If it doesn't respond, the device
    528   should not be in system. 
     528  should not be in system.
    529529
    530530  @param  BiosKeyboardPrivate  Keyboard Private Data Struture
     
    541541/**
    542542  Timer event handler: read a series of key stroke from 8042
    543   and put them into memory key buffer. 
     543  and put them into memory key buffer.
    544544  It is registered as running under TPL_NOTIFY
    545  
     545
    546546  @param  Event   The timer event
    547547  @param  Context A BIOS_KEYBOARD_DEV pointer
     
    557557/**
    558558  Reset the input device and optionaly run diagnostics
    559  
     559
    560560  @param  This                  Protocol instance pointer.
    561561  @param  ExtendedVerification  Driver may perform diagnostics on reset.
    562562
    563563  @retval EFI_SUCCESS           The device was reset.
    564   @retval EFI_DEVICE_ERROR      The device is not functioning properly and could 
     564  @retval EFI_DEVICE_ERROR      The device is not functioning properly and could
    565565                                not be reset.
    566566
     
    574574
    575575/**
    576   Reads the next keystroke from the input device. The WaitForKey Event can 
     576  Reads the next keystroke from the input device. The WaitForKey Event can
    577577  be used to test for existance of a keystroke via WaitForEvent () call.
    578578
    579579  @param  This         Protocol instance pointer.
    580   @param  KeyData      A pointer to a buffer that is filled in with the keystroke 
     580  @param  KeyData      A pointer to a buffer that is filled in with the keystroke
    581581                       state data for the key that was pressed.
    582  
     582
    583583  @retval  EFI_SUCCESS           The keystroke information was returned.
    584584  @retval  EFI_NOT_READY         There was no keystroke data availiable.
    585   @retval  EFI_DEVICE_ERROR      The keystroke information was not returned due to 
     585  @retval  EFI_DEVICE_ERROR      The keystroke information was not returned due to
    586586                                 hardware errors.
    587   @retval  EFI_INVALID_PARAMETER KeyData is NULL.                       
    588    
     587  @retval  EFI_INVALID_PARAMETER KeyData is NULL.
     588
    589589**/
    590590EFI_STATUS
     
    599599
    600600  @param  This              Protocol instance pointer.
    601   @param  KeyToggleState    A pointer to the EFI_KEY_TOGGLE_STATE to set the 
     601  @param  KeyToggleState    A pointer to the EFI_KEY_TOGGLE_STATE to set the
    602602                            state for the input device.
    603603
    604604  @retval EFI_SUCCESS           The device state was set successfully.
    605   @retval EFI_DEVICE_ERROR      The device is not functioning correctly and could 
     605  @retval EFI_DEVICE_ERROR      The device is not functioning correctly and could
    606606                                not have the setting adjusted.
    607607  @retval EFI_UNSUPPORTED       The device does not have the ability to set its state.
    608   @retval EFI_INVALID_PARAMETER KeyToggleState is NULL.                       
    609 
    610 **/   
     608  @retval EFI_INVALID_PARAMETER KeyToggleState is NULL.
     609
     610**/
    611611EFI_STATUS
    612612EFIAPI
     
    620620
    621621  @param  This                    Protocol instance pointer.
    622   @param  KeyData                 A pointer to a buffer that is filled in with the keystroke 
     622  @param  KeyData                 A pointer to a buffer that is filled in with the keystroke
    623623                                  information data for the key that was pressed.
    624   @param  KeyNotificationFunction Points to the function to be called when the key 
    625                                   sequence is typed specified by KeyData.                       
    626   @param  NotifyHandle            Points to the unique handle assigned to the registered notification.                         
    627 
    628  
     624  @param  KeyNotificationFunction Points to the function to be called when the key
     625                                  sequence is typed specified by KeyData.
     626  @param  NotifyHandle            Points to the unique handle assigned to the registered notification.
     627
     628
    629629  @retval EFI_SUCCESS             The notification function was registered successfully.
    630630  @retval EFI_OUT_OF_RESOURCES    Unable to allocate resources for necesssary data structures.
    631631  @retval EFI_INVALID_PARAMETER   KeyData or NotifyHandle is NULL.
    632                                                  
    633 **/   
     632
     633**/
    634634EFI_STATUS
    635635EFIAPI
     
    644644  Remove a registered notification function from a particular keystroke.
    645645
    646   @param  This                 Protocol instance pointer.   
     646  @param  This                 Protocol instance pointer.
    647647  @param  NotificationHandle   The handle of the notification function being unregistered.
    648  
     648
    649649  @retval EFI_SUCCESS             The notification function was unregistered successfully.
    650650  @retval EFI_INVALID_PARAMETER   The NotificationHandle is invalid.
    651                              
    652 **/   
     651
     652**/
    653653EFI_STATUS
    654654EFIAPI
     
    706706BiosKeyboardFreeNotifyList (
    707707  IN OUT LIST_ENTRY           *ListHead
    708   ); 
     708  );
    709709
    710710/**
    711711  Check if key is registered.
    712712
    713   @param  RegsiteredData    A pointer to a buffer that is filled in with the keystroke 
     713  @param  RegsiteredData    A pointer to a buffer that is filled in with the keystroke
    714714                            state data for the key that was registered.
    715   @param  InputData         A pointer to a buffer that is filled in with the keystroke 
     715  @param  InputData         A pointer to a buffer that is filled in with the keystroke
    716716                            state data for the key that was pressed.
    717717
    718718  @retval TRUE              Key be pressed matches a registered key.
    719   @retval FLASE             Match failed. 
    720  
     719  @retval FLASE             Match failed.
     720
    721721**/
    722722BOOLEAN
     
    731731  @param  Event    The event that be siganlled when any key has been stroked.
    732732  @param  Context  Pointer of the protocol EFI_SIMPLE_TEXT_INPUT_EX_PROTOCOL.
    733  
     733
    734734**/
    735735VOID
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/BiosThunk/KeyboardDxe/KeyboardDxe.inf

    r58459 r58466  
    22# Ps2 Keyboard driver.
    33#
    4 # Ps2 Keyboard driver by using Legacy Bios protocol service and IsaIo protocol 
     4# Ps2 Keyboard driver by using Legacy Bios protocol service and IsaIo protocol
    55# service. This dirver uses legacy INT16 to get the key stroke status.
    66#
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/BiosThunk/Snp16Dxe/BiosSnp16.c

    r58459 r58466  
    4343  @param SimpleNetworkDevice A pointer to EFI_SIMPLE_NETWORK_DEV data structure.
    4444  @param Ax                  PCI address of Undi device.
    45  
    46   @retval EFI_DEVICE_ERROR Fail to start 16 bit UNDI ROM. 
    47   @retval Others           Status of start 16 bit UNDI ROM. 
     45
     46  @retval EFI_DEVICE_ERROR Fail to start 16 bit UNDI ROM.
     47  @retval Others           Status of start 16 bit UNDI ROM.
    4848**/
    4949EFI_STATUS
     
    5757
    5858  @param SimpleNetworkDevice A pointer to EFI_SIMPLE_NETWORK_DEV data structure.
    59  
    60   @retval EFI_DEVICE_ERROR Fail to start 16 bit UNDI ROM. 
    61   @retval Others           Status of start 16 bit UNDI ROM. 
     59
     60  @retval EFI_DEVICE_ERROR Fail to start 16 bit UNDI ROM.
     61  @retval Others           Status of start 16 bit UNDI ROM.
    6262**/
    6363EFI_STATUS
     
    7070
    7171  @param SimpleNetworkDevice A pointer to EFI_SIMPLE_NETWORK_DEV data structure.
    72  
    73   @retval EFI_DEVICE_ERROR Fail to stop 16 bit UNDI ROM. 
    74   @retval Others           Status of stop 16 bit UNDI ROM. 
     72
     73  @retval EFI_DEVICE_ERROR Fail to stop 16 bit UNDI ROM.
     74  @retval Others           Status of stop 16 bit UNDI ROM.
    7575**/
    7676EFI_STATUS
     
    8383
    8484  @param This A pointer to EFI_SIMPLE_NETWORK_PROTOCOL structure.
    85  
    86   @retval EFI_SUCCESS Sucess operation. 
    87   @retval Others      Fail to get runtime information for Undi network interface. 
     85
     86  @retval EFI_SUCCESS Sucess operation.
     87  @retval Others      Fail to get runtime information for Undi network interface.
    8888**/
    8989EFI_STATUS
     
    9696
    9797  @param This A pointer to EFI_SIMPLE_NETWORK_PROTOCOL structure.
    98  
    99   @retval EFI_SUCCESS Sucess operation. 
     98
     99  @retval EFI_SUCCESS Sucess operation.
    100100  @retval Others      Fail to get NIC type.
    101101**/
     
    109109
    110110  @param This A pointer to EFI_SIMPLE_NETWORK_PROTOCOL structure.
    111  
    112   @retval EFI_SUCCESS Sucess operation. 
     111
     112  @retval EFI_SUCCESS Sucess operation.
    113113  @retval Others      Fail to get NDIS information.
    114114**/
     
    120120/**
    121121  Signal handlers for ExitBootServices event.
    122  
    123   Clean up any Real-mode UNDI residue from the system 
    124    
     122
     123  Clean up any Real-mode UNDI residue from the system
     124
    125125  @param Event      ExitBootServices event
    126   @param Context 
     126  @param Context
    127127**/
    128128VOID
     
    137137
    138138  @param SimpleNetworkDevice A pointer to EFI_SIMPLE_NETWORK_DEV data structure.
    139  
     139
    140140  @retval   EFI_SUCCESS   - Successfully loads undi driver.
    141141  @retval   EFI_NOT_FOUND - Doesn't find undi driver or undi driver load failure.
     
    150150
    151151  @param SimpleNetworkDevice A pointer to EFI_SIMPLE_NETWORK_DEV data structure.
    152  
    153   @return EFI_STATUS 
     152
     153  @return EFI_STATUS
    154154**/
    155155EFI_STATUS
     
    163163  @param ImageHandle Handle that identifies the loaded image.
    164164  @param SystemTable System Table for this image.
    165  
    166   @return EFI_STATUS Return status from EfiLibInstallAllDriverProtocols. 
     165
     166  @return EFI_STATUS Return status from EfiLibInstallAllDriverProtocols.
    167167**/
    168168EFI_STATUS
     
    192192  @param Controller           The handle of the controller to test.
    193193  @param RemainingDevicePath  A pointer to the remaining portion of a device path.
    194  
     194
    195195  @retval EFI_SUCCESS    The driver supports given controller.
    196196  @retval EFI_UNSUPPORT  The driver doesn't support given controller.
     
    287287  @param Controller           The handle of the controller to test.
    288288  @param RemainingDevicePath  A pointer to the remaining portion of a device path.
    289  
    290   @retval  EFI_SUCCESS          - The device was started.   
     289
     290  @retval  EFI_SUCCESS          - The device was started.
    291291  @retval  EFI_DEVICE_ERROR     - The device could not be started due to a device error.
    292292  @retval  EFI_OUT_OF_RESOURCES - The request could not be completed due to a lack of resources.
     
    507507  //
    508508  Status = EfiCreateEventLegacyBootEx(
    509              TPL_NOTIFY, 
    510              Undi16SimpleNetworkEvent, 
    511              NULL, 
     509             TPL_NOTIFY,
     510             Undi16SimpleNetworkEvent,
     511             NULL,
    512512             &SimpleNetworkDevice->LegacyBootEvent
    513513             );
    514  
     514
    515515  if (EFI_ERROR(Status)) {
    516516    DEBUG ((DEBUG_ERROR,"ERROR : Could not create event.  Status = %r\n",Status));
     
    751751        gBS->CloseEvent (SimpleNetworkDevice->LegacyBootEvent);
    752752      }
    753      
     753
    754754      if (SimpleNetworkDevice->EfiBootEvent != NULL) {
    755755        gBS->CloseEvent (SimpleNetworkDevice->EfiBootEvent);
     
    776776
    777777      gBS->FreePool (SimpleNetworkDevice);
    778      
     778
    779779      //
    780780      //  Only restore the vector if it was cached.
     
    820820      Status = EFI_DEVICE_ERROR;
    821821    }
    822   } 
     822  }
    823823  return Status;
    824824}
     
    832832  @param ChildHandleBuffer  An array of child handles to be freed. May be NULL if
    833833                            NumberOfChildren is 0.
    834  
     834
    835835  @retval  EFI_SUCCESS      - The device was stopped.
    836836  @retval  EFI_DEVICE_ERROR - The device could not be stopped due to a device error.
     
    900900                    Controller
    901901                    );
    902                    
     902
    903903    if (EFI_ERROR (Status)) {
    904904      Status = EFI_DEVICE_ERROR;
     
    974974          gBS->CloseEvent (SimpleNetworkDevice->LegacyBootEvent);
    975975        }
    976      
     976
    977977        if (SimpleNetworkDevice->EfiBootEvent != NULL) {
    978978          gBS->CloseEvent (SimpleNetworkDevice->EfiBootEvent);
     
    10221022
    10231023  @param Fifo Point to trasmit FIFO structure.
    1024  
     1024
    10251025  @return BOOLEAN whether transmit FIFO is full.
    10261026**/
     
    10411041
    10421042  @param Fifo Point to trasmit FIFO structure.
    1043  
     1043
    10441044  @return BOOLEAN whether transmit FIFO is empty.
    10451045**/
     
    10621062  @param Fifo Point to trasmit FIFO structure.
    10631063  @param Data The data point want to be added.
    1064  
    1065   @retval EFI_OUT_OF_RESOURCES  FIFO is full 
    1066   @retval EFI_SUCCESS           Success operation. 
     1064
     1065  @retval EFI_OUT_OF_RESOURCES  FIFO is full
     1066  @retval EFI_SUCCESS           Success operation.
    10671067**/
    10681068EFI_STATUS
     
    10861086  @param Fifo Point to trasmit FIFO structure.
    10871087  @param Data On return, point to the data point want to be got and removed.
    1088  
    1089   @retval EFI_OUT_OF_RESOURCES network transmit buffer is empty. 
    1090   @retval EFI_SUCCESS           Success operation. 
     1088
     1089  @retval EFI_OUT_OF_RESOURCES network transmit buffer is empty.
     1090  @retval EFI_SUCCESS           Success operation.
    10911091**/
    10921092EFI_STATUS
     
    11091109
    11101110  @param ReceiveFilterSetting  filter setting EFI mask value.
    1111  
     1111
    11121112  @return UINT16 Undi filter setting value.
    11131113**/
     
    11501150/**
    11511151  Get filter setting from multi cast buffer .
    1152    
     1152
    11531153  @param Mode           Point to mode structure.
    1154   @param McastBuffer    The multi cast buffer 
     1154  @param McastBuffer    The multi cast buffer
    11551155  @param HwAddressSize  Size of filter value.
    1156  
     1156
    11571157**/
    11581158VOID
     
    11841184
    11851185  @param SimpleNetworkDevice A pointer to EFI_SIMPLE_NETWORK_DEV data structure.
    1186  
     1186
    11871187  @retval   EFI_SUCCESS   - Successfully loads undi driver.
    11881188  @retval   EFI_NOT_FOUND - Doesn't find undi driver or undi driver load failure.
     
    11991199  PCI_DATA_STRUCTURE        *PciDataStructure;
    12001200  PCI_TYPE00                Pci;
    1201  
     1201
    12021202  if (!mCachedInt1A) {
    12031203    Status = CacheVectorAddress (0x1A);
    12041204    if (!EFI_ERROR (Status)) {
    1205       mCachedInt1A = TRUE;   
     1205      mCachedInt1A = TRUE;
    12061206    }
    12071207  }
     
    12281228
    12291229    //
    1230     // If the pointer to the PCI Data Structure is invalid, no further images can be located. 
    1231     // The PCI Data Structure must be DWORD aligned. 
     1230    // If the pointer to the PCI Data Structure is invalid, no further images can be located.
     1231    // The PCI Data Structure must be DWORD aligned.
    12321232    //
    12331233    if (PciExpansionRomHeader->PcirOffset == 0 ||
     
    12501250
    12511251    DEBUG (
    1252         (DEBUG_INIT, 
     1252        (DEBUG_INIT,
    12531253         "PCI device with matchinng VendorId and DeviceId (%d,%d)\n",
    12541254         (UINTN) PciDataStructure->VendorId,
     
    12611261      return EFI_SUCCESS;
    12621262    }
    1263    
     1263
    12641264    //
    12651265    // Free resources allocated in LaunchBaseCode
     
    12751275
    12761276  @param SimpleNetworkDevice A pointer to EFI_SIMPLE_NETWORK_DEV data structure.
    1277  
    1278   @return EFI_STATUS 
     1277
     1278  @return EFI_STATUS
    12791279**/
    12801280EFI_STATUS
     
    13321332  @param SimpleNetworkDevice A pointer to EFI_SIMPLE_NETWORK_DEV data structure.
    13331333  @param Ax                  PCI address of Undi device.
    1334  
    1335   @retval EFI_DEVICE_ERROR Fail to start 16 bit UNDI ROM. 
    1336   @retval Others           Status of start 16 bit UNDI ROM. 
     1334
     1335  @retval EFI_DEVICE_ERROR Fail to start 16 bit UNDI ROM.
     1336  @retval Others           Status of start 16 bit UNDI ROM.
    13371337**/
    13381338EFI_STATUS
     
    13771377
    13781378  @param SimpleNetworkDevice A pointer to EFI_SIMPLE_NETWORK_DEV data structure.
    1379  
    1380   @retval EFI_DEVICE_ERROR Fail to stop 16 bit UNDI ROM. 
    1381   @retval Others           Status of stop 16 bit UNDI ROM. 
     1379
     1380  @retval EFI_DEVICE_ERROR Fail to stop 16 bit UNDI ROM.
     1381  @retval Others           Status of stop 16 bit UNDI ROM.
    13821382**/
    13831383EFI_STATUS
     
    14121412
    14131413  @param SimpleNetworkDevice A pointer to EFI_SIMPLE_NETWORK_DEV data structure.
    1414  
    1415   @retval EFI_DEVICE_ERROR Fail to cleanup 16 bit UNDI ROM. 
    1416   @retval Others           Status of cleanup 16 bit UNDI ROM. 
     1414
     1415  @retval EFI_DEVICE_ERROR Fail to cleanup 16 bit UNDI ROM.
     1416  @retval Others           Status of cleanup 16 bit UNDI ROM.
    14171417**/
    14181418EFI_STATUS
     
    14471447
    14481448  @param This A pointer to EFI_SIMPLE_NETWORK_PROTOCOL structure.
    1449  
    1450   @retval EFI_SUCCESS Sucess operation. 
    1451   @retval Others      Fail to get runtime information for Undi network interface. 
     1449
     1450  @retval EFI_SUCCESS Sucess operation.
     1451  @retval Others      Fail to get runtime information for Undi network interface.
    14521452**/
    14531453EFI_STATUS
     
    15781578
    15791579  @param This A pointer to EFI_SIMPLE_NETWORK_PROTOCOL structure.
    1580  
    1581   @retval EFI_SUCCESS Sucess operation. 
     1580
     1581  @retval EFI_SUCCESS Sucess operation.
    15821582  @retval Others      Fail to get NIC type.
    15831583**/
     
    16291629
    16301630  @param This A pointer to EFI_SIMPLE_NETWORK_PROTOCOL structure.
    1631  
    1632   @retval EFI_SUCCESS Sucess operation. 
     1631
     1632  @retval EFI_SUCCESS Sucess operation.
    16331633  @retval Others      Fail to get NDIS information.
    16341634**/
     
    16881688  @param ProtType           The type network transmit protocol
    16891689  @param PktType            The type of package.
    1690  
    1691   @retval EFI_DEVICE_ERROR  Fail to execute 16 bit ROM's ISR, or status is invalid. 
    1692   @retval EFI_SUCCESS       Success operation. 
     1690
     1691  @retval EFI_DEVICE_ERROR  Fail to execute 16 bit ROM's ISR, or status is invalid.
     1692  @retval EFI_SUCCESS       Success operation.
    16931693**/
    16941694EFI_STATUS
     
    19031903
    19041904  @param This       A pointer to EFI_SIMPLE_NETWORK_PROTOCOL structure.
    1905  
     1905
    19061906  @retval EFI_DEVICE_ERROR Network interface has not be initialized.
    19071907  @retval EFI_DEVICE_ERROR Fail to execute 16 bit ROM call.
     
    19771977
    19781978  @param This       A pointer to EFI_SIMPLE_NETWORK_PROTOCOL structure.
    1979  
     1979
    19801980  @retval EFI_DEVICE_ERROR Network interface has not be initialized.
    19811981  @retval EFI_DEVICE_ERROR Fail to execute 16 bit ROM call.
     
    20252025//
    20262026/**
    2027   Initialize network interface 
     2027  Initialize network interface
    20282028
    20292029  @param This                 A pointer to EFI_SIMPLE_NETWORK_PROTOCOL structure.
    20302030  @param ExtraRxBufferSize    The size of extra request receive buffer.
    20312031  @param ExtraTxBufferSize    The size of extra request transmit buffer.
    2032  
     2032
    20332033  @retval EFI_DEVICE_ERROR Fail to execute 16 bit ROM call.
    20342034  @retval EFI_SUCESS       Success operation.
     
    21482148  @param This                 A pointer to EFI_SIMPLE_NETWORK_PROTOCOL structure.
    21492149  @param ExtendedVerification Need extended verfication.
    2150  
     2150
    21512151  @retval EFI_INVALID_PARAMETER Invalid This paramter.
    21522152  @retval EFI_DEVICE_ERROR      Network device has not been initialized.
     
    22292229
    22302230  @param This                 A pointer to EFI_SIMPLE_NETWORK_PROTOCOL structure.
    2231  
     2231
    22322232  @retval EFI_INVALID_PARAMETER Invalid This paramter.
    22332233  @retval EFI_DEVICE_ERROR      Network device has not been initialized.
     
    23422342  @param MCastFilterCnt       Count of mutli cast filter for different MAC address
    23432343  @param MCastFilter          Buffer for mustli cast filter for different MAC address.
    2344  
     2344
    23452345  @retval EFI_INVALID_PARAMETER Invalid This paramter.
    23462346  @retval EFI_DEVICE_ERROR      Network device has not been initialized.
     
    24822482        &MCastFilter[Index],
    24832483        sizeof (EFI_MAC_ADDRESS)
    2484         );     
     2484        );
    24852485    }
    24862486  }
     
    24992499  @param Reset                Whether reset station MAC address to permenent address
    25002500  @param New                  A pointer to New address
    2501  
     2501
    25022502  @retval EFI_INVALID_PARAMETER Invalid This paramter.
    25032503  @retval EFI_DEVICE_ERROR      Network device has not been initialized.
     
    28532853  @param IP                   A pointer to given Ip address.
    28542854  @param MAC                  On return, translated MAC address.
    2855  
     2855
    28562856  @retval EFI_INVALID_PARAMETER Invalid This paramter.
    28572857  @retval EFI_INVALID_PARAMETER Invalid IP address.
    28582858  @retval EFI_INVALID_PARAMETER Invalid return buffer for holding MAC address.
    2859   @retval EFI_UNSUPPORTED       Do not support IPv6 
     2859  @retval EFI_UNSUPPORTED       Do not support IPv6
    28602860  @retval EFI_DEVICE_ERROR      Network device has not been initialized.
    28612861  @retval EFI_NOT_STARTED       Network device has been stopped.
     
    29382938//
    29392939/**
    2940   Performs read and write operations on the NVRAM device attached to a 
     2940  Performs read and write operations on the NVRAM device attached to a
    29412941  network interface.
    29422942
     
    29732973//
    29742974/**
    2975   Reads the current interrupt status and recycled transmit buffer status from 
     2975  Reads the current interrupt status and recycled transmit buffer status from
    29762976  a network interface.
    29772977
     
    30903090  @retval EFI_SUCCESS           The packet was placed on the transmit queue.
    30913091  @retval EFI_NOT_STARTED       The network interface has not been started.
    3092   @retval EFI_NOT_READY         The network interface is too busy to accept this transmit request.                     
     3092  @retval EFI_NOT_READY         The network interface is too busy to accept this transmit request.
    30933093  @retval EFI_BUFFER_TOO_SMALL  The BufferSize parameter is too small.
    30943094  @retval EFI_INVALID_PARAMETER One or more of the parameters has an unsupported value.
     
    32583258/**
    32593259  Receives a packet from a network interface.
    3260  
     3260
    32613261  @param  This       The protocol instance pointer.
    32623262  @param  HeaderSize The size, in bytes, of the media header received on the network
     
    33783378  @param Event      Event used with WaitForEvent() to wait for a packet to be received.
    33793379  @param Context    Event Context
    3380  
     3380
    33813381**/
    33823382VOID
     
    34023402
    34033403  @param This The protocol instance pointer.
    3404  
     3404
    34053405  @retval  EFI_SUCCESS           Receive data is ready.
    34063406  @retval  EFI_NOT_STARTED       The network interface has not been started.
     
    34673467/**
    34683468  Signal handlers for ExitBootServices event.
    3469  
    3470   Clean up any Real-mode UNDI residue from the system 
    3471    
     3469
     3470  Clean up any Real-mode UNDI residue from the system
     3471
    34723472  @param Event      ExitBootServices event
    3473   @param Context 
     3473  @param Context
    34743474**/
    34753475VOID
     
    34953495  @param NumPages     The number pages want to be allocated.
    34963496  @param Buffer       On return, allocated buffer.
    3497  
     3497
    34983498  @return Status of allocating pages.
    34993499**/
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/BiosThunk/Snp16Dxe/BiosSnp16.h

    r48674 r58466  
    120120  @param Controller           The handle of the controller to test.
    121121  @param RemainingDevicePath  A pointer to the remaining portion of a device path.
    122  
     122
    123123  @retval EFI_SUCCESS    The driver supports given controller.
    124124  @retval EFI_UNSUPPORT  The driver doesn't support given controller.
     
    141141  @param Controller           The handle of the controller to test.
    142142  @param RemainingDevicePath  A pointer to the remaining portion of a device path.
    143  
    144   @retval  EFI_SUCCESS          - The device was started.   
     143
     144  @retval  EFI_SUCCESS          - The device was started.
    145145  @retval  EFI_DEVICE_ERROR     - The device could not be started due to a device error.
    146146  @retval  EFI_OUT_OF_RESOURCES - The request could not be completed due to a lack of resources.
     
    163163  @param ChildHandleBuffer  An array of child handles to be freed. May be NULL if
    164164                            NumberOfChildren is 0.
    165  
     165
    166166  @retval  EFI_SUCCESS      - The device was stopped.
    167167  @retval  EFI_DEVICE_ERROR - The device could not be stopped due to a device error.
     
    184184
    185185  @param This       A pointer to EFI_SIMPLE_NETWORK_PROTOCOL structure.
    186  
     186
    187187  @retval EFI_DEVICE_ERROR Network interface has not be initialized.
    188188  @retval EFI_DEVICE_ERROR Fail to execute 16 bit ROM call.
     
    200200
    201201  @param This       A pointer to EFI_SIMPLE_NETWORK_PROTOCOL structure.
    202  
     202
    203203  @retval EFI_DEVICE_ERROR Network interface has not be initialized.
    204204  @retval EFI_DEVICE_ERROR Fail to execute 16 bit ROM call.
     
    213213
    214214/**
    215   Initialize network interface 
     215  Initialize network interface
    216216
    217217  @param This                 A pointer to EFI_SIMPLE_NETWORK_PROTOCOL structure.
    218218  @param ExtraRxBufferSize    The size of extra request receive buffer.
    219219  @param ExtraTxBufferSize    The size of extra request transmit buffer.
    220  
     220
    221221  @retval EFI_DEVICE_ERROR Fail to execute 16 bit ROM call.
    222222  @retval EFI_SUCESS       Success operation.
     
    236236  @param This                 A pointer to EFI_SIMPLE_NETWORK_PROTOCOL structure.
    237237  @param ExtendedVerification Need extended verfication.
    238  
     238
    239239  @retval EFI_INVALID_PARAMETER Invalid This paramter.
    240240  @retval EFI_DEVICE_ERROR      Network device has not been initialized.
     
    255255
    256256  @param This                 A pointer to EFI_SIMPLE_NETWORK_PROTOCOL structure.
    257  
     257
    258258  @retval EFI_INVALID_PARAMETER Invalid This paramter.
    259259  @retval EFI_DEVICE_ERROR      Network device has not been initialized.
     
    278278  @param MCastFilterCnt       Count of mutli cast filter for different MAC address
    279279  @param MCastFilter          Buffer for mustli cast filter for different MAC address.
    280  
     280
    281281  @retval EFI_INVALID_PARAMETER Invalid This paramter.
    282282  @retval EFI_DEVICE_ERROR      Network device has not been initialized.
     
    303303  @param Reset                Whether reset station MAC address to permenent address
    304304  @param New                  A pointer to New address
    305  
     305
    306306  @retval EFI_INVALID_PARAMETER Invalid This paramter.
    307307  @retval EFI_DEVICE_ERROR      Network device has not been initialized.
     
    326326  @param StatisticsSize       The buffer of statistics table.
    327327  @param StatisticsTable      A pointer to statistics buffer.
    328  
     328
    329329  @retval EFI_INVALID_PARAMETER Invalid This paramter.
    330330  @retval EFI_DEVICE_ERROR      Network device has not been initialized.
     
    350350  @param IP                   A pointer to given Ip address.
    351351  @param MAC                  On return, translated MAC address.
    352  
     352
    353353  @retval EFI_INVALID_PARAMETER Invalid This paramter.
    354354  @retval EFI_INVALID_PARAMETER Invalid IP address.
    355355  @retval EFI_INVALID_PARAMETER Invalid return buffer for holding MAC address.
    356   @retval EFI_UNSUPPORTED       Do not support IPv6 
     356  @retval EFI_UNSUPPORTED       Do not support IPv6
    357357  @retval EFI_DEVICE_ERROR      Network device has not been initialized.
    358358  @retval EFI_NOT_STARTED       Network device has been stopped.
     
    371371
    372372/**
    373   Performs read and write operations on the NVRAM device attached to a 
     373  Performs read and write operations on the NVRAM device attached to a
    374374  network interface.
    375375
     
    402402
    403403/**
    404   Reads the current interrupt status and recycled transmit buffer status from 
     404  Reads the current interrupt status and recycled transmit buffer status from
    405405  a network interface.
    406406
     
    461461  @retval EFI_SUCCESS           The packet was placed on the transmit queue.
    462462  @retval EFI_NOT_STARTED       The network interface has not been started.
    463   @retval EFI_NOT_READY         The network interface is too busy to accept this transmit request.                     
     463  @retval EFI_NOT_READY         The network interface is too busy to accept this transmit request.
    464464  @retval EFI_BUFFER_TOO_SMALL  The BufferSize parameter is too small.
    465465  @retval EFI_INVALID_PARAMETER One or more of the parameters has an unsupported value.
     
    531531  @param Event      Event used with WaitForEvent() to wait for a packet to be received.
    532532  @param Context    Event Context
    533  
     533
    534534**/
    535535VOID
     
    545545
    546546  @param This The protocol instance pointer.
    547  
     547
    548548  @retval  EFI_SUCCESS           Receive data is ready.
    549549  @retval  EFI_NOT_STARTED       The network interface has not been started.
     
    565565
    566566 @param VectorNumber  IVT number
    567  
     567
    568568 @retval EFI_SUCCESS Success to operation.
    569569**/
     
    575575
    576576/**
    577  Get interrupt vector address according to IVT number. 
    578  
     577 Get interrupt vector address according to IVT number.
     578
    579579 @param VectorNumber    Given IVT number
    580  
     580
    581581 @return cached interrupt vector address.
    582582**/
     
    591591  This should install the !PXE and PXENV+ structures in memory for
    592592  subsequent use.
    593  
     593
    594594
    595595  @param SimpleNetworkDevice    Simple network device instance
    596596  @param RomAddress             The ROM base address for NIC rom.
    597  
    598   @retval EFI_NOT_FOUND         The check sum does not match 
    599   @retval EFI_NOT_FOUND         Rom ID offset is wrong 
    600   @retval EFI_NOT_FOUND         No Rom ID structure is found 
     597
     598  @retval EFI_NOT_FOUND         The check sum does not match
     599  @retval EFI_NOT_FOUND         Rom ID offset is wrong
     600  @retval EFI_NOT_FOUND         No Rom ID structure is found
    601601**/
    602602EFI_STATUS
     
    608608
    609609/**
    610   PXE 
     610  PXE
    611611  START UNDI
    612612  Op-Code: PXENV_START_UNDI (0000h)
     
    637637  [BBS] specifications.
    638638  Returned from API service
    639   Status: See the PXENV_STATUS_xxx constants.   
    640 
    641   @param  SimpleNetworkDevice   Device instance
    642   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    643                                 for option ROM call.
    644                                
    645   @return Return value of PXE option ROM far call.                               
     639  Status: See the PXENV_STATUS_xxx constants.
     640
     641  @param  SimpleNetworkDevice   Device instance
     642  @param  PxeUndiTable          Point to structure which hold paramter and return value
     643                                for option ROM call.
     644
     645  @return Return value of PXE option ROM far call.
    646646**/
    647647EFI_STATUS
     
    653653
    654654/**
    655   PXE 
    656   UNDI STARTUP   
     655  PXE
     656  UNDI STARTUP
    657657  Op-Code: PXENV_UNDI_STARTUP (0001h)
    658658  Input: Far pointer to a PXENV_UNDI_STARTUP_T parameter structure that has been initialized by the
     
    671671  PXENV_STOP_UNDI API calls.
    672672  This service cannot be used in protected mode.
    673   typedef struct 
     673  typedef struct
    674674  {
    675675      PXENV_STATUS Status;
     
    681681
    682682  @param  SimpleNetworkDevice   Device instance
    683   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    684                                 for option ROM call.
    685                                
    686   @return Return value of PXE option ROM far call.   
     683  @param  PxeUndiTable          Point to structure which hold paramter and return value
     684                                for option ROM call.
     685
     686  @return Return value of PXE option ROM far call.
    687687**/
    688688EFI_STATUS
     
    694694
    695695/**
    696   PXE 
     696  PXE
    697697  UNDI CLEANUP
    698698  Op-Code: PXENV_UNDI_CLEANUP (0002h)
     
    714714
    715715  @param  SimpleNetworkDevice   Device instance
    716   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    717                                 for option ROM call.
    718                                
    719   @return Return value of PXE option ROM far call. 
     716  @param  PxeUndiTable          Point to structure which hold paramter and return value
     717                                for option ROM call.
     718
     719  @return Return value of PXE option ROM far call.
    720720**/
    721721EFI_STATUS
     
    727727
    728728/**
    729   PXE 
     729  PXE
    730730  UNDI INITIALIZE
    731731  Op-Code: PXENV_UNDI_INITIALIZE (0003h)
     
    757757  other application interfacing to the universal NIC driver
    758758  Returned from API service
    759   Status: See the PXENV_STATUS_xxx constants.   
    760  
     759  Status: See the PXENV_STATUS_xxx constants.
     760
    761761  @param  SimpleNetworkDevice   Device instance.
    762   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    763                                 for option ROM call.
    764                                
    765   @return Return value of PXE option ROM far call. 
     762  @param  PxeUndiTable          Point to structure which hold paramter and return value
     763                                for option ROM call.
     764
     765  @return Return value of PXE option ROM far call.
    766766**/
    767767EFI_STATUS
     
    774774/**
    775775  Wrapper routine for reset adapter.
    776  
    777   PXE 
     776
     777  PXE
    778778  UNDI RESET ADAPTER
    779779  Op-Code: PXENV_UNDI_RESET_ADAPTER (0004h)
     
    807807  Returned from API service
    808808  Status: See the PXENV_STATUS_xxx constants.
    809  
     809
    810810  @param  SimpleNetworkDevice   Device instance.
    811   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    812                                 for option ROM call.
    813   @param  RxFilter             Filter setting mask value for PXE recive .     
    814                                
    815   @return Return value of PXE option ROM far call. 
     811  @param  PxeUndiTable          Point to structure which hold paramter and return value
     812                                for option ROM call.
     813  @param  RxFilter             Filter setting mask value for PXE recive .
     814
     815  @return Return value of PXE option ROM far call.
    816816**/
    817817EFI_STATUS
     
    824824
    825825/**
    826   PXE 
     826  PXE
    827827  UNDI SHUTDOWN
    828828  Op-Code: PXENV_UNDI_SHUTDOWN (0005h)
     
    834834  Note: The contents of the PXENV_UNDI_STARTUP parameter structure need to be saved by the
    835835  Universal NIC Driver in case PXENV_UNDI_INITIALIZE is called again.
    836   typedef struct 
     836  typedef struct
    837837  {
    838838    PXENV_STATUS Status;
     
    842842  Returned from API service
    843843  Status: See the PXENV_STATUS_xxx constants.
    844  
    845   @param  SimpleNetworkDevice   Device instance
    846   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    847                                 for option ROM call.
    848                              
    849   @return Return value of PXE option ROM far call.   
     844
     845  @param  SimpleNetworkDevice   Device instance
     846  @param  PxeUndiTable          Point to structure which hold paramter and return value
     847                                for option ROM call.
     848
     849  @return Return value of PXE option ROM far call.
    850850**/
    851851EFI_STATUS
     
    857857
    858858/**
    859   PXE 
     859  PXE
    860860  UNDI OPEN
    861861  Op-Code: PXENV_UNDI_OPEN (0006h)
     
    889889  Returned from API service
    890890  Status: See the PXENV_STATUS_xxx constants.
    891  
    892   @param  SimpleNetworkDevice   Device instance
    893   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    894                                 for option ROM call.
    895                              
    896   @return Return value of PXE option ROM far call. 
     891
     892  @param  SimpleNetworkDevice   Device instance
     893  @param  PxeUndiTable          Point to structure which hold paramter and return value
     894                                for option ROM call.
     895
     896  @return Return value of PXE option ROM far call.
    897897**/
    898898EFI_STATUS
     
    904904
    905905/**
    906   PXE 
     906  PXE
    907907  UNDI CLOSE
    908908  Op-Code: PXENV_UNDI_CLOSE (0007h)
     
    920920  Returned from API service
    921921  Status: See the PXENV_STATUS_xxx constants.
    922  
    923   @param  SimpleNetworkDevice   Device instance
    924   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    925                                 for option ROM call.
    926                              
    927   @return Return value of PXE option ROM far call. 
     922
     923  @param  SimpleNetworkDevice   Device instance
     924  @param  PxeUndiTable          Point to structure which hold paramter and return value
     925                                for option ROM call.
     926
     927  @return Return value of PXE option ROM far call.
    928928**/
    929929EFI_STATUS
     
    935935
    936936/**
    937   PXE 
     937  PXE
    938938  UNDI TRANSMIT PACKET
    939939  Op-Code: PXENV_UNDI_TRANSMIT (0008h)
     
    10051005  DataBlock: Array of transmit data blocks.
    10061006  Returned from API service
    1007   Status: See the PXENV_STATUS_xxx constants 
    1008  
    1009   @param  SimpleNetworkDevice   Device instance
    1010   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1011                                 for option ROM call.
    1012                              
    1013   @return Return value of PXE option ROM far call. 
     1007  Status: See the PXENV_STATUS_xxx constants
     1008
     1009  @param  SimpleNetworkDevice   Device instance
     1010  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1011                                for option ROM call.
     1012
     1013  @return Return value of PXE option ROM far call.
    10141014**/
    10151015EFI_STATUS
     
    10211021
    10221022/**
    1023   PXE 
     1023  PXE
    10241024  UNDI SET MULTICAST ADDRESS
    10251025  Op-Code: PXENV_UNDI_SET_MCAST_ADDRESS (0009h)
     
    10391039  (0004h) API.
    10401040  Returned from API service
    1041   Status: See the PXENV_STATUS_xxx constants       
    1042  
    1043   @param  SimpleNetworkDevice   Device instance
    1044   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1045                                 for option ROM call.
    1046                              
    1047   @return Return value of PXE option ROM far call. 
     1041  Status: See the PXENV_STATUS_xxx constants
     1042
     1043  @param  SimpleNetworkDevice   Device instance
     1044  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1045                                for option ROM call.
     1046
     1047  @return Return value of PXE option ROM far call.
    10481048**/
    10491049EFI_STATUS
     
    10551055
    10561056/**
    1057   PXE 
     1057  PXE
    10581058  UNDI SET STATION ADDRESS
    10591059  Op-Code: PXENV_UNDI_SET_STATION_ADDRESS (000Ah)
     
    10741074  transmit and receive.
    10751075  Returned from API service
    1076   Status: See the PXENV_STATUS_xxx constants.     
    1077  
    1078   @param  SimpleNetworkDevice   Device instance
    1079   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1080                                 for option ROM call.
    1081                              
    1082   @return Return value of PXE option ROM far call. 
     1076  Status: See the PXENV_STATUS_xxx constants.
     1077
     1078  @param  SimpleNetworkDevice   Device instance
     1079  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1080                                for option ROM call.
     1081
     1082  @return Return value of PXE option ROM far call.
    10831083**/
    10841084EFI_STATUS
     
    10901090
    10911091/**
    1092   PXE 
     1092  PXE
    10931093  UNDI SET PACKET FILTER
    10941094  Op-Code: PXENV_UNDI_SET_PACKET_FILTER (000Bh)
     
    11081108  (0006h) API description.
    11091109  Returned from API service
    1110   Status: See the PXENV_STATUS_xxx constants.   
    1111  
    1112   @param  SimpleNetworkDevice   Device instance
    1113   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1114                                 for option ROM call.
    1115                              
    1116   @return Return value of PXE option ROM far call. 
     1110  Status: See the PXENV_STATUS_xxx constants.
     1111
     1112  @param  SimpleNetworkDevice   Device instance
     1113  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1114                                for option ROM call.
     1115
     1116  @return Return value of PXE option ROM far call.
    11171117**/
    11181118EFI_STATUS
     
    11241124
    11251125/**
    1126   PXE 
     1126  PXE
    11271127  UNDI GET INFORMATION
    11281128  Op-Code: PXENV_UNDI_GET_INFORMATION (000Ch)
     
    11671167  ROMAddress: Real mode ROM segment address.
    11681168  RxBufCnt: Receive queue length.
    1169   TxBufCnt: Transmit queue length. 
    1170  
    1171   @param  SimpleNetworkDevice   Device instance
    1172   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1173                                 for option ROM call.
    1174                              
    1175   @return Return value of PXE option ROM far call. 
     1169  TxBufCnt: Transmit queue length.
     1170
     1171  @param  SimpleNetworkDevice   Device instance
     1172  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1173                                for option ROM call.
     1174
     1175  @return Return value of PXE option ROM far call.
    11761176**/
    11771177EFI_STATUS
     
    11831183
    11841184/**
    1185   PXE 
     1185  PXE
    11861186  UNDI GET STATISTICS
    11871187  Op-Code: PXENV_UNDI_GET_STATISTICS (000Dh)
     
    12091209  RcvResourceErrors: Number of frames discarded
    12101210  because receive queue was full.
    1211  
    1212   @param  SimpleNetworkDevice   Device instance
    1213   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1214                                 for option ROM call.
    1215                              
    1216   @return Return value of PXE option ROM far call. 
     1211
     1212  @param  SimpleNetworkDevice   Device instance
     1213  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1214                                for option ROM call.
     1215
     1216  @return Return value of PXE option ROM far call.
    12171217**/
    12181218EFI_STATUS
     
    12241224
    12251225/**
    1226   PXE 
     1226  PXE
    12271227  UNDI CLEAR STATISTICS
    12281228  Op-Code: PXENV_UNDI_CLEAR_STATISTICS (000Eh)
     
    12391239  Returned from API service
    12401240  Status: See the PXENV_STATUS_xxx constants.
    1241  
    1242   @param  SimpleNetworkDevice   Device instance
    1243   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1244                                 for option ROM call.
    1245                              
    1246   @return Return value of PXE option ROM far call. 
     1241
     1242  @param  SimpleNetworkDevice   Device instance
     1243  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1244                                for option ROM call.
     1245
     1246  @return Return value of PXE option ROM far call.
    12471247**/
    12481248EFI_STATUS
     
    12541254
    12551255/**
    1256   PXE 
     1256  PXE
    12571257  UNDI INITIATE DIAGS
    12581258  Op-Code: PXENV_UNDI_INITIATE_DIAGS (000Fh)
     
    12691269  N/A
    12701270  Returned from API service
    1271   Status: See the PXENV_STATUS_xxx constants.   
    1272  
    1273   @param  SimpleNetworkDevice   Device instance
    1274   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1275                                 for option ROM call.
    1276                              
    1277   @return Return value of PXE option ROM far call. 
     1271  Status: See the PXENV_STATUS_xxx constants.
     1272
     1273  @param  SimpleNetworkDevice   Device instance
     1274  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1275                                for option ROM call.
     1276
     1277  @return Return value of PXE option ROM far call.
    12781278**/
    12791279EFI_STATUS
     
    12851285
    12861286/**
    1287   PXE 
     1287  PXE
    12881288  UNDI FORCE INTERRUPT
    12891289  Op-Code: PXENV_UNDI_FORCE_INTERRUPT (0010h)
     
    13061306  N/A
    13071307  Returned from API service
    1308   Status: See the PXENV_STATUS_xxx constants. 
    1309  
    1310   @param  SimpleNetworkDevice   Device instance
    1311   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1312                                 for option ROM call.
    1313                              
    1314   @return Return value of PXE option ROM far call. 
     1308  Status: See the PXENV_STATUS_xxx constants.
     1309
     1310  @param  SimpleNetworkDevice   Device instance
     1311  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1312                                for option ROM call.
     1313
     1314  @return Return value of PXE option ROM far call.
    13151315**/
    13161316EFI_STATUS
     
    13221322
    13231323/**
    1324   PXE 
     1324  PXE
    13251325  UNDI GET MULTICAST ADDRESS
    13261326  Op-Code: PXENV_UNDI_GET_MCAST_ADDRESS (0011h)
     
    13411341  Status: See the PXENV_STATUS_xxx constants.
    13421342  MediaAddr: MAC multicast address.
    1343  
    1344   @param  SimpleNetworkDevice   Device instance
    1345   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1346                                 for option ROM call.
    1347                              
    1348   @return Return value of PXE option ROM far call. 
     1343
     1344  @param  SimpleNetworkDevice   Device instance
     1345  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1346                                for option ROM call.
     1347
     1348  @return Return value of PXE option ROM far call.
    13491349**/
    13501350EFI_STATUS
     
    13561356
    13571357/**
    1358   PXE 
     1358  PXE
    13591359  UNDI GET NIC TYPE
    13601360  Op-Code: PXENV_UNDI_GET_NIC_TYPE (0012h)
     
    14061406  structure.
    14071407  Info: Information about the fields in this union can be found
    1408   in the [PnP] and [PCI] specifications   
    1409  
    1410   @param  SimpleNetworkDevice   Device instance
    1411   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1412                                 for option ROM call.
    1413                              
    1414   @return Return value of PXE option ROM far call. 
     1408  in the [PnP] and [PCI] specifications
     1409
     1410  @param  SimpleNetworkDevice   Device instance
     1411  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1412                                for option ROM call.
     1413
     1414  @return Return value of PXE option ROM far call.
    14151415**/
    14161416EFI_STATUS
     
    14221422
    14231423/**
    1424   PXE 
     1424  PXE
    14251425  UNDI GET IFACE INFO
    14261426  Op-Code: PXENV_UNDI_GET_IFACE_INFO (0013h)
     
    14551455  LinkSpeed: Defined in the NDIS 2.0 specification.
    14561456  ServiceFlags: Defined in the NDIS 2.0 specification.
    1457   Reserved: Must be zero.       
    1458  
    1459   @param  SimpleNetworkDevice   Device instance
    1460   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1461                                 for option ROM call.
    1462                              
    1463   @return Return value of PXE option ROM far call. 
     1457  Reserved: Must be zero.
     1458
     1459  @param  SimpleNetworkDevice   Device instance
     1460  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1461                                for option ROM call.
     1462
     1463  @return Return value of PXE option ROM far call.
    14641464**/
    14651465EFI_STATUS
     
    14711471
    14721472/**
    1473   PXE 
     1473  PXE
    14741474  UNDI ISR
    14751475  Op-Code: PXENV_UNDI_ISR (0014h)
     
    15131513  NETWORK INTERFACE level and returns PXENV_UNDI_ISR_OUT_DONE in the FuncFlag.
    15141514  IMPORTANT: It is possible for the protocol driver to be interrupted again while in the
    1515   strategy routine when the UNDI re-enables interrupts.   
    1516  
    1517   @param  SimpleNetworkDevice   Device instance
    1518   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1519                                 for option ROM call.
    1520                              
    1521   @return Return value of PXE option ROM far call. 
     1515  strategy routine when the UNDI re-enables interrupts.
     1516
     1517  @param  SimpleNetworkDevice   Device instance
     1518  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1519                                for option ROM call.
     1520
     1521  @return Return value of PXE option ROM far call.
    15221522**/
    15231523EFI_STATUS
     
    15291529
    15301530/**
    1531   PXE 
     1531  PXE
    15321532  STOP UNDI
    15331533  Op-Code: PXENV_STOP_UNDI (0015h)
     
    15481548  N/A
    15491549  Returned from API service
    1550   Status: See the PXENV_STATUS_xxx constants.     
    1551  
    1552   @param  SimpleNetworkDevice   Device instance
    1553   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1554                                 for option ROM call.
    1555                              
    1556   @return Return value of PXE option ROM far call. 
     1550  Status: See the PXENV_STATUS_xxx constants.
     1551
     1552  @param  SimpleNetworkDevice   Device instance
     1553  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1554                                for option ROM call.
     1555
     1556  @return Return value of PXE option ROM far call.
    15571557**/
    15581558EFI_STATUS
     
    15641564
    15651565/**
    1566   PXE 
     1566  PXE
    15671567  UNDI GET STATE
    15681568  Op-Code: PXENV_UNDI_GET_STATE (0015h)
     
    15961596  Description: This API function will be called at different levels of processing the interrupt. The FuncFlag field in
    15971597  the parameter block indicates the operation to be performed for the call. This field is filled with the
    1598   status of that operation on return.     
    1599  
    1600   @param  SimpleNetworkDevice   Device instance
    1601   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1602                                 for option ROM call.
    1603                              
    1604   @return Return value of PXE option ROM far call. 
     1598  status of that operation on return.
     1599
     1600  @param  SimpleNetworkDevice   Device instance
     1601  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1602                                for option ROM call.
     1603
     1604  @return Return value of PXE option ROM far call.
    16051605**/
    16061606EFI_STATUS
     
    16201620      push Index                              ;UINT16 is pushed onto stack.
    16211621      call dword ptr (s_PXE ptr es:[di]).EntryPointSP
    1622       add sp, 6 ;Caller cleans up stack. 
     1622      add sp, 6 ;Caller cleans up stack.
    16231623
    16241624  @param SimpleNetworkDevice    Device instance for simple network
     
    16261626  @param TableSize              The size of paramter/return value table
    16271627  @param CallIndex              The index of legacy call.
    1628  
    1629   @return EFI_STATUS 
     1628
     1629  @return EFI_STATUS
    16301630**/
    16311631EFI_STATUS
     
    16431643  @param NumPages     The number pages want to be allocated.
    16441644  @param Buffer       On return, allocated buffer.
    1645  
     1645
    16461646  @return Status of allocating pages.
    16471647**/
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/BiosThunk/Snp16Dxe/Misc.c

    r58459 r58466  
    11/** @file
    22  Helper Routines that use a PXE-enabled NIC option ROM.
    3  
     3
    44Copyright (c) 1999 - 2014, Intel Corporation. All rights reserved.<BR>
    55
     
    4040
    4141 @param VectorNumber  IVT number
    42  
     42
    4343 @retval EFI_SUCCESS Success to operation.
    4444**/
     
    5656
    5757/**
    58  Get interrupt vector address according to IVT number. 
    59  
     58 Get interrupt vector address according to IVT number.
     59
    6060 @param VectorNumber    Given IVT number
    61  
     61
    6262 @return cached interrupt vector address.
    6363**/
     
    7575
    7676/**
    77  Print Undi loader table. 
    78 
    79  @param UndiLoaderStructure Point to Undi Loader table structure. 
    80  
     77 Print Undi loader table.
     78
     79 @param UndiLoaderStructure Point to Undi Loader table structure.
     80
    8181**/
    8282VOID
     
    109109  Simple table dumper.  The ROMID table is necessary in order to effect
    110110  the "Early UNDI" trick.  Herein, the UNDI layer can be loaded in the
    111   pre-boot phase without having to download a Network Boot Program 
     111  pre-boot phase without having to download a Network Boot Program
    112112  across the wire.  It is required in the implementation in that we
    113113  are not using PXE.
    114114
    115115  @param RomIDStructure Point to RomID structure.
    116  
     116
    117117**/
    118118VOID
     
    200200
    201201  @param PxeTable Point to PXE table structure
    202  
     202
    203203**/
    204204VOID
     
    352352
    353353  @param PxenvTable Point to PXENV
    354  
     354
    355355**/
    356356VOID
     
    426426  This should install the !PXE and PXENV+ structures in memory for
    427427  subsequent use.
    428  
     428
    429429
    430430  @param SimpleNetworkDevice    Simple network device instance
    431431  @param RomAddress             The ROM base address for NIC rom.
    432  
    433   @retval EFI_NOT_FOUND         The check sum does not match 
    434   @retval EFI_NOT_FOUND         Rom ID offset is wrong 
    435   @retval EFI_NOT_FOUND         No Rom ID structure is found 
     432
     433  @retval EFI_NOT_FOUND         The check sum does not match
     434  @retval EFI_NOT_FOUND         Rom ID offset is wrong
     435  @retval EFI_NOT_FOUND         No Rom ID structure is found
    436436**/
    437437EFI_STATUS
     
    820820      push Index                              ;UINT16 is pushed onto stack.
    821821      call dword ptr (s_PXE ptr es:[di]).EntryPointSP
    822       add sp, 6 ;Caller cleans up stack. 
     822      add sp, 6 ;Caller cleans up stack.
    823823
    824824  @param SimpleNetworkDevice    Device instance for simple network
     
    826826  @param TableSize              The size of paramter/return value table
    827827  @param CallIndex              The index of legacy call.
    828  
    829   @return EFI_STATUS 
     828
     829  @return EFI_STATUS
    830830**/
    831831EFI_STATUS
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/BiosThunk/Snp16Dxe/Pxe.h

    r48674 r58466  
    33
    44  This file relies upon the existence of a PXE-compliant ROM
    5   in memory, as defined by the Preboot Execution Environment 
     5  in memory, as defined by the Preboot Execution Environment
    66  Specification (PXE), Version 2.1, located at
    77
     
    7070//
    7171//    Status codes returned in the status word of PXENV API parameter structures.
    72 // 
     72//
    7373//    Generic API errors - these do not match up with the M0x or E0x messages
    7474//    that are reported by the loader.
     
    9393/* Driver errors (0x60 to 0x6F) */
    9494
    95 // These errors are for UNDI compatible NIC drivers. 
     95// These errors are for UNDI compatible NIC drivers.
    9696#define PXENV_STATUS_UNDI_INVALID_FUNCTION          0x60
    9797#define PXENV_STATUS_UNDI_MEDIATEST_FAILED          0x61
     
    261261#define ADDR_LEN                      16
    262262#define MAXNUM_MCADDR                 8
    263 #define IPLEN                         4       ///< length of an IP address 
     263#define IPLEN                         4       ///< length of an IP address
    264264#define XMT_DESTADDR                  0x0000  ///< destination address given
    265265#define XMT_BROADCAST                 0x0001  ///< use broadcast address
     
    289289  IN UINT16   Bx;           ///<     filled in with the same data
    290290  IN UINT16   Dx;           ///<     that was passed to the MLID
    291   IN UINT16   Di;           ///<     option ROM boot code by the 
     291  IN UINT16   Di;           ///<     option ROM boot code by the
    292292  IN UINT16   Es;           ///<     system BIOS.
    293293} PXENV_START_UNDI_T;
     
    303303typedef struct {
    304304  OUT UINT16  Status;       ///< Out: PXENV_STATUS_xxx
    305  
     305
    306306  ///
    307307  ///  This is an input parameter and is a 32-bit physical address of
     
    316316  ///  interfacing to the Universal NIC Driver.
    317317  ///
    318   IN UINT32   ProtocolIni; 
     318  IN UINT32   ProtocolIni;
    319319  UINT8       Reserved[8];
    320320} PXENV_UNDI_INITIALIZE_T;
     
    330330    addresses provided in any  call.    So  the  application  must
    331331    provide the multicast address  list with all  the calls that
    332     reset the receive unit of the adapter. 
     332    reset the receive unit of the adapter.
    333333  --*/
    334334typedef struct {
    335   OUT UINT16  Status;                     ///< Out: PXENV_STATUS_xxx 
     335  OUT UINT16  Status;                     ///< Out: PXENV_STATUS_xxx
    336336} PXENV_UNDI_SHUTDOWN_T;
    337337
    338338typedef struct {
    339339  OUT UINT16                  Status;     ///< Out: PXENV_STATUS_xxx
    340  
     340
    341341  ///
    342342  ///  This is  an input parameter and is  adapter specific.  This is
    343343  ///  supported  for Universal NDIS 2.0 driver to pass down the Open
    344344  ///  flags  provided  by   the  protocol   driver  (See   NDIS  2.0
    345   ///  specifications).  This can be zero. 
    346   ///   
    347   IN UINT16                   OpenFlag;   ///< In: See description below 
    348   IN UINT16                   PktFilter;  ///< In: Filter for receiving 
     345  ///  specifications).  This can be zero.
     346  ///
     347  IN UINT16                   OpenFlag;   ///< In: See description below
     348  IN UINT16                   PktFilter;  ///< In: Filter for receiving
    349349
    350350  /* packet. It takes the following */
     
    356356#define FLTR_BRDCST   0x0002                ///< broadcast packets
    357357#define FLTR_PRMSCS   0x0004                ///< any packet on LAN
    358 #define FLTR_SRC_RTG  0x0008                ///< source routing packet 
     358#define FLTR_SRC_RTG  0x0008                ///< source routing packet
    359359  IN PXENV_UNDI_MCAST_ADDR_T  McastBuffer;  /* In: */
    360360  /* See t_PXENV_UNDI_MCAST_ADDR. */
     
    371371
    372372  /* bytes. */
    373   UINT16    XmitOffset;   ///< 16-bit segment & offset of the 
    374   UINT16    XmitSegment;  ///< immediate data buffer. 
    375   UINT16    DataBlkCount; ///< In: Number of data blocks. 
     373  UINT16    XmitOffset;   ///< 16-bit segment & offset of the
     374  UINT16    XmitSegment;  ///< immediate data buffer.
     375  UINT16    DataBlkCount; ///< In: Number of data blocks.
    376376  struct DataBlk {
    377     UINT8   TDPtrType;    ///< 0 => 32 bit Phys pointer in TDDataPtr, not supported in this version of LSA 
     377    UINT8   TDPtrType;    ///< 0 => 32 bit Phys pointer in TDDataPtr, not supported in this version of LSA
    378378                          ///< 1 => seg:offser in TDDataPtr which can be a real mode or 16-bit protected mode pointer
    379     UINT8   TDRsvdByte;         ///< Reserved, must be zero. 
    380     UINT16  TDDataLen;          ///< Data block length in bytes. 
    381     UINT16  TDDataPtrOffset;    ///< Far pointer to data buffer. 
    382     UINT16  TDDataPtrSegment;   ///< Far pointer to data buffer. 
     379    UINT8   TDRsvdByte;         ///< Reserved, must be zero.
     380    UINT16  TDDataLen;          ///< Data block length in bytes.
     381    UINT16  TDDataPtrOffset;    ///< Far pointer to data buffer.
     382    UINT16  TDDataPtrSegment;   ///< Far pointer to data buffer.
    383383  } DataBlock[MAX_DATA_BLKS];
    384384}
     
    386386
    387387typedef struct {
    388   OUT UINT16  Status;           ///< Out: PXENV_STATUS_xxx 
     388  OUT UINT16  Status;           ///< Out: PXENV_STATUS_xxx
    389389
    390390  ///
     
    404404  ///  the   NIC  driver   fills  the   broadcast  address   for  the
    405405  ///  destination.
    406   /// 
    407   IN UINT8    XmitFlag;   
    408 #define XMT_DESTADDR  0x0000    ///< destination address given 
     406  ///
     407  IN UINT8    XmitFlag;
     408#define XMT_DESTADDR  0x0000    ///< destination address given
    409409#define XMT_BROADCAST 0x0001    ///< use broadcast address
    410410
     
    416416  ///  (with  Address Resolution Protocol) and NIC driver does not do
    417417  ///  any address resolution.
    418   /// 
     418  ///
    419419  IN UINT16   DestAddrOffset;   ///< 16-bit segment & offset of the
    420420  IN UINT16   DestAddrSegment;  ///< destination media address
    421421
    422  
    423   IN UINT16   TBDOffset;  ///< 16-bit segment & offset of the 
    424   IN UINT16   TBDSegment; ///< transmit buffer descriptor of type 
    425 
    426   /// XmitBufferDesc 
     422
     423  IN UINT16   TBDOffset;  ///< 16-bit segment & offset of the
     424  IN UINT16   TBDSegment; ///< transmit buffer descriptor of type
     425
     426  /// XmitBufferDesc
    427427  IN UINT32   Reserved[2];
    428428} PXENV_UNDI_TRANSMIT_T;
     
    430430
    431431typedef struct {
    432   OUT UINT16                  Status;       ///<  Out: PXENV_STATUS_xxx 
    433   IN PXENV_UNDI_MCAST_ADDR_T  McastBuffer;  ///<  In: 
     432  OUT UINT16                  Status;       ///<  Out: PXENV_STATUS_xxx
     433  IN PXENV_UNDI_MCAST_ADDR_T  McastBuffer;  ///<  In:
    434434} PXENV_UNDI_SET_MCAST_ADDR_T;
    435435
    436436typedef struct {
    437   OUT UINT16  Status;                   ///< Out: PXENV_STATUS_xxx 
    438   IN UINT8    StationAddress[ADDR_LEN]; ///< new address to be set 
     437  OUT UINT16  Status;                   ///< Out: PXENV_STATUS_xxx
     438  IN UINT8    StationAddress[ADDR_LEN]; ///< new address to be set
    439439} PXENV_UNDI_SET_STATION_ADDR_T;
    440440
    441441typedef struct s_PXENV_UNDI_SET_PACKET_FILTER {
    442   OUT UINT16  Status;                   ///< Out: PXENV_STATUS_xxx 
    443   IN UINT8    Filter;                   ///< In: Receive filter value. 
     442  OUT UINT16  Status;                   ///< Out: PXENV_STATUS_xxx
     443  IN UINT8    Filter;                   ///< In: Receive filter value.
    444444} PXENV_UNDI_SET_PACKET_FILTER_T;
    445445
    446446typedef struct {
    447   OUT UINT16  Status;       ///< Out: PXENV_STATUS_xxx 
    448   OUT UINT16  BaseIo;       ///< Out: Adapter's Base IO 
    449   OUT UINT16  IntNumber;    ///< Out: IRQ number 
    450   OUT UINT16  MaxTranUnit;  ///< Out: MTU 
    451   OUT UINT16  HwType;       ///< Out: type of protocol at hardware level 
     447  OUT UINT16  Status;       ///< Out: PXENV_STATUS_xxx
     448  OUT UINT16  BaseIo;       ///< Out: Adapter's Base IO
     449  OUT UINT16  IntNumber;    ///< Out: IRQ number
     450  OUT UINT16  MaxTranUnit;  ///< Out: MTU
     451  OUT UINT16  HwType;       ///< Out: type of protocol at hardware level
    452452
    453453#define ETHER_TYPE      1
     
    455455#define IEEE_TYPE       6
    456456#define ARCNET_TYPE     7
    457   /*++ 
     457  /*++
    458458        other numbers can  be obtained from  rfc1010 for "Assigned
    459459        Numbers".  This number may not be validated by the application
    460460        and hence adding new numbers to the list should be fine at any
    461         time. 
     461        time.
    462462    --*/
    463   OUT UINT16  HwAddrLen;                    ///< Out: actual length of hardware address 
     463  OUT UINT16  HwAddrLen;                    ///< Out: actual length of hardware address
    464464  OUT UINT8   CurrentNodeAddress[ADDR_LEN]; ///< Out: Current hardware address
    465465  OUT UINT8   PermNodeAddress[ADDR_LEN];    ///< Out: Permanent hardware address
    466   OUT UINT16  ROMAddress;                   ///< Out: ROM address 
    467   OUT UINT16  RxBufCt;                      ///< Out: receive Queue length   
    468   OUT UINT16  TxBufCt;                      ///< Out: Transmit Queue length 
     466  OUT UINT16  ROMAddress;                   ///< Out: ROM address
     467  OUT UINT16  RxBufCt;                      ///< Out: receive Queue length
     468  OUT UINT16  TxBufCt;                      ///< Out: Transmit Queue length
    469469} PXENV_UNDI_GET_INFORMATION_T;
    470470
    471471typedef struct {
    472   OUT UINT16  Status;                       ///< Out: PXENV_STATUS_xxx 
    473   OUT UINT32  XmtGoodFrames;                ///< Out: No. of good transmissions 
    474   OUT UINT32  RcvGoodFrames;                ///< Out: No. of good frames received 
    475   OUT UINT32  RcvCRCErrors;                 ///< Out: No. of frames with CRC error 
    476   OUT UINT32  RcvResourceErrors;            ///< Out: no. of frames discarded 
     472  OUT UINT16  Status;                       ///< Out: PXENV_STATUS_xxx
     473  OUT UINT32  XmtGoodFrames;                ///< Out: No. of good transmissions
     474  OUT UINT32  RcvGoodFrames;                ///< Out: No. of good frames received
     475  OUT UINT32  RcvCRCErrors;                 ///< Out: No. of frames with CRC error
     476  OUT UINT32  RcvResourceErrors;            ///< Out: no. of frames discarded
    477477  /* Out: receive Queue full */
    478478} PXENV_UNDI_GET_STATISTICS_T;
    479479
    480480typedef struct {
    481   OUT UINT16  Status;               ///< Out: PXENV_STATUS_xxx 
     481  OUT UINT16  Status;               ///< Out: PXENV_STATUS_xxx
    482482} PXENV_UNDI_CLEAR_STATISTICS_T;
    483483
     
    491491
    492492typedef struct {
    493   OUT UINT16  Status;               ///< Out: PXENV_STATUS_xxx 
    494   IN UINT32   InetAddr;             ///< In: IP Multicast Address 
    495   OUT UINT8   MediaAddr[ADDR_LEN];  ///< Out: corresponding hardware 
     493  OUT UINT16  Status;               ///< Out: PXENV_STATUS_xxx
     494  IN UINT32   InetAddr;             ///< In: IP Multicast Address
     495  OUT UINT8   MediaAddr[ADDR_LEN];  ///< Out: corresponding hardware
    496496  /*      multicast address */
    497497} PXENV_UNDI_GET_MCAST_ADDR_T;
    498498
    499499typedef struct {
    500     OUT UINT16  Vendor_ID;  ///< OUT: 
    501     OUT UINT16  Dev_ID;     ///< OUT: 
    502     OUT UINT8   Base_Class; ///< OUT: 
    503     OUT UINT8   Sub_Class;  ///< OUT: 
    504     OUT UINT8   Prog_Intf;  ///< OUT: program interface 
    505     OUT UINT8   Rev;        ///< OUT: Revision number 
    506     OUT UINT16  BusDevFunc; ///< OUT: Bus, Device  & Function numbers 
    507     OUT UINT16  SubVendor_ID; ///< OUT: 
    508     OUT UINT16  SubDevice_ID; ///< OUT: 
     500    OUT UINT16  Vendor_ID;  ///< OUT:
     501    OUT UINT16  Dev_ID;     ///< OUT:
     502    OUT UINT8   Base_Class; ///< OUT:
     503    OUT UINT8   Sub_Class;  ///< OUT:
     504    OUT UINT8   Prog_Intf;  ///< OUT: program interface
     505    OUT UINT8   Rev;        ///< OUT: Revision number
     506    OUT UINT16  BusDevFunc; ///< OUT: Bus, Device  & Function numbers
     507    OUT UINT16  SubVendor_ID; ///< OUT:
     508    OUT UINT16  SubDevice_ID; ///< OUT:
    509509} PCI_INFO_T;
    510510
    511511typedef struct {
    512     OUT UINT32  EISA_Dev_ID;  ///< Out: 
    513     OUT UINT8   Base_Class;   ///< OUT: 
    514     OUT UINT8   Sub_Class;    ///< OUT: 
    515     OUT UINT8   Prog_Intf;    ///< OUT: program interface 
    516     OUT UINT16  CardSelNum;   ///< OUT: Card Selector Number 
    517     OUT UINT8   Reserved;     ///< to make it 10 bytes 
     512    OUT UINT32  EISA_Dev_ID;  ///< Out:
     513    OUT UINT8   Base_Class;   ///< OUT:
     514    OUT UINT8   Sub_Class;    ///< OUT:
     515    OUT UINT8   Prog_Intf;    ///< OUT: program interface
     516    OUT UINT16  CardSelNum;   ///< OUT: Card Selector Number
     517    OUT UINT8   Reserved;     ///< to make it 10 bytes
    518518} PNP_INFO_T;
    519519
     
    525525
    526526typedef struct {
    527   OUT UINT16  Status;         ///< OUT: PXENV_STATUS_xxx 
    528   OUT UINT8   NicType;        ///< OUT: 2=PCI, 3=PnP 
     527  OUT UINT16  Status;         ///< OUT: PXENV_STATUS_xxx
     528  OUT UINT8   NicType;        ///< OUT: 2=PCI, 3=PnP
    529529  PCI_PNP_INFO_T PciPnpInfo;
    530530} PXENV_UNDI_GET_NIC_TYPE_T;
    531531
    532532typedef struct {
    533   OUT UINT16  Status;           ///< OUT: PXENV_STATUS_xxx 
    534   OUT UINT8   IfaceType[16];    ///< OUT: Type name of MAC, AsciiZ 
     533  OUT UINT16  Status;           ///< OUT: PXENV_STATUS_xxx
     534  OUT UINT8   IfaceType[16];    ///< OUT: Type name of MAC, AsciiZ
    535535
    536536  /*      format.  This is used by the */
     
    543543
    544544  /*      characteristic table */
    545   OUT UINT32  LinkSpeed;    ///< OUT: 
    546   OUT UINT32  ServiceFlags; ///< OUT: as defined in NDIS Spec 2.0X 
     545  OUT UINT32  LinkSpeed;    ///< OUT:
     546  OUT UINT32  ServiceFlags; ///< OUT: as defined in NDIS Spec 2.0X
    547547  OUT UINT32  Reserved[4];  ///< OUT: will be filled with 0s till defined
    548548} PXENV_UNDI_GET_NDIS_INFO_T;
    549549
    550550typedef struct {
    551   OUT UINT16    Status;   ///< OUT: PXENV_STATUS_xxx 
    552   IN OUT UINT16 FuncFlag; ///< In: PXENV_UNDI_ISR_IN_xxx 
     551  OUT UINT16    Status;   ///< OUT: PXENV_STATUS_xxx
     552  IN OUT UINT16 FuncFlag; ///< In: PXENV_UNDI_ISR_IN_xxx
    553553
    554554  /* Out: PXENV_UNDI_ISR_OUT_xxx */
     
    581581
    582582 --*/
    583 #define PXENV_UNDI_ISR_OUT_OURS 0 ///< This is our interrupt.  Deal  with it. 
     583#define PXENV_UNDI_ISR_OUT_OURS 0 ///< This is our interrupt.  Deal  with it.
    584584#define PXENV_UNDI_ISR_OUT_NOT_OURS 1 ///< This is not our interrupt.
    585585
     
    590590
    591591--*/
    592 #define PXENV_UNDI_ISR_OUT_DONE 0       ///< We are done processing this  interrupt. 
    593 #define PXENV_UNDI_ISR_OUT_TRANSMIT 2   ///< We completed a transmit interrupt. 
    594 #define PXENV_UNDI_ISR_OUT_RECEIVE  3   ///< Get data from receive buffer. 
     592#define PXENV_UNDI_ISR_OUT_DONE 0       ///< We are done processing this  interrupt.
     593#define PXENV_UNDI_ISR_OUT_TRANSMIT 2   ///< We completed a transmit interrupt.
     594#define PXENV_UNDI_ISR_OUT_RECEIVE  3   ///< Get data from receive buffer.
    595595
    596596#define PXENV_UNDI_ISR_OUT_BUSY     4 /* ? */
    597597
    598598typedef struct {
    599   UINT16  Status;                     ///< Out: PXENV_STATUS_xxx 
     599  UINT16  Status;                     ///< Out: PXENV_STATUS_xxx
    600600} PXENV_STOP_UNDI_T;
    601601
    602 #define PXENV_UNDI_STARTED      1     ///< not even initialized 
    603 #define PXENV_UNDI_INITIALIZED  2     ///< initialized and closed (not opened) 
    604 #define PXENV_UNDI_OPENED       3     ///< initialized & opened 
    605 
    606 typedef struct {
    607   OUT UINT16  Status;                 ///< Out: PXENV_STATUS_xxx 
     602#define PXENV_UNDI_STARTED      1     ///< not even initialized
     603#define PXENV_UNDI_INITIALIZED  2     ///< initialized and closed (not opened)
     604#define PXENV_UNDI_OPENED       3     ///< initialized & opened
     605
     606typedef struct {
     607  OUT UINT16  Status;                 ///< Out: PXENV_STATUS_xxx
    608608  UINT16      UNDI_State;
    609609} PXENV_UNDI_GET_STATE_T;
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/BiosThunk/Snp16Dxe/PxeUndi.c

    r48674 r58466  
    1 /** @file 
    2   Wrapper routines that use a PXE-enabled NIC option ROM to 
    3   supply internal routines for an EFI SNI (Simple Network 
     1/** @file
     2  Wrapper routines that use a PXE-enabled NIC option ROM to
     3  supply internal routines for an EFI SNI (Simple Network
    44  Interface) Protocol.
    55
    66  This file relies upon the existence of a PXE-compliant ROM
    7   in memory, as defined by the Preboot Execution Environment 
     7  in memory, as defined by the Preboot Execution Environment
    88  Specification (PXE), Version 2.1, located at
    99
     
    2626
    2727/**
    28   PXE 
     28  PXE
    2929  START UNDI
    3030  Op-Code: PXENV_START_UNDI (0000h)
     
    5555  [BBS] specifications.
    5656  Returned from API service
    57   Status: See the PXENV_STATUS_xxx constants.   
    58 
    59   @param  SimpleNetworkDevice   Device instance
    60   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    61                                 for option ROM call.
    62                                
    63   @return Return value of PXE option ROM far call.                               
     57  Status: See the PXENV_STATUS_xxx constants.
     58
     59  @param  SimpleNetworkDevice   Device instance
     60  @param  PxeUndiTable          Point to structure which hold paramter and return value
     61                                for option ROM call.
     62
     63  @return Return value of PXE option ROM far call.
    6464**/
    6565EFI_STATUS
     
    7878
    7979/**
    80   PXE 
    81   UNDI STARTUP   
     80  PXE
     81  UNDI STARTUP
    8282  Op-Code: PXENV_UNDI_STARTUP (0001h)
    8383  Input: Far pointer to a PXENV_UNDI_STARTUP_T parameter structure that has been initialized by the
     
    9696  PXENV_STOP_UNDI API calls.
    9797  This service cannot be used in protected mode.
    98   typedef struct 
     98  typedef struct
    9999  {
    100100      PXENV_STATUS Status;
     
    106106
    107107  @param  SimpleNetworkDevice   Device instance
    108   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    109                                 for option ROM call.
    110                                
    111   @return Return value of PXE option ROM far call.   
     108  @param  PxeUndiTable          Point to structure which hold paramter and return value
     109                                for option ROM call.
     110
     111  @return Return value of PXE option ROM far call.
    112112**/
    113113EFI_STATUS
     
    126126
    127127/**
    128   PXE 
     128  PXE
    129129  UNDI CLEANUP
    130130  Op-Code: PXENV_UNDI_CLEANUP (0002h)
     
    146146
    147147  @param  SimpleNetworkDevice   Device instance
    148   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    149                                 for option ROM call.
    150                                
    151   @return Return value of PXE option ROM far call. 
     148  @param  PxeUndiTable          Point to structure which hold paramter and return value
     149                                for option ROM call.
     150
     151  @return Return value of PXE option ROM far call.
    152152**/
    153153EFI_STATUS
     
    166166
    167167/**
    168   PXE 
     168  PXE
    169169  UNDI INITIALIZE
    170170  Op-Code: PXENV_UNDI_INITIALIZE (0003h)
     
    196196  other application interfacing to the universal NIC driver
    197197  Returned from API service
    198   Status: See the PXENV_STATUS_xxx constants.   
    199  
    200   @param  SimpleNetworkDevice   Device instance
    201   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    202                                 for option ROM call.
    203                                
    204   @return Return value of PXE option ROM far call. 
     198  Status: See the PXENV_STATUS_xxx constants.
     199
     200  @param  SimpleNetworkDevice   Device instance
     201  @param  PxeUndiTable          Point to structure which hold paramter and return value
     202                                for option ROM call.
     203
     204  @return Return value of PXE option ROM far call.
    205205**/
    206206EFI_STATUS
     
    220220/**
    221221  Wrapper routine for reset adapter.
    222  
    223   PXE 
     222
     223  PXE
    224224  UNDI RESET ADAPTER
    225225  Op-Code: PXENV_UNDI_RESET_ADAPTER (0004h)
     
    253253  Returned from API service
    254254  Status: See the PXENV_STATUS_xxx constants.
    255  
     255
    256256  @param  SimpleNetworkDevice   Device instance.
    257   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    258                                 for option ROM call.
    259   @param  RxFilter             Filter setting mask value for PXE recive .     
    260                                
    261   @return Return value of PXE option ROM far call. 
     257  @param  PxeUndiTable          Point to structure which hold paramter and return value
     258                                for option ROM call.
     259  @param  RxFilter             Filter setting mask value for PXE recive .
     260
     261  @return Return value of PXE option ROM far call.
    262262**/
    263263EFI_STATUS
     
    311311    &PxeUndiTable->R_Mcast_Buf,
    312312    sizeof (PXENV_UNDI_MCAST_ADDR_T)
    313     );     
    314  
     313    );
     314
    315315
    316316  Status = MakePxeCall (
     
    328328
    329329/**
    330   PXE 
     330  PXE
    331331  UNDI SHUTDOWN
    332332  Op-Code: PXENV_UNDI_SHUTDOWN (0005h)
     
    338338  Note: The contents of the PXENV_UNDI_STARTUP parameter structure need to be saved by the
    339339  Universal NIC Driver in case PXENV_UNDI_INITIALIZE is called again.
    340   typedef struct 
     340  typedef struct
    341341  {
    342342    PXENV_STATUS Status;
     
    346346  Returned from API service
    347347  Status: See the PXENV_STATUS_xxx constants.
    348  
    349   @param  SimpleNetworkDevice   Device instance
    350   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    351                                 for option ROM call.
    352                              
    353   @return Return value of PXE option ROM far call.   
     348
     349  @param  SimpleNetworkDevice   Device instance
     350  @param  PxeUndiTable          Point to structure which hold paramter and return value
     351                                for option ROM call.
     352
     353  @return Return value of PXE option ROM far call.
    354354**/
    355355EFI_STATUS
     
    368368
    369369/**
    370   PXE 
     370  PXE
    371371  UNDI OPEN
    372372  Op-Code: PXENV_UNDI_OPEN (0006h)
     
    400400  Returned from API service
    401401  Status: See the PXENV_STATUS_xxx constants.
    402  
    403   @param  SimpleNetworkDevice   Device instance
    404   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    405                                 for option ROM call.
    406                              
    407   @return Return value of PXE option ROM far call. 
     402
     403  @param  SimpleNetworkDevice   Device instance
     404  @param  PxeUndiTable          Point to structure which hold paramter and return value
     405                                for option ROM call.
     406
     407  @return Return value of PXE option ROM far call.
    408408**/
    409409EFI_STATUS
     
    422422
    423423/**
    424   PXE 
     424  PXE
    425425  UNDI CLOSE
    426426  Op-Code: PXENV_UNDI_CLOSE (0007h)
     
    438438  Returned from API service
    439439  Status: See the PXENV_STATUS_xxx constants.
    440  
    441   @param  SimpleNetworkDevice   Device instance
    442   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    443                                 for option ROM call.
    444                              
    445   @return Return value of PXE option ROM far call. 
     440
     441  @param  SimpleNetworkDevice   Device instance
     442  @param  PxeUndiTable          Point to structure which hold paramter and return value
     443                                for option ROM call.
     444
     445  @return Return value of PXE option ROM far call.
    446446**/
    447447EFI_STATUS
     
    460460
    461461/**
    462   PXE 
     462  PXE
    463463  UNDI TRANSMIT PACKET
    464464  Op-Code: PXENV_UNDI_TRANSMIT (0008h)
     
    530530  DataBlock: Array of transmit data blocks.
    531531  Returned from API service
    532   Status: See the PXENV_STATUS_xxx constants 
    533  
    534   @param  SimpleNetworkDevice   Device instance
    535   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    536                                 for option ROM call.
    537                              
    538   @return Return value of PXE option ROM far call. 
     532  Status: See the PXENV_STATUS_xxx constants
     533
     534  @param  SimpleNetworkDevice   Device instance
     535  @param  PxeUndiTable          Point to structure which hold paramter and return value
     536                                for option ROM call.
     537
     538  @return Return value of PXE option ROM far call.
    539539**/
    540540EFI_STATUS
     
    566566
    567567/**
    568   PXE 
     568  PXE
    569569  UNDI SET MULTICAST ADDRESS
    570570  Op-Code: PXENV_UNDI_SET_MCAST_ADDRESS (0009h)
     
    584584  (0004h) API.
    585585  Returned from API service
    586   Status: See the PXENV_STATUS_xxx constants       
    587  
    588   @param  SimpleNetworkDevice   Device instance
    589   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    590                                 for option ROM call.
    591                              
    592   @return Return value of PXE option ROM far call. 
     586  Status: See the PXENV_STATUS_xxx constants
     587
     588  @param  SimpleNetworkDevice   Device instance
     589  @param  PxeUndiTable          Point to structure which hold paramter and return value
     590                                for option ROM call.
     591
     592  @return Return value of PXE option ROM far call.
    593593**/
    594594EFI_STATUS
     
    607607
    608608/**
    609   PXE 
     609  PXE
    610610  UNDI SET STATION ADDRESS
    611611  Op-Code: PXENV_UNDI_SET_STATION_ADDRESS (000Ah)
     
    626626  transmit and receive.
    627627  Returned from API service
    628   Status: See the PXENV_STATUS_xxx constants.     
    629  
    630   @param  SimpleNetworkDevice   Device instance
    631   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    632                                 for option ROM call.
    633                              
    634   @return Return value of PXE option ROM far call. 
     628  Status: See the PXENV_STATUS_xxx constants.
     629
     630  @param  SimpleNetworkDevice   Device instance
     631  @param  PxeUndiTable          Point to structure which hold paramter and return value
     632                                for option ROM call.
     633
     634  @return Return value of PXE option ROM far call.
    635635**/
    636636EFI_STATUS
     
    649649
    650650/**
    651   PXE 
     651  PXE
    652652  UNDI SET PACKET FILTER
    653653  Op-Code: PXENV_UNDI_SET_PACKET_FILTER (000Bh)
     
    667667  (0006h) API description.
    668668  Returned from API service
    669   Status: See the PXENV_STATUS_xxx constants.   
    670  
    671   @param  SimpleNetworkDevice   Device instance
    672   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    673                                 for option ROM call.
    674                              
    675   @return Return value of PXE option ROM far call. 
     669  Status: See the PXENV_STATUS_xxx constants.
     670
     671  @param  SimpleNetworkDevice   Device instance
     672  @param  PxeUndiTable          Point to structure which hold paramter and return value
     673                                for option ROM call.
     674
     675  @return Return value of PXE option ROM far call.
    676676**/
    677677EFI_STATUS
     
    690690
    691691/**
    692   PXE 
     692  PXE
    693693  UNDI GET INFORMATION
    694694  Op-Code: PXENV_UNDI_GET_INFORMATION (000Ch)
     
    733733  ROMAddress: Real mode ROM segment address.
    734734  RxBufCnt: Receive queue length.
    735   TxBufCnt: Transmit queue length. 
    736  
    737   @param  SimpleNetworkDevice   Device instance
    738   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    739                                 for option ROM call.
    740                              
    741   @return Return value of PXE option ROM far call. 
     735  TxBufCnt: Transmit queue length.
     736
     737  @param  SimpleNetworkDevice   Device instance
     738  @param  PxeUndiTable          Point to structure which hold paramter and return value
     739                                for option ROM call.
     740
     741  @return Return value of PXE option ROM far call.
    742742**/
    743743EFI_STATUS
     
    756756
    757757/**
    758   PXE 
     758  PXE
    759759  UNDI GET STATISTICS
    760760  Op-Code: PXENV_UNDI_GET_STATISTICS (000Dh)
     
    782782  RcvResourceErrors: Number of frames discarded
    783783  because receive queue was full.
    784  
    785   @param  SimpleNetworkDevice   Device instance
    786   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    787                                 for option ROM call.
    788                              
    789   @return Return value of PXE option ROM far call. 
     784
     785  @param  SimpleNetworkDevice   Device instance
     786  @param  PxeUndiTable          Point to structure which hold paramter and return value
     787                                for option ROM call.
     788
     789  @return Return value of PXE option ROM far call.
    790790**/
    791791EFI_STATUS
     
    804804
    805805/**
    806   PXE 
     806  PXE
    807807  UNDI CLEAR STATISTICS
    808808  Op-Code: PXENV_UNDI_CLEAR_STATISTICS (000Eh)
     
    819819  Returned from API service
    820820  Status: See the PXENV_STATUS_xxx constants.
    821  
    822   @param  SimpleNetworkDevice   Device instance
    823   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    824                                 for option ROM call.
    825                              
    826   @return Return value of PXE option ROM far call. 
     821
     822  @param  SimpleNetworkDevice   Device instance
     823  @param  PxeUndiTable          Point to structure which hold paramter and return value
     824                                for option ROM call.
     825
     826  @return Return value of PXE option ROM far call.
    827827**/
    828828EFI_STATUS
     
    841841
    842842/**
    843   PXE 
     843  PXE
    844844  UNDI INITIATE DIAGS
    845845  Op-Code: PXENV_UNDI_INITIATE_DIAGS (000Fh)
     
    856856  N/A
    857857  Returned from API service
    858   Status: See the PXENV_STATUS_xxx constants.   
    859  
    860   @param  SimpleNetworkDevice   Device instance
    861   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    862                                 for option ROM call.
    863                              
    864   @return Return value of PXE option ROM far call. 
     858  Status: See the PXENV_STATUS_xxx constants.
     859
     860  @param  SimpleNetworkDevice   Device instance
     861  @param  PxeUndiTable          Point to structure which hold paramter and return value
     862                                for option ROM call.
     863
     864  @return Return value of PXE option ROM far call.
    865865**/
    866866EFI_STATUS
     
    879879
    880880/**
    881   PXE 
     881  PXE
    882882  UNDI FORCE INTERRUPT
    883883  Op-Code: PXENV_UNDI_FORCE_INTERRUPT (0010h)
     
    900900  N/A
    901901  Returned from API service
    902   Status: See the PXENV_STATUS_xxx constants. 
    903  
    904   @param  SimpleNetworkDevice   Device instance
    905   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    906                                 for option ROM call.
    907                              
    908   @return Return value of PXE option ROM far call. 
     902  Status: See the PXENV_STATUS_xxx constants.
     903
     904  @param  SimpleNetworkDevice   Device instance
     905  @param  PxeUndiTable          Point to structure which hold paramter and return value
     906                                for option ROM call.
     907
     908  @return Return value of PXE option ROM far call.
    909909**/
    910910EFI_STATUS
     
    923923
    924924/**
    925   PXE 
     925  PXE
    926926  UNDI GET MULTICAST ADDRESS
    927927  Op-Code: PXENV_UNDI_GET_MCAST_ADDRESS (0011h)
     
    942942  Status: See the PXENV_STATUS_xxx constants.
    943943  MediaAddr: MAC multicast address.
    944  
    945   @param  SimpleNetworkDevice   Device instance
    946   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    947                                 for option ROM call.
    948                              
    949   @return Return value of PXE option ROM far call. 
     944
     945  @param  SimpleNetworkDevice   Device instance
     946  @param  PxeUndiTable          Point to structure which hold paramter and return value
     947                                for option ROM call.
     948
     949  @return Return value of PXE option ROM far call.
    950950**/
    951951EFI_STATUS
     
    964964
    965965/**
    966   PXE 
     966  PXE
    967967  UNDI GET NIC TYPE
    968968  Op-Code: PXENV_UNDI_GET_NIC_TYPE (0012h)
     
    10141014  structure.
    10151015  Info: Information about the fields in this union can be found
    1016   in the [PnP] and [PCI] specifications   
    1017  
    1018   @param  SimpleNetworkDevice   Device instance
    1019   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1020                                 for option ROM call.
    1021                              
    1022   @return Return value of PXE option ROM far call. 
     1016  in the [PnP] and [PCI] specifications
     1017
     1018  @param  SimpleNetworkDevice   Device instance
     1019  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1020                                for option ROM call.
     1021
     1022  @return Return value of PXE option ROM far call.
    10231023**/
    10241024EFI_STATUS
     
    10371037
    10381038/**
    1039   PXE 
     1039  PXE
    10401040  UNDI GET IFACE INFO
    10411041  Op-Code: PXENV_UNDI_GET_IFACE_INFO (0013h)
     
    10701070  LinkSpeed: Defined in the NDIS 2.0 specification.
    10711071  ServiceFlags: Defined in the NDIS 2.0 specification.
    1072   Reserved: Must be zero.       
    1073  
    1074   @param  SimpleNetworkDevice   Device instance
    1075   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1076                                 for option ROM call.
    1077                              
    1078   @return Return value of PXE option ROM far call. 
     1072  Reserved: Must be zero.
     1073
     1074  @param  SimpleNetworkDevice   Device instance
     1075  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1076                                for option ROM call.
     1077
     1078  @return Return value of PXE option ROM far call.
    10791079**/
    10801080EFI_STATUS
     
    10931093
    10941094/**
    1095   PXE 
     1095  PXE
    10961096  UNDI ISR
    10971097  Op-Code: PXENV_UNDI_ISR (0014h)
     
    11351135  NETWORK INTERFACE level and returns PXENV_UNDI_ISR_OUT_DONE in the FuncFlag.
    11361136  IMPORTANT: It is possible for the protocol driver to be interrupted again while in the
    1137   strategy routine when the UNDI re-enables interrupts.   
    1138  
    1139   @param  SimpleNetworkDevice   Device instance
    1140   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1141                                 for option ROM call.
    1142                              
    1143   @return Return value of PXE option ROM far call. 
     1137  strategy routine when the UNDI re-enables interrupts.
     1138
     1139  @param  SimpleNetworkDevice   Device instance
     1140  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1141                                for option ROM call.
     1142
     1143  @return Return value of PXE option ROM far call.
    11441144**/
    11451145EFI_STATUS
     
    11581158
    11591159/**
    1160   PXE 
     1160  PXE
    11611161  STOP UNDI
    11621162  Op-Code: PXENV_STOP_UNDI (0015h)
     
    11771177  N/A
    11781178  Returned from API service
    1179   Status: See the PXENV_STATUS_xxx constants.     
    1180  
    1181   @param  SimpleNetworkDevice   Device instance
    1182   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1183                                 for option ROM call.
    1184                              
    1185   @return Return value of PXE option ROM far call. 
     1179  Status: See the PXENV_STATUS_xxx constants.
     1180
     1181  @param  SimpleNetworkDevice   Device instance
     1182  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1183                                for option ROM call.
     1184
     1185  @return Return value of PXE option ROM far call.
    11861186**/
    11871187EFI_STATUS
     
    12001200
    12011201/**
    1202   PXE 
     1202  PXE
    12031203  UNDI GET STATE
    12041204  Op-Code: PXENV_UNDI_GET_STATE (0015h)
     
    12321232  Description: This API function will be called at different levels of processing the interrupt. The FuncFlag field in
    12331233  the parameter block indicates the operation to be performed for the call. This field is filled with the
    1234   status of that operation on return.     
    1235  
    1236   @param  SimpleNetworkDevice   Device instance
    1237   @param  PxeUndiTable          Point to structure which hold paramter and return value 
    1238                                 for option ROM call.
    1239                              
    1240   @return Return value of PXE option ROM far call. 
     1234  status of that operation on return.
     1235
     1236  @param  SimpleNetworkDevice   Device instance
     1237  @param  PxeUndiTable          Point to structure which hold paramter and return value
     1238                                for option ROM call.
     1239
     1240  @return Return value of PXE option ROM far call.
    12411241**/
    12421242EFI_STATUS
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/BiosThunk/Snp16Dxe/Snp16Dxe.inf

    r58459 r58466  
    2424  INF_VERSION                          = 0x00010005
    2525  VERSION_STRING                       = 1.0
    26  
     26
    2727  ENTRY_POINT                          = BiosSnp16DriverEntryPoint
    2828
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/BiosThunk/VideoDxe/BiosVideo.c

    r58459 r58466  
    189189      Node = (EFI_DEV_PATH *) RemainingDevicePath;
    190190      //
    191       // Check if RemainingDevicePath is the End of Device Path Node, 
     191      // Check if RemainingDevicePath is the End of Device Path Node,
    192192      // if yes, return EFI_SUCCESS
    193193      //
     
    296296                      &mOriginalPciAttributes
    297297                      );
    298    
     298
    299299    if (EFI_ERROR (Status)) {
    300300      goto Done;
     
    320320    Status = EFI_UNSUPPORTED;
    321321    goto Done;
    322   } 
     322  }
    323323
    324324  REPORT_STATUS_CODE_WITH_DEVICE_PATH (
     
    385385
    386386  if (RemainingDevicePath != NULL) {
    387     if (IsDevicePathEnd (RemainingDevicePath) && 
     387    if (IsDevicePathEnd (RemainingDevicePath) &&
    388388        (FeaturePcdGet (PcdBiosVideoCheckVbeEnable) || FeaturePcdGet (PcdBiosVideoCheckVgaEnable))) {
    389389      //
     
    510510                      );
    511511      ASSERT_EFI_ERROR (Status);
    512      
     512
    513513      //
    514514      // Restore original PCI attributes
     
    669669      AcpiDeviceNode.ADR = ACPI_DISPLAY_ADR (1, 0, 0, 1, 0, ACPI_ADR_DISPLAY_TYPE_VGA, 0, 0);
    670670      SetDevicePathNodeLength (&AcpiDeviceNode.Header, sizeof (ACPI_ADR_DEVICE_PATH));
    671    
     671
    672672      BiosVideoPrivate->GopDevicePath = AppendDevicePathNode (
    673673                                          ParentDevicePath,
     
    677677      BiosVideoPrivate->GopDevicePath = AppendDevicePathNode (ParentDevicePath, RemainingDevicePath);
    678678    }
    679    
     679
    680680    //
    681681    // Creat child handle and device path protocol firstly
     
    817817    if ((BiosVideoPrivate != NULL) && (BiosVideoPrivate->ExitBootServicesEvent != NULL)) {
    818818      gBS->CloseEvent (BiosVideoPrivate->ExitBootServicesEvent);
    819     } 
     819    }
    820820    //
    821821    // Free private data structure
     
    12731273    }
    12741274  }
    1275  
     1275
    12761276  return HasChild;
    12771277}
     
    13451345
    13461346  ZeroMem (&ValidEdidTiming, sizeof (VESA_BIOS_EXTENSIONS_VALID_EDID_TIMING));
    1347        
     1347
    13481348  //
    13491349  // Fill in the VBE related data structures
     
    15091509  PreferMode = 0;
    15101510  ModeNumber = 0;
    1511  
     1511
    15121512  //
    15131513  // ModeNumberPtr may be not 16-byte aligned, so ReadUnaligned16 is used to access the buffer pointed by ModeNumberPtr.
     
    16371637    //
    16381638    if ((BiosVideoPrivate->VbeModeInformationBlock->XResolution > HighestHorizontalResolution) ||
    1639         ((BiosVideoPrivate->VbeModeInformationBlock->XResolution == HighestHorizontalResolution) && 
     1639        ((BiosVideoPrivate->VbeModeInformationBlock->XResolution == HighestHorizontalResolution) &&
    16401640         (BiosVideoPrivate->VbeModeInformationBlock->YResolution > HighestVerticalResolution))) {
    16411641      HighestHorizontalResolution = BiosVideoPrivate->VbeModeInformationBlock->XResolution;
     
    17171717    //
    17181718    ASSERT (CurrentModeData->FrameBufferSize <= (UINTN)(BiosVideoPrivate->VbeInformationBlock->TotalMemory * 64 * 1024));
    1719    
     1719
    17201720    BiosVideoPrivate->ModeData = ModeBuffer;
    17211721  }
     
    20812081    return EFI_UNSUPPORTED;
    20822082  }
    2083  
     2083
    20842084  if (ModeNumber == This->Mode->Mode) {
    20852085    //
    20862086    // Clear screen to black
    2087     //   
     2087    //
    20882088    ZeroMem (&Background, sizeof (EFI_GRAPHICS_OUTPUT_BLT_PIXEL));
    20892089    BiosVideoGraphicsOutputVbeBlt (
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/LegacyBiosDxe/IA32/InterruptTable.S

    r48674 r58466  
    1818
    1919#----------------------------------------------------------------------------
    20 # Procedure:    InterruptRedirectionTemplate: Redirects interrupts 0x68-0x6F 
     20# Procedure:    InterruptRedirectionTemplate: Redirects interrupts 0x68-0x6F
    2121#
    2222# Input:        None
     
    2525#
    2626# Prototype:    VOID
    27 #               InterruptRedirectionTemplate ( 
     27#               InterruptRedirectionTemplate (
    2828#                                VOID
    2929#                                );
     
    3737#               This template must be copied into low memory, and the IDT entries
    3838#               0x68-0x6F must be point to the low memory copy of this code.  Each
    39 #               entry is 4 bytes long, so IDT entries 0x68-0x6F can be easily 
     39#               entry is 4 bytes long, so IDT entries 0x68-0x6F can be easily
    4040#               computed.
    4141#
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/LegacyBiosDxe/IA32/InterruptTable.asm

    r48674 r58466  
    2020
    2121;----------------------------------------------------------------------------
    22 ; Procedure:    InterruptRedirectionTemplate: Redirects interrupts 0x68-0x6F 
     22; Procedure:    InterruptRedirectionTemplate: Redirects interrupts 0x68-0x6F
    2323;
    2424; Input:        None
     
    2727;
    2828; Prototype:    VOID
    29 ;               InterruptRedirectionTemplate ( 
     29;               InterruptRedirectionTemplate (
    3030;                                VOID
    3131;                                );
     
    3939;               This template must be copied into low memory, and the IDT entries
    4040;               0x68-0x6F must be point to the low memory copy of this code.  Each
    41 ;               entry is 4 bytes long, so IDT entries 0x68-0x6F can be easily 
     41;               entry is 4 bytes long, so IDT entries 0x68-0x6F can be easily
    4242;               computed.
    4343;
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/LegacyBiosDxe/Ipf/IpfBootSupport.c

    r58459 r58466  
    249249      //
    250250      // Create a new handle with gEfiCallerIdGuid to be used as the ImageHandle fore the reloaded image
    251       // 
     251      //
    252252      NewImageHandle = NULL;
    253253      Status = gBS->InstallProtocolInterface (
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/LegacyBiosDxe/Ipf/IpfThunk.i

    • Property svn:eol-style set to native
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/LegacyBiosDxe/LegacyBbs.c

    r48674 r58466  
    3232/**
    3333  Checks the state of the floppy and if media is inserted.
    34  
     34
    3535  This routine checks the state of the floppy and if media is inserted.
    3636  There are 3 cases:
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/LegacyBiosDxe/LegacyBios.c

    r58459 r58466  
    270270      //
    271271      // Bugbug: need to figure out whether C/D/E/F segment should be marked as reserved memory.
    272       // 
     272      //
    273273      DEBUG ((DEBUG_ERROR, "Failed to allocate the C/D/E/F segment Status = %r", Status));
    274274    }
     
    414414  NewMask = 0xFFFF;
    415415  Private->Legacy8259->SetMask(Private->Legacy8259, &NewMask, NULL, NULL, NULL);
    416  
     416
    417417  //
    418418  // Call into Legacy16 code to do an INIT
     
    436436  //
    437437  Private->Legacy8259->SetMask(Private->Legacy8259, &OldMask, NULL, NULL, NULL);
    438  
     438
    439439  if (Regs.X.AX != 0) {
    440440    return EFI_DEVICE_ERROR;
     
    652652
    653653  PciInterfaceVersion = 0;
    654  
     654
    655655  Reg.X.AX = 0xB101;
    656656  Reg.E.EDI = 0;
     
    692692  EFI_STATUS                  Status;
    693693  SMBIOS_TABLE_ENTRY_POINT    *EntryPointStructure;
    694  
     694
    695695  //
    696696  // Get SMBIOS table from EFI configuration table
     
    703703    return;
    704704  }
    705  
     705
    706706  EntryPointStructure = (SMBIOS_TABLE_ENTRY_POINT *) mRuntimeSmbiosEntryPoint;
    707707
     
    727727    DEBUG ((EFI_D_INFO, "Allocate memory for Smbios Entry Point Structure\n"));
    728728  }
    729  
    730   if ((mStructureTableAddress != 0) && 
     729
     730  if ((mStructureTableAddress != 0) &&
    731731      (mStructureTablePages < (UINTN) EFI_SIZE_TO_PAGES (EntryPointStructure->TableLength))) {
    732732    //
     
    738738    DEBUG ((EFI_D_INFO, "Original size is not enough. Re-allocate the memory.\n"));
    739739  }
    740  
     740
    741741  if (mStructureTableAddress == 0) {
    742742    //
     
    754754    if (EFI_ERROR (Status)) {
    755755      gBS->FreePages (
    756         mReserveSmbiosEntryPoint, 
     756        mReserveSmbiosEntryPoint,
    757757        EFI_SIZE_TO_PAGES ((UINTN) (EntryPointStructure->EntryPointLength))
    758758        );
     
    821821    return EFI_SECURITY_VIOLATION;
    822822  }
    823  
     823
    824824  if (SecureBoot != NULL) {
    825825    FreePool (SecureBoot);
     
    10201020  //
    10211021  MemorySize = PcdGet32 (PcdLowPmmMemorySize);
    1022   ASSERT ((MemorySize & 0xFFF) == 0); 
     1022  ASSERT ((MemorySize & 0xFFF) == 0);
    10231023  Status = AllocateLegacyMemory (
    10241024             AllocateMaxAddress,
     
    10601060  //
    10611061  // Allocate high PMM Memory under 16 MB
    1062   //   
     1062  //
    10631063  Status = AllocateLegacyMemory (
    10641064             AllocateMaxAddress,
     
    10701070    //
    10711071    // If it fails, allocate high PMM Memory under 4GB
    1072     //   
     1072    //
    10731073    Status = AllocateLegacyMemory (
    10741074               AllocateMaxAddress,
     
    10761076               EFI_SIZE_TO_PAGES (MemorySize),
    10771077               &MemoryAddress
    1078                );   
     1078               );
    10791079  }
    10801080  if (!EFI_ERROR (Status)) {
    10811081    EfiToLegacy16InitTable->HiPmmMemory            = (UINT32) (EFI_PHYSICAL_ADDRESS) (UINTN) MemoryAddress;
    10821082    EfiToLegacy16InitTable->HiPmmMemorySizeInBytes = MemorySize;
    1083   } 
     1083  }
    10841084
    10851085  //
     
    11151115  //
    11161116  Private->ThunkSeg = (UINT16) (EFI_SEGMENT (IntRedirCode));
    1117  
     1117
    11181118  //
    11191119  // Allocate reserved memory for SMBIOS table used in legacy boot if SMBIOS table exists
     
    11321132                  &InstallSmbiosEvent
    11331133                  );
    1134   ASSERT_EFI_ERROR (Status); 
     1134  ASSERT_EFI_ERROR (Status);
    11351135
    11361136  //
     
    11451145                  );
    11461146  Private->Csm16PciInterfaceVersion = GetPciInterfaceVersion (Private);
    1147  
    1148   DEBUG ((EFI_D_INFO, "CSM16 PCI BIOS Interface Version: %02x.%02x\n", 
    1149           (UINT8) (Private->Csm16PciInterfaceVersion >> 8), 
     1147
     1148  DEBUG ((EFI_D_INFO, "CSM16 PCI BIOS Interface Version: %02x.%02x\n",
     1149          (UINT8) (Private->Csm16PciInterfaceVersion >> 8),
    11501150          (UINT8) Private->Csm16PciInterfaceVersion
    11511151        ));
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/LegacyBiosDxe/LegacyBiosInterface.h

    r58459 r58466  
    9898
    9999//
    100 // When we call CSM16 functions, some CSM16 use es:[offset + 0xabcd] to get data passed from CSM32, 
    101 // offset + 0xabcd could overflow which exceeds 0xFFFF which is invalid in real mode. 
    102 // So this will keep offset as small as possible to avoid offset overflow in real mode. 
     100// When we call CSM16 functions, some CSM16 use es:[offset + 0xabcd] to get data passed from CSM32,
     101// offset + 0xabcd could overflow which exceeds 0xFFFF which is invalid in real mode.
     102// So this will keep offset as small as possible to avoid offset overflow in real mode.
    103103//
    104104#define NORMALIZE_EFI_SEGMENT(_Adr)      (UINT16) (((UINTN) (_Adr)) >> 4)
     
    539539// Timer 0, Read/Write LSB then MSB, Square wave output, binary count use.
    540540//
    541 #define TIMER0_CONTROL_WORD         0x36     
     541#define TIMER0_CONTROL_WORD         0x36
    542542
    543543#define LEGACY_BIOS_INSTANCE_SIGNATURE  SIGNATURE_32 ('L', 'B', 'I', 'T')
     
    551551
    552552  //
    553   // CPU Architectural Protocol 
     553  // CPU Architectural Protocol
    554554  //
    555555  EFI_CPU_ARCH_PROTOCOL             *Cpu;
    556556
    557557  //
    558   // Timer Architectural Protocol 
     558  // Timer Architectural Protocol
    559559  //
    560560  EFI_TIMER_ARCH_PROTOCOL           *Timer;
    561   BOOLEAN                           TimerUses8254; 
    562  
     561  BOOLEAN                           TimerUses8254;
     562
    563563  //
    564564  // Protocol to Lock and Unlock 0xc0000 - 0xfffff
     
    572572  //
    573573  EFI_LEGACY_8259_PROTOCOL          *Legacy8259;
    574  
     574
    575575  //
    576576  // PCI Interrupt PIRQ control
     
    668668  // Indicate that whether GenericLegacyBoot is entered or not
    669669  //
    670   BOOLEAN                           LegacyBootEntered;                             
     670  BOOLEAN                           LegacyBootEntered;
    671671
    672672  //
     
    13441344/**
    13451345  Checks the state of the floppy and if media is inserted.
    1346  
     1346
    13471347  This routine checks the state of the floppy and if media is inserted.
    13481348  There are 3 cases:
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/LegacyBiosDxe/LegacyBootSupport.c

    r58459 r58466  
    792792{
    793793  SMBIOS_TABLE_ENTRY_POINT    *EntryPointStructure;
    794  
    795   if ((mRuntimeSmbiosEntryPoint == NULL) || 
    796       (mReserveSmbiosEntryPoint == 0) || 
     794
     795  if ((mRuntimeSmbiosEntryPoint == NULL) ||
     796      (mReserveSmbiosEntryPoint == 0) ||
    797797      (mStructureTableAddress == 0)) {
    798798    return;
    799799  }
    800  
     800
    801801  EntryPointStructure = (SMBIOS_TABLE_ENTRY_POINT *) mRuntimeSmbiosEntryPoint;
    802  
     802
    803803  //
    804804  // Copy SMBIOS Entry Point Structure
     
    809809    EntryPointStructure->EntryPointLength
    810810  );
    811  
     811
    812812  //
    813813  // Copy SMBIOS Structure Table into EfiReservedMemoryType memory
     
    818818    EntryPointStructure->TableLength
    819819  );
    820  
     820
    821821  //
    822822  // Update TableAddress in Entry Point Structure
     
    824824  EntryPointStructure = (SMBIOS_TABLE_ENTRY_POINT *)(UINTN) mReserveSmbiosEntryPoint;
    825825  EntryPointStructure->TableAddress = (UINT32)(UINTN) mStructureTableAddress;
    826  
     826
    827827  //
    828828  // Fixup checksums in the Entry Point Structure
     
    831831  EntryPointStructure->EntryPointStructureChecksum = 0;
    832832
    833   EntryPointStructure->IntermediateChecksum = 
     833  EntryPointStructure->IntermediateChecksum =
    834834    CalculateCheckSum8 (
    835       (UINT8 *) EntryPointStructure + OFFSET_OF (SMBIOS_TABLE_ENTRY_POINT, IntermediateAnchorString), 
     835      (UINT8 *) EntryPointStructure + OFFSET_OF (SMBIOS_TABLE_ENTRY_POINT, IntermediateAnchorString),
    836836      EntryPointStructure->EntryPointLength - OFFSET_OF (SMBIOS_TABLE_ENTRY_POINT, IntermediateAnchorString)
    837837      );
     
    899899  EfiToLegacy16BootTable->MajorVersion = EFI_TO_LEGACY_MAJOR_VERSION;
    900900  EfiToLegacy16BootTable->MinorVersion = EFI_TO_LEGACY_MINOR_VERSION;
    901  
     901
    902902  //
    903903  // If booting to a legacy OS then force HDD drives to the appropriate
     
    917917    if (!EFI_ERROR (Status)) {
    918918      IdeController = HandleBuffer[0];
    919     }   
     919    }
    920920  }
    921921  //
     
    12721272    //
    12731273    Private->Timer->SetTimerPeriod (Private->Timer, 0);
    1274    
     1274
    12751275    //
    12761276    // Save and disable interrupt of debug timer
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/LegacyBiosDxe/LegacyIde.c

    r58459 r58466  
    7777                                          );
    7878  if (!EFI_ERROR (Status)) {
    79     IdeController = HandleBuffer[0];   
     79    IdeController = HandleBuffer[0];
    8080    //
    8181    // Force IDE drive spin up!
     
    280280  //
    281281  Status = gBS->HandleProtocol (
    282                   IdeController, 
    283                   &gEfiPciIoProtocolGuid, 
     282                  IdeController,
     283                  &gEfiPciIoProtocolGuid,
    284284                  (VOID **)&PciIo
    285285                  );
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/LegacyBiosDxe/LegacyPci.c

    r58459 r58466  
    151151  IN  EFI_HANDLE                                  PciHandle,
    152152  IN  UINT32                                      ShadowAddress,
    153   IN  UINT32                                      ShadowedSize, 
     153  IN  UINT32                                      ShadowedSize,
    154154  IN  UINT8                                       DiskStart,
    155155  IN  UINT8                                       DiskEnd
     
    259259
    260260/**
    261   Find the PC-AT ROM Image in the raw PCI Option ROM. Also return the 
     261  Find the PC-AT ROM Image in the raw PCI Option ROM. Also return the
    262262  related information from the header.
    263263
     
    322322      break;
    323323    }
    324    
     324
    325325    if (Pcir->CodeType == PCI_CODE_TYPE_PCAT_IMAGE) {
    326326      Match = FALSE;
     
    385385      }
    386386    }
    387    
     387
    388388    if ((Pcir->Indicator & 0x80) == 0x80) {
    389389      break;
     
    416416
    417417  if (OpRomRevision != NULL) {
    418     // 
     418    //
    419419    // Optional return PCI Data Structure revision
    420420    //
     
    816816    Regs.X.BX = (UINT16) 0x1;
    817817    //
    818     // 16-byte boundary alignment requirement according to 
     818    // 16-byte boundary alignment requirement according to
    819819    // PCI IRQ Routing Table Specification
    820820    //
     
    833833      DEBUG ((EFI_D_ERROR, "PIRQ table length insufficient - %x\n", PirqTableSize));
    834834    } else {
    835       DEBUG ((EFI_D_INFO, "PIRQ table in legacy region - %x\n", Private->Legacy16Table->IrqRoutingTablePointer));   
     835      DEBUG ((EFI_D_INFO, "PIRQ table in legacy region - %x\n", Private->Legacy16Table->IrqRoutingTablePointer));
    836836      Private->Legacy16Table->IrqRoutingTableLength = (UINT32)PirqTableSize;
    837837      CopyMem (
     
    15961596                                          &HandleCount,
    15971597                                          NULL
    1598                                           ); 
     1598                                          );
    15991599  if (EFI_ERROR (Status)) {
    16001600    return EFI_UNSUPPORTED;
    16011601  }
    1602  
     1602
    16031603  VgaHandle = HandleBuffer[0];
    16041604
     
    17001700                 &Pci
    17011701                 );
    1702    
    1703     //
    1704     // Only one Video OPROM can be given control in BIOS phase. If there are multiple Video devices, 
    1705     // one will work in legacy mode (OPROM will be given control) and 
     1702
     1703    //
     1704    // Only one Video OPROM can be given control in BIOS phase. If there are multiple Video devices,
     1705    // one will work in legacy mode (OPROM will be given control) and
    17061706    // other Video devices will work in native mode (OS driver will handle these devices).
    1707     // 
    1708     if (IS_PCI_DISPLAY (&Pci) && Index != 0) {   
     1707    //
     1708    if (IS_PCI_DISPLAY (&Pci) && Index != 0) {
    17091709      continue;
    17101710    }
     
    17161716      continue;
    17171717    }
    1718    
     1718
    17191719    //
    17201720    // If legacy VBIOS Oprom has not been dispatched before, install legacy VBIOS here.
    17211721    //
    1722     if (IS_PCI_DISPLAY (&Pci) && Index == 0) {   
     1722    if (IS_PCI_DISPLAY (&Pci) && Index == 0) {
    17231723      Status = LegacyBiosInstallVgaRom (Private);
    17241724      //
     
    21052105    return Status;
    21062106  }
    2107  
     2107
    21082108  for (Index = 0; Index < EntryCount; Index++) {
    21092109    if ((OpenInfoBuffer[Index].Attributes & EFI_OPEN_PROTOCOL_BY_DRIVER) != 0) {
     
    21242124    }
    21252125  }
    2126  
     2126
    21272127  //
    21282128  // Kick off the native EFI driver
     
    23152315                    &PhysicalAddress
    23162316                    );
    2317        
     2317
    23182318    if (EFI_ERROR (Status)) {
    23192319      DEBUG ((EFI_D_ERROR, "return LegacyBiosInstallRom(%d): EFI_OUT_OF_RESOURCES (no more space for OpROM)\n", __LINE__));
     
    23782378                           &Granularity
    23792379                           );
    2380    
     2380
    23812381  DEBUG ((EFI_D_INFO, " Shadowing OpROM init/runtime/isize = %x/%x/%x\n", InitAddress, RuntimeAddress, ImageSize));
    23822382
     
    24522452  gRT->GetTime (&BootTime, NULL);
    24532453  LocalTime = BootTime.Hour * 3600 + BootTime.Minute * 60 + BootTime.Second;
    2454  
     2454
    24552455  //
    24562456  // Multiply result by 18.2 for number of ticks since midnight.
     
    24602460  BdaPtr    = (UINT32 *) ((UINTN) 0x46C);
    24612461  *BdaPtr   = LocalTime;
    2462  
     2462
    24632463  //
    24642464  // Pass in handoff data
     
    24672467  ZeroMem (&Regs, sizeof (Regs));
    24682468  if (PciHandle != NULL) {
    2469  
     2469
    24702470    Status = gBS->HandleProtocol (
    24712471                    PciHandle,
     
    24742474                    );
    24752475    ASSERT_EFI_ERROR (Status);
    2476  
     2476
    24772477    //
    24782478    // Enable command register.
     
    24842484                               NULL
    24852485                               );
    2486  
     2486
    24872487    PciIo->GetLocation (
    24882488             PciIo,
     
    24942494    DEBUG ((EFI_D_INFO, "Shadowing OpROM on the PCI device %x/%x/%x\n", Bus, Device, Function));
    24952495  }
    2496  
     2496
    24972497  mIgnoreBbsUpdateFlag  = FALSE;
    24982498  Regs.X.AX             = Legacy16DispatchOprom;
    2499  
     2499
    25002500  //
    25012501  // Generate DispatchOpRomTable data
     
    25292529    Regs.X.BX = 0;
    25302530  }
    2531  
     2531
    25322532  if (Private->IntThunk->DispatchOpromTable.NumberBbsEntries != (UINT8) Private->IntThunk->EfiToLegacy16BootTable.NumberBbsEntries) {
    25332533    Private->IntThunk->EfiToLegacy16BootTable.NumberBbsEntries  = (UINT8) Private->IntThunk->DispatchOpromTable.NumberBbsEntries;
     
    25962596
    25972597  LocalDiskEnd = (UINT8) ((*(UINT8 *) ((UINTN) 0x475)) + 0x80);
    2598  
     2598
    25992599  //
    26002600  // Allow platform to perform any required actions after the
     
    26652665
    26662666  Status = EFI_SUCCESS;
    2667    
     2667
    26682668Done:
    26692669  if (PhysicalAddress != 0) {
     
    28022802  if ((PciHandle != NULL) && (RomImage == NULL)) {
    28032803    //
    2804     // If PciHandle has OpRom to Execute 
     2804    // If PciHandle has OpRom to Execute
    28052805    // and OpRom are all associated with Hardware
    28062806    //
     
    29482948      return EFI_UNSUPPORTED;
    29492949    }
    2950    
     2950
    29512951    Pcir = (PCI_3_0_DATA_STRUCTURE *)
    29522952           ((UINT8 *) LocalRomImage + ((PCI_EXPANSION_ROM_HEADER *) LocalRomImage)->PcirOffset);
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/LegacyBiosDxe/Thunk.c

    r48674 r58466  
    7474  //
    7575  VectorBase              = 0;
    76  
     76
    7777  return InternalLegacyBiosFarCall (
    7878           This,
     
    128128
    129129/**
    130   Provide NULL interrupt handler which is used to check 
     130  Provide NULL interrupt handler which is used to check
    131131  if there is more than one HW interrupt registers with the CPU AP.
    132132
     
    215215  //
    216216  Private->Timer->SetTimerPeriod (Private->Timer, 0);
    217  
     217
    218218  //
    219219  // Save and disable interrupt of debug timer
     
    228228  //
    229229  // Check to see if there is more than one HW interrupt registers with the CPU AP.
    230   // If there is, then ASSERT() since that is not compatible with the CSM because 
    231   // interupts other than the Timer interrupt that was disabled above can not be 
     230  // If there is, then ASSERT() since that is not compatible with the CSM because
     231  // interupts other than the Timer interrupt that was disabled above can not be
    232232  // handled properly from real mode.
    233233  //
     
    235235    UINTN  Vector;
    236236    UINTN  Count;
    237    
     237
    238238    for (Vector = 0x20, Count = 0; Vector < 0x100; Vector++) {
    239239      Status = Private->Cpu->RegisterInterruptHandler (Private->Cpu, Vector, LegacyBiosNullInterruptHandler);
     
    252252
    253253  //
    254   // If the Timer AP has enabled the 8254 timer IRQ and the current 8254 timer 
    255   // period is less than the CSM required rate of 54.9254, then force the 8254 
     254  // If the Timer AP has enabled the 8254 timer IRQ and the current 8254 timer
     255  // period is less than the CSM required rate of 54.9254, then force the 8254
    256256  // PIT counter to 0, which is the CSM required rate of 54.9254 ms
    257257  //
     
    259259    SetPitCount (0);
    260260  }
    261  
     261
    262262  if (Stack != NULL && StackSize != 0) {
    263263    //
     
    324324  //
    325325  gBS->RestoreTPL (OriginalTpl);
    326  
     326
    327327  //
    328328  // Restore interrupt of debug timer
     
    379379  Status = Private->Legacy8259->GetVector (Private->Legacy8259, Efi8259Irq0, &TimerVector);
    380380  ASSERT_EFI_ERROR (Status);
    381  
     381
    382382  //
    383383  // Check to see if the Timer AP has hooked the IRQ0 from the 8254 PIT
    384   // 
     384  //
    385385  Status = Private->Cpu->RegisterInterruptHandler (
    386                            Private->Cpu, 
    387                            TimerVector, 
     386                           Private->Cpu,
     387                           TimerVector,
    388388                           LegacyBiosNullInterruptHandler
    389389                           );
    390390  if (Status == EFI_SUCCESS) {
    391391    //
    392     // If the Timer AP has not enabled the 8254 timer IRQ, then force the 8254 PIT 
     392    // If the Timer AP has not enabled the 8254 timer IRQ, then force the 8254 PIT
    393393    // counter to 0, which is the CSM required rate of 54.9254 ms
    394394    //
    395395    Private->Cpu->RegisterInterruptHandler (
    396                     Private->Cpu, 
    397                     TimerVector, 
     396                    Private->Cpu,
     397                    TimerVector,
    398398                    NULL
    399399                    );
    400400    SetPitCount (0);
    401    
     401
    402402    //
    403403    // Save status that the Timer AP is not using the 8254 PIT
     
    415415    ASSERT (FALSE);
    416416  }
    417  
     417
    418418  return EFI_SUCCESS;
    419419}
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Csm/LegacyBiosDxe/X64/InterruptTable.asm

    r48674 r58466  
    1818
    1919;----------------------------------------------------------------------------
    20 ; Procedure:    InterruptRedirectionTemplate: Redirects interrupts 0x68-0x6F 
     20; Procedure:    InterruptRedirectionTemplate: Redirects interrupts 0x68-0x6F
    2121;
    2222; Input:        None
     
    2525;
    2626; Prototype:    VOID
    27 ;               InterruptRedirectionTemplate ( 
     27;               InterruptRedirectionTemplate (
    2828;                                VOID
    2929;                                );
     
    3737;               This template must be copied into low memory, and the IDT entries
    3838;               0x68-0x6F must be point to the low memory copy of this code.  Each
    39 ;               entry is 4 bytes long, so IDT entries 0x68-0x6F can be easily 
     39;               entry is 4 bytes long, so IDT entries 0x68-0x6F can be easily
    4040;               computed.
    4141;
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Guid/AcpiVariableCompatibility.h

    r48674 r58466  
    6363  // S3 Debug extension
    6464  //
    65   EFI_PHYSICAL_ADDRESS  S3DebugBufferAddress; 
    66   EFI_PHYSICAL_ADDRESS  S3ResumeNvsEntryPoint;   
     65  EFI_PHYSICAL_ADDRESS  S3DebugBufferAddress;
     66  EFI_PHYSICAL_ADDRESS  S3ResumeNvsEntryPoint;
    6767} ACPI_VARIABLE_SET_COMPATIBILITY;
    6868
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Guid/BdsHii.h

    r48674 r58466  
    11/** @file
    22  GUIDs used as HII FormSet and HII Package list GUID in BdsDxe driver.
    3  
     3
    44Copyright (c) 2011, Intel Corporation. All rights reserved.<BR>
    5 This program and the accompanying materials are licensed and made available under 
    6 the terms and conditions of the BSD License that accompanies this distribution. 
     5This program and the accompanying materials are licensed and made available under
     6the terms and conditions of the BSD License that accompanies this distribution.
    77The full text of the license may be found at
    8 http://opensource.org/licenses/bsd-license.php.                                           
     8http://opensource.org/licenses/bsd-license.php.
    99
    10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
     10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1111WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Guid/BdsLibHii.h

    r48674 r58466  
    11/** @file
    22  GUID used as HII Package list GUID in GenericBdsLib module.
    3  
     3
    44Copyright (c) 2011, Intel Corporation. All rights reserved.<BR>
    5 This program and the accompanying materials are licensed and made available under 
    6 the terms and conditions of the BSD License that accompanies this distribution. 
     5This program and the accompanying materials are licensed and made available under
     6the terms and conditions of the BSD License that accompanies this distribution.
    77The full text of the license may be found at
    8 http://opensource.org/licenses/bsd-license.php.                                           
     8http://opensource.org/licenses/bsd-license.php.
    99
    10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
     10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1111WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Guid/BlockIoVendor.h

    r48674 r58466  
    33
    44Copyright (c) 2011, Intel Corporation. All rights reserved.<BR>
    5 This program and the accompanying materials are licensed and made available under 
    6 the terms and conditions of the BSD License that accompanies this distribution. 
     5This program and the accompanying materials are licensed and made available under
     6the terms and conditions of the BSD License that accompanies this distribution.
    77The full text of the license may be found at
    8 http://opensource.org/licenses/bsd-license.php.                                         
    9    
    10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
     8http://opensource.org/licenses/bsd-license.php.
     9
     10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1111WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Guid/CapsuleDataFile.h

    r48674 r58466  
    33
    44Copyright (c) 2011, Intel Corporation. All rights reserved.<BR>
    5 This program and the accompanying materials are licensed and made available under 
    6 the terms and conditions of the BSD License that accompanies this distribution. 
     5This program and the accompanying materials are licensed and made available under
     6the terms and conditions of the BSD License that accompanies this distribution.
    77The full text of the license may be found at
    8 http://opensource.org/licenses/bsd-license.php.                                         
    9    
    10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
     8http://opensource.org/licenses/bsd-license.php.
     9
     10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1111WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Guid/DataHubStatusCodeRecord.h

    r48674 r58466  
    11/** @file
    22  GUID used to identify Data Hub records logged by Status Code Protocol.
    3  
     3
    44Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
    5 This program and the accompanying materials are licensed and made available under 
    6 the terms and conditions of the BSD License that accompanies this distribution. 
     5This program and the accompanying materials are licensed and made available under
     6the terms and conditions of the BSD License that accompanies this distribution.
    77The full text of the license may be found at
    8 http://opensource.org/licenses/bsd-license.php.                                         
    9    
    10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
    11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             
     8http://opensource.org/licenses/bsd-license.php.
     9
     10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     11WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
    1313**/
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Guid/HdBootVariable.h

    r48674 r58466  
    11/** @file
    22  GUID used as EFI Variable for the device path of Boot file on HardDevice.
    3  
     3
    44Copyright (c) 2011, Intel Corporation. All rights reserved.<BR>
    5 This program and the accompanying materials are licensed and made available under 
    6 the terms and conditions of the BSD License that accompanies this distribution. 
     5This program and the accompanying materials are licensed and made available under
     6the terms and conditions of the BSD License that accompanies this distribution.
    77The full text of the license may be found at
    8 http://opensource.org/licenses/bsd-license.php.                                           
     8http://opensource.org/licenses/bsd-license.php.
    99
    10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
     10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1111WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Guid/IntelFrameworkModulePkgTokenSpace.h

    r48674 r58466  
    11/** @file
    2   GUID for IntelFrameworkModulePkg PCD Token Space 
     2  GUID for IntelFrameworkModulePkg PCD Token Space
    33
    44Copyright (c) 2009 - 2010, Intel Corporation. All rights reserved.<BR>
    5 This program and the accompanying materials are licensed and made available under 
    6 the terms and conditions of the BSD License that accompanies this distribution. 
     5This program and the accompanying materials are licensed and made available under
     6the terms and conditions of the BSD License that accompanies this distribution.
    77The full text of the license may be found at
    8 http://opensource.org/licenses/bsd-license.php.                                         
    9    
    10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
     8http://opensource.org/licenses/bsd-license.php.
     9
     10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1111WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212**/
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Guid/LastEnumLang.h

    r48674 r58466  
    11/** @file
    22  GUID used as EFI variable to store platform language at last time enumeration.
    3  
     3
    44Copyright (c) 2011, Intel Corporation. All rights reserved.<BR>
    5 This program and the accompanying materials are licensed and made available under 
    6 the terms and conditions of the BSD License that accompanies this distribution. 
     5This program and the accompanying materials are licensed and made available under
     6the terms and conditions of the BSD License that accompanies this distribution.
    77The full text of the license may be found at
    8 http://opensource.org/licenses/bsd-license.php.                                           
     8http://opensource.org/licenses/bsd-license.php.
    99
    10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
     10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1111WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
     
    1717
    1818///
    19 /// This GUID is used for Set/Get platform language into/from variable at last time enumeration 
     19/// This GUID is used for Set/Get platform language into/from variable at last time enumeration
    2020/// to ensure the enumeration will only execute once.
    2121///
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Guid/LegacyBios.h

    r48674 r58466  
    11/** @file
    22  Defines a Tag GUID used to mark a UEFI legacy BIOS thunk driver based
    3   on legacy BIOS services and legacy option ROM. This Tag GUID must be installed on 
    4   the ImageHandle of any module that follows the EFI Driver Model and uses 
     3  on legacy BIOS services and legacy option ROM. This Tag GUID must be installed on
     4  the ImageHandle of any module that follows the EFI Driver Model and uses
    55  the Int86() or FarCall() services of the Legacy Bios Protocol to produce
    66  a standard UEFI I/O Protocol.
     
    2323
    2424///
    25 /// The Global ID for the Legacy BIOS GUID that must be installed onto the ImageHandle 
    26 /// of any module follows the EFI Driver Model and uses the Int86() or FarCall() 
     25/// The Global ID for the Legacy BIOS GUID that must be installed onto the ImageHandle
     26/// of any module follows the EFI Driver Model and uses the Int86() or FarCall()
    2727/// services of the Legacy BIOS Protocol to produce a standard UEFI I/O Protocol.
    2828///
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Guid/LegacyDevOrder.h

    r48674 r58466  
    44
    55Copyright (c) 2011, Intel Corporation. All rights reserved.<BR>
    6 This program and the accompanying materials are licensed and made available under 
    7 the terms and conditions of the BSD License that accompanies this distribution. 
     6This program and the accompanying materials are licensed and made available under
     7the terms and conditions of the BSD License that accompanies this distribution.
    88The full text of the license may be found at
    9 http://opensource.org/licenses/bsd-license.php.                                         
    10    
    11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
     9http://opensource.org/licenses/bsd-license.php.
     10
     11THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1212WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1313
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Guid/TianoDecompress.h

    r48674 r58466  
    11/** @file
    22  Tiano Custom decompress Guid definition.
    3  
     3
    44Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
    5 This program and the accompanying materials are licensed and made available under 
    6 the terms and conditions of the BSD License that accompanies this distribution. 
     5This program and the accompanying materials are licensed and made available under
     6the terms and conditions of the BSD License that accompanies this distribution.
    77The full text of the license may be found at
    8 http://opensource.org/licenses/bsd-license.php.                                         
    9    
    10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
     8http://opensource.org/licenses/bsd-license.php.
     9
     10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1111WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
     
    1717
    1818///
    19 /// The Global ID used to identify a section of an FFS file of type 
    20 /// EFI_SECTION_GUID_DEFINED, whose contents have been compressed using 
     19/// The Global ID used to identify a section of an FFS file of type
     20/// EFI_SECTION_GUID_DEFINED, whose contents have been compressed using
    2121/// Tiano Custom compression.
    2222///
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Library/GenericBdsLib.h

    r58459 r58466  
    66
    77Copyright (c) 2004 - 2013, Intel Corporation. All rights reserved.<BR>
    8 This program and the accompanying materials are licensed and made available under 
    9 the terms and conditions of the BSD License that accompanies this distribution. 
     8This program and the accompanying materials are licensed and made available under
     9the terms and conditions of the BSD License that accompanies this distribution.
    1010The full text of the license may be found at
    11 http://opensource.org/licenses/bsd-license.php.                                         
    12    
    13 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
     11http://opensource.org/licenses/bsd-license.php.
     12
     13THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1414WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1515
     
    135135/**
    136136  This function will enumerate all possible boot devices in the system, and
    137   automatically create boot options for Network, Shell, Removable BlockIo, 
    138   and Non-BlockIo Simplefile devices. 
    139  
     137  automatically create boot options for Network, Shell, Removable BlockIo,
     138  and Non-BlockIo Simplefile devices.
     139
    140140  BDS separates EFI boot options into six types:
    141   1. Network - The boot option points to the SimpleNetworkProtocol device. 
     141  1. Network - The boot option points to the SimpleNetworkProtocol device.
    142142               Bds will try to automatically create this type of boot option during enumeration.
    143   2. Shell   - The boot option points to internal flash shell. 
     143  2. Shell   - The boot option points to internal flash shell.
    144144               Bds will try to automatically create this type of boot option during enumeration.
    145145  3. Removable BlockIo      - The boot option points to a removable media
     
    147147                              These devices should contain a *removable* blockIo
    148148                              protocol in their device handle.
    149                               Bds will try to automatically create this type boot option 
     149                              Bds will try to automatically create this type boot option
    150150                              when enumerate.
    151   4. Fixed BlockIo          - The boot option points to a Fixed blockIo device, 
     151  4. Fixed BlockIo          - The boot option points to a Fixed blockIo device,
    152152                              such as a hard disk.
    153153                              These devices should contain a *fixed* blockIo
    154154                              protocol in their device handle.
    155155                              BDS will skip fixed blockIo devices, and not
    156                               automatically create boot option for them. But BDS 
    157                               will help to delete those fixed blockIo boot options, 
     156                              automatically create boot option for them. But BDS
     157                              will help to delete those fixed blockIo boot options,
    158158                              whose description rules conflict with other auto-created
    159159                              boot options.
    160   5. Non-BlockIo Simplefile - The boot option points to a device whose handle 
     160  5. Non-BlockIo Simplefile - The boot option points to a device whose handle
    161161                              has SimpleFileSystem Protocol, but has no blockio
    162162                              protocol. These devices do not offer blockIo
    163                               protocol, but BDS still can get the 
     163                              protocol, but BDS still can get the
    164164                              \EFI\BOOT\boot{machinename}.EFI by SimpleFileSystem
    165165                              Protocol.
    166   6. File    - The boot option points to a file. These boot options are usually 
     166  6. File    - The boot option points to a file. These boot options are usually
    167167               created by the user, either manually or with an OS loader. BDS will not delete or modify
    168                these boot options.       
    169    
     168               these boot options.
     169
    170170  This function will enumerate all possible boot devices in the system, and
    171   automatically create boot options for Network, Shell, Removable BlockIo, 
     171  automatically create boot options for Network, Shell, Removable BlockIo,
    172172  and Non-BlockIo Simplefile devices.
    173173  It will excute once every boot.
    174  
     174
    175175  @param  BdsBootOptionList      The header of the linked list that indexed all
    176176                                 current boot options.
    177177
    178   @retval EFI_SUCCESS            Finished all the boot device enumerations and 
     178  @retval EFI_SUCCESS            Finished all the boot device enumerations and
    179179                                 created the boot option based on the boot device.
    180180
    181   @retval EFI_OUT_OF_RESOURCES   Failed to enumerate the boot device and create 
     181  @retval EFI_OUT_OF_RESOURCES   Failed to enumerate the boot device and create
    182182                                 the boot option list.
    183183**/
     
    191191  Build the boot option with the handle parsed in.
    192192
    193   @param  Handle                 The handle representing the device path for which 
     193  @param  Handle                 The handle representing the device path for which
    194194                                 to create a boot option.
    195195  @param  BdsBootOptionList      The header of the link list that indexed all
     
    284284  @param  VariableSize          Returns the size of the EFI variable that was read.
    285285
    286   @return                       Dynamically allocated memory that contains a copy 
    287                                 of the EFI variable. The caller is responsible for 
     286  @return                       Dynamically allocated memory that contains a copy
     287                                of the EFI variable. The caller is responsible for
    288288                                freeing the buffer.
    289289  @retval NULL                  The variable was not read.
     
    367367//
    368368/**
    369   This function connects all system drivers with the corresponding controllers. 
     369  This function connects all system drivers with the corresponding controllers.
    370370
    371371**/
     
    408408
    409409/**
    410   This function will connect all current system handles recursively.     
    411   gBS->ConnectController() service is invoked for each handle exist in system handler buffer. 
     410  This function will connect all current system handles recursively.
     411  gBS->ConnectController() service is invoked for each handle exist in system handler buffer.
    412412  If the handle is bus type handler, all childrens also will be connected recursively  by gBS->ConnectController().
    413  
     413
    414414  @retval EFI_SUCCESS           All handles and child handles have been
    415                                 connected. 
     415                                connected.
    416416  @retval EFI_STATUS            Return the status of gBS->LocateHandleBuffer().
    417417**/
     
    423423
    424424/**
    425   This function will disconnect all current system handles.     
    426   gBS->DisconnectController() is invoked for each handle exists in system handle buffer. 
     425  This function will disconnect all current system handles.
     426  gBS->DisconnectController() is invoked for each handle exists in system handle buffer.
    427427  If handle is a bus type handle, all childrens also are disconnected recursively by  gBS->DisconnectController().
    428  
     428
    429429  @retval EFI_SUCCESS           All handles have been disconnected.
    430430  @retval EFI_STATUS            Error status returned by of gBS->LocateHandleBuffer().
     
    536536//
    537537/**
    538   Delete the instance in Multi that overlaps with Single. 
     538  Delete the instance in Multi that overlaps with Single.
    539539
    540540  @param  Multi                 A pointer to a multi-instance device path data
     
    564564                                structure.
    565565
    566   @retval TRUE                  If the Single device path is contained within a 
     566  @retval TRUE                  If the Single device path is contained within a
    567567                                Multi device path.
    568   @retval FALSE                 The Single device path is not contained within a 
     568  @retval FALSE                 The Single device path is not contained within a
    569569                                Multi device path.
    570570
     
    658658  Add the legacy boot options from BBS table if they do not exist.
    659659
    660   @retval EFI_SUCCESS          The boot options were added successfully, 
     660  @retval EFI_SUCCESS          The boot options were added successfully,
    661661                               or they are already in boot options.
    662662  @retval EFI_NOT_FOUND        No legacy boot options is found.
     
    671671
    672672/**
    673   Add the legacy boot devices from BBS table into 
     673  Add the legacy boot devices from BBS table into
    674674  the legacy device boot order.
    675675
     
    690690
    691691  @param  Entry             The boot option is to be checked for a refreshed BBS table.
    692  
     692
    693693  @retval EFI_SUCCESS           The boot priority for BBS entries refreshed successfully.
    694694  @retval EFI_NOT_FOUND         BBS entries can't be found.
     
    859859/**
    860860  Expand a device path that starts with a hard drive media device path node to be a
    861   full device path that includes the full hardware path to the device. This function enables the device to boot. 
     861  full device path that includes the full hardware path to the device. This function enables the device to boot.
    862862  To avoid requiring a connect on every boot, the front match is saved in a variable (the part point
    863863  to the partition node. E.g. ACPI() /PCI()/ATA()/Partition() ).
     
    876876  IN  HARDDRIVE_DEVICE_PATH      *HardDriveDevicePath
    877877  );
    878  
     878
    879879/**
    880880  Return the bootable media handle.
     
    893893  IN  EFI_DEVICE_PATH_PROTOCOL      *DevicePath
    894894  );
    895  
     895
    896896
    897897/**
     
    942942
    943943  @retval BDS_EFI_MEDIA_HD_BOOT           The given device path contains MEDIA_DEVICE_PATH type device path node,
    944                                           whose subtype is MEDIA_HARDDRIVE_DP. 
    945   @retval BDS_EFI_MEDIA_CDROM_BOOT        If given device path contains MEDIA_DEVICE_PATH type device path node, 
    946                                           whose subtype is MEDIA_CDROM_DP. 
    947   @retval BDS_EFI_ACPI_FLOPPY_BOOT        A given device path contains ACPI_DEVICE_PATH type device path node,                                         
    948                                           whose HID is floppy device. 
    949   @retval BDS_EFI_MESSAGE_ATAPI_BOOT      A given device path contains MESSAGING_DEVICE_PATH type device path node, 
    950                                           and its last device path node's subtype is MSG_ATAPI_DP. 
     944                                          whose subtype is MEDIA_HARDDRIVE_DP.
     945  @retval BDS_EFI_MEDIA_CDROM_BOOT        If given device path contains MEDIA_DEVICE_PATH type device path node,
     946                                          whose subtype is MEDIA_CDROM_DP.
     947  @retval BDS_EFI_ACPI_FLOPPY_BOOT        A given device path contains ACPI_DEVICE_PATH type device path node,
     948                                          whose HID is floppy device.
     949  @retval BDS_EFI_MESSAGE_ATAPI_BOOT      A given device path contains MESSAGING_DEVICE_PATH type device path node,
     950                                          and its last device path node's subtype is MSG_ATAPI_DP.
    951951  @retval BDS_EFI_MESSAGE_SCSI_BOOT       A given device path contains MESSAGING_DEVICE_PATH type device path node,
    952                                           and its last device path node's subtype is MSG_SCSI_DP. 
    953   @retval BDS_EFI_MESSAGE_USB_DEVICE_BOOT A given device path contains MESSAGING_DEVICE_PATH type device path node, 
     952                                          and its last device path node's subtype is MSG_SCSI_DP.
     953  @retval BDS_EFI_MESSAGE_USB_DEVICE_BOOT A given device path contains MESSAGING_DEVICE_PATH type device path node,
    954954                                          and its last device path node's subtype is MSG_USB_DP.
    955   @retval BDS_EFI_MESSAGE_MISC_BOOT       The device path does not contain any media device path node, and 
    956                                           its last device path node points to a message device path node. 
    957   @retval BDS_LEGACY_BBS_BOOT             A given device path contains BBS_DEVICE_PATH type device path node. 
    958   @retval BDS_EFI_UNSUPPORT               An EFI Removable BlockIO device path does not point to a media and message device.   
     955  @retval BDS_EFI_MESSAGE_MISC_BOOT       The device path does not contain any media device path node, and
     956                                          its last device path node points to a message device path node.
     957  @retval BDS_LEGACY_BBS_BOOT             A given device path contains BBS_DEVICE_PATH type device path node.
     958  @retval BDS_EFI_UNSUPPORT               An EFI Removable BlockIO device path does not point to a media and message device.
    959959
    960960  **/
     
    976976  VOID
    977977  );
    978  
     978
    979979/**
    980980  Identify a user and, if authenticated, returns the current user profile handle.
    981981
    982982  @param[out]  User           Points to the user profile handle.
    983  
     983
    984984  @retval EFI_SUCCESS         The user is successfully identified, or user identification
    985985                              is not supported.
     
    991991BdsLibUserIdentify (
    992992  OUT EFI_USER_PROFILE_HANDLE         *User
    993   ); 
     993  );
    994994
    995995/**
     
    10311031
    10321032  @retval EFI_SUCCESS           The specific Usb device is connected successfully.
    1033   @retval EFI_INVALID_PARAMETER Invalid HostControllerPi (not 0x00, 0x20 or 0xFF) 
     1033  @retval EFI_INVALID_PARAMETER Invalid HostControllerPi (not 0x00, 0x20 or 0xFF)
    10341034                                or RemainingDevicePath is not the USB class device path.
    10351035  @retval EFI_NOT_FOUND         The device specified by device path is not found.
     
    10421042  IN EFI_DEVICE_PATH_PROTOCOL   *RemainingDevicePath
    10431043  );
    1044  
     1044
    10451045
    10461046//
     
    10991099
    11001100/**
    1101   Use SystemTable ConOut to turn on video based Simple Text Out consoles. The 
     1101  Use SystemTable ConOut to turn on video based Simple Text Out consoles. The
    11021102  Simple Text Out screens will now be synced up with all non-video output devices.
    11031103
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Library/PlatformBdsLib.h

    r48674 r58466  
    11/** @file
    2   Platform BDS library definition. A platform can implement 
     2  Platform BDS library definition. A platform can implement
    33  instances to support platform-specific behavior.
    44
    55Copyright (c) 2008 - 2010, Intel Corporation. All rights reserved.<BR>
    6 This program and the accompanying materials are licensed and made available under 
    7 the terms and conditions of the BSD License that accompanies this distribution. 
     6This program and the accompanying materials are licensed and made available under
     7the terms and conditions of the BSD License that accompanies this distribution.
    88The full text of the license may be found at
    9 http://opensource.org/licenses/bsd-license.php.                                         
    10    
    11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
     9http://opensource.org/licenses/bsd-license.php.
     10
     11THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1212WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1313
     
    5555
    5656**/
    57 typedef 
     57typedef
    5858EFI_STATUS
    5959(EFIAPI *PROCESS_CAPSULES)(
     
    9393
    9494/**
    95   Hook point for a user-provided function, for after a boot attempt fails. 
     95  Hook point for a user-provided function, for after a boot attempt fails.
    9696
    9797  @param  Option                  A pointer to Boot Option that failed to boot.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Protocol/IsaAcpi.h

    r48674 r58466  
    44
    55Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
    6 This program and the accompanying materials are licensed and made available under 
    7 the terms and conditions of the BSD License that accompanies this distribution. 
     6This program and the accompanying materials are licensed and made available under
     7the terms and conditions of the BSD License that accompanies this distribution.
    88The full text of the license may be found at
    9 http://opensource.org/licenses/bsd-license.php.                                         
    10    
    11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
     9http://opensource.org/licenses/bsd-license.php.
     10
     11THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1212WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1313
     
    7272
    7373///
    74 /// EFI ISA ACPI resource type 
     74/// EFI ISA ACPI resource type
    7575///
    7676typedef enum {
     
    7878  EfiIsaAcpiResourceIo,           ///< ISA I/O port resource range.
    7979  EfiIsaAcpiResourceMemory,       ///< ISA MMIO resource range.
    80   EfiIsaAcpiResourceDma,          ///< ISA DMA resource. 
     80  EfiIsaAcpiResourceDma,          ///< ISA DMA resource.
    8181  EfiIsaAcpiResourceInterrupt     ///< ISA interrupt resource.
    8282} EFI_ISA_ACPI_RESOURCE_TYPE;
     
    113113  This service allows all the ISA controllers on an ISA bus to be enumerated.  If
    114114  Device is a pointer to a NULL value, then the first ISA controller on the ISA
    115   bus is returned in Device and EFI_SUCCESS is returned.  If Device is a pointer 
    116   to a value that was returned on a prior call to DeviceEnumerate(), then the next 
     115  bus is returned in Device and EFI_SUCCESS is returned.  If Device is a pointer
     116  to a value that was returned on a prior call to DeviceEnumerate(), then the next
    117117  ISA controller on the ISA bus is returned in Device and EFI_SUCCESS is returned.
    118   If Device is a pointer to the last ISA controller on the ISA bus, then 
     118  If Device is a pointer to the last ISA controller on the ISA bus, then
    119119  EFI_NOT_FOUND is returned.
    120120
     
    136136  Sets the power state of an ISA controller.
    137137
    138   This services sets the power state of the ISA controller specified by Device to 
    139   the power state specified by OnOff.  TRUE denotes on, FALSE denotes off. 
     138  This services sets the power state of the ISA controller specified by Device to
     139  the power state specified by OnOff.  TRUE denotes on, FALSE denotes off.
    140140  If the power state is sucessfully set on the ISA Controller, then
    141141  EFI_SUCCESS is returned.
     
    156156  IN BOOLEAN                 OnOff
    157157  );
    158  
     158
    159159/**
    160160  Retrieves the current set of resources associated with an ISA controller.
    161161
    162   Retrieves the set of I/O, MMIO, DMA, and interrupt resources currently 
     162  Retrieves the set of I/O, MMIO, DMA, and interrupt resources currently
    163163  assigned to the ISA controller specified by Device.  These resources
    164164  are returned in ResourceList.
     
    210210  @param[in] This           The pointer to the EFI_ISA_ACPI_PROTOCOL instance.
    211211  @param[in] Device         The pointer to an ISA controller named by ACPI HID/UID.
    212   @param[in] ResourceList   The pointer to a resources list that must be one of the 
     212  @param[in] ResourceList   The pointer to a resources list that must be one of the
    213213                            resource lists returned by GetPosResource() for the
    214214                            ISA controller specified by Device.
     
    224224  IN EFI_ISA_ACPI_DEVICE_ID      *Device,
    225225  IN EFI_ISA_ACPI_RESOURCE_LIST  *ResourceList
    226   );   
     226  );
    227227
    228228/**
     
    244244  IN EFI_ISA_ACPI_DEVICE_ID  *Device,
    245245  IN BOOLEAN                 Enable
    246   );   
     246  );
    247247
    248248/**
     
    262262  IN EFI_ISA_ACPI_PROTOCOL   *This,
    263263  IN EFI_ISA_ACPI_DEVICE_ID  *Device
    264   ); 
    265 
    266 /**
    267   Initializes all the HW states required for the ISA controllers on the ISA bus 
     264  );
     265
     266/**
     267  Initializes all the HW states required for the ISA controllers on the ISA bus
    268268  to be enumerated and managed by the rest of the services in this prorotol.
    269269  This service must be called before any of the other services in this
    270270  protocol will function as expected.
    271  
     271
    272272  @param[in] This  The pointer to the EFI_ISA_ACPI_PROTOCOL instance.
    273273
     
    284284///
    285285/// The EFI_ISA_ACPI_PROTOCOL provides the services to enumerate and manage
    286 /// ISA controllers on an ISA bus.  These services include the ability to initialize, 
    287 /// enable, disable, and manage the power state of ISA controllers.  It also 
    288 /// includes services to query current resources, query possible resources, 
     286/// ISA controllers on an ISA bus.  These services include the ability to initialize,
     287/// enable, disable, and manage the power state of ISA controllers.  It also
     288/// includes services to query current resources, query possible resources,
    289289/// and assign resources to an ISA controller.
    290290///
     
    301301
    302302extern EFI_GUID gEfiIsaAcpiProtocolGuid;
    303  
     303
    304304#endif
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Protocol/IsaIo.h

    r48674 r58466  
    11/** @file
    2   ISA I/O Protocol is used by ISA device drivers to perform I/O, MMIO and DMA 
     2  ISA I/O Protocol is used by ISA device drivers to perform I/O, MMIO and DMA
    33  operations on the ISA controllers they manage.
    4  
     4
    55Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
    6 This program and the accompanying materials are licensed and made available under 
    7 the terms and conditions of the BSD License that accompanies this distribution. 
     6This program and the accompanying materials are licensed and made available under
     7the terms and conditions of the BSD License that accompanies this distribution.
    88The full text of the license may be found at
    9 http://opensource.org/licenses/bsd-license.php.                                         
    10    
    11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
     9http://opensource.org/licenses/bsd-license.php.
     10
     11THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1212WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1313
     
    8585  ///
    8686  /// Provides both read and write access to system memory by both the processor
    87   /// and a bus master. The buffer is coherent from both the processor's and the 
     87  /// and a bus master. The buffer is coherent from both the processor's and the
    8888  /// bus master's point of view.
    8989  ///
     
    103103  Performs ISA I/O and MMIO Read/Write Cycles
    104104
    105   @param[in]      This     A pointer to the EFI_ISA_IO_PROTOCOL instance. 
     105  @param[in]      This     A pointer to the EFI_ISA_IO_PROTOCOL instance.
    106106  @param[in]      Width    Specifies the width of the I/O or MMIO operation.
    107   @param[in]      Offset   The offset into the ISA I/O or MMIO space to start the 
    108                            operation. 
     107  @param[in]      Offset   The offset into the ISA I/O or MMIO space to start the
     108                           operation.
    109109  @param[in]      Count    The number of I/O or MMIO operations to perform.
    110   @param[in, out] Buffer   For read operations, the destination buffer to store 
    111                            the results. For write operations, the source buffer to 
    112                            write data from. 
    113                                  
     110  @param[in, out] Buffer   For read operations, the destination buffer to store
     111                           the results. For write operations, the source buffer to
     112                           write data from.
     113
    114114  @retval EFI_SUCCESS             The data was successfully read from or written to the device.
    115115  @retval EFI_UNSUPPORTED         The Offset is not valid for this device.
     
    172172
    173173  This function returns the device-specific addresses required to access system memory.
    174   This function is used to map system memory for ISA DMA operations.  All ISA DMA 
    175   operations must be performed through their mapped addresses, and such mappings must 
     174  This function is used to map system memory for ISA DMA operations.  All ISA DMA
     175  operations must be performed through their mapped addresses, and such mappings must
    176176  be freed with EFI_ISA_IO_PROTOCOL.Unmap() after the DMA operation is completed.
    177    
    178   If the DMA operation is a single read or write data transfer through an ISA bus 
    179   master, then EfiIsaIoOperationBusMasterRead or EfiIsaIoOperationBusMasterWrite 
     177
     178  If the DMA operation is a single read or write data transfer through an ISA bus
     179  master, then EfiIsaIoOperationBusMasterRead or EfiIsaIoOperationBusMasterWrite
    180180  is used and the range is unmapped to complete the operation. If the DMA operation
    181   is a single read or write data transfer through an ISA slave controller, then 
    182   EfiIsaIoOperationSlaveRead or EfiIsaIoOperationSlaveWrite is used and the range 
    183   is unmapped to complete the operation. 
    184  
    185   If performing a DMA read operation, all the data must be present in system memory before the Map() is performed.  Similarly, 
    186   if performing a DMA write operation, the data must not be accessed in system 
    187   memory until EFI_ISA_IO_PROTOCOL.Unmap() is performed.  Bus master operations that 
    188   require both read and write access or require multiple host device interactions 
    189   within the same mapped region must use EfiIsaIoOperationBusMasterCommonBuffer. 
    190   However, only memory allocated via the EFI_ISA_IO_PROTOCOL.AllocateBuffer() interface 
    191   is guaranteed to be able to be mapped for this operation type.  In all mapping 
     181  is a single read or write data transfer through an ISA slave controller, then
     182  EfiIsaIoOperationSlaveRead or EfiIsaIoOperationSlaveWrite is used and the range
     183  is unmapped to complete the operation.
     184
     185  If performing a DMA read operation, all the data must be present in system memory before the Map() is performed.  Similarly,
     186  if performing a DMA write operation, the data must not be accessed in system
     187  memory until EFI_ISA_IO_PROTOCOL.Unmap() is performed.  Bus master operations that
     188  require both read and write access or require multiple host device interactions
     189  within the same mapped region must use EfiIsaIoOperationBusMasterCommonBuffer.
     190  However, only memory allocated via the EFI_ISA_IO_PROTOCOL.AllocateBuffer() interface
     191  is guaranteed to be able to be mapped for this operation type.  In all mapping
    192192  requests the NumberOfBytes returned may be less than originally requested.  It is
    193193  the caller's responsibility to make additional requests to complete the entire
     
    195195
    196196  @param[in]      This                A pointer to the EFI_ISA_IO_PROTOCOL instance.
    197   @param[in]      Operation           Indicates the type of DMA (slave or bus master), 
    198                                       and if the DMA operation is going to read or 
    199                                       write to system memory. 
    200   @param[in]      ChannelNumber       The slave channel number to use for this DMA 
    201                                       operation.  If Operation and ChannelAttributes 
    202                                       shows that this device performs bus mastering 
    203                                       DMA, then this field is ignored.  The legal 
     197  @param[in]      Operation           Indicates the type of DMA (slave or bus master),
     198                                      and if the DMA operation is going to read or
     199                                      write to system memory.
     200  @param[in]      ChannelNumber       The slave channel number to use for this DMA
     201                                      operation.  If Operation and ChannelAttributes
     202                                      shows that this device performs bus mastering
     203                                      DMA, then this field is ignored.  The legal
    204204                                      range for this field is 0..7.
    205205  @param[in]      ChannelAttributes   A bitmask of the attributes used to configure
    206                                       the slave DMA channel for this DMA operation. 
     206                                      the slave DMA channel for this DMA operation.
    207207                                      See EFI_ISA_IO_SLAVE_DMA_ATTRIBUTE_* for the
    208208                                      legal bit combinations.
    209209  @param[in]      HostAddress         The system memory address to map to the device.
    210   @param[in, out] NumberOfBytes       On input the number of bytes to map.  On 
     210  @param[in, out] NumberOfBytes       On input the number of bytes to map.  On
    211211                                      output the number of bytes that were mapped.
    212   @param[out]     DeviceAddress       The resulting map address for the bus master 
    213                                       device to use to access the hosts HostAddress. 
     212  @param[out]     DeviceAddress       The resulting map address for the bus master
     213                                      device to use to access the hosts HostAddress.
    214214  @param[out]     Mapping             A returned value that must be passed to into
    215                                       EFI_ISA_IO_PROTOCOL.Unmap() to free all the the 
     215                                      EFI_ISA_IO_PROTOCOL.Unmap() to free all the the
    216216                                      resources associated with this map request.
    217217
     
    240240  Unmaps a memory region that was previously mapped with EFI_ISA_IO_PROTOCOL.Map().
    241241
    242   The EFI_ISA_IO_PROTOCOL.Map() operation is completed and any corresponding 
    243   resources are released.  If the operation was EfiIsaIoOperationSlaveWrite 
    244   or EfiIsaIoOperationBusMasterWrite, the data is committed to system memory. 
     242  The EFI_ISA_IO_PROTOCOL.Map() operation is completed and any corresponding
     243  resources are released.  If the operation was EfiIsaIoOperationSlaveWrite
     244  or EfiIsaIoOperationBusMasterWrite, the data is committed to system memory.
    245245  Any resources used for the mapping are freed.
    246246
     
    260260/**
    261261  Allocates pages that are suitable for an EfiIsaIoOperationBusMasterCommonBuffer
    262   mapping.                                                                       
     262  mapping.
    263263
    264264  @param[in]  This          A pointer to the EFI_ISA_IO_PROTOCOL instance.
    265   @param[in]  Type          The type allocation to perform. 
     265  @param[in]  Type          The type allocation to perform.
    266266  @param[in]  MemoryType    The type of memory to allocate.
    267267  @param[in]  Pages         The number of pages to allocate.
     
    326326
    327327///
    328 /// The EFI_ISA_IO_PROTOCOL provides the basic Memory, I/O, and DMA interfaces 
    329 /// used to abstract accesses to ISA controllers.  There is one EFI_ISA_IO_PROTOCOL 
    330 /// instance for each ISA controller on a ISA bus. A device driver that wishes 
    331 /// to manage an ISA controller in a system will have to retrieve the 
     328/// The EFI_ISA_IO_PROTOCOL provides the basic Memory, I/O, and DMA interfaces
     329/// used to abstract accesses to ISA controllers.  There is one EFI_ISA_IO_PROTOCOL
     330/// instance for each ISA controller on a ISA bus. A device driver that wishes
     331/// to manage an ISA controller in a system will have to retrieve the
    332332/// ISA_PCI_IO_PROTOCOL instance associated with the ISA controller.
    333333///
     
    351351  UINT32                               RomSize;
    352352  ///
    353   /// A pointer to the in memory copy of the ROM image. The ISA Bus Driver is responsible 
     353  /// A pointer to the in memory copy of the ROM image. The ISA Bus Driver is responsible
    354354  /// for allocating memory for the ROM image, and copying the contents of the ROM to memory
    355355  /// during ISA Bus initialization.
    356   /// 
     356  ///
    357357  VOID                                 *RomImage;
    358358};
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Protocol/OEMBadging.h

    r48674 r58466  
    11/** @file
    2   The OEM Badging Protocol defines the interface to get the OEM badging 
     2  The OEM Badging Protocol defines the interface to get the OEM badging
    33  image with the display attribute. This protocol can be produced based on OEM badging images.
    44
    55Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
    6 This program and the accompanying materials are licensed and made available under 
    7 the terms and conditions of the BSD License that accompanies this distribution. 
     6This program and the accompanying materials are licensed and made available under
     7the terms and conditions of the BSD License that accompanies this distribution.
    88The full text of the license may be found at
    9 http://opensource.org/licenses/bsd-license.php.                                         
    10    
    11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
     9http://opensource.org/licenses/bsd-license.php.
     10
     11THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1212WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1313
     
    5454  @param Instance          The visible image instance is found.
    5555  @param Format            The format of the image. Examples: BMP, JPEG.
    56   @param ImageData         The image data for the badge file. Currently only 
    57                            supports the .bmp file format. 
     56  @param ImageData         The image data for the badge file. Currently only
     57                           supports the .bmp file format.
    5858  @param ImageSize         The size of the image returned.
    5959  @param Attribute         The display attributes of the image returned.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Protocol/Ps2Policy.h

    r48674 r58466  
    33
    44Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
    5 This program and the accompanying materials are licensed and made available under 
    6 the terms and conditions of the BSD License that accompanies this distribution. 
     5This program and the accompanying materials are licensed and made available under
     6the terms and conditions of the BSD License that accompanies this distribution.
    77The full text of the license may be found at
    8 http://opensource.org/licenses/bsd-license.php.                                         
    9    
    10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
    11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             
     8http://opensource.org/licenses/bsd-license.php.
     9
     10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     11WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
    1313**/
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Include/Protocol/VgaMiniPort.h

    r48674 r58466  
    33
    44Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
    5 This program and the accompanying materials are licensed and made available under 
    6 the terms and conditions of the BSD License that accompanies this distribution. 
     5This program and the accompanying materials are licensed and made available under
     6the terms and conditions of the BSD License that accompanies this distribution.
    77The full text of the license may be found at
    8 http://opensource.org/licenses/bsd-license.php.                                         
    9    
    10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
     8http://opensource.org/licenses/bsd-license.php.
     9
     10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1111WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
     
    3131/**
    3232  Sets the text display mode of a VGA controller.
    33  
    34   Sets the text display mode of the VGA controller to the mode specified by 
    35   ModeNumber.  A ModeNumber of 0 is a request for an 80x25 text mode.  A 
     33
     34  Sets the text display mode of the VGA controller to the mode specified by
     35  ModeNumber.  A ModeNumber of 0 is a request for an 80x25 text mode.  A
    3636  ModeNumber of 1 is a request for an 80x50 text mode.  If ModeNumber is greater
    37   than MaxModeNumber, then EFI_UNSUPPORTED is returned.  If the VGA controller 
     37  than MaxModeNumber, then EFI_UNSUPPORTED is returned.  If the VGA controller
    3838  is not functioning properly, then EFI_DEVICE_ERROR is returned.  If the VGA
    39   controller is sucessfully set to the mode number specified by ModeNumber, then 
     39  controller is sucessfully set to the mode number specified by ModeNumber, then
    4040  EFI_SUCCESS is returned.
    41    
     41
    4242  @param[in] This         A pointer to the EFI_VGA_MINI_PORT_PROTOCOL instance.
    4343  @param[in] ModeNumber   The requested mode number.  0 for 80x25.  1 for 80x5.
     
    4646  @retval EFI_UNSUPPORTED    The mode number specified by ModeNumber is not supported.
    4747  @retval EFI_DEVICE_ERROR   The device is not functioning properly.
    48  
     48
    4949**/
    5050typedef
     
    7070  UINT64                      CrtcDataRegisterOffset;
    7171  ///
    72   /// PCI Controller MMIO BAR index of the VGA text mode frame buffer.  Typically 
     72  /// PCI Controller MMIO BAR index of the VGA text mode frame buffer.  Typically
    7373  /// set to EFI_PCI_IO_PASS_THROUGH_BAR
    7474  ///
    7575  UINT8                       VgaMemoryBar;
    7676  ///
    77   /// PCI Controller I/O BAR index of the VGA CRTC address register.  Typically 
     77  /// PCI Controller I/O BAR index of the VGA CRTC address register.  Typically
    7878  /// set to EFI_PCI_IO_PASS_THROUGH_BAR
    7979  ///
    8080  UINT8                       CrtcAddressRegisterBar;
    8181  ///
    82   /// PCI Controller I/O BAR index of the VGA CRTC data register.  Typically set 
     82  /// PCI Controller I/O BAR index of the VGA CRTC data register.  Typically set
    8383  /// to EFI_PCI_IO_PASS_THROUGH_BAR
    8484  ///
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec

    • Property svn:eol-style set to native
    r58459 r58466  
    5252  ## Include/Guid/LegacyBios.h
    5353  gEfiLegacyBiosGuid                 = { 0x2E3044AC, 0x879F, 0x490F, { 0x97, 0x60, 0xBB, 0xDF, 0xAF, 0x69, 0x5F, 0x50 }}
    54  
     54
    5555  ## Include/Guid/LegacyDevOrder.h
    5656  gEfiLegacyDevOrderVariableGuid     = { 0xa56074db, 0x65fe, 0x45f7, {0xbd, 0x21, 0x2d, 0x2b, 0xdd, 0x8e, 0x96, 0x52 }}
     
    5858  ## Include/Guid/CapsuleDataFile.h
    5959  gEfiUpdateDataFileGuid             = { 0x283fa2ee, 0x532c, 0x484d, { 0x93, 0x83, 0x9f, 0x93, 0xb3, 0x6f, 0xb, 0x7e }}
    60  
     60
    6161  ## Include/Guid/BlockIoVendor.h
    6262  gBlockIoVendorGuid                 = { 0xcf31fac5, 0xc24e, 0x11d2,  {0x85, 0xf3, 0x0, 0xa0, 0xc9, 0x3e, 0xc9, 0x3b }}
    63  
     63
    6464  ## Include/Guid/BdsHii.h
    6565  gFrontPageFormSetGuid              = { 0x9e0c30bc, 0x3f06, 0x4ba6, {0x82, 0x88, 0x9, 0x17, 0x9b, 0x85, 0x5d, 0xbe }}
     
    6969  gBootMaintFormSetGuid              = { 0x642237c7, 0x35d4, 0x472d, {0x83, 0x65, 0x12, 0xe0, 0xcc, 0xf2, 0x7a, 0x22 }}
    7070  gFileExploreFormSetGuid            = { 0x1f2d63e1, 0xfebd, 0x4dc7, {0x9c, 0xc5, 0xba, 0x2b, 0x1c, 0xef, 0x9c, 0x5b }}
    71  
     71
    7272  ## Include/Guid/BdsLibHii.h
    7373  gBdsLibStringPackageGuid           = { 0x3b4d9b23, 0x95ac, 0x44f6, {0x9f, 0xcd, 0xe, 0x95, 0x94, 0x58, 0x6c, 0x72 }}
    74  
     74
    7575  ## Include/Guid/LastEnumLang.h
    7676  gLastEnumLangGuid                  = { 0xe8c545b, 0xa2ee, 0x470d, {0x8e, 0x26, 0xbd, 0xa1, 0xa1, 0x3c, 0xa, 0xa3 }}
     
    142142  gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdPs2KbdExtendedVerification|TRUE|BOOLEAN|0x00010045
    143143
    144   ## Indicates if Framework Acpi Support protocol is installed.<BR><BR> 
     144  ## Indicates if Framework Acpi Support protocol is installed.<BR><BR>
    145145  #   TRUE  - Install Framework Acpi Support protocol.<BR>
    146146  #   FALSE - Doesn't install Framework Acpi Support protocol.<BR>
     
    189189  gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdBootState|TRUE|BOOLEAN|0x0001002f
    190190
    191   ## The number of seconds that the firmware will wait before initiating the original default boot selection. 
    192   #  A value of 0 indicates that the default boot selection is to be initiated immediately on boot. 
     191  ## The number of seconds that the firmware will wait before initiating the original default boot selection.
     192  #  A value of 0 indicates that the default boot selection is to be initiated immediately on boot.
    193193  #  The value of 0xFFFF then firmware will wait for user input before booting.
    194194  # @Prompt Boot Timeout (s)
    195195  gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdPlatformBootTimeOut|0xffff|UINT16|0x40000001
    196196
    197   ## Error level for hardware recorder. 
     197  ## Error level for hardware recorder.
    198198  #  If value 0, platform does not support feature of hardware error record.
    199199  # @Prompt Error Level For Hardware Recorder
     
    211211  # @Prompt Video Horizontal Resolution of Text Setup
    212212  gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdSetupVideoHorizontalResolution|800|UINT32|0x50000001
    213  
     213
    214214  ## Specify the video vertical resolution of text setup.
    215215  # @Prompt Video Vertical Resolution of Text Setup
     
    219219  # @Prompt Console Output Column of Text Setup
    220220  gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdSetupConOutColumn|80|UINT32|0x50000003
    221  
     221
    222222  ## Specify the console output row of text setup.
    223223  # @Prompt Console Output Row of Text Setup
     
    256256
    257257  ## Specify memory size with bytes to reserve EBDA below 640K for OPROM.
    258   # The value should be a multiple of 4KB. 
     258  # The value should be a multiple of 4KB.
    259259  # @Prompt Reserved EBDA Memory Size
    260260  # @Expression 0x80000001 | (gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdEbdaReservedMemorySize < 0xA0000) AND ((gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdEbdaReservedMemorySize & 0x1000) == 0)
     
    262262
    263263  ## Specify memory base address for OPROM to find free memory.
    264   # Some OPROMs do not use EBDA or PMM to allocate memory for its usage, 
     264  # Some OPROMs do not use EBDA or PMM to allocate memory for its usage,
    265265  # instead they find the memory filled with zero from 0x20000.
    266266  # The value should be a multiple of 4KB.
    267   # The range should be below the EBDA reserved range from 
     267  # The range should be below the EBDA reserved range from
    268268  # (CONVENTIONAL_MEMORY_TOP - Reserved EBDA Memory Size) to CONVENTIONAL_MEMORY_TOP.
    269269  gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdOpromReservedMemoryBase|0x60000|UINT32|0x3000000c
    270  
     270
    271271  ## Specify memory size with bytes for OPROM to find free memory.
    272   #  The value should be a multiple of 4KB. And the range should be below the EBDA reserved range from 
     272  #  The value should be a multiple of 4KB. And the range should be below the EBDA reserved range from
    273273  # (CONVENTIONAL_MEMORY_TOP - Reserved EBDA Memory Size) to CONVENTIONAL_MEMORY_TOP.
    274274  gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdOpromReservedMemorySize|0x28000|UINT32|0x3000000d
    275275
    276276  ## Specify memory size with page number for a pre-allocated reserved memory to be used
    277   #  by PEI in S3 phase. The default size 32K. When changing the value make sure the memory size 
     277  #  by PEI in S3 phase. The default size 32K. When changing the value make sure the memory size
    278278  #  is large enough to meet PEI requirement in the S3 phase.
    279279  # @Prompt Reserved S3 Boot ACPI Memory Size
     
    281281
    282282  ## Specify memory size for boot script executor stack usage in S3 phase.
    283   #  The default size 32K. When changing the value make sure the memory size is large enough 
     283  #  The default size 32K. When changing the value make sure the memory size is large enough
    284284  #  to meet boot script executor requirement in the S3 phase.
    285285  # @Prompt Reserved S3 Boot Script Stack ACPI Memory Size
     
    291291  # @Expression 0x80000001 | gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdEndOpromShadowAddress < 0x100000
    292292  gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdEndOpromShadowAddress|0xdffff|UINT32|0x30000008
    293  
     293
    294294  ## Specify the low PMM (Post Memory Manager) size with bytes below 1MB.
    295295  #  The value should be a multiple of 4KB.
     
    297297  # @Expression 0x80000001 | (gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdLowPmmMemorySize < 0x100000) AND ((gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdLowPmmMemorySize & 0x1000) == 0)
    298298  gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdLowPmmMemorySize|0x10000|UINT32|0x30000009
    299  
     299
    300300  ## Specify the high PMM (Post Memory Manager) size with bytes above 1MB.
    301301  #  The value should be a multiple of 4KB.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/IntelFrameworkModulePkg.dsc

    r58459 r58466  
    55#
    66#Copyright (c) 2007 - 2014, Intel Corporation. All rights reserved.<BR>
    7 #This program and the accompanying materials are licensed and made available under 
    8 #the terms and conditions of the BSD License that accompanies this distribution. 
     7#This program and the accompanying materials are licensed and made available under
     8#the terms and conditions of the BSD License that accompanies this distribution.
    99#The full text of the license may be found at
    10 #http://opensource.org/licenses/bsd-license.php.                         
     10#http://opensource.org/licenses/bsd-license.php.
    1111#
    1212# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1313# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1414#
    15 ##           
     15##
    1616
    1717################################################################################
     
    4343  DebugAgentLib|MdeModulePkg/Library/DebugAgentLibNull/DebugAgentLibNull.inf
    4444  DebugLib|MdePkg/Library/BaseDebugLibNull/BaseDebugLibNull.inf
    45   DebugPrintErrorLevelLib|MdePkg/Library/BaseDebugPrintErrorLevelLib/BaseDebugPrintErrorLevelLib.inf 
     45  DebugPrintErrorLevelLib|MdePkg/Library/BaseDebugPrintErrorLevelLib/BaseDebugPrintErrorLevelLib.inf
    4646  BaseLib|MdePkg/Library/BaseLib/BaseLib.inf
    4747  SynchronizationLib|MdePkg/Library/BaseSynchronizationLib/BaseSynchronizationLib.inf
     
    9393[LibraryClasses.common.DXE_RUNTIME_DRIVER]
    9494  DebugLib|MdePkg/Library/UefiDebugLibConOut/UefiDebugLibConOut.inf
    95  
     95
    9696################################################################################
    9797#
     
    175175[Components.IA32,Components.X64,Components.IPF]
    176176  IntelFrameworkModulePkg/Csm/LegacyBiosDxe/LegacyBiosDxe.inf
    177  
     177
    178178[Components.IA32]
    179179  IntelFrameworkModulePkg/Universal/StatusCode/RuntimeDxe/StatusCodeRuntimeDxe.inf
     
    189189      IoLib|MdePkg/Library/BaseIoLibIntrinsic/BaseIoLibIntrinsic.inf
    190190  }
    191  
     191
    192192[Components.IPF]
    193193  IntelFrameworkModulePkg/Universal/CpuIoDxe/CpuIoDxe.inf {
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/BaseUefiTianoCustomDecompressLib/BaseUefiTianoCustomDecompressLib.c

    r58459 r58466  
    11/** @file
    2   UEFI and Tiano Custom Decompress Library 
     2  UEFI and Tiano Custom Decompress Library
    33  It will do Tiano or UEFI decompress with different verison parameter.
    4  
     4
    55Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
    6 This program and the accompanying materials                         
    7 are licensed and made available under the terms and conditions of the BSD License         
    8 which accompanies this distribution.  The full text of the license may be found at       
    9 http://opensource.org/licenses/bsd-license.php                                           
    10                                                                                          
    11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
    12 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             
     6This program and the accompanying materials
     7are licensed and made available under the terms and conditions of the BSD License
     8which accompanies this distribution.  The full text of the license may be found at
     9http://opensource.org/licenses/bsd-license.php
     10
     11THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     12WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1313
    1414**/
     
    1818/**
    1919  Shift mBitBuf NumOfBits left. Read in NumOfBits of bits from source.
    20  
     20
    2121  @param Sd         The global scratch data
    22   @param NumOfBits  The number of bits to shift and read. 
     22  @param NumOfBits  The number of bits to shift and read.
    2323**/
    2424VOID
     
    6363  //
    6464  Sd->mBitCount = (UINT16) (Sd->mBitCount - NumOfBits);
    65  
     65
    6666  //
    6767  // Copy NumOfBits of bits from mSubBitBuf into mBitBuf
     
    7373  Get NumOfBits of bits out from mBitBuf
    7474
    75   Get NumOfBits of bits out from mBitBuf. Fill mBitBuf with subsequent 
    76   NumOfBits of bits from source. Returns NumOfBits of bits that are 
     75  Get NumOfBits of bits out from mBitBuf. Fill mBitBuf with subsequent
     76  NumOfBits of bits from source. Returns NumOfBits of bits that are
    7777  popped out.
    7878
     
    9393  //
    9494  // Pop NumOfBits of Bits from Left
    95   // 
     95  //
    9696  OutBits = (UINT32) (Sd->mBitBuf >> (BITBUFSIZ - NumOfBits));
    9797
     
    107107  Creates Huffman Code mapping table according to code length array.
    108108
    109   Creates Huffman Code mapping table for Extra Set, Char&Len Set 
     109  Creates Huffman Code mapping table for Extra Set, Char&Len Set
    110110  and Position Set according to code length array.
    111111  If TableBits > 16, then ASSERT ().
     
    158158    Count[BitLen[Index]]++;
    159159  }
    160  
     160
    161161  Start[0] = 0;
    162162  Start[1] = 0;
     
    174174
    175175  JuBits = (UINT16) (16 - TableBits);
    176  
     176
    177177  Weight[0] = 0;
    178178  for (Index = 1; Index <= TableBits; Index++) {
     
    183183  while (Index <= 16) {
    184184    Weight[Index] = (UINT16) (1U << (16 - Index));
    185     Index++;   
     185    Index++;
    186186  }
    187187
     
    224224          *Pointer = Avail++;
    225225        }
    226        
     226
    227227        if (*Pointer < (2 * NC - 1)) {
    228228          if ((Index3 & Mask) != 0) {
     
    251251/**
    252252  Decodes a position value.
    253  
     253
    254254  Get a position value according to Position Huffman Table.
    255255
    256256  @param Sd      the global scratch data
    257  
     257
    258258  @return The position value decoded.
    259259**/
     
    326326  ASSERT (nn <= NPT);
    327327  //
    328   // Read Extra Set Code Length Array size 
     328  // Read Extra Set Code Length Array size
    329329  //
    330330  Number = (UINT16) GetBits (Sd, nbit);
     
    353353    //
    354354    // If a code length is less than 7, then it is encoded as a 3-bit
    355     // value. Or it is encoded as a series of "1"s followed by a 
     355    // value. Or it is encoded as a series of "1"s followed by a
    356356    // terminating "0". The number of "1"s = Code length - 4.
    357357    //
     
    363363      }
    364364    }
    365    
     365
    366366    FillBuf (Sd, (UINT16) ((CharC < 7) ? 3 : CharC - 3));
    367367
    368368    Sd->mPTLen[Index++] = (UINT8) CharC;
    369  
    370     //
    371     // For Code&Len Set, 
     369
     370    //
     371    // For Code&Len Set,
    372372    // After the third length of the code length concatenation,
    373     // a 2-bit value is used to indicated the number of consecutive 
     373    // a 2-bit value is used to indicated the number of consecutive
    374374    // zero lengths after the third length.
    375375    //
     
    385385    Sd->mPTLen[Index++] = 0;
    386386  }
    387  
     387
    388388  return MakeTable (Sd, nn, Sd->mPTLen, 8, Sd->mPTTable);
    389389}
     
    391391/**
    392392  Reads code lengths for Char&Len Set.
    393  
     393
    394394  Read in and decode the Char&Len Set Code Length Array, then
    395395  generate the Huffman Code mapping table for the Char&Len Set.
     
    478478/**
    479479  Decode a character/length value.
    480  
     480
    481481  Read one value from mBitBuf, Get one code from mBitBuf. If it is at block boundary, generates
    482482  Huffman code mapping table for Extra Set, Code&Len Set and
     
    500500    // Starting a new block
    501501    // Read BlockSize from block header
    502     // 
     502    //
    503503    Sd->mBlockSize    = (UINT16) GetBits (Sd, 16);
    504504
     
    519519
    520520    //
    521     // Read in the Position Set Code Length Arrary, 
     521    // Read in the Position Set Code Length Arrary,
    522522    // Generate the Huffman code mapping table for the Position Set.
    523523    //
     
    557557/**
    558558  Decode the source data and put the resulting data into the destination buffer.
    559  
     559
    560560  @param  Sd The global scratch data
    561561**/
     
    576576    //
    577577    // Get one code from mBitBuf
    578     // 
     578    //
    579579    CharC = DecodeC (Sd);
    580580    if (Sd->mBadTableFlag != 0) {
     
    600600      //
    601601      CharC       = (UINT16) (CharC - (BIT8 - THRESHOLD));
    602  
     602
    603603      //
    604604      // Get string length
     
    631631
    632632/**
    633   Given a compressed source buffer, this function retrieves the size of 
    634   the uncompressed buffer and the size of the scratch buffer required 
     633  Given a compressed source buffer, this function retrieves the size of
     634  the uncompressed buffer and the size of the scratch buffer required
    635635  to decompress the compressed source buffer.
    636636
    637   Retrieves the size of the uncompressed buffer and the temporary scratch buffer 
     637  Retrieves the size of the uncompressed buffer and the temporary scratch buffer
    638638  required to decompress the buffer specified by Source and SourceSize.
    639639  If the size of the uncompressed buffer or the size of the scratch buffer cannot
    640   be determined from the compressed data specified by Source and SourceData, 
     640  be determined from the compressed data specified by Source and SourceData,
    641641  then RETURN_INVALID_PARAMETER is returned.  Otherwise, the size of the uncompressed
    642642  buffer is returned in DestinationSize, the size of the scratch buffer is returned
    643643  in ScratchSize, and RETURN_SUCCESS is returned.
    644   This function does not have scratch buffer available to perform a thorough 
     644  This function does not have scratch buffer available to perform a thorough
    645645  checking of the validity of the source data.  It just retrieves the "Original Size"
    646646  field from the beginning bytes of the source data and output it as DestinationSize.
     
    657657                          by Source and SourceSize is decompressed..
    658658  @param  ScratchSize     A pointer to the size, in bytes, of the scratch buffer that
    659                           is required to decompress the compressed buffer specified 
     659                          is required to decompress the compressed buffer specified
    660660                          by Source and SourceSize.
    661661
    662   @retval  RETURN_SUCCESS The size of the uncompressed data was returned 
    663                           in DestinationSize and the size of the scratch 
     662  @retval  RETURN_SUCCESS The size of the uncompressed data was returned
     663                          in DestinationSize and the size of the scratch
    664664                          buffer was returned in ScratchSize.
    665   @retval  RETURN_INVALID_PARAMETER 
    666                           The size of the uncompressed data or the size of 
    667                           the scratch buffer cannot be determined from 
    668                           the compressed data specified by Source 
     665  @retval  RETURN_INVALID_PARAMETER
     666                          The size of the uncompressed data or the size of
     667                          the scratch buffer cannot be determined from
     668                          the compressed data specified by Source
    669669                          and SourceSize.
    670670**/
     
    705705  This function is designed so that the decompression algorithm can be implemented
    706706  without using any memory services.  As a result, this function is not allowed to
    707   call any memory allocation services in its implementation.  It is the caller's 
     707  call any memory allocation services in its implementation.  It is the caller's
    708708  responsibility to allocate and free the Destination and Scratch buffers.
    709   If the compressed source data specified by Source is successfully decompressed 
    710   into Destination, then RETURN_SUCCESS is returned.  If the compressed source data 
     709  If the compressed source data specified by Source is successfully decompressed
     710  into Destination, then RETURN_SUCCESS is returned.  If the compressed source data
    711711  specified by Source is not in a valid compressed data format,
    712712  then RETURN_INVALID_PARAMETER is returned.
     
    719719  @param  Destination The destination buffer to store the decompressed data
    720720  @param  Scratch     A temporary scratch buffer that is used to perform the decompression.
    721                       This is an optional parameter that may be NULL if the 
     721                      This is an optional parameter that may be NULL if the
    722722                      required scratch buffer size is 0.
    723723  @param  Version     1 for UEFI Decompress algoruthm, 2 for Tiano Decompess algorithm.
    724724
    725   @retval  RETURN_SUCCESS Decompression completed successfully, and 
     725  @retval  RETURN_SUCCESS Decompression completed successfully, and
    726726                          the uncompressed buffer is returned in Destination.
    727   @retval  RETURN_INVALID_PARAMETER 
    728                           The source buffer specified by Source is corrupted 
     727  @retval  RETURN_INVALID_PARAMETER
     728                          The source buffer specified by Source is corrupted
    729729                          (not in a valid compressed format).
    730730**/
     
    816816  This function is designed so that the decompression algorithm can be implemented
    817817  without using any memory services.  As a result, this function is not allowed to
    818   call any memory allocation services in its implementation.  It is the caller's 
     818  call any memory allocation services in its implementation.  It is the caller's
    819819  responsibility to allocate and free the Destination and Scratch buffers.
    820   If the compressed source data specified by Source is successfully decompressed 
    821   into Destination, then RETURN_SUCCESS is returned.  If the compressed source data 
     820  If the compressed source data specified by Source is successfully decompressed
     821  into Destination, then RETURN_SUCCESS is returned.  If the compressed source data
    822822  specified by Source is not in a valid compressed data format,
    823823  then RETURN_INVALID_PARAMETER is returned.
     
    830830  @param  Destination The destination buffer to store the decompressed data
    831831  @param  Scratch     A temporary scratch buffer that is used to perform the decompression.
    832                       This is an optional parameter that may be NULL if the 
     832                      This is an optional parameter that may be NULL if the
    833833                      required scratch buffer size is 0.
    834834
    835   @retval  RETURN_SUCCESS Decompression completed successfully, and 
     835  @retval  RETURN_SUCCESS Decompression completed successfully, and
    836836                          the uncompressed buffer is returned in Destination.
    837   @retval  RETURN_INVALID_PARAMETER 
    838                           The source buffer specified by Source is corrupted 
     837  @retval  RETURN_INVALID_PARAMETER
     838                          The source buffer specified by Source is corrupted
    839839                          (not in a valid compressed format).
    840840**/
     
    854854  size of an optional scratch buffer required to actually decode the data in a GUIDed section.
    855855
    856   Examines a GUIDed section specified by InputSection. 
     856  Examines a GUIDed section specified by InputSection.
    857857  If GUID for InputSection does not match the GUID that this handler supports,
    858   then RETURN_UNSUPPORTED is returned. 
     858  then RETURN_UNSUPPORTED is returned.
    859859  If the required information can not be retrieved from InputSection,
    860860  then RETURN_INVALID_PARAMETER is returned.
     
    863863  the size of an optional scratch buffer is returned in ScratchSize, and the Attributes field
    864864  from EFI_GUID_DEFINED_SECTION header of InputSection is returned in SectionAttribute.
    865  
     865
    866866  If InputSection is NULL, then ASSERT().
    867867  If OutputBufferSize is NULL, then ASSERT().
     
    906906    }
    907907    //
    908     // Get guid attribute of guid section. 
     908    // Get guid attribute of guid section.
    909909    //
    910910    *SectionAttribute = ((EFI_GUID_DEFINED_SECTION2 *) InputSection)->Attributes;
     
    926926    }
    927927    //
    928     // Get guid attribute of guid section. 
     928    // Get guid attribute of guid section.
    929929    //
    930930    *SectionAttribute = ((EFI_GUID_DEFINED_SECTION *) InputSection)->Attributes;
     
    944944/**
    945945  Decompress a Tiano compressed GUIDed section into a caller allocated output buffer.
    946  
    947   Decodes the GUIDed section specified by InputSection. 
    948   If GUID for InputSection does not match the GUID that this handler supports, then RETURN_UNSUPPORTED is returned. 
     946
     947  Decodes the GUIDed section specified by InputSection.
     948  If GUID for InputSection does not match the GUID that this handler supports, then RETURN_UNSUPPORTED is returned.
    949949  If the data in InputSection can not be decoded, then RETURN_INVALID_PARAMETER is returned.
    950950  If the GUID of InputSection does match the GUID that this handler supports, then InputSection
     
    953953  data in InputSection, then OutputBuffer is set to point at the data in InputSection.  Otherwise,
    954954  the decoded data will be placed in caller allocated buffer specified by OutputBuffer.
    955  
     955
    956956  If InputSection is NULL, then ASSERT().
    957957  If OutputBuffer is NULL, then ASSERT().
     
    961961
    962962  @param[in]  InputSection  A pointer to a GUIDed section of an FFS formatted file.
    963   @param[out] OutputBuffer  A pointer to a buffer that contains the result of a decode operation. 
     963  @param[out] OutputBuffer  A pointer to a buffer that contains the result of a decode operation.
    964964  @param[in] ScratchBuffer  A caller allocated buffer that may be required by this function
    965                             as a scratch buffer to perform the decode operation. 
    966   @param[out] AuthenticationStatus 
     965                            as a scratch buffer to perform the decode operation.
     966  @param[out] AuthenticationStatus
    967967                            A pointer to the authentication status of the decoded output buffer.
    968968                            See the definition of authentication status in the EFI_PEI_GUIDED_SECTION_EXTRACTION_PPI
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/BaseUefiTianoCustomDecompressLib/BaseUefiTianoCustomDecompressLibInternals.h

    r48674 r58466  
    116116  Creates Huffman Code mapping table according to code length array.
    117117
    118   Creates Huffman Code mapping table for Extra Set, Char&Len Set 
     118  Creates Huffman Code mapping table for Extra Set, Char&Len Set
    119119  and Position Set according to code length array.
    120120
     
    142142
    143143  Get a position value according to Position Huffman Table.
    144  
     144
    145145  @param  Sd the global scratch data
    146146
     
    178178/**
    179179  Reads code lengths for Char&Len Set.
    180  
     180
    181181  Read in and decode the Char&Len Set Code Length Array, then
    182182  generate the Huffman Code mapping table for the Char&Len Set.
     
    192192/**
    193193  Decode a character/length value.
    194  
     194
    195195  Read one value from mBitBuf, Get one code from mBitBuf. If it is at block boundary, generates
    196196  Huffman code mapping table for Extra Set, Code&Len Set and
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/DxeCapsuleLib/DxeCapsuleLib.c

    r58459 r58466  
    8383  if (ItemNum == FmpCapsuleHeader->EmbeddedDriverCount) {
    8484    //
    85     // No payload element 
     85    // No payload element
    8686    //
    8787    if (((UINT8 *)FmpCapsuleHeader + ItemOffsetList[ItemNum - 1]) < EndOfCapsule) {
     
    124124
    125125/**
    126   Process Firmware management protocol data capsule. 
     126  Process Firmware management protocol data capsule.
    127127
    128128  @param  CapsuleHeader         Points to a capsule header.
     
    188188
    189189  //
    190   // 1. ConnectAll to ensure 
    191   //    All the communication protocol required by driver in capsule installed 
     190  // 1. ConnectAll to ensure
     191  //    All the communication protocol required by driver in capsule installed
    192192  //    All FMP protocols are installed
    193193  //
     
    196196
    197197  //
    198   // 2. Try to load & start all the drivers within capsule 
     198  // 2. Try to load & start all the drivers within capsule
    199199  //
    200200  SetDevicePathNodeLength (&MemMapNode.Header, sizeof (MemMapNode));
     
    233233
    234234    Status = gBS->StartImage(
    235                     ImageHandle, 
    236                     &ExitDataSize, 
     235                    ImageHandle,
     236                    &ExitDataSize,
    237237                    NULL
    238238                    );
     
    244244
    245245  //
    246   // Connnect all again to connect drivers within capsule 
     246  // Connnect all again to connect drivers within capsule
    247247  //
    248248  if (FmpCapsuleHeader->EmbeddedDriverCount > 0) {
     
    321321      for (Index2 = 0; Index2 < FmpImageInfoCount; Index2++) {
    322322        //
    323         // Check all the payload entry in capsule payload list 
     323        // Check all the payload entry in capsule payload list
    324324        //
    325325        for (Index = FmpCapsuleHeader->EmbeddedDriverCount; Index < ItemNum; Index++) {
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/DxeReportStatusCodeLibFramework/ReportStatusCodeLib.c

    r48674 r58466  
    107107      }
    108108    }
    109  
     109
    110110    //
    111111    // A status code service is present in system, so pass in all the parameters to the service.
     
    113113    return (*mReportStatusCode) (Type, Value, Instance, (EFI_GUID *)CallerId, Data);
    114114  }
    115  
     115
    116116  return EFI_UNSUPPORTED;
    117117}
     
    509509  Tpl = gBS->RaiseTPL (TPL_HIGH_LEVEL);
    510510  gBS->RestoreTPL (Tpl);
    511  
     511
    512512  StatusCodeData = NULL;
    513513  if (Tpl <= TPL_NOTIFY) {
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/GenericBdsLib/BdsBoot.c

    r58460 r58466  
    418418
    419419  FreePool (Buffer);
    420  
     420
    421421  Buffer = NULL;
    422422
     
    579579      }
    580580    }
    581  
     581
    582582    //
    583583    // Skip Non-Legacy boot option
    584     // 
     584    //
    585585    if (!BdsIsLegacyBootOption (BootOptionVar, &BbsEntry, &BbsIndex)) {
    586586      if (BootOptionVar!= NULL) {
     
    789789  Add the legacy boot options from BBS table if they do not exist.
    790790
    791   @retval EFI_SUCCESS          The boot options are added successfully 
     791  @retval EFI_SUCCESS          The boot options are added successfully
    792792                               or they are already in boot options.
    793793  @retval EFI_NOT_FOUND        No legacy boot options is found.
     
    939939  @param BbsCount        The BBS Count.
    940940
    941   @retval EFI_SUCCES             The buffer is created and the EFI variable named 
     941  @retval EFI_SUCCES             The buffer is created and the EFI variable named
    942942                                 VAR_LEGACY_DEV_ORDER and gEfiLegacyDevOrderVariableGuid is
    943943                                 set correctly.
     
    10301030  DevOrderPtr->Length  = (UINT16) (sizeof (UINT16) + HDCount * sizeof (UINT16));
    10311031  DevOrderPtr          = (LEGACY_DEV_ORDER_ENTRY *) BdsFillDevOrderBuf (BbsTable, BBS_HARDDISK, BbsCount, DevOrderPtr->Data);
    1032  
     1032
    10331033  DevOrderPtr->BbsType = BBS_CDROM;
    10341034  DevOrderPtr->Length  = (UINT16) (sizeof (UINT16) + CDCount * sizeof (UINT16));
    10351035  DevOrderPtr          = (LEGACY_DEV_ORDER_ENTRY *) BdsFillDevOrderBuf (BbsTable, BBS_CDROM, BbsCount, DevOrderPtr->Data);
    1036  
     1036
    10371037  DevOrderPtr->BbsType = BBS_EMBED_NETWORK;
    10381038  DevOrderPtr->Length  = (UINT16) (sizeof (UINT16) + NETCount * sizeof (UINT16));
     
    10611061
    10621062/**
    1063   Add the legacy boot devices from BBS table into 
     1063  Add the legacy boot devices from BBS table into
    10641064  the legacy device boot order.
    10651065
     
    12791279  }
    12801280  NewNETPtr = NewPtr->Data;
    1281  
     1281
    12821282  //
    12831283  // copy BEV
     
    15031503
    15041504  @param  Entry             The boot option is to be checked for refresh BBS table.
    1505  
     1505
    15061506  @retval EFI_SUCCESS           The boot priority for BBS entries is refreshed successfully.
    15071507  @retval EFI_NOT_FOUND         BBS entries can't be found.
     
    17051705               TPL_NOTIFY,
    17061706               WriteBootToOsPerformanceData,
    1707                NULL, 
     1707               NULL,
    17081708               &LegacyBootEvent
    17091709               );
     
    25542554      EFI_ERROR_CODE | EFI_ERROR_MINOR,
    25552555      (EFI_SOFTWARE_DXE_BS_DRIVER | EFI_SW_DXE_BS_EC_BOOT_OPTION_LOAD_ERROR)
    2556       );   
     2556      );
    25572557    goto Done;
    25582558  }
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/GenericBdsLib/BdsConnect.c

    r58459 r58466  
    110110  }
    111111  CopyOfDevicePath  = DevicePath;
    112  
     112
    113113  do {
    114114    //
     
    123123      return EFI_OUT_OF_RESOURCES;
    124124    }
    125    
     125
    126126    Next      = Instance;
    127127    while (!IsDevicePathEndType (Next)) {
     
    204204
    205205/**
    206   This function will connect all current system handles recursively. 
    207  
     206  This function will connect all current system handles recursively.
     207
    208208  gBS->ConnectController() service is invoked for each handle exist in system handler buffer.
    209209  If the handle is bus type handler, all childrens also will be connected recursively
     
    248248
    249249/**
    250   This function will disconnect all current system handles. 
    251  
     250  This function will disconnect all current system handles.
     251
    252252  gBS->DisconnectController() is invoked for each handle exists in system handle buffer.
    253253  If handle is a bus type handle, all childrens also are disconnected recursively by
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/GenericBdsLib/BdsMisc.c

    r58460 r58466  
    13591359
    13601360/**
    1361   This routine adjust the memory information for different memory type and 
     1361  This routine adjust the memory information for different memory type and
    13621362  save them into the variables for next boot.
    13631363**/
     
    15711571  @param  VendorGuid             A unique identifier for the vendor.
    15721572  @param  Attributes             Attributes bitmask to set for the variable.
    1573   @param  DataSize               The size in bytes of the Data buffer. Unless the EFI_VARIABLE_APPEND_WRITE, 
    1574                                  EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS, or 
    1575                                  EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS attribute is set, a size of zero 
    1576                                  causes the variable to be deleted. When the EFI_VARIABLE_APPEND_WRITE attribute is 
    1577                                  set, then a SetVariable() call with a DataSize of zero will not cause any change to 
    1578                                  the variable value (the timestamp associated with the variable may be updated however 
    1579                                  even if no new data value is provided,see the description of the 
    1580                                  EFI_VARIABLE_AUTHENTICATION_2 descriptor below. In this case the DataSize will not 
    1581                                  be zero since the EFI_VARIABLE_AUTHENTICATION_2 descriptor will be populated). 
     1573  @param  DataSize               The size in bytes of the Data buffer. Unless the EFI_VARIABLE_APPEND_WRITE,
     1574                                 EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS, or
     1575                                 EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS attribute is set, a size of zero
     1576                                 causes the variable to be deleted. When the EFI_VARIABLE_APPEND_WRITE attribute is
     1577                                 set, then a SetVariable() call with a DataSize of zero will not cause any change to
     1578                                 the variable value (the timestamp associated with the variable may be updated however
     1579                                 even if no new data value is provided,see the description of the
     1580                                 EFI_VARIABLE_AUTHENTICATION_2 descriptor below. In this case the DataSize will not
     1581                                 be zero since the EFI_VARIABLE_AUTHENTICATION_2 descriptor will be populated).
    15821582  @param  Data                   The contents for the variable.
    15831583
     
    15911591  @retval EFI_WRITE_PROTECTED    The variable in question is read-only.
    15921592  @retval EFI_WRITE_PROTECTED    The variable in question cannot be deleted.
    1593   @retval EFI_SECURITY_VIOLATION The variable could not be written due to EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS 
    1594                                  or EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACESS being set, but the AuthInfo 
     1593  @retval EFI_SECURITY_VIOLATION The variable could not be written due to EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS
     1594                                 or EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACESS being set, but the AuthInfo
    15951595                                 does NOT pass the validation check carried out by the firmware.
    15961596
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/GenericBdsLib/GenericBdsLib.inf

    r58459 r58466  
    11## @file
    22#  General BDS library.
    3 # 
     3#
    44#  General BDS defines and produce general interfaces for platform BDS driver including:
    55#  1) BDS boot policy interface;
    66#  2) BDS boot device connect interface;
    77#  3) BDS Misc interfaces for mainting boot variable, ouput string, etc.
    8 # 
     8#
    99#  Copyright (c) 2007 - 2014, Intel Corporation. All rights reserved.<BR>
    1010#  This program and the accompanying materials
     
    1212#  which accompanies this distribution.  The full text of the license may be found at
    1313#  http://opensource.org/licenses/bsd-license.php
    14 # 
     14#
    1515#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1616#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    17 # 
     17#
    1818##
    1919
     
    2525  MODULE_TYPE                    = DXE_DRIVER
    2626  VERSION_STRING                 = 1.0
    27   LIBRARY_CLASS                  = GenericBdsLib|DXE_DRIVER DXE_RUNTIME_DRIVER UEFI_APPLICATION 
     27  LIBRARY_CLASS                  = GenericBdsLib|DXE_DRIVER DXE_RUNTIME_DRIVER UEFI_APPLICATION
    2828  CONSTRUCTOR                    = GenericBdsLibConstructor
    2929
     
    4545  String.c
    4646  GenericBdsStrings.uni
    47  
     47
    4848[Packages]
    4949  MdePkg/MdePkg.dec
     
    7777  ## SOMETIMES_CONSUMES ## Variable:L"MemoryTypeInformation"
    7878  ## SOMETIMES_PRODUCES ## Variable:L"MemoryTypeInformation"
    79   gEfiMemoryTypeInformationGuid                 
     79  gEfiMemoryTypeInformationGuid
    8080  ## SOMETIMES_CONSUMES ## Variable:L"BootXXXX"    # Boot option variable
    8181  ## SOMETIMES_PRODUCES ## Variable:L"BootXXXX"    # Boot option variable
     
    141141
    142142#
    143 # [BootMode] 
     143# [BootMode]
    144144#   RECOVERY_FULL    ## SOMETIMES_CONSUMES # Memory Type Information variable
    145145#
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/GenericBdsLib/GenericBdsStrings.uni

    • Property svn:mime-type changed from application/octet-stream to text/plain;encoding=UTF-16LE
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/GenericBdsLib/InternalBdsLib.h

    r58459 r58466  
    134134
    135135/**
    136   This routine adjust the memory information for different memory type and 
     136  This routine adjust the memory information for different memory type and
    137137  save them into the variables for next boot.
    138138**/
     
    152152
    153153**/
    154 BOOLEAN 
     154BOOLEAN
    155155ValidateOption (
    156156  UINT8                     *Variable,
     
    167167  @param  VendorGuid             A unique identifier for the vendor.
    168168  @param  Attributes             Attributes bitmask to set for the variable.
    169   @param  DataSize               The size in bytes of the Data buffer. Unless the EFI_VARIABLE_APPEND_WRITE, 
    170                                  EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS, or 
    171                                  EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS attribute is set, a size of zero 
    172                                  causes the variable to be deleted. When the EFI_VARIABLE_APPEND_WRITE attribute is 
    173                                  set, then a SetVariable() call with a DataSize of zero will not cause any change to 
    174                                  the variable value (the timestamp associated with the variable may be updated however 
    175                                  even if no new data value is provided,see the description of the 
    176                                  EFI_VARIABLE_AUTHENTICATION_2 descriptor below. In this case the DataSize will not 
    177                                  be zero since the EFI_VARIABLE_AUTHENTICATION_2 descriptor will be populated). 
     169  @param  DataSize               The size in bytes of the Data buffer. Unless the EFI_VARIABLE_APPEND_WRITE,
     170                                 EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS, or
     171                                 EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS attribute is set, a size of zero
     172                                 causes the variable to be deleted. When the EFI_VARIABLE_APPEND_WRITE attribute is
     173                                 set, then a SetVariable() call with a DataSize of zero will not cause any change to
     174                                 the variable value (the timestamp associated with the variable may be updated however
     175                                 even if no new data value is provided,see the description of the
     176                                 EFI_VARIABLE_AUTHENTICATION_2 descriptor below. In this case the DataSize will not
     177                                 be zero since the EFI_VARIABLE_AUTHENTICATION_2 descriptor will be populated).
    178178  @param  Data                   The contents for the variable.
    179179
     
    187187  @retval EFI_WRITE_PROTECTED    The variable in question is read-only.
    188188  @retval EFI_WRITE_PROTECTED    The variable in question cannot be deleted.
    189   @retval EFI_SECURITY_VIOLATION The variable could not be written due to EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS 
    190                                  or EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACESS being set, but the AuthInfo 
     189  @retval EFI_SECURITY_VIOLATION The variable could not be written due to EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS
     190                                 or EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACESS being set, but the AuthInfo
    191191                                 does NOT pass the validation check carried out by the firmware.
    192192
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/GenericBdsLib/Performance.c

    r58459 r58466  
    188188
    189189  Freq    = GetPerformanceCounterProperties (&StartValue, &EndValue);
    190  
     190
    191191  Freq    = DivU64x32 (Freq, 1000);
    192192
     
    252252  PerfEntriesAsDxeHandle = AllocateZeroPool (NumPerfEntries * sizeof (BOOLEAN));
    253253  ASSERT (PerfEntriesAsDxeHandle != NULL);
    254  
     254
    255255  //
    256256  // Get DXE drivers performance
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/LzmaCustomDecompressLib/F86GuidedSectionExtraction.c

    r58464 r58466  
    11/** @file
    2   LZMA Decompress GUIDed Section Extraction Library, which produces LZMA custom 
     2  LZMA Decompress GUIDed Section Extraction Library, which produces LZMA custom
    33  decompression algorithm with the converter for the different arch code.
    44  It wraps Lzma decompress interfaces to GUIDed Section Extraction interfaces
     
    2323  size of an scratch buffer required to actually decode the data in a GUIDed section.
    2424
    25   Examines a GUIDed section specified by InputSection. 
     25  Examines a GUIDed section specified by InputSection.
    2626  If GUID for InputSection does not match the GUID that this handler supports,
    27   then RETURN_UNSUPPORTED is returned. 
     27  then RETURN_UNSUPPORTED is returned.
    2828  If the required information can not be retrieved from InputSection,
    2929  then RETURN_INVALID_PARAMETER is returned.
     
    3232  the size of an optional scratch buffer is returned in ScratchSize, and the Attributes field
    3333  from EFI_GUID_DEFINED_SECTION header of InputSection is returned in SectionAttribute.
    34  
     34
    3535  If InputSection is NULL, then ASSERT().
    3636  If OutputBufferSize is NULL, then ASSERT().
     
    101101/**
    102102  Decompress a LZAM compressed GUIDed section into a caller allocated output buffer.
    103  
    104   Decodes the GUIDed section specified by InputSection. 
    105   If GUID for InputSection does not match the GUID that this handler supports, then RETURN_UNSUPPORTED is returned. 
     103
     104  Decodes the GUIDed section specified by InputSection.
     105  If GUID for InputSection does not match the GUID that this handler supports, then RETURN_UNSUPPORTED is returned.
    106106  If the data in InputSection can not be decoded, then RETURN_INVALID_PARAMETER is returned.
    107107  If the GUID of InputSection does match the GUID that this handler supports, then InputSection
     
    110110  data in InputSection, then OutputBuffer is set to point at the data in InputSection.  Otherwise,
    111111  the decoded data will be placed in caller allocated buffer specified by OutputBuffer.
    112  
     112
    113113  If InputSection is NULL, then ASSERT().
    114114  If OutputBuffer is NULL, then ASSERT().
     
    118118
    119119  @param[in]  InputSection  A pointer to a GUIDed section of an FFS formatted file.
    120   @param[out] OutputBuffer  A pointer to a buffer that contains the result of a decode operation. 
     120  @param[out] OutputBuffer  A pointer to a buffer that contains the result of a decode operation.
    121121  @param[out] ScratchBuffer A caller allocated buffer that may be required by this function
    122                             as a scratch buffer to perform the decode operation. 
    123   @param[out] AuthenticationStatus 
     122                            as a scratch buffer to perform the decode operation.
     123  @param[out] AuthenticationStatus
    124124                            A pointer to the authentication status of the decoded output buffer.
    125125                            See the definition of authentication status in the EFI_PEI_GUIDED_SECTION_EXTRACTION_PPI
     
    148148  UINT32            OutputBufferSize;
    149149  UINT32            ScratchBufferSize;
    150  
     150
    151151  ASSERT (OutputBuffer != NULL);
    152152  ASSERT (InputSection != NULL);
     
    179179
    180180  //
    181   // After decompress, the data need to be converted to the raw data. 
     181  // After decompress, the data need to be converted to the raw data.
    182182  //
    183183  if (!EFI_ERROR (Status)) {
     
    188188             &ScratchBufferSize
    189189             );
    190    
     190
    191191    if (!EFI_ERROR (Status)) {
    192192      x86_Convert_Init(X86State);
     
    194194    }
    195195  }
    196  
     196
    197197  return Status;
    198198}
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/LzmaCustomDecompressLib/GuidedSectionExtraction.c

    r48674 r58466  
    2121  size of an scratch buffer required to actually decode the data in a GUIDed section.
    2222
    23   Examines a GUIDed section specified by InputSection. 
     23  Examines a GUIDed section specified by InputSection.
    2424  If GUID for InputSection does not match the GUID that this handler supports,
    25   then RETURN_UNSUPPORTED is returned. 
     25  then RETURN_UNSUPPORTED is returned.
    2626  If the required information can not be retrieved from InputSection,
    2727  then RETURN_INVALID_PARAMETER is returned.
     
    3030  the size of an optional scratch buffer is returned in ScratchSize, and the Attributes field
    3131  from EFI_GUID_DEFINED_SECTION header of InputSection is returned in SectionAttribute.
    32  
     32
    3333  If InputSection is NULL, then ASSERT().
    3434  If OutputBufferSize is NULL, then ASSERT().
     
    9999/**
    100100  Decompress a LZAM compressed GUIDed section into a caller allocated output buffer.
    101  
    102   Decodes the GUIDed section specified by InputSection. 
    103   If GUID for InputSection does not match the GUID that this handler supports, then RETURN_UNSUPPORTED is returned. 
     101
     102  Decodes the GUIDed section specified by InputSection.
     103  If GUID for InputSection does not match the GUID that this handler supports, then RETURN_UNSUPPORTED is returned.
    104104  If the data in InputSection can not be decoded, then RETURN_INVALID_PARAMETER is returned.
    105105  If the GUID of InputSection does match the GUID that this handler supports, then InputSection
     
    108108  data in InputSection, then OutputBuffer is set to point at the data in InputSection.  Otherwise,
    109109  the decoded data will be placed in caller allocated buffer specified by OutputBuffer.
    110  
     110
    111111  If InputSection is NULL, then ASSERT().
    112112  If OutputBuffer is NULL, then ASSERT().
     
    116116
    117117  @param[in]  InputSection  A pointer to a GUIDed section of an FFS formatted file.
    118   @param[out] OutputBuffer  A pointer to a buffer that contains the result of a decode operation. 
     118  @param[out] OutputBuffer  A pointer to a buffer that contains the result of a decode operation.
    119119  @param[out] ScratchBuffer A caller allocated buffer that may be required by this function
    120                             as a scratch buffer to perform the decode operation. 
    121   @param[out] AuthenticationStatus 
     120                            as a scratch buffer to perform the decode operation.
     121  @param[out] AuthenticationStatus
    122122                            A pointer to the authentication status of the decoded output buffer.
    123123                            See the definition of authentication status in the EFI_PEI_GUIDED_SECTION_EXTRACTION_PPI
     
    197197          LzmaGuidedSectionGetInfo,
    198198          LzmaGuidedSectionExtraction
    199           );     
     199          );
    200200}
    201201
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/LzmaCustomDecompressLib/LzmaArchCustomDecompressLib.inf

    r58464 r58466  
    4444  Sdk/C/LzHash.h
    4545  Sdk/C/LzmaDec.h
    46   Sdk/C/Types.h 
     46  Sdk/C/Types.h
    4747  UefiLzma.h
    4848  LzmaDecompressLibInternal.h
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/LzmaCustomDecompressLib/LzmaCustomDecompressLib.inf

    r58459 r58466  
    4343  Sdk/C/LzHash.h
    4444  Sdk/C/LzmaDec.h
    45   Sdk/C/Types.h 
     45  Sdk/C/Types.h
    4646  GuidedSectionExtraction.c
    4747  UefiLzma.h
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/LzmaCustomDecompressLib/LzmaDecompress.c

    r48674 r58466  
    106106
    107107/**
    108   Given a Lzma compressed source buffer, this function retrieves the size of 
    109   the uncompressed buffer and the size of the scratch buffer required 
     108  Given a Lzma compressed source buffer, this function retrieves the size of
     109  the uncompressed buffer and the size of the scratch buffer required
    110110  to decompress the compressed source buffer.
    111111
    112   Retrieves the size of the uncompressed buffer and the temporary scratch buffer 
     112  Retrieves the size of the uncompressed buffer and the temporary scratch buffer
    113113  required to decompress the buffer specified by Source and SourceSize.
    114   The size of the uncompressed buffer is returned in DestinationSize, 
     114  The size of the uncompressed buffer is returned in DestinationSize,
    115115  the size of the scratch buffer is returned in ScratchSize, and RETURN_SUCCESS is returned.
    116   This function does not have scratch buffer available to perform a thorough 
     116  This function does not have scratch buffer available to perform a thorough
    117117  checking of the validity of the source data. It just retrieves the "Original Size"
    118118  field from the LZMA_HEADER_SIZE beginning bytes of the source data and output it as DestinationSize.
     
    127127                          by Source and SourceSize is decompressed.
    128128  @param  ScratchSize     A pointer to the size, in bytes, of the scratch buffer that
    129                           is required to decompress the compressed buffer specified 
     129                          is required to decompress the compressed buffer specified
    130130                          by Source and SourceSize.
    131131
    132   @retval  RETURN_SUCCESS The size of the uncompressed data was returned 
    133                           in DestinationSize and the size of the scratch 
     132  @retval  RETURN_SUCCESS The size of the uncompressed data was returned
     133                          in DestinationSize and the size of the scratch
    134134                          buffer was returned in ScratchSize.
    135135
     
    159159
    160160  Extracts decompressed data to its original form.
    161   If the compressed source data specified by Source is successfully decompressed 
    162   into Destination, then RETURN_SUCCESS is returned.  If the compressed source data 
     161  If the compressed source data specified by Source is successfully decompressed
     162  into Destination, then RETURN_SUCCESS is returned.  If the compressed source data
    163163  specified by Source is not in a valid compressed data format,
    164164  then RETURN_INVALID_PARAMETER is returned.
     
    168168  @param  Destination The destination buffer to store the decompressed data
    169169  @param  Scratch     A temporary scratch buffer that is used to perform the decompression.
    170                       This is an optional parameter that may be NULL if the 
     170                      This is an optional parameter that may be NULL if the
    171171                      required scratch buffer size is 0.
    172                      
    173   @retval  RETURN_SUCCESS Decompression completed successfully, and 
     172
     173  @retval  RETURN_SUCCESS Decompression completed successfully, and
    174174                          the uncompressed buffer is returned in Destination.
    175   @retval  RETURN_INVALID_PARAMETER 
    176                           The source buffer specified by Source is corrupted 
     175  @retval  RETURN_INVALID_PARAMETER
     176                          The source buffer specified by Source is corrupted
    177177                          (not in a valid compressed format).
    178178**/
     
    196196  AllocFuncs.Buffer           = Scratch;
    197197  AllocFuncs.BufferSize       = SCRATCH_BUFFER_REQUEST_SIZE;
    198  
     198
    199199  DecodedBufSize = (SizeT)GetDecodedSizeOfBuf((UINT8*)Source);
    200200  EncodedDataSize = (SizeT) (SourceSize - LZMA_HEADER_SIZE);
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/LzmaCustomDecompressLib/LzmaDecompressLibInternal.h

    r48674 r58466  
    2424
    2525/**
    26   Given a Lzma compressed source buffer, this function retrieves the size of 
    27   the uncompressed buffer and the size of the scratch buffer required 
     26  Given a Lzma compressed source buffer, this function retrieves the size of
     27  the uncompressed buffer and the size of the scratch buffer required
    2828  to decompress the compressed source buffer.
    2929
    30   Retrieves the size of the uncompressed buffer and the temporary scratch buffer 
     30  Retrieves the size of the uncompressed buffer and the temporary scratch buffer
    3131  required to decompress the buffer specified by Source and SourceSize.
    32   The size of the uncompressed buffer is returned in DestinationSize, 
     32  The size of the uncompressed buffer is returned in DestinationSize,
    3333  the size of the scratch buffer is returned in ScratchSize, and RETURN_SUCCESS is returned.
    34   This function does not have scratch buffer available to perform a thorough 
     34  This function does not have scratch buffer available to perform a thorough
    3535  checking of the validity of the source data. It just retrieves the "Original Size"
    3636  field from the LZMA_HEADER_SIZE beginning bytes of the source data and output it as DestinationSize.
     
    4545                          by Source and SourceSize is decompressed.
    4646  @param  ScratchSize     A pointer to the size, in bytes, of the scratch buffer that
    47                           is required to decompress the compressed buffer specified 
     47                          is required to decompress the compressed buffer specified
    4848                          by Source and SourceSize.
    4949
    50   @retval  RETURN_SUCCESS The size of the uncompressed data was returned 
    51                           in DestinationSize and the size of the scratch 
     50  @retval  RETURN_SUCCESS The size of the uncompressed data was returned
     51                          in DestinationSize and the size of the scratch
    5252                          buffer was returned in ScratchSize.
    5353
     
    6666
    6767  Extracts decompressed data to its original form.
    68   If the compressed source data specified by Source is successfully decompressed 
    69   into Destination, then RETURN_SUCCESS is returned.  If the compressed source data 
     68  If the compressed source data specified by Source is successfully decompressed
     69  into Destination, then RETURN_SUCCESS is returned.  If the compressed source data
    7070  specified by Source is not in a valid compressed data format,
    7171  then RETURN_INVALID_PARAMETER is returned.
     
    7575  @param  Destination The destination buffer to store the decompressed data
    7676  @param  Scratch     A temporary scratch buffer that is used to perform the decompression.
    77                       This is an optional parameter that may be NULL if the 
     77                      This is an optional parameter that may be NULL if the
    7878                      required scratch buffer size is 0.
    79                      
    80   @retval  RETURN_SUCCESS Decompression completed successfully, and 
     79
     80  @retval  RETURN_SUCCESS Decompression completed successfully, and
    8181                          the uncompressed buffer is returned in Destination.
    82   @retval  RETURN_INVALID_PARAMETER 
    83                           The source buffer specified by Source is corrupted 
     82  @retval  RETURN_INVALID_PARAMETER
     83                          The source buffer specified by Source is corrupted
    8484                          (not in a valid compressed format).
    8585**/
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/Bra.h

    r58464 r58466  
    1010These functions convert relative addresses to absolute addresses
    1111in CALL instructions to increase the compression ratio.
    12  
     12
    1313  In:
    1414    data     - data buffer
     
    1717    state    - state variable for x86 converter
    1818    encoding - 0 (for decoding), 1 (for encoding)
    19  
     19
    2020  Out:
    2121    state    - state variable for x86 converter
     
    2424    The number of processed bytes. If you call these functions with multiple calls,
    2525    you must start next call with first byte after block of processed bytes.
    26  
     26
    2727  Type   Endian  Alignment  LookAhead
    28  
     28
    2929  x86    little      1          4
    3030  ARMT   little      2          2
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzFind.c

    r48674 r58466  
    522522  delta2 = p->pos - p->hash[hash2Value];
    523523  curMatch = p->hash[kFix3HashSize + hashValue];
    524  
     524
    525525  p->hash[hash2Value] =
    526526  p->hash[kFix3HashSize + hashValue] = p->pos;
     
    556556  delta3 = p->pos - p->hash[kFix3HashSize + hash3Value];
    557557  curMatch = p->hash[kFix4HashSize + hashValue];
    558  
     558
    559559  p->hash[                hash2Value] =
    560560  p->hash[kFix3HashSize + hash3Value] =
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzmaDec.c

    r48674 r58466  
    167167  SizeT dicBufSize = p->dicBufSize;
    168168  SizeT dicPos = p->dicPos;
    169  
     169
    170170  UInt32 processedPos = p->processedPos;
    171171  UInt32 checkDicSize = p->checkDicSize;
     
    351351              NORMALIZE
    352352              range >>= 1;
    353              
     353
    354354              {
    355355                UInt32 t;
     
    749749  (*srcLen) = 0;
    750750  LzmaDec_WriteRem(p, dicLimit);
    751  
     751
    752752  *status = LZMA_STATUS_NOT_SPECIFIED;
    753753
     
    795795      if (p->needInitState)
    796796        LzmaDec_InitStateReal(p);
    797  
     797
    798798      if (p->tempBufSize == 0)
    799799      {
     
    926926  UInt32 dicSize;
    927927  Byte d;
    928  
     928
    929929  if (size < LZMA_PROPS_SIZE)
    930930    return SZ_ERROR_UNSUPPORTED;
    931931  else
    932932    dicSize = data[1] | ((UInt32)data[2] << 8) | ((UInt32)data[3] << 16) | ((UInt32)data[4] << 24);
    933  
     933
    934934  if (dicSize < LZMA_DIC_MIN)
    935935    dicSize = LZMA_DIC_MIN;
     
    10131013
    10141014  LzmaDec_Init(&p);
    1015  
     1015
    10161016  *srcLen = inSize;
    10171017  res = LzmaDec_DecodeToDic(&p, outSize, src, srcLen, finishMode, status);
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/LzmaCustomDecompressLib/Sdk/C/LzmaDec.h

    r48674 r58466  
    127127  SZ_ERROR_UNSUPPORTED - Unsupported properties
    128128*/
    129    
     129
    130130SRes LzmaDec_AllocateProbs(CLzmaDec *p, const Byte *props, unsigned propsSize, ISzAlloc *alloc);
    131131void LzmaDec_FreeProbs(CLzmaDec *p, ISzAlloc *alloc);
     
    156156
    157157/* LzmaDec_DecodeToDic
    158    
     158
    159159   The decoding to internal dictionary buffer (CLzmaDec::dic).
    160160   You must manually update CLzmaDec::dicPos, if it reaches CLzmaDec::dicBufSize !!!
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/LzmaCustomDecompressLib/Sdk/history.txt

    r48674 r58466  
    1515-------------------------
    1616- The bug in ANSI-C LZMA Decoder was fixed:
    17     If encoded stream was corrupted, decoder could access memory 
     17    If encoded stream was corrupted, decoder could access memory
    1818    outside of allocated range.
    1919- Some changes in ANSI-C 7z Decoder interfaces.
     
    2929-------------------------
    3030- The bug was fixed:
    31     LZMA Encoder in fast compression mode could access memory outside of 
     31    LZMA Encoder in fast compression mode could access memory outside of
    3232    allocated range in some rare cases.
    3333
     
    42424.57           2007-12-12
    4343-------------------------
    44 - Speed optimizations in Ñ++ LZMA Decoder. 
     44- Speed optimizations in Ñ++ LZMA Decoder.
    4545- Small changes for more compatibility with some C/C++ compilers.
    4646
     
    5252     - now it supports files larger than 4 GB.
    5353     - now it supports "Last Write Time" field for files.
    54 - C++ code for .7z archives compressing/decompressing from 7-zip 
     54- C++ code for .7z archives compressing/decompressing from 7-zip
    5555  was included to LZMA SDK.
    56  
     56
    5757
    58584.43           2006-06-04
    5959-------------------------
    6060- Small changes for more compatibility with some C/C++ compilers.
    61  
     61
    6262
    63634.42           2006-05-15
    6464-------------------------
    6565- Small changes in .h files in ANSI-C version.
    66  
     66
    6767
    68684.39 beta      2006-04-14
    6969-------------------------
    7070- The bug in versions 4.33b:4.38b was fixed:
    71   C++ version of LZMA encoder could not correctly compress 
     71  C++ version of LZMA encoder could not correctly compress
    7272  files larger than 2 GB with HC4 match finder (-mfhc4).
    73  
     73
    7474
    75754.37 beta      2005-04-06
    7676-------------------------
    77 - Fixes in C++ code: code could no be compiled if _NO_EXCEPTIONS was defined. 
     77- Fixes in C++ code: code could no be compiled if _NO_EXCEPTIONS was defined.
    7878
    7979
     
    8181-------------------------
    8282- The bug was fixed in C++ version of LZMA Decoder:
    83     If encoded stream was corrupted, decoder could access memory 
     83    If encoded stream was corrupted, decoder could access memory
    8484    outside of allocated range.
    8585
     
    1521524.17           2005-04-18
    153153-------------------------
    154 - New example for RAM->RAM compressing/decompressing: 
     154- New example for RAM->RAM compressing/decompressing:
    155155  LZMA + BCJ (filter for x86 code):
    156156    - LzmaRam.h
     
    1631634.16           2005-03-29
    164164-------------------------
    165 - The bug was fixed in LzmaDecode.c (ANSI-C LZMA Decoder): 
     165- The bug was fixed in LzmaDecode.c (ANSI-C LZMA Decoder):
    166166   If _LZMA_OUT_READ was defined, and if encoded stream was corrupted,
    167167   decoder could access memory outside of allocated range.
    168168- Speed optimization of ANSI-C LZMA Decoder (now it's about 20% faster).
    169   Old version of LZMA Decoder now is in file LzmaDecodeSize.c. 
     169  Old version of LZMA Decoder now is in file LzmaDecodeSize.c.
    170170  LzmaDecodeSize.c can provide slightly smaller code than LzmaDecode.c
    171171- Small speed optimization in LZMA C++ code
     
    1821824.05           2004-08-25
    183183-------------------------
    184 - Source code of filters for x86, IA-64, ARM, ARM-Thumb 
     184- Source code of filters for x86, IA-64, ARM, ARM-Thumb
    185185  and PowerPC code was included to SDK
    186186- Some internal minor changes
     
    1941944.03           2004-06-18
    195195-------------------------
    196 - "Benchmark" command was added. It measures compressing 
    197   and decompressing speed and shows rating values. 
     196- "Benchmark" command was added. It measures compressing
     197  and decompressing speed and shows rating values.
    198198  Also it checks hardware errors.
    199199
     
    224224HISTORY of the LZMA
    225225-------------------
    226   2001-2008:  Improvements to LZMA compressing/decompressing code, 
     226  2001-2008:  Improvements to LZMA compressing/decompressing code,
    227227              keeping compatibility with original LZMA format
    228228  1996-2001:  Development of LZMA compression format
     
    232232  2001-08-30: LZMA compression was added to 7-Zip
    233233  1999-01-02: First version of 7-Zip was released
    234  
     234
    235235
    236236End of document
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/LzmaCustomDecompressLib/Sdk/lzma.txt

    r48674 r58466  
    22-------------
    33
    4 LZMA SDK provides the documentation, samples, header files, libraries, 
     4LZMA SDK provides the documentation, samples, header files, libraries,
    55and tools you need to develop applications that use LZMA compression.
    66
    77LZMA is default and general compression method of 7z format
    8 in 7-Zip compression program (www.7-zip.org). LZMA provides high 
     8in 7-Zip compression program (www.7-zip.org). LZMA provides high
    99compression ratio and very fast decompression.
    1010
    11 LZMA is an improved version of famous LZ77 compression algorithm. 
     11LZMA is an improved version of famous LZ77 compression algorithm.
    1212It was improved in way of maximum increasing of compression ratio,
    13 keeping high decompression speed and low memory requirements for 
     13keeping high decompression speed and low memory requirements for
    1414decompressing.
    1515
     
    3131
    3232
    33 UNIX/Linux version 
     33UNIX/Linux version
    3434------------------
    3535To compile C++ version of file->file LZMA encoding, go to directory
    36 C++/7zip/Compress/LZMA_Alone 
     36C++/7zip/Compress/LZMA_Alone
    3737and call make to recompile it:
    3838  make -f makefile.gcc clean all
    3939
    4040In some UNIX/Linux versions you must compile LZMA with static libraries.
    41 To compile with static libraries, you can use 
     41To compile with static libraries, you can use
    4242LIB = -lm -static
    4343
     
    6060        Alloc.*    - Memory allocation functions
    6161        Bra*.*     - Filters for x86, IA-64, ARM, ARM-Thumb, PowerPC and SPARC code
    62         LzFind.*   - Match finder for LZ (LZMA) encoders 
     62        LzFind.*   - Match finder for LZ (LZMA) encoders
    6363        LzFindMt.* - Match finder for LZ (LZMA) encoders for multithreading encoding
    6464        LzHash.h   - Additional file for LZ match finder
     
    7070
    7171    LzmaLib  - LZMA Library (.DLL for Windows)
    72    
     72
    7373    LzmaUtil - LZMA Utility (file->file LZMA encoder/decoder).
    7474
     
    9999
    100100    Bundles    - Modules that are bundles of other modules
    101  
     101
    102102      Alone7z           - 7zr.exe: Standalone version of 7z.exe that supports only 7z/LZMA/BCJ/BCJ2
    103103      Format7zR         - 7zr.dll: Reduced version of 7za.dll: extracting/compressing to 7z/LZMA/BCJ/BCJ2
     
    105105
    106106    UI        - User Interface files
    107          
     107
    108108      Client7z - Test application for 7za.dll,  7zr.dll, 7zxr.dll
    109109      Common   - Common UI files
     
    140140  - Variable dictionary size (up to 1 GB)
    141141  - Estimated compressing speed: about 2 MB/s on 2 GHz CPU
    142   - Estimated decompressing speed: 
     142  - Estimated decompressing speed:
    143143      - 20-30 MB/s on 2 GHz Core 2 or AMD Athlon 64
    144144      - 1-2 MB/s on 200 MHz ARM, MIPS, PowerPC or other simple RISC
     
    146146  - Small code size for decompressing: 5-8 KB
    147147
    148 LZMA decoder uses only integer operations and can be 
     148LZMA decoder uses only integer operations and can be
    149149implemented in any modern 32-bit CPU (or on 16-bit CPU with some conditions).
    150150
     
    155155
    156156The speed of LZMA decompressing mostly depends from CPU speed.
    157 Memory speed has no big meaning. But if your CPU has small data cache, 
     157Memory speed has no big meaning. But if your CPU has small data cache,
    158158overall weight of memory speed will slightly increase.
    159159
     
    171171  d: decode file
    172172
    173   b: Benchmark. There are two tests: compressing and decompressing 
    174      with LZMA method. Benchmark shows rating in MIPS (million 
    175      instructions per second). Rating value is calculated from 
     173  b: Benchmark. There are two tests: compressing and decompressing
     174     with LZMA method. Benchmark shows rating in MIPS (million
     175     instructions per second). Rating value is calculated from
    176176     measured speed and it is normalized with Intel's Core 2 results.
    177      Also Benchmark checks possible hardware errors (RAM 
     177     Also Benchmark checks possible hardware errors (RAM
    178178     errors in most cases). Benchmark uses these settings:
    179      (-a1, -d21, -fb32, -mfbt4). You can change only -d parameter. 
     179     (-a1, -d21, -fb32, -mfbt4). You can change only -d parameter.
    180180     Also you can change the number of iterations. Example for 30 iterations:
    181181       LZMA b 30
     
    183183
    184184<Switches>
    185  
     185
    186186
    187187  -a{N}:  set compression mode 0 = fast, 1 = normal
     
    190190  d{N}:   Sets Dictionary size - [0, 30], default: 23 (8MB)
    191191          The maximum value for dictionary size is 1 GB = 2^30 bytes.
    192           Dictionary size is calculated as DictionarySize = 2^N bytes. 
    193           For decompressing file compressed by LZMA method with dictionary 
     192          Dictionary size is calculated as DictionarySize = 2^N bytes.
     193          For decompressing file compressed by LZMA method with dictionary
    194194          size D = 2^N you need about D bytes of memory (RAM).
    195195
    196196  -fb{N}: set number of fast bytes - [5, 273], default: 128
    197           Usually big number gives a little bit better compression ratio 
     197          Usually big number gives a little bit better compression ratio
    198198          and slower compression process.
    199199
     
    202202
    203203  -lp{N}: set number of literal pos bits - [0, 4], default: 0
    204           lp switch is intended for periodical data when period is 
    205           equal 2^N. For example, for 32-bit (4 bytes) 
    206           periodical data you can use lp=2. Often it's better to set lc0, 
     204          lp switch is intended for periodical data when period is
     205          equal 2^N. For example, for 32-bit (4 bytes)
     206          periodical data you can use lp=2. Often it's better to set lc0,
    207207          if you change lp switch.
    208208
    209209  -pb{N}: set number of pos bits - [0, 4], default: 2
    210           pb switch is intended for periodical data 
     210          pb switch is intended for periodical data
    211211          when period is equal 2^N.
    212212
    213   -mf{MF_ID}: set Match Finder. Default: bt4. 
    214               Algorithms from hc* group doesn't provide good compression 
    215               ratio, but they often works pretty fast in combination with 
     213  -mf{MF_ID}: set Match Finder. Default: bt4.
     214              Algorithms from hc* group doesn't provide good compression
     215              ratio, but they often works pretty fast in combination with
    216216              fast mode (-a0).
    217217
    218               Memory requirements depend from dictionary size 
    219               (parameter "d" in table below). 
     218              Memory requirements depend from dictionary size
     219              (parameter "d" in table below).
    220220
    221221               MF_ID     Memory                   Description
     
    226226                hc4    d *  7.5 + 4MB  Hash Chain with 4 bytes hashing.
    227227
    228   -eos:   write End Of Stream marker. By default LZMA doesn't write 
    229           eos marker, since LZMA decoder knows uncompressed size 
     228  -eos:   write End Of Stream marker. By default LZMA doesn't write
     229          eos marker, since LZMA decoder knows uncompressed size
    230230          stored in .lzma file header.
    231231
     
    236236Examples:
    237237
    238 1) LZMA e file.bin file.lzma -d16 -lc0 
    239 
    240 compresses file.bin to file.lzma with 64 KB dictionary (2^16=64K) 
    241 and 0 literal context bits. -lc0 allows to reduce memory requirements 
     2381) LZMA e file.bin file.lzma -d16 -lc0
     239
     240compresses file.bin to file.lzma with 64 KB dictionary (2^16=64K)
     241and 0 literal context bits. -lc0 allows to reduce memory requirements
    242242for decompression.
    243243
     
    2452452) LZMA e file.bin file.lzma -lc0 -lp2
    246246
    247 compresses file.bin to file.lzma with settings suitable 
     247compresses file.bin to file.lzma with settings suitable
    248248for 32-bit periodical data (for example, ARM or MIPS code).
    249249
     
    259259---------------
    260260
    261 To increase the compression ratio for LZMA compressing it's desirable 
     261To increase the compression ratio for LZMA compressing it's desirable
    262262to have aligned data (if it's possible) and also it's desirable to locate
    263 data in such order, where code is grouped in one place and data is 
     263data in such order, where code is grouped in one place and data is
    264264grouped in other place (it's better than such mixing: code, data, code,
    265265data, ...).
     
    269269-------
    270270You can increase the compression ratio for some data types, using
    271 special filters before compressing. For example, it's possible to 
    272 increase the compression ratio on 5-10% for code for those CPU ISAs: 
     271special filters before compressing. For example, it's possible to
     272increase the compression ratio on 5-10% for code for those CPU ISAs:
    273273x86, IA-64, ARM, ARM-Thumb, PowerPC, SPARC.
    274274
    275275You can find C source code of such filters in C/Bra*.* files
    276276
    277 You can check the compression ratio gain of these filters with such 
     277You can check the compression ratio gain of these filters with such
    2782787-Zip commands (example for ARM code):
    279279No filter:
     
    281281
    282282With filter for little-endian ARM code:
    283   7z a a2.7z a.bin -m0=arm -m1=lzma       
     283  7z a a2.7z a.bin -m0=arm -m1=lzma
    284284
    285285It works in such manner:
     
    289289Compressing and decompressing speed of such filters is very high,
    290290so it will not increase decompressing time too much.
    291 Moreover, it reduces decompression time for LZMA_decoding, 
     291Moreover, it reduces decompression time for LZMA_decoding,
    292292since compression ratio with filtering is higher.
    293293
    294 These filters convert CALL (calling procedure) instructions 
    295 from relative offsets to absolute addresses, so such data becomes more 
     294These filters convert CALL (calling procedure) instructions
     295from relative offsets to absolute addresses, so such data becomes more
    296296compressible.
    297297
     
    323323-------------------------------------
    324324
    325 Stack usage of LZMA decoding function for local variables is not 
     325Stack usage of LZMA decoding function for local variables is not
    326326larger than 200-400 bytes.
    327327
     
    356356  - Input buffer: compressed size
    357357  - Output buffer: uncompressed size
    358   - LZMA Internal Structures: state_size (16 KB for default settings) 
     358  - LZMA Internal Structures: state_size (16 KB for default settings)
    359359
    360360Interface:
    361361  int LzmaDecode(Byte *dest, SizeT *destLen, const Byte *src, SizeT *srcLen,
    362       const Byte *propData, unsigned propSize, ELzmaFinishMode finishMode, 
     362      const Byte *propData, unsigned propSize, ELzmaFinishMode finishMode,
    363363      ELzmaStatus *status, ISzAlloc *alloc);
    364   In: 
     364  In:
    365365    dest     - output data
    366366    destLen  - output data size
     
    372372         LZMA_FINISH_ANY - Decode just destLen bytes.
    373373         LZMA_FINISH_END - Stream must be finished after (*destLen).
    374                            You can use LZMA_FINISH_END, when you know that 
    375                            current output buffer covers last bytes of stream. 
     374                           You can use LZMA_FINISH_END, when you know that
     375                           current output buffer covers last bytes of stream.
    376376    alloc    - Memory allocator.
    377377
    378   Out: 
    379     destLen  - processed output size 
    380     srcLen   - processed input size 
     378  Out:
     379    destLen  - processed output size
     380    srcLen   - processed input size
    381381
    382382  Output:
     
    384384      status:
    385385        LZMA_STATUS_FINISHED_WITH_MARK
    386         LZMA_STATUS_NOT_FINISHED 
     386        LZMA_STATUS_NOT_FINISHED
    387387        LZMA_STATUS_MAYBE_FINISHED_WITHOUT_MARK
    388388    SZ_ERROR_DATA - Data error
     
    397397    1) Check Result and "status" variable.
    398398    2) Check that output(destLen) = uncompressedSize, if you know real uncompressedSize.
    399     3) Check that output(srcLen) = compressedSize, if you know real compressedSize. 
    400        You must use correct finish mode in that case. */ 
     399    3) Check that output(srcLen) = compressedSize, if you know real compressedSize.
     400       You must use correct finish mode in that case. */
    401401
    402402
     
    404404----------------------------------------------------
    405405
    406 When to use: file->file decompressing 
     406When to use: file->file decompressing
    407407Compile files: LzmaDec.h + LzmaDec.c + Types.h
    408408
     
    410410 - Buffer for input stream: any size (for example, 16 KB)
    411411 - Buffer for output stream: any size (for example, 16 KB)
    412  - LZMA Internal Structures: state_size (16 KB for default settings) 
     412 - LZMA Internal Structures: state_size (16 KB for default settings)
    413413 - LZMA dictionary (dictionary size is encoded in LZMA properties header)
    414414
     
    430430  for (;;)
    431431  {
    432     ... 
    433     int res = LzmaDec_DecodeToBuf(CLzmaDec *p, Byte *dest, SizeT *destLen, 
     432    ...
     433    int res = LzmaDec_DecodeToBuf(CLzmaDec *p, Byte *dest, SizeT *destLen,
    434434        const Byte *src, SizeT *srcLen, ELzmaFinishMode finishMode);
    435435    ...
     
    4564562) allocBig - for big arrays.
    457457
    458 For example, you can use Large RAM Pages (2 MB) in allocBig allocator for 
    459 better compression speed. Note that Windows has bad implementation for 
    460 Large RAM Pages. 
     458For example, you can use Large RAM Pages (2 MB) in allocBig allocator for
     459better compression speed. Note that Windows has bad implementation for
     460Large RAM Pages.
    461461It's OK to use same allocator for alloc and allocBig.
    462462
     
    465465--------------------------------------
    466466
    467 Check C/LzmaUtil/LzmaUtil.c as example, 
    468 
    469 When to use: file->file decompressing 
     467Check C/LzmaUtil/LzmaUtil.c as example,
     468
     469When to use: file->file decompressing
    470470
    4714711) you must implement callback structures for interfaces:
     
    521521
    5225226) Call encoding function:
    523       res = LzmaEnc_Encode(enc, &outStream.funcTable, &inStream.funcTable, 
     523      res = LzmaEnc_Encode(enc, &outStream.funcTable, &inStream.funcTable,
    524524        NULL, &g_Alloc, &g_Alloc);
    525525
     
    538538
    539539HRes LzmaEncode(Byte *dest, SizeT *destLen, const Byte *src, SizeT srcLen,
    540     CLzmaEncProps *props, Byte *propsEncoded, SizeT *propsSize, int writeEndMark, 
     540    CLzmaEncProps *props, Byte *propsEncoded, SizeT *propsSize, int writeEndMark,
    541541    ICompressProgress *progress, ISzAlloc *alloc, ISzAlloc *allocBig);
    542542
    543543Return code:
    544544  SZ_OK               - OK
    545   SZ_ERROR_MEM        - Memory allocation error 
     545  SZ_ERROR_MEM        - Memory allocation error
    546546  SZ_ERROR_PARAM      - Incorrect paramater
    547547  SZ_ERROR_OUTPUT_EOF - output buffer overflow
     
    555555_LZMA_SIZE_OPT - Enable some optimizations in LZMA Decoder to get smaller executable code.
    556556
    557 _LZMA_PROB32   - It can increase the speed on some 32-bit CPUs, but memory usage for 
     557_LZMA_PROB32   - It can increase the speed on some 32-bit CPUs, but memory usage for
    558558                 some structures will be doubled in that case.
    559559
     
    563563
    564564
    565 C++ LZMA Encoder/Decoder 
     565C++ LZMA Encoder/Decoder
    566566~~~~~~~~~~~~~~~~~~~~~~~~
    567 C++ LZMA code use COM-like interfaces. So if you want to use it, 
     567C++ LZMA code use COM-like interfaces. So if you want to use it,
    568568you can study basics of COM/OLE.
    569569C++ LZMA code is just wrapper over ANSI-C code.
     
    583583  return p;
    584584}
    585 If you use MSCV that throws exception for "new" operator, you can compile without 
    586 "NewHandler.cpp". So standard exception will be used. Actually some code of 
     585If you use MSCV that throws exception for "new" operator, you can compile without
     586"NewHandler.cpp". So standard exception will be used. Actually some code of
    5875877-Zip catches any exception in internal code and converts it to HRESULT code.
    588588So you don't need to catch CNewException, if you call COM interfaces of 7-Zip.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/PeiDxeDebugLibReportStatusCode/DebugLib.c

    r58459 r58466  
    3131  Prints a debug message to the debug output device if the specified error level is enabled.
    3232
    33   If any bit in ErrorLevel is also set in DebugPrintErrorLevelLib function 
    34   GetDebugPrintErrorLevel (), then print the message specified by Format and the 
     33  If any bit in ErrorLevel is also set in DebugPrintErrorLevelLib function
     34  GetDebugPrintErrorLevel (), then print the message specified by Format and the
    3535  associated variable argument list to the debug output device.
    3636
     
    4242  @param  ErrorLevel  The error level of the debug message.
    4343  @param  Format      Format string for the debug message to print.
    44   @param  ...         Variable argument list whose contents are accessed 
     44  @param  ...         Variable argument list whose contents are accessed
    4545                      based on the format string specified by Format.
    4646
     
    7676  //
    7777  // Compute the total size of the record.
    78   // Note that the passing-in format string and variable parameters will be constructed to 
     78  // Note that the passing-in format string and variable parameters will be constructed to
    7979  // the following layout:
    8080  //
     
    166166        //
    167167        // Make no output if Format string terminates unexpectedly when
    168         // looking up for flag, width, precision and type. 
     168        // looking up for flag, width, precision and type.
    169169        //
    170170        Format--;
     
    176176      break;
    177177    }
    178    
     178
    179179    //
    180180    // Pack variable arguments into the storage area following EFI_DEBUG_INFO.
     
    199199    //
    200200    // If the converted BASE_LIST is larger than the 12 * sizeof (UINT64) allocated bytes, then ASSERT()
    201     // This indicates that the DEBUG() macro is passing in more argument than can be handled by 
     201    // This indicates that the DEBUG() macro is passing in more argument than can be handled by
    202202    // the EFI_DEBUG_INFO record
    203203    //
     
    229229
    230230/**
    231   Prints an assert message containing a filename, line number, and description. 
     231  Prints an assert message containing a filename, line number, and description.
    232232  This may be followed by a breakpoint or a dead loop.
    233233
    234234  Print a message of the form "ASSERT <FileName>(<LineNumber>): <Description>\n"
    235   to the debug output device.  If DEBUG_PROPERTY_ASSERT_BREAKPOINT_ENABLED bit of 
    236   PcdDebugProperyMask is set then CpuBreakpoint() is called. Otherwise, if 
    237   DEBUG_PROPERTY_ASSERT_DEADLOOP_ENABLED bit of PcdDebugProperyMask is set then 
    238   CpuDeadLoop() is called.  If neither of these bits are set, then this function 
     235  to the debug output device.  If DEBUG_PROPERTY_ASSERT_BREAKPOINT_ENABLED bit of
     236  PcdDebugProperyMask is set then CpuBreakpoint() is called. Otherwise, if
     237  DEBUG_PROPERTY_ASSERT_DEADLOOP_ENABLED bit of PcdDebugProperyMask is set then
     238  CpuDeadLoop() is called.  If neither of these bits are set, then this function
    239239  returns immediately after the message is printed to the debug output device.
    240240  DebugAssert() must actively prevent recursion.  If DebugAssert() is called while
     
    277277  if (HeaderSize + FileNameSize + DescriptionSize > sizeof (Buffer)) {
    278278    //
    279     // FileName + Description is too long to be filled into buffer. 
     279    // FileName + Description is too long to be filled into buffer.
    280280    //
    281281    if (HeaderSize + FileNameSize < sizeof (Buffer)) {
    282282      //
    283       // Description has enough buffer to be truncated. 
     283      // Description has enough buffer to be truncated.
    284284      //
    285285      DescriptionSize = sizeof (Buffer) - HeaderSize - FileNameSize;
     
    293293    }
    294294  }
    295  
     295
    296296  //
    297297  // Fill in EFI_DEBUG_ASSERT_DATA
     
    339339  Fills a target buffer with PcdDebugClearMemoryValue, and returns the target buffer.
    340340
    341   This function fills Length bytes of Buffer with the value specified by 
     341  This function fills Length bytes of Buffer with the value specified by
    342342  PcdDebugClearMemoryValue, and returns Buffer.
    343343
    344344  If Buffer is NULL, then ASSERT().
    345   If Length is greater than (MAX_ADDRESS - Buffer + 1), then ASSERT(). 
     345  If Length is greater than (MAX_ADDRESS - Buffer + 1), then ASSERT().
    346346
    347347  @param   Buffer  Pointer to the target buffer to be filled with PcdDebugClearMemoryValue.
    348   @param   Length  Number of bytes in Buffer to fill with zeros PcdDebugClearMemoryValue. 
     348  @param   Length  Number of bytes in Buffer to fill with zeros PcdDebugClearMemoryValue.
    349349
    350350  @return  Buffer  Pointer to the target buffer filled with PcdDebugClearMemoryValue.
     
    367367  Returns TRUE if ASSERT() macros are enabled.
    368368
    369   This function returns TRUE if the DEBUG_PROPERTY_DEBUG_ASSERT_ENABLED bit of 
     369  This function returns TRUE if the DEBUG_PROPERTY_DEBUG_ASSERT_ENABLED bit of
    370370  PcdDebugProperyMask is set.  Otherwise FALSE is returned.
    371371
     
    384384
    385385
    386 /** 
     386/**
    387387  Returns TRUE if DEBUG() macros are enabled.
    388388
    389   This function returns TRUE if the DEBUG_PROPERTY_DEBUG_PRINT_ENABLED bit of 
     389  This function returns TRUE if the DEBUG_PROPERTY_DEBUG_PRINT_ENABLED bit of
    390390  PcdDebugProperyMask is set.  Otherwise FALSE is returned.
    391391
     
    404404
    405405
    406 /** 
     406/**
    407407  Returns TRUE if DEBUG_CODE() macros are enabled.
    408408
    409   This function returns TRUE if the DEBUG_PROPERTY_DEBUG_CODE_ENABLED bit of 
     409  This function returns TRUE if the DEBUG_PROPERTY_DEBUG_CODE_ENABLED bit of
    410410  PcdDebugProperyMask is set.  Otherwise FALSE is returned.
    411411
     
    424424
    425425
    426 /** 
     426/**
    427427  Returns TRUE if DEBUG_CLEAR_MEMORY() macro is enabled.
    428428
    429   This function returns TRUE if the DEBUG_PROPERTY_CLEAR_MEMORY_ENABLED bit of 
     429  This function returns TRUE if the DEBUG_PROPERTY_CLEAR_MEMORY_ENABLED bit of
    430430  PcdDebugProperyMask is set.  Otherwise FALSE is returned.
    431431
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/PeiDxeDebugLibReportStatusCode/PeiDxeDebugLibReportStatusCode.inf

    r58459 r58466  
    3737  MdePkg/MdePkg.dec
    3838  MdeModulePkg/MdeModulePkg.dec
    39  
     39
    4040[LibraryClasses]
    4141  PcdLib
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/PeiRecoveryLib/PeiRecoveryLib.c

    r48674 r58466  
    44  This library instance is no longer used and module using this library
    55  class should update to directly locate EFI_PEI_RECOVERY_MODULE_PPI defined
    6   in PI 1.2 specification. 
     6  in PI 1.2 specification.
    77
    88Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
     
    2525/**
    2626  Calling this function causes the system do recovery.
    27  
     27
    2828  @retval EFI_SUCESS   Sucess to do recovery.
    2929  @retval Others       Fail to do recovery.
     
    3737  EFI_STATUS                      Status;
    3838  EFI_PEI_RECOVERY_MODULE_PPI     *PeiRecovery;
    39  
     39
    4040  Status = PeiServicesLocatePpi (
    4141             &gEfiPeiRecoveryModulePpiGuid,
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/PeiRecoveryLib/PeiRecoveryLib.inf

    r58459 r58466  
    44#  This library instance is no longer used and module using this library
    55#  class should update to directly locate EFI_PEI_RECOVERY_MODULE_PPI defined
    6 #  in PI 1.2 specification. 
     6#  in PI 1.2 specification.
    77#
    88#  Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
     
    4747[Ppis]
    4848  gEfiPeiRecoveryModulePpiGuid            ## CONSUMES
     49
    4950 
    50  
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/PeiS3Lib/PeiS3Lib.c

    r48674 r58466  
    11/** @file
    2   This library provides API to invoke the S3 resume vector in the APCI Table in S3 resume mode. 
     2  This library provides API to invoke the S3 resume vector in the APCI Table in S3 resume mode.
    33
    44  This library instance is no longer used and module using this library
    55  class should update to directly locate EFI_PEI_S3_RESUME_PPI defined
    6   in PI 1.2 specification. 
     6  in PI 1.2 specification.
    77
    88Copyright (c) 2006 - 2008, Intel Corporation. All rights reserved.<BR>
     
    2626/**
    2727  This function is responsible for calling the S3 resume vector in the ACPI Tables.
    28  
     28
    2929  @retval EFI_SUCESS   Success to restore config from S3.
    3030  @retval Others       Fail to restore config from S3.
     
    3838  EFI_STATUS              Status;
    3939  EFI_PEI_S3_RESUME_PPI   *S3Resume;
    40  
     40
    4141  Status = PeiServicesLocatePpi (
    4242             &gEfiPeiS3ResumePpiGuid,
     
    4747  ASSERT_EFI_ERROR (Status);
    4848
    49   return S3Resume->S3RestoreConfig ((EFI_PEI_SERVICES  **) GetPeiServicesTablePointer()); 
     49  return S3Resume->S3RestoreConfig ((EFI_PEI_SERVICES  **) GetPeiServicesTablePointer());
    5050}
    5151
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/PeiS3Lib/PeiS3Lib.inf

    r58459 r58466  
    44#  This library instance is no longer used and module using this library
    55#  class should update to directly locate EFI_PEI_S3_RESUME_PPI defined
    6 #  in PI 1.2 specification. 
     6#  in PI 1.2 specification.
    77#
    88#  Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/PlatformBdsLibNull/PlatformBdsLibNull.inf

    r58459 r58466  
    11## @file
    22#  NULL implementation for PlatformBdsLib library class interfaces.
    3 # 
     3#
    44#  Copyright (c) 2007 - 2014, Intel Corporation. All rights reserved.<BR>
    55#  This program and the accompanying materials
     
    77#  which accompanies this distribution.  The full text of the license may be found at
    88#  http://opensource.org/licenses/bsd-license.php
    9 # 
     9#
    1010#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1111#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    12 # 
     12#
    1313##
    1414
     
    2020  MODULE_TYPE                    = DXE_DRIVER
    2121  VERSION_STRING                 = 1.0
    22   LIBRARY_CLASS                  = PlatformBdsLib|DXE_DRIVER   
     22  LIBRARY_CLASS                  = PlatformBdsLib|DXE_DRIVER
    2323
    2424#
     
    3737  MdeModulePkg/MdeModulePkg.dec
    3838  IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec
    39  
     39
    4040[LibraryClasses]
    4141  BaseLib
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/SmmRuntimeDxeReportStatusCodeLibFramework/SmmRuntimeDxeReportStatusCodeLibFramework.inf

    r58459 r58466  
    2626  VERSION_STRING                 = 1.0
    2727  LIBRARY_CLASS                  = ReportStatusCodeLib|DXE_RUNTIME_DRIVER DXE_SMM_DRIVER
    28  
     28
    2929  CONSTRUCTOR                    = ReportStatusCodeLibConstruct
    3030  DESTRUCTOR                     = ReportStatusCodeLibDestruct
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Library/SmmRuntimeDxeReportStatusCodeLibFramework/SmmRuntimeDxeSupport.c

    r48674 r58466  
    2727/**
    2828  Locates and caches SMM Status Code Protocol.
    29  
     29
    3030**/
    3131VOID
     
    4444/**
    4545  Report status code via SMM Status Code Protocol.
    46  
     46
    4747  @param  Type          Indicates the type of status code being reported.
    48   @param  Value         Describes the current status of a hardware or software entity. 
    49                         This included information about the class and subclass that is used to classify the entity 
    50                         as well as an operation.  For progress codes, the operation is the current activity. 
    51                         For error codes, it is the exception.  For debug codes, it is not defined at this time. 
    52   @param  Instance      The enumeration of a hardware or software entity within the system. 
    53                         A system may contain multiple entities that match a class/subclass pairing. 
    54                         The instance differentiates between them.  An instance of 0 indicates that instance information is unavailable, 
     48  @param  Value         Describes the current status of a hardware or software entity.
     49                        This included information about the class and subclass that is used to classify the entity
     50                        as well as an operation.  For progress codes, the operation is the current activity.
     51                        For error codes, it is the exception.  For debug codes, it is not defined at this time.
     52  @param  Instance      The enumeration of a hardware or software entity within the system.
     53                        A system may contain multiple entities that match a class/subclass pairing.
     54                        The instance differentiates between them.  An instance of 0 indicates that instance information is unavailable,
    5555                        not meaningful, or not relevant.  Valid instance numbers start with 1.
    56   @param  CallerId      This optional parameter may be used to identify the caller. 
    57                         This parameter allows the status code driver to apply different rules to different callers. 
     56  @param  CallerId      This optional parameter may be used to identify the caller.
     57                        This parameter allows the status code driver to apply different rules to different callers.
    5858  @param  Data          This optional parameter may be used to pass additional data
    59  
     59
    6060  @retval EFI_SUCCESS   Always return EFI_SUCCESS.
    6161
     
    157157      }
    158158    }
    159  
     159
    160160    //
    161161    // A status code service is present in system, so pass in all the parameters to the service.
     
    163163    return (*mReportStatusCode) (Type, Value, Instance, (EFI_GUID *)CallerId, Data);
    164164  }
    165  
     165
    166166  return EFI_UNSUPPORTED;
    167167}
     
    221221  @param  ImageHandle   The firmware allocated handle for the EFI image.
    222222  @param  SystemTable   A pointer to the EFI System Table.
    223  
     223
    224224  @retval EFI_SUCCESS   The constructor always returns EFI_SUCCESS.
    225225
     
    243243      Status = mSmmBase->SmmAllocatePool (
    244244                           mSmmBase,
    245                            EfiRuntimeServicesData, 
    246                            sizeof (EFI_STATUS_CODE_DATA) + EFI_STATUS_CODE_DATA_MAX_SIZE, 
     245                           EfiRuntimeServicesData,
     246                           sizeof (EFI_STATUS_CODE_DATA) + EFI_STATUS_CODE_DATA_MAX_SIZE,
    247247                           (VOID **) &mStatusCodeData
    248248                           );
     
    258258  //
    259259  // Library should not use the gRT directly, for it may be converted by other library instance.
    260   // 
     260  //
    261261  mInternalRT = gRT;
    262262  mInSmm      = FALSE;
     
    266266  //
    267267  // Cache the report status code service
    268   // 
     268  //
    269269  mReportStatusCode = InternalGetReportStatusCode ();
    270270
    271271  //
    272272  // Register notify function for EVT_SIGNAL_VIRTUAL_ADDRESS_CHANGE
    273   // 
     273  //
    274274  Status = gBS->CreateEventEx (
    275275                  EVT_NOTIFY_SIGNAL,
     
    284284  //
    285285  // Register notify function for EVT_SIGNAL_EXIT_BOOT_SERVICES
    286   // 
     286  //
    287287  Status = gBS->CreateEventEx (
    288288                  EVT_NOTIFY_SIGNAL,
     
    300300/**
    301301  The destructor function of SMM Runtime DXE Report Status Code Lib.
    302  
     302
    303303  The destructor function frees memory allocated by constructor, and closes related events.
    304   It will ASSERT() if that related operation fails and it will always return EFI_SUCCESS. 
     304  It will ASSERT() if that related operation fails and it will always return EFI_SUCCESS.
    305305
    306306  @param  ImageHandle   The firmware allocated handle for the EFI image.
    307307  @param  SystemTable   A pointer to the EFI System Table.
    308  
     308
    309309  @retval EFI_SUCCESS   The constructor always returns EFI_SUCCESS.
    310310
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/Acpi/AcpiS3SaveDxe/AcpiS3Save.c

    r58459 r58466  
    6969  @param  MemoryType   Memory type of memory to allocate.
    7070  @param  Size         Size of memory to allocate.
    71  
     71
    7272  @return Allocated address for output.
    7373
     
    127127
    128128  EntryCount = (Rsdt->Length - sizeof (EFI_ACPI_DESCRIPTION_HEADER)) / sizeof(UINT32);
    129  
     129
    130130  EntryPtr = (UINT32 *)(Rsdt + 1);
    131131  for (Index = 0; Index < EntryCount; Index ++, EntryPtr ++) {
     
    135135    }
    136136  }
    137  
     137
    138138  return NULL;
    139139}
     
    166166
    167167  EntryCount = (Xsdt->Length - sizeof (EFI_ACPI_DESCRIPTION_HEADER)) / sizeof(UINT64);
    168  
     168
    169169  BasePtr = (UINTN)(Xsdt + 1);
    170170  for (Index = 0; Index < EntryCount; Index ++) {
     
    175175    }
    176176  }
    177  
     177
    178178  return NULL;
    179179}
     
    183183
    184184  @param Fadt   FADT table pointer
    185  
     185
    186186  @return  Facs table pointer.
    187187**/
     
    213213/**
    214214  To find Facs in Acpi tables.
    215  
    216   To find Firmware ACPI control strutcure in Acpi Tables since the S3 waking vector is stored 
     215
     216  To find Firmware ACPI control strutcure in Acpi Tables since the S3 waking vector is stored
    217217  in the table.
    218218
    219219  @param AcpiTableGuid   The guid used to find ACPI table in UEFI ConfigurationTable.
    220  
     220
    221221  @return  Facs table pointer.
    222222**/
     
    282282/**
    283283  To find Facs in Acpi tables.
    284  
    285   To find Firmware ACPI control strutcure in Acpi Tables since the S3 waking vector is stored 
     284
     285  To find Firmware ACPI control strutcure in Acpi Tables since the S3 waking vector is stored
    286286  in the table.
    287  
     287
    288288  @return  Facs table pointer.
    289289**/
     
    306306  Allocates and fills in the Page Directory and Page Table Entries to
    307307  establish a 1:1 Virtual to Physical mapping.
    308   If BootScriptExector driver will run in 64-bit mode, this function will establish the 1:1 
     308  If BootScriptExector driver will run in 64-bit mode, this function will establish the 1:1
    309309  virtual to physical mapping page table.
    310   If BootScriptExector driver will not run in 64-bit mode, this function will do nothing. 
    311  
    312   @return  the 1:1 Virtual to Physical identity mapping page table base address. 
     310  If BootScriptExector driver will not run in 64-bit mode, this function will do nothing.
     311
     312  @return  the 1:1 Virtual to Physical identity mapping page table base address.
    313313
    314314**/
     
    317317  VOID
    318318  )
    319 { 
     319{
    320320  if (FeaturePcdGet (PcdDxeIplSwitchToLongMode)) {
    321321    UINT32                                        RegEax;
     
    343343        }
    344344      }
    345      
     345
    346346      //
    347347      // Get physical address bits supported.
     
    359359        }
    360360      }
    361      
     361
    362362      //
    363363      // IA-32e paging translates 48-bit linear addresses to 52-bit physical addresses.
     
    367367        PhysicalAddressBits = 48;
    368368      }
    369      
     369
    370370      //
    371371      // Calculate the table entries needed.
     
    378378        NumberOfPdpEntriesNeeded = 512;
    379379      }
    380      
     380
    381381      //
    382382      // We need calculate whole page size then allocate once, because S3 restore page table does not know each page in Nvs.
     
    388388      }
    389389      DEBUG ((EFI_D_ERROR, "TotalPageTableSize - %x pages\n", TotalPageTableSize));
    390      
     390
    391391      //
    392392      // By architecture only one PageMapLevel4 exists - so lets allocate storage for it.
     
    394394      S3NvsPageTableAddress = (EFI_PHYSICAL_ADDRESS)(UINTN)AllocateMemoryBelow4G (EfiReservedMemoryType, EFI_PAGES_TO_SIZE(TotalPageTableSize));
    395395      ASSERT (S3NvsPageTableAddress != 0);
    396       PcdSet64 (PcdIdentifyMappingPageTablePtr, S3NvsPageTableAddress); 
     396      PcdSet64 (PcdIdentifyMappingPageTablePtr, S3NvsPageTableAddress);
    397397      return S3NvsPageTableAddress;
    398398    }
     
    401401    // If DXE is running 32-bit mode, no need to establish page table.
    402402    //
    403     return  (EFI_PHYSICAL_ADDRESS) 0; 
    404   }
    405 }
    406 
    407 /**
    408   Gets the buffer of legacy memory below 1 MB 
     403    return  (EFI_PHYSICAL_ADDRESS) 0;
     404  }
     405}
     406
     407/**
     408  Gets the buffer of legacy memory below 1 MB
    409409  This function is to get the buffer in legacy memory below 1MB that is required during S3 resume.
    410410
     
    433433/**
    434434  Prepares all information that is needed in the S3 resume boot path.
    435  
    436   Allocate the resources or prepare informations and save in ACPI variable set for S3 resume boot path 
    437  
     435
     436  Allocate the resources or prepare informations and save in ACPI variable set for S3 resume boot path
     437
    438438  @param This                 A pointer to the EFI_ACPI_S3_SAVE_PROTOCOL instance.
    439439  @param LegacyMemoryAddress  The base address of legacy memory.
     
    547547/**
    548548  The Driver Entry Point.
    549  
     549
    550550  The function is the driver Entry point which will produce AcpiS3SaveProtocol.
    551  
     551
    552552  @param ImageHandle   A handle for the image that is initializing this driver
    553553  @param SystemTable   A pointer to the EFI system table
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/Acpi/AcpiS3SaveDxe/AcpiS3Save.h

    r58459 r58466  
    11/** @file
    2   This is an implementation of the ACPI S3 Save protocol.  This is defined in 
     2  This is an implementation of the ACPI S3 Save protocol.  This is defined in
    33  S3 boot path specification 0.9.
    44
     
    2020
    2121/**
    22   Gets the buffer of legacy memory below 1 MB 
     22  Gets the buffer of legacy memory below 1 MB
    2323  This function is to get the buffer in legacy memory below 1MB that is required during S3 resume.
    2424
     
    3939/**
    4040  Prepares all information that is needed in the S3 resume boot path.
    41  
    42   Allocate the resources or prepare informations and save in ACPI variable set for S3 resume boot path 
    43  
     41
     42  Allocate the resources or prepare informations and save in ACPI variable set for S3 resume boot path
     43
    4444  @param This                 A pointer to the EFI_ACPI_S3_SAVE_PROTOCOL instance.
    4545  @param LegacyMemoryAddress  The base address of legacy memory.
     
    5555S3Ready (
    5656  IN EFI_ACPI_S3_SAVE_PROTOCOL     *This,
    57   IN VOID                          *LegacyMemoryAddress   
     57  IN VOID                          *LegacyMemoryAddress
    5858  );
    5959#endif
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/Acpi/AcpiS3SaveDxe/AcpiS3SaveDxe.inf

    r58459 r58466  
    8585  #
    8686  # Note: the extra dependency of gEfiMpServiceProtocolGuid is to ensure that ACPI variable is set by MpDxe driver before
    87   # AcpiS3SaveDxe module is executed. 
     87  # AcpiS3SaveDxe module is executed.
    8888  #
    8989  gEfiVariableArchProtocolGuid AND gEfiVariableWriteArchProtocolGuid AND gEfiMpServiceProtocolGuid
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/Acpi/AcpiS3SaveDxe/AcpiVariableThunkPlatform.c

    r58459 r58466  
    2626  EFI_PHYSICAL_ADDRESS  VideoOpromAddress;
    2727  UINT32                VideoOpromSize;
    28   EFI_PHYSICAL_ADDRESS  S3DebugBufferAddress; 
    29   EFI_PHYSICAL_ADDRESS  S3ResumeNvsEntryPoint;   
     28  EFI_PHYSICAL_ADDRESS  S3DebugBufferAddress;
     29  EFI_PHYSICAL_ADDRESS  S3ResumeNvsEntryPoint;
    3030} ACPI_VARIABLE_SET_COMPATIBILITY;
    3131
     
    5656  @param  MemoryType   Memory type of memory to allocate.
    5757  @param  Size         Size of memory to allocate.
    58  
     58
    5959  @return Allocated address for output.
    6060
     
    170170  if (!EFI_ERROR (Status)) {
    171171    //
    172     // On ECP platform, if framework CPU drivers are in use, The compatible version of ACPI variable set 
    173     // should be produced by CPU driver. 
     172    // On ECP platform, if framework CPU drivers are in use, The compatible version of ACPI variable set
     173    // should be produced by CPU driver.
    174174    //
    175175    VarSize = sizeof (mAcpiVariableSetCompatibility);
     
    187187  } else {
    188188    //
    189     // Allocate/initialize the compatible version of Acpi Variable Set since Framework chipset/platform 
     189    // Allocate/initialize the compatible version of Acpi Variable Set since Framework chipset/platform
    190190    // driver need this variable. ACPI_GLOBAL_VARIABLE variable is not used in runtime phase,
    191191    // so RT attribute is not needed for it.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/Acpi/AcpiSupportDxe/AcpiSupport.c

    r48674 r58466  
    11/** @file
    2   This is an implementation of the ACPI Support protocol.  This is defined in 
     2  This is an implementation of the ACPI Support protocol.  This is defined in
    33  the Tiano ACPI External Product Specification, revision 0.3.6.
    44
     
    2727
    2828/**
    29   Entry point of the ACPI support driver. This function creates and initializes an instance of the ACPI Support 
     29  Entry point of the ACPI support driver. This function creates and initializes an instance of the ACPI Support
    3030  Protocol and installs it on a new handle.
    3131
    3232  @param ImageHandle   A handle for the image that is initializing this driver
    33   @param SystemTable   A pointer to the EFI system table       
     33  @param SystemTable   A pointer to the EFI system table
    3434
    3535  @retval EFI_SUCCESS              Driver initialized successfully
    36   @retval EFI_LOAD_ERROR           Failed to Initialize or has been loaded 
     36  @retval EFI_LOAD_ERROR           Failed to Initialize or has been loaded
    3737  @retval EFI_OUT_OF_RESOURCES     Could not allocate needed resources
    3838**/
     
    8686                    );
    8787    ASSERT_EFI_ERROR (Status);
    88   } 
     88  }
    8989
    9090  return Status;
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/Acpi/AcpiSupportDxe/AcpiSupport.h

    r58459 r58466  
    132132      EFI_ACPI_SUPPORT_SIGNATURE \
    133133      )
    134      
     134
    135135/**
    136   Constructor for the ACPI support protocol. 
    137  
     136  Constructor for the ACPI support protocol.
     137
    138138  Constructor for the ACPI support protocol to initializes instance data.
    139  
     139
    140140  @param AcpiSupportInstance   Instance to construct
    141141
     
    148148  );
    149149/**
    150   Entry point of the ACPI support driver. This function creates and initializes an instance of the ACPI Support 
     150  Entry point of the ACPI support driver. This function creates and initializes an instance of the ACPI Support
    151151  Protocol and installs it on a new handle.
    152152
    153153  @param ImageHandle   A handle for the image that is initializing this driver
    154   @param SystemTable   A pointer to the EFI system table       
     154  @param SystemTable   A pointer to the EFI system table
    155155
    156156  @retval EFI_SUCCESS              Driver initialized successfully
    157   @retval EFI_LOAD_ERROR           Failed to Initialize or has been loaded 
     157  @retval EFI_LOAD_ERROR           Failed to Initialize or has been loaded
    158158  @retval EFI_OUT_OF_RESOURCES     Could not allocate needed resources
    159159**/
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/Acpi/AcpiSupportDxe/AcpiSupportAcpiSupportProtocol.c

    r58459 r58466  
    2020#include "AcpiSupport.h"
    2121//
    22 // The maximum number of tables that pre-allocated. 
     22// The maximum number of tables that pre-allocated.
    2323//
    24 UINTN         mEfiAcpiMaxNumTables = EFI_ACPI_MAX_NUM_TABLES; 
     24UINTN         mEfiAcpiMaxNumTables = EFI_ACPI_MAX_NUM_TABLES;
    2525/**
    2626  This function adds an ACPI table to the table list.  It will detect FACS and
     
    9292
    9393/**
    94   This function returns a table specified by an index if it exists. 
    95  
    96   The function returns a buffer containing the table that the caller must free. 
    97   The function also returns a handle used to identify the table for update or 
     94  This function returns a table specified by an index if it exists.
     95
     96  The function returns a buffer containing the table that the caller must free.
     97  The function also returns a handle used to identify the table for update or
    9898  deletion using the SetAcpiTable function.
    9999
     
    166166/**
    167167  This function adds, removes, or updates ACPI tables.  If the address is not
    168   null and the handle value is null, the table is added.  If both the address and 
     168  null and the handle value is null, the table is added.  If both the address and
    169169  handle are not null, the table at handle is updated with the table at address.
    170170  If the address is null and the handle is not, the table at handle is deleted.
     
    372372
    373373  @return EFI_SUCCESS            The table was successfully inserted.
    374   @return EFI_INVALID_PARAMETER  Either AcpiTableBuffer is NULL, TableKey is NULL, or AcpiTableBufferSize 
     374  @return EFI_INVALID_PARAMETER  Either AcpiTableBuffer is NULL, TableKey is NULL, or AcpiTableBufferSize
    375375                                 and the size field embedded in the ACPI table pointed to by AcpiTableBuffer
    376376                                 are not in sync.
     
    428428  }
    429429  FreePool (AcpiTableBufferConst);
    430  
     430
    431431  return Status;
    432432}
     
    501501  UINT64                     CurrentData;
    502502
    503   CopyMem (&TempPrivateData, AcpiSupportInstance, sizeof (EFI_ACPI_SUPPORT_INSTANCE)); 
     503  CopyMem (&TempPrivateData, AcpiSupportInstance, sizeof (EFI_ACPI_SUPPORT_INSTANCE));
    504504  //
    505505  // Enlarge the max table number from mEfiAcpiMaxNumTables to mEfiAcpiMaxNumTables + EFI_ACPI_MAX_NUM_TABLES
     
    539539  Pointer = (UINT8 *) (UINTN) PageAddress;
    540540  ZeroMem (Pointer, TotalSize);
    541  
     541
    542542  AcpiSupportInstance->Rsdt1 = (EFI_ACPI_DESCRIPTION_HEADER *) Pointer;
    543543  Pointer += (sizeof (EFI_ACPI_DESCRIPTION_HEADER) + NewMaxTableNumber * sizeof (UINT32));
     
    555555
    556556  //
    557   // copy the original Rsdt1, Rsdt3 and Xsdt structure to new buffer 
    558   //
    559   CopyMem (AcpiSupportInstance->Rsdt1, TempPrivateData.Rsdt1, (sizeof (EFI_ACPI_DESCRIPTION_HEADER) + mEfiAcpiMaxNumTables * sizeof (UINT32))); 
    560   CopyMem (AcpiSupportInstance->Rsdt3, TempPrivateData.Rsdt3, (sizeof (EFI_ACPI_DESCRIPTION_HEADER) + mEfiAcpiMaxNumTables * sizeof (UINT32))); 
     557  // copy the original Rsdt1, Rsdt3 and Xsdt structure to new buffer
     558  //
     559  CopyMem (AcpiSupportInstance->Rsdt1, TempPrivateData.Rsdt1, (sizeof (EFI_ACPI_DESCRIPTION_HEADER) + mEfiAcpiMaxNumTables * sizeof (UINT32)));
     560  CopyMem (AcpiSupportInstance->Rsdt3, TempPrivateData.Rsdt3, (sizeof (EFI_ACPI_DESCRIPTION_HEADER) + mEfiAcpiMaxNumTables * sizeof (UINT32)));
    561561  CopyMem (AcpiSupportInstance->Xsdt, TempPrivateData.Xsdt, (sizeof (EFI_ACPI_DESCRIPTION_HEADER) + mEfiAcpiMaxNumTables * sizeof (UINT64)));
    562  
     562
    563563  //
    564564  // Calculate orignal ACPI table buffer size
     
    571571              mEfiAcpiMaxNumTables * sizeof (UINT64);
    572572  gBS->FreePages ((EFI_PHYSICAL_ADDRESS)(UINTN)TempPrivateData.Rsdt1, EFI_SIZE_TO_PAGES (TotalSize));
    573  
     573
    574574  //
    575575  // Update the Max ACPI table number
    576   // 
     576  //
    577577  mEfiAcpiMaxNumTables = NewMaxTableNumber;
    578578  return EFI_SUCCESS;
     
    651651  // Allocation memory type depends on the type of the table
    652652  //
    653   if ((CurrentTableSignature == EFI_ACPI_2_0_FIRMWARE_ACPI_CONTROL_STRUCTURE_SIGNATURE) || 
     653  if ((CurrentTableSignature == EFI_ACPI_2_0_FIRMWARE_ACPI_CONTROL_STRUCTURE_SIGNATURE) ||
    654654      (CurrentTableSignature == EFI_ACPI_4_0_UEFI_ACPI_DATA_TABLE_SIGNATURE)) {
    655655    //
     
    779779      //
    780780      // Update pointers in FADT.  If tables don't exist this will put NULL pointers there.
    781       // Note: If the FIRMWARE_CTRL is non-zero, then X_FIRMWARE_CTRL must be zero, and 
     781      // Note: If the FIRMWARE_CTRL is non-zero, then X_FIRMWARE_CTRL must be zero, and
    782782      // vice-versa.
    783783      //
     
    914914      if (AcpiSupportInstance->Fadt3 != NULL) {
    915915        //
    916         // Note: If the FIRMWARE_CTRL is non-zero, then X_FIRMWARE_CTRL must be zero, and 
     916        // Note: If the FIRMWARE_CTRL is non-zero, then X_FIRMWARE_CTRL must be zero, and
    917917        // vice-versa.
    918918        //
     
    985985      }
    986986    }
    987    
     987
    988988     if ((Version & EFI_ACPI_TABLE_VERSION_2_0) != 0 ||
    989989        (Version & EFI_ACPI_TABLE_VERSION_3_0) != 0) {
     
    10151015          );
    10161016      }
    1017     }       
     1017    }
    10181018    //
    10191019    // Checksum the table
     
    10951095         Status = ReallocateAcpiTableBuffer (AcpiSupportInstance);
    10961096         ASSERT_EFI_ERROR (Status);
    1097        }     
     1097       }
    10981098      //
    10991099      // At this time, it is assumed that RSDT and XSDT maintain parallel lists of tables.
     
    11601160  @param  Handle      Table to find.
    11611161  @param  TableList   Table list to search
    1162   @param  Table       Pointer to table found. 
     1162  @param  Table       Pointer to table found.
    11631163
    11641164  @return EFI_SUCCESS    The function completed successfully.
     
    12081208  For Acpi 2.0 tables, pass in both Rsdt and Xsdt.
    12091209
    1210   @param  Table                 Pointer to table found. 
     1210  @param  Table                 Pointer to table found.
    12111211  @param  NumberOfTableEntries  Current number of table entries in the RSDT/XSDT
    12121212  @param  Rsdt                  Pointer to the RSDT to remove from
     
    14181418      if (Version & EFI_ACPI_TABLE_VERSION_2_0 & Table->Version) {
    14191419        Table->Version = Table->Version &~EFI_ACPI_TABLE_VERSION_2_0;
    1420       }     
     1420      }
    14211421      if (Version & EFI_ACPI_TABLE_VERSION_3_0 & Table->Version) {
    14221422        Table->Version = Table->Version &~EFI_ACPI_TABLE_VERSION_3_0;
    14231423      }
    1424      
     1424
    14251425      //
    14261426      // Remove from Rsdt and Xsdt.  We don't care about the return value
     
    14361436          );
    14371437      }
    1438     }   
     1438    }
    14391439    //
    14401440    // Free the table, clean up any dependent tables and our private data pointers.
     
    14961496            );
    14971497        }
    1498       }   
     1498      }
    14991499      break;
    15001500
     
    15211521      }
    15221522
    1523      
     1523
    15241524      if ((Version & EFI_ACPI_TABLE_VERSION_2_0) != 0 ||
    15251525          (Version & EFI_ACPI_TABLE_VERSION_3_0) != 0) {
     
    17341734    Checksum)
    17351735    );
    1736  
     1736
    17371737  return EFI_SUCCESS;
    17381738}
    1739 /** 
     1739/**
    17401740  Constructor for the ACPI support protocol to initializes instance data.
    1741  
     1741
    17421742  @param AcpiSupportInstance   Instance to construct
    17431743
     
    17701770  AcpiSupportInstance->AcpiTableProtocol.InstallAcpiTable   = InstallAcpiTable;
    17711771  AcpiSupportInstance->AcpiTableProtocol.UninstallAcpiTable = UninstallAcpiTable;
    1772  
     1772
    17731773  //
    17741774  // Create RSDP table
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/Acpi/AcpiSupportDxe/AcpiSupportDxe.inf

    r58459 r58466  
    22# Acpi Support Dirver to install Framework Acpi Support Protocol.
    33#
    4 # This driver initializes ACPI support protocol instance data structure and intstall 
     4# This driver initializes ACPI support protocol instance data structure and intstall
    55# ACPI support protocol to provide Get, Set and Publish Table services.
    66#
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/Bds.h

    r58459 r58466  
    200200  @param  VendorGuid             A unique identifier for the vendor.
    201201  @param  Attributes             Attributes bitmask to set for the variable.
    202   @param  DataSize               The size in bytes of the Data buffer. Unless the EFI_VARIABLE_APPEND_WRITE, 
    203                                  EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS, or 
    204                                  EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS attribute is set, a size of zero 
    205                                  causes the variable to be deleted. When the EFI_VARIABLE_APPEND_WRITE attribute is 
    206                                  set, then a SetVariable() call with a DataSize of zero will not cause any change to 
    207                                  the variable value (the timestamp associated with the variable may be updated however 
    208                                  even if no new data value is provided,see the description of the 
    209                                  EFI_VARIABLE_AUTHENTICATION_2 descriptor below. In this case the DataSize will not 
    210                                  be zero since the EFI_VARIABLE_AUTHENTICATION_2 descriptor will be populated). 
     202  @param  DataSize               The size in bytes of the Data buffer. Unless the EFI_VARIABLE_APPEND_WRITE,
     203                                 EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS, or
     204                                 EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS attribute is set, a size of zero
     205                                 causes the variable to be deleted. When the EFI_VARIABLE_APPEND_WRITE attribute is
     206                                 set, then a SetVariable() call with a DataSize of zero will not cause any change to
     207                                 the variable value (the timestamp associated with the variable may be updated however
     208                                 even if no new data value is provided,see the description of the
     209                                 EFI_VARIABLE_AUTHENTICATION_2 descriptor below. In this case the DataSize will not
     210                                 be zero since the EFI_VARIABLE_AUTHENTICATION_2 descriptor will be populated).
    211211  @param  Data                   The contents for the variable.
    212212
     
    220220  @retval EFI_WRITE_PROTECTED    The variable in question is read-only.
    221221  @retval EFI_WRITE_PROTECTED    The variable in question cannot be deleted.
    222   @retval EFI_SECURITY_VIOLATION The variable could not be written due to EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS 
    223                                  or EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACESS being set, but the AuthInfo 
     222  @retval EFI_SECURITY_VIOLATION The variable could not be written due to EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS
     223                                 or EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACESS being set, but the AuthInfo
    224224                                 does NOT pass the validation check carried out by the firmware.
    225225
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BdsDxe.inf

    r58459 r58466  
    22#  BDSDxe module is core driver for BDS phase.
    33#
    4 #  When DxeCore dispatching all DXE driver, this module will produce architecture protocol 
     4#  When DxeCore dispatching all DXE driver, this module will produce architecture protocol
    55#  gEfiBdsArchProtocolGuid. After DxeCore finish dispatching, DxeCore will invoke Entry
    66#  interface of protocol gEfiBdsArchProtocolGuid, then BDS phase is entered.
    77#
    8 #  Generally, this module take reposiblity to connect all necessary devices for platform boot, 
     8#  Generally, this module take reposiblity to connect all necessary devices for platform boot,
    99#  these boot device path are hold in PlatformBdsLib library instance produced by platform.
    1010#  For legacy boot, BDS will transfer control to legacy BIOS after legacy boot device is select.
    11 #  For EFI boot, BDS will load boot loader file EFI\BOOT\BOOTIA32.EFI, EFI\BOOT\BOOTX64.EFI, 
     11#  For EFI boot, BDS will load boot loader file EFI\BOOT\BOOTIA32.EFI, EFI\BOOT\BOOTX64.EFI,
    1212#  EFI\BOOT\BOOTIA64.EFI file from selected boot device and transfer control to boot loader.
    1313#
    1414#  BDSDxe also maintain the UI for "Boot Manager, Boot Maintaince Manager, Device Manager" which
    1515#  is used for user to configure boot option or maintain hardware device.
    16 # 
     16#
    1717#  Copyright (c) 2008 - 2014, Intel Corporation. All rights reserved.<BR>
    1818#  This program and the accompanying materials
     
    2020#  which accompanies this distribution.  The full text of the license may be found at
    2121#  http://opensource.org/licenses/bsd-license.php
    22 # 
     22#
    2323#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    2424#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    25 # 
     25#
    2626##
    2727
     
    3232  FILE_GUID                      = FC5C7020-1A48-4198-9BE2-EAD5ABC8CF2F
    3333  MODULE_TYPE                    = DXE_DRIVER
    34   VERSION_STRING                 = 1.0 
     34  VERSION_STRING                 = 1.0
    3535  ENTRY_POINT                    = BdsInitialize
    3636
     
    9292  IntelFrameworkPkg/IntelFrameworkPkg.dec
    9393  IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec
    94  
     94
    9595[LibraryClasses]
    9696  DevicePathLib
     
    113113  PcdLib
    114114  UefiHiiServicesLib
    115  
     115
    116116[Guids]
    117117  ## SOMETIMES_PRODUCES ## Variable:L"BootXXXX"          # Boot option variable
     
    171171  ## CONSUMES
    172172  ## NOTIFY
    173   gEfiSimpleTextInputExProtocolGuid             
     173  gEfiSimpleTextInputExProtocolGuid
    174174  gEfiHiiConfigAccessProtocolGuid               ## SOMETIMES_PRODUCES
    175175  gEfiFormBrowser2ProtocolGuid                  ## CONSUMES
     
    202202  ## PRODUCES
    203203  gEfiIntelFrameworkModulePkgTokenSpaceGuid.PcdBootState
    204   gEfiMdeModulePkgTokenSpaceGuid.PcdFirmwareVendor   ## CONSUMES   
     204  gEfiMdeModulePkgTokenSpaceGuid.PcdFirmwareVendor   ## CONSUMES
    205205  gEfiMdeModulePkgTokenSpaceGuid.PcdFirmwareRevision ## CONSUMES
    206206  gEfiMdeModulePkgTokenSpaceGuid.PcdVideoHorizontalResolution  ## PRODUCES
     
    221221
    222222#
    223 # [BootMode] 
     223# [BootMode]
    224224#   FLASH_UPDATE    ## SOMETIMES_CONSUMES # Update Capsule Image
    225225#
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BdsEntry.c

    r58459 r58466  
    198198
    199199  //
    200   // When we didn't have chance to build boot option variables in the first 
     200  // When we didn't have chance to build boot option variables in the first
    201201  // full configuration boot (e.g.: Reset in the first page or in Device Manager),
    202202  // we have no boot options in the following mini configuration boot.
     
    279279    //
    280280    BdsSetConsoleMode (FALSE);
    281    
     281
    282282    //
    283283    // All the driver options should have been processed since
     
    344344/**
    345345
    346   Validate input console variable data. 
     346  Validate input console variable data.
    347347
    348348  If found the device path is not a valid device path, remove the variable.
    349  
     349
    350350  @param VariableName             Input console variable name.
    351351
     
    365365                      &VariableSize
    366366                      );
    367   if ((DevicePath != NULL) && !IsDevicePathValid (DevicePath, VariableSize)) { 
     367  if ((DevicePath != NULL) && !IsDevicePathValid (DevicePath, VariableSize)) {
    368368    Status = gRT->SetVariable (
    369369                    VariableName,
     
    382382/**
    383383
    384   Formalize Bds global variables. 
     384  Formalize Bds global variables.
    385385
    386386 1. For ConIn/ConOut/ConErr, if found the device path is not a valid device path, remove the variable.
    387  2. For OsIndicationsSupported, Create a BS/RT/UINT64 variable to report caps 
     387 2. For OsIndicationsSupported, Create a BS/RT/UINT64 variable to report caps
    388388 3. Delete OsIndications variable if it is not NV/BS/RT UINT64
    389389 Item 3 is used to solve case when OS corrupts OsIndications. Here simply delete this NV variable.
    390  
    391 **/
    392 VOID 
     390
     391**/
     392VOID
    393393BdsFormalizeEfiGlobalVariable (
    394394  VOID
     
    400400  UINTN      DataSize;
    401401  UINT32     Attributes;
    402  
     402
    403403  //
    404404  // Validate Console variable.
     
    678678  @param  VendorGuid             A unique identifier for the vendor.
    679679  @param  Attributes             Attributes bitmask to set for the variable.
    680   @param  DataSize               The size in bytes of the Data buffer. Unless the EFI_VARIABLE_APPEND_WRITE, 
    681                                  EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS, or 
    682                                  EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS attribute is set, a size of zero 
    683                                  causes the variable to be deleted. When the EFI_VARIABLE_APPEND_WRITE attribute is 
    684                                  set, then a SetVariable() call with a DataSize of zero will not cause any change to 
    685                                  the variable value (the timestamp associated with the variable may be updated however 
    686                                  even if no new data value is provided,see the description of the 
    687                                  EFI_VARIABLE_AUTHENTICATION_2 descriptor below. In this case the DataSize will not 
    688                                  be zero since the EFI_VARIABLE_AUTHENTICATION_2 descriptor will be populated). 
     680  @param  DataSize               The size in bytes of the Data buffer. Unless the EFI_VARIABLE_APPEND_WRITE,
     681                                 EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS, or
     682                                 EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACCESS attribute is set, a size of zero
     683                                 causes the variable to be deleted. When the EFI_VARIABLE_APPEND_WRITE attribute is
     684                                 set, then a SetVariable() call with a DataSize of zero will not cause any change to
     685                                 the variable value (the timestamp associated with the variable may be updated however
     686                                 even if no new data value is provided,see the description of the
     687                                 EFI_VARIABLE_AUTHENTICATION_2 descriptor below. In this case the DataSize will not
     688                                 be zero since the EFI_VARIABLE_AUTHENTICATION_2 descriptor will be populated).
    689689  @param  Data                   The contents for the variable.
    690690
     
    698698  @retval EFI_WRITE_PROTECTED    The variable in question is read-only.
    699699  @retval EFI_WRITE_PROTECTED    The variable in question cannot be deleted.
    700   @retval EFI_SECURITY_VIOLATION The variable could not be written due to EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS 
    701                                  or EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACESS being set, but the AuthInfo 
     700  @retval EFI_SECURITY_VIOLATION The variable could not be written due to EFI_VARIABLE_AUTHENTICATED_WRITE_ACCESS
     701                                 or EFI_VARIABLE_TIME_BASED_AUTHENTICATED_WRITE_ACESS being set, but the AuthInfo
    702702                                 does NOT pass the validation check carried out by the firmware.
    703703
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/BBSsupport.c

    r58459 r58466  
    5454  UINTN                    Index;
    5555  UINTN                    StartPosition;
    56  
     56
    5757  BDS_COMMON_OPTION        *BootOption;
    58  
     58
    5959  CHAR16                   OptionName[sizeof ("Boot####")];
    6060  UINT16                   *BbsIndexArray;
     
    8383
    8484  for (Index = 0; Index < BootOrderSize / sizeof (UINT16); Index++) {
    85  
     85
    8686    UnicodeSPrint (OptionName, sizeof (OptionName), L"Boot%04x", BootOrder[Index]);
    8787    InitializeListHead (&List);
    8888    BootOption = BdsLibVariableToOption (&List, OptionName);
    8989    ASSERT (BootOption != NULL);
    90    
     90
    9191    if ((DevicePathType (BootOption->DevicePath) == BBS_DEVICE_PATH) &&
    9292        (DevicePathSubType (BootOption->DevicePath) == BBS_BBS_DP)) {
     
    120120        StartPosition = MIN (StartPosition, Index);
    121121        NewBootOption[DevOrderCount] = BootOrder[Index];
    122        
     122
    123123        if ((DevOrder[DevOrderCount] & 0xFF00) == 0xFF00) {
    124124          (*DisBootOption)[*DisBootOptionCount] = BootOrder[Index];
     
    157157  Group the legacy boot options in the BootOption.
    158158
    159   The routine assumes the boot options in the beginning that covers all the device 
     159  The routine assumes the boot options in the beginning that covers all the device
    160160  types are ordered properly and re-position the following boot options just after
    161161  the corresponding boot options with the same device type.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/BBSsupport.h

    r58459 r58466  
    4040  Group the legacy boot options in the BootOption.
    4141
    42   The routine assumes the boot options in the beginning that covers all the device 
     42  The routine assumes the boot options in the beginning that covers all the device
    4343  types are ordered properly and re-position the following boot options just after
    4444  the corresponding boot options with the same device type.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/Bm.vfr

    • Property svn:eol-style set to native
    r58459 r58466  
    11///** @file
    2 // 
     2//
    33//    Boot Maintenance Utility Formset
    4 // 
     4//
    55//  Copyright (c) 2004 - 2010, Intel Corporation. All rights reserved.<BR>
    66//  This program and the accompanying materials
     
    88//  which accompanies this distribution.  The full text of the license may be found at
    99//  http://opensource.org/licenses/bsd-license.php
    10 // 
     10//
    1111//  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1212//  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    13 // 
     13//
    1414//**/
    1515
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/BmLib.c

    r58459 r58466  
    147147  @param VarName           A Null-terminated Unicode string that is
    148148                           the name of the vendor's variable.
    149                          
     149
    150150  @param VarGuid           A unique identifier for the vendor.
    151151
     
    362362
    363363/**
    364   Get a string from the Data Hub record based on 
     364  Get a string from the Data Hub record based on
    365365  a device path.
    366366
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/Bmstring.uni

    • Property svn:mime-type changed from application/octet-stream to text/plain;encoding=UTF-16LE
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/BootMaint.c

    r58459 r58466  
    4444    END_DEVICE_PATH_TYPE,
    4545    END_ENTIRE_DEVICE_PATH_SUBTYPE,
    46     { 
     46    {
    4747      (UINT8) (END_DEVICE_PATH_LENGTH),
    4848      (UINT8) ((END_DEVICE_PATH_LENGTH) >> 8)
     
    6666    END_DEVICE_PATH_TYPE,
    6767    END_ENTIRE_DEVICE_PATH_SUBTYPE,
    68     { 
     68    {
    6969      (UINT8) (END_DEVICE_PATH_LENGTH),
    7070      (UINT8) ((END_DEVICE_PATH_LENGTH) >> 8)
     
    144144  //
    145145  // Initialize data which located in Console Options Menu
    146   // 
    147   GetConsoleOutMode (CallbackData); 
     146  //
     147  GetConsoleOutMode (CallbackData);
    148148  GetConsoleInCheck (CallbackData);
    149149  GetConsoleOutCheck (CallbackData);
     
    315315  @param[in]  This                Points to the EFI_HII_CONFIG_ACCESS_PROTOCOL.
    316316  @param[in]  Configuration       A null-terminated Unicode string in
    317                                   <ConfigString> format.   
     317                                  <ConfigString> format.
    318318  @param[out] Progress            A pointer to a string filled in with the
    319319                                  offset of the most recent '&' before the
     
    325325
    326326  @retval EFI_SUCCESS             The results have been distributed or are
    327                                   awaiting distribution. 
     327                                  awaiting distribution.
    328328  @retval EFI_OUT_OF_RESOURCES    Not enough memory to store the
    329329                                  parts of the results that must be
     
    353353  BM_MENU_ENTRY                   *NewMenuEntry;
    354354  BM_LOAD_CONTEXT                 *NewLoadContext;
    355   UINT16                          Index; 
     355  UINT16                          Index;
    356356  BOOLEAN                         TerminalAttChange;
    357   BMM_CALLBACK_DATA               *Private; 
     357  BMM_CALLBACK_DATA               *Private;
    358358
    359359  if (Progress == NULL) {
     
    375375
    376376  Status = gBS->LocateProtocol (
    377                   &gEfiHiiConfigRoutingProtocolGuid, 
    378                   NULL, 
     377                  &gEfiHiiConfigRoutingProtocolGuid,
     378                  NULL,
    379379                  (VOID**) &ConfigRouting
    380380                  );
     
    402402  ASSERT_EFI_ERROR (Status);
    403403  //
    404   // Compare new and old BMM configuration data and only do action for modified item to 
     404  // Compare new and old BMM configuration data and only do action for modified item to
    405405  // avoid setting unnecessary non-volatile variable
    406406  //
     
    430430
    431431  //
    432   // Change for "delete boot option" page need update NewBmmData->BootOptionOrder, so process 
     432  // Change for "delete boot option" page need update NewBmmData->BootOptionOrder, so process
    433433  // NewBmmData->BootOptionOrder before NewBmmData->BootOptionDel
    434434  //
    435   if (CompareMem (NewBmmData->BootOptionOrder, OldBmmData->BootOptionOrder, sizeof (NewBmmData->BootOptionOrder)) != 0) { 
     435  if (CompareMem (NewBmmData->BootOptionOrder, OldBmmData->BootOptionOrder, sizeof (NewBmmData->BootOptionOrder)) != 0) {
    436436    Status = Var_UpdateBootOrder (Private);
    437437  }
    438438
    439439  //
    440   // Change for "delete driver option" page need update NewBmmData->DriverOptionOrder, so process 
     440  // Change for "delete driver option" page need update NewBmmData->DriverOptionOrder, so process
    441441  // NewBmmData->DriverOptionOrder before NewBmmData->DriverOptionDel
    442442  //
    443   if (CompareMem (NewBmmData->DriverOptionOrder, OldBmmData->DriverOptionOrder, sizeof (NewBmmData->DriverOptionOrder)) != 0) { 
     443  if (CompareMem (NewBmmData->DriverOptionOrder, OldBmmData->DriverOptionOrder, sizeof (NewBmmData->DriverOptionOrder)) != 0) {
    444444    Status = Var_UpdateDriverOrder (Private);
    445445  }
     
    448448  // Check data which located in Boot Options Menu and save the settings if need
    449449  //
    450   if (CompareMem (NewBmmData->BootOptionDel, OldBmmData->BootOptionDel, sizeof (NewBmmData->BootOptionDel)) != 0) { 
    451     for (Index = 0; 
    452          ((Index < BootOptionMenu.MenuNumber) && (Index < (sizeof (NewBmmData->BootOptionDel) / sizeof (NewBmmData->BootOptionDel[0])))); 
     450  if (CompareMem (NewBmmData->BootOptionDel, OldBmmData->BootOptionDel, sizeof (NewBmmData->BootOptionDel)) != 0) {
     451    for (Index = 0;
     452         ((Index < BootOptionMenu.MenuNumber) && (Index < (sizeof (NewBmmData->BootOptionDel) / sizeof (NewBmmData->BootOptionDel[0]))));
    453453         Index ++) {
    454454      NewMenuEntry            = BOpt_GetMenuEntry (&BootOptionMenu, Index);
     
    465465  // Check data which located in Driver Options Menu and save the settings if need
    466466  //
    467   if (CompareMem (NewBmmData->DriverOptionDel, OldBmmData->DriverOptionDel, sizeof (NewBmmData->DriverOptionDel)) != 0) {       
    468     for (Index = 0; 
    469          ((Index < DriverOptionMenu.MenuNumber) && (Index < (sizeof (NewBmmData->DriverOptionDel) / sizeof (NewBmmData->DriverOptionDel[0])))); 
     467  if (CompareMem (NewBmmData->DriverOptionDel, OldBmmData->DriverOptionDel, sizeof (NewBmmData->DriverOptionDel)) != 0) {
     468    for (Index = 0;
     469         ((Index < DriverOptionMenu.MenuNumber) && (Index < (sizeof (NewBmmData->DriverOptionDel) / sizeof (NewBmmData->DriverOptionDel[0]))));
    470470         Index++) {
    471471      NewMenuEntry            = BOpt_GetMenuEntry (&DriverOptionMenu, Index);
     
    491491    // Bugbug: code not exit in UiApp but in IntelFrameworkModulePkg, need do more check.
    492492    //
    493     Private->BmmOldFakeNVData.BootTimeOut = NewBmmData->BootTimeOut; 
     493    Private->BmmOldFakeNVData.BootTimeOut = NewBmmData->BootTimeOut;
    494494  }
    495495
     
    498498  }
    499499
    500   if (CompareMem (&NewBmmData->ConsoleOutMode, &OldBmmData->ConsoleOutMode, sizeof (NewBmmData->ConsoleOutMode)) != 0) { 
     500  if (CompareMem (&NewBmmData->ConsoleOutMode, &OldBmmData->ConsoleOutMode, sizeof (NewBmmData->ConsoleOutMode)) != 0) {
    501501    Var_UpdateConMode (Private);
    502502  }
     
    571571  }
    572572
    573   if (CompareMem (NewBmmData->ConsoleErrCheck, OldBmmData->ConsoleErrCheck, sizeof (NewBmmData->ConsoleErrCheck)) != 0) { 
     573  if (CompareMem (NewBmmData->ConsoleErrCheck, OldBmmData->ConsoleErrCheck, sizeof (NewBmmData->ConsoleErrCheck)) != 0) {
    574574    for (Index = 0; Index < ConsoleErrMenu.MenuNumber; Index++) {
    575575      NewMenuEntry                = BOpt_GetMenuEntry (&ConsoleErrMenu, Index);
     
    601601  RefreshUpdateData ();
    602602  mStartLabel->Number = FORM_BOOT_LEGACY_DEVICE_ID;
    603  
     603
    604604  //
    605605  // If LegacyBios Protocol is installed, add 3 tags about legacy boot option
     
    650650    FORM_SET_BEV_ORDER_ID
    651651    );
    652  
     652
    653653  HiiUpdateForm (
    654654    mBmmCallbackInfo->BmmHiiHandle,
     
    658658    mEndOpCodeHandle    // LABEL_END
    659659    );
    660  
     660
    661661  return EFI_SUCCESS;
    662662}
     
    701701  UINTN             Bit;
    702702  UINT16            NewValuePos;
    703   UINT16            Index3; 
     703  UINT16            Index3;
    704704  UINT16            Index2;
    705705  UINT16            Index;
     
    718718      InitializeLegacyBootOption ();
    719719    }
    720    
     720
    721721    return EFI_SUCCESS;
    722722  }
    723723
    724   if (Action != EFI_BROWSER_ACTION_CHANGING && Action != EFI_BROWSER_ACTION_CHANGED) {   
     724  if (Action != EFI_BROWSER_ACTION_CHANGING && Action != EFI_BROWSER_ACTION_CHANGED) {
    725725    //
    726726    // All other action return unsupported.
     
    728728    return EFI_UNSUPPORTED;
    729729  }
    730  
     730
    731731  Status       = EFI_SUCCESS;
    732732  OldValue     = 0;
     
    748748      return EFI_INVALID_PARAMETER;
    749749    }
    750    
     750
    751751    UpdatePageId (Private, QuestionId);
    752752
     
    10221022        DiscardChangeHandler (Private, CurrentFakeNVMap);
    10231023        *ActionRequest = EFI_BROWSER_ACTION_REQUEST_FORM_DISCARD_EXIT;
    1024         break; 
     1024        break;
    10251025
    10261026      case FORM_RESET:
     
    11221122
    11231123  Status = EFI_SUCCESS;
    1124   BmmCallbackInfo = mBmmCallbackInfo; 
     1124  BmmCallbackInfo = mBmmCallbackInfo;
    11251125
    11261126  BmmCallbackInfo->BmmPreviousPageId             = FORM_MAIN_ID;
     
    11321132  // Reinstall String packages to include more new strings.
    11331133  //
    1134  
     1134
    11351135  //
    11361136  // String package size
     
    11391139
    11401140  //
    1141   // Add the length of the Package List Header and the terminating Package Header 
     1141  // Add the length of the Package List Header and the terminating Package Header
    11421142  //
    11431143  Length += sizeof (EFI_HII_PACKAGE_LIST_HEADER) + sizeof (EFI_HII_PACKAGE_HEADER);
    1144  
     1144
    11451145  //
    11461146  // Allocate the storage for the entire Package List
     
    11611161
    11621162  //
    1163   // Copy String Data into Package list. 
     1163  // Copy String Data into Package list.
    11641164  //
    11651165  Data = (UINT8 *)(PackageListHeader + 1);
    11661166  Length = ReadUnaligned32 ((UINT32 *) BdsDxeStrings) - sizeof (UINT32);
    11671167  CopyMem (Data, (UINT8 *) BdsDxeStrings + sizeof (UINT32), Length);
    1168  
     1168
    11691169  //
    11701170  // Add End type HII package.
     
    11791179  CopyGuid (&PackageListHeader->PackageListGuid, &gBootMaintFormSetGuid);
    11801180  Status = gHiiDatabase->UpdatePackageList (gHiiDatabase, BmmCallbackInfo->BmmHiiHandle, PackageListHeader);
    1181  
     1181
    11821182  //
    11831183  // Update String package for FE.
     
    11851185  CopyGuid (&PackageListHeader->PackageListGuid, &gFileExploreFormSetGuid);
    11861186  Status = gHiiDatabase->UpdatePackageList (gHiiDatabase, BmmCallbackInfo->FeHiiHandle, PackageListHeader);
    1187  
     1187
    11881188  FreePool (PackageListHeader);
    11891189
     
    12271227  CreateMenuStringToken (BmmCallbackInfo, BmmCallbackInfo->BmmHiiHandle, &TerminalMenu);
    12281228  CreateMenuStringToken (BmmCallbackInfo, BmmCallbackInfo->BmmHiiHandle, &DriverMenu);
    1229  
     1229
    12301230  InitializeBmmConfig (BmmCallbackInfo);
    12311231
     
    12391239  //
    12401240  CleanUpStringDepository ();
    1241  
     1241
    12421242  FreeAllMenu ();
    12431243
     
    15451545  EFI_STATUS                  Status;
    15461546  UINT8                       *Ptr;
    1547  
     1547
    15481548  //
    15491549  // Create CallbackData structures for Driver Callback
     
    15531553    return EFI_OUT_OF_RESOURCES;
    15541554  }
    1555  
     1555
    15561556  //
    15571557  // Create LoadOption in BmmCallbackInfo for Driver Callback
     
    16341634                                   );
    16351635  ASSERT (BmmCallbackInfo->FeHiiHandle != NULL);
    1636  
     1636
    16371637  mBmmCallbackInfo = BmmCallbackInfo;
    1638  
    1639   return EFI_SUCCESS; 
     1638
     1639  return EFI_SUCCESS;
    16401640}
    16411641
     
    16841684  FreePool (BmmCallbackInfo);
    16851685
    1686   mBmmCallbackInfo = NULL; 
    1687  
     1686  mBmmCallbackInfo = NULL;
     1687
    16881688  return;
    16891689}
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/BootMaint.h

    r58459 r58466  
    474474  @return EFI_SUCESS The functin completes successfully.
    475475  @retval EFI_OUT_OF_RESOURCES Not enough memory to compete the operation.
    476  
     476
    477477
    478478**/
     
    718718/**
    719719  Update the multi-instance device path of Terminal Device based on
    720   the global TerminalMenu. If ChangeTernimal is TRUE, the terminal 
     720  the global TerminalMenu. If ChangeTernimal is TRUE, the terminal
    721721  device path in the Terminal Device in TerminalMenu is also updated.
    722722
    723723  @param DevicePath      The multi-instance device path.
    724   @param ChangeTerminal  TRUE, then device path in the Terminal Device 
     724  @param ChangeTerminal  TRUE, then device path in the Terminal Device
    725725                         in TerminalMenu is also updated; FALSE, no update.
    726726
     
    738738//
    739739/**
    740   This function create a currently loaded Boot Option from 
    741   the BMM. It then appends this Boot Option to the end of 
     740  This function create a currently loaded Boot Option from
     741  the BMM. It then appends this Boot Option to the end of
    742742  the "BootOrder" list. It also append this Boot Opotion to the end
    743743  of BootOptionMenu.
     
    761761  make sure BootOrder is in valid state.
    762762
    763   @retval EFI_SUCCESS   If all boot load option EFI Variables corresponding to 
     763  @retval EFI_SUCCESS   If all boot load option EFI Variables corresponding to
    764764                        BM_LOAD_CONTEXT marked for deletion is deleted
    765   @return Others        If failed to update the "BootOrder" variable after deletion. 
     765  @return Others        If failed to update the "BootOrder" variable after deletion.
    766766
    767767**/
     
    787787
    788788/**
    789   This function create a currently loaded Drive Option from 
    790   the BMM. It then appends this Driver Option to the end of 
     789  This function create a currently loaded Drive Option from
     790  the BMM. It then appends this Driver Option to the end of
    791791  the "DriverOrder" list. It append this Driver Opotion to the end
    792792  of DriverOptionMenu.
     
    877877
    878878/**
    879   Update the device path of "ConOut", "ConIn" and "ErrOut" based on the new BaudRate, Data Bits, 
     879  Update the device path of "ConOut", "ConIn" and "ErrOut" based on the new BaudRate, Data Bits,
    880880  parity and stop Bits set.
    881881
     
    887887
    888888/**
    889   This function update the "BootNext" EFI Variable. If there is no "BootNex" specified in BMM, 
     889  This function update the "BootNext" EFI Variable. If there is no "BootNex" specified in BMM,
    890890  this EFI Variable is deleted.
    891891  It also update the BMM context data specified the "BootNext" value.
     
    903903
    904904/**
    905   This function update the "BootOrder" EFI Variable based on BMM Formset's NV map. It then refresh 
     905  This function update the "BootOrder" EFI Variable based on BMM Formset's NV map. It then refresh
    906906  BootOptionMenu with the new "BootOrder" list.
    907907
     
    981981/**
    982982  Clean up the dynamic opcode at label and form specified by
    983   both LabelId. 
     983  both LabelId.
    984984
    985985  @param LabelId         It is both the Form ID and Label ID for
     
    11781178  @param VarName            A Null-terminated Unicode string that is
    11791179                            the name of the vendor's variable.
    1180                          
     1180
    11811181  @param VarGuid            A unique identifier for the vendor.
    11821182
     
    12431243
    12441244/**
    1245   Get a string from the Data Hub record based on 
     1245  Get a string from the Data Hub record based on
    12461246  a device path.
    12471247
     
    14511451  @param[in]  This                Points to the EFI_HII_CONFIG_ACCESS_PROTOCOL.
    14521452  @param[in]  Configuration       A null-terminated Unicode string in
    1453                                   <ConfigString> format.   
     1453                                  <ConfigString> format.
    14541454  @param[out] Progress            A pointer to a string filled in with the
    14551455                                  offset of the most recent '&' before the
     
    14611461
    14621462  @retval EFI_SUCCESS             The results have been distributed or are
    1463                                   awaiting distribution. 
     1463                                  awaiting distribution.
    14641464  @retval EFI_OUT_OF_RESOURCES    Not enough memory to store the
    14651465                                  parts of the results that must be
     
    15141514
    15151515/**
    1516   Get option number according to Boot#### and BootOrder variable. 
     1516  Get option number according to Boot#### and BootOrder variable.
    15171517  The value is saved as #### + 1.
    15181518
    15191519  @param CallbackData    The BMM context data.
    15201520**/
    1521 VOID 
     1521VOID
    15221522GetBootOrder (
    15231523  IN  BMM_CALLBACK_DATA    *CallbackData
     
    15281528
    15291529  @param CallbackData    The BMM context data.
    1530  
    1531 **/
    1532 VOID 
     1530
     1531**/
     1532VOID
    15331533GetDriverOrder (
    15341534  IN  BMM_CALLBACK_DATA    *CallbackData
     
    15631563  IN  BMM_CALLBACK_DATA    *CallbackData
    15641564  );
    1565  
     1565
    15661566/**
    15671567
     
    15711571  @param CallbackData    The BMM context data.
    15721572
    1573 **/ 
    1574 VOID 
     1573**/
     1574VOID
    15751575GetConsoleInCheck (
    15761576  IN  BMM_CALLBACK_DATA    *CallbackData
    15771577  );
    1578  
     1578
    15791579/**
    15801580
     
    15841584  @param CallbackData    The BMM context data.
    15851585
    1586 **/     
    1587 VOID   
     1586**/
     1587VOID
    15881588GetConsoleOutCheck (
    15891589  IN  BMM_CALLBACK_DATA    *CallbackData
     
    15971597  @param CallbackData    The BMM context data.
    15981598
    1599 **/       
    1600 VOID 
     1599**/
     1600VOID
    16011601GetConsoleErrCheck (
    16021602  IN  BMM_CALLBACK_DATA    *CallbackData
     
    16101610  @param CallbackData    The BMM context data.
    16111611
    1612 **/       
    1613 VOID 
     1612**/
     1613VOID
    16141614GetTerminalAttribute (
    16151615  IN  BMM_CALLBACK_DATA    *CallbackData
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/BootOption.c

    r58459 r58466  
    877877  UINTN                     MenuCount;
    878878  UINT8                     *Ptr;
    879  
     879
    880880  MenuCount         = 0;
    881881  BootOrderListSize = 0;
     
    898898    return EFI_NOT_FOUND;
    899899  }
    900  
     900
    901901  //
    902902  // Get the BootNext from the Var
     
    10121012    NewLoadContext->FilePathListLength = *(UINT16 *) LoadOptionPtr;
    10131013    LoadOptionPtr += sizeof (UINT16);
    1014    
     1014
    10151015    StringSize = StrSize((UINT16*)LoadOptionPtr);
    10161016
     
    10181018    ASSERT (NewLoadContext->Description != NULL);
    10191019    StrCpy (NewLoadContext->Description, (UINT16*)LoadOptionPtr);
    1020    
     1020
    10211021    ASSERT (NewLoadContext->Description != NULL);
    10221022    NewMenuEntry->DisplayString = NewLoadContext->Description;
     
    11041104  ASSERT (Str != NULL);
    11051105
    1106   TmpStr = AllocateZeroPool (Size1 + Size2 + sizeof (CHAR16)); 
     1106  TmpStr = AllocateZeroPool (Size1 + Size2 + sizeof (CHAR16));
    11071107  ASSERT (TmpStr != NULL);
    11081108
     
    11251125
    11261126      //
    1127       // Use TmpStr as a backup, as StrCpy in BaseLib does not handle copy of two strings 
     1127      // Use TmpStr as a backup, as StrCpy in BaseLib does not handle copy of two strings
    11281128      // that overlap.
    11291129      //
     
    11371137
    11381138      //
    1139       // Use TmpStr as a backup, as StrCpy in BaseLib does not handle copy of two strings 
     1139      // Use TmpStr as a backup, as StrCpy in BaseLib does not handle copy of two strings
    11401140      // that overlap.
    11411141      //
     
    11511151
    11521152  FreePool (TmpStr);
    1153  
     1153
    11541154  return Str;
    11551155}
     
    15021502    return EFI_NOT_FOUND;
    15031503  }
    1504  
     1504
    15051505  for (Index = 0; Index < DriverOrderListSize / sizeof (UINT16); Index++) {
    15061506    UnicodeSPrint (
     
    16811681  UINTN                     OptionIndex;
    16821682  UINT16                    PageIdList[5];
    1683   UINTN                     PageNum; 
     1683  UINTN                     PageNum;
    16841684  UINTN                     VarSize;
    1685   UINT8                     *VarData;     
    1686   UINT8                     *WorkingVarData; 
     1685  UINT8                     *VarData;
     1686  UINT8                     *WorkingVarData;
    16871687  LEGACY_DEV_ORDER_ENTRY    *DevOrder;
    1688   UINT16                    VarDevOrder; 
    1689   UINT8                     *DisMap; 
     1688  UINT16                    VarDevOrder;
     1689  UINT8                     *DisMap;
    16901690  BM_MENU_OPTION            *OptionMenu;
    16911691  BBS_TYPE                  BbsType;
    16921692  UINT8                     *LegacyOrder;
    1693   UINT8                     *OldData; 
     1693  UINT8                     *OldData;
    16941694  UINTN                     Pos;
    16951695  UINTN                     Bit;
    1696  
     1696
    16971697  ASSERT (CallbackData != NULL);
    16981698
     
    17161716  for (Index = 0; Index < PageNum; Index++) {
    17171717    switch (PageIdList[Index]) {
    1718      
     1718
    17191719    case FORM_SET_FD_ORDER_ID:
    17201720      OptionMenu  = (BM_MENU_OPTION *) &LegacyFDMenu;
     
    17301730      OldData     = CallbackData->BmmOldFakeNVData.LegacyHD;
    17311731      break;
    1732    
     1732
    17331733    case FORM_SET_CD_ORDER_ID:
    17341734      OptionMenu  = (BM_MENU_OPTION *) &LegacyCDMenu;
     
    17371737      OldData     = CallbackData->BmmOldFakeNVData.LegacyCD;
    17381738      break;
    1739    
     1739
    17401740    case FORM_SET_NET_ORDER_ID:
    17411741      OptionMenu  = (BM_MENU_OPTION *) &LegacyNETMenu;
     
    17531753      break;
    17541754    }
    1755    
     1755
    17561756    if (NULL != VarData) {
    17571757      WorkingVarData = VarData;
     
    17611761          break;
    17621762        }
    1763    
     1763
    17641764        WorkingVarData  = (UINT8 *)((UINTN)WorkingVarData + sizeof (BBS_TYPE));
    17651765        WorkingVarData += *(UINT16 *) WorkingVarData;
    17661766        DevOrder = (LEGACY_DEV_ORDER_ENTRY *) WorkingVarData;
    1767       } 
     1767      }
    17681768      for (OptionIndex = 0; OptionIndex < OptionMenu->MenuNumber; OptionIndex++) {
    17691769        VarDevOrder = *(UINT16 *) ((UINTN) DevOrder + sizeof (BBS_TYPE) + sizeof (UINT16) + OptionIndex * sizeof (UINT16));
     
    17761776          LegacyOrder[OptionIndex] = (UINT8) (VarDevOrder & 0xFF);
    17771777        }
    1778       } 
     1778      }
    17791779      CopyMem (OldData, LegacyOrder, 100);
    17801780    }
    1781   } 
     1781  }
    17821782}
    17831783
     
    17861786
    17871787  @param CallbackData    The BMM context data.
    1788  
     1788
    17891789**/
    17901790VOID
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/ConsoleOption.c

    r58459 r58466  
    3333
    3434  @param[in] FlowControl    The device path node to be checked.
    35  
     35
    3636  @retval TRUE              It's the Flow Control node.
    3737  @retval FALSE             It's not.
     
    8686/**
    8787  Update the multi-instance device path of Terminal Device based on
    88   the global TerminalMenu. If ChangeTernimal is TRUE, the terminal 
     88  the global TerminalMenu. If ChangeTernimal is TRUE, the terminal
    8989  device path in the Terminal Device in TerminalMenu is also updated.
    9090
    9191  @param DevicePath      The multi-instance device path.
    92   @param ChangeTerminal  TRUE, then device path in the Terminal Device 
     92  @param ChangeTerminal  TRUE, then device path in the Terminal Device
    9393                         in TerminalMenu is also updated; FALSE, no update.
    9494
     
    761761
    762762  @retval EFI_UNSUPPORTED The type passed in is not in the 3 types defined.
    763   @retval EFI_NOT_FOUND   If the EFI Variable defined in UEFI spec with name "ConOutDev", 
     763  @retval EFI_NOT_FOUND   If the EFI Variable defined in UEFI spec with name "ConOutDev",
    764764                          "ConInDev" or "ConErrDev" doesn't exists.
    765765  @retval EFI_OUT_OF_RESOURCES Not enough resource to complete the operations.
     
    10581058  @param CallbackData    The BMM context data.
    10591059
    1060 **/ 
    1061 VOID 
     1060**/
     1061VOID
    10621062GetConsoleInCheck (
    10631063  IN  BMM_CALLBACK_DATA    *CallbackData
     
    10651065{
    10661066  UINT16              Index;
    1067   BM_MENU_ENTRY       *NewMenuEntry; 
     1067  BM_MENU_ENTRY       *NewMenuEntry;
    10681068  UINT8               *ConInCheck;
    10691069  BM_CONSOLE_CONTEXT  *NewConsoleContext;
    1070  
     1070
    10711071  ASSERT (CallbackData != NULL);
    1072    
     1072
    10731073  ConInCheck = &CallbackData->BmmFakeNvData.ConsoleInCheck[0];
    10741074  for (Index = 0; ((Index < ConsoleInpMenu.MenuNumber) && \
    1075        (Index < MAX_MENU_NUMBER)) ; Index++) { 
     1075       (Index < MAX_MENU_NUMBER)) ; Index++) {
    10761076    NewMenuEntry      = BOpt_GetMenuEntry (&ConsoleInpMenu, Index);
    1077     NewConsoleContext = (BM_CONSOLE_CONTEXT *) NewMenuEntry->VariableContext; 
     1077    NewConsoleContext = (BM_CONSOLE_CONTEXT *) NewMenuEntry->VariableContext;
    10781078    ConInCheck[Index] = NewConsoleContext->IsActive;
    10791079  }
     
    10871087  @param CallbackData    The BMM context data.
    10881088
    1089 **/     
    1090 VOID   
     1089**/
     1090VOID
    10911091GetConsoleOutCheck (
    10921092  IN  BMM_CALLBACK_DATA    *CallbackData
     
    10941094{
    10951095  UINT16              Index;
    1096   BM_MENU_ENTRY       *NewMenuEntry; 
     1096  BM_MENU_ENTRY       *NewMenuEntry;
    10971097  UINT8               *ConOutCheck;
    10981098  BM_CONSOLE_CONTEXT  *NewConsoleContext;
    1099  
     1099
    11001100  ASSERT (CallbackData != NULL);
    11011101  ConOutCheck = &CallbackData->BmmFakeNvData.ConsoleOutCheck[0];
    11021102  for (Index = 0; ((Index < ConsoleOutMenu.MenuNumber) && \
    1103        (Index < MAX_MENU_NUMBER)) ; Index++) { 
     1103       (Index < MAX_MENU_NUMBER)) ; Index++) {
    11041104    NewMenuEntry      = BOpt_GetMenuEntry (&ConsoleOutMenu, Index);
    1105     NewConsoleContext = (BM_CONSOLE_CONTEXT *) NewMenuEntry->VariableContext; 
     1105    NewConsoleContext = (BM_CONSOLE_CONTEXT *) NewMenuEntry->VariableContext;
    11061106    ConOutCheck[Index] = NewConsoleContext->IsActive;
    11071107  }
    11081108}
    1109  
     1109
    11101110/**
    11111111
     
    11151115  @param CallbackData    The BMM context data.
    11161116
    1117 **/       
    1118 VOID 
     1117**/
     1118VOID
    11191119GetConsoleErrCheck (
    11201120  IN  BMM_CALLBACK_DATA    *CallbackData
     
    11221122{
    11231123  UINT16              Index;
    1124   BM_MENU_ENTRY       *NewMenuEntry; 
     1124  BM_MENU_ENTRY       *NewMenuEntry;
    11251125  UINT8               *ConErrCheck;
    11261126  BM_CONSOLE_CONTEXT  *NewConsoleContext;
    1127  
     1127
    11281128  ASSERT (CallbackData != NULL);
    11291129  ConErrCheck = &CallbackData->BmmFakeNvData.ConsoleErrCheck[0];
    11301130  for (Index = 0; ((Index < ConsoleErrMenu.MenuNumber) && \
    1131        (Index < MAX_MENU_NUMBER)) ; Index++) { 
     1131       (Index < MAX_MENU_NUMBER)) ; Index++) {
    11321132    NewMenuEntry      = BOpt_GetMenuEntry (&ConsoleErrMenu, Index);
    1133     NewConsoleContext = (BM_CONSOLE_CONTEXT *) NewMenuEntry->VariableContext; 
     1133    NewConsoleContext = (BM_CONSOLE_CONTEXT *) NewMenuEntry->VariableContext;
    11341134    ConErrCheck[Index] = NewConsoleContext->IsActive;
    11351135  }
     
    11431143  @param CallbackData    The BMM context data.
    11441144
    1145 **/       
    1146 VOID 
     1145**/
     1146VOID
    11471147GetTerminalAttribute (
    11481148  IN  BMM_CALLBACK_DATA    *CallbackData
     
    11511151  BMM_FAKE_NV_DATA     *CurrentFakeNVMap;
    11521152  BM_MENU_ENTRY        *NewMenuEntry;
    1153   BM_TERMINAL_CONTEXT  *NewTerminalContext;   
    1154   UINT16               TerminalIndex; 
     1153  BM_TERMINAL_CONTEXT  *NewTerminalContext;
     1154  UINT16               TerminalIndex;
    11551155  UINT8                AttributeIndex;
    11561156
    11571157  ASSERT (CallbackData != NULL);
    1158  
    1159   CurrentFakeNVMap = &CallbackData->BmmFakeNvData;     
     1158
     1159  CurrentFakeNVMap = &CallbackData->BmmFakeNvData;
    11601160  for (TerminalIndex = 0; ((TerminalIndex < TerminalMenu.MenuNumber) && \
    1161        (TerminalIndex < MAX_MENU_NUMBER)); TerminalIndex++) { 
     1161       (TerminalIndex < MAX_MENU_NUMBER)); TerminalIndex++) {
    11621162    NewMenuEntry        = BOpt_GetMenuEntry (&TerminalMenu, TerminalIndex);
    11631163    NewTerminalContext  = (BM_TERMINAL_CONTEXT *) NewMenuEntry->VariableContext;
     
    11731173        break;
    11741174      }
    1175     }   
    1176    
     1175    }
     1176
    11771177    for (AttributeIndex = 0; AttributeIndex < sizeof (ParityList) / sizeof (ParityList[0]); AttributeIndex++) {
    11781178      if (NewTerminalContext->Parity == (UINT64) (ParityList[AttributeIndex].Value)) {
     
    11801180        break;
    11811181      }
    1182     }           
    1183    
     1182    }
     1183
    11841184    for (AttributeIndex = 0; AttributeIndex < sizeof (StopBitsList) / sizeof (StopBitsList[0]); AttributeIndex++) {
    11851185      if (NewTerminalContext->StopBits == (UINT64) (StopBitsList[AttributeIndex].Value)) {
     
    11871187        break;
    11881188      }
    1189     }       
     1189    }
    11901190    CurrentFakeNVMap->COMBaudRate[TerminalIndex]     = NewTerminalContext->BaudRateIndex;
    11911191    CurrentFakeNVMap->COMDataRate[TerminalIndex]     = NewTerminalContext->DataBitsIndex;
    11921192    CurrentFakeNVMap->COMStopBits[TerminalIndex]     = NewTerminalContext->StopBitsIndex;
    1193     CurrentFakeNVMap->COMParity[TerminalIndex]       = NewTerminalContext->ParityIndex; 
     1193    CurrentFakeNVMap->COMParity[TerminalIndex]       = NewTerminalContext->ParityIndex;
    11941194    CurrentFakeNVMap->COMTerminalType[TerminalIndex] = NewTerminalContext->TerminalType;
    11951195    CurrentFakeNVMap->COMFlowControl[TerminalIndex]  = NewTerminalContext->FlowControl;
    1196   } 
    1197 }
    1198 
     1196  }
     1197}
     1198
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/FE.vfr

    • Property svn:eol-style set to native
    r58459 r58466  
    11///** @file
    2 // 
     2//
    33//    File Explorer Formset
    4 // 
     4//
    55//  Copyright (c) 2004 - 2014, Intel Corporation. All rights reserved.<BR>
    66//  This program and the accompanying materials
     
    88//  which accompanies this distribution.  The full text of the license may be found at
    99//  http://opensource.org/licenses/bsd-license.php
    10 // 
     10//
    1111//  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1212//  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    13 // 
     13//
    1414//**/
    1515
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/FileExplorer.c

    r58459 r58466  
    237237  @param[in]  This                Points to the EFI_HII_CONFIG_ACCESS_PROTOCOL.
    238238  @param[in]  Configuration       A null-terminated Unicode string in
    239                                   <ConfigString> format.   
     239                                  <ConfigString> format.
    240240  @param[out] Progress            A pointer to a string filled in with the
    241241                                  offset of the most recent '&' before the
     
    247247
    248248  @retval EFI_SUCCESS             The results have been distributed or are
    249                                   awaiting distribution. 
     249                                  awaiting distribution.
    250250  @retval EFI_OUT_OF_RESOURCES    Not enough memory to store the
    251251                                  parts of the results that must be
     
    290290
    291291  Status = gBS->LocateProtocol (
    292                   &gEfiHiiConfigRoutingProtocolGuid, 
    293                   NULL, 
     292                  &gEfiHiiConfigRoutingProtocolGuid,
     293                  NULL,
    294294                  (VOID**) &ConfigRouting
    295295                  );
     
    394394    return EFI_UNSUPPORTED;
    395395  }
    396  
     396
    397397  Status         = EFI_SUCCESS;
    398398  Private        = FE_CALLBACK_DATA_FROM_THIS (This);
     
    408408      return EFI_INVALID_PARAMETER;
    409409    }
    410    
     410
    411411    if (QuestionId == KEY_VALUE_SAVE_AND_EXIT_BOOT) {
    412412      NvRamMap->BootOptionChanged = FALSE;
     
    452452      return EFI_INVALID_PARAMETER;
    453453    }
    454    
     454
    455455    if (QuestionId >= FILE_OPTION_GOTO_OFFSET) {
    456456      //
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/UpdatePage.c

    r58459 r58466  
    2626  //
    2727  // Free current updated date
    28   // 
     28  //
    2929  if (mStartOpCodeHandle != NULL) {
    3030    HiiFreeOpCodeHandle (mStartOpCodeHandle);
     
    4747  Add a "Go back to main page" tag in front of the form when there are no
    4848  "Apply changes" and "Discard changes" tags in the end of the form.
    49  
     49
    5050  @param CallbackData    The BMM context data.
    5151
     
    132132
    133133/**
    134   Clean up the dynamic opcode at label and form specified by both LabelId. 
     134  Clean up the dynamic opcode at label and form specified by both LabelId.
    135135
    136136  @param LabelId         It is both the Form ID and Label ID for opcode deletion.
     
    346346
    347347  CreateMenuStringToken (CallbackData, CallbackData->BmmHiiHandle, &DriverOptionMenu);
    348  
     348
    349349  ASSERT (DriverOptionMenu.MenuNumber <= (sizeof (CallbackData->BmmFakeNvData.DriverOptionDel) / sizeof (CallbackData->BmmFakeNvData.DriverOptionDel[0])));
    350350  for (Index = 0; Index < DriverOptionMenu.MenuNumber; Index++) {
     
    381381
    382382/**
    383   Prepare the page to allow user to add description for 
     383  Prepare the page to allow user to add description for
    384384  a Driver Option.
    385385
     
    554554
    555555  CreateMenuStringToken (CallbackData, CallbackData->BmmHiiHandle, OptionMenu);
    556  
     556
    557557  OptionOrder = NULL;
    558558  QuestionId = 0;
    559559  VarOffset = 0;
    560   switch (UpdatePageId) { 
     560  switch (UpdatePageId) {
    561561
    562562  case FORM_BOOT_CHG_ID:
     
    573573    VarOffset = DRIVER_OPTION_ORDER_VAR_OFFSET;
    574574    break;
    575   } 
     575  }
    576576  ASSERT (OptionOrder != NULL);
    577577
    578578  OptionsOpCodeHandle = HiiAllocateOpCodeHandle ();
    579579  ASSERT (OptionsOpCodeHandle != NULL);
    580  
     580
    581581  NewMenuEntry = NULL;
    582582  for (OptionIndex = 0; (OptionIndex < MAX_MENU_NUMBER && OptionOrder[OptionIndex] != 0); OptionIndex++) {
     
    600600    }
    601601  }
    602  
     602
    603603  if (OptionMenu->MenuNumber > 0) {
    604     HiiCreateOrderedListOpCode (                   
    605       mStartOpCodeHandle,                          // Container for dynamic created opcodes     
    606       QuestionId,                                  // Question ID                               
    607       VARSTORE_ID_BOOT_MAINT,                      // VarStore ID                               
    608       VarOffset,                                   // Offset in Buffer Storage                 
    609       STRING_TOKEN (STR_CHANGE_ORDER),             // Question prompt text                     
    610       STRING_TOKEN (STR_CHANGE_ORDER),             // Question help text                       
    611       0,                                           // Question flag                             
     604    HiiCreateOrderedListOpCode (
     605      mStartOpCodeHandle,                          // Container for dynamic created opcodes
     606      QuestionId,                                  // Question ID
     607      VARSTORE_ID_BOOT_MAINT,                      // VarStore ID
     608      VarOffset,                                   // Offset in Buffer Storage
     609      STRING_TOKEN (STR_CHANGE_ORDER),             // Question prompt text
     610      STRING_TOKEN (STR_CHANGE_ORDER),             // Question help text
     611      0,                                           // Question flag
    612612      0,                                           // Ordered list flag, e.g. EFI_IFR_UNIQUE_SET
    613       EFI_IFR_TYPE_NUM_SIZE_32,                    // Data type of Question value               
    614       100,                                         // Maximum container                         
    615       OptionsOpCodeHandle,                         // Option Opcode list                       
    616       NULL                                         // Default Opcode is NULL                   
     613      EFI_IFR_TYPE_NUM_SIZE_32,                    // Data type of Question value
     614      100,                                         // Maximum container
     615      OptionsOpCodeHandle,                         // Option Opcode list
     616      NULL                                         // Default Opcode is NULL
    617617      );
    618618  }
     
    693693        Index
    694694        );
    695     }     
     695    }
    696696
    697697    HiiCreateOneOfOpCode (
     
    752752    DefaultOpCodeHandle
    753753    );
    754  
     754
    755755  HiiFreeOpCodeHandle (DefaultOpCodeHandle);
    756756
     
    827827      continue;
    828828    }
    829    
     829
    830830    //
    831831    // Build mode string Column x Row
     
    940940    NULL
    941941    );
    942  
     942
    943943  HiiFreeOpCodeHandle (OptionsOpCodeHandle);
    944944  OptionsOpCodeHandle = HiiAllocateOpCodeHandle ();
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BootMaint/Variable.c

    r58459 r58466  
    2020  make sure BootOrder is in valid state.
    2121
    22   @retval EFI_SUCCESS   If all boot load option EFI Variables corresponding to 
     22  @retval EFI_SUCCESS   If all boot load option EFI Variables corresponding to
    2323                        BM_LOAD_CONTEXT marked for deletion is deleted.
    2424  @retval EFI_NOT_FOUND If can not find the boot option want to be deleted.
    25   @return Others        If failed to update the "BootOrder" variable after deletion. 
     25  @return Others        If failed to update the "BootOrder" variable after deletion.
    2626
    2727**/
     
    8787
    8888
    89  
     89
    9090
    9191  @retval  EFI_SUCCESS  The boot order is updated successfully.
     
    314314
    315315/**
    316   Update the device path of "ConOut", "ConIn" and "ErrOut" 
     316  Update the device path of "ConOut", "ConIn" and "ErrOut"
    317317  based on the new BaudRate, Data Bits, parity and Stop Bits
    318318  set.
     
    384384  This function clear the EFI variable defined by ConsoleName and
    385385  gEfiGlobalVariableGuid. It then build the multi-instance device
    386   path by appending the device path of the Console (In/Out/Err) instance 
     386  path by appending the device path of the Console (In/Out/Err) instance
    387387  in ConsoleMenu. Then it scan all corresponding console device by
    388388  scanning Terminal (built from device supporting Serial I/O instances)
     
    448448      Vendor.Header.Type    = MESSAGING_DEVICE_PATH;
    449449      Vendor.Header.SubType = MSG_VENDOR_DP;
    450      
     450
    451451      ASSERT (NewTerminalContext->TerminalType < (sizeof (TerminalTypeGuid) / sizeof (TerminalTypeGuid[0])));
    452452      CopyMem (
     
    521521
    522522  @retval EFI_SUCCESS    The function complete successfully.
    523   @return The EFI variable can not be saved. See gRT->SetVariable for detail return information. 
     523  @return The EFI variable can not be saved. See gRT->SetVariable for detail return information.
    524524**/
    525525EFI_STATUS
     
    532532
    533533/**
    534   This function create a currently loaded Drive Option from 
    535   the BMM. It then appends this Driver Option to the end of 
     534  This function create a currently loaded Drive Option from
     535  the BMM. It then appends this Driver Option to the end of
    536536  the "DriverOrder" list. It append this Driver Opotion to the end
    537537  of DriverOptionMenu.
     
    727727
    728728/**
    729   This function create a currently loaded Boot Option from 
    730   the BMM. It then appends this Boot Option to the end of 
     729  This function create a currently loaded Boot Option from
     730  the BMM. It then appends this Boot Option to the end of
    731731  the "BootOrder" list. It also append this Boot Opotion to the end
    732732  of BootOptionMenu.
     
    908908
    909909/**
    910   This function update the "BootNext" EFI Variable. If there is 
     910  This function update the "BootNext" EFI Variable. If there is
    911911  no "BootNext" specified in BMM, this EFI Variable is deleted.
    912912  It also update the BMM context data specified the "BootNext"
     
    916916
    917917  @retval EFI_SUCCESS    The function complete successfully.
    918   @return                The EFI variable can be saved. See gRT->SetVariable 
     918  @return                The EFI variable can be saved. See gRT->SetVariable
    919919                         for detail return information.
    920920
     
    11021102  //
    11031103  ASSERT_EFI_ERROR (Status);
    1104  
     1104
    11051105  BOpt_FreeMenu (&DriverOptionMenu);
    11061106  BOpt_GetDriverOptions (CallbackData);
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BootMngr/BootManager.c

    r58459 r58466  
    4545    END_DEVICE_PATH_TYPE,
    4646    END_ENTIRE_DEVICE_PATH_SUBTYPE,
    47     { 
     47    {
    4848      (UINT8) (END_DEVICE_PATH_LENGTH),
    4949      (UINT8) ((END_DEVICE_PATH_LENGTH) >> 8)
     
    188188/**
    189189  This function invokes Boot Manager. If all devices have not a chance to be connected,
    190   the connect all will be triggered. It then enumerate all boot options. If 
     190  the connect all will be triggered. It then enumerate all boot options. If
    191191  a boot option from the Boot Manager page is selected, Boot Manager will boot
    192192  from this boot option.
    193  
     193
    194194**/
    195195VOID
     
    295295      HiiCreateEndOpCode (StartOpCodeHandle);
    296296    }
    297    
     297
    298298    if (IsLegacyOption && DeviceType != ((BBS_BBS_DEVICE_PATH *) Option->DevicePath)->DeviceType) {
    299299      if (NeedEndOp) {
     
    315315
    316316    ASSERT (Option->Description != NULL);
    317    
     317
    318318    Token = HiiSetString (HiiHandle, 0, Option->Description, NULL);
    319319
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BootMngr/BootManager.h

    r48674 r58466  
    9191/**
    9292  This function invokes Boot Manager. If all devices have not a chance to be connected,
    93   the connect all will be triggered. It then enumerate all boot options. If 
     93  the connect all will be triggered. It then enumerate all boot options. If
    9494  a boot option from the Boot Manager page is selected, Boot Manager will boot
    9595  from this boot option.
    96  
     96
    9797**/
    9898VOID
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BootMngr/BootManagerStrings.uni

    • Property svn:mime-type changed from application/octet-stream to text/plain;encoding=UTF-16LE
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/BootMngr/BootManagerVfr.Vfr

    • Property svn:eol-style set to native
    r48674 r58466  
    11///** @file
    2 // 
     2//
    33//    Browser formset.
    4 // 
     4//
    55//  Copyright (c) 2004 - 2011, Intel Corporation. All rights reserved.<BR>
    66//  This program and the accompanying materials
     
    88//  which accompanies this distribution.  The full text of the license may be found at
    99//  http://opensource.org/licenses/bsd-license.php
    10 // 
     10//
    1111//  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1212//  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    13 // 
     13//
    1414//**/
    1515
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/Capsules.c

    r58459 r58466  
    5252  VOID                        **CapsulePtr;
    5353  VOID                        **CapsulePtrCache;
    54   EFI_GUID                    *CapsuleGuidCache; 
     54  EFI_GUID                    *CapsuleGuidCache;
    5555  BOOLEAN                     NeedReset;
    5656
     
    7171    return EFI_INVALID_PARAMETER;
    7272  }
    73  
     73
    7474  Status = EFI_SUCCESS;
    7575  //
     
    8181    HobPointer.Raw = GET_NEXT_HOB (HobPointer);
    8282  }
    83  
     83
    8484  if (CapsuleTotalNumber == 0) {
    8585    //
     
    9393    return EFI_SUCCESS;
    9494  }
    95  
     95
    9696  //
    9797  // Init temp Capsule Data table.
     
    103103  CapsuleGuidCache = (EFI_GUID *) AllocateZeroPool (sizeof (EFI_GUID) * CapsuleTotalNumber);
    104104  ASSERT (CapsuleGuidCache != NULL);
    105  
     105
    106106  //
    107107  // Find all capsule images from hob
     
    120120  //
    121121  // Capsules who have CAPSULE_FLAGS_POPULATE_SYSTEM_TABLE always are used for operating
    122   // System to have information persist across a system reset. EFI System Table must 
     122  // System to have information persist across a system reset. EFI System Table must
    123123  // point to an array of capsules that contains the same CapsuleGuid value. And agents
    124   // searching for this type capsule will look in EFI System Table and search for the 
     124  // searching for this type capsule will look in EFI System Table and search for the
    125125  // capsule's Guid and associated pointer to retrieve the data. Two steps below describes
    126   // how to sorting the capsules by the unique guid and install the array to EFI System Table. 
    127   // Firstly, Loop for all coalesced capsules, record unique CapsuleGuids and cache them in an 
     126  // how to sorting the capsules by the unique guid and install the array to EFI System Table.
     127  // Firstly, Loop for all coalesced capsules, record unique CapsuleGuids and cache them in an
    128128  // array for later sorting capsules by CapsuleGuid.
    129129  //
     
    133133      //
    134134      // For each capsule, we compare it with known CapsuleGuid in the CacheArray.
    135       // If already has the Guid, skip it. Whereas, record it in the CacheArray as 
     135      // If already has the Guid, skip it. Whereas, record it in the CacheArray as
    136136      // an additional one.
    137137      //
     
    160160  CacheIndex = 0;
    161161  while (CacheIndex < CacheNumber) {
    162     CapsuleNumber = 0; 
     162    CapsuleNumber = 0;
    163163    for (Index = 0; Index < CapsuleTotalNumber; Index++) {
    164164      CapsuleHeader = (EFI_CAPSULE_HEADER*) CapsulePtr [Index];
     
    173173    }
    174174    if (CapsuleNumber != 0) {
    175       Size = sizeof(EFI_CAPSULE_TABLE) + (CapsuleNumber - 1) * sizeof(VOID*); 
     175      Size = sizeof(EFI_CAPSULE_TABLE) + (CapsuleNumber - 1) * sizeof(VOID*);
    176176      CapsuleTable = AllocateRuntimePool (Size);
    177177      ASSERT (CapsuleTable != NULL);
     
    186186  //
    187187  // Besides ones with CAPSULE_FLAGS_POPULATE_SYSTEM_TABLE flag, all capsules left are
    188   // recognized by platform with CapsuleGuid. For general platform driver, UpdateFlash 
     188  // recognized by platform with CapsuleGuid. For general platform driver, UpdateFlash
    189189  // type is commonly supported, so here only deal with encapsuled FVs capsule. Additional
    190190  // type capsule transaction could be extended. It depends on platform policy.
     
    221221
    222222  PlatformBdsLockNonUpdatableFlash ();
    223  
     223
    224224  //
    225225  // Free the allocated temp memory space.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/DeviceMngr/DeviceManager.c

    r58459 r58466  
    4444// Which form Id need to be show.
    4545//
    46 EFI_FORM_ID      mNextShowFormId = DEVICE_MANAGER_FORM_ID; 
     46EFI_FORM_ID      mNextShowFormId = DEVICE_MANAGER_FORM_ID;
    4747
    4848//
     
    7575    END_DEVICE_PATH_TYPE,
    7676    END_ENTIRE_DEVICE_PATH_SUBTYPE,
    77     { 
     77    {
    7878      (UINT8) (END_DEVICE_PATH_LENGTH),
    7979      (UINT8) ((END_DEVICE_PATH_LENGTH) >> 8)
     
    9797    END_DEVICE_PATH_TYPE,
    9898      END_ENTIRE_DEVICE_PATH_SUBTYPE,
    99     { 
     99    {
    100100      (UINT8) (END_DEVICE_PATH_LENGTH),
    101101        (UINT8) ((END_DEVICE_PATH_LENGTH) >> 8)
     
    241241
    242242  ASSERT (Handle != NULL);
    243   ASSERT (SetupClassGuid != NULL); 
     243  ASSERT (SetupClassGuid != NULL);
    244244  ASSERT (FormSetTitle != NULL);
    245245  ASSERT (FormSetHelp != NULL);
     
    264264  //
    265265  ASSERT (Status == EFI_BUFFER_TOO_SMALL);
    266  
     266
    267267  HiiPackageList = AllocatePool (BufferSize);
    268268  ASSERT (HiiPackageList != NULL);
     
    327327      }
    328328    }
    329    
     329
    330330    //
    331331    // Go to next package
     
    342342  Get the mac address string from the device path.
    343343  if the device path has the vlan, get the vanid also.
    344  
    345   @param MacAddressNode              Device path begin with mac address 
     344
     345  @param MacAddressNode              Device path begin with mac address
    346346  @param PBuffer                     Output string buffer contain mac address.
    347347
    348348**/
    349 BOOLEAN 
     349BOOLEAN
    350350GetMacAddressString(
    351351  IN  MAC_ADDR_DEVICE_PATH   *MacAddressNode,
     
    383383  StrCpy(String, L"MAC:");
    384384  String += 4;
    385  
     385
    386386  //
    387387  // Convert the MAC address into a unicode string.
     
    394394    }
    395395  }
    396  
     396
    397397  //
    398398  // If VLAN is configured, it will need extra 5 characters like "\0005".
     
    429429  @return  Other values if failed to Add the item.
    430430**/
    431 BOOLEAN 
     431BOOLEAN
    432432AddIdToMacDeviceList (
    433433  IN  EFI_STRING        MacAddrString
     
    471471      TempDeviceList = (MENU_INFO_ITEM *)AllocatePool (sizeof (MENU_INFO_ITEM) * mMacDeviceList.MaxListLen);
    472472    }
    473    
     473
    474474    if (TempDeviceList == NULL) {
    475475      return FALSE;
    476476    }
    477     TempDeviceList[mMacDeviceList.CurListLen].PromptId = PromptId; 
     477    TempDeviceList[mMacDeviceList.CurListLen].PromptId = PromptId;
    478478    TempDeviceList[mMacDeviceList.CurListLen].QuestionId = (EFI_QUESTION_ID) (mMacDeviceList.CurListLen + NETWORK_DEVICE_LIST_KEY_OFFSET);
    479    
     479
    480480    if (mMacDeviceList.CurListLen > 0) {
    481481      FreePool(mMacDeviceList.NodeList);
    482482    }
    483    
     483
    484484    mMacDeviceList.NodeList = TempDeviceList;
    485485  }
     
    498498  @param    *Node           Input device which need to be check.
    499499  @param    *NeedAddItem    Whether need to add the menu in the network device list.
    500  
     500
    501501  @retval  TRUE             Has mac address device path.
    502   @retval  FALSE            NOT Has mac address device path. 
     502  @retval  FALSE            NOT Has mac address device path.
    503503
    504504**/
     
    512512  CHAR16                     *Buffer;
    513513  BOOLEAN                    ReturnVal;
    514  
     514
    515515  ASSERT (Node != NULL);
    516516  *NeedAddItem = FALSE;
     
    527527       (DevicePathSubType (DevicePath) == MSG_MAC_ADDR_DP)) {
    528528      ReturnVal = TRUE;
    529      
     529
    530530      if (DEVICE_MANAGER_FORM_ID == mNextShowFormId) {
    531531        *NeedAddItem = TRUE;
    532532        break;
    533       } 
    534      
     533      }
     534
    535535      if (!GetMacAddressString((MAC_ADDR_DEVICE_PATH*)DevicePath, &Buffer)) {
    536536        break;
     
    546546      if (NETWORK_DEVICE_LIST_FORM_ID == mNextShowFormId) {
    547547        //
    548         // Same handle may has two network child handle, so the questionid 
     548        // Same handle may has two network child handle, so the questionid
    549549        // has the offset of SAME_HANDLE_KEY_OFFSET.
    550550        //
     
    554554        break;
    555555      }
    556     } 
     556    }
    557557    DevicePath = NextDevicePathNode (DevicePath);
    558558  }
     
    575575
    576576**/
    577 BOOLEAN 
     577BOOLEAN
    578578IsNeedAddNetworkMenu (
    579579  IN      EFI_HII_HANDLE      Handle,
     
    583583  EFI_STATUS     Status;
    584584  UINTN          EntryCount;
    585   UINTN          Index; 
     585  UINTN          Index;
    586586  EFI_HANDLE     DriverHandle;
    587587  EFI_HANDLE     ControllerHandle;
     
    612612  TmpDevicePath = DevicePath;
    613613
    614   // 
     614  //
    615615  // Check whether this device path include mac address device path.
    616   // If this path has mac address path, get the value whether need 
     616  // If this path has mac address path, get the value whether need
    617617  // add this info to the menu and return.
    618618  // Else check more about the child handle devcie path.
     
    636636
    637637  if (!IsDevicePathEnd (TmpDevicePath)) {
    638     return FALSE;   
     638    return FALSE;
    639639  }
    640640
     
    675675      }
    676676
    677       // 
     677      //
    678678      // Check whether this device path include mac address device path.
    679679      //
     
    695695          //
    696696          // If need to update other form, return whether need to add to the menu.
    697           //         
     697          //
    698698          goto Done;
    699699        }
     
    704704Done:
    705705  if (OpenInfoBuffer != NULL) {
    706     FreePool (OpenInfoBuffer); 
    707   }
    708   return IsNeedAdd; 
     706    FreePool (OpenInfoBuffer);
     707  }
     708  return IsNeedAdd;
    709709}
    710710
     
    736736  @param   GuidLists               The input form set guid lists.
    737737  @param   ArrayCount              The input array count, new array will be arraycount + 1 size.
    738   @param   Offset                  The current used HiiHandle's Offset. 
     738  @param   Offset                  The current used HiiHandle's Offset.
    739739  @param   FormSetGuid             The new found formset guid.
    740740
     
    780780  This function create the dynamic content for device manager. It includes
    781781  section header for all class of devices, one-of opcode to set VBIOS.
    782  
     782
    783783  @retval  EFI_SUCCESS             Operation is successful.
    784784  @return  Other values if failed to clean up the dynamic content from HII
     
    870870    NewStringTitle = AllocatePool (NewStringLen);
    871871    UnicodeSPrint (NewStringTitle, NewStringLen, L"%s %s", String, mSelectedMacAddrString);
    872     HiiSetString (HiiHandle, STRING_TOKEN (STR_FORM_NETWORK_DEVICE_TITLE), NewStringTitle, NULL);   
     872    HiiSetString (HiiHandle, STRING_TOKEN (STR_FORM_NETWORK_DEVICE_TITLE), NewStringTitle, NULL);
    873873    FreePool (String);
    874874    FreePool (NewStringTitle);
     
    928928
    929929    //
    930     // One HiiHandle has more than one formset can be shown, 
     930    // One HiiHandle has more than one formset can be shown,
    931931    // Insert a new pair of HiiHandle + Guid to the HiiHandles and GuidLists list.
    932     // 
     932    //
    933933    if (SkipCount > 0) {
    934934      AdjustArrayData (&HiiHandles, &GuidLists, HandleNum, Index + 1, FormSetGuid);
     
    955955    //
    956956    // Network device process
    957     // 
     957    //
    958958    if (IsNeedAddNetworkMenu (HiiHandles[Index], &AddItemCount)) {
    959959      if (mNextShowFormId == DEVICE_MANAGER_FORM_ID) {
     
    10021002    } else {
    10031003      //
    1004       // 
     1004      //
    10051005      // Not network device process, only need to show at device manger form.
    10061006      //
     
    11151115
    11161116  //
    1117   // Driver Health item chose. 
     1117  // Driver Health item chose.
    11181118  //
    11191119  if (gCallbackKey == DEVICE_MANAGER_KEY_DRIVER_HEALTH) {
     
    12241224
    12251225/**
    1226   Collect and display the platform's driver health relative information, allow user to do interactive 
     1226  Collect and display the platform's driver health relative information, allow user to do interactive
    12271227  operation while the platform is unhealthy.
    12281228
    1229   This function display a form which divided into two parts. The one list all modules which has installed 
     1229  This function display a form which divided into two parts. The one list all modules which has installed
    12301230  driver health protocol. The list usually contain driver name, controller name, and it's health info.
    12311231  While the driver name can't be retrieved, will use device path as backup. The other part of the form provide
     
    12381238  )
    12391239{
    1240   EFI_STATUS                  Status; 
     1240  EFI_STATUS                  Status;
    12411241  EFI_HII_HANDLE              HiiHandle;
    12421242  EFI_BROWSER_ACTION_REQUEST  ActionRequest;
     
    12651265
    12661266  Index               = 0;
    1267   DriverHealthInfo    = NULL; 
     1267  DriverHealthInfo    = NULL;
    12681268  DriverDevicePath    = NULL;
    12691269  IsControllerNameEmpty = FALSE;
     
    13391339  Link = GetFirstNode (&DriverHealthList);
    13401340
    1341   while (!IsNull (&DriverHealthList, Link)) {   
    1342     DriverHealthInfo = DEVICE_MANAGER_HEALTH_INFO_FROM_LINK (Link);   
     1341  while (!IsNull (&DriverHealthList, Link)) {
     1342    DriverHealthInfo = DEVICE_MANAGER_HEALTH_INFO_FROM_LINK (Link);
    13431343
    13441344    Status = DriverHealthGetDriverName (DriverHealthInfo->DriverHandle, &DriverName);
     
    13531353
    13541354    Status = DriverHealthGetControllerName (
    1355                DriverHealthInfo->DriverHandle, 
    1356                DriverHealthInfo->ControllerHandle, 
    1357                DriverHealthInfo->ChildHandle, 
     1355               DriverHealthInfo->DriverHandle,
     1356               DriverHealthInfo->ControllerHandle,
     1357               DriverHealthInfo->ChildHandle,
    13581358               &ControllerName
    13591359               );
     
    13661366      IsControllerNameEmpty = TRUE;
    13671367    }
    1368    
     1368
    13691369    //
    13701370    // Add the message of the Module itself provided after the string item.
     
    13721372    if ((DriverHealthInfo->MessageList != NULL) && (DriverHealthInfo->MessageList->StringId != 0)) {
    13731373       TmpString = HiiGetString (
    1374                      DriverHealthInfo->MessageList->HiiHandle, 
    1375                      DriverHealthInfo->MessageList->StringId, 
     1374                     DriverHealthInfo->MessageList->HiiHandle,
     1375                     DriverHealthInfo->MessageList->StringId,
    13761376                     NULL
    13771377                     );
    13781378       ASSERT (TmpString != NULL);
    1379        
     1379
    13801380       StringSize += StrLen (L"    ") * sizeof(CHAR16);
    13811381       StringSize += StrLen (TmpString) * sizeof(CHAR16);
     
    13831383       String = (EFI_STRING) AllocateZeroPool (StringSize);
    13841384       ASSERT (String != NULL);
    1385        
     1385
    13861386       StrnCpy (String, DriverName, StringSize / sizeof(CHAR16));
    13871387       if (!IsControllerNameEmpty) {
     
    13921392       StrnCat (String, L"    ", StringSize / sizeof(CHAR16) - StrLen(String) - 1);
    13931393       StrnCat (String, TmpString, StringSize / sizeof(CHAR16) - StrLen(String) - 1);
    1394        
     1394
    13951395    } else {
    13961396      //
     
    14231423      String = (EFI_STRING) AllocateZeroPool (StringSize);
    14241424      ASSERT (String != NULL);
    1425      
     1425
    14261426      StrnCpy (String, DriverName, StringSize / sizeof(CHAR16));
    14271427      if (!IsControllerNameEmpty) {
     
    14511451    Link = GetNextNode (&DriverHealthList, Link);
    14521452  }
    1453    
     1453
    14541454  //
    14551455  // Add End Opcode for Subtitle
    1456   // 
     1456  //
    14571457  HiiCreateEndOpCode (StartOpCodeHandle);
    14581458
    14591459  HiiCreateSubTitleOpCode (StartOpCodeHandleRepair, STRING_TOKEN (STR_DRIVER_HEALTH_REPAIR_ALL), 0, 0, 1);
    1460   TokenHelp = HiiSetString (HiiHandle, 0, GetStringById( STRING_TOKEN (STR_DH_REPAIR_ALL_HELP)), NULL); 
     1460  TokenHelp = HiiSetString (HiiHandle, 0, GetStringById( STRING_TOKEN (STR_DH_REPAIR_ALL_HELP)), NULL);
    14611461
    14621462  if (PlaformHealthStatusCheck ()) {
     
    15281528  // a target to display.
    15291529  // Process the diver health status states here.
    1530   // 
     1530  //
    15311531  if (gCallbackKey >= DRIVER_HEALTH_KEY_OFFSET && gCallbackKey != DRIVER_HEALTH_REPAIR_ALL_KEY) {
    15321532    ActionRequest = EFI_BROWSER_ACTION_REQUEST_NONE;
     
    15391539      // Got the item relative node in the List
    15401540      //
    1541       if (Index == (gCallbackKey - DRIVER_HEALTH_KEY_OFFSET)) { 
     1541      if (Index == (gCallbackKey - DRIVER_HEALTH_KEY_OFFSET)) {
    15421542        DriverHealthInfo = DEVICE_MANAGER_HEALTH_INFO_FROM_LINK (Link);
    15431543        //
     
    15471547        ProcessSingleControllerHealth (
    15481548          DriverHealthInfo->DriverHealth,
    1549           DriverHealthInfo->ControllerHandle,     
     1549          DriverHealthInfo->ControllerHandle,
    15501550          DriverHealthInfo->ChildHandle,
    15511551          DriverHealthInfo->HealthStatus,
     
    15661566      EnableResetRequired ();
    15671567    }
    1568    
    1569     //
    1570     // Force return to the form of Driver Health in Device Manager 
     1568
     1569    //
     1570    // Force return to the form of Driver Health in Device Manager
    15711571    //
    15721572    gCallbackKey = DRIVER_HEALTH_RETURN_KEY;
     
    15781578  if (gCallbackKey == DRIVER_HEALTH_REPAIR_ALL_KEY) {
    15791579    ActionRequest = EFI_BROWSER_ACTION_REQUEST_NONE;
    1580    
     1580
    15811581    PlatformRepairAll (&DriverHealthList);
    15821582
    15831583    gCallbackKey = DRIVER_HEALTH_RETURN_KEY;
    15841584  }
    1585    
     1585
    15861586  //
    15871587  // Remove driver health packagelist from HII database.
     
    16021602      FreePool(DriverHealthInfo->MessageList);
    16031603      FreePool (DriverHealthInfo);
    1604     }   
     1604    }
    16051605  }
    16061606
    16071607  HiiFreeOpCodeHandle (StartOpCodeHandle);
    1608   HiiFreeOpCodeHandle (EndOpCodeHandle); 
     1608  HiiFreeOpCodeHandle (EndOpCodeHandle);
    16091609  HiiFreeOpCodeHandle (StartOpCodeHandleRepair);
    1610   HiiFreeOpCodeHandle (EndOpCodeHandleRepair); 
     1610  HiiFreeOpCodeHandle (EndOpCodeHandleRepair);
    16111611
    16121612  if (gCallbackKey == DRIVER_HEALTH_RETURN_KEY) {
     
    16261626  contoller's health state.
    16271627
    1628   @param DriverHealthList   A Pointer to the list contain all of the platform driver health information. 
     1628  @param DriverHealthList   A Pointer to the list contain all of the platform driver health information.
    16291629  @param DriverHandle       The handle of driver.
    16301630  @param ControllerHandle   The class guid specifies which form set will be displayed.
    1631   @param ChildHandle        The handle of the child controller to retrieve the health 
    1632                             status on.  This is an optional parameter that may be NULL. 
     1631  @param ChildHandle        The handle of the child controller to retrieve the health
     1632                            status on.  This is an optional parameter that may be NULL.
    16331633  @param DriverHealth       A pointer to the EFI_DRIVER_HEALTH_PROTOCOL instance.
    16341634  @param HealthStatus       The health status of the controller.
     
    17271727  }
    17281728
    1729   DriverHealthInfo->Signature          = DEVICE_MANAGER_DRIVER_HEALTH_INFO_SIGNATURE; 
     1729  DriverHealthInfo->Signature          = DEVICE_MANAGER_DRIVER_HEALTH_INFO_SIGNATURE;
    17301730  DriverHealthInfo->DriverHandle       = DriverHandle;
    17311731  DriverHealthInfo->ControllerHandle   = ControllerHandle;
     
    17421742
    17431743/**
    1744   Collects all the EFI Driver Health Protocols currently present in the EFI Handle Database, 
    1745   and queries each EFI Driver Health Protocol to determine if one or more of the controllers 
    1746   managed by each EFI Driver Health Protocol instance are not healthy. 
     1744  Collects all the EFI Driver Health Protocols currently present in the EFI Handle Database,
     1745  and queries each EFI Driver Health Protocol to determine if one or more of the controllers
     1746  managed by each EFI Driver Health Protocol instance are not healthy.
    17471747
    17481748  @param DriverHealthList   A Pointer to the list contain all of the platform driver health
    1749                             information. 
     1749                            information.
    17501750
    17511751  @retval    EFI_NOT_FOUND         No controller in the platform install Driver Health Protocol.
     
    17591759  )
    17601760{
    1761   EFI_STATUS                 Status; 
     1761  EFI_STATUS                 Status;
    17621762  UINTN                      NumHandles;
    17631763  EFI_HANDLE                 *DriverHealthHandles;
     
    17691769  UINTN                      ControllerIndex;
    17701770  UINTN                      ChildIndex;
    1771  
     1771
    17721772  //
    17731773  // Initialize local variables
     
    17971797  if (EFI_ERROR (Status) || DriverHealthHandles == NULL) {
    17981798    //
    1799     // If the list of Driver Health Protocol handles can not be retrieved, then 
     1799    // If the list of Driver Health Protocol handles can not be retrieved, then
    18001800    // return EFI_OUT_OF_RESOURCES
    18011801    //
     
    18181818    // Retrieve the Driver Health Protocol from DriverHandle
    18191819    //
    1820     Status = gBS->HandleProtocol ( 
     1820    Status = gBS->HandleProtocol (
    18211821                    DriverHealthHandles[DriverHealthIndex],
    18221822                    &gEfiDriverHealthProtocolGuid,
     
    18451845
    18461846    //
    1847     // If all the controllers managed by this Driver Health Protocol are healthy, then skip to the next 
     1847    // If all the controllers managed by this Driver Health Protocol are healthy, then skip to the next
    18481848    // Driver Health Protocol handle
    18491849    //
     
    18691869      if (EFI_ERROR (Status) || Handles == NULL) {
    18701870        //
    1871         // If all the handles in the handle database can not be retrieved, then 
     1871        // If all the handles in the handle database can not be retrieved, then
    18721872        // return EFI_OUT_OF_RESOURCES
    18731873        //
     
    19461946
    19471947/**
    1948   Check the healthy status of the platform, this function will return immediately while found one driver 
     1948  Check the healthy status of the platform, this function will return immediately while found one driver
    19491949  in the platform are not healthy.
    19501950
     
    19891989  //
    19901990  // Assume all modules are healthy.
    1991   // 
     1991  //
    19921992  AllHealthy = TRUE;
    19931993
     
    19951995  // Found one or more Handles.
    19961996  //
    1997   if (!EFI_ERROR (Status)) {   
     1997  if (!EFI_ERROR (Status)) {
    19981998    for (Index = 0; Index < NoHandles; Index++) {
    19991999      Status = gBS->HandleProtocol (
     
    20202020           // Return immediately one driver's status not in healthy.
    20212021           //
    2022            return FALSE;         
     2022           return FALSE;
    20232023         }
    20242024      }
     
    20292029
    20302030/**
    2031   Processes a single controller using the EFI Driver Health Protocol associated with 
     2031  Processes a single controller using the EFI Driver Health Protocol associated with
    20322032  that controller. This algorithm continues to query the GetHealthStatus() service until
    2033   one of the legal terminal states of the EFI Driver Health Protocol is reached. This may 
     2033  one of the legal terminal states of the EFI Driver Health Protocol is reached. This may
    20342034  require the processing of HII Messages, HII Form, and invocation of repair operations.
    20352035
    20362036  @param DriverHealth       A pointer to the EFI_DRIVER_HEALTH_PROTOCOL instance.
    20372037  @param ControllerHandle   The class guid specifies which form set will be displayed.
    2038   @param ChildHandle        The handle of the child controller to retrieve the health 
    2039                             status on.  This is an optional parameter that may be NULL. 
     2038  @param ChildHandle        The handle of the child controller to retrieve the health
     2039                            status on.  This is an optional parameter that may be NULL.
    20402040  @param HealthStatus       The health status of the controller.
    2041   @param MessageList        An array of warning or error messages associated 
    2042                             with the controller specified by ControllerHandle and 
     2041  @param MessageList        An array of warning or error messages associated
     2042                            with the controller specified by ControllerHandle and
    20432043                            ChildHandle.  This is an optional parameter that may be NULL.
    2044   @param FormHiiHandle      The HII handle for an HII form associated with the 
     2044  @param FormHiiHandle      The HII handle for an HII form associated with the
    20452045                            controller specified by ControllerHandle and ChildHandle.
    20462046  @param RebootRequired     Indicate whether a reboot is required to repair the controller.
     
    20592059  EFI_STATUS                         Status;
    20602060  EFI_DRIVER_HEALTH_STATUS           LocalHealthStatus;
    2061  
     2061
    20622062  LocalHealthStatus = HealthStatus;
    20632063  //
    20642064  // If the module need to be repaired or reconfiguration,  will process it until
    2065   // reach a terminal status. The status from EfiDriverHealthStatusRepairRequired after repair 
     2065  // reach a terminal status. The status from EfiDriverHealthStatusRepairRequired after repair
    20662066  // will be in (Health, Failed, Configuration Required).
    20672067  //
     
    20782078    }
    20792079    //
    2080     // Via a form of the driver need to do configuration provided to process of status in 
     2080    // Via a form of the driver need to do configuration provided to process of status in
    20812081    // EfiDriverHealthStatusConfigurationRequired. The status after configuration should be in
    2082     // (Healthy, Reboot Required, Failed, Reconnect Required, Repair Required).   
     2082    // (Healthy, Reboot Required, Failed, Reconnect Required, Repair Required).
    20832083    //
    20842084    if (LocalHealthStatus == EfiDriverHealthStatusConfigurationRequired) {
     
    21142114    if (*MessageList != NULL) {
    21152115      ProcessMessages (*MessageList);
    2116     } 
    2117   }
    2118  
     2116    }
     2117  }
     2118
    21192119  //
    21202120  // Health status in {Healthy, Failed} may also have Messages need to process
     
    21312131    *RebootRequired = TRUE;
    21322132  }
    2133  
     2133
    21342134  //
    21352135  // Do reconnect if need.
     
    21522152  Reports the progress of a repair operation.
    21532153
    2154   @param[in]  Value             A value between 0 and Limit that identifies the current 
     2154  @param[in]  Value             A value between 0 and Limit that identifies the current
    21552155                                progress of the repair operation.
    21562156
    21572157  @param[in]  Limit             The maximum value of Value for the current repair operation.
    2158                                 For example, a driver that wants to specify progress in 
     2158                                For example, a driver that wants to specify progress in
    21592159                                percent would use a Limit value of 100.
    21602160
     
    21842184  service of the EFI Driver Health Protocol
    21852185
    2186   @param    MessageList  The MessageList point to messages need to processed. 
     2186  @param    MessageList  The MessageList point to messages need to processed.
    21872187
    21882188**/
     
    22062206    if (MessageString != NULL) {
    22072207      //
    2208       // User can customize the output. Just simply print out the MessageString like below. 
     2208      // User can customize the output. Just simply print out the MessageString like below.
    22092209      // Also can use the HiiHandle to display message on the front page.
    2210       // 
     2210      //
    22112211      // Print(L"%s\n",MessageString);
    22122212      // gBS->Stall (100000);
     
    22202220
    22212221  This function is the main entry for user choose "Repair All" in the front page.
    2222   It will try to do recovery job till all the driver health protocol installed modules 
     2222  It will try to do recovery job till all the driver health protocol installed modules
    22232223  reach a terminal state.
    22242224
     
    22312231  IN LIST_ENTRY  *DriverHealthList
    22322232  )
    2233 { 
     2233{
    22342234  DRIVER_HEALTH_INFO          *DriverHealthInfo;
    22352235  LIST_ENTRY                  *Link;
     
    22502250    ASSERT (DriverHealthInfo != NULL);
    22512251
    2252     ProcessSingleControllerHealth ( 
     2252    ProcessSingleControllerHealth (
    22532253      DriverHealthInfo->DriverHealth,
    22542254      DriverHealthInfo->ControllerHandle,
     
    22682268/**
    22692269
    2270   Select the best matching language according to front page policy for best user experience. 
    2271  
    2272   This function supports both ISO 639-2 and RFC 4646 language codes, but language 
    2273   code types may not be mixed in a single call to this function. 
     2270  Select the best matching language according to front page policy for best user experience.
     2271
     2272  This function supports both ISO 639-2 and RFC 4646 language codes, but language
     2273  code types may not be mixed in a single call to this function.
    22742274
    22752275  @param  SupportedLanguages   A pointer to a Null-terminated ASCII string that
    2276                                contains a set of language codes in the format 
     2276                               contains a set of language codes in the format
    22772277                               specified by Iso639Language.
    22782278  @param  Iso639Language       If TRUE, then all language codes are assumed to be
     
    22812281
    22822282  @retval NULL                 The best matching language could not be found in SupportedLanguages.
    2283   @retval NULL                 There are not enough resources available to return the best matching 
     2283  @retval NULL                 There are not enough resources available to return the best matching
    22842284                               language.
    2285   @retval Other                A pointer to a Null-terminated ASCII string that is the best matching 
     2285  @retval Other                A pointer to a Null-terminated ASCII string that is the best matching
    22862286                               language in SupportedLanguages.
    22872287**/
     
    23212321  @param  DriverBindingHandle  The handle on which the Component Name (2) protocol instance is retrieved.
    23222322  @param  ComponentName        A pointer to the Component Name (2) protocol interface.
    2323   @param  SupportedLanguage    The best suitable language that matches the SupportedLangues interface for the 
     2323  @param  SupportedLanguage    The best suitable language that matches the SupportedLangues interface for the
    23242324                               located Component Name (2) instance.
    23252325
     
    23982398
    23992399  //
    2400   // Retrieve Component Name (2) protocol instance on the driver binding handle and 
    2401   // find the best language this instance supports. 
     2400  // Retrieve Component Name (2) protocol instance on the driver binding handle and
     2401  // find the best language this instance supports.
    24022402  //
    24032403  Status = GetComponentNameWorker (
     
    24102410    return Status;
    24112411  }
    2412  
     2412
    24132413  //
    24142414  // Get the driver name from Component Name (2) protocol instance on the driver binging handle.
     
    24202420                            );
    24212421  FreePool (BestLanguage);
    2422  
     2422
    24232423  return Status;
    24242424}
     
    24292429  in turn. It first tries UEFI 2.0 Component Name 2 protocol interface and try to get the driver name.
    24302430  If the attempt fails, it then gets the driver name from EFI 1.1 Component Name protocol for backward
    2431   compatibility support. 
     2431  compatibility support.
    24322432
    24332433  @param  DriverBindingHandle  The handle on which the Component Name (2) protocol instance is retrieved.
     
    24702470  in turn. It first tries UEFI 2.0 Component Name 2 protocol interface and try to get the controller name.
    24712471  If the attempt fails, it then gets the controller name from EFI 1.1 Component Name protocol for backward
    2472   compatibility support. 
     2472  compatibility support.
    24732473
    24742474  @param  ProtocolGuid         A pointer to an EFI_GUID. It points to Component Name (2) protocol GUID.
     
    25032503
    25042504  //
    2505   // Retrieve Component Name (2) protocol instance on the driver binding handle and 
    2506   // find the best language this instance supports. 
     2505  // Retrieve Component Name (2) protocol instance on the driver binding handle and
     2506  // find the best language this instance supports.
    25072507  //
    25082508  Status = GetComponentNameWorker (
     
    25342534
    25352535  This function gets controller name from Component Name 2 protocol interface and Component Name protocol interface
    2536   in turn. It first tries UEFI 2.0 Component Name 2 protocol interface and try to get the controller name. 
     2536  in turn. It first tries UEFI 2.0 Component Name 2 protocol interface and try to get the controller name.
    25372537  If the attempt fails, it then gets the controller name from EFI 1.1 Component Name protocol for backward
    2538   compatibility support. 
     2538  compatibility support.
    25392539
    25402540  @param  DriverBindingHandle  The handle on which the Component Name (2) protocol instance is retrieved.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/DeviceMngr/DeviceManager.h

    r58459 r58466  
    7676  EFI_DRIVER_HEALTH_PROTOCOL      *DriverHealth;
    7777  ///
    78   /// Driver health messages of the specify Driver 
     78  /// Driver health messages of the specify Driver
    7979  ///
    8080  EFI_DRIVER_HEALTH_HII_MESSAGE   *MessageList;
     
    193193  This function create the dynamic content for device manager. It includes
    194194  section header for all class of devices, one-of opcode to set VBIOS.
    195  
     195
    196196  @retval  EFI_SUCCESS             Operation is successful.
    197197  @retval  Other values if failed to clean up the dynamic content from HII
     
    211211  contoller's health state.
    212212
    213   @param DriverHealthList   A Pointer to the list contain all of the platform driver health information. 
     213  @param DriverHealthList   A Pointer to the list contain all of the platform driver health information.
    214214  @param DriverHandle       The handle of driver.
    215215  @param ControllerHandle   The class guid specifies which form set will be displayed.
    216   @param ChildHandle        The handle of the child controller to retrieve the health 
    217                             status on.  This is an optional parameter that may be NULL. 
     216  @param ChildHandle        The handle of the child controller to retrieve the health
     217                            status on.  This is an optional parameter that may be NULL.
    218218  @param DriverHealth       A pointer to the EFI_DRIVER_HEALTH_PROTOCOL instance.
    219219  @param HealthStatus       The health status of the controller.
     
    238238
    239239/**
    240   Collects all the EFI Driver Health Protocols currently present in the EFI Handle Database, 
    241   and queries each EFI Driver Health Protocol to determine if one or more of the controllers 
    242   managed by each EFI Driver Health Protocol instance are not healthy. 
     240  Collects all the EFI Driver Health Protocols currently present in the EFI Handle Database,
     241  and queries each EFI Driver Health Protocol to determine if one or more of the controllers
     242  managed by each EFI Driver Health Protocol instance are not healthy.
    243243
    244244  @param DriverHealthList   A Pointer to the list contain all of the platform driver health
     
    256256
    257257/**
    258   Check the healthy status of the platform, this function will return immediately while found one driver 
     258  Check the healthy status of the platform, this function will return immediately while found one driver
    259259  in the platform are not healthy.
    260260
     
    272272
    273273  This function is the main entry for user choose "Repair All" in the front page.
    274   It will try to do recovery job till all the driver health protocol installed modules 
     274  It will try to do recovery job till all the driver health protocol installed modules
    275275  reach a terminal state.
    276276
     
    285285
    286286/**
    287   Processes a single controller using the EFI Driver Health Protocol associated with 
     287  Processes a single controller using the EFI Driver Health Protocol associated with
    288288  that controller. This algorithm continues to query the GetHealthStatus() service until
    289   one of the legal terminal states of the EFI Driver Health Protocol is reached. This may 
     289  one of the legal terminal states of the EFI Driver Health Protocol is reached. This may
    290290  require the processing of HII Messages, HII Form, and invocation of repair operations.
    291291
    292292  @param DriverHealth       A pointer to the EFI_DRIVER_HEALTH_PROTOCOL instance.
    293293  @param ControllerHandle   The class guid specifies which form set will be displayed.
    294   @param ChildHandle        The handle of the child controller to retrieve the health 
    295                             status on.  This is an optional parameter that may be NULL. 
     294  @param ChildHandle        The handle of the child controller to retrieve the health
     295                            status on.  This is an optional parameter that may be NULL.
    296296  @param HealthStatus       The health status of the controller.
    297   @param MessageList        An array of warning or error messages associated 
    298                             with the controller specified by ControllerHandle and 
     297  @param MessageList        An array of warning or error messages associated
     298                            with the controller specified by ControllerHandle and
    299299                            ChildHandle.  This is an optional parameter that may be NULL.
    300   @param FormHiiHandle      The HII handle for an HII form associated with the 
     300  @param FormHiiHandle      The HII handle for an HII form associated with the
    301301                            controller specified by ControllerHandle and ChildHandle.
    302302  @param RebootRequired     Indicate whether a reboot is required to repair the controller.
     
    316316  Reports the progress of a repair operation.
    317317
    318   @param[in]  Value             A value between 0 and Limit that identifies the current 
     318  @param[in]  Value             A value between 0 and Limit that identifies the current
    319319                                progress of the repair operation.
    320320
    321321  @param[in]  Limit             The maximum value of Value for the current repair operation.
    322                                 For example, a driver that wants to specify progress in 
     322                                For example, a driver that wants to specify progress in
    323323                                percent would use a Limit value of 100.
    324324
     
    337337  service of the EFI Driver Health Protocol
    338338
    339   @param    MessageList  The MessageList point to messages need to processed. 
     339  @param    MessageList  The MessageList point to messages need to processed.
    340340
    341341**/
     
    347347
    348348/**
    349   Collect and display the platform's driver health relative information, allow user to do interactive 
     349  Collect and display the platform's driver health relative information, allow user to do interactive
    350350  operation while the platform is unhealthy.
    351351
    352   This function display a form which divided into two parts. The one list all modules which has installed 
     352  This function display a form which divided into two parts. The one list all modules which has installed
    353353  driver health protocol. The list usually contain driver name, controller name, and it's health info.
    354354  While the driver name can't be retrieved, will use device path as backup. The other part of the form provide
     
    363363/**
    364364
    365   Select the best matching language according to front page policy for best user experience. 
    366  
    367   This function supports both ISO 639-2 and RFC 4646 language codes, but language 
    368   code types may not be mixed in a single call to this function. 
     365  Select the best matching language according to front page policy for best user experience.
     366
     367  This function supports both ISO 639-2 and RFC 4646 language codes, but language
     368  code types may not be mixed in a single call to this function.
    369369
    370370  @param  SupportedLanguages   A pointer to a Null-terminated ASCII string that
    371                                contains a set of language codes in the format 
     371                               contains a set of language codes in the format
    372372                               specified by Iso639Language.
    373373  @param  Iso639Language       If TRUE, then all language codes are assumed to be
     
    376376
    377377  @retval NULL                 The best matching language could not be found in SupportedLanguages.
    378   @retval NULL                 There are not enough resources available to return the best matching 
     378  @retval NULL                 There are not enough resources available to return the best matching
    379379                               language.
    380   @retval Other                A pointer to a Null-terminated ASCII string that is the best matching 
     380  @retval Other                A pointer to a Null-terminated ASCII string that is the best matching
    381381                               language in SupportedLanguages.
    382382**/
     
    395395  @param  DriverBindingHandle  The handle on which the Component Name (2) protocol instance is retrieved.
    396396  @param  ComponentName        A pointer to the Component Name (2) protocol interface.
    397   @param  SupportedLanguage    The best suitable language that matches the SupportedLangues interface for the 
     397  @param  SupportedLanguage    The best suitable language that matches the SupportedLangues interface for the
    398398                               located Component Name (2) instance.
    399399
     
    441441  in turn. It first tries UEFI 2.0 Component Name 2 protocol interface and try to get the driver name.
    442442  If the attempt fails, it then gets the driver name from EFI 1.1 Component Name protocol for backward
    443   compatibility support. 
     443  compatibility support.
    444444
    445445  @param  DriverBindingHandle  The handle on which the Component Name (2) protocol instance is retrieved.
     
    463463  in turn. It first tries UEFI 2.0 Component Name 2 protocol interface and try to get the controller name.
    464464  If the attempt fails, it then gets the controller name from EFI 1.1 Component Name protocol for backward
    465   compatibility support. 
     465  compatibility support.
    466466
    467467  @param  ProtocolGuid         A pointer to an EFI_GUID. It points to Component Name (2) protocol GUID.
     
    493493/**
    494494  This function gets controller name from Component Name 2 protocol interface and Component Name protocol interface
    495   in turn. It first tries UEFI 2.0 Component Name 2 protocol interface and try to get the controller name. 
     495  in turn. It first tries UEFI 2.0 Component Name 2 protocol interface and try to get the controller name.
    496496  If the attempt fails, it then gets the controller name from EFI 1.1 Component Name protocol for backward
    497   compatibility support. 
     497  compatibility support.
    498498
    499499  @param  DriverBindingHandle  The handle on which the Component Name (2) protocol instance is retrieved.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/DeviceMngr/DeviceManagerStrings.uni

    • Property svn:mime-type changed from application/octet-stream to text/plain;encoding=UTF-16LE
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/DeviceMngr/DeviceManagerVfr.Vfr

    • Property svn:eol-style set to native
    r48674 r58466  
    11///** @file
    2 // 
     2//
    33//    Device Manager formset.
    4 // 
     4//
    55//  Copyright (c) 2004 - 2011, Intel Corporation. All rights reserved.<BR>
    66//  This program and the accompanying materials
     
    88//  which accompanies this distribution.  The full text of the license may be found at
    99//  http://opensource.org/licenses/bsd-license.php
    10 // 
     10//
    1111//  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1212//  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    13 // 
     13//
    1414//**/
    1515
     
    6060    label LABEL_DEVICES_LIST;
    6161    label LABEL_END;
    62      
     62
    6363    subtitle text = STRING_TOKEN(STR_EMPTY_STRING);
    6464
    6565    label LABEL_VBIOS;
    6666    label LABEL_END;
    67    
     67
    6868    subtitle text = STRING_TOKEN(STR_EMPTY_STRING);
    6969    subtitle text = STRING_TOKEN(STR_EXIT_STRING);
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/DeviceMngr/DriverHealthVfr.Vfr

    • Property svn:eol-style set to native
    r48674 r58466  
    11///** @file
    2 // 
     2//
    33//    Driver Health formset.
    4 // 
     4//
    55//  Copyright (c) 2004 - 2011, Intel Corporation. All rights reserved.<BR>
    66//  This program and the accompanying materials
     
    88//  which accompanies this distribution.  The full text of the license may be found at
    99//  http://opensource.org/licenses/bsd-license.php
    10 // 
     10//
    1111//  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1212//  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    13 // 
     13//
    1414//**/
    1515
     
    2121  help      = STRING_TOKEN(STR_EMPTY_STRING),
    2222  classguid = DRIVER_HEALTH_FORMSET_GUID,
    23  
     23
    2424  form formid = DRIVER_HEALTH_FORM_ID,
    2525      title  = STRING_TOKEN(STR_DH_BANNER);
    2626
    2727      label LABEL_DRIVER_HEALTH;
    28       label LABEL_DRIVER_HEALTH_END; 
    29            
     28      label LABEL_DRIVER_HEALTH_END;
     29
    3030      subtitle text = STRING_TOKEN(STR_LAST_STRING);
    3131      label LABEL_DRIVER_HEALTH_REAPIR_ALL;
    3232      label LABEL_DRIVER_HEALTH_REAPIR_ALL_END;
    33            
     33
    3434      subtitle text = STRING_TOKEN(STR_LAST_STRING);
    3535      subtitle text = STRING_TOKEN(STR_HELP_FOOTER);
    36       subtitle text = STRING_TOKEN(STR_LAST_STRING);     
    37   endform;   
     36      subtitle text = STRING_TOKEN(STR_LAST_STRING);
     37  endform;
    3838endformset;
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/FrontPage.c

    r58459 r58466  
    190190    return EFI_UNSUPPORTED;
    191191  }
    192  
     192
    193193  gCallbackKey = QuestionId;
    194194
     
    211211      //
    212212      Lang = AllocatePool (AsciiStrSize (mLanguageString));
    213       ASSERT (Lang != NULL); 
     213      ASSERT (Lang != NULL);
    214214
    215215      Index = 0;
     
    280280  }
    281281
    282   return EFI_SUCCESS; 
     282  return EFI_SUCCESS;
    283283}
    284284
     
    415415    //
    416416    // Count the language list number.
    417     // 
     417    //
    418418    LangCode      = mLanguageString;
    419419    Lang          = AllocatePool (AsciiStrSize (mLanguageString));
     
    759759      FreePool (NewString);
    760760      Find[0] = TRUE;
    761     } 
     761    }
    762762
    763763    if (Record->Type == EFI_SMBIOS_TYPE_SYSTEM_INFORMATION) {
     
    770770      Find[1] = TRUE;
    771771    }
    772      
     772
    773773    if (Record->Type == EFI_SMBIOS_TYPE_PROCESSOR_INFORMATION) {
    774774      Type4Record = (SMBIOS_TABLE_TYPE4 *) Record;
     
    779779      FreePool (NewString);
    780780      Find[2] = TRUE;
    781     }   
     781    }
    782782
    783783    if (Record->Type == EFI_SMBIOS_TYPE_PROCESSOR_INFORMATION) {
     
    788788      FreePool (NewString);
    789789      Find[3] = TRUE;
    790     } 
     790    }
    791791
    792792    if ( Record->Type == EFI_SMBIOS_TYPE_MEMORY_ARRAY_MAPPED_ADDRESS ) {
     
    799799      HiiSetString (gFrontPagePrivate.HiiHandle, TokenToUpdate, NewString, NULL);
    800800      FreePool (NewString);
    801       Find[4] = TRUE; 
     801      Find[4] = TRUE;
    802802    }
    803803  } while ( !(Find[0] && Find[1] && Find[2] && Find[3] && Find[4]));
     
    901901  SetMem (&Background, sizeof (EFI_GRAPHICS_OUTPUT_BLT_PIXEL), 0x0);
    902902  SetMem (&Color, sizeof (EFI_GRAPHICS_OUTPUT_BLT_PIXEL), 0xff);
    903  
     903
    904904  TmpStr = GetStringById (STRING_TOKEN (STR_START_BOOT_OPTION));
    905905
     
    912912    }
    913913  }
    914  
     914
    915915
    916916  TimeoutRemain = TimeoutDefault;
     
    923923    }
    924924    TimeoutRemain--;
    925    
     925
    926926    if (!FeaturePcdGet(PcdBootlogoOnlyEnable)) {
    927927      //
     
    940940    }
    941941  }
    942  
     942
    943943  if (TmpStr != NULL) {
    944944    gBS->FreePool (TmpStr);
     
    991991{
    992992  EFI_STATUS                         Status;
    993   EFI_STATUS                         StatusHotkey; 
     993  EFI_STATUS                         StatusHotkey;
    994994  EFI_BOOT_LOGO_PROTOCOL             *BootLogo;
    995995  EFI_GRAPHICS_OUTPUT_PROTOCOL       *GraphicsOutput;
     
    10141014  if (!mModeInitialized) {
    10151015    //
    1016     // After the console is ready, get current video resolution 
     1016    // After the console is ready, get current video resolution
    10171017    // and text mode before launching setup at first time.
    10181018    //
     
    10251025      GraphicsOutput = NULL;
    10261026    }
    1027    
     1027
    10281028    Status = gBS->HandleProtocol (
    10291029                    gST->ConsoleOutHandle,
     
    10331033    if (EFI_ERROR (Status)) {
    10341034      SimpleTextOut = NULL;
    1035     } 
     1035    }
    10361036
    10371037    if (GraphicsOutput != NULL) {
     
    10561056    //
    10571057    // Get user defined text mode for setup.
    1058     // 
     1058    //
    10591059    mSetupHorizontalResolution = PcdGet32 (PcdSetupVideoHorizontalResolution);
    1060     mSetupVerticalResolution   = PcdGet32 (PcdSetupVideoVerticalResolution);     
     1060    mSetupVerticalResolution   = PcdGet32 (PcdSetupVideoVerticalResolution);
    10611061    mSetupTextModeColumn       = PcdGet32 (PcdSetupConOutColumn);
    10621062    mSetupTextModeRow          = PcdGet32 (PcdSetupConOutRow);
     
    10851085    //
    10861086    // Clear EFI_OS_INDICATIONS_BOOT_TO_FW_UI to acknowledge OS
    1087     // 
     1087    //
    10881088    OsIndication &= ~((UINT64)EFI_OS_INDICATIONS_BOOT_TO_FW_UI);
    10891089    Status = gRT->SetVariable (
     
    11221122        //
    11231123        // Ensure screen is clear when switch Console from Graphics mode to Text mode
    1124         // Skip it in normal boot 
     1124        // Skip it in normal boot
    11251125        //
    11261126        gST->ConOut->EnableCursor (gST->ConOut, TRUE);
     
    11461146
    11471147  //
    1148   // Install BM HiiPackages. 
    1149   // Keep BootMaint HiiPackage, so that it can be covered by global setting. 
     1148  // Install BM HiiPackages.
     1149  // Keep BootMaint HiiPackage, so that it can be covered by global setting.
    11501150  //
    11511151  InitBMPackage ();
     
    11571157    //
    11581158    BdsSetConsoleMode (TRUE);
    1159    
     1159
    11601160    InitializeFrontPage (FALSE);
    11611161
     
    12661266/**
    12671267  This function will change video resolution and text mode
    1268   according to defined setup mode or defined boot mode 
    1269 
    1270   @param  IsSetupMode   Indicate mode is changed to setup mode or boot mode. 
     1268  according to defined setup mode or defined boot mode
     1269
     1270  @param  IsSetupMode   Indicate mode is changed to setup mode or boot mode.
    12711271
    12721272  @retval  EFI_SUCCESS  Mode is changed successfully.
     
    12961296  UINTN                                 Index;
    12971297  UINTN                                 CurrentColumn;
    1298   UINTN                                 CurrentRow; 
     1298  UINTN                                 CurrentRow;
    12991299
    13001300  MaxGopMode  = 0;
     
    13021302
    13031303  //
    1304   // Get current video resolution and text mode 
     1304  // Get current video resolution and text mode
    13051305  //
    13061306  Status = gBS->HandleProtocol (
     
    13201320  if (EFI_ERROR (Status)) {
    13211321    SimpleTextOut = NULL;
    1322   } 
     1322  }
    13231323
    13241324  if ((GraphicsOutput == NULL) || (SimpleTextOut == NULL)) {
     
    13411341    NewVerticalResolution   = mBootVerticalResolution;
    13421342    NewColumns              = mBootTextModeColumn;
    1343     NewRows                 = mBootTextModeRow;   
    1344   }
    1345  
     1343    NewRows                 = mBootTextModeRow;
     1344  }
     1345
    13461346  if (GraphicsOutput != NULL) {
    13471347    MaxGopMode  = GraphicsOutput->Mode->MaxMode;
    1348   } 
     1348  }
    13491349
    13501350  if (SimpleTextOut != NULL) {
     
    14441444  PcdSet32 (PcdConOutColumn, NewColumns);
    14451445  PcdSet32 (PcdConOutRow, NewRows);
    1446  
    1447  
     1446
     1447
    14481448  //
    14491449  // Video mode is changed, so restart graphics console driver and higher level driver.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/FrontPage.h

    r58459 r58466  
    237237/**
    238238  This function will change video resolution and text mode
    239   according to defined setup mode or defined boot mode 
    240 
    241   @param  IsSetupMode   Indicate mode is changed to setup mode or boot mode. 
     239  according to defined setup mode or defined boot mode
     240
     241  @param  IsSetupMode   Indicate mode is changed to setup mode or boot mode.
    242242
    243243  @retval  EFI_SUCCESS  Mode is changed successfully.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/FrontPageStrings.uni

    • Property svn:mime-type changed from application/octet-stream to text/plain;encoding=UTF-16LE
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/FrontPageVfr.Vfr

    • Property svn:eol-style set to native
    r58459 r58466  
    11///** @file
    2 // 
     2//
    33//    Browser formset.
    4 // 
     4//
    55//  Copyright (c) 2007 - 2011, Intel Corporation. All rights reserved.<BR>
    66//  This program and the accompanying materials
     
    88//  which accompanies this distribution.  The full text of the license may be found at
    99//  http://opensource.org/licenses/bsd-license.php
    10 // 
     10//
    1111//  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1212//  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    13 // 
     13//
    1414//**/
    1515
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/Hotkey.c

    r58459 r58466  
    7474  VOID
    7575  )
    76 { 
     76{
    7777  EFI_STATUS           Status;
    7878  UINTN                ExitDataSize;
     
    8181  if (mHotkeyBootOption == NULL) {
    8282    return EFI_NOT_FOUND;
    83   } 
    84  
     83  }
     84
    8585  BdsLibConnectDevicePath (mHotkeyBootOption->DevicePath);
    8686
     
    163163    if ((KeyData->Key.ScanCode == HotkeyData->Key.ScanCode) &&
    164164        (KeyData->Key.UnicodeChar == HotkeyData->Key.UnicodeChar) &&
    165         (((KeyData->KeyState.KeyShiftState & EFI_SHIFT_STATE_VALID) != 0) ? 
     165        (((KeyData->KeyState.KeyShiftState & EFI_SHIFT_STATE_VALID) != 0) ?
    166166          (KeyData->KeyState.KeyShiftState == HotkeyData->KeyState.KeyShiftState) : TRUE
    167167        )
     
    422422{
    423423  UINTN         Index;
    424  
     424
    425425  if (!CompareGuid (Guid, &gEfiGlobalVariableGuid) ||
    426426      (StrSize (Name) != sizeof (L"Key####")) ||
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/HwErrRecSupport.c

    r58459 r58466  
    2929  EFI_STATUS    Status;
    3030  UINT16        HardwareErrorRecordLevel;
    31  
     31
    3232  HardwareErrorRecordLevel = PcdGet16 (PcdHardwareErrorRecordLevel);
    33  
     33
    3434  if (HardwareErrorRecordLevel != 0) {
    3535    //
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/Language.c

    r58459 r58466  
    344344  IN  CHAR8            *Lang,
    345345  IN  BOOLEAN          Iso639Language
    346   ) 
     346  )
    347347{
    348348  UINTN    Index;
     
    376376      //
    377377      for (CompareLength = 0; SupportedLang[CompareLength] != '\0' && SupportedLang[CompareLength] != ';'; CompareLength++);
    378      
    379       if ((CompareLength == LanguageLength) && 
     378
     379      if ((CompareLength == LanguageLength) &&
    380380          (AsciiStrnCmp (Lang, SupportedLang, CompareLength) == 0)) {
    381381        //
     
    405405  IN CHAR16     *LangName,
    406406  IN CHAR8      *SupportedLang,
    407   IN CHAR8      *DefaultLang,     
     407  IN CHAR8      *DefaultLang,
    408408  IN BOOLEAN    Iso639Language
    409409  )
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/MemoryTest.c

    r58459 r58466  
    283283    return EFI_SUCCESS;
    284284  }
    285  
     285
    286286  if (!FeaturePcdGet(PcdBootlogoOnlyEnable)) {
    287287    TmpStr = GetStringById (STRING_TOKEN (STR_ESC_TO_SKIP_MEM_TEST));
     
    311311      ASSERT (0);
    312312    }
    313    
     313
    314314    if (!FeaturePcdGet(PcdBootlogoOnlyEnable)) {
    315315      TempData = (UINT32) DivU64x32 (TotalMemorySize, 16);
     
    403403      (UINTN) PreviousValue
    404404      );
    405    
     405
    406406  } else {
    407407    DEBUG ((EFI_D_INFO, "%d bytes of system memory tested OK\r\n", TotalMemorySize));
    408408  }
    409  
     409
    410410  FreePool (Pos);
    411411
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/BdsDxe/Strings.uni

    • Property svn:mime-type changed from application/octet-stream to text/plain;encoding=UTF-16LE
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/Console/VgaClassDxe/ComponentName.c

    r48674 r58466  
    11/** @file
    2   UEFI Component Name(2) protocol implementation for VGA Class Driver. 
     2  UEFI Component Name(2) protocol implementation for VGA Class Driver.
    33
    44Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
    5 This program and the accompanying materials                         
    6 are licensed and made available under the terms and conditions of the BSD License         
    7 which accompanies this distribution.  The full text of the license may be found at       
    8 http://opensource.org/licenses/bsd-license.php                                           
    9                                                                                          
    10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
    11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             
     5This program and the accompanying materials
     6are licensed and made available under the terms and conditions of the BSD License
     7which accompanies this distribution.  The full text of the license may be found at
     8http://opensource.org/licenses/bsd-license.php
     9
     10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     11WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
    1313**/
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/Console/VgaClassDxe/VgaClass.c

    r48674 r58466  
    33
    44Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
    5 This program and the accompanying materials                         
    6 are licensed and made available under the terms and conditions of the BSD License         
    7 which accompanies this distribution.  The full text of the license may be found at       
    8 http://opensource.org/licenses/bsd-license.php                                           
    9                                                                                          
    10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
    11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             
     5This program and the accompanying materials
     6are licensed and made available under the terms and conditions of the BSD License
     7which accompanies this distribution.  The full text of the license may be found at
     8http://opensource.org/licenses/bsd-license.php
     9
     10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     11WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
    1313**/
     
    311311  @param  ImageHandle       The firmware allocated handle for the EFI image.
    312312  @param  SystemTable       A pointer to the EFI System Table.
    313  
     313
    314314  @retval EFI_SUCCESS       The entry point is executed successfully.
    315315
     
    342342/**
    343343  Internal worker function to program CRTC register via PCI I/O Protocol.
    344  
     344
    345345  @param VgaClassDev  device instance object
    346346  @param Address      Address of register to write
     
    376376/**
    377377  Internal worker function to set cursor's position to VgaClass device
    378  
     378
    379379  @param  VgaClassDev   Private data structure for device instance.
    380380  @param  Column        Colomn of position to set cursor to.
    381381  @param  Row           Row of position to set cursor to.
    382382  @param  MaxColumn     Max value of column.
    383  
     383
    384384**/
    385385VOID
     
    462462/**
    463463  Internal worker function to check whether input value is an ASCII char.
    464  
     464
    465465  @param  Char     Character to check.
    466466
     
    483483/**
    484484  Internal worker function to check whether input value is a unicode control char.
    485  
     485
    486486  @param  Char    Character to check.
    487487
     
    713713/**
    714714  Starts the device controller.
    715  
     715
    716716  This function implments EFI_DRIVER_BINDING_PROTOCOL.Stop().
    717717  It stops this driver on Controller. Support stoping any child handles
     
    799799  It resets the text output device hardware. The cursor position is set to (0, 0),
    800800  and the screen is cleared to the default background color for the output device.
    801  
     801
    802802  @param  This                 Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
    803803  @param  ExtendedVerification Indicates that the driver may perform a more exhaustive
     
    838838/**
    839839  Writes a Unicode string to the output device.
    840  
     840
    841841  This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.OutputString().
    842842  It writes a Unicode string to the output device. This is the most basic output mechanism
     
    978978/**
    979979  Verifies that all characters in a Unicode string can be output to the target device.
    980  
     980
    981981  This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.TestString().
    982982  It verifies that all characters in a Unicode string can be output to the target device.
     
    10101010/**
    10111011  Clears the output device(s) display to the currently selected background color.
    1012  
     1012
    10131013  This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.ClearScreen().
    10141014  The ClearScreen() function clears the output device(s) display to the currently
     
    10161016
    10171017  @param  This                   Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
    1018  
     1018
    10191019  @retval EFI_SUCESS             The operation completed successfully.
    10201020  @retval EFI_DEVICE_ERROR       The device had an error and could not complete the request.
     
    10641064/**
    10651065  Sets the background and foreground colors for theOutputString() and ClearScreen() functions.
    1066  
     1066
    10671067  This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.SetAttribute().
    10681068  It sets the background and foreground colors for the OutputString() and ClearScreen() functions.
     
    10751075                                 Bits 0..3 are the foreground color,
    10761076                                 and bits 4..6 are the background color.
    1077  
     1077
    10781078  @retval EFI_SUCCESS            The requested attributes were set.
    10791079  @retval EFI_DEVICE_ERROR       The device had an error and could not complete the request.
     
    10971097/**
    10981098  Sets the current coordinates of the cursor position.
    1099  
     1099
    11001100  This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.SetCursorPosition().
    11011101  It sets the current coordinates of the cursor position.
    11021102  The upper left corner of the screen is defined as coordinate (0, 0).
    1103  
     1103
    11041104  @param  This                   Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
    11051105  @param  Column                 Column of position to set the cursor to.
    11061106  @param  Row                    Row of position to set the cursor to.
    1107  
     1107
    11081108  @retval EFI_SUCCESS            The operation completed successfully.
    11091109  @retval EFI_DEVICE_ERROR       The device had an error and could not complete the request.
     
    11511151/**
    11521152  Makes the cursor visible or invisible.
    1153  
     1153
    11541154  This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.EnableCursor().
    11551155  It makes the cursor visible or invisible.
     
    11581158  @param  Visible                If TRUE, the cursor is set to be visible.
    11591159                                 If FALSE, the cursor is set to be invisible.
    1160  
     1160
    11611161  @retval EFI_SUCESS             The operation completed successfully.
    11621162  @retval EFI_DEVICE_ERROR       The device had an error and could not complete the request or the
     
    12091209  @param  Columns                Columen in current mode number
    12101210  @param  Rows                   Row in current mode number.
    1211  
     1211
    12121212  @retval EFI_SUCCESS            The requested mode information was returned.
    12131213  @retval EFI_DEVICE_ERROR       The device had an error and could not complete the request.
     
    12521252/**
    12531253  Sets the output device(s) to a specified mode.
    1254  
     1254
    12551255  This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.QueryMode().
    12561256  It sets the output device(s) to the requested mode.
     
    12601260  @param  This                   Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
    12611261  @param  ModeNumber             The text mode to set.
    1262  
     1262
    12631263  @retval EFI_SUCCESS            The requested text mode was set.
    12641264  @retval EFI_DEVICE_ERROR       The device had an error and could not complete the request.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/Console/VgaClassDxe/VgaClass.h

    r48674 r58466  
    33
    44Copyright (c) 2006 - 2011, Intel Corporation. All rights reserved.<BR>
    5 This program and the accompanying materials                         
    6 are licensed and made available under the terms and conditions of the BSD License         
    7 which accompanies this distribution.  The full text of the license may be found at       
    8 http://opensource.org/licenses/bsd-license.php                                           
    9                                                                                          
    10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
    11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             
     5This program and the accompanying materials
     6are licensed and made available under the terms and conditions of the BSD License
     7which accompanies this distribution.  The full text of the license may be found at
     8http://opensource.org/licenses/bsd-license.php
     9
     10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     11WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
    1313**/
     
    133133/**
    134134  Starts the device controller.
    135  
     135
    136136  This function implments EFI_DRIVER_BINDING_PROTOCOL.Stop().
    137137  It stops this driver on Controller. Support stoping any child handles
     
    279279  It resets the text output device hardware. The cursor position is set to (0, 0),
    280280  and the screen is cleared to the default background color for the output device.
    281  
     281
    282282  @param  This                 Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
    283283  @param  ExtendedVerification Indicates that the driver may perform a more exhaustive
     
    297297/**
    298298  Writes a Unicode string to the output device.
    299  
     299
    300300  This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.OutputString().
    301301  It writes a Unicode string to the output device. This is the most basic output mechanism
     
    320320/**
    321321  Verifies that all characters in a Unicode string can be output to the target device.
    322  
     322
    323323  This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.TestString().
    324324  It verifies that all characters in a Unicode string can be output to the target device.
     
    341341/**
    342342  Clears the output device(s) display to the currently selected background color.
    343  
     343
    344344  This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.ClearScreen().
    345345  The ClearScreen() function clears the output device(s) display to the currently
     
    347347
    348348  @param  This                   Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
    349  
     349
    350350  @retval EFI_SUCESS             The operation completed successfully.
    351351  @retval EFI_DEVICE_ERROR       The device had an error and could not complete the request.
     
    361361/**
    362362  Sets the background and foreground colors for theOutputString() and ClearScreen() functions.
    363  
     363
    364364  This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.SetAttribute().
    365365  It sets the background and foreground colors for the OutputString() and ClearScreen() functions.
     
    372372                                 Bits 0..3 are the foreground color,
    373373                                 and bits 4..6 are the background color.
    374  
     374
    375375  @retval EFI_SUCCESS            The requested attributes were set.
    376376  @retval EFI_DEVICE_ERROR       The device had an error and could not complete the request.
     
    386386/**
    387387  Sets the current coordinates of the cursor position.
    388  
     388
    389389  This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.SetCursorPosition().
    390390  It sets the current coordinates of the cursor position.
    391391  The upper left corner of the screen is defined as coordinate (0, 0).
    392  
     392
    393393  @param  This                   Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
    394394  @param  Column                 Column of position to set the cursor to.
    395395  @param  Row                    Row of position to set the cursor to.
    396  
     396
    397397  @retval EFI_SUCCESS            The operation completed successfully.
    398398  @retval EFI_DEVICE_ERROR       The device had an error and could not complete the request.
     
    411411/**
    412412  Makes the cursor visible or invisible.
    413  
     413
    414414  This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.EnableCursor().
    415415  It makes the cursor visible or invisible.
     
    418418  @param  Visible                If TRUE, the cursor is set to be visible.
    419419                                 If FALSE, the cursor is set to be invisible.
    420  
     420
    421421  @retval EFI_SUCESS             The operation completed successfully.
    422422  @retval EFI_DEVICE_ERROR       The device had an error and could not complete the request or the
     
    444444  @param  Columns                Columen in current mode number
    445445  @param  Rows                   Row in current mode number.
    446  
     446
    447447  @retval EFI_SUCCESS            The requested mode information was returned.
    448448  @retval EFI_DEVICE_ERROR       The device had an error and could not complete the request.
     
    461461/**
    462462  Sets the output device(s) to a specified mode.
    463  
     463
    464464  This function implements EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL.QueryMode().
    465465  It sets the output device(s) to the requested mode.
     
    469469  @param  This                   Pointer to EFI_SIMPLE_TEXT_OUTPUT_PROTOCOL instance.
    470470  @param  ModeNumber             The text mode to set.
    471  
     471
    472472  @retval EFI_SUCCESS            The requested text mode was set.
    473473  @retval EFI_DEVICE_ERROR       The device had an error and could not complete the request.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/Console/VgaClassDxe/VgaClassDxe.inf

    r58459 r58466  
    44#  Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
    55#
    6 #  This program and the accompanying materials                         
    7 #  are licensed and made available under the terms and conditions of the BSD License         
    8 #  which accompanies this distribution.  The full text of the license may be found at       
    9 #  http://opensource.org/licenses/bsd-license.php                                           
    10 #                                                                                         
    11 #  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
    12 #  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.   
     6#  This program and the accompanying materials
     7#  are licensed and made available under the terms and conditions of the BSD License
     8#  which accompanies this distribution.  The full text of the license may be found at
     9#  http://opensource.org/licenses/bsd-license.php
     10#
     11#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     12#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1313#
    1414#
     
    2929#  VALID_ARCHITECTURES           = IA32 X64 IPF EBC
    3030#
    31 #  DRIVER_BINDING                =  gVgaClassDriverBinding                       
     31#  DRIVER_BINDING                =  gVgaClassDriverBinding
    3232#  COMPONENT_NAME                =  gVgaClassComponentName
    33 #  COMPONENT_NAME2               =  gVgaClassComponentName2                   
     33#  COMPONENT_NAME2               =  gVgaClassComponentName2
    3434#
    3535
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/CpuIoDxe/CpuIo.c

    r58459 r58466  
    33
    44Copyright (c) 2004 - 2012, Intel Corporation. All rights reserved.<BR>
    5 This program and the accompanying materials                         
    6 are licensed and made available under the terms and conditions of the BSD License         
    7 which accompanies this distribution.  The full text of the license may be found at       
    8 http://opensource.org/licenses/bsd-license.php                                           
    9                                                                                          
    10 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
    11 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             
     5This program and the accompanying materials
     6are licensed and made available under the terms and conditions of the BSD License
     7which accompanies this distribution.  The full text of the license may be found at
     8http://opensource.org/licenses/bsd-license.php
     9
     10THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     11WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
    1313**/
     
    7373  Check parameters to a CPU I/O Protocol service request.
    7474
    75   The I/O operations are carried out exactly as requested. The caller is responsible 
    76   for satisfying any alignment and I/O width restrictions that a PI System on a 
    77   platform might require. For example on some platforms, width requests of 
    78   EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will 
     75  The I/O operations are carried out exactly as requested. The caller is responsible
     76  for satisfying any alignment and I/O width restrictions that a PI System on a
     77  platform might require. For example on some platforms, width requests of
     78  EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
    7979  be handled by the driver.
    80  
     80
    8181  @param[in] MmioOperation  TRUE for an MMIO operation, FALSE for I/O Port operation.
    8282  @param[in] Width          Signifies the width of the I/O or Memory operation.
    83   @param[in] Address        The base address of the I/O operation. 
    84   @param[in] Count          The number of I/O operations to perform. The number of 
     83  @param[in] Address        The base address of the I/O operation.
     84  @param[in] Count          The number of I/O operations to perform. The number of
    8585                            bytes moved is Width size * Count, starting at Address.
    8686  @param[in] Buffer         For read operations, the destination buffer to store the results.
     
    9191  @retval EFI_INVALID_PARAMETER  Buffer is NULL.
    9292  @retval EFI_UNSUPPORTED        The Buffer is not aligned for the given Width.
    93   @retval EFI_UNSUPPORTED        The address range specified by Address, Width, 
     93  @retval EFI_UNSUPPORTED        The address range specified by Address, Width,
    9494                                 and Count is not valid for this PI system.
    9595
     
    136136    return EFI_INVALID_PARAMETER;
    137137  }
    138  
     138
    139139  //
    140140  // Check to see if Address is aligned
     
    145145
    146146  //
    147   // Check to see if any address associated with this transfer exceeds the maximum 
     147  // Check to see if any address associated with this transfer exceeds the maximum
    148148  // allowed address.  The maximum address implied by the parameters passed in is
    149149  // Address + Size * Count.  If the following condition is met, then the transfer
     
    152152  //    Address + Size * Count > (MmioOperation ? MAX_ADDRESS : MAX_IO_PORT_ADDRESS) + 1
    153153  //
    154   // Since MAX_ADDRESS can be the maximum integer value supported by the CPU and Count 
     154  // Since MAX_ADDRESS can be the maximum integer value supported by the CPU and Count
    155155  // can also be the maximum integer value supported by the CPU, this range
    156156  // check must be adjusted to avoid all overflow conditions.
    157   //   
    158   // The following form of the range check is equivalent but assumes that 
     157  //
     158  // The following form of the range check is equivalent but assumes that
    159159  // MAX_ADDRESS and MAX_IO_PORT_ADDRESS are of the form (2^n - 1).
    160160  //
     
    164164      return EFI_UNSUPPORTED;
    165165    }
    166   } else { 
     166  } else {
    167167    MaxCount = RShiftU64 (Limit, Width);
    168168    if (MaxCount < (Count - 1)) {
     
    188188  Reads memory-mapped registers.
    189189
    190   The I/O operations are carried out exactly as requested. The caller is responsible 
    191   for satisfying any alignment and I/O width restrictions that a PI System on a 
    192   platform might require. For example on some platforms, width requests of 
    193   EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will 
     190  The I/O operations are carried out exactly as requested. The caller is responsible
     191  for satisfying any alignment and I/O width restrictions that a PI System on a
     192  platform might require. For example on some platforms, width requests of
     193  EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
    194194  be handled by the driver.
    195  
    196   If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32, 
    197   or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for 
     195
     196  If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
     197  or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
    198198  each of the Count operations that is performed.
    199  
    200   If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16, 
    201   EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is 
    202   incremented for each of the Count operations that is performed. The read or 
     199
     200  If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
     201  EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
     202  incremented for each of the Count operations that is performed. The read or
    203203  write operation is performed Count times on the same Address.
    204  
    205   If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16, 
    206   EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is 
    207   incremented for each of the Count operations that is performed. The read or 
     204
     205  If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
     206  EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
     207  incremented for each of the Count operations that is performed. The read or
    208208  write operation is performed Count times from the first element of Buffer.
    209  
     209
    210210  @param[in]  This     A pointer to the EFI_CPU_IO_PROTOCOL instance.
    211211  @param[in]  Width    Signifies the width of the I/O or Memory operation.
    212   @param[in]  Address  The base address of the I/O operation. 
    213   @param[in]  Count    The number of I/O operations to perform. The number of 
     212  @param[in]  Address  The base address of the I/O operation.
     213  @param[in]  Count    The number of I/O operations to perform. The number of
    214214                       bytes moved is Width size * Count, starting at Address.
    215215  @param[out] Buffer   For read operations, the destination buffer to store the results.
     
    220220  @retval EFI_INVALID_PARAMETER  Buffer is NULL.
    221221  @retval EFI_UNSUPPORTED        The Buffer is not aligned for the given Width.
    222   @retval EFI_UNSUPPORTED        The address range specified by Address, Width, 
     222  @retval EFI_UNSUPPORTED        The address range specified by Address, Width,
    223223                                 and Count is not valid for this PI system.
    224224
     
    268268  Writes memory-mapped registers.
    269269
    270   The I/O operations are carried out exactly as requested. The caller is responsible 
    271   for satisfying any alignment and I/O width restrictions that a PI System on a 
    272   platform might require. For example on some platforms, width requests of 
    273   EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will 
     270  The I/O operations are carried out exactly as requested. The caller is responsible
     271  for satisfying any alignment and I/O width restrictions that a PI System on a
     272  platform might require. For example on some platforms, width requests of
     273  EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
    274274  be handled by the driver.
    275  
    276   If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32, 
    277   or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for 
     275
     276  If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
     277  or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
    278278  each of the Count operations that is performed.
    279  
    280   If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16, 
    281   EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is 
    282   incremented for each of the Count operations that is performed. The read or 
     279
     280  If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
     281  EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
     282  incremented for each of the Count operations that is performed. The read or
    283283  write operation is performed Count times on the same Address.
    284  
    285   If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16, 
    286   EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is 
    287   incremented for each of the Count operations that is performed. The read or 
     284
     285  If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
     286  EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
     287  incremented for each of the Count operations that is performed. The read or
    288288  write operation is performed Count times from the first element of Buffer.
    289  
     289
    290290  @param[in]  This     A pointer to the EFI_CPU_IO_PROTOCOL instance.
    291291  @param[in]  Width    Signifies the width of the I/O or Memory operation.
    292   @param[in]  Address  The base address of the I/O operation. 
    293   @param[in]  Count    The number of I/O operations to perform. The number of 
     292  @param[in]  Address  The base address of the I/O operation.
     293  @param[in]  Count    The number of I/O operations to perform. The number of
    294294                       bytes moved is Width size * Count, starting at Address.
    295295  @param[in]  Buffer   For read operations, the destination buffer to store the results.
     
    300300  @retval EFI_INVALID_PARAMETER  Buffer is NULL.
    301301  @retval EFI_UNSUPPORTED        The Buffer is not aligned for the given Width.
    302   @retval EFI_UNSUPPORTED        The address range specified by Address, Width, 
     302  @retval EFI_UNSUPPORTED        The address range specified by Address, Width,
    303303                                 and Count is not valid for this PI system.
    304304
     
    348348  Reads I/O registers.
    349349
    350   The I/O operations are carried out exactly as requested. The caller is responsible 
    351   for satisfying any alignment and I/O width restrictions that a PI System on a 
    352   platform might require. For example on some platforms, width requests of 
    353   EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will 
     350  The I/O operations are carried out exactly as requested. The caller is responsible
     351  for satisfying any alignment and I/O width restrictions that a PI System on a
     352  platform might require. For example on some platforms, width requests of
     353  EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
    354354  be handled by the driver.
    355  
    356   If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32, 
    357   or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for 
     355
     356  If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
     357  or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
    358358  each of the Count operations that is performed.
    359  
    360   If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16, 
    361   EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is 
    362   incremented for each of the Count operations that is performed. The read or 
     359
     360  If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
     361  EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
     362  incremented for each of the Count operations that is performed. The read or
    363363  write operation is performed Count times on the same Address.
    364  
    365   If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16, 
    366   EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is 
    367   incremented for each of the Count operations that is performed. The read or 
     364
     365  If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
     366  EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
     367  incremented for each of the Count operations that is performed. The read or
    368368  write operation is performed Count times from the first element of Buffer.
    369  
     369
    370370  @param[in]  This     A pointer to the EFI_CPU_IO_PROTOCOL instance.
    371371  @param[in]  Width    Signifies the width of the I/O or Memory operation.
    372   @param[in]  Address  The base address of the I/O operation. 
    373   @param[in]  Count    The number of I/O operations to perform. The number of 
     372  @param[in]  Address  The base address of the I/O operation.
     373  @param[in]  Count    The number of I/O operations to perform. The number of
    374374                       bytes moved is Width size * Count, starting at Address.
    375375  @param[out] Buffer   For read operations, the destination buffer to store the results.
     
    380380  @retval EFI_INVALID_PARAMETER  Buffer is NULL.
    381381  @retval EFI_UNSUPPORTED        The Buffer is not aligned for the given Width.
    382   @retval EFI_UNSUPPORTED        The address range specified by Address, Width, 
     382  @retval EFI_UNSUPPORTED        The address range specified by Address, Width,
    383383                                 and Count is not valid for this PI system.
    384384
     
    427427  Write I/O registers.
    428428
    429   The I/O operations are carried out exactly as requested. The caller is responsible 
    430   for satisfying any alignment and I/O width restrictions that a PI System on a 
    431   platform might require. For example on some platforms, width requests of 
    432   EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will 
     429  The I/O operations are carried out exactly as requested. The caller is responsible
     430  for satisfying any alignment and I/O width restrictions that a PI System on a
     431  platform might require. For example on some platforms, width requests of
     432  EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
    433433  be handled by the driver.
    434  
    435   If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32, 
    436   or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for 
     434
     435  If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
     436  or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
    437437  each of the Count operations that is performed.
    438  
    439   If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16, 
    440   EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is 
    441   incremented for each of the Count operations that is performed. The read or 
     438
     439  If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
     440  EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
     441  incremented for each of the Count operations that is performed. The read or
    442442  write operation is performed Count times on the same Address.
    443  
    444   If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16, 
    445   EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is 
    446   incremented for each of the Count operations that is performed. The read or 
     443
     444  If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
     445  EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
     446  incremented for each of the Count operations that is performed. The read or
    447447  write operation is performed Count times from the first element of Buffer.
    448  
     448
    449449  @param[in]  This     A pointer to the EFI_CPU_IO_PROTOCOL instance.
    450450  @param[in]  Width    Signifies the width of the I/O or Memory operation.
    451   @param[in]  Address  The base address of the I/O operation. 
    452   @param[in]  Count    The number of I/O operations to perform. The number of 
     451  @param[in]  Address  The base address of the I/O operation.
     452  @param[in]  Count    The number of I/O operations to perform. The number of
    453453                       bytes moved is Width size * Count, starting at Address.
    454454  @param[in]  Buffer   For read operations, the destination buffer to store the results.
     
    459459  @retval EFI_INVALID_PARAMETER  Buffer is NULL.
    460460  @retval EFI_UNSUPPORTED        The Buffer is not aligned for the given Width.
    461   @retval EFI_UNSUPPORTED        The address range specified by Address, Width, 
     461  @retval EFI_UNSUPPORTED        The address range specified by Address, Width,
    462462                                 and Count is not valid for this PI system.
    463                                  
     463
    464464**/
    465465EFI_STATUS
     
    502502    }
    503503  }
    504  
     504
    505505  return EFI_SUCCESS;
    506506}
     
    509509  The user Entry Point for module CpuIo. The user code starts with this function.
    510510
    511   @param[in] ImageHandle    The firmware allocated handle for the EFI image. 
     511  @param[in] ImageHandle    The firmware allocated handle for the EFI image.
    512512  @param[in] SystemTable    A pointer to the EFI System Table.
    513  
     513
    514514  @retval EFI_SUCCESS       The entry point is executed successfully.
    515515  @retval other             Some error occurs when executing this entry point.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/CpuIoDxe/CpuIo.h

    r48674 r58466  
    3131  Reads memory-mapped registers.
    3232
    33   The I/O operations are carried out exactly as requested. The caller is responsible 
    34   for satisfying any alignment and I/O width restrictions that a PI System on a 
    35   platform might require. For example on some platforms, width requests of 
    36   EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will 
    37   be handled by the driver.
    38  
    39   If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32, 
    40   or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for 
    41   each of the Count operations that is performed.
    42  
    43   If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16, 
    44   EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is 
    45   incremented for each of the Count operations that is performed. The read or 
    46   write operation is performed Count times on the same Address.
    47  
    48   If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16, 
    49   EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is 
    50   incremented for each of the Count operations that is performed. The read or 
    51   write operation is performed Count times from the first element of Buffer.
    52  
    53   @param[in]  This     A pointer to the EFI_CPU_IO_PROTOCOL instance.
    54   @param[in]  Width    Signifies the width of the I/O or Memory operation.
    55   @param[in]  Address  The base address of the I/O operation. 
    56   @param[in]  Count    The number of I/O operations to perform. The number of 
     33  The I/O operations are carried out exactly as requested. The caller is responsible
     34  for satisfying any alignment and I/O width restrictions that a PI System on a
     35  platform might require. For example on some platforms, width requests of
     36  EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
     37  be handled by the driver.
     38
     39  If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
     40  or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
     41  each of the Count operations that is performed.
     42
     43  If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
     44  EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
     45  incremented for each of the Count operations that is performed. The read or
     46  write operation is performed Count times on the same Address.
     47
     48  If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
     49  EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
     50  incremented for each of the Count operations that is performed. The read or
     51  write operation is performed Count times from the first element of Buffer.
     52
     53  @param[in]  This     A pointer to the EFI_CPU_IO_PROTOCOL instance.
     54  @param[in]  Width    Signifies the width of the I/O or Memory operation.
     55  @param[in]  Address  The base address of the I/O operation.
     56  @param[in]  Count    The number of I/O operations to perform. The number of
    5757                       bytes moved is Width size * Count, starting at Address.
    5858  @param[out] Buffer   For read operations, the destination buffer to store the results.
     
    6363  @retval EFI_INVALID_PARAMETER  Buffer is NULL.
    6464  @retval EFI_UNSUPPORTED        The Buffer is not aligned for the given Width.
    65   @retval EFI_UNSUPPORTED        The address range specified by Address, Width, 
     65  @retval EFI_UNSUPPORTED        The address range specified by Address, Width,
    6666                                 and Count is not valid for this PI system.
    6767
     
    8080  Writes memory-mapped registers.
    8181
    82   The I/O operations are carried out exactly as requested. The caller is responsible 
    83   for satisfying any alignment and I/O width restrictions that a PI System on a 
    84   platform might require. For example on some platforms, width requests of 
    85   EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will 
    86   be handled by the driver.
    87  
    88   If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32, 
    89   or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for 
    90   each of the Count operations that is performed.
    91  
    92   If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16, 
    93   EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is 
    94   incremented for each of the Count operations that is performed. The read or 
    95   write operation is performed Count times on the same Address.
    96  
    97   If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16, 
    98   EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is 
    99   incremented for each of the Count operations that is performed. The read or 
    100   write operation is performed Count times from the first element of Buffer.
    101  
    102   @param[in]  This     A pointer to the EFI_CPU_IO_PROTOCOL instance.
    103   @param[in]  Width    Signifies the width of the I/O or Memory operation.
    104   @param[in]  Address  The base address of the I/O operation. 
    105   @param[in]  Count    The number of I/O operations to perform. The number of 
     82  The I/O operations are carried out exactly as requested. The caller is responsible
     83  for satisfying any alignment and I/O width restrictions that a PI System on a
     84  platform might require. For example on some platforms, width requests of
     85  EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
     86  be handled by the driver.
     87
     88  If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
     89  or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
     90  each of the Count operations that is performed.
     91
     92  If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
     93  EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
     94  incremented for each of the Count operations that is performed. The read or
     95  write operation is performed Count times on the same Address.
     96
     97  If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
     98  EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
     99  incremented for each of the Count operations that is performed. The read or
     100  write operation is performed Count times from the first element of Buffer.
     101
     102  @param[in]  This     A pointer to the EFI_CPU_IO_PROTOCOL instance.
     103  @param[in]  Width    Signifies the width of the I/O or Memory operation.
     104  @param[in]  Address  The base address of the I/O operation.
     105  @param[in]  Count    The number of I/O operations to perform. The number of
    106106                       bytes moved is Width size * Count, starting at Address.
    107107  @param[in]  Buffer   For read operations, the destination buffer to store the results.
     
    112112  @retval EFI_INVALID_PARAMETER  Buffer is NULL.
    113113  @retval EFI_UNSUPPORTED        The Buffer is not aligned for the given Width.
    114   @retval EFI_UNSUPPORTED        The address range specified by Address, Width, 
     114  @retval EFI_UNSUPPORTED        The address range specified by Address, Width,
    115115                                 and Count is not valid for this PI system.
    116116
     
    129129  Reads I/O registers.
    130130
    131   The I/O operations are carried out exactly as requested. The caller is responsible 
    132   for satisfying any alignment and I/O width restrictions that a PI System on a 
    133   platform might require. For example on some platforms, width requests of 
    134   EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will 
    135   be handled by the driver.
    136  
    137   If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32, 
    138   or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for 
    139   each of the Count operations that is performed.
    140  
    141   If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16, 
    142   EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is 
    143   incremented for each of the Count operations that is performed. The read or 
    144   write operation is performed Count times on the same Address.
    145  
    146   If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16, 
    147   EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is 
    148   incremented for each of the Count operations that is performed. The read or 
    149   write operation is performed Count times from the first element of Buffer.
    150  
    151   @param[in]  This     A pointer to the EFI_CPU_IO_PROTOCOL instance.
    152   @param[in]  Width    Signifies the width of the I/O or Memory operation.
    153   @param[in]  Address  The base address of the I/O operation. 
    154   @param[in]  Count    The number of I/O operations to perform. The number of 
     131  The I/O operations are carried out exactly as requested. The caller is responsible
     132  for satisfying any alignment and I/O width restrictions that a PI System on a
     133  platform might require. For example on some platforms, width requests of
     134  EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
     135  be handled by the driver.
     136
     137  If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
     138  or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
     139  each of the Count operations that is performed.
     140
     141  If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
     142  EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
     143  incremented for each of the Count operations that is performed. The read or
     144  write operation is performed Count times on the same Address.
     145
     146  If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
     147  EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
     148  incremented for each of the Count operations that is performed. The read or
     149  write operation is performed Count times from the first element of Buffer.
     150
     151  @param[in]  This     A pointer to the EFI_CPU_IO_PROTOCOL instance.
     152  @param[in]  Width    Signifies the width of the I/O or Memory operation.
     153  @param[in]  Address  The base address of the I/O operation.
     154  @param[in]  Count    The number of I/O operations to perform. The number of
    155155                       bytes moved is Width size * Count, starting at Address.
    156156  @param[out] Buffer   For read operations, the destination buffer to store the results.
     
    161161  @retval EFI_INVALID_PARAMETER  Buffer is NULL.
    162162  @retval EFI_UNSUPPORTED        The Buffer is not aligned for the given Width.
    163   @retval EFI_UNSUPPORTED        The address range specified by Address, Width, 
     163  @retval EFI_UNSUPPORTED        The address range specified by Address, Width,
    164164                                 and Count is not valid for this PI system.
    165165
     
    178178  Write I/O registers.
    179179
    180   The I/O operations are carried out exactly as requested. The caller is responsible 
    181   for satisfying any alignment and I/O width restrictions that a PI System on a 
    182   platform might require. For example on some platforms, width requests of 
    183   EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will 
    184   be handled by the driver.
    185  
    186   If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32, 
    187   or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for 
    188   each of the Count operations that is performed.
    189  
    190   If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16, 
    191   EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is 
    192   incremented for each of the Count operations that is performed. The read or 
    193   write operation is performed Count times on the same Address.
    194  
    195   If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16, 
    196   EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is 
    197   incremented for each of the Count operations that is performed. The read or 
    198   write operation is performed Count times from the first element of Buffer.
    199  
    200   @param[in]  This     A pointer to the EFI_CPU_IO_PROTOCOL instance.
    201   @param[in]  Width    Signifies the width of the I/O or Memory operation.
    202   @param[in]  Address  The base address of the I/O operation. 
    203   @param[in]  Count    The number of I/O operations to perform. The number of 
     180  The I/O operations are carried out exactly as requested. The caller is responsible
     181  for satisfying any alignment and I/O width restrictions that a PI System on a
     182  platform might require. For example on some platforms, width requests of
     183  EfiCpuIoWidthUint64 do not work. Misaligned buffers, on the other hand, will
     184  be handled by the driver.
     185
     186  If Width is EfiCpuIoWidthUint8, EfiCpuIoWidthUint16, EfiCpuIoWidthUint32,
     187  or EfiCpuIoWidthUint64, then both Address and Buffer are incremented for
     188  each of the Count operations that is performed.
     189
     190  If Width is EfiCpuIoWidthFifoUint8, EfiCpuIoWidthFifoUint16,
     191  EfiCpuIoWidthFifoUint32, or EfiCpuIoWidthFifoUint64, then only Buffer is
     192  incremented for each of the Count operations that is performed. The read or
     193  write operation is performed Count times on the same Address.
     194
     195  If Width is EfiCpuIoWidthFillUint8, EfiCpuIoWidthFillUint16,
     196  EfiCpuIoWidthFillUint32, or EfiCpuIoWidthFillUint64, then only Address is
     197  incremented for each of the Count operations that is performed. The read or
     198  write operation is performed Count times from the first element of Buffer.
     199
     200  @param[in]  This     A pointer to the EFI_CPU_IO_PROTOCOL instance.
     201  @param[in]  Width    Signifies the width of the I/O or Memory operation.
     202  @param[in]  Address  The base address of the I/O operation.
     203  @param[in]  Count    The number of I/O operations to perform. The number of
    204204                       bytes moved is Width size * Count, starting at Address.
    205205  @param[in]  Buffer   For read operations, the destination buffer to store the results.
     
    210210  @retval EFI_INVALID_PARAMETER  Buffer is NULL.
    211211  @retval EFI_UNSUPPORTED        The Buffer is not aligned for the given Width.
    212   @retval EFI_UNSUPPORTED        The address range specified by Address, Width, 
    213                                  and Count is not valid for this PI system.
    214                                  
     212  @retval EFI_UNSUPPORTED        The address range specified by Address, Width,
     213                                 and Count is not valid for this PI system.
     214
    215215**/
    216216EFI_STATUS
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/DataHubDxe/DataHub.c

    r48674 r58466  
    22  This code produces the Data Hub protocol. It preloads the data hub
    33  with status information copied in from PEI HOBs.
    4  
     4
    55Copyright (c) 2006 - 2010, Intel Corporation. All rights reserved.<BR>
    6 This program and the accompanying materials                         
    7 are licensed and made available under the terms and conditions of the BSD License         
    8 which accompanies this distribution.  The full text of the license may be found at       
    9 http://opensource.org/licenses/bsd-license.php                                           
    10                                                                                          
    11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
    12 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             
     6This program and the accompanying materials
     7are licensed and made available under the terms and conditions of the BSD License
     8which accompanies this distribution.  The full text of the license may be found at
     9http://opensource.org/licenses/bsd-license.php
     10
     11THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     12WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1313
    1414**/
     
    3535
    3636  @retval EFI_SUCCESS           If data was logged
    37   @retval EFI_OUT_OF_RESOURCES  If data was not logged due to lack of system 
     37  @retval EFI_OUT_OF_RESOURCES  If data was not logged due to lack of system
    3838                                resources.
    3939**/
     
    7171  RecordSize  = sizeof (EFI_DATA_RECORD_HEADER) + RawDataSize;
    7272  TotalSize   = sizeof (EFI_DATA_ENTRY) + RecordSize;
    73  
     73
    7474  //
    7575  // First try to get log time at TPL level <= TPL_CALLBACK.
     
    142142    FilterEntry = FILTER_ENTRY_FROM_LINK (Link);
    143143    if (((FilterEntry->ClassFilter & DataRecordClass) != 0) &&
    144         (CompareGuid (&FilterEntry->FilterDataRecordGuid, &gZeroGuid) || 
     144        (CompareGuid (&FilterEntry->FilterDataRecordGuid, &gZeroGuid) ||
    145145         CompareGuid (&FilterEntry->FilterDataRecordGuid, DataRecordGuid))) {
    146146      gBS->SignalEvent (FilterEntry->Event);
     
    152152
    153153/**
    154   Search the Head doubly linked list for the passed in MTC. Return the 
     154  Search the Head doubly linked list for the passed in MTC. Return the
    155155  matching element in Head and the MTC on the next entry.
    156156
     
    160160  @param PtrCurrentMTC    On IN contians MTC to search for. On OUT contians next
    161161                          MTC in the data log list or zero if at end of the list.
    162  
     162
    163163  @retval EFI_DATA_LOG_ENTRY  Return pointer to data log data from Head list.
    164164  @retval NULL                If no data record exists.
     
    258258
    259259  Get a previously logged data record and the MonotonicCount for the next
    260   availible Record. This allows all records or all records later 
     260  availible Record. This allows all records or all records later
    261261  than a give MonotonicCount to be returned. If an optional FilterDriverEvent
    262   is passed in with a MonotonicCout of zero return the first record 
    263   not yet read by the filter driver. If FilterDriverEvent is NULL and 
     262  is passed in with a MonotonicCout of zero return the first record
     263  not yet read by the filter driver. If FilterDriverEvent is NULL and
    264264  MonotonicCount is zero return the first data record.
    265265
     
    268268                                  return the first record. On output, contains the next
    269269                                  record to availible. Zero indicates no more records.
    270   @param FilterDriverEvent        If FilterDriverEvent is not passed in a MonotonicCount 
    271                                   of zero, it means to return the first data record. 
    272                                   If FilterDriverEvent is passed in, then a MonotonicCount 
    273                                   of zero means to return the first data not yet read by 
     270  @param FilterDriverEvent        If FilterDriverEvent is not passed in a MonotonicCount
     271                                  of zero, it means to return the first data record.
     272                                  If FilterDriverEvent is passed in, then a MonotonicCount
     273                                  of zero means to return the first data not yet read by
    274274                                  FilterDriverEvent.
    275   @param Record                   Returns a dynamically allocated memory buffer with a data 
     275  @param Record                   Returns a dynamically allocated memory buffer with a data
    276276                                  record that matches MonotonicCount.
    277277
     
    315315    return EFI_SUCCESS;
    316316  }
    317    
     317
    318318  //
    319319  // For events the beginning is the last unread record. This info is
     
    335335  //
    336336  // Retrieve the next record or the first record.
    337   //   
    338   if (*MonotonicCount != 0 || FilterDriver->GetNextMonotonicCount == 0) { 
     337  //
     338  if (*MonotonicCount != 0 || FilterDriver->GetNextMonotonicCount == 0) {
    339339    *Record = GetNextDataRecord (&Private->DataListHead, ClassFilter, MonotonicCount);
    340340    if (*Record == NULL) {
    341341      return EFI_NOT_FOUND;
    342342    }
    343    
     343
    344344    if (*MonotonicCount != 0) {
    345345      //
    346       // If this was not the last record then update the count associated with the filter 
     346      // If this was not the last record then update the count associated with the filter
    347347      //
    348348      FilterDriver->GetNextMonotonicCount = *MonotonicCount;
     
    355355    return EFI_SUCCESS;
    356356  }
    357  
    358   //
    359   // This is a request to read the first record that has not been read yet. 
     357
     358  //
     359  // This is a request to read the first record that has not been read yet.
    360360  // Set MonotoicCount to the last record successfuly read
    361361  //
    362362  *MonotonicCount = FilterDriver->GetNextMonotonicCount;
    363  
     363
    364364  //
    365365  // Retrieve the last record successfuly read again, but do not return it since
     
    370370    return EFI_NOT_FOUND;
    371371  }
    372  
     372
    373373  if (*MonotonicCount != 0) {
    374374    //
    375     // Update the count associated with the filter 
     375    // Update the count associated with the filter
    376376    //
    377377    FilterDriver->GetNextMonotonicCount = *MonotonicCount;
    378378
    379379    //
    380     // Retrieve the record after the last record successfuly read 
    381     // 
     380    // Retrieve the record after the last record successfuly read
     381    //
    382382    *Record = GetNextDataRecord (&Private->DataListHead, ClassFilter, MonotonicCount);
    383383    if (*Record == NULL) {
     
    385385    }
    386386  }
    387  
     387
    388388  return EFI_SUCCESS;
    389389}
    390390
    391391/**
    392   This function registers the data hub filter driver that is represented 
     392  This function registers the data hub filter driver that is represented
    393393  by FilterEvent. Only one instance of each FilterEvent can be registered.
    394   After the FilterEvent is registered, it will be signaled so it can sync 
    395   with data records that have been recorded prior to the FilterEvent being 
     394  After the FilterEvent is registered, it will be signaled so it can sync
     395  with data records that have been recorded prior to the FilterEvent being
    396396  registered.
    397    
     397
    398398  @param This                   Pointer to  The EFI_DATA_HUB_PROTOCOL instance.
    399   @param FilterEvent            The EFI_EVENT to signal whenever data that matches 
     399  @param FilterEvent            The EFI_EVENT to signal whenever data that matches
    400400                                FilterClass is logged in the system.
    401   @param FilterTpl              The maximum EFI_TPL at which FilterEvent can be 
    402                                 signaled. It is strongly recommended that you use the 
     401  @param FilterTpl              The maximum EFI_TPL at which FilterEvent can be
     402                                signaled. It is strongly recommended that you use the
    403403                                lowest EFI_TPL possible.
    404   @param FilterClass            FilterEvent will be signaled whenever a bit in 
    405                                 EFI_DATA_RECORD_HEADER.DataRecordClass is also set in 
    406                                 FilterClass. If FilterClass is zero, no class-based 
     404  @param FilterClass            FilterEvent will be signaled whenever a bit in
     405                                EFI_DATA_RECORD_HEADER.DataRecordClass is also set in
     406                                FilterClass. If FilterClass is zero, no class-based
    407407                                filtering will be performed.
    408   @param FilterDataRecordGuid   FilterEvent will be signaled whenever FilterDataRecordGuid 
    409                                 matches EFI_DATA_RECORD_HEADER.DataRecordGuid. If 
    410                                 FilterDataRecordGuid is NULL, then no GUID-based filtering 
    411                                 will be performed.             
     408  @param FilterDataRecordGuid   FilterEvent will be signaled whenever FilterDataRecordGuid
     409                                matches EFI_DATA_RECORD_HEADER.DataRecordGuid. If
     410                                FilterDataRecordGuid is NULL, then no GUID-based filtering
     411                                will be performed.
    412412
    413413  @retval EFI_SUCCESS           The filter driver event was registered.
    414   @retval EFI_ALREADY_STARTED   FilterEvent was previously registered and cannot be 
     414  @retval EFI_ALREADY_STARTED   FilterEvent was previously registered and cannot be
    415415                                registered again.
    416   @retval EFI_OUT_OF_RESOURCES  The filter driver event was not registered due to lack of 
     416  @retval EFI_OUT_OF_RESOURCES  The filter driver event was not registered due to lack of
    417417                                system resources.
    418418
     
    483483
    484484/**
    485   Remove a Filter Driver, so it no longer gets called when data 
     485  Remove a Filter Driver, so it no longer gets called when data
    486486   information is logged.
    487487
    488488  @param This           Protocol instance structure
    489489
    490   @param FilterEvent    Event that represents a filter driver that is to be 
     490  @param FilterEvent    Event that represents a filter driver that is to be
    491491                        Unregistered.
    492492
     
    529529
    530530/**
    531   Driver's Entry point routine that install Driver to produce Data Hub protocol. 
     531  Driver's Entry point routine that install Driver to produce Data Hub protocol.
    532532
    533533  @param ImageHandle    Module's image handle
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/DataHubDxe/DataHub.h

    r48674 r58466  
    11/** @file
    2   This code supports a the private implementation 
     2  This code supports a the private implementation
    33  of the Data Hub protocol
    4  
     4
    55Copyright (c) 2006, Intel Corporation. All rights reserved.<BR>
    6 This program and the accompanying materials                         
    7 are licensed and made available under the terms and conditions of the BSD License         
    8 which accompanies this distribution.  The full text of the license may be found at       
    9 http://opensource.org/licenses/bsd-license.php                                           
    10                                                                                          
    11 THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
    12 WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             
     6This program and the accompanying materials
     7are licensed and made available under the terms and conditions of the BSD License
     8which accompanies this distribution.  The full text of the license may be found at
     9http://opensource.org/licenses/bsd-license.php
     10
     11THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     12WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1313
    1414**/
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/DataHubDxe/DataHubDxe.inf

    r58459 r58466  
    2121#  drivers to be aware of all reporting formats.
    2222#  For more information, please ref http://www.intel.com/technology/framework/
    23 # 
     23#
    2424#  Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
    2525#
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/DataHubStdErrDxe/DataHubStdErr.c

    r48674 r58466  
    6666    return ;
    6767  }
    68  
     68
    6969  //
    7070  // Mtc of zero means return the next record that has not been read by the
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/FirmwareVolume/FwVolDxe/FwPadFile.c

    r48674 r58466  
    220220/**
    221221  Fill pad file header within firmware cache.
    222  
     222
    223223  @param PadFileHeader    The start of the Pad File Buffer.
    224224  @param PadFileLength    The length of the pad file including the header.
     
    265265/**
    266266  Create entire FFS file.
    267  
     267
    268268  @param FileHeader      Starting Address of a Buffer that hold the FFS File image.
    269269  @param FfsFileBuffer   The source buffer that contains the File Data.
     
    663663  @param PadSize         The array of leading pad file size for each FFS File
    664664  @param FfsBuffer       The array of Ffs Buffer pointer.
    665   @param FileData        The array of EFI_FV_WRITE_FILE_DATA structure, 
     665  @param FileData        The array of EFI_FV_WRITE_FILE_DATA structure,
    666666                         used to get name, attributes, type, etc.
    667667
     
    869869  @param PadSize         The array of leading pad file size for each FFS File
    870870  @param FfsBuffer       The array of Ffs Buffer pointer.
    871   @param FileData        The array of EFI_FV_WRITE_FILE_DATA structure, 
     871  @param FileData        The array of EFI_FV_WRITE_FILE_DATA structure,
    872872                         used to get name, attributes, type, etc.
    873873
     
    994994  @param FvDevice        Firmware Volume Device.
    995995  @param NumOfFiles      Total File number to be written.
    996   @param FileData        The array of EFI_FV_WRITE_FILE_DATA structure, 
     996  @param FileData        The array of EFI_FV_WRITE_FILE_DATA structure,
    997997                         used to get name, attributes, type, etc
    998998  @param FileOperation   The array of operation for each file.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/FirmwareVolume/FwVolDxe/FwVol.c

    r58459 r58466  
    207207  if (FvDevice->Fv.ParentHandle != NULL) {
    208208    //
    209     // By Parent Handle, find out the FV image file and section(in another firmware volume) where the firmware volume came from 
     209    // By Parent Handle, find out the FV image file and section(in another firmware volume) where the firmware volume came from
    210210    //
    211211    Status = gBS->HandleProtocol (FvDevice->Fv.ParentHandle, &gEfiFirmwareVolume2ProtocolGuid, (VOID **) &ParentFvProtocol);
     
    748748        FreePool (FvDevice);
    749749      }
    750      
     750
    751751      DEBUG ((EFI_D_INFO, "Reinstall FV protocol as writable - %r\n", Status));
    752752      ASSERT_EFI_ERROR (Status);
     
    766766        FreePool (FvDevice);
    767767      }
    768      
     768
    769769      DEBUG ((EFI_D_INFO, "Install FV protocol as writable - %r\n", Status));
    770770      ASSERT_EFI_ERROR (Status);
     
    781781    return EFI_SUCCESS;
    782782  }
    783  
     783
    784784  //
    785785  // No FV protocol install/reinstall successfully.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/FirmwareVolume/FwVolDxe/FwVolAttrib.c

    r48674 r58466  
    6666                        modified and the firmware volume
    6767                        settings are not changed.
    68  
     68
    6969  @retval EFI_SUCCESS             The requested firmware volume attributes
    7070                                  were set and the resulting
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/FirmwareVolume/FwVolDxe/FwVolDriver.h

    r58459 r58466  
    129129                        modified and the firmware volume
    130130                        settings are not changed.
    131  
     131
    132132  @retval EFI_SUCCESS             The requested firmware volume attributes
    133133                                  were set and the resulting
     
    596596  @param FvDevice        Firmware Volume Device.
    597597  @param NumOfFiles      Total File number to be written.
    598   @param FileData        The array of EFI_FV_WRITE_FILE_DATA structure, 
     598  @param FileData        The array of EFI_FV_WRITE_FILE_DATA structure,
    599599                         used to get name, attributes, type, etc
    600600  @param FileOperation   The array of operation for each file.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/FirmwareVolume/FwVolDxe/FwVolWrite.c

    r48674 r58466  
    676676  UINTN                               WriteLength;
    677677  UINT8                               *TmpBuffer;
    678  
     678
    679679  LOffset = 0;
    680680  RemainingLength = CalculateRemainingLength (FvDevice, Offset, &Lba, &LOffset);
     
    14291429    if (FileData[Index1].Type == EFI_FV_FILETYPE_FFS_PAD) {
    14301430      //
    1431       // According to PI spec, on EFI_FV_FILETYPE_FFS_PAD: 
    1432       // "Standard firmware file system services will not return the handle of any pad files, 
     1431      // According to PI spec, on EFI_FV_FILETYPE_FFS_PAD:
     1432      // "Standard firmware file system services will not return the handle of any pad files,
    14331433      // nor will they permit explicit creation of such files."
    14341434      //
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/FirmwareVolume/UpdateDriverDxe/ParseUpdateProfile.c

    r48674 r58466  
    623623
    624624/**
    625   Convert the input value to a ascii string, 
     625  Convert the input value to a ascii string,
    626626  and concatenates this string to the input string.
    627627
     
    788788/**
    789789  Pre process config data buffer into Section entry list and Comment entry list.
    790  
     790
    791791  @param DataBuffer      Config raw file buffer.
    792792  @param BufferSize      Size of raw buffer.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/FirmwareVolume/UpdateDriverDxe/UpdateDispatcher.c

    r58459 r58466  
    2323/**
    2424  Update the whole FV, or certain files in the FV.
    25  
     25
    2626  @param ConfigData      Pointer to the config data on updating file.
    2727  @param ImageBuffer     Image buffer to be updated.
     
    9090    Status = FvbProtocol->GetAttributes (FvbProtocol, &Attributes);
    9191    if (EFI_ERROR (Status) || ((Attributes & EFI_FVB2_WRITE_STATUS) == 0)) {
    92       continue;     
     92      continue;
    9393    }
    9494
     
    198198    FreePool (TmpStr);
    199199  }
    200  
     200
    201201  //
    202202  // Locate all Fvb protocol
     
    243243      Status = FvbProtocol->GetAttributes (FvbProtocol, &Attributes);
    244244      if (EFI_ERROR (Status) || ((Attributes & EFI_FVB2_WRITE_STATUS) == 0)) {
    245         continue;     
     245        continue;
    246246      }
    247247
     
    327327      return Status;
    328328    }
    329  
     329
    330330    //
    331331    // Check if we are done with the update
     
    541541  //
    542542  // FvAlignment must be greater than or equal to 8 bytes of the minimum FFS alignment value.
    543   // 
     543  //
    544544  if (FvAlignment < 8) {
    545545    FvAlignment = 8;
     
    584584  Find the image in the same FV and program it in a target Firmware Volume device.
    585585  After update image, it will reset system and no return.
    586  
     586
    587587  @param ImageHandle   A handle for the image that is initializing this driver
    588588  @param SystemTable   A pointer to the EFI system table
     
    603603  EFI_FIRMWARE_VOLUME2_PROTOCOL         *FwVolProtocol;
    604604  EFI_FIRMWARE_VOLUME2_PROTOCOL         *DataFwVolProtocol;
    605   MEDIA_FW_VOL_FILEPATH_DEVICE_PATH     *FwVolFilePathNode; 
     605  MEDIA_FW_VOL_FILEPATH_DEVICE_PATH     *FwVolFilePathNode;
    606606  MEDIA_FW_VOL_FILEPATH_DEVICE_PATH     *AlignedDevPathNode;
    607607  EFI_DEVICE_PATH_PROTOCOL              *FilePathNode;
     
    816816               );
    817817    //
    818     // Shall updates be serialized so that if an update is not successfully completed, 
     818    // Shall updates be serialized so that if an update is not successfully completed,
    819819    // the remaining updates won't be performed.
    820820    //
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/FirmwareVolume/UpdateDriverDxe/UpdateDriverDxe.inf

    r58459 r58466  
    22# Update Driver for Capulse update.
    33#
    4 # This driver is intended to be put in a capsule (FV). If all goes well, 
    5 # then it should be dispatched from the capsule FV, then find the image 
     4# This driver is intended to be put in a capsule (FV). If all goes well,
     5# then it should be dispatched from the capsule FV, then find the image
    66# in the same FV and program it in a target Firmware Volume device.
    77#
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/FirmwareVolume/UpdateDriverDxe/UpdateStrings.uni

    • Property svn:mime-type changed from application/octet-stream to text/plain;encoding=UTF-16LE
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/LegacyRegionDxe/LegacyRegion.c

    r48674 r58466  
    22  Produces the Legacy Region Protocol.
    33
    4   This generic implementation of the Legacy Region Protocol does not actually 
    5   perform any lock/unlock operations.  This module may be used on platforms 
    6   that do not provide HW locking of the legacy memory regions.  It can also 
     4  This generic implementation of the Legacy Region Protocol does not actually
     5  perform any lock/unlock operations.  This module may be used on platforms
     6  that do not provide HW locking of the legacy memory regions.  It can also
    77  be used as a template driver for implementing the Legacy Region Protocol on
    88  a platform that does support HW locking of the legacy memory regions.
     
    136136  The user Entry Point for module LegacyRegionDxe.  The user code starts with this function.
    137137
    138   @param[in] ImageHandle    The firmware allocated handle for the EFI image. 
     138  @param[in] ImageHandle    The firmware allocated handle for the EFI image.
    139139  @param[in] SystemTable    A pointer to the EFI System Table.
    140  
     140
    141141  @retval EFI_SUCCESS       The entry point is executed successfully.
    142142  @retval other             Some error occurs when executing this entry point.
     
    151151{
    152152  EFI_STATUS  Status;
    153  
     153
    154154  //
    155155  // Make sure the Legacy Region Protocol is not already installed in the system
    156156  //
    157157  ASSERT_PROTOCOL_ALREADY_INSTALLED (NULL, &gEfiLegacyRegionProtocolGuid);
    158  
     158
    159159  //
    160160  // Install the protocol on a new handle.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/LegacyRegionDxe/LegacyRegionDxe.inf

    r58459 r58466  
    22#  Produces Framework Legacy Region Protocol.
    33#
    4 #  This generic implementation of the Legacy Region Protocol does not actually 
    5 #  perform any lock/unlock operations.  This module may be used on platforms 
    6 #  that do not provide HW locking of the legacy memory regions.  It can also 
     4#  This generic implementation of the Legacy Region Protocol does not actually
     5#  perform any lock/unlock operations.  This module may be used on platforms
     6#  that do not provide HW locking of the legacy memory regions.  It can also
    77#  be used as a template driver for implementing the Legacy Region Protocol on
    88#  a platform that does support HW locking of the legacy memory regions.
     
    1313# which accompanies this distribution.  The full text of the license may be found at
    1414# http://opensource.org/licenses/bsd-license.php
    15 #                                                                                           
     15#
    1616# THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1717# WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/SectionExtractionDxe/SectionExtraction.c

    r58459 r58466  
    11/** @file
    22  Section Extraction Protocol implementation.
    3  
     3
    44  Stream database is implemented as a linked list of section streams,
    55  where each stream contains a linked list of children, which may be leaves or
    6   encapsulations. 
    7  
     6  encapsulations.
     7
    88  Children that are encapsulations generate new stream entries
    9   when they are created.  Streams can also be created by calls to 
     9  when they are created.  Streams can also be created by calls to
    1010  SEP->OpenSectionStream().
    11  
     11
    1212  The database is only created far enough to return the requested data from
    1313  any given stream, or to determine that the requested data is not found.
    14  
     14
    1515  If a GUIDed encapsulation is encountered, there are three possiblilites.
    16  
     16
    1717  1) A support protocol is found, in which the stream is simply processed with
    1818     the support protocol.
    19      
     19
    2020  2) A support protocol is not found, but the data is available to be read
    2121     without processing.  In this case, the database is built up through the
    2222     recursions to return the data, and a RPN event is set that will enable
    2323     the stream in question to be refreshed if and when the required section
    24      extraction protocol is published.This insures the AuthenticationStatus 
     24     extraction protocol is published.This insures the AuthenticationStatus
    2525     does not become stale in the cache.
    26      
     26
    2727  3) A support protocol is not found, and the data is not available to be read
    2828     without it.  This results in EFI_PROTOCOL_ERROR.
     
    7878  EFI_GUID                    *EncapsulationGuid;
    7979  //
    80   // If the section REQUIRES an extraction protocol, register for RPN 
     80  // If the section REQUIRES an extraction protocol, register for RPN
    8181  // when the required GUIDed extraction protocol becomes available.
    8282  //
     
    158158                               section.
    159159
    160  
     160
    161161  @retval EFI_SUCCESS           Section was retrieved successfully
    162   @retval EFI_PROTOCOL_ERROR    A GUID defined section was encountered in the section 
     162  @retval EFI_PROTOCOL_ERROR    A GUID defined section was encountered in the section
    163163                                stream with its EFI_GUIDED_SECTION_PROCESSING_REQUIRED
    164                                 bit set, but there was no corresponding GUIDed Section 
    165                                 Extraction Protocol in the handle database.  *Buffer is 
     164                                bit set, but there was no corresponding GUIDed Section
     165                                Extraction Protocol in the handle database.  *Buffer is
    166166                                unmodified.
    167167  @retval EFI_NOT_FOUND         An error was encountered when parsing the SectionStream.
    168                                 This indicates the SectionStream  is not correctly 
     168                                This indicates the SectionStream  is not correctly
    169169                                formatted.
    170170  @retval EFI_NOT_FOUND         The requested section does not exist.
    171   @retval EFI_OUT_OF_RESOURCES  The system has insufficient resources to process the 
     171  @retval EFI_OUT_OF_RESOURCES  The system has insufficient resources to process the
    172172                                request.
    173173  @retval EFI_INVALID_PARAMETER The SectionStreamHandle does not exist.
    174   @retval EFI_WARN_TOO_SMALL    The size of the caller allocated input buffer is 
    175                                 insufficient to contain the requested section.  The 
     174  @retval EFI_WARN_TOO_SMALL    The size of the caller allocated input buffer is
     175                                insufficient to contain the requested section.  The
    176176                                input buffer is filled and contents are section contents
    177177                                are truncated.
     
    219219EFI_HANDLE mSectionExtractionHandle = NULL;
    220220
    221 EFI_SECTION_EXTRACTION_PROTOCOL mSectionExtraction = { 
    222   OpenSectionStream, 
    223   GetSection, 
     221EFI_SECTION_EXTRACTION_PROTOCOL mSectionExtraction = {
     222  OpenSectionStream,
     223  GetSection,
    224224  CloseSectionStream
    225225};
    226226
    227227/**
    228   Entry point of the section extraction code. Initializes an instance of the 
     228  Entry point of the section extraction code. Initializes an instance of the
    229229  section extraction interface and installs it on a new handle.
    230230
    231231  @param ImageHandle             A handle for the image that is initializing this driver
    232   @param SystemTable             A pointer to the EFI system table       
     232  @param SystemTable             A pointer to the EFI system table
    233233
    234234  @retval EFI_SUCCESS            Driver initialized successfully
     
    282282  TotalLength = 0;
    283283  SectionHeader = (EFI_COMMON_SECTION_HEADER *)SectionStream;
    284  
     284
    285285  while (TotalLength < SectionStreamLength) {
    286286    if (IS_SECTION2 (SectionHeader)) {
     
    292292
    293293    if (TotalLength == SectionStreamLength) {
    294       return TRUE;   
     294      return TRUE;
    295295    }
    296296
     
    299299    //
    300300    SectionHeader = (EFI_COMMON_SECTION_HEADER *) ((UINT8 *) SectionHeader + SectionLength);
    301    
     301
    302302    //
    303303    // Figure out where the next section begins
     
    332332  IN     VOID                                      *SectionStream,
    333333  IN     BOOLEAN                                   AllocateBuffer,
    334   IN     UINT32                                    AuthenticationStatus,   
     334  IN     UINT32                                    AuthenticationStatus,
    335335     OUT UINTN                                     *SectionStreamHandle
    336336  )
     
    338338  FRAMEWORK_SECTION_STREAM_NODE    *NewStream;
    339339  EFI_TPL                          OldTpl;
    340  
     340
    341341  //
    342342  // Allocate a new stream
     
    346346    return EFI_OUT_OF_RESOURCES;
    347347  }
    348  
    349   if (AllocateBuffer) { 
     348
     349  if (AllocateBuffer) {
    350350    //
    351351    // if we're here, we're double buffering, allocate the buffer and copy the
     
    353353    //
    354354    if (SectionStreamLength > 0) {
    355       NewStream->StreamBuffer = AllocatePool (SectionStreamLength); 
     355      NewStream->StreamBuffer = AllocatePool (SectionStreamLength);
    356356      if (NewStream->StreamBuffer == NULL) {
    357357        FreePool (NewStream);
     
    376376    NewStream->StreamBuffer = SectionStream;
    377377  }
    378  
     378
    379379  //
    380380  // Initialize the rest of the section stream
     
    385385  InitializeListHead (&NewStream->Children);
    386386  NewStream->AuthenticationStatus = AuthenticationStatus;
    387  
     387
    388388  //
    389389  // Add new stream to stream list
     
    394394
    395395  *SectionStreamHandle = NewStream->StreamHandle;
    396  
     396
    397397  return EFI_SUCCESS;
    398398}
     
    429429    return EFI_INVALID_PARAMETER;
    430430  }
    431  
    432   return OpenSectionStreamEx ( 
    433           SectionStreamLength, 
     431
     432  return OpenSectionStreamEx (
     433          SectionStreamLength,
    434434          SectionStream,
    435435          TRUE,
     
    461461{
    462462  EFI_GUID_DEFINED_SECTION    *GuidedSection;
    463  
     463
    464464  if (SearchType == EFI_SECTION_ALL) {
    465465    return TRUE;
     
    550550  @return TRUE      The GuidedSectionGuid could be identified, and the pointer to
    551551                    the Guided Section Extraction Protocol will be returned to *GuidedSectionExtraction.
    552   @return FALSE     The GuidedSectionGuid could not be identified, or 
     552  @return FALSE     The GuidedSectionGuid could not be identified, or
    553553                    the Guided Section Extraction Protocol has not been installed yet.
    554554
     
    589589
    590590/**
    591   RPN callback function. 
     591  RPN callback function.
    592592  1. Initialize the section stream when the GUIDED_SECTION_EXTRACTION_PROTOCOL is installed.
    593593  2. Removes a stale section stream and re-initializes it with an updated AuthenticationStatus.
     
    612612  UINT32                                  AuthenticationStatus;
    613613  RPN_EVENT_CONTEXT                       *Context;
    614  
     614
    615615  Context = RpnContext;
    616616  Status = EFI_SUCCESS;
     
    620620  if (!EFI_ERROR (Status)) {
    621621    //
    622     // The stream is not initialized, open it. 
     622    // The stream is not initialized, open it.
    623623    // Or the stream closed successfully, so re-open the stream with correct AuthenticationStatus.
    624624    //
    625  
    626     GuidedHeader = (EFI_GUID_DEFINED_SECTION *) 
     625
     626    GuidedHeader = (EFI_GUID_DEFINED_SECTION *)
    627627      (Context->ParentStream->StreamBuffer + Context->ChildNode->OffsetInStream);
    628628    ASSERT (GuidedHeader->CommonHeader.Type == EFI_SECTION_GUID_DEFINED);
    629    
     629
    630630    if (!VerifyGuidedSectionGuid (Context->ChildNode->EncapsulationGuid, &GuidedExtraction)) {
    631631      return;
     
    659659  //  it.
    660660  //
    661  
     661
    662662  gBS->CloseEvent (Event);
    663663  Context->ChildNode->Event = NULL;
    664664  FreePool (Context);
    665 } 
     665}
    666666
    667667/**
     
    680680{
    681681  RPN_EVENT_CONTEXT *Context;
    682  
     682
    683683  //
    684684  // Allocate new event structure and context
     
    686686  Context = AllocatePool (sizeof (RPN_EVENT_CONTEXT));
    687687  ASSERT (Context != NULL);
    688  
     688
    689689  Context->ChildNode = ChildNode;
    690690  Context->ParentStream = ParentStream;
    691  
     691
    692692  Context->ChildNode->Event = CreateProtocolNotifyEvent (
    693693                                Context->ChildNode->EncapsulationGuid,
     
    741741  UINT8                                        CompressionType;
    742742  UINT16                                       GuidedSectionAttributes;
    743    
     743
    744744  FRAMEWORK_SECTION_CHILD_NODE                      *Node;
    745745
     
    754754    return EFI_OUT_OF_RESOURCES;
    755755  }
    756  
     756
    757757  //
    758758  // Now initialize it
     
    768768  Node->EncapsulatedStreamHandle = NULL_STREAM_HANDLE;
    769769  Node->EncapsulationGuid = NULL;
    770  
     770
    771771  //
    772772  // If it's an encapsulating section, then create the new section stream also
     
    806806          return EFI_OUT_OF_RESOURCES;
    807807        }
    808        
     808
    809809        if (CompressionType == EFI_NOT_COMPRESSED) {
    810810          //
     
    815815          //
    816816          // Only support the EFI_SATNDARD_COMPRESSION algorithm.
    817           // 
     817          //
    818818
    819819          //
     
    821821          //
    822822          Status = gBS->LocateProtocol (&gEfiDecompressProtocolGuid, NULL, (VOID **)&Decompress);
    823          
     823
    824824          ASSERT_EFI_ERROR (Status);
    825          
     825
    826826          Status = Decompress->GetInfo (
    827827                                 Decompress,
     
    856856                                 ScratchSize
    857857                                 );
    858           FreePool (ScratchBuffer); 
     858          FreePool (ScratchBuffer);
    859859          if (EFI_ERROR (Status)) {
    860860            FreePool (Node);
     
    867867        NewStreamBufferSize = 0;
    868868      }
    869      
     869
    870870      Status = OpenSectionStreamEx (
    871871                 NewStreamBufferSize,
     
    907907          return EFI_PROTOCOL_ERROR;
    908908        }
    909        
     909
    910910        //
    911         // Make sure we initialize the new stream with the correct 
     911        // Make sure we initialize the new stream with the correct
    912912        // authentication status for both aggregate and local status fields.
    913913        //
     
    924924          AuthenticationStatus = Stream->AuthenticationStatus;
    925925        }
    926        
     926
    927927        Status = OpenSectionStreamEx (
    928928                   NewStreamBufferSize,
     
    943943        if ((GuidedSectionAttributes & EFI_GUIDED_SECTION_PROCESSING_REQUIRED) == EFI_GUIDED_SECTION_PROCESSING_REQUIRED) {
    944944          //
    945           // If the section REQUIRES an extraction protocol, register for RPN 
    946           // when the required GUIDed extraction protocol becomes available. 
     945          // If the section REQUIRES an extraction protocol, register for RPN
     946          // when the required GUIDed extraction protocol becomes available.
    947947          //
    948948          AuthenticationStatus = 0;
     
    955955          if ((GuidedSectionAttributes & EFI_GUIDED_SECTION_AUTH_STATUS_VALID) == EFI_GUIDED_SECTION_AUTH_STATUS_VALID) {
    956956            //
    957             //  The local status of the new stream is contained in 
     957            //  The local status of the new stream is contained in
    958958            //  AuthenticaionStatus.  This value needs to be ORed into the
    959959            //  Aggregate bits also...
    960960            //
    961            
     961
    962962            //
    963963            // Clear out and initialize the local status
     
    970970            AuthenticationStatus |= AuthenticationStatus >> 16;
    971971          }
    972          
     972
    973973          if (IS_SECTION2 (GuidedHeader)) {
    974974            Status = OpenSectionStreamEx (
     
    994994        }
    995995      }
    996      
    997       if ((AuthenticationStatus & EFI_LOCAL_AUTH_STATUS_ALL) == 
     996
     997      if ((AuthenticationStatus & EFI_LOCAL_AUTH_STATUS_ALL) ==
    998998            (EFI_LOCAL_AUTH_STATUS_IMAGE_SIGNED | EFI_LOCAL_AUTH_STATUS_NOT_TESTED)) {
    999999        //
     
    10051005        CreateGuidedExtractionRpnEvent (Stream, Node);
    10061006      }
    1007      
     1007
    10081008      break;
    10091009
    10101010    default:
    1011      
     1011
    10121012      //
    10131013      // Nothing to do if it's a leaf
     
    10151015      break;
    10161016  }
    1017  
     1017
    10181018  //
    10191019  // Last, add the new child node to the stream
     
    10651065  EFI_STATUS                                    ErrorStatus;
    10661066  EFI_STATUS                                    Status;
    1067  
     1067
    10681068  CurrentChildNode = NULL;
    10691069  ErrorStatus = EFI_NOT_FOUND;
    1070  
     1070
    10711071  if (SourceStream->StreamLength == 0) {
    10721072    return EFI_NOT_FOUND;
    10731073  }
    1074  
    1075   if (IsListEmpty (&SourceStream->Children) && 
     1074
     1075  if (IsListEmpty (&SourceStream->Children) &&
    10761076                   SourceStream->StreamLength >= sizeof (EFI_COMMON_SECTION_HEADER)) {
    10771077    //
     
    10871087    }
    10881088  }
    1089  
     1089
    10901090  //
    10911091  // At least one child has been parsed out of the section stream.  So, walk
     
    11141114      }
    11151115    }
    1116    
     1116
    11171117    if (CurrentChildNode->EncapsulatedStreamHandle != NULL_STREAM_HANDLE) {
    11181118      //
     
    11481148      ErrorStatus = EFI_PROTOCOL_ERROR;
    11491149    }
    1150    
     1150
    11511151    if (!IsNodeAtEnd (&SourceStream->Children, &CurrentChildNode->Link)) {
    11521152      //
     
    12001200  OUT FRAMEWORK_SECTION_STREAM_NODE                  **FoundStream
    12011201  )
    1202 { 
     1202{
    12031203  FRAMEWORK_SECTION_STREAM_NODE                      *StreamNode;
    1204  
     1204
    12051205  if (!IsListEmpty (&mStreamRoot)) {
    12061206    StreamNode = STREAM_NODE_FROM_LINK (GetFirstNode (&mStreamRoot));
     
    12161216    }
    12171217  }
    1218  
     1218
    12191219  return EFI_NOT_FOUND;
    12201220}
    1221  
     1221
    12221222/**
    12231223  SEP member function.  Retrieves requested section from section stream.
     
    12431243                               section.
    12441244
    1245  
     1245
    12461246  @retval EFI_SUCCESS           Section was retrieved successfully
    1247   @retval EFI_PROTOCOL_ERROR    A GUID defined section was encountered in the section 
     1247  @retval EFI_PROTOCOL_ERROR    A GUID defined section was encountered in the section
    12481248                                stream with its EFI_GUIDED_SECTION_PROCESSING_REQUIRED
    1249                                 bit set, but there was no corresponding GUIDed Section 
    1250                                 Extraction Protocol in the handle database.  *Buffer is 
     1249                                bit set, but there was no corresponding GUIDed Section
     1250                                Extraction Protocol in the handle database.  *Buffer is
    12511251                                unmodified.
    12521252  @retval EFI_NOT_FOUND         An error was encountered when parsing the SectionStream.
    1253                                 This indicates the SectionStream  is not correctly 
     1253                                This indicates the SectionStream  is not correctly
    12541254                                formatted.
    12551255  @retval EFI_NOT_FOUND         The requested section does not exist.
    1256   @retval EFI_OUT_OF_RESOURCES  The system has insufficient resources to process the 
     1256  @retval EFI_OUT_OF_RESOURCES  The system has insufficient resources to process the
    12571257                                request.
    12581258  @retval EFI_INVALID_PARAMETER The SectionStreamHandle does not exist.
    1259   @retval EFI_WARN_TOO_SMALL    The size of the caller allocated input buffer is 
    1260                                 insufficient to contain the requested section.  The 
     1259  @retval EFI_WARN_TOO_SMALL    The size of the caller allocated input buffer is
     1260                                insufficient to contain the requested section.  The
    12611261                                input buffer is filled and contents are section contents
    12621262                                are truncated.
     
    12871287  UINTN                                                 SectionSize;
    12881288  EFI_COMMON_SECTION_HEADER                             *Section;
    1289  
     1289
    12901290
    12911291  OldTpl = gBS->RaiseTPL (TPL_NOTIFY);
    12921292  Instance = SectionInstance + 1;
    12931293  ChildStreamNode = NULL;
    1294  
     1294
    12951295  //
    12961296  // Locate target stream
     
    13011301    goto GetSection_Done;
    13021302  }
    1303  
     1303
    13041304  //
    13051305  // Found the stream, now locate and return the appropriate section
     
    13171317    //
    13181318    Status = FindChildNode (
    1319                       StreamNode, 
    1320                       *SectionType, 
    1321                       &Instance, 
     1319                      StreamNode,
     1320                      *SectionType,
     1321                      &Instance,
    13221322                      SectionDefinitionGuid,
    13231323                      &ChildNode,
    1324                       &ChildStreamNode, 
     1324                      &ChildStreamNode,
    13251325                      &ExtractedAuthenticationStatus
    13261326                      );
     
    13401340    }
    13411341    *AuthenticationStatus = ExtractedAuthenticationStatus;
    1342   }   
    1343    
    1344   SectionSize = CopySize; 
     1342  }
     1343
     1344  SectionSize = CopySize;
    13451345  if (*Buffer != NULL) {
    13461346    //
     
    13631363  CopyMem (*Buffer, CopyBuffer, CopySize);
    13641364  *BufferSize = SectionSize;
    1365  
     1365
    13661366GetSection_Done:
    13671367  gBS->RestoreTPL (OldTpl);
     
    13851385  //
    13861386  RemoveEntryList (&ChildNode->Link);
    1387  
     1387
    13881388  if (ChildNode->EncapsulatedStreamHandle != NULL_STREAM_HANDLE) {
    13891389    //
     
    14021402  //
    14031403  FreePool (ChildNode);
    1404 } 
     1404}
    14051405
    14061406/**
     
    14281428  LIST_ENTRY                                    *Link;
    14291429  FRAMEWORK_SECTION_CHILD_NODE                       *ChildNode;
    1430  
     1430
    14311431  OldTpl = gBS->RaiseTPL (TPL_NOTIFY);
    1432  
     1432
    14331433  //
    14341434  // Locate target stream
     
    14511451    Status = EFI_INVALID_PARAMETER;
    14521452  }
    1453  
     1453
    14541454  gBS->RestoreTPL (OldTpl);
    14551455  return Status;
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/SectionExtractionDxe/SectionExtractionDxe.inf

    r58459 r58466  
    55#  where each stream contains a linked list of children, which may be leaves or
    66#  encapsulations. Encapsulation section will further generate new section stream entries.
    7 # 
     7#
    88#  Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
    99#  This program and the accompanying materials
     
    1111#  which accompanies this distribution.  The full text of the license may be found at
    1212#  http://opensource.org/licenses/bsd-license.php
    13 # 
     13#
    1414#  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
    1515#  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    16 # 
     16#
    1717##
    1818
     
    2424  MODULE_TYPE                    = DXE_DRIVER
    2525  VERSION_STRING                 = 1.0
    26   ENTRY_POINT                    = SectionExtractionEntryPoint 
     26  ENTRY_POINT                    = SectionExtractionEntryPoint
    2727
    2828# The following information is for reference only and not required by the build tools.
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/StatusCode/DatahubStatusCodeHandlerDxe/DataHubStatusCodeWorker.c

    r48674 r58466  
    6363      //
    6464      // Memory management should work at <=TPL_NOTIFY
    65       // 
     65      //
    6666      gBS->RestoreTPL (CurrentTpl);
    6767      return NULL;
     
    133133/**
    134134  Release given record and return it to free record buffer.
    135  
     135
    136136  @param RecordData  Pointer to the record to release.
    137137
     
    349349
    350350  Status = gBS->LocateProtocol (
    351                   &gEfiDataHubProtocolGuid, 
    352                   NULL, 
     351                  &gEfiDataHubProtocolGuid,
     352                  NULL,
    353353                  (VOID **) &mDataHubProtocol
    354354                  );
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/StatusCode/DatahubStatusCodeHandlerDxe/DatahubStatusCodeHandlerDxe.c

    r48674 r58466  
    4646  @param  ImageHandle       The firmware allocated handle for the EFI image.
    4747  @param  SystemTable       A pointer to the EFI System Table.
    48  
     48
    4949  @retval EFI_SUCCESS       The entry point is executed successfully.
    5050
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/StatusCode/DatahubStatusCodeHandlerDxe/DatahubStatusCodeHandlerDxe.inf

    r58459 r58466  
    2020  FILE_GUID                      = 863D214F-0920-437B-8CAD-88EA83A24E97
    2121  MODULE_TYPE                    = DXE_DRIVER
    22   VERSION_STRING                 = 1.0 
     22  VERSION_STRING                 = 1.0
    2323  ENTRY_POINT                    = DatahubStatusCodeHandlerDxeEntry
    2424
     
    3333  DatahubStatusCodeHandlerDxe.c
    3434  DataHubStatusCodeWorker.c
    35  
     35
    3636[Packages]
    3737  MdePkg/MdePkg.dec
     
    3939  IntelFrameworkPkg/IntelFrameworkPkg.dec
    4040  IntelFrameworkModulePkg/IntelFrameworkModulePkg.dec
    41  
     41
    4242[LibraryClasses]
    4343  BaseLib
     
    5151  SynchronizationLib
    5252  BaseMemoryLib
    53  
     53
    5454[Guids]
    5555  gEfiEventExitBootServicesGuid                 ## CONSUMES ## Event
    5656  gEfiDataHubStatusCodeRecordGuid               ## PRODUCES ## UNDEFINED # DataRecord Guid
    5757  gEfiStatusCodeDataTypeDebugGuid               ## SOMETIMES_PRODUCES ## UNDEFINED # Record data type
    58  
     58
    5959[Protocols]
    6060  gEfiRscHandlerProtocolGuid                    ## CONSUMES
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/StatusCode/Pei/MemoryStausCodeWorker.c

    r48674 r58466  
    8282
    8383  //
    84   // Find GUID'ed HOBs to locate current record buffer. 
     84  // Find GUID'ed HOBs to locate current record buffer.
    8585  //
    8686  Hob.Raw = GetFirstGuidHob (&gMemoryStatusCodeRecordGuid);
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/StatusCode/Pei/StatusCodePei.c

    r48674 r58466  
    9696/**
    9797  Entry point of Status Code PEIM.
    98  
     98
    9999  This function is the entry point of this Status Code PEIM.
    100100  It initializes supported status code devices according to PCD settings,
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/StatusCode/RuntimeDxe/DataHubStatusCodeWorker.c

    r48674 r58466  
    6363      //
    6464      // Memory management should work at <=TPL_NOTIFY
    65       // 
     65      //
    6666      gBS->RestoreTPL (CurrentTpl);
    6767      return NULL;
     
    133133/**
    134134  Release given record and return it to free record buffer.
    135  
     135
    136136  @param RecordData  Pointer to the record to release.
    137137
     
    213213    }
    214214  }
    215  
     215
    216216  Record = AcquireRecordBuffer ();
    217217  if (Record == NULL) {
     
    363363
    364364  Status = gBS->LocateProtocol (
    365                   &gEfiDataHubProtocolGuid, 
    366                   NULL, 
     365                  &gEfiDataHubProtocolGuid,
     366                  NULL,
    367367                  (VOID **) &mDataHubProtocol
    368368                  );
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/StatusCode/RuntimeDxe/RtMemoryStatusCodeWorker.c

    r48674 r58466  
    33
    44  Copyright (c) 2006 - 2009, Intel Corporation. All rights reserved.<BR>
    5   This program and the accompanying materials                         
    6   are licensed and made available under the terms and conditions of the BSD License         
    7   which accompanies this distribution.  The full text of the license may be found at       
    8   http://opensource.org/licenses/bsd-license.php                                           
    9                                                                                            
    10   THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
    11   WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             
     5  This program and the accompanying materials
     6  are licensed and made available under the terms and conditions of the BSD License
     7  which accompanies this distribution.  The full text of the license may be found at
     8  http://opensource.org/licenses/bsd-license.php
     9
     10  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     11  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
    1313**/
     
    1919/**
    2020  Initialize runtime memory status code table as initialization for runtime memory status code worker
    21  
     21
    2222  @retval EFI_SUCCESS  Runtime memory status code table successfully initialized.
    2323
     
    3939  mRtMemoryStatusCodeTable->RecordIndex      = 0;
    4040  mRtMemoryStatusCodeTable->NumberOfRecords  = 0;
    41   mRtMemoryStatusCodeTable->MaxRecordsNumber = 
     41  mRtMemoryStatusCodeTable->MaxRecordsNumber =
    4242    (PcdGet16 (PcdStatusCodeMemorySize) * 1024) / sizeof (MEMORY_STATUSCODE_RECORD);
    4343
     
    4747
    4848/**
    49   Report status code into runtime memory. If the runtime pool is full, roll back to the 
     49  Report status code into runtime memory. If the runtime pool is full, roll back to the
    5050  first record and overwrite it.
    51  
     51
    5252  @param  CodeType                Indicates the type of status code being reported.
    5353  @param  Value                   Describes the current status of a hardware or software entity.
     
    5656  @param  Instance                The enumeration of a hardware or software entity within
    5757                                  the system. Valid instance numbers start with 1.
    58  
     58
    5959  @retval EFI_SUCCESS             Status code successfully recorded in runtime memory status code table.
    6060
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/StatusCode/RuntimeDxe/SerialStatusCodeWorker.c

    r58459 r58466  
    33
    44  Copyright (c) 2006 - 2014, Intel Corporation. All rights reserved.<BR>
    5   This program and the accompanying materials                         
    6   are licensed and made available under the terms and conditions of the BSD License         
    7   which accompanies this distribution.  The full text of the license may be found at       
    8   http://opensource.org/licenses/bsd-license.php                                           
    9                                                                                            
    10   THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,                     
    11   WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.             
     5  This program and the accompanying materials
     6  are licensed and made available under the terms and conditions of the BSD License
     7  which accompanies this distribution.  The full text of the license may be found at
     8  http://opensource.org/licenses/bsd-license.php
     9
     10  THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     11  WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
    1212
    1313**/
     
    1717/**
    1818  Convert status code value and extended data to readable ASCII string, send string to serial I/O device.
    19  
     19
    2020  @param  CodeType         Indicates the type of status code being reported.
    2121  @param  Value            Describes the current status of a hardware or software entity.
     
    7373    //
    7474    CharCount = AsciiBSPrint (
    75                   Buffer, 
    76                   sizeof (Buffer), 
    77                   Format, 
     75                  Buffer,
     76                  sizeof (Buffer),
     77                  Format,
    7878                  Marker
    7979                  );
     
    8383    //
    8484    CharCount = AsciiSPrint (
    85                   Buffer, 
    86                   sizeof (Buffer), 
    87                   "ERROR: C%08x:V%08x I%x", 
    88                   CodeType, 
    89                   Value, 
     85                  Buffer,
     86                  sizeof (Buffer),
     87                  "ERROR: C%08x:V%08x I%x",
     88                  CodeType,
     89                  Value,
    9090                  Instance
    9191                  );
    92    
     92
    9393    if (CallerId != NULL) {
    9494      CharCount += AsciiSPrint (
     
    119119    //
    120120    CharCount = AsciiSPrint (
    121                   Buffer, 
    122                   sizeof (Buffer), 
    123                   "PROGRESS CODE: V%08x I%x\n\r", 
    124                   Value, 
     121                  Buffer,
     122                  sizeof (Buffer),
     123                  "PROGRESS CODE: V%08x I%x\n\r",
     124                  Value,
    125125                  Instance
    126126                  );
     
    142142    //
    143143    CharCount = AsciiSPrint (
    144                   Buffer, 
    145                   sizeof (Buffer), 
    146                   "Undefined: C%08x:V%08x I%x\n\r", 
    147                   CodeType, 
    148                   Value, 
     144                  Buffer,
     145                  sizeof (Buffer),
     146                  "Undefined: C%08x:V%08x I%x\n\r",
     147                  CodeType,
     148                  Value,
    149149                  Instance
    150150                  );
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/StatusCode/RuntimeDxe/StatusCodeRuntimeDxe.c

    r48674 r58466  
    3939  @param  ImageHandle       The firmware allocated handle for the EFI image.
    4040  @param  SystemTable       A pointer to the EFI System Table.
    41  
     41
    4242  @retval EFI_SUCCESS       The entry point is executed successfully.
    4343
     
    193193
    194194/**
    195   Dispatch initialization request to sub status code devices based on 
     195  Dispatch initialization request to sub status code devices based on
    196196  customized feature flags.
    197  
     197
    198198**/
    199199VOID
     
    237237
    238238  //
    239   // Replay Status code which saved in GUID'ed HOB to all supported devices. 
     239  // Replay Status code which saved in GUID'ed HOB to all supported devices.
    240240  //
    241241  if (FeaturePcdGet (PcdStatusCodeReplayIn)) {
    242     // 
    243     // Journal GUID'ed HOBs to find all record entry, if found, 
     242    //
     243    // Journal GUID'ed HOBs to find all record entry, if found,
    244244    // then output record to support replay device.
    245245    //
  • trunk/src/VBox/Devices/EFI/Firmware/IntelFrameworkModulePkg/Universal/StatusCode/RuntimeDxe/StatusCodeRuntimeDxe.h

    r48674 r58466  
    9797
    9898/**
    99   Dispatch initialization request to sub status code devices based on 
     99  Dispatch initialization request to sub status code devices based on
    100100  customized feature flags.
    101  
     101
    102102**/
    103103VOID
     
    109109/**
    110110  Locates Serial I/O Protocol as initialization for serial status code worker.
    111  
     111
    112112  @retval EFI_SUCCESS  Serial I/O Protocol is successfully located.
    113113
     
    121121/**
    122122  Convert status code value and extended data to readable ASCII string, send string to serial I/O device.
    123  
     123
    124124  @param  CodeType         Indicates the type of status code being reported.
    125125  @param  Value            Describes the current status of a hardware or software entity.
     
    149149/**
    150150  Initialize runtime memory status code table as initialization for runtime memory status code worker
    151  
     151
    152152  @retval EFI_SUCCESS  Runtime memory status code table successfully initialized.
    153153
     
    159159
    160160/**
    161   Report status code into runtime memory. If the runtime pool is full, roll back to the 
     161  Report status code into runtime memory. If the runtime pool is full, roll back to the
    162162  first record and overwrite it.
    163  
     163
    164164  @param  CodeType                Indicates the type of status code being reported.
    165165  @param  Value                   Describes the current status of a hardware or software entity.
     
    168168  @param  Instance                The enumeration of a hardware or software entity within
    169169                                  the system. Valid instance numbers start with 1.
    170  
     170
    171171  @retval EFI_SUCCESS             Status code successfully recorded in runtime memory status code table.
    172172
Note: See TracChangeset for help on using the changeset viewer.

© 2024 Oracle Support Privacy / Do Not Sell My Info Terms of Use Trademark Policy Automated Access Etiquette