Home | History | Annotate | Download | only in Protocol
      1 /*++
      2 
      3   Copyright (c) 2004  - 2014, Intel Corporation. All rights reserved.<BR>
      4 
      5   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.
      9   The full text of the license may be found at
     11   http://opensource.org/licenses/bsd-license.php.
     13 
     15   THE PROGRAM IS DISTRIBUTED UNDER THE BSD LICENSE ON AN "AS IS" BASIS,
     17   WITHOUT WARRANTIES OR REPRESENTATIONS OF ANY KIND, EITHER EXPRESS OR IMPLIED.
     19 
     21 
     23 **/
     24 
     25 #ifndef __MMIO_DEVICE_H__
     26 #define __MMIO_DEVICE_H__
     27 
     28 //
     29 // Protocol to define for the MMIO device
     30 //
     31 typedef struct {
     32   //
     33   // Address of a GUID
     34   //
     35   EFI_GUID *Guid;
     36 
     37   //
     38   // Context for the protocol
     39   //
     40   VOID *Context;
     41 } EFI_MMIO_DEVICE_PROTOCOL_ITEM;
     42 
     43 
     44 typedef struct _EFI_MMIO_DEVICE_PROTOCOL  EFI_MMIO_DEVICE_PROTOCOL;
     45 
     46 //
     47 //  The MMIO device protocol defines a memory mapped I/O device
     48 //  for use by the system.
     49 //
     50 struct _EFI_MMIO_DEVICE_PROTOCOL {
     51   //
     52   // Pointer to an ACPI_EXTENDED_HID_DEVICE_PATH structure
     53   // containing HID/HidStr and CID/CidStr values.
     54   //
     55   // See the note below associated with the UnitIdentification
     56   // field.
     57   //
     58   CONST ACPI_EXTENDED_HID_DEVICE_PATH *AcpiPath;
     59 
     60   //
     61   // Allow the use of a shared template for the AcpiPath.
     62   //
     63   // If this value is non-zero UID value then the AcpiPath must
     64   // be a template which contains only the HID/HidStr and CID/CidStr
     65   // values.  The UID/UidStr values in the AcpiPath must be zero!
     66   //
     67   // If this value is zero then the AcpiPath is not shared and
     68   // must contain either a non-zero UID value or a UidStr value.
     69   //
     70   UINT32 UnitIdentification;
     71 
     72   //
     73   // Hardware revision - ACPI _HRV value
     74   //
     75   UINT32 HardwareRevision;
     76 
     77   //
     78   // Pointer to a data structure containing the controller
     79   // resources and configuration.  At a minimum this points
     80   // to an EFI_PHYSICAL_ADDRESS for the base address of the
     81   // MMIO device.
     82   //
     83   CONST VOID *DriverResources;
     84 
     85   //
     86   // Number of protocols in the array
     87   //
     88   UINTN ProtocolCount;
     89 
     90   //
     91   // List of protocols to define
     92   //
     93   CONST EFI_MMIO_DEVICE_PROTOCOL_ITEM *ProtocolArray;
     94 };
     95 
     96 extern EFI_GUID gEfiMmioDeviceProtocolGuid;
     97 
     98 #endif  //  __MMIO_DEVICE_H__
     99