WHENCE: Update licensing information about the a56 assembler given the GPLed patches...
[linux-libre-firmware.git] / ath9k_htc / target_firmware / magpie_fw_dev / target / inc / magpie / vdesc_api.h
1 /*
2  * @File: VBUF_api.h
3  * 
4  * @Abstract: Host Interface api
5  * 
6  * @Notes:
7  * 
8  * Copyright (c) 2008 Atheros Communications Inc.
9  * All rights reserved.
10  *
11  */
12
13 #ifndef _VDESC_API_H
14 #define _VDESC_API_H
15
16 //#define VDESC_CONTROL_BUF_HDR          (1 << 6)  /* the buffer was manipulated and a header added */
17
18 #define MAX_HW_DESC_SIZE 20
19
20 typedef struct _VDESC
21 {
22     struct _VDESC   *next_desc;
23     A_UINT8         *buf_addr;
24     A_UINT16        buf_size;
25     A_UINT16        data_offset;
26     A_UINT16        data_size;
27     A_UINT16        control;
28     A_UINT8         hw_desc_buf[MAX_HW_DESC_SIZE]; 
29 } VDESC;
30
31 //#define VDESC_HW_TO_VDESC(hwdesc)   ((VDESC *)(((A_UINT32 *)hwdesc - 4)))
32 #define VDESC_HW_TO_VDESC(hwdesc)   ((VDESC *)(((A_UINT32 *)hwdesc - 4)))
33
34 struct vdesc_api {
35     void        (*_init)(int nDesc);
36     VDESC*      (*_alloc_vdesc)();
37     A_UINT8*    (*_get_hw_desc)(VDESC *desc);
38     void        (*_swap_vdesc)(VDESC *dest, VDESC *src);
39     //void (*_free_vdesc)(void);
40         /* room to expand this table by another table */
41     void *pReserved;    
42 };
43
44 extern void vdesc_module_install(struct vdesc_api *apis);
45
46 #endif