L4Re Operating System Framework
Interface and Usage Documentation
Loading...
Searching...
No Matches
L4::Io_pager Class Reference

Io_pager interface. More...

#include <pager>

+ Inheritance diagram for L4::Io_pager:
+ Collaboration diagram for L4::Io_pager:

Public Member Functions

l4_msgtag_t io_page_fault (l4_fpage_t io_pfa, l4_umword_t pc, L4::Ipc::Rcv_fpage rwin, L4::Ipc::Opt< L4::Ipc::Snd_fpage & > fp)
 IO page fault protocol message.
 

Detailed Description

Io_pager interface.

Note
This interface is IA32 specific.

This class defines the interface for handling IO page faults. IO page faults happen when a thread tries to access an IO port that it does not currently have access to.

Depending on the microkernel's implementation, IO page faults can be handled in two ways.

If the microkernel does not support IO page faults, this IO pagefault interface is not used. Instead, the microkernel sends an exception IPC to the thread's exception handler (L4::Exception), indicating a GP (exception number 13). The exception handler must consult the faulting instruction to determine the cause of the exception. This is the default in Fiasco.OC.

In contrast, if the microkernel supports IO page faults, the microkernel will generate an IO page fault message and send it to the thread's page fault handler (pager). The page fault handler can implement this interface to handle the IO page faults.

Note
A program may use this mechanism to implement a lazy IO port access scheme.
The page fault and exception handlers are set with the L4::Thread::control interface.

Definition at line 61 of file pager.

Member Function Documentation

◆ io_page_fault()

l4_msgtag_t L4::Io_pager::io_page_fault ( l4_fpage_t  io_pfa,
l4_umword_t  pc,
L4::Ipc::Rcv_fpage  rwin,
L4::Ipc::Opt< L4::Ipc::Snd_fpage & >  fp 
)

IO page fault protocol message.

Parameters
io_pfaFlex-page describing the faulting IO-port.
pcFaulting program counter.
rwinThe receive window for a flex-page mapping.
[out]fpOptional: flex-page descriptor to send to the task raising the page fault.
Returns
System call message tag; use l4_error() to check for errors.

IO-port fault messages are usually generated by the kernel and an IO-page-fault handler needs to be in place to handle such faults and generate a reply, potentially filling in fp.


The documentation for this class was generated from the following file: