// SPDX-License-Identifier: GPL-2.0 /****************************************************************************** * * Copyright(c) 2007 - 2011 Realtek Corporation. All rights reserved. * ******************************************************************************/ /* The purpose of rtw_io.c a. provides the API b. provides the protocol engine c. provides the software interface between caller and the hardware interface Compiler Flag Option: 1. CONFIG_SDIO_HCI: a. USE_SYNC_IRP: Only sync operations are provided. b. USE_ASYNC_IRP:Both sync/async operations are provided. [email protected] */ #include <drv_types.h> #include <rtw_debug.h> u8 rtw_read8(struct adapter *adapter, u32 addr) { … } u16 rtw_read16(struct adapter *adapter, u32 addr) { … } u32 rtw_read32(struct adapter *adapter, u32 addr) { … } int rtw_write8(struct adapter *adapter, u32 addr, u8 val) { … } int rtw_write16(struct adapter *adapter, u32 addr, u16 val) { … } int rtw_write32(struct adapter *adapter, u32 addr, u32 val) { … } u32 rtw_write_port(struct adapter *adapter, u32 addr, u32 cnt, u8 *pmem) { … } int rtw_init_io_priv(struct adapter *padapter, void (*set_intf_ops)(struct adapter *padapter, struct _io_ops *pops)) { … } /* * Increase and check if the continual_io_error of this @param dvobjprive is larger than MAX_CONTINUAL_IO_ERR * @return true: * @return false: */ int rtw_inc_and_chk_continual_io_error(struct dvobj_priv *dvobj) { … } /* * Set the continual_io_error of this @param dvobjprive to 0 */ void rtw_reset_continual_io_error(struct dvobj_priv *dvobj) { … }