dxd - dynax driver framework 3.0.0d222
cross platform open source driver development framework
Loading...
Searching...
No Matches
dxd::ppc Class Reference

PPC device. More...

#include <dxd_pci_ppc.h>

Inheritance diagram for dxd::ppc:
Collaboration diagram for dxd::ppc:

Public Types

enum  eumb {
  omisr = 0x030 , omimr = 0x034 , ifpqr = 0x040 , ofpqr = 0x044 ,
  odbr = 0x060 , idbr = 0x068 , itwr = 0x310
}
 embedded utility memory block More...
enum  i2o { om0i = LE32(0x01) , om1i = LE32(0x02) , odi = LE32(0x08) , opqi = LE32(0x20) }

Public Member Functions

volatile unsigned int * eumb (eumb offset)
 pointer to eumb register
template<endian endian_t>
void fill32 (unsigned int pattern, unsigned int inbound, size_t size32)
 fill ppc inbound range with 32bit pattern
os_result i2o (const unsigned int *msg, size_t size)
 i2o message send
virtual os_result ioctl (unsigned int ioctl, const void *, size_t size_in, void *out, size_t size_out, size_t &size)
 control I/O handler, reached through client::ioctl()
 operator::IOPCIDevice * () const
 IOKit IOPCIDevice* implicit cast.
template<endian endian_t>
void read32 (unsigned int *dst, unsigned int inbound, size_t size32)
 read endian corrected 32bit values from ppc
template<endian endian_t>
unsigned int read32 (unsigned int inbound)
 read the endian corrected 32bit value from ppc
template<endian endian_t>
void write32 (const unsigned int *src, unsigned int inbound, size_t size32)
 write endian corrected 32bit values to ppc
template<endian endian_t>
void write32 (unsigned int src, unsigned int inbound)
 write endian corrected 32bit value to ppc

Public Attributes

os_result status = not_initialized

Protected Member Functions

virtual clientclient_create ()
 user client factory
void conclude () override
 IOKit: Main driver finalization.
virtual os_result irq_disable ()
 IOKit: disable hardware irq handler.
virtual os_result irq_enable ()
 IOKit: enable hardware irq handler.
virtual os_result isr_odi (unsigned int dbr)
 outbound doorbell interrupt handler
virtual os_result isr_opqi (unsigned int fpqr)
 outbound messsage interrupt handler
os_result launch () override
 IOKit: Main driver entry.

Protected Attributes

