Uniformize package Makefile,
[openwrt.git] / package / openwrt / include / wlutils.h
1 /*
2 * Broadcom wireless network adapter utility functions
3 *
4 * Copyright 2004, Broadcom Corporation
5 * All Rights Reserved.
6 *
7 * THIS SOFTWARE IS OFFERED "AS IS", AND BROADCOM GRANTS NO WARRANTIES OF ANY
8 * KIND, EXPRESS OR IMPLIED, BY STATUTE, COMMUNICATION OR OTHERWISE. BROADCOM
9 * SPECIFICALLY DISCLAIMS ANY IMPLIED WARRANTIES OF MERCHANTABILITY, FITNESS
10 * FOR A SPECIFIC PURPOSE OR NONINFRINGEMENT CONCERNING THIS SOFTWARE.
11 *
12 * $Id$
13 */
14
15 #ifndef _wlutils_h_
16 #define _wlutils_h_
17
18 #include <typedefs.h>
19 #include <wlioctl.h>
20
21 /*
22 * Pass a wlioctl request to the specified interface.
23 * @param name interface name
24 * @param cmd WLC_GET_MAGIC <= cmd < WLC_LAST
25 * @param buf buffer for passing in and/or receiving data
26 * @param len length of buf
27 * @return >= 0 if successful or < 0 otherwise
28 */
29 extern int wl_ioctl(char *name, int cmd, void *buf, int len);
30
31 /*
32 * Get the MAC (hardware) address of the specified interface.
33 * @param name interface name
34 * @param hwaddr 6-byte buffer for receiving address
35 * @return >= 0 if successful or < 0 otherwise
36 */
37 extern int wl_hwaddr(char *name, unsigned char *hwaddr);
38
39 /*
40 * Probe the specified interface.
41 * @param name interface name
42 * @return >= 0 if a Broadcom wireless device or < 0 otherwise
43 */
44 extern int wl_probe(char *name);
45
46 /*
47 * Set/Get named variable.
48 * @param name interface name
49 * @param var variable name
50 * @param val variable value/buffer
51 * @param len variable value/buffer length
52 * @return success == 0, failure != 0
53 */
54 extern int wl_set_val(char *name, char *var, void *val, int len);
55 extern int wl_get_val(char *name, char *var, void *val, int len);
56 extern int wl_set_int(char *name, char *var, int val);
57 extern int wl_get_int(char *name, char *var, int *val);
58
59 #endif /* _wlutils_h_ */
This page took 0.046399 seconds and 5 git commands to generate.