ebda

package
v0.13.0 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 7, 2024 License: BSD-3-Clause Imports: 4 Imported by: 24

Documentation

Overview

Package ebda looks for the Extended Bios Data Area (EBDA) pointer in /dev/mem, and provides access to the EBDA. This is useful for us to read or write to the EBDA, for example to copy the RSDP into the EBDA.

  • The address 0x40E contains the pointer to the start of the EBDA, shifted right by 4 bits
  • We take that and find the EBDA, where the first byte usually encodes the length of the the area in KiB.
  • If the pointer is not set, there may be no EBDA.

Index

Constants

View Source
const EBDAAddressOffset = 0x40E

EBDAAddressOffset is the traditional offset where the location of the EBDA is stored.

Variables

This section is empty.

Functions

func WriteEBDA

func WriteEBDA(e *EBDA, f io.ReadWriteSeeker) error

WriteEBDA assumes it's been passed in /dev/mem and searches for and writes to the EBDA.

Types

type EBDA

type EBDA struct {
	BaseOffset int64
	Length     int64
	Data       []byte
}

EBDA represents an EBDA region in memory

func ReadEBDA

func ReadEBDA(f io.ReadSeeker) (*EBDA, error)

ReadEBDA assumes it's been passed in /dev/mem and searches for and reads the EBDA.

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL