Noob Query : About RAM Disks - Linux

This is a discussion on Noob Query : About RAM Disks - Linux ; Hi, I have been reading up about RAM Disks, but I don't seem to understand how interrupts are generated for these. I mean, considering block io(maybe I am wrong in this assumption), given a situation that the IO(writing specifically) is ...

+ Reply to Thread
Results 1 to 3 of 3

Thread: Noob Query : About RAM Disks

  1. Noob Query : About RAM Disks

    Hi,

    I have been reading up about RAM Disks, but I don't seem to understand
    how interrupts are generated for these. I mean, considering block
    io(maybe I am wrong in this assumption), given a situation that the
    IO(writing specifically) is done, how does, lets say the FS routines,
    know of that completion? Who sends them the interrupt?

    Thanks, Draw

    PS: If you think I am asking a question that has been answered in
    articles elsewhere, please give me links to those, would really
    appreciate it.


  2. Re: Noob Query : About RAM Disks


    Draw wrote:

    > I have been reading up about RAM Disks, but I don't seem to understand
    > how interrupts are generated for these.


    They aren't. You only need an interrupt when a hardware operation might
    complete or begin at an arbtirary future point in time.

    > I mean, considering block
    > io(maybe I am wrong in this assumption), given a situation that the
    > IO(writing specifically) is done, how does, lets say the FS routines,
    > know of that completion? Who sends them the interrupt?


    The writing routines know of the completion because they complete. It's
    not like a disk where the writing routines tell the disk to do the
    write and the disk finishes (or accepts) the request later. As soon as
    they finish doing the write, they're done. There's nothing to notify
    them of.

    If for some reason the write is done by another thread or "in the
    background", the code that completes the write can signal other code
    using a mechanism that has the same effect as an interrupt. But I don't
    see why this would be necessary because there's really no reason to
    wait for the write to complete.

    DS


  3. Re: Noob Query : About RAM Disks

    On 13 Oct 2006 10:23:37 -0700 Draw wrote:

    | I have been reading up about RAM Disks, but I don't seem to understand
    | how interrupts are generated for these. I mean, considering block
    | io(maybe I am wrong in this assumption), given a situation that the
    | IO(writing specifically) is done, how does, lets say the FS routines,
    | know of that completion? Who sends them the interrupt?

    RAM disk is simulated by software. The software gets called to write
    to the "disk", copies the data into the RAM location the simulated disk
    is in, then returns to the caller. When it's done, it's done.

    --
    |---------------------------------------/----------------------------------|
    | Phil Howard KA9WGN (ka9wgn.ham.org) / Do not send to the address below |
    | first name lower case at ipal.net / spamtrap-2006-10-13-1514@ipal.net |
    |------------------------------------/-------------------------------------|

+ Reply to Thread