Skip to content
Commit 468ef446 authored by Nishant Sharma's avatar Nishant Sharma
Browse files

mod/noc_s3: add the support to discovery node offset



The configuration register layout for NoC S3 is laid out in a
multibranch tree format. On the top of the tree is global configuration
node which points to the domain and domains points to components nodes.
The components nodes contains subfeatures that can be used to enable
PSAM, APU, FCU and IDM.

Add the support to validate the part number of NoC S3 and find the
offset address of the configuration registers of all the nodes on the
tree and put that into a table.

For example: The discovery process will convert the following tree
                       Global CFGNI
                       /         \
                      /           \
                    VD0           VD1
                   /              /
                 PD0             PD1
                /               /
              CD0              CD1
             /  \             /
            C0  C1           C2

to the following table containing node offset.
_______________________________________________
Node Type      | Index  |      Node Id         |
---------------|--------|----------------------|
               |        |   0   |   1   |  2   |
---------------|--------|-------|-------|------|
Global CFGNI   |   0    |CFGNI0 |       |      |
Voltage Domain |   1    |VD0    |VD1    |      |
Power Domain   |   2    |PD0    |PD1    |      |
CLock Domain   |   3    |CD0    |CD1    |      |
ASNI           |   4    |C0     |C1     |C2    |
AMNI           |   5    |       |       |      |
PMU            |   6    |       |       |      |
HSNI           |   7    |       |       |      |
HMNI           |   8    |       |       |      |
PMNI           |   9    |       |       |      |

As the node id and type are predefined, the offset of the target node is
fetched in O(1) by using id and type. To get offset of the C2, the user
will access the table using node type 4 and Id 2. Table[4][2] will give
offset of C2

Signed-off-by: Nishant Sharma's avatarNishant Sharma <nishant.sharma@arm.com>
Change-Id: I221694d12a853e46df0f6c434058eaf6dfb4aa2b
parent ffd00f49
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment