blob: 54048bc826e5ab1eb5c421800a003a192d9f91a5 [file] [log] [blame]
Larry Finger58c43402013-08-21 22:34:07 -05001/******************************************************************************
2 *
3 * Copyright(c) 2007 - 2011 Realtek Corporation. All rights reserved.
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 *
Larry Finger58c43402013-08-21 22:34:07 -050014 ******************************************************************************/
15#ifndef __RTL8188E_RECV_H__
16#define __RTL8188E_RECV_H__
17
18#define TX_RPT1_PKT_LEN 8
19
20#define RECV_BLK_SZ 512
21#define RECV_BLK_CNT 16
22#define RECV_BLK_TH RECV_BLK_CNT
23#define RECV_BULK_IN_ADDR 0x80
24#define RECV_INT_IN_ADDR 0x81
25
26#define NR_PREALLOC_RECV_SKB (8)
27
28#define NR_RECVBUFF (4)
29
30#define MAX_RECVBUF_SZ (15360) /* 15k < 16k */
31
32struct phy_stat {
33 unsigned int phydw0;
34 unsigned int phydw1;
35 unsigned int phydw2;
36 unsigned int phydw3;
37 unsigned int phydw4;
38 unsigned int phydw5;
39 unsigned int phydw6;
40 unsigned int phydw7;
41};
42
43/* Rx smooth factor */
44#define Rx_Smooth_Factor (20)
45
46enum rx_packet_type {
47 NORMAL_RX,/* Normal rx packet */
48 TX_REPORT1,/* CCX */
49 TX_REPORT2,/* TX RPT */
50 HIS_REPORT,/* USB HISR RPT */
51};
52
53#define INTERRUPT_MSG_FORMAT_LEN 60
Larry Finger58c43402013-08-21 22:34:07 -050054s32 rtl8188eu_init_recv_priv(struct adapter *padapter);
Tim Jester-Pfadtc7333c12014-01-12 00:55:43 +010055void rtl8188eu_free_recv_priv(struct adapter *padapter);
56void rtl8188eu_recv_hdl(struct adapter *padapter, struct recv_buf *precvbuf);
Larry Finger58c43402013-08-21 22:34:07 -050057void rtl8188eu_recv_tasklet(void *priv);
Larry Fingerf31cca82014-02-14 16:54:07 -060058void rtl8188e_query_rx_phy_status(struct recv_frame *fr, struct phy_stat *phy);
Tim Jester-Pfadtc7333c12014-01-12 00:55:43 +010059void rtl8188e_process_phy_info(struct adapter *padapter, void *prframe);
Larry Fingerf31cca82014-02-14 16:54:07 -060060void update_recvframe_phyinfo_88e(struct recv_frame *fra, struct phy_stat *phy);
61void update_recvframe_attrib_88e(struct recv_frame *fra,
62 struct recv_stat *stat);
Larry Finger58c43402013-08-21 22:34:07 -050063
64#endif