NOVA User-Level Environment  Version testbox/changed-memory-timing-317-g320d8b5
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Pages
Atare Class Reference

ATARE - ACPI table IRQ routing extraction. More...

Inheritance diagram for Atare:
StaticReceiver< Atare > Device

Classes

struct  NamedRef
struct  PciRoutingEntry
 A single PCI routing entry. More...

Public Member Functions

bool receive (MessageAcpi &msg)
 Atare (DBus< MessageAcpi > &bus_acpi, unsigned debug)
- Public Member Functions inherited from StaticReceiver< Atare >
 StaticReceiver ()
- Public Member Functions inherited from Device
void debug_dump ()
 Device (const char *debug_name)

Private Member Functions

void debug_show_items ()
void debug_show_routing ()

Static Private Member Functions

static unsigned get_pkgsize_len (const unsigned char *data)
 Returns the number of bytes for this package len.
static unsigned read_pkgsize (const unsigned char *data)
 Read the pkgsize.
static bool name_seg (const unsigned char *res)
 Returns whether this is a nameseg.
static unsigned get_nameprefix_len (const unsigned char *table)
 Get the length of the nameprefix;.
static unsigned get_name_len (const unsigned char *table)
 Get the length of a name.
static void get_absname (NamedRef *parent, const unsigned char *name, int &namelen, char *res, unsigned skip=0)
 Calc an absname.
static unsigned read_data (const unsigned char *data, unsigned &length)
 Get the length of a data item and the data value.
static long get_packet4 (const unsigned char *table, long len, unsigned *x)
 Search and read a packet with 4 entries.
static void search_prt_direct (NamedRef *dev, NamedRef *ref)
 Searches for PCI routing information in some region and adds them to dev.
static void search_prt_indirect (NamedRef *head, NamedRef *dev, NamedRef *prt)
 Searches for PCI routing information by following references in the PRT method and adds them to dev.
static unsigned get_namedef_value (NamedRef *head, NamedRef *parent, const char *name)
 Return a single value of a namedef declaration.
static NamedRefsearch_ref (NamedRef *head, NamedRef *parent, const char *name, bool upstream)
 Search some reference per name, either absolute or relative to some parent.
static unsigned long long get_device_bdf (NamedRef *head, NamedRef *dev)
 Return a single bdf for a device struct by combining different device properties.
static NamedRefadd_refs (const unsigned char *table, unsigned len, NamedRef *res=0)
 Add all named refs from a table and return the list head pointer.
static void add_routing (NamedRef *head)
 Add the PCI routing information to the devices.

Private Attributes

NamedRef_head

Additional Inherited Members

- Static Public Member Functions inherited from StaticReceiver< Atare >
static bool receive_static (Device *o, M &msg)

Detailed Description

ATARE - ACPI table IRQ routing extraction.

This extends the ideas from "ATARE: ACPI Tables and Regular Expressions, Bernhard Kauer, TU Dresden technical report TUD-FI09-09, Dresden, Germany, August 2009".

State: testing Features: direct PRT, referenced PRTs, exact name resolution, Routing Entries

Constructor & Destructor Documentation

Atare::Atare ( DBus< MessageAcpi > &  bus_acpi,
unsigned  debug 
)
inline

Member Function Documentation

static NamedRef* Atare::add_refs ( const unsigned char *  table,
unsigned  len,
NamedRef res = 0 
)
inlinestaticprivate

Add all named refs from a table and return the list head pointer.

static void Atare::add_routing ( NamedRef head)
inlinestaticprivate

Add the PCI routing information to the devices.

void Atare::debug_show_items ( )
inlineprivate
void Atare::debug_show_routing ( )
inlineprivate
static void Atare::get_absname ( NamedRef parent,
const unsigned char *  name,
int &  namelen,
char *  res,
unsigned  skip = 0 
)
inlinestaticprivate

Calc an absname.

static unsigned long long Atare::get_device_bdf ( NamedRef head,
NamedRef dev 
)
inlinestaticprivate

Return a single bdf for a device struct by combining different device properties.

static unsigned Atare::get_name_len ( const unsigned char *  table)
inlinestaticprivate

Get the length of a name.

Returns 0 on failure or the length.

static unsigned Atare::get_namedef_value ( NamedRef head,
NamedRef parent,
const char *  name 
)
inlinestaticprivate

Return a single value of a namedef declaration.

static unsigned Atare::get_nameprefix_len ( const unsigned char *  table)
inlinestaticprivate

Get the length of the nameprefix;.

static long Atare::get_packet4 ( const unsigned char *  table,
long  len,
unsigned *  x 
)
inlinestaticprivate

Search and read a packet with 4 entries.

static unsigned Atare::get_pkgsize_len ( const unsigned char *  data)
inlinestaticprivate

Returns the number of bytes for this package len.

static bool Atare::name_seg ( const unsigned char *  res)
inlinestaticprivate

Returns whether this is a nameseg.

static unsigned Atare::read_data ( const unsigned char *  data,
unsigned &  length 
)
inlinestaticprivate

Get the length of a data item and the data value.

Note: We support only numbers here.

static unsigned Atare::read_pkgsize ( const unsigned char *  data)
inlinestaticprivate

Read the pkgsize.

bool Atare::receive ( MessageAcpi msg)
inline
static void Atare::search_prt_direct ( NamedRef dev,
NamedRef ref 
)
inlinestaticprivate

Searches for PCI routing information in some region and adds them to dev.

static void Atare::search_prt_indirect ( NamedRef head,
NamedRef dev,
NamedRef prt 
)
inlinestaticprivate

Searches for PCI routing information by following references in the PRT method and adds them to dev.

static NamedRef* Atare::search_ref ( NamedRef head,
NamedRef parent,
const char *  name,
bool  upstream 
)
inlinestaticprivate

Search some reference per name, either absolute or relative to some parent.

Member Data Documentation

NamedRef* Atare::_head
private

The documentation for this class was generated from the following file: