https://bugzilla.tianocore.org/show_bug.cgi?id=1373 Replace BSD 2-Clause License with BSD+Patent License. This change is based on the following emails: https://lists.01.org/pipermail/edk2-devel/2019-February/036260.html https://lists.01.org/pipermail/edk2-devel/2018-October/030385.html RFCs with detailed process for the license change: V3: https://lists.01.org/pipermail/edk2-devel/2019-March/038116.html V2: https://lists.01.org/pipermail/edk2-devel/2019-March/037669.html V1: https://lists.01.org/pipermail/edk2-devel/2019-March/037500.html Contributed-under: TianoCore Contribution Agreement 1.1 Signed-off-by: Michael D Kinney <michael.d.kinney@intel.com> Reviewed-by: Hao Wu <hao.a.wu@intel.com> Reviewed-by: Jian J Wang <jian.j.wang@intel.com>
		
			
				
	
	
		
			59 lines
		
	
	
		
			2.1 KiB
		
	
	
	
		
			C
		
	
	
	
	
	
			
		
		
	
	
			59 lines
		
	
	
		
			2.1 KiB
		
	
	
	
		
			C
		
	
	
	
	
	
/** @file
 | 
						|
  Copyright (c) 2016, Linaro, Ltd. All rights reserved.<BR>
 | 
						|
 | 
						|
  SPDX-License-Identifier: BSD-2-Clause-Patent
 | 
						|
 | 
						|
**/
 | 
						|
 | 
						|
#ifndef __NON_DISCOVERABLE_DEVICE_REGISTRATION_LIB_H__
 | 
						|
#define __NON_DISCOVERABLE_DEVICE_REGISTRATION_LIB_H__
 | 
						|
 | 
						|
#include <Protocol/NonDiscoverableDevice.h>
 | 
						|
 | 
						|
typedef enum {
 | 
						|
  NonDiscoverableDeviceTypeAhci,
 | 
						|
  NonDiscoverableDeviceTypeAmba,
 | 
						|
  NonDiscoverableDeviceTypeEhci,
 | 
						|
  NonDiscoverableDeviceTypeNvme,
 | 
						|
  NonDiscoverableDeviceTypeOhci,
 | 
						|
  NonDiscoverableDeviceTypeSdhci,
 | 
						|
  NonDiscoverableDeviceTypeUfs,
 | 
						|
  NonDiscoverableDeviceTypeUhci,
 | 
						|
  NonDiscoverableDeviceTypeXhci,
 | 
						|
  NonDiscoverableDeviceTypeMax,
 | 
						|
} NON_DISCOVERABLE_DEVICE_TYPE;
 | 
						|
 | 
						|
/**
 | 
						|
  Register a non-discoverable MMIO device
 | 
						|
 | 
						|
  @param[in]      Type                The type of non-discoverable device
 | 
						|
  @param[in]      DmaType             Whether the device is DMA coherent
 | 
						|
  @param[in]      InitFunc            Initialization routine to be invoked when
 | 
						|
                                      the device is enabled
 | 
						|
  @param[in,out]  Handle              The handle onto which to install the
 | 
						|
                                      non-discoverable device protocol.
 | 
						|
                                      If Handle is NULL or *Handle is NULL, a
 | 
						|
                                      new handle will be allocated.
 | 
						|
  @param[in]      NumMmioResources    The number of UINTN base/size pairs that
 | 
						|
                                      follow, each describing an MMIO region
 | 
						|
                                      owned by the device
 | 
						|
  @param[in]  ...                     The variable argument list which contains the
 | 
						|
                                      info about MmioResources.
 | 
						|
 | 
						|
  @retval EFI_SUCCESS                 The registration succeeded.
 | 
						|
  @retval Other                       The registration failed.
 | 
						|
 | 
						|
**/
 | 
						|
EFI_STATUS
 | 
						|
EFIAPI
 | 
						|
RegisterNonDiscoverableMmioDevice (
 | 
						|
  IN      NON_DISCOVERABLE_DEVICE_TYPE      Type,
 | 
						|
  IN      NON_DISCOVERABLE_DEVICE_DMA_TYPE  DmaType,
 | 
						|
  IN      NON_DISCOVERABLE_DEVICE_INIT      InitFunc,
 | 
						|
  IN OUT  EFI_HANDLE                        *Handle OPTIONAL,
 | 
						|
  IN      UINTN                             NumMmioResources,
 | 
						|
  ...
 | 
						|
  );
 | 
						|
 | 
						|
#endif
 |