26.02.2014 Views

Getting Started with QNX Neutrino - QNX Software Systems

Getting Started with QNX Neutrino - QNX Software Systems

Getting Started with QNX Neutrino - QNX Software Systems

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.

© 2009, <strong>QNX</strong> <strong>Software</strong> <strong>Systems</strong> GmbH & Co. KG. Alphabetical listing of connect and I/O functions<br />

uint32_t<br />

};<br />

flag;<br />

typedef union {<br />

struct _io_sync i;<br />

} io_sync_t;<br />

Description: This is the entry point for a flush command. The helper function<br />

iofunc_sync() is passed the flag member from the input message, and returns one of<br />

the following values, which indicate what actions your resource manager must take:<br />

• 0 — do nothing.<br />

io_unblock() [CONNECT]<br />

io_unblock() [I/O]<br />

• O_SYNC — everything associated <strong>with</strong> the file (including the file contents,<br />

directory structures, inodes, etc.) must be present and recoverable from media.<br />

• O_DSYNC — only the data portion of the file must be present and recoverable from<br />

media.<br />

Note that this outcall will occur only if you’ve agreed to provide sync services by<br />

setting the mount structure flag.<br />

Returns: Returns the status via the helper macro _RESMGR_STATUS.<br />

int io_unblock (resmgr_context_t *ctp, io_pulse_t *msg,<br />

RESMGR_HANDLE_T *handle, void *reserved)<br />

Classification: Connect (synthesized by kernel, synthesized by library)<br />

Default handler: none<br />

Helper functions: iofunc_unblock()<br />

Client function: none — kernel action due to signal or timeout<br />

Messages: none — synthesized by library<br />

Data structure: (See I/O version of io_unblock(), next)<br />

Description: This is the connect message version of the unblock outcall, synthesized<br />

by the library as a result of a kernel pulse due to the client’s attempt to unblock during<br />

the connect message phase. See the I/O version of io_unblock() for more details.<br />

Returns: The status via the helper macro _RESMGR_STATUS.<br />

See the section in the Message Passing chapter, titled “Using the<br />

_NTO_MI_UNBLOCK_REQ” for a detailed discussion of unblocking strategies.<br />

int io_unblock (resmgr_context_t *ctp, io_pulse_t *msg,<br />

RESMGR_OCB_T *ocb)<br />

Classification: I/O (synthesized by kernel, synthesized by library)<br />

Default handler: iofunc_unblock_default()<br />

April 30, 2009 Chapter 5 • Resource Managers 249

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

Saved successfully!

Ooh no, something went wrong!