resources hw
struct { 
   ::DEVICE_OBJECT *   bus 
 the device object below More...
   ::DEVICE_OBJECT *   device 
 this device's own FDO More...
   ::DEVICE_OBJECT *   pdo 
 the devnode's PDO More...
wdm

Detailed Description

PPC device.

This class provides embedded PPC PCI device driver functionality.

Member Enumeration Documentation

◆ eumb

embedded utility memory block

Register set for use in eumb function to retrieve pointer of device register.

Enumerator
omisr 

outbound message interrupt service indication register

omimr 

outbound message interrupt mask register

ifpqr 

inbound FIFO queue port register

ofpqr 

outbound FIFO queue port register

odbr 

outbound doorbell message register

idbr 

inbound doorbell message register

itwr 

inbound translation window register

◆ i2o

Enumerator
om0i 

outbound message interrupt #0 indication

om1i 

outbound message interrupt #1 indication

odi 

outbound doorbell message interrupt indication

opqi 

Member Function Documentation

◆ client_create()

virtual client * dxd::device::client_create ( )
inlineprotectedvirtualinherited

user client factory

◆ conclude()

void dxd::pci::conclude ( )
inlineoverrideprotectedvirtualinherited

IOKit: Main driver finalization.

conclude() is one of the driver-supplied routines that is called before a driver is to be removed. It is responsible for freeing all resource the driver acquired during launch().

Reimplemented from dxd::device.

Here is the call graph for this function:

◆ eumb()

volatile unsigned int * dxd::ppc::eumb ( eumb offset)
inline

pointer to eumb register

Use with eumb register set for use in eumb function to retrieve pointer of device register.

◆ fill32()

template<endian endian_t>
void dxd::ppc::fill32 ( unsigned int pattern,
unsigned int inbound,
size_t size32 )
inline

fill ppc inbound range with 32bit pattern

Fill the ppc inbound range with a 32bit pattern. Since this function needs to access the inbound translation window this call blocks.

Parameters
pattern32bit pattern to be written to inbound ppc range
inboundppc inbound range start address to be filled
size32amount of 32bit values written to inbound range
Template Parameters
endian_tindicates the endianism of the firewire device
Here is the call graph for this function:

◆ i2o()

os_result dxd::ppc::i2o ( const unsigned int * msg,
size_t size )
inline

i2o message send

Copies the message contents to PCI window and

writes inbound queue to post the message.

Here is the call graph for this function:

◆ ioctl()

virtual os_result dxd::device::ioctl ( unsigned int ioctl,
const void * ,
size_t size_in,
void * out,
size_t size_out,
size_t & size )
inlinevirtualinherited

control I/O handler, reached through client::ioctl()

Reimplemented in dxd::adapter::device.

Here is the call graph for this function:
Here is the caller graph for this function:

◆ irq_disable()

virtual os_result dxd::pci::irq_disable ( )
inlineprotectedvirtualinherited

IOKit: disable hardware irq handler.

◆ irq_enable()

virtual os_result dxd::pci::irq_enable ( )
inlineprotectedvirtualinherited

IOKit: enable hardware irq handler.

◆ isr_odi()

virtual os_result dxd::ppc::isr_odi ( unsigned int dbr)
inlineprotectedvirtual

outbound doorbell interrupt handler

Parameters
dbrdoorbell register

◆ isr_opqi()

virtual os_result dxd::ppc::isr_opqi ( unsigned int fpqr)
inlineprotectedvirtual

outbound messsage interrupt handler

Parameters
fpqrFIFO pointer queue register

◆ launch()

os_result dxd::ppc::launch ( )
inlineoverrideprotectedvirtual

IOKit: Main driver entry.

launch() is one of the dynax driver frameword-supplied routines that is called after this driver is loaded. It is responsible for initializing the driver.

Checks if there are exactly two PCI memory windows.

Reimplemented from dxd::pci.

Here is the call graph for this function:

◆ operator::IOPCIDevice *()

dxd::pci::operator::IOPCIDevice * ( ) const
inlineinherited

IOKit IOPCIDevice* implicit cast.

◆ read32() [1/2]

template<endian endian_t>
void dxd::ppc::read32 ( unsigned int * dst,
unsigned int inbound,
size_t size32 )
inline

read endian corrected 32bit values from ppc

Return the endian corrected 32bit values from ppc device. Since this function needs to access the inbound translation window this call blocks.

Parameters
dstbuffer to accept read data
inboundppc inbound address to read from
size32amount of 32bit words to read
Template Parameters
endian_tindicates the endianism of the firewire device
Here is the call graph for this function:

◆ read32() [2/2]

template<endian endian_t>
unsigned int dxd::ppc::read32 ( unsigned int inbound)
inline

read the endian corrected 32bit value from ppc

Return the endian corrected 32bit value from ppc device. Since this function needs to access the inbound translation window this call blocks.

Parameters
inboundppc inbound address to read from
Template Parameters
endian_tindicates the endianism of the firewire device
Here is the call graph for this function:

◆ write32() [1/2]

template<endian endian_t>
void dxd::ppc::write32 ( const unsigned int * src,
unsigned int inbound,
size_t size32 )
inline

write endian corrected 32bit values to ppc

Writes the endian corrected 32bit values to ppc device. Since this function needs to access the inbound translation window this call blocks.

Parameters
src32bit buffer containing data to be written to ppc
inboundppc inbound destination address
size32number of 32bit values to be written to ppc
Template Parameters
endian_tindicates the endianism of the firewire device
Here is the call graph for this function:
Here is the caller graph for this function:

◆ write32() [2/2]

template<endian endian_t>
void dxd::ppc::write32 ( unsigned int src,
unsigned int inbound )
inline

write endian corrected 32bit value to ppc

Writes the endian corrected 32bit value to ppc device. Since this function needs to access the inbound translation window this call blocks.

Parameters
src32bit value containing data to be written to ppc
inboundppc inbound destination address
Template Parameters
endian_tindicates the endianism of the firewire device
Here is the call graph for this function:

Member Data Documentation

◆ bus

::DEVICE_OBJECT* dxd::device::bus
inherited

the device object below

◆ dbr

volatile unsigned int dxd::ppc::dbr

doorbell register

◆ hw

resources dxd::pci::hw
protectedinherited

◆ pdo

::DEVICE_OBJECT* dxd::device::pdo
inherited

the devnode's PDO

◆ sr

volatile unsigned int dxd::ppc::sr

status register

◆ status

os_result dxd::device::status = not_initialized
inherited

◆ [struct]

struct { ... } dxd::device::wdm

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.