5 * acxpci.h: PCI related constants and structures.
7 * Copyright (c) 2008 Francis Galiegue <fgaliegue@gmail.com> for the ACX100
10 * This file is licensed under the GPLv2. See the README file for details.
17 /* Register I/O offsets */
18 #define ACX100_EEPROM_ID_OFFSET 0x380
21 * Please add further ACX hardware register definitions only when
22 * it turns out you need them in the driver, and please try to use firmware
23 * functionality instead, since using direct I/O access instead of letting the
24 * firmware do it might confuse the firmware's state machine.
27 /* ***** ABSOLUTELY ALWAYS KEEP OFFSETS IN SYNC WITH THE INITIALIZATION
28 ** OF THE I/O ARRAYS!!!! (grep for '^IO_ACX') ***** */
31 * NOTE about ACX_IO_IRQ_REASON: this register is CLEARED ON READ.
34 ACX_IO_SOFT_RESET
= 0,
41 ACX_IO_FEMR
, /* Function Event Mask */
45 ACX_IO_IRQ_STATUS_NON_DES
,
65 ACX_IO_CMD_MAILBOX_OFFS
,
66 ACX_IO_INFO_MAILBOX_OFFS
,
67 ACX_IO_EEPROM_INFORMATION
,
73 /* ***** ABSOLUTELY ALWAYS KEEP OFFSETS IN SYNC WITH THE INITIALIZATION
74 ** OF THE I/O ARRAYS!!!! (grep for '^IO_ACX') ***** */
76 /* Values for ACX_IO_INT_TRIG register: */
77 /* inform hw that rxdesc in queue needs processing */
78 #define INT_TRIG_RXPRC 0x08
79 /* inform hw that txdesc in queue needs processing */
80 #define INT_TRIG_TXPRC 0x04
81 /* ack that we received info from info mailbox */
82 #define INT_TRIG_INFOACK 0x02
83 /* inform hw that we have filled command mailbox */
84 #define INT_TRIG_CMD 0x01
87 * In-hardware TX/RX structures
91 acx_ptr data_phy
; /* 0x00 [u8 *] */
92 u16 data_offset
; /* 0x04 */
93 u16 reserved
; /* 0x06 */
94 u16 Ctl_16
; /* 16bit value, endianness!! */
95 u16 length
; /* 0x0a */
96 acx_ptr desc_phy_next
; /* 0x0c [txhostdesc *] */
97 acx_ptr pNext
; /* 0x10 [txhostdesc *] */
98 u32 Status
; /* 0x14, unused on Tx */
99 /* From here on you can use this area as you want (variable length, too!) */
101 struct ieee80211_tx_status txstatus
;
104 } __attribute__ ((packed
));
107 acx_ptr data_phy
; /* 0x00 [rxbuffer_t *] */
108 u16 data_offset
; /* 0x04 */
109 u16 reserved
; /* 0x06 */
110 u16 Ctl_16
; /* 0x08; 16bit value, endianness!! */
111 u16 length
; /* 0x0a */
112 acx_ptr desc_phy_next
; /* 0x0c [rxhostdesc_t *] */
113 acx_ptr pNext
; /* 0x10 [rxhostdesc_t *] */
114 u32 Status
; /* 0x14 */
115 /* From here on you can use this area as you want (variable length, too!) */
117 } __attribute__ ((packed
));
120 #endif /* _ACXPCI_H_ */