This file describes the format of the register map based on XML.
Root
----
As any XML document, the content of the file should be enclosed in a "xml" tag.
Example:
Root Element: root
------------------
The root element can either be "soc" tag if the file contains a single description,
or "root" with no properties and one or more "soc" tags as children.
Element: soc
------------
The XML can contain one or more SoC description. Each description is enclosed in
a "soc" tag. The following properties are defined:
- "name" (mandatory,string): the mnemonic of the SoC.
- "desc" (optional,string): a textual description of the SoC.
Example:
Element: soc.dev
----------------
Each SoC can contain any number of devices. Each device is enclosed in a "dev"
tag. A device is logical group of registers and doesn't have a precise meaning.
If a SoC has several copies of the same device at different addresses (SSP1, SSP2
for example), then only one copy has to be described since a device can have
several address (see soc.dev.addr section). The following properties are defined:
- "name" (mandatory,string): the mnemonic of the device.
- "long_name" (optional,string): a short description of the device.
- "desc" (optional,string): a long description of the SoC.
- "version" (optional,string): version of the register description for this device.
Example:
The address shortcut has the following standard translation:
is equivalent to:
Element: soc.dev.reg.addr
-------------------------
Each device can have one or more addresses associated with it. Each address
is enclosed in a "addr" tag. This allows to describe several register at once on
SoCs where a similar register is replicated several times.
The following properties are defined:
- "name" (mandatory,string): unique name of this instance of the register.
- "addr" (mandatory,integer): base address of this instance of the register.
Example:
Element: soc.dev.reg.formula
----------------------------
In the special case where the addresses of the register follow a pattern, an
explicit formula can be described as part of the format. There is no specific
requirement on the formula except that the register addresses be indexed by
a variable "n" which range from 0 to N-1 where N is the number of address.
The formula is not used for anything except header generation where it is
handy to have a formula rather a long list of conditionals.
The following properties are defined:
- "string" (mandatory,string): the equation describing the addresses.
Example:
Element: soc.dev.reg.field
--------------------------
Each register can be further divided into disjoints fields. Each field
is enclosed in a "field" tag. A field is defined as a contiguous set
of bits in the register. The following properties are defined:
- "name" (mandatory,string): the mnemonic of field
- "bitrange" (mandatory,string): the bit range of the field written as
"n-m" where n and m are integers giving the most (resp. least) significant
bit of the field.
Example:
Element: soc.dev.reg.field.value
--------------------------------
Each field can describe a list of named values in cases where this is appropriate.
Each value is enclosed in a "value" tag. The following properties are defined:
- "name" (mandatory,string): the mnemonic of the value.
- "value" (mandatory,integer): the associated value.
Example: