AHB Issues : AHB Locked Transfers

Locked Transfers are those transfers which assert HLOCK signals.
This means that the master is about to start a series of transfers which should not be interrupted.
HLOCK signal indicates to the arbiter that the arbiter is not allowed to grant the bus to any other
master till the master which is issuing 'LOCKED' transfers de-asserts its HLOCK signal
indicating end of series of 'LOCKED' transfers.
Who uses LOCKED transfers:
The ARM Cortex class processors use Locked transfers for writing to 'bit-band' region in its
memory map.
'bit-banding' is a mechanism, where the user can write to a memory word (32 bits), and the effect of it will be
writing to a single bit in the memory.
The Word address (A) is an alias of another address (B). When the user writes to the word in the bit-band
region using address (A), it results in read-modify-write operation to modify a single bit at address (B).
Obviously if there are 'N' bits that are allowed to be modified, you will need 32xN of address space.
As can be seen in the figure below: The 1MB region is aliased into 32 MB region in ARM memory map:

Now, the read-modify-write operation is protected by 'HLOCK', so that it may not be interrupted in between.
This is one use of the 'HLOCK' signal.

Its pretty obvious, that writing to a Bit-Band region, will result in 3 operations, ie. Read-Modify-Write.
It wont happen in a single clock cycle.

<-Prev                                             Next ->


KeyWords: AHB Issues, AHB Locked transfers. HLOCK, HMASTLOCK, bit-banding. Read-modify-write. bit band