aacvar.h (74374) | aacvar.h (81082) |
---|---|
1/*- 2 * Copyright (c) 2000 Michael Smith | 1/*- 2 * Copyright (c) 2000 Michael Smith |
3 * Copyright (c) 2001 Scott Long |
|
3 * Copyright (c) 2000 BSDi | 4 * Copyright (c) 2000 BSDi |
5 * Copyright (c) 2001 Adaptec, Inc. |
|
4 * All rights reserved. 5 * 6 * Redistribution and use in source and binary forms, with or without 7 * modification, are permitted provided that the following conditions 8 * are met: 9 * 1. Redistributions of source code must retain the above copyright 10 * notice, this list of conditions and the following disclaimer. 11 * 2. Redistributions in binary form must reproduce the above copyright --- 7 unchanged lines hidden (view full) --- 19 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 20 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 21 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 22 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 23 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 24 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 25 * SUCH DAMAGE. 26 * | 6 * All rights reserved. 7 * 8 * Redistribution and use in source and binary forms, with or without 9 * modification, are permitted provided that the following conditions 10 * are met: 11 * 1. Redistributions of source code must retain the above copyright 12 * notice, this list of conditions and the following disclaimer. 13 * 2. Redistributions in binary form must reproduce the above copyright --- 7 unchanged lines hidden (view full) --- 21 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 22 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 23 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 24 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 25 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 26 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 27 * SUCH DAMAGE. 28 * |
27 * $FreeBSD: head/sys/dev/aac/aacvar.h 74374 2001-03-17 00:12:15Z gibbs $ | 29 * $FreeBSD: head/sys/dev/aac/aacvar.h 81082 2001-08-03 00:50:30Z scottl $ |
28 */ 29 | 30 */ 31 |
30/******************************************************************************** 31 ******************************************************************************** 32 Driver Parameter Definitions 33 ******************************************************************************** 34 ********************************************************************************/ | 32/****************************************************************************** 33 ****************************************************************************** 34 Driver Parameter Definitions 35 ****************************************************************************** 36 ******************************************************************************/ |
35 36/* 37 * The firmware interface allows for a 16-bit s/g list length. We limit 38 * ourselves to a reasonable maximum and ensure alignment. 39 */ 40#define AAC_MAXSGENTRIES 64 /* max S/G entries, limit 65535 */ 41 42/* --- 5 unchanged lines hidden (view full) --- 48 * FIBs are allocated up-front, and the pool isn't grown. We should allocate 49 * enough here to let us keep the adapter busy without wasting large amounts 50 * of kernel memory. The current interface implementation limits us to 512 51 * FIBs queued for the adapter at any one time. 52 */ 53#define AAC_FIB_COUNT 128 54 55/* | 37 38/* 39 * The firmware interface allows for a 16-bit s/g list length. We limit 40 * ourselves to a reasonable maximum and ensure alignment. 41 */ 42#define AAC_MAXSGENTRIES 64 /* max S/G entries, limit 65535 */ 43 44/* --- 5 unchanged lines hidden (view full) --- 50 * FIBs are allocated up-front, and the pool isn't grown. We should allocate 51 * enough here to let us keep the adapter busy without wasting large amounts 52 * of kernel memory. The current interface implementation limits us to 512 53 * FIBs queued for the adapter at any one time. 54 */ 55#define AAC_FIB_COUNT 128 56 57/* |
56 * The controller reports status events in AIFs. We hang on to a number of these 57 * in order to pass them out to user-space management tools. | 58 * The controller reports status events in AIFs. We hang on to a number of 59 * these in order to pass them out to user-space management tools. |
58 */ 59#define AAC_AIFQ_LENGTH 64 60 61/* 62 * Firmware messages are passed in the printf buffer. 63 */ 64#define AAC_PRINTF_BUFSIZE 256 65 66/* | 60 */ 61#define AAC_AIFQ_LENGTH 64 62 63/* 64 * Firmware messages are passed in the printf buffer. 65 */ 66#define AAC_PRINTF_BUFSIZE 256 67 68/* |
67 * We wait this many seconds for the adapter to come ready if it is still booting | 69 * We wait this many seconds for the adapter to come ready if it is still 70 * booting |
68 */ 69#define AAC_BOOT_TIMEOUT (3 * 60) 70 71/* 72 * Timeout for immediate commands. 73 */ 74#define AAC_IMMEDIATE_TIMEOUT 30 /* seconds */ 75 --- 8 unchanged lines hidden (view full) --- 84 */ 85#define AAC_PERIODIC_INTERVAL 10 /* seconds */ 86 87/* 88 * Character device major numbers. 89 */ 90#define AAC_DISK_MAJOR 200 91 | 71 */ 72#define AAC_BOOT_TIMEOUT (3 * 60) 73 74/* 75 * Timeout for immediate commands. 76 */ 77#define AAC_IMMEDIATE_TIMEOUT 30 /* seconds */ 78 --- 8 unchanged lines hidden (view full) --- 87 */ 88#define AAC_PERIODIC_INTERVAL 10 /* seconds */ 89 90/* 91 * Character device major numbers. 92 */ 93#define AAC_DISK_MAJOR 200 94 |
92/******************************************************************************** 93 ******************************************************************************** 94 Driver Variable Definitions 95 ******************************************************************************** 96 ********************************************************************************/ | 95/****************************************************************************** 96 ****************************************************************************** 97 Driver Variable Definitions 98 ****************************************************************************** 99 ******************************************************************************/ |
97 98#include "opt_aac.h" 99 100#if __FreeBSD_version >= 500005 101# include <sys/taskqueue.h> 102#endif 103 104/* --- 29 unchanged lines hidden (view full) --- 134 * Per-command control structure. 135 */ 136struct aac_command 137{ 138 TAILQ_ENTRY(aac_command) cm_link; /* list linkage */ 139 140 struct aac_softc *cm_sc; /* controller that owns us */ 141 | 100 101#include "opt_aac.h" 102 103#if __FreeBSD_version >= 500005 104# include <sys/taskqueue.h> 105#endif 106 107/* --- 29 unchanged lines hidden (view full) --- 137 * Per-command control structure. 138 */ 139struct aac_command 140{ 141 TAILQ_ENTRY(aac_command) cm_link; /* list linkage */ 142 143 struct aac_softc *cm_sc; /* controller that owns us */ 144 |
142 struct aac_fib *cm_fib; /* FIB associated with this command */ | 145 struct aac_fib *cm_fib; /* FIB associated with this 146 * command */ |
143 u_int32_t cm_fibphys; /* bus address of the FIB */ | 147 u_int32_t cm_fibphys; /* bus address of the FIB */ |
144 struct bio *cm_data; /* pointer to data in kernel space */ | 148 struct bio *cm_data; /* pointer to data in kernel 149 * space */ |
145 u_int32_t cm_datalen; /* data length */ 146 bus_dmamap_t cm_datamap; /* DMA map for bio data */ | 150 u_int32_t cm_datalen; /* data length */ 151 bus_dmamap_t cm_datamap; /* DMA map for bio data */ |
147 struct aac_sg_table *cm_sgtable; /* pointer to s/g table in command */ | 152 struct aac_sg_table *cm_sgtable; /* pointer to s/g table in 153 * command */ |
148 149 int cm_flags; | 154 155 int cm_flags; |
150#define AAC_CMD_MAPPED (1<<0) /* command has had its data mapped */ 151#define AAC_CMD_DATAIN (1<<1) /* command involves data moving from controller to host */ 152#define AAC_CMD_DATAOUT (1<<2) /* command involves data moving from host to controller */ | 156#define AAC_CMD_MAPPED (1<<0) /* command has had its data 157 * mapped */ 158#define AAC_CMD_DATAIN (1<<1) /* command involves data moving 159 * from controller to host */ 160#define AAC_CMD_DATAOUT (1<<2) /* command involves data moving 161 * from host to controller */ |
153#define AAC_CMD_COMPLETED (1<<3) /* command has been completed */ 154#define AAC_CMD_TIMEDOUT (1<<4) /* command taken too long */ 155 156 void (* cm_complete)(struct aac_command *cm); 157 void *cm_private; 158 time_t cm_timestamp; /* command creation time */ 159}; 160 --- 13 unchanged lines hidden (view full) --- 174struct aac_common { 175 /* fibs for the controller to send us messages */ 176 struct aac_fib ac_fibs[AAC_ADAPTER_FIBS]; 177 178 /* the init structure */ 179 struct aac_adapter_init ac_init; 180 181 /* arena within which the queue structures are kept */ | 162#define AAC_CMD_COMPLETED (1<<3) /* command has been completed */ 163#define AAC_CMD_TIMEDOUT (1<<4) /* command taken too long */ 164 165 void (* cm_complete)(struct aac_command *cm); 166 void *cm_private; 167 time_t cm_timestamp; /* command creation time */ 168}; 169 --- 13 unchanged lines hidden (view full) --- 183struct aac_common { 184 /* fibs for the controller to send us messages */ 185 struct aac_fib ac_fibs[AAC_ADAPTER_FIBS]; 186 187 /* the init structure */ 188 struct aac_adapter_init ac_init; 189 190 /* arena within which the queue structures are kept */ |
182 u_int8_t ac_qbuf[sizeof(struct aac_queue_table) + AAC_QUEUE_ALIGN]; | 191 u_int8_t ac_qbuf[sizeof(struct aac_queue_table) + 192 AAC_QUEUE_ALIGN]; |
183 184 /* buffer for text messages from the controller */ 185 char ac_printf[AAC_PRINTF_BUFSIZE]; 186 187 /* fib for synchronous commands */ 188 struct aac_fib ac_sync_fib; 189}; 190 191/* 192 * Interface operations 193 */ 194struct aac_interface 195{ 196 int (* aif_get_fwstatus)(struct aac_softc *sc); 197 void (* aif_qnotify)(struct aac_softc *sc, int qbit); 198 int (* aif_get_istatus)(struct aac_softc *sc); 199 void (* aif_set_istatus)(struct aac_softc *sc, int mask); 200 void (* aif_set_mailbox)(struct aac_softc *sc, u_int32_t command, | 193 194 /* buffer for text messages from the controller */ 195 char ac_printf[AAC_PRINTF_BUFSIZE]; 196 197 /* fib for synchronous commands */ 198 struct aac_fib ac_sync_fib; 199}; 200 201/* 202 * Interface operations 203 */ 204struct aac_interface 205{ 206 int (* aif_get_fwstatus)(struct aac_softc *sc); 207 void (* aif_qnotify)(struct aac_softc *sc, int qbit); 208 int (* aif_get_istatus)(struct aac_softc *sc); 209 void (* aif_set_istatus)(struct aac_softc *sc, int mask); 210 void (* aif_set_mailbox)(struct aac_softc *sc, u_int32_t command, |
201 u_int32_t arg0, u_int32_t arg1, u_int32_t arg2, u_int32_t arg3); | 211 u_int32_t arg0, u_int32_t arg1, 212 u_int32_t arg2, u_int32_t arg3); |
202 int (* aif_get_mailboxstatus)(struct aac_softc *sc); 203 void (* aif_set_interrupts)(struct aac_softc *sc, int enable); 204}; 205extern struct aac_interface aac_rx_interface; 206extern struct aac_interface aac_sa_interface; 207 208#define AAC_GET_FWSTATUS(sc) ((sc)->aac_if.aif_get_fwstatus((sc))) 209#define AAC_QNOTIFY(sc, qbit) ((sc)->aac_if.aif_qnotify((sc), (qbit))) 210#define AAC_GET_ISTATUS(sc) ((sc)->aac_if.aif_get_istatus((sc))) | 213 int (* aif_get_mailboxstatus)(struct aac_softc *sc); 214 void (* aif_set_interrupts)(struct aac_softc *sc, int enable); 215}; 216extern struct aac_interface aac_rx_interface; 217extern struct aac_interface aac_sa_interface; 218 219#define AAC_GET_FWSTATUS(sc) ((sc)->aac_if.aif_get_fwstatus((sc))) 220#define AAC_QNOTIFY(sc, qbit) ((sc)->aac_if.aif_qnotify((sc), (qbit))) 221#define AAC_GET_ISTATUS(sc) ((sc)->aac_if.aif_get_istatus((sc))) |
211#define AAC_CLEAR_ISTATUS(sc, mask) ((sc)->aac_if.aif_set_istatus((sc), (mask))) | 222#define AAC_CLEAR_ISTATUS(sc, mask) ((sc)->aac_if.aif_set_istatus((sc), \ 223 (mask))) |
212#define AAC_SET_MAILBOX(sc, command, arg0, arg1, arg2, arg3) \ | 224#define AAC_SET_MAILBOX(sc, command, arg0, arg1, arg2, arg3) \ |
213 ((sc)->aac_if.aif_set_mailbox((sc), (command), (arg0), (arg1), (arg2), (arg3))) | 225 ((sc)->aac_if.aif_set_mailbox((sc), (command), (arg0), (arg1), (arg2), \ 226 (arg3))) |
214#define AAC_GET_MAILBOXSTATUS(sc) ((sc)->aac_if.aif_get_mailboxstatus((sc))) 215#define AAC_MASK_INTERRUPTS(sc) ((sc)->aac_if.aif_set_interrupts((sc), 0)) 216#define AAC_UNMASK_INTERRUPTS(sc) ((sc)->aac_if.aif_set_interrupts((sc), 1)) 217 | 227#define AAC_GET_MAILBOXSTATUS(sc) ((sc)->aac_if.aif_get_mailboxstatus((sc))) 228#define AAC_MASK_INTERRUPTS(sc) ((sc)->aac_if.aif_set_interrupts((sc), 0)) 229#define AAC_UNMASK_INTERRUPTS(sc) ((sc)->aac_if.aif_set_interrupts((sc), 1)) 230 |
218#define AAC_SETREG4(sc, reg, val) bus_space_write_4(sc->aac_btag, sc->aac_bhandle, reg, val) 219#define AAC_GETREG4(sc, reg) bus_space_read_4 (sc->aac_btag, sc->aac_bhandle, reg) 220#define AAC_SETREG2(sc, reg, val) bus_space_write_2(sc->aac_btag, sc->aac_bhandle, reg, val) 221#define AAC_GETREG2(sc, reg) bus_space_read_2 (sc->aac_btag, sc->aac_bhandle, reg) 222#define AAC_SETREG1(sc, reg, val) bus_space_write_1(sc->aac_btag, sc->aac_bhandle, reg, val) 223#define AAC_GETREG1(sc, reg) bus_space_read_1 (sc->aac_btag, sc->aac_bhandle, reg) | 231#define AAC_SETREG4(sc, reg, val) bus_space_write_4(sc->aac_btag, \ 232 sc->aac_bhandle, reg, val) 233#define AAC_GETREG4(sc, reg) bus_space_read_4 (sc->aac_btag, \ 234 sc->aac_bhandle, reg) 235#define AAC_SETREG2(sc, reg, val) bus_space_write_2(sc->aac_btag, \ 236 sc->aac_bhandle, reg, val) 237#define AAC_GETREG2(sc, reg) bus_space_read_2 (sc->aac_btag, \ 238 sc->aac_bhandle, reg) 239#define AAC_SETREG1(sc, reg, val) bus_space_write_1(sc->aac_btag, \ 240 sc->aac_bhandle, reg, val) 241#define AAC_GETREG1(sc, reg) bus_space_read_1 (sc->aac_btag, \ 242 sc->aac_bhandle, reg) |
224 225/* 226 * Per-controller structure. 227 */ 228struct aac_softc 229{ 230 /* bus connections */ 231 device_t aac_dev; | 243 244/* 245 * Per-controller structure. 246 */ 247struct aac_softc 248{ 249 /* bus connections */ 250 device_t aac_dev; |
232 struct resource *aac_regs_resource; /* register interface window */ | 251 struct resource *aac_regs_resource; /* register interface 252 * window */ |
233 int aac_regs_rid; /* resource ID */ 234 bus_space_handle_t aac_bhandle; /* bus space handle */ 235 bus_space_tag_t aac_btag; /* bus space tag */ 236 bus_dma_tag_t aac_parent_dmat; /* parent DMA tag */ | 253 int aac_regs_rid; /* resource ID */ 254 bus_space_handle_t aac_bhandle; /* bus space handle */ 255 bus_space_tag_t aac_btag; /* bus space tag */ 256 bus_dma_tag_t aac_parent_dmat; /* parent DMA tag */ |
237 bus_dma_tag_t aac_buffer_dmat; /* data buffer/command DMA tag */ | 257 bus_dma_tag_t aac_buffer_dmat; /* data buffer/command 258 * DMA tag */ |
238 struct resource *aac_irq; /* interrupt */ 239 int aac_irq_rid; 240 void *aac_intr; /* interrupt handle */ 241 242 /* controller features, limits and status */ 243 int aac_state; 244#define AAC_STATE_SUSPEND (1<<0) 245#define AAC_STATE_OPEN (1<<1) 246#define AAC_STATE_INTERRUPTS_ON (1<<2) 247#define AAC_STATE_AIF_SLEEPER (1<<3) 248 struct FsaRevision aac_revision; 249 250 /* controller hardware interface */ 251 int aac_hwif; 252#define AAC_HWIF_I960RX 0 253#define AAC_HWIF_STRONGARM 1 254#define AAC_HWIF_UNKNOWN -1 | 259 struct resource *aac_irq; /* interrupt */ 260 int aac_irq_rid; 261 void *aac_intr; /* interrupt handle */ 262 263 /* controller features, limits and status */ 264 int aac_state; 265#define AAC_STATE_SUSPEND (1<<0) 266#define AAC_STATE_OPEN (1<<1) 267#define AAC_STATE_INTERRUPTS_ON (1<<2) 268#define AAC_STATE_AIF_SLEEPER (1<<3) 269 struct FsaRevision aac_revision; 270 271 /* controller hardware interface */ 272 int aac_hwif; 273#define AAC_HWIF_I960RX 0 274#define AAC_HWIF_STRONGARM 1 275#define AAC_HWIF_UNKNOWN -1 |
255 bus_dma_tag_t aac_common_dmat; /* common structure DMA tag */ 256 bus_dmamap_t aac_common_dmamap; /* common structure DMA map */ | 276 bus_dma_tag_t aac_common_dmat; /* common structure 277 * DMA tag */ 278 bus_dmamap_t aac_common_dmamap; /* common structure 279 * DMA map */ |
257 struct aac_common *aac_common; 258 u_int32_t aac_common_busaddr; 259 struct aac_interface aac_if; 260 261 /* command/fib resources */ | 280 struct aac_common *aac_common; 281 u_int32_t aac_common_busaddr; 282 struct aac_interface aac_if; 283 284 /* command/fib resources */ |
262 bus_dma_tag_t aac_fib_dmat; /* DMA tag for allocating FIBs */ | 285 bus_dma_tag_t aac_fib_dmat; /* DMA tag for allocing FIBs */ |
263 struct aac_fib *aac_fibs; 264 bus_dmamap_t aac_fibmap; 265 u_int32_t aac_fibphys; 266 struct aac_command aac_command[AAC_FIB_COUNT]; 267 268 /* command management */ | 286 struct aac_fib *aac_fibs; 287 bus_dmamap_t aac_fibmap; 288 u_int32_t aac_fibphys; 289 struct aac_command aac_command[AAC_FIB_COUNT]; 290 291 /* command management */ |
269 TAILQ_HEAD(,aac_command) aac_free; /* command structures available for reuse */ 270 TAILQ_HEAD(,aac_command) aac_ready; /* commands on hold for controller resources */ | 292 TAILQ_HEAD(,aac_command) aac_free; /* command structures 293 * available for reuse */ 294 TAILQ_HEAD(,aac_command) aac_ready; /* commands on hold for 295 * controller resources */ |
271 TAILQ_HEAD(,aac_command) aac_busy; | 296 TAILQ_HEAD(,aac_command) aac_busy; |
272 TAILQ_HEAD(,aac_command) aac_complete; /* commands which have been returned by the controller */ | 297 TAILQ_HEAD(,aac_command) aac_complete; /* commands which have been 298 * returned by the controller */ |
273 struct bio_queue_head aac_bioq; 274 struct aac_queue_table *aac_queues; 275 struct aac_queue_entry *aac_qentries[AAC_QUEUE_COUNT]; 276 277 struct aac_qstat aac_qstat[AACQ_COUNT]; /* queue statistics */ 278 279 /* connected containters */ 280 struct aac_container aac_container[AAC_MAX_CONTAINERS]; 281 282 /* delayed activity infrastructure */ 283#if __FreeBSD_version >= 500005 | 299 struct bio_queue_head aac_bioq; 300 struct aac_queue_table *aac_queues; 301 struct aac_queue_entry *aac_qentries[AAC_QUEUE_COUNT]; 302 303 struct aac_qstat aac_qstat[AACQ_COUNT]; /* queue statistics */ 304 305 /* connected containters */ 306 struct aac_container aac_container[AAC_MAX_CONTAINERS]; 307 308 /* delayed activity infrastructure */ 309#if __FreeBSD_version >= 500005 |
284 struct task aac_task_complete; /* deferred-completion task */ | 310 struct task aac_task_complete; /* deferred-completion 311 * task */ |
285#endif 286 struct intr_config_hook aac_ich; 287 288 /* management interface */ 289 dev_t aac_dev_t; 290 struct aac_aif_command aac_aifq[AAC_AIFQ_LENGTH]; 291 int aac_aifq_head; 292 int aac_aifq_tail; --- 16 unchanged lines hidden (view full) --- 309 310/* 311 * Debugging levels: 312 * 0 - quiet, only emit warnings 313 * 1 - noisy, emit major function points and things done 314 * 2 - extremely noisy, emit trace items in loops, etc. 315 */ 316#ifdef AAC_DEBUG | 312#endif 313 struct intr_config_hook aac_ich; 314 315 /* management interface */ 316 dev_t aac_dev_t; 317 struct aac_aif_command aac_aifq[AAC_AIFQ_LENGTH]; 318 int aac_aifq_head; 319 int aac_aifq_tail; --- 16 unchanged lines hidden (view full) --- 336 337/* 338 * Debugging levels: 339 * 0 - quiet, only emit warnings 340 * 1 - noisy, emit major function points and things done 341 * 2 - extremely noisy, emit trace items in loops, etc. 342 */ 343#ifdef AAC_DEBUG |
317# define debug(level, fmt, args...) \ 318 do { \ 319 if (level <= AAC_DEBUG) printf("%s: " fmt "\n", __FUNCTION__ , ##args); \ | 344# define debug(level, fmt, args...) \ 345 do { \ 346 if (level <=AAC_DEBUG) printf("%s: " fmt "\n", __FUNCTION__ , ##args); \ |
320 } while(0) 321# define debug_called(level) \ 322 do { \ 323 if (level <= AAC_DEBUG) printf(__FUNCTION__ ": called\n"); \ 324 } while(0) 325 326extern void aac_print_queues(struct aac_softc *sc); 327extern void aac_panic(struct aac_softc *sc, char *reason); | 347 } while(0) 348# define debug_called(level) \ 349 do { \ 350 if (level <= AAC_DEBUG) printf(__FUNCTION__ ": called\n"); \ 351 } while(0) 352 353extern void aac_print_queues(struct aac_softc *sc); 354extern void aac_panic(struct aac_softc *sc, char *reason); |
328extern void aac_print_fib(struct aac_softc *sc, struct aac_fib *fib, char *caller); 329extern void aac_print_aif(struct aac_softc *sc, struct aac_aif_command *aif); | 355extern void aac_print_fib(struct aac_softc *sc, struct aac_fib *fib, 356 char *caller); 357extern void aac_print_aif(struct aac_softc *sc, 358 struct aac_aif_command *aif); |
330 331# define AAC_PRINT_FIB(sc, fib) aac_print_fib(sc, fib, __FUNCTION__) 332 333#else 334# define debug(level, fmt, args...) 335# define debug_called(level) 336 337# define aac_print_queues(sc) 338# define aac_panic(sc, reason) 339# define aac_print_aif(sc, aif) 340 341# define AAC_PRINT_FIB(sc, fib) 342#endif 343 344struct aac_code_lookup { 345 char *string; 346 u_int32_t code; 347}; 348 | 359 360# define AAC_PRINT_FIB(sc, fib) aac_print_fib(sc, fib, __FUNCTION__) 361 362#else 363# define debug(level, fmt, args...) 364# define debug_called(level) 365 366# define aac_print_queues(sc) 367# define aac_panic(sc, reason) 368# define aac_print_aif(sc, aif) 369 370# define AAC_PRINT_FIB(sc, fib) 371#endif 372 373struct aac_code_lookup { 374 char *string; 375 u_int32_t code; 376}; 377 |
349/******************************************************************************** | 378/****************************************************************************** |
350 * Queue primitives for driver queues. 351 */ 352#define AACQ_ADD(sc, qname) \ 353 do { \ 354 struct aac_qstat *qs = &(sc)->aac_qstat[qname]; \ 355 \ 356 qs->q_length++; \ 357 if (qs->q_length > qs->q_max) \ --- 104 unchanged lines hidden --- | 379 * Queue primitives for driver queues. 380 */ 381#define AACQ_ADD(sc, qname) \ 382 do { \ 383 struct aac_qstat *qs = &(sc)->aac_qstat[qname]; \ 384 \ 385 qs->q_length++; \ 386 if (qs->q_length > qs->q_max) \ --- 104 unchanged lines hidden --- |