TianoCore EDK2 master
Loading...
Searching...
No Matches
TlsDriver.c File Reference
#include "TlsImpl.h"

Go to the source code of this file.

Functions

VOID TlsCleanInstance (IN TLS_INSTANCE *Instance)
 
EFI_STATUS TlsCreateInstance (IN TLS_SERVICE *Service, OUT TLS_INSTANCE **Instance)
 
VOID TlsCleanService (IN TLS_SERVICE *Service)
 
EFI_STATUS TlsCreateService (IN EFI_HANDLE Image, OUT TLS_SERVICE **Service)
 
EFI_STATUS EFIAPI TlsUnload (IN EFI_HANDLE ImageHandle)
 
EFI_STATUS EFIAPI TlsDriverEntryPoint (IN EFI_HANDLE ImageHandle, IN EFI_SYSTEM_TABLE *SystemTable)
 
EFI_STATUS EFIAPI TlsServiceBindingCreateChild (IN EFI_SERVICE_BINDING_PROTOCOL *This, IN EFI_HANDLE *ChildHandle)
 
EFI_STATUS EFIAPI TlsServiceBindingDestroyChild (IN EFI_SERVICE_BINDING_PROTOCOL *This, IN EFI_HANDLE ChildHandle)
 

Variables

EFI_SERVICE_BINDING_PROTOCOL mTlsServiceBinding
 

Detailed Description

The Driver Binding and Service Binding Protocol for TlsDxe driver.

Copyright (c) 2016, Intel Corporation. All rights reserved.

SPDX-License-Identifier: BSD-2-Clause-Patent

Definition in file TlsDriver.c.

Function Documentation

◆ TlsCleanInstance()

VOID TlsCleanInstance ( IN TLS_INSTANCE Instance)

Release all the resources used by the TLS instance.

Parameters
[in]InstanceThe TLS instance data.

Definition at line 24 of file TlsDriver.c.

◆ TlsCleanService()

VOID TlsCleanService ( IN TLS_SERVICE Service)

Release all the resources used by the TLS service binding instance.

Parameters
[in]ServiceThe TLS service data.

Definition at line 84 of file TlsDriver.c.

◆ TlsCreateInstance()

EFI_STATUS TlsCreateInstance ( IN TLS_SERVICE Service,
OUT TLS_INSTANCE **  Instance 
)

Create the TLS instance and initialize it.

Parameters
[in]ServiceThe pointer to the TLS service.
[out]InstanceThe pointer to the TLS instance.
Return values
EFI_OUT_OF_RESOURCESFailed to allocate resources.
EFI_SUCCESSThe TLS instance is created.

Definition at line 48 of file TlsDriver.c.

◆ TlsCreateService()

EFI_STATUS TlsCreateService ( IN EFI_HANDLE  Image,
OUT TLS_SERVICE **  Service 
)

Create then initialize a TLS service.

Parameters
[in]ImageImageHandle of the TLS driver
[out]ServiceThe service for TLS driver
Return values
EFI_OUT_OF_RESOURCESFailed to allocate resource to create the service.
EFI_SUCCESSThe service is created for the driver.

Definition at line 108 of file TlsDriver.c.

◆ TlsDriverEntryPoint()

EFI_STATUS EFIAPI TlsDriverEntryPoint ( IN EFI_HANDLE  ImageHandle,
IN EFI_SYSTEM_TABLE SystemTable 
)

This is the declaration of an EFI image entry point. This entry point is the same for UEFI Applications, UEFI OS Loaders, and UEFI Drivers including both device drivers and bus drivers.

Parameters
ImageHandleThe firmware allocated handle for the UEFI image.
SystemTableA pointer to the EFI System Table.
Return values
EFI_SUCCESSThe operation completed successfully.
OthersAn unexpected error occurred.

Definition at line 235 of file TlsDriver.c.

◆ TlsServiceBindingCreateChild()

EFI_STATUS EFIAPI TlsServiceBindingCreateChild ( IN EFI_SERVICE_BINDING_PROTOCOL This,
IN EFI_HANDLE ChildHandle 
)

Creates a child handle and installs a protocol.

The CreateChild() function installs a protocol on ChildHandle. If ChildHandle is a pointer to NULL, then a new handle is created and returned in ChildHandle. If ChildHandle is not a pointer to NULL, then the protocol installs on the existing ChildHandle.

Parameters
[in]ThisPointer to the EFI_SERVICE_BINDING_PROTOCOL instance.
[in]ChildHandlePointer to the handle of the child to create. If it is NULL, then a new handle is created. If it is a pointer to an existing UEFI handle, then the protocol is added to the existing UEFI handle.
Return values
EFI_SUCCESSThe protocol was added to ChildHandle.
EFI_INVALID_PARAMETERChildHandle is NULL.
EFI_OUT_OF_RESOURCESThere are not enough resources available to create the child.
otherThe child handle was not created.

Definition at line 311 of file TlsDriver.c.

◆ TlsServiceBindingDestroyChild()

EFI_STATUS EFIAPI TlsServiceBindingDestroyChild ( IN EFI_SERVICE_BINDING_PROTOCOL This,
IN EFI_HANDLE  ChildHandle 
)

Destroys a child handle with a protocol installed on it.

The DestroyChild() function does the opposite of CreateChild(). It removes a protocol that was installed by CreateChild() from ChildHandle. If the removed protocol is the last protocol on ChildHandle, then ChildHandle is destroyed.

Parameters
ThisPointer to the EFI_SERVICE_BINDING_PROTOCOL instance.
ChildHandleHandle of the child to destroy.
Return values
EFI_SUCCESSThe protocol was removed from ChildHandle.
EFI_UNSUPPORTEDChildHandle does not support the protocol that is being removed.
EFI_INVALID_PARAMETERChild handle is NULL.
EFI_ACCESS_DENIEDThe protocol could not be removed from the ChildHandle because its services are being used.
otherThe child handle was not destroyed.

Definition at line 405 of file TlsDriver.c.

◆ TlsUnload()

EFI_STATUS EFIAPI TlsUnload ( IN EFI_HANDLE  ImageHandle)

Unloads an image.

Parameters
[in]ImageHandleHandle that identifies the image to be unloaded.
Return values
EFI_SUCCESSThe image has been unloaded.
EFI_INVALID_PARAMETERImageHandle is not a valid image handle.

Definition at line 152 of file TlsDriver.c.

Variable Documentation

◆ mTlsServiceBinding

EFI_SERVICE_BINDING_PROTOCOL mTlsServiceBinding
Initial value:
= {
}
EFI_STATUS EFIAPI TlsServiceBindingCreateChild(IN EFI_SERVICE_BINDING_PROTOCOL *This, IN EFI_HANDLE *ChildHandle)
Definition: TlsDriver.c:311
EFI_STATUS EFIAPI TlsServiceBindingDestroyChild(IN EFI_SERVICE_BINDING_PROTOCOL *This, IN EFI_HANDLE ChildHandle)
Definition: TlsDriver.c:405

Definition at line 12 of file TlsDriver.c.