Mac Developer Library

Developer

IOSubMemoryDescriptor Class Reference

Options
Deployment Target:

On This Page
Language:

IOSubMemoryDescriptor

Inheritance


Not Applicable

Conforms To


Not Applicable

Import Statement


Not Applicable

Objective-C

@import Kernel;

Availability


Available in OS X v10.0 and later.

The IOSubMemoryDescriptor object describes a memory area made up of a portion of another IOMemoryDescriptor.

The IOSubMemoryDescriptor object represents a subrange of memory, specified as a portion of another IOMemoryDescriptor.

  • Create an IOMemoryDescriptor to describe a subrange of an existing descriptor.

    Declaration

    C++

    static IOSubMemoryDescriptor * withSubRange( IOMemoryDescriptor *of, IOByteCountoffset, IOByteCountlength, IOOptionBitsoptions);

    Parameters

    of

    The parent IOMemoryDescriptor of which a subrange is to be used for the new descriptor, which will be retained by the subrange IOMemoryDescriptor.

    offset

    A byte offset into the parent memory descriptor's memory.

    length

    The length of the subrange.

    options

    kIOMemoryDirectionMask (options:direction) This nibble indicates the I/O direction to be associated with the descriptor, which may affect the operation of the prepare and complete methods on some architectures.

    Return Value

    The created IOMemoryDescriptor on success, to be released by the caller, or zero on failure.

    Discussion

    This method creates and initializes an IOMemoryDescriptor for memory consisting of a subrange of the specified memory descriptor. The parent memory descriptor is retained by the new descriptor.