dxd - dynax driver framework 3.0.0d222
cross platform open source driver development framework
Loading...
Searching...
No Matches
dxd::stream::umap< stream_t > Class Template Reference

stream user mapping More...

#include <dxd_stream.h>

Inheritance diagram for dxd::stream::umap< stream_t >:
Collaboration diagram for dxd::stream::umap< stream_t >:

Public Member Functions

void free ()
 DriverKit map free.
os_result initialize (::IOMemoryDescriptor *io_memory_descriptor, size_t offset=0, size_t size=0, uint64_t alignment=0, void *address=nullptr)
 DriverKit map initializer.
 operator const dx::circular * () const
 operator const::IOMemoryMap * () const
 operator dx::circular * () const
const dx::circularoperator-> () const
 operator to use mapping like pointer
 operator::IOMemoryMap * ()
template<typename reference_t>
int release (reference_t &reference)
void retain ()
size_t size () const
 DriverKit mapping size.
os_result start ()
os_result stop (bool force=false)
 umap (client &client, const dx::os_event &os_event, stream_t *&stream)
 ~umap ()

Public Attributes

dxd::abstract::eventreference
atomic< int > references {}
os_result status
 status of mapping object

Protected Attributes

dx::circular_vm
 DriverKit virtual address mapping.
::IOMemoryMap * io_memory_map
atomic< event * > next
stream_t *& stream
 auto nulling reference

Detailed Description

template<typename stream_t = stream>
class dxd::stream::umap< stream_t >

stream user mapping

Constructor & Destructor Documentation

◆ umap()

template<typename stream_t = stream>
dxd::stream::umap< stream_t >::umap ( client & client,
const dx::os_event & os_event,
stream_t *& stream )
inline

insert broadcast user event

◆ ~umap()

template<typename stream_t = stream>
dxd::stream::umap< stream_t >::~umap ( )
inline

remove broadcast user event

releases this stream reference and nulls stream pointer if it was the last reference

Member Function Documentation

◆ free()

void dxd::map< scope_t, dx::circular >::free ( )
inlineinherited

DriverKit map free.

Checks if DriverKit mapping already exists and

does not call unmap(): IOMemoryMap instances will unmap themselves upon free, ie. when the last client with a reference calls release. unmap() forces the IOMemoryMap to destroy the mapping it represents, regardless of the number of clients. releases the map object.

Here is the caller graph for this function:

◆ initialize()

os_result dxd::map< scope_t, dx::circular >::initialize ( ::IOMemoryDescriptor * io_memory_descriptor,
size_t offset = 0,
size_t size = 0,
uint64_t alignment = 0,
void * address = nullptr )
inlineinherited

DriverKit map initializer.

map<kernel> maps an IOMemoryDescriptor (typically cast of a dxd::memory or buffer class) into the DriverKit address space.

            kIOMemoryMapFixedAddress map at the address requested
            kIOMemoryMapReadOnly create a read only mapping
            kIOMemoryMapCacheModeDefault default cache mode
            kIOMemoryMapCacheModeInhibit inhibited cache mode
            kIOMemoryMapCacheModeCopyback copyback cache mode
            kIOMemoryMapCacheModeWriteThrough write through cache mode

Allows re-initialization.

Checks buffer object,

maps the buffer into the DriverKit (will fail if offset is given)

and obtains a DriverKit virtual address (apply offset here instead).

Parameters
io_memory_descriptorIOMemoryDescriptor to be mapped into the DriverKit address space
offsetoffset into memory descriptor to create mapping
sizesize of mapping

◆ operator const dx::circular *()

dxd::map< scope_t, dx::circular >::operator const dx::circular * ( ) const
inlineinherited

◆ operator const::IOMemoryMap *()

dxd::map< scope_t, dx::circular >::operator const::IOMemoryMap * ( ) const
inlineinherited

◆ operator dx::circular *()

dxd::map< scope_t, dx::circular >::operator dx::circular * ( ) const
inlineinherited

◆ operator->()

const dx::circular * dxd::map< scope_t, dx::circular >::operator-> ( ) const
inlineinherited

operator to use mapping like pointer

◆ operator::IOMemoryMap *()

dxd::map< scope_t, dx::circular >::operator::IOMemoryMap * ( )
inlineinherited

◆ release()

template<typename reference_t>
int dxd::referenced::release ( reference_t & reference)
inlineinherited

◆ retain()

void dxd::referenced::retain ( )
inlineinherited

◆ size()

size_t dxd::map< scope_t, dx::circular >::size ( ) const
inlineinherited

DriverKit mapping size.

◆ start()

template<typename stream_t = stream>
os_result dxd::stream::umap< stream_t >::start ( )
inline

◆ stop()

template<typename stream_t = stream>
os_result dxd::stream::umap< stream_t >::stop ( bool force = false)
inline
Here is the caller graph for this function:

Member Data Documentation

◆ _vm

dx::circular* dxd::map< scope_t, dx::circular >::_vm
protectedinherited

DriverKit virtual address mapping.

◆ io_memory_map

::IOMemoryMap* dxd::map< scope_t, dx::circular >::io_memory_map
protectedinherited

◆ next

atomic<event*> dxd::linked::item< event >::next
protectedinherited

◆ reference

◆ references

atomic<int> dxd::referenced::references {}
inherited

◆ status

os_result dxd::map< scope_t, dx::circular >::status
inherited

status of mapping object

◆ stream

template<typename stream_t = stream>
stream_t*& dxd::stream::umap< stream_t >::stream
protected

auto nulling reference


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

(c) copyright 2009 dynamic acoustics e.U. generated on

a closed source license may be obtained by requesting a written permission from dynamic acoustics e.U.
however - governmental use generally and military use especially is strictly prohibited though.