Path: utzoo!utgpu!news-server.csri.toronto.edu!cs.utexas.edu!uunet!comp.vuw.ac.nz!windy!sramtrc From: sramtrc@windy.dsir.govt.nz Newsgroups: comp.unix.internals Subject: How do I find my buffers once I have lost them? Keywords: kernel virtual sigio Message-ID: <18747.27394289@windy.dsir.govt.nz> Date: 8 Nov 90 11:33:27 GMT Reply-To: sramtrc@albert.dsir.govt.nz Organization: DSIR, Wellington, New Zealand Lines: 19 Suppose I have a UNIX version which maps a user program into the kernel virtual space. Then accessing a user buffer by the kernel is easy since the buffer has an address in the kernel virtual space. Suppose the kernel wants to send the user buffer to a device in several transfers. This is easy because the kernel tells the device the address of the buffer, starts the transfer, and waits for an interrupt from the device. When the kernel gets the interrupt how can it find the user buffer again (assuming it has been locked into memory) to do the next transfer? The buffer may no longer be mapped into the kernel's virtual address space since at the time of the interrupt some other user process may be running. How can the kernel even find the original user process (to, say, send a SIGIO to it)? Does it have to search the process table looking for it? It can't search physical RAM looking for the buffer since the buffer may be segmented into many chunks of RAM. Thanks, Tony Cooper sramtrc@albert.dsir.govt.nz