Apple Developer Connection
Advanced Search
Member Login Log In | Not a Member? Contact ADC
ADC Home > Reference Library > Reference > Hardware & Drivers > I/O Kit Framework Reference

 


IOFireWireLib.h

Includes:
<CoreFoundation/CoreFoundation.h>
<IOKit/IOCFPlugIn.h>
<IOKit/firewire/IOFireWireFamilyCommon.h>

Overview

IOFireWireLib is the software used by user space software to communicate with FireWire devices and control the FireWire bus. IOFireWireLib is the lowest-level FireWire interface available in user space.

To communicate with a device on the FireWire bus, an instance of IOFireWireDeviceInterface (a struct which is defined below) is created. The methods of IOFireWireDeviceInterface allow you to communicate with the device and create instances of other interfaces which provide extended functionality (for example, creation of unit directories on the local machine).

References to interfaces should be kept using the interface reference typedefs defined herein. For example, you should use IOFireWireLibDeviceRef to refer to instances of IOFireWireDeviceInterface, IOFireWireLibCommandRef to refer to instances of IOFireWireCommandInterface, and so on.

To obtain an IOFireWireDeviceInterface for a device on the FireWire bus, use the function IOCreatePlugInInterfaceForService() defined in IOKit/IOCFPlugIn.h. (Note the "i" in "PlugIn" is always upper-case.) Quick usage reference:

The interface returned by IOCreatePlugInInterfaceForService() should be deallocated using IODestroyPlugInInterface(). Do not call Release() on it.



COM Interfaces

IOFireWireCommandInterface
IOFireWireLib command object.
IOFireWireCompareSwapCommandInterface
IOFireWireConfigDirectoryInterface
IOFireWireLib device config ROM browsing interface.
IOFireWireDeviceInterface
IOFireWireDeviceInterface is your primary gateway to the functionality contained in IOFireWireLib.
IOFireWireLocalUnitDirectoryInterface
IOFireWireNubInterface
IOFireWireDeviceInterface is your primary gateway to the functionality contained in IOFireWireLib.
IOFireWirePhysicalAddressSpaceInterface
IOFireWireLib physical address space object.
IOFireWirePseudoAddressSpaceInterface
IOFireWireReadCommandInterface
IOFireWireLib block read command object.
IOFireWireUnitInterface
IOFireWireDeviceInterface is your primary gateway to the functionality contained in IOFireWireLib.
IOFireWireWriteCommandInterface
IOFireWireLib block read command object.


Functions

