staging: ath6kl: Convert enum A_STATUS to int
[linux-2.6.git] / drivers / staging / ath6kl / include / gpio_api.h
blob81c228dd16ab0939e076dbec588cb9713cda4f86
1 //------------------------------------------------------------------------------
2 // <copyright file="gpio_api.h" company="Atheros">
3 // Copyright (c) 2004-2010 Atheros Corporation. All rights reserved.
4 //
5 //
6 // Permission to use, copy, modify, and/or distribute this software for any
7 // purpose with or without fee is hereby granted, provided that the above
8 // copyright notice and this permission notice appear in all copies.
9 //
10 // THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
11 // WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
12 // MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
13 // ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
14 // WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
15 // ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
16 // OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
19 //------------------------------------------------------------------------------
20 //==============================================================================
21 // Host-side General Purpose I/O API.
23 // Author(s): ="Atheros"
24 //==============================================================================
25 #ifndef _GPIO_API_H_
26 #define _GPIO_API_H_
29 * Send a command to the Target in order to change output on GPIO pins.
31 int wmi_gpio_output_set(struct wmi_t *wmip,
32 A_UINT32 set_mask,
33 A_UINT32 clear_mask,
34 A_UINT32 enable_mask,
35 A_UINT32 disable_mask);
38 * Send a command to the Target requesting input state of GPIO pins.
40 int wmi_gpio_input_get(struct wmi_t *wmip);
43 * Send a command to the Target to change the value of a GPIO register.
45 int wmi_gpio_register_set(struct wmi_t *wmip,
46 A_UINT32 gpioreg_id,
47 A_UINT32 value);
50 * Send a command to the Target to fetch the value of a GPIO register.
52 int wmi_gpio_register_get(struct wmi_t *wmip, A_UINT32 gpioreg_id);
55 * Send a command to the Target, acknowledging some GPIO interrupts.
57 int wmi_gpio_intr_ack(struct wmi_t *wmip, A_UINT32 ack_mask);
59 #endif /* _GPIO_API_H_ */