1 /****************************************************************************** 2 * 3 * Copyright(c) 2007 - 2017 Realtek Corporation. 4 * 5 * This program is free software; you can redistribute it and/or modify it 6 * under the terms of version 2 of the GNU General Public License as 7 * published by the Free Software Foundation. 8 * 9 * This program is distributed in the hope that it will be useful, but WITHOUT 10 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or 11 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for 12 * more details. 13 * 14 *****************************************************************************/ 15 #ifndef __RTL8188F_RECV_H__ 16 #define __RTL8188F_RECV_H__ 17 18 #if defined(CONFIG_USB_HCI) 19 #ifndef MAX_RECVBUF_SZ 20 21 #ifdef CONFIG_MINIMAL_MEMORY_USAGE 22 #define MAX_RECVBUF_SZ (4000) /* about 4K */ 23 #else 24 #ifdef CONFIG_PLATFORM_HISILICON 25 #define MAX_RECVBUF_SZ (16384) /* 16k */ 26 #else 27 #define MAX_RECVBUF_SZ (32768) /* 32k */ 28 #endif 29 /* #define MAX_RECVBUF_SZ (20480) */ /* 20K */ 30 /* #define MAX_RECVBUF_SZ (10240) */ /* 10K */ 31 /* #define MAX_RECVBUF_SZ (16384) */ /* 16k - 92E RX BUF :16K */ 32 /* #define MAX_RECVBUF_SZ (8192+1024) */ /* 8K+1k */ 33 #endif 34 #endif /* !MAX_RECVBUF_SZ */ 35 #elif defined(CONFIG_PCI_HCI) 36 #define MAX_RECVBUF_SZ (4000) /* about 4K */ 37 #elif defined(CONFIG_SDIO_HCI) 38 /* minmum 4K, multiple of 8-byte is required, multiple of sdio block size is prefered */ 39 #define MAX_RECVBUF_SZ _RND(RX_DMA_BOUNDARY_8188F + 1, 8) 40 #endif /* CONFIG_SDIO_HCI */ 41 42 /* Rx smooth factor */ 43 #define Rx_Smooth_Factor (20) 44 45 #if defined(CONFIG_SDIO_HCI) || defined(CONFIG_GSPI_HCI) 46 s32 rtl8188fs_init_recv_priv(PADAPTER padapter); 47 void rtl8188fs_free_recv_priv(PADAPTER padapter); 48 s32 rtl8188fs_recv_hdl(_adapter *padapter); 49 #endif 50 51 #ifdef CONFIG_USB_HCI 52 int rtl8188fu_init_recv_priv(_adapter *padapter); 53 void rtl8188fu_free_recv_priv(_adapter *padapter); 54 void rtl8188fu_init_recvbuf(_adapter *padapter, struct recv_buf *precvbuf); 55 #endif 56 57 #ifdef CONFIG_PCI_HCI 58 s32 rtl8188fe_init_recv_priv(PADAPTER padapter); 59 void rtl8188fe_free_recv_priv(PADAPTER padapter); 60 #endif 61 62 void rtl8188f_query_rx_desc_status(union recv_frame *precvframe, u8 *pdesc); 63 64 #endif /* __RTL8188F_RECV_H__ */ 65