This book provides an overview of modern boot firmware, including the Unified Extensible Firmware Interface (UEFI) and its associated EFI Developer Kit II (EDKII) firmware. The authors have each made significant contributions to developments in these areas. The reader will learn to use the latest developments in UEFI on modern hardware, including open source firmware and open hardware designs. The book begins with an exploration of interfaces exposed to higher-level software and operating systems, and commences to the left of the boot timeline, describing the flow of typical systems, beginning with the machine restart event.

Software engineers working with UEFI will benefit greatly from this book, while specific sections of the book address topics relevant for a general audience: system architects, pre-operating-system application developers, operating system vendors (loader, kernel), independent hardware vendors (such as for plug-in adapters), and developers of end-user applications. As a secondary audience, project technical leaders or managers may be interested in this book to get a feel for what their engineers are doing.

The reader will find:

  • An overview of UEFI and underlying Platform Initialization (PI) specifications
  • How to create UEFI applications and drivers
  • Workflow to design the firmware solution for a modern platform
  • Advanced usages of UEFI firmware for security and manageability



Autorentext

Vincent Zimmer Engineer, WA, USA, Suresh Marisetty Systems Architect, CA, USA, Michael Rothman Engineer,WA, USA



Inhalt

Acknowledgements | v

Preface | vii

Chapter 1 - Introduction | 1

Terminology | 4

Short History of EFI | 5

EFI Becomes UEFI-The UEFI Forum | 6

PIWG and USWG | 8

Platform Trust/Security | 11

Embedded Systems: The New Challenge | 12

How the Boot Process Differs between a Normal Boot and an

Optimized/Embedded Boot | 13

Summary | 14

Chapter 2 - Basic UEFI Architecture | 15

Objects Managed by UEFI-based Firmware | 15

UEFI System Table | 16

Handle Database | 16

Protocols | 18

Working with Protocols | 21

Multiple Protocol Instances | 21

Tag GUID | 21

UEFI Images | 22

Applications | 25

OS Loader | 25

Drivers | 26

Events and Task Priority Levels | 27

Summary | 30

Chapter 3 - UEFI Driver Model | 31

Why a Driver Model Prior to OS Booting? | 31

Driver Initialization | 32

Host Bus Controllers | 33

Device Drivers | 35

Bus Drivers | 36

Platform Components | 38

Hot Plug Events | 38

Pseudo Code | 41

Device Driver | 41

Bus Driver that Creates All of Its Child Handles on the First Call to

Start() | 42

Bus Driver that Is Able to Create All or One of Its Child Handles on Each Call

to Start(): | 43

Additional Innovations | 47

Security | 47

Manageability | 48

Networking | 49

Summary | 52

Chapter 4 - Protocols You Should Know | 53

EFI OS Loaders | 55

Device Path and Image Information of the OS Loader | 56

Accessing Files in the Device Path of the OS Loader | 57

Finding the OS Partition | 58

Getting the Current System Configuration | 60

Getting the Current Memory Map | 61

Getting Environment Variables | 62

Transitioning to an OS Kernel | 63

Summary | 63

Chapter 5 - UEFI Runtime | 65

Isn't There Only One Kind of Memory? | 66

How Are Runtime Services Exposed? | 69

Time Services | 70

Why Abstract Time? | 70

Get Time | 70

Set Time | 71

Get Wakeup Time | 72

Set Wakeup Time | 72

Virtual Memory Services | 72

Set Virtual Address Map | 73

ConvertPointer | 73

Variable Services | 74

GetVariable | 74

GetNextVariableName | 75

SetVariable | 75

Miscellaneous Services | 77

Reset System | 78

Get Next High Monotonic Count | 79

UpdateCapsule | 79

QueryCapsuleCapabilities | 80

Summary | 80

Chapter 6 - UEFI Console Services | 81

Simple Text Input Protocol | 83

Simple Text Input Ex Protocol | 86

Simple Text Output Protocol | 87

Remote Console Support | 89

Console Splitter | 92

Network Consoles | 93

Summary | 95

Chapter 7 - Different Types of Platforms | 97

Summary | 110

Chapter 8 - DXE Basics: Core, Dispatching, and Drivers | 111

DXE Core | 112

Hand-Off Block (HOB) List | 114

DXE Architectural Protocols | 115

EFI System Table | 117

EFI Boot Services Table | 118

EFI Runtime Services Table | 119

DXE Services Table | 119

Global Coherency Domain Services | 120

GCD Memory Resources | 120

GCD I/O Resources | 122

DXE Dispatcher | 123

The a priori File | 125

Dependency Grammar | 125

DXE Drivers | 126

Boot Device Selection (BDS) Phase | 127

Console Devices | 128

Boot Devices | 129

Boot Services Terminate | 129

Summary | 130

Chapter 9 - Some Common UEFI and PI Functions | 131

Architectural Protocol Examples | 132

CPU Architectural Protocol | 133

Real Time Clock Architectural Protocol | 135

Timer Architectural Protocol | 135

Reset Architectural Protocol | 136

Boot Device Selection Architectural Protocol | 137

Variable Architectural Protocol | 138

Watchdog Timer Architectural Protocol | 138

PCI Protocols | 139

PCI Host Bridge Resour…

Titel
Beyond BIOS
Untertitel
Developing with the Unified Extensible Firmware Interface, Third Edition
EAN
9781501505690
ISBN
978-1-5015-0569-0
Format
E-Book (pdf)
Hersteller
Veröffentlichung
23.01.2017
Digitaler Kopierschutz
Wasserzeichen
Dateigrösse
40.96 MB
Anzahl Seiten
322
Jahr
2017
Untertitel
Englisch
Auflage
3rd Ed