Changeset 2acae4d in mainline


Ignore:
Timestamp:
2013-12-30T03:19:17Z (10 years ago)
Author:
Jan Vesely <jano.vesely@…>
Branches:
lfn, master, serial, ticket/834-toolchain-update, topic/msim-upgrade, topic/simplify-dev-export
Children:
81d5f74
Parents:
f5bfd98
Message:

ohci: Use pio_* functions to access registers.

This makes io accesses traceable, among other things

File:
1 edited

Legend:

Unmodified
Added
Removed
  • uspace/drv/bus/usb/ohci/ohci_regs.h

    rf5bfd98 r2acae4d  
    3434#ifndef DRV_OHCI_OHCI_REGS_H
    3535#define DRV_OHCI_OHCI_REGS_H
     36#include <ddi.h>
    3637#include <sys/types.h>
    3738#include <byteorder.h>
    3839
    39 #define OHCI_WR(reg, val) reg = host2uint32_t_le(val)
    40 #define OHCI_RD(reg) uint32_t_le2host(reg)
    41 #define OHCI_SET(reg, val) reg |= host2uint32_t_le(val)
    42 #define OHCI_CLR(reg, val) reg &= host2uint32_t_le(~val)
    43 
     40#define OHCI_WR(reg, val) pio_write_32(&(reg), host2uint32_t_le(val))
     41#define OHCI_RD(reg) uint32_t_le2host(pio_read_32(&(reg)))
     42#define OHCI_SET(reg, val) pio_set_32(&(reg), host2uint32_t_le(val), 1)
     43#define OHCI_CLR(reg, val) pio_clear_32(&(reg), host2uint32_t_le(val), 1)
    4444
    4545#define LEGACY_REGS_OFFSET 0x100
Note: See TracChangeset for help on using the changeset viewer.