26.07.2013 Views

I/O Devices and disk scheduling - Csbdu.in

I/O Devices and disk scheduling - Csbdu.in

I/O Devices and disk scheduling - Csbdu.in

SHOW MORE
SHOW LESS

You also want an ePaper? Increase the reach of your titles

YUMPU automatically turns print PDFs into web optimized ePapers that Google loves.

when the processor does not need it, or it must force the processor to suspend operation<br />

temporarily. The latter technique is more common <strong>and</strong> is referred to as cycle steal<strong>in</strong>g,<br />

because the DMA unit <strong>in</strong> effect steals a bus cycle.<br />

Data count<br />

Data Register<br />

Address<br />

Register<br />

Control Logic<br />

The DMA technique works as follows.<br />

Figure 4.4 DMA Controller<br />

Data l<strong>in</strong>es<br />

Address l<strong>in</strong>es<br />

DMA request<br />

DMA acknowledge<br />

Interrupt<br />

rEAD Read<br />

Write<br />

• Whether a read or write is requested, us<strong>in</strong>g read or write control l<strong>in</strong>e between the<br />

processor <strong>and</strong> the DMA module<br />

• The address of the I/O device <strong>in</strong>volved, communicated on the data l<strong>in</strong>es<br />

• The start<strong>in</strong>g location <strong>in</strong> memory to read from or write to, communicated on the<br />

data l<strong>in</strong>es <strong>and</strong> stored by the DMA module <strong>in</strong> its address register<br />

• The number of words to be read or written, aga<strong>in</strong> communicated via the data l<strong>in</strong>es<br />

<strong>and</strong> stored <strong>in</strong> the data count register<br />

The Processor then cont<strong>in</strong>ues with other work. It has assigned this I/O operation<br />

to DMA module. The DMA module transfers the entire block of data, one word at a<br />

time, directly to or from memory, without go<strong>in</strong>g through the processor. When the

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!