Example #1
0
DMPAPI(void) io_Out16(void* handle, unsigned long offset, unsigned short val) {
    IO_BASE_t* base = (handle == NULL)? &IO_defaultBase : (IO_BASE_t*)handle;

    switch (base->iotype)
    {
        case IO_USE_PORTIO:
            portio_outpw((unsigned short)(base->addr + offset), val);
            break;
        case IO_USE_MMIO:
            mmio_outpw(base, offset, val);
            break;
    }
}
Example #2
0
DMPAPI(void) io_Out16P(void* handle, unsigned long offset, unsigned short val) {
    portio_outpw((unsigned short)(((IO_BASE_t*)handle)->addr + offset), val);
}