OSDN Git Service

staging: rtl8723bs: update to the latest driver
[android-x86/kernel.git] / drivers / staging / rtl8723bs / include / rtw_br_ext.h
1 /******************************************************************************
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  *
14  ******************************************************************************/
15 #ifndef _RTW_BR_EXT_H_
16 #define _RTW_BR_EXT_H_
17
18 #define MACADDRLEN              6
19 #define _DEBUG_ERR              DBG_8192C
20 #define _DEBUG_INFO             /* DBG_8192C */
21 #define DEBUG_WARN              DBG_8192C
22 #define DEBUG_INFO              /* DBG_8192C */
23 #define DEBUG_ERR               DBG_8192C
24 /* define GET_MY_HWADDR         ((GET_MIB(priv))->dot11OperationEntry.hwaddr) */
25 #define GET_MY_HWADDR(padapter)         ((padapter)->eeprompriv.mac_addr)
26
27 #define NAT25_HASH_BITS         4
28 #define NAT25_HASH_SIZE         (1 << NAT25_HASH_BITS)
29 #define NAT25_AGEING_TIME       300
30
31 #define MAX_NETWORK_ADDR_LEN    17
32
33 struct nat25_network_db_entry
34 {
35         struct nat25_network_db_entry   *next_hash;
36         struct nat25_network_db_entry   **pprev_hash;
37         atomic_t                                                use_count;
38         unsigned char                           macAddr[6];
39         unsigned long                                   ageing_timer;
40         unsigned char                           networkAddr[MAX_NETWORK_ADDR_LEN];
41 };
42
43 enum NAT25_METHOD {
44         NAT25_MIN,
45         NAT25_CHECK,
46         NAT25_INSERT,
47         NAT25_LOOKUP,
48         NAT25_PARSE,
49         NAT25_MAX
50 };
51
52 struct br_ext_info {
53         unsigned int    nat25_disable;
54         unsigned int    macclone_enable;
55         unsigned int    dhcp_bcst_disable;
56         int             addPPPoETag;            /*  1: Add PPPoE relay-SID, 0: disable */
57         unsigned char nat25_dmzMac[MACADDRLEN];
58         unsigned int    nat25sc_disable;
59 };
60
61 void nat25_db_cleanup(struct adapter *priv);
62
63 #endif /*  _RTW_BR_EXT_H_ */