AddCommand
Adds a command to the vector command.
allocateIsochResources
Use this interface to allocate isochronous resources
areIsochResourcesAllocated
Poll to see if IRM resources are still allocated
ClientCommandIsComplete
Notify the PHY packet listener object that a packet notification handler has completed.
deallocateIsochResources
Deallocate previously allocated resources
DidLock
Was the last lock operation successful?
EnsureCapacity
Sets the number of commands this vector can hold.
GetCommandAtIndex
Returns the command at a given index.
GetCommandCount
Returns the number of commands currently in this vector.
GetFlags(IOFireWireLibPHYPacketListenerRef)
get the flags of listener.
GetFlags(IOFireWireLibVectorCommandRef)
Get the flags currently set for this command.
GetIndexOfCommand
Returns the index of the specified command.
GetRefCon
Returns the user refCon value for thisinterface.
GetRefCon(IOFireWireLibIRMAllocationRef)
Get the current refcon
GetRefCon(IOFireWireLibVectorCommandRef)
Get the reference constant for this command.
InsertCommandAtIndex
Inserts a command at a given index. Commands at and after this index will be moved to their next sequential index.
IsExecuting
Checks if the vector command is currently executing.
Locked
Get the 32-bit value returned on the last compare swap operation.
Locked64
Get the 64-bit value returned on the last compare swap operation.
NotificationIsOn(IOFireWireLibIRMAllocationRef)
Is notification on?
NotificationIsOn(IOFireWireLibPHYPacketListenerRef)
Is notification on?
RemoveAllCommands
Removes all commands from the vector.
RemoveCommand
Removes a command to the vector command.
RemoveCommandAtIndex
Removes the command at a give index. Commands at and afte this index will be moved to their previous sequential index.
SetCallback
Set the callback routine for this command.
SetDataQuads
Set the 2 quadlets of data to be sent in a PHY packet.
SetFlags(IOFireWireLibPHYPacketListenerRef, UInt32)
set flags for the listener.
SetFlags(IOFireWireLibVectorCommandRef, UInt32)
Set flags governing this command's execution.
SetListenerCallback
Set the callback that should be called to handle incoming phy packets
SetQuads
Set destination for read data
SetRefCon(IOFireWireLibIRMAllocationRef, void *)
Set a new refcon
SetRefCon(IOFireWireLibPHYPacketListenerRef, void *)
Sets the user refCon value for this interface.
SetRefCon(IOFireWireLibVectorCommandRef, UInt32)
Set flags governing this command's execution.
SetRefCon(IOFireWireLibVectorCommandRef, void *)
Set the reference constant for this command.
setReleaseIRMResourcesOnFree
Set a new value for releaseIRMResourcesOnFree
SetSkippedPacketCallback
Set the callback that should be called when incoming phy packets are dropped by the listener space.
SetValues
Set values for 32-bit compare swap operation. Calling this function will make the command object perform 32-bit compare swap transactions on the bus. To perform 64-bit compare swap operations, use the SetValues64() call, below.
SetValues64
Set values for 64-bit compare swap operation. Calling this function will make the command object perform 64-bit compare swap transactions on the bus. To perform 32-bit compare swap operations, use the SetValues() call, above.
Submit(IOFireWireLibVectorCommandRef)
Submit this command object to FireWire for execution.
Submit(IOFireWireLibVectorCommandRef, void *, IOFireWireLibCommandCallback)
Submit this command object to FireWire for execution.
SubmitWithRefconAndCallback
Submit this command object to FireWire for execution.
TurnOffNotification(IOFireWireLibIRMAllocationRef)
Force notification off.
TurnOffNotification(IOFireWireLibPHYPacketListenerRef)
Turn packet notification off.
TurnOnNotification(IOFireWireLibIRMAllocationRef)
Try to turn on notifications
TurnOnNotification(IOFireWireLibPHYPacketListenerRef)
Try to turn on packet notifications for this listener.

AddCommand


Adds a command to the vector command.

void ( *AddCommand)(
    IOFireWireLibVectorCommandRef self,
    IOFireWireLibCommandRef command);  
Parameters
self
A reference to the vector command object
command
A reference to the command to add
Return Value

An IOReturn result code


allocateIsochResources


Use this interface to allocate isochronous resources

IOReturn ( *allocateIsochResources)(
    IOFireWireLibIRMAllocationRef self,
    UInt8 isochChannel,
    UInt32 bandwidthUnits);  
Parameters
self
The IRMAllocation interface to use.
isochChannel
The isoch channel to allocate.
bandwidthUnits
The bandwidth units to allocate.
Return Value

Returns true if allocation success


areIsochResourcesAllocated


Poll to see if IRM resources are still allocated

Boolean ( *areIsochResourcesAllocated)(
    IOFireWireLibIRMAllocationRef self,
    UInt8 *pAllocatedIsochChannel,
    UInt32 *pAllocatedBandwidthUnits);  
Parameters
self
The IRMAllocation interface to use.
pAllocatedIsochChannel
If allocated, the channel
pAllocatedBandwidthUnits
If allocated, the amount of bandwidth
Return Value

Returns true if currently allocated, false otherwise


ClientCommandIsComplete


Notify the PHY packet listener object that a packet notification handler has completed.

void ( *ClientCommandIsComplete)(
    IOFireWireLibPHYPacketListenerRef self,
    FWClientCommandID commandID );  
Parameters
self
The PHY packet listener object.
commandID
The ID of the packet notification being completed. This is the same ID that was passed when a packet notification handler is called.
Discussion

Packet notifications are received one at a time, in order. This function must be called after a packet handler has completed its work.


deallocateIsochResources


Deallocate previously allocated resources

IOReturn ( *deallocateIsochResources)(
    IOFireWireLibIRMAllocationRef self);  
Parameters
self
The IRMAllocation interface to use.
Return Value

Returns true if deallocation success


DidLock


Was the last lock operation successful?

Boolean ( *DidLock)(
    IOFireWireLibCompareSwapCommandRef self);  
Parameters
self
The command object interface of interest
Return Value

Returns true if the last lock operation performed by this command object was successful, false otherwise.

Discussion

Available in v2 and newer.


EnsureCapacity


Sets the number of commands this vector can hold.

IOReturn ( *EnsureCapacity)(
    IOFireWireLibVectorCommandRef self,
    UInt32 capacity);  
Parameters
self
A reference to the vector command object
capacity
The number of commands this vector command should expect to hold
Return Value

An IOReturn result code

Discussion

The vector can grow dynamically, but for performance reasons developers may want the storage preallocated for a certain number of commmands


GetCommandAtIndex


Returns the command at a given index.

IOFireWireLibCommandRef ( *GetCommandAtIndex)(
    IOFireWireLibVectorCommandRef self,
    UInt32 index);  
Parameters
self
A reference to the vector command object
index
The index to return a command from
Return Value

The IOFireWireLibCommandRef at the specified index on return

Discussion

Returns kIOReturnBadArgument if the index is out of bounds.


GetCommandCount


Returns the number of commands currently in this vector.

UInt32 ( *GetCommandCount)(
    IOFireWireLibVectorCommandRef self);  
Parameters
self
A reference to the vector command object
Return Value

UInt32 The number of commands in this vector


GetFlags(IOFireWireLibPHYPacketListenerRef)


get the flags of listener.

UInt32 ( *GetFlags)(
    IOFireWireLibPHYPacketListenerRef self );  
Parameters
self
The PHY packet listener object.
Return Value

flags No current flags are defined.


GetFlags(IOFireWireLibVectorCommandRef)


Get the flags currently set for this command.

UInt32 ( *GetFlags)(
    IOFireWireLibVectorCommandRef self);  
Parameters
self
A reference to the vector command object
Return Value

The flags set in SetFlags


GetIndexOfCommand


Returns the index of the specified command.

UInt32 ( *GetIndexOfCommand)(
    IOFireWireLibVectorCommandRef self,
    IOFireWireLibCommandRef command);  
Parameters
self
A reference to the vector command object
command
The command in question
Return Value

The index of the specified command

Discussion

Returns kIOReturnNotFound if the command does not exist in this vector.


GetRefCon


Returns the user refCon value for thisinterface.

void* ( *GetRefCon)(
    IOFireWireLibPHYPacketListenerRef self );  
Parameters
self
The PHY packet listener object.
Return Value

returns the refcon


GetRefCon(IOFireWireLibIRMAllocationRef)


Get the current refcon

void* ( *GetRefCon)(
    IOFireWireLibIRMAllocationRef self);  
Parameters
self
The IRMAllocation interface to use.
Return Value

Returns the current refcon value


GetRefCon(IOFireWireLibVectorCommandRef)


Get the reference constant for this command.

void * ( *GetRefCon)(
    IOFireWireLibVectorCommandRef self);  
Parameters
self
A reference to the vector command object
Return Value

The reference contant set in SetRefCon


InsertCommandAtIndex


Inserts a command at a given index. Commands at and after this index will be moved to their next sequential index.

void ( *InsertCommandAtIndex)(
    IOFireWireLibVectorCommandRef self,
    IOFireWireLibCommandRef command,
    UInt32 index);  
Parameters
self
A reference to the vector command object
command
A reference to the command to be inserted
index
The index to insert the command at.


IsExecuting


Checks if the vector command is currently executing.

Boolean ( *IsExecuting)(
    IOFireWireLibVectorCommandRef self);  
Parameters
self
A reference to the vector command object
Return Value

True if the command is executing, false otherwise


Locked


Get the 32-bit value returned on the last compare swap operation.

IOReturn ( *Locked)(
    IOFireWireLibCompareSwapCommandRef self,
    UInt32 *oldValue);  
