Commit | Line | Data |
---|---|---|
5e8e8b57 HS |
1 | /** |
2 | * Contains all definitions needed for the Libertas' MESH implementation. | |
3 | */ | |
4 | #ifndef _LBS_MESH_H_ | |
5 | #define _LBS_MESH_H_ | |
6 | ||
7 | ||
8 | #include <net/iw_handler.h> | |
ece1e3c6 | 9 | #include <net/lib80211.h> |
5e8e8b57 HS |
10 | |
11 | ||
12 | /* Mesh statistics */ | |
13 | struct lbs_mesh_stats { | |
14 | u32 fwd_bcast_cnt; /* Fwd: Broadcast counter */ | |
15 | u32 fwd_unicast_cnt; /* Fwd: Unicast counter */ | |
16 | u32 fwd_drop_ttl; /* Fwd: TTL zero */ | |
17 | u32 fwd_drop_rbt; /* Fwd: Recently Broadcasted */ | |
18 | u32 fwd_drop_noroute; /* Fwd: No route to Destination */ | |
19 | u32 fwd_drop_nobuf; /* Fwd: Run out of internal buffers */ | |
20 | u32 drop_blind; /* Rx: Dropped by blinding table */ | |
21 | u32 tx_failed_cnt; /* Tx: Failed transmissions */ | |
22 | }; | |
23 | ||
24 | ||
25 | struct net_device; | |
e0e42da3 HS |
26 | struct lbs_private; |
27 | ||
28 | int lbs_init_mesh(struct lbs_private *priv); | |
29 | int lbs_deinit_mesh(struct lbs_private *priv); | |
30 | ||
31 | int lbs_add_mesh(struct lbs_private *priv); | |
32 | void lbs_remove_mesh(struct lbs_private *priv); | |
33 | ||
34 | ||
35 | /* Sending / Receiving */ | |
36 | ||
37 | struct rxpd; | |
38 | struct txpd; | |
39 | ||
40 | struct net_device *lbs_mesh_set_dev(struct lbs_private *priv, | |
41 | struct net_device *dev, struct rxpd *rxpd); | |
42 | void lbs_mesh_set_txpd(struct lbs_private *priv, | |
43 | struct net_device *dev, struct txpd *txpd); | |
44 | ||
45 | ||
ece1e3c6 HS |
46 | /* Command handling */ |
47 | ||
48 | struct cmd_ds_command; | |
49 | ||
50 | int lbs_cmd_bt_access(struct cmd_ds_command *cmd, | |
51 | u16 cmd_action, void *pdata_buf); | |
52 | int lbs_cmd_fwt_access(struct cmd_ds_command *cmd, | |
53 | u16 cmd_action, void *pdata_buf); | |
54 | ||
55 | ||
e0e42da3 | 56 | /* Persistent configuration */ |
5e8e8b57 HS |
57 | |
58 | void lbs_persist_config_init(struct net_device *net); | |
59 | void lbs_persist_config_remove(struct net_device *net); | |
60 | ||
e0e42da3 HS |
61 | |
62 | /* WEXT handler */ | |
63 | ||
5e8e8b57 HS |
64 | extern struct iw_handler_def mesh_handler_def; |
65 | ||
66 | ||
c7fe64cf HS |
67 | /* Ethtool statistics */ |
68 | ||
69 | struct ethtool_stats; | |
70 | ||
71 | void lbs_mesh_ethtool_get_stats(struct net_device *dev, | |
72 | struct ethtool_stats *stats, uint64_t *data); | |
73 | int lbs_mesh_ethtool_get_sset_count(struct net_device *dev, int sset); | |
74 | void lbs_mesh_ethtool_get_strings(struct net_device *dev, | |
75 | uint32_t stringset, uint8_t *s); | |
76 | ||
77 | ||
5e8e8b57 | 78 | #endif |