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