blob: 210c2b1b7f9758cbe05b3c6758a19e8a55e85897 [file] [log] [blame]
David Kilroy712a4342009-02-04 23:05:55 +00001/* Encapsulate basic setting changes on Hermes hardware
2 *
3 * See copyright notice in main.c
4 */
5#ifndef _ORINOCO_HW_H_
6#define _ORINOCO_HW_H_
7
8#include <linux/types.h>
9#include <linux/wireless.h>
10
11/* Hardware BAPs */
12#define USER_BAP 0
13#define IRQ_BAP 1
14
15/* WEP key sizes */
16#define SMALL_KEY_SIZE 5
17#define LARGE_KEY_SIZE 13
18
19/* Number of supported channels */
20#define NUM_CHANNELS 14
21
22/* Forward declarations */
23struct orinoco_private;
24struct dev_addr_list;
25
David Kilroya2d1a422009-06-18 23:21:18 +010026int determine_fw_capabilities(struct orinoco_private *priv);
David Kilroye9e3d012009-06-18 23:21:19 +010027int orinoco_hw_read_card_settings(struct orinoco_private *priv, u8 *dev_addr);
David Kilroy42a51b92009-06-18 23:21:20 +010028int orinoco_hw_allocate_fid(struct orinoco_private *priv);
David Kilroy712a4342009-02-04 23:05:55 +000029int orinoco_get_bitratemode(int bitrate, int automatic);
30void orinoco_get_ratemode_cfg(int ratemode, int *bitrate, int *automatic);
31
David Kilroy721aa2f2009-06-18 23:21:31 +010032int orinoco_hw_program_rids(struct orinoco_private *priv);
David Kilroy712a4342009-02-04 23:05:55 +000033int orinoco_hw_get_tkip_iv(struct orinoco_private *priv, int key, u8 *tsc);
34int __orinoco_hw_set_bitrate(struct orinoco_private *priv);
35int orinoco_hw_get_act_bitrate(struct orinoco_private *priv, int *bitrate);
36int __orinoco_hw_set_wap(struct orinoco_private *priv);
37int __orinoco_hw_setup_wepkeys(struct orinoco_private *priv);
38int __orinoco_hw_setup_enc(struct orinoco_private *priv);
David Kilroy98e5f402009-06-18 23:21:25 +010039int __orinoco_hw_set_tkip_key(struct orinoco_private *priv, int key_idx,
40 int set_tx, u8 *key, u8 *rsc, u8 *tsc);
David Kilroy712a4342009-02-04 23:05:55 +000041int orinoco_clear_tkip_key(struct orinoco_private *priv, int key_idx);
42int __orinoco_hw_set_multicast_list(struct orinoco_private *priv,
43 struct dev_addr_list *mc_list,
44 int mc_count, int promisc);
45int orinoco_hw_get_essid(struct orinoco_private *priv, int *active,
46 char buf[IW_ESSID_MAX_SIZE+1]);
47int orinoco_hw_get_freq(struct orinoco_private *priv);
48int orinoco_hw_get_bitratelist(struct orinoco_private *priv,
49 int *numrates, s32 *rates, int max);
50
51#endif /* _ORINOCO_HW_H_ */