Coma FW-C2800 User's Guide Page 249

  • Download
  • Add to my manuals
  • Print
  • Page
    / 276
  • Table of contents
  • BOOKMARKS
  • Rated. / 5. Based on customer reviews
Page view 248
Streaming DEV Structures
7-30
7.10 Streaming DEV Structures
The DEV_Fxns structure contains pointers to internal driver functions
corresponding to generic I/O operations as shown in Example 7-19.
Example 7-19. The DEV_Fxns Structure
Device frames are structures of type DEV_Frame used by SIO and device
drivers to enqueue/dequeue stream buffers. The device
todevice and
device
fromdevice queues contain elements of this type (Example 7-20).
Example 7-20. The DEV_Frame Structure
Example 7-20 has the following parameters:
link is used by QUE_put and QUE_get to enqueue/dequeue the frame.
addr contains the address of the stream buffer.
size contains the logical size of the stream buffer. The logical size can be
less than the physical buffer size.
misc is an extra field which is reserved for use by a device.
arg is an extra field available for you to associate information with a
particular frame of data. This field should be preserved by the device.
cmd is a command code for use with mini-drivers that use the IOM model
described in the DSP/BIOS Driver Developer's Guide (SPRU616). The
command code tells the mini-driver what action to perform.
status is a field set by an IOM mini-driver before calling a callback
function.
typedef struct DEV_Fxns {
Int (*close)(DEV_Handle);
Int (*ctrl)(DEV_Handle, Uns, Arg);
Int (*idle)(DEV_Handle, Bool);
Int (*issue(DEV_Handle);
Int (*open)(DEV_Handle, String);
Bool (*ready)(DEV_Handle, SEM_Handle);
Int (*reclaim)(DEV_Handle);
} DEV_Fxns;
typedef struct DEV_Frame { /* frame object */
QUE_Elem link; /* queue link */
Ptr addr; /* buffer address */
Uns size; /* buffer size */
Arg misc; /* reserved for driver */
Arg arg; /* user argument */
Uns cmd; /* mini-driver command */
Int status; /* status of command */
} DEV_Frame;
Page view 248
1 2 ... 244 245 246 247 248 249 250 251 252 253 254 ... 275 276

Comments to this Manuals

No comments