1/* 2 * Copyright 2007, Fran��ois Revol <revol@free.fr>. 3 * Distributed under the terms of the MIT License. 4 */ 5 6 7#include "pci_io.h" 8#include "pci_private.h" 9 10 11status_t 12pci_io_init() 13{ 14 return B_OK; 15} 16 17 18uint8 19pci_read_io_8(int mapped_io_addr) 20{ 21 return m68k_in8((vuint8*)mapped_io_addr); 22} 23 24 25void 26pci_write_io_8(int mapped_io_addr, uint8 value) 27{ 28 m68k_out8((vuint8*)mapped_io_addr, value); 29} 30 31 32uint16 33pci_read_io_16(int mapped_io_addr) 34{ 35 return m68k_in16((vuint16*)mapped_io_addr); 36} 37 38 39void 40pci_write_io_16(int mapped_io_addr, uint16 value) 41{ 42 m68k_out16((vuint16*)mapped_io_addr, value); 43} 44 45 46uint32 47pci_read_io_32(int mapped_io_addr) 48{ 49 return m68k_in32((vuint32*)mapped_io_addr); 50} 51 52 53void 54pci_write_io_32(int mapped_io_addr, uint32 value) 55{ 56 m68k_out32((vuint32*)mapped_io_addr, value); 57} 58