What is meant by the term BUS arbitration? Why is it needed? How can bus arbitration be implemented in Daisy chaining scheme?
What is meant by the term BUS arbitration? Why is it needed? How can bus arbitration be implemented in Daisy chaining scheme?
Quick answer
Bus arbitration is the method of deciding which device may use a shared bus when more than one device requests it at the same time. The device that gets the bus is called the bus master. The unit that decides is the arbiter. The arbiter can be the CPU, or a special bus controller.
Why it is needed
A bus is a shared resource, and only one device can send data on it at a time. If two devices sent together, the signals would mix and the data would be wrong. Several devices, such as the CPU, DMA controllers and I/O processors, can all become bus masters. So a rule is needed to give the bus to one of them and to make others wait. Arbitration also gives the important devices a higher priority and stops any device from using the bus for ever.
Daisy chaining scheme
In this scheme, all the devices are connected in series. The devices share one common bus request line. The bus grant line passes from the arbiter through each device in turn, and it goes from one device to the next one.
Arbiter --grant--> [Dev 1] --grant--> [Dev 2] --grant--> [Dev 3]
^ | | |
+------ common bus request line (wired OR) -------------+
The working is as follows.
- Any device that needs the bus puts a signal on the common bus request line. The line is the OR of all requests.
- The arbiter sees the request and sends the grant signal to the first device in the chain.
- If this device did not request the bus, it passes the grant signal on to the next device.
- The first device that did request the bus keeps the grant signal and does not pass it on. It becomes the bus master and also sets a busy line, so that the others know the bus is in use.
- When the master finishes, it removes the busy signal. The arbiter then looks at the request line again.
The priority of a device depends only on its position in the chain. The device nearest to the arbiter has the highest priority, and the last one has the lowest.
Advantages and disadvantages
It is simple and needs very few wires, and a new device is easy to add at the end. But the priority is fixed by position, and a device at the end may starve if the earlier ones request often. The grant signal has to pass through every device, so the delay grows with the chain length. If one device in the chain fails, the devices after it cannot get the bus.
Short on time? The 1, 5 and 10 mark versions of this answer, flashcards and practice sets come with a program pass.
Up nextShow the multiplication process using Booth's algorithm when the following numbers are mul