
136
SAM9G45 [DATASHEET]
6438K–ATARM–12-Feb-13
19.5.2
Arbitration Priority Scheme
The bus Matrix arbitration scheme is organized in priority pools.
Round-Robin priority is used inside the highest and lowest priority pools, whereas fix level priority is used between
priority pools and inside the intermediate priority pools.
For each slave, each master x is assigned to one of the slave priority pools through the Priority Registers for
Slaves (MxPR fields of MATRIX_PRAS and MATRIX_PRBS). When evaluating masters requests, this pro-
grammed priority level always takes precedence.
After reset, all the masters are belonging to the lowest priority pool (MxPR = 0) and so are granted bus access in a
true Round-Robin fashion.
The highest priority pool must be specifically reserved for masters requiring very low access latency. If more than
one master belong to this pool, these will be granted bus access in a biased Round-Robin fashion which allow tight
and deterministic maximum access latency from AHB bus request. In fact, at worst, any currently high priority mas-
ter request will be granted after the current bus master access is ended and the other high priority pool masters, if
any, have been granted once each.
The lowest priority pool shares the remaining bus bandwidth between AHB Masters.
Intermediate priority pools allow fine priority tuning. Typically, a moderately latency critical master or a bandwidth
only critical master will use such a priority level. The higher the priority level (MxPR value), the higher the master
priority.
All combination of MxPR values are allowed for all masters and slaves. For example some masters might be
assigned to the highest priority pool (round-robin) and the remaining masters to the lowest priority pool (round-
robin), with no master for intermediate fix priority levels.
If more than one master is requesting the slave bus, whatever are the respective masters priorities, no master will
be granted the slave bus for two consecutive runs. A master can only get back to back grants as long as it is the
only requesting master.
19.5.2.1
Fixed Priority Arbitration
This arbitration algorithm is the first and only applied between masters from distinct priority pools. It is also used
inside priority pools other than the highest and lowest ones (intermediate priority pools).
It allows the Bus Matrix arbiters to dispatch the requests from different masters to the same slave by using the fixed
priority defined by the user in the MxPR field for each master inside the MATRIX_PRAS and MATRIX_PRBS Prior-
ity Registers. If two or more master requests are active at the same time, the master with the highest priority
number MxPR is serviced first.
Inside intermediate priority pools, if two or more master requests with the same priority are active at the same time,
the master with the highest number is serviced first.
19.5.2.2
Round-Robin Arbitration
This algorithm is only used inside the highest and lowest priority pools. It allows the Bus Matrix arbiters to dispatch
the requests from different masters to the same slave in a fair way. If two or more master requests are active at the
same time inside the priority pool, they are serviced in a round-robin increasing master number order.