RAM disk.

David M. Warme dmw9q at uvacs.cs.Virginia.EDU
Sat Oct 13 05:09:21 AEST 1990


In message <15785 at csli.Stanford.EDU>, Bill Poser asks:

> Supposing that RAM disk is a wonderful thing, I don't see why it
> requires any change to UNIX. Couldn't the RAM used for this be
> treated as a device and mapped into the filesystem in the same way
> as any other block device? I should think that it would just be a matter
> of writing an appropriate driver.

There are two major reasons this is not usually done:

- It is easier to hook up new gizmo that works through a known
  and tested interface (i.e. SCSI).

- Writing such a device driver would cripple the CPU by forcing
  it to copy data from the RAM partition into the block I/O
  buffer.  Note that disk controllers have DMA which allows the
  data transfer to be done in parallel with other useful CPU
  work, especially if you have a large cache.

If you happen to have a few spare DMA channels on the CPU board
itself, then this might not be a bad idea.  However, vendors
such as Sun, HP, etc are not known for putting spare hardware
into their system that is not already used for something.


Dave Warme,
all disclaimers made, no rights reserved, etc.



More information about the Comp.unix.internals mailing list