Parameters
self
The command object interface of interest
oldValue
A pointer to contain the value returned by the target of this command on the last compare swap operation
Return Value

Returns kIOReturnBadArgument if the last compare swap operation performed was 64-bit.

Discussion

Available in v2 and newer.


Locked64


Get the 64-bit value returned on the last compare swap operation.

IOReturn ( *Locked64)(
    IOFireWireLibCompareSwapCommandRef self,
    UInt64 *oldValue);  
Parameters
self
The command object interface of interest
oldValue
A pointer to contain the value returned by the target of this command on the last compare swap operation
Return Value

Returns kIOReturnBadArgument if the last compare swap performed was 32-bit.

Discussion

Available in v2 and newer.


NotificationIsOn(IOFireWireLibIRMAllocationRef)


Is notification on?

Boolean ( *NotificationIsOn)(
    IOFireWireLibIRMAllocationRef self);  
Parameters
self
The IRMAllocation interface to use.
Return Value

Returns true if notifications for this IRMAllocation are enabled


NotificationIsOn(IOFireWireLibPHYPacketListenerRef)


Is notification on?

Boolean ( *NotificationIsOn)(
    IOFireWireLibPHYPacketListenerRef self );  
Parameters
self
The PHY packet listener object.
Return Value

Returns true if packet notifications for this listener are active


RemoveAllCommands


Removes all commands from the vector.

void ( *RemoveAllCommands)(
    IOFireWireLibVectorCommandRef self);  
Parameters
self
A reference to the vector command object


RemoveCommand


Removes a command to the vector command.

void ( *RemoveCommand)(
    IOFireWireLibVectorCommandRef self,
    IOFireWireLibCommandRef command);  
Parameters
self
A reference to the vector command object
command
A reference to the command to be removed
Return Value

An IOReturn result code


RemoveCommandAtIndex


Removes the command at a give index. Commands at and afte this index will be moved to their previous sequential index.

void ( *RemoveCommandAtIndex)(
    IOFireWireLibVectorCommandRef self,
    UInt32 index);  
Parameters
self
A reference to the vector command object
command
The command in question
outIndex
Will be set to the index of the specified command.
Discussion

Returns kIOReturnBadArgument if the index is out of bounds.


SetCallback


Set the callback routine for this command.

void ( *SetCallback)(
    IOFireWireLibVectorCommandRef self,
    IOFireWireLibCommandCallback inCallback);  
Parameters
self
A reference to the vector command object
inCallback
A callback function to be called upon command completion.
Return Value

void


SetDataQuads


Set the 2 quadlets of data to be sent in a PHY packet.

void ( *SetDataQuads)(
    IOFireWireLibPHYCommandRef self,
    UInt32 data1,
    UInt32 data2 );  
Parameters
self
The command object interface of interest
data1
The value of the first quad of the phy packet
data2
The value of the second quad of the phy packet
Discussion

Available in v1 and newer.


SetFlags(IOFireWireLibPHYPacketListenerRef, UInt32)


set flags for the listener.

void ( *SetFlags)(
    IOFireWireLibPHYPacketListenerRef self,
    UInt32 flags );  
Parameters
self
The PHY packet listener object.
flags
No current flags are defined.


SetFlags(IOFireWireLibVectorCommandRef, UInt32)


Set flags governing this command's execution.

See Also:
SetRefCon
void ( *SetFlags)(
    IOFireWireLibVectorCommandRef self,
    UInt32 inFlags);  
Parameters
self
A reference to the vector command object
inFlags
A UInt32 with bits set corresponding to the flags that should be set for this command object. The following values may be used:


SetListenerCallback


Set the callback that should be called to handle incoming phy packets

void ( *SetListenerCallback)(
    IOFireWireLibPHYPacketListenerRef self,
    IOFireWireLibPHYPacketCallback inCallback );  
Parameters
self
The PHY packet listener object.
inCallback
The callback to set.


SetQuads


Set destination for read data

void ( *SetQuads)(
    IOFireWireLibReadQuadletCommandRef self,
    UInt32 inQuads[],
    UInt32 inNumQuads);  
Parameters
self
The command object interface of interest
inQuads
An array of quadlets
inNumQuads
Number of quadlet in 'inQuads'


SetRefCon(IOFireWireLibIRMAllocationRef, void *)


Set a new refcon

void ( *SetRefCon)(
    IOFireWireLibIRMAllocationRef self,
    void *refCon);  
Parameters
self
The IRMAllocation interface to use.
refCon
The new refcon value.


SetRefCon(IOFireWireLibPHYPacketListenerRef, void *)


Sets the user refCon value for this interface.

void ( *SetRefCon)(
    IOFireWireLibPHYPacketListenerRef self,
    void *refcon );  
Parameters
self
The PHY packet listener object.
refcon
the refcon


SetRefCon(IOFireWireLibVectorCommandRef, UInt32)


Set flags governing this command's execution.

See Also:
SetFlags
void ( *SetFlags)(
    IOFireWireLibVectorCommandRef self,
    UInt32 inFlags);  
Parameters
self
A reference to the vector command object
inFlags
A UInt32 with bits set corresponding to the flags that should be set for this command object. The following values may be used:
Return Value

void


SetRefCon(IOFireWireLibVectorCommandRef, void *)


Set the reference constant for this command.

void ( *SetRefCon)(
    IOFireWireLibVectorCommandRef self,
    void *refCon);  
Parameters
self
A reference to the vector command object
refCon
A reference constant for 3rd party use.
Return Value

void


setReleaseIRMResourcesOnFree


Set a new value for releaseIRMResourcesOnFree

const void ( *setReleaseIRMResourcesOnFree)(
    IOFireWireLibIRMAllocationRef self,
    Boolean doRelease);  
Parameters
self
The IRMAllocation interface to use.
doRelease
The new value for releaseIRMResourcesOnFree.


SetSkippedPacketCallback


Set the callback that should be called when incoming phy packets are dropped by the listener space.

void ( *SetSkippedPacketCallback)(
    IOFireWireLibPHYPacketListenerRef self,
    IOFireWireLibPHYPacketSkippedCallback inCallback );  
Parameters
self
The PHY packet listener object.
inCallback
The callback to set.


SetValues


Set values for 32-bit compare swap operation. Calling this function will make the command object perform 32-bit compare swap transactions on the bus. To perform 64-bit compare swap operations, use the SetValues64() call, below.

void ( *SetValues)(
    IOFireWireLibCompareSwapCommandRef self,
    UInt32 cmpVal,
    UInt32 newVal);  
Parameters
self
The command object interface of interest
cmpVal
The value expected at the address targeted by this command object
newVal
The value to be written at the address targeted by this command object
Discussion

Available in v2 and newer.


SetValues64


Set values for 64-bit compare swap operation. Calling this function will make the command object perform 64-bit compare swap transactions on the bus. To perform 32-bit compare swap operations, use the SetValues() call, above.

void ( *SetValues64)(
    IOFireWireLibCompareSwapCommandRef self,
    UInt64 cmpVal,
    UInt64 newVal);  
Parameters
self
The command object interface of interest
cmpVal
The value expected at the address targeted by this command object
newVal
The value to be written at the address targeted by this command object
Discussion

Available in v2 and newer.


Submit(IOFireWireLibVectorCommandRef)


Submit this command object to FireWire for execution.

IOReturn ( *Submit)(
    IOFireWireLibVectorCommandRef self);  
Parameters
self
A reference to the vector command object
Return Value

An IOReturn result code


Submit(IOFireWireLibVectorCommandRef, void *, IOFireWireLibCommandCallback)


Submit this command object to FireWire for execution.

See Also:
SubmitWithRefconAndCallback
IOReturn ( *SubmitWithRefconAndCallback)(
    IOFireWireLibVectorCommandRef self,
    void *refCon,
    IOFireWireLibCommandCallback inCallback);  
Parameters
self
A reference to the vector command object
refCon
A reference constant for 3rd party use. This is the same refcon set with SetRefCon and retreived with GetRefCon.
inCallback
A callback function to be called upon command completion.
Return Value

An IOReturn result code

Discussion

A convienence method to set the callback and refcon and then submit.


SubmitWithRefconAndCallback


Submit this command object to FireWire for execution.

See Also:
Submit
IOReturn ( *SubmitWithRefconAndCallback)(
    IOFireWireLibVectorCommandRef self,
    void *refCon,
    IOFireWireLibCommandCallback inCallback);  
Parameters
self
A reference to the vector command object
refCon
A reference constant for 3rd party use. This is the same refcon set with SetRefCon and retreived with GetRefCon.
inCallback
A callback function to be called upon command completion.
Discussion

A convienence method to set the callback and refcon and then submit.


TurnOffNotification(IOFireWireLibIRMAllocationRef)


Force notification off.

void ( *TurnOffNotification)(
    IOFireWireLibIRMAllocationRef self);  
Parameters
self
The IRMAllocation interface to use.


TurnOffNotification(IOFireWireLibPHYPacketListenerRef)


Turn packet notification off.

void ( *TurnOffNotification)(
    IOFireWireLibPHYPacketListenerRef self );  
Parameters
self
The PHY packet listener object.


TurnOnNotification(IOFireWireLibIRMAllocationRef)


Try to turn on notifications

Boolean ( *TurnOnNotification)(
    IOFireWireLibIRMAllocationRef self);  
Parameters
self
The IRMAllocation interface to use.
Return Value

Returns true upon success


TurnOnNotification(IOFireWireLibPHYPacketListenerRef)


Try to turn on packet notifications for this listener.

IOReturn ( *TurnOnNotification)(
    IOFireWireLibPHYPacketListenerRef self );  
Parameters
self
The PHY packet listener object.
Return Value

Returns kIOReturnSuccess if successful

Typedefs


IOFireWireBusResetDoneHandler


Called when a bus reset has occured and FireWire has completed configuring the bus.

typedef void ( *IOFireWireBusResetDoneHandler)( 
    IOFireWireLibDeviceRef interface, 
    FWClientCommandID commandID );  // parameters may change 
Parameters
interface
A reference to the device on which the callback was installed.
commandID
An FWClientCommandID to be passed to ClientCommandIsComplete().


IOFireWireBusResetHandler


Called when a bus reset has occured, but before FireWire has completed configuring the bus.

typedef void ( *IOFireWireBusResetHandler)( 
    IOFireWireLibDeviceRef interface, 
    FWClientCommandID commandID );  // parameters may change 
Parameters
interface
A reference to the device on which the callback was installed.
commandID
An FWClientCommandID to be passed to ClientCommandIsComplete().


IOFireWireLibCommandCallback


Callback called when an asynchronous command has completed executing.

typedef void ( *IOFireWireLibCommandCallback)( 
    void *refCon, 
    IOReturn completionStatus);  
Parameters
refCon
A user-specified reference value set before command object was submitted.


IOFireWireLibIRMAllocationLostNotificationProc


Callback called when an IOFireWireLibIRMAllocationRef fails to reclaim IRM resources after a bus-reset

typedef void ( *IOFireWireLibIRMAllocationLostNotificationProc)(
    IOFireWireLibIRMAllocationRef irmAllocation,
    void *refCon);  


IOFireWireLibPHYPacketCallback


Callback called to handle incoming PHY packets

typedef void ( *IOFireWireLibPHYPacketCallback)( 
    IOFireWireLibPHYPacketListenerRef listener, 
    FWClientCommandID commandID, 
    UInt32 data1, 
    UInt32 data2, 
    void *refCon );  
Parameters
listener
The listener which received the callback
commandID
An FWClientCommandID to be passed to ClientCommandIsComplete()
data1
first quad of received PHY packet
data2
second quad of received PHY packet
refCon
user specified reference value specified on the listener


IOFireWireLibPHYPacketSkippedCallback


Callback called when incoming packets have been dropped from the internal queue

typedef void ( *IOFireWireLibPHYPacketSkippedCallback)( 
    IOFireWireLibPHYPacketListenerRef listener, 
    FWClientCommandID commandID, 
    UInt32 skippedPacketCount, 
    void *refCon );  
Parameters
listener
The listener which dropped the packets
commandID
An FWClientCommandID to be passed to ClientCommandIsComplete()
skippedPacketCount
The number of skipped packets
refCon
user specified reference value specified on the listener


IOFireWirePseudoAddressSpaceReadHandler


Handles read requests to pseudo address spaces.

typedef UInt32 ( *IOFireWirePseudoAddressSpaceReadHandler)( 
    IOFireWireLibPseudoAddressSpaceRef addressSpace, 
    FWClientCommandID commandID, 
    UInt32 packetLen, 
    UInt32 packetOffset, 
    UInt16 srcNodeID, // nodeID of requester 
    UInt32 destAddressHi, // destination on this node 
    UInt32 destAddressLo, 
    void *refCon);  
Parameters
addressSpace
The address space to which the request is being made.
commandID
An FWClientCommandID which should be passed to ClientCommandIsComplete when the buffer has been filled in.
packetLen
Number of bytes requested.
packetOffset
Number of bytes from beginning of address space backing store.
srcNodeID
NodeID of the requester.
destAddressHi
High 16 bits of destination address on this computer.
destAddressLo
Low 32 bits of destination address on this computer.
refCon
User-specified reference number passed in when the address space was created.
Discussion

This callback is called to handle read requests to pseudo address spaces. This function should fill in the specified area in the pseudo address space backing store and call ClientCommandIsComplete with the specified command ID.


IOFireWirePseudoAddressSpaceSkippedPacketHandler


Callback called when incoming packets have been dropped from the internal queue.

typedef void ( *IOFireWirePseudoAddressSpaceSkippedPacketHandler)( 
    IOFireWireLibPseudoAddressSpaceRef addressSpace, 
    FWClientCommandID commandID, 
    UInt32 skippedPacketCount);  
Parameters
addressSpace
The address space which dropped the packet(s).
commandID
An FWClientCommandID to be passed to ClientCommandIsComplete().
skippedPacketCount
The number of skipped packets.


IOFireWirePseudoAddressSpaceWriteHandler


Callback called to handle write requests to a pseudo address space.

typedef UInt32 ( *IOFireWirePseudoAddressSpaceWriteHandler)( 
    IOFireWireLibPseudoAddressSpaceRef addressSpace, 
    FWClientCommandID commandID, 
    UInt32 packetLen, 
    void *packet, 
    UInt16 srcNodeID, // nodeID of sender 
    UInt32 destAddressHi, // destination on this node 
    UInt32 destAddressLo, 
    void *refCon);  
Parameters
addressSpace
The address space to which the write is being made.
commandID
An FWClientCommandID to be passed to ClientCommandIsComplete().
packetLen
Length in bytes of incoming packet.
packet
Pointer to the received data.
srcNodeID
Node ID of the sender.
destAddressHi
High 16 bits of destination address on this computer.
destAddressLo
Low 32 bits of destination address on this computer.
refCon
User-specified reference number passed in when the address space was created.


IOFWAsyncStreamListenerHandler


Callback called to handle Async Stream packets.

typedef UInt32 ( *IOFWAsyncStreamListenerHandler)( 
    IOFWAsyncStreamListenerInterfaceRef listener, 
    FWClientCommandID commandID, 
    UInt32 size, 
    void *packet, 
    void *refCon);  
Parameters
listener
The listener which received the callback
commandID
An FWClientCommandID to be passed to ClientCommandIsComplete()
packet
Pointer to the received data
refCon
user specified reference number passed in when async stream interface is created


IOFWAsyncStreamListenerSkippedPacketHandler


Callback called when incoming packets have been dropped from the internal queue

typedef void ( *IOFWAsyncStreamListenerSkippedPacketHandler)( 
    IOFWAsyncStreamListenerInterfaceRef listener, 
    FWClientCommandID commandID, 
    UInt32 skippedPacketCount);  
Parameters
listener
The listener which dropped the packets
commandID
An FWClientCommandID to be passed to ClientCommandIsComplete()
skippedPacketCount
The number of skipped packets




Did this document help you?
Yes: Tell us what works for you.

It’s good, but: Report typos, inaccuracies, and so forth.

It wasn’t helpful: Tell us what would have helped.
Last Updated: 2008-03-11