aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net/wireless/iwlwifi/iwl-commands.h
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/net/wireless/iwlwifi/iwl-commands.h')
-rw-r--r--drivers/net/wireless/iwlwifi/iwl-commands.h105
1 files changed, 64 insertions, 41 deletions
diff --git a/drivers/net/wireless/iwlwifi/iwl-commands.h b/drivers/net/wireless/iwlwifi/iwl-commands.h
index 0edba8a6419b..5fdad6532118 100644
--- a/drivers/net/wireless/iwlwifi/iwl-commands.h
+++ b/drivers/net/wireless/iwlwifi/iwl-commands.h
@@ -386,7 +386,18 @@ struct iwl_tx_ant_config_cmd {
386 *****************************************************************************/ 386 *****************************************************************************/
387 387
388#define UCODE_VALID_OK cpu_to_le32(0x1) 388#define UCODE_VALID_OK cpu_to_le32(0x1)
389#define INITIALIZE_SUBTYPE (9) 389
390enum iwlagn_ucode_subtype {
391 UCODE_SUBTYPE_REGULAR = 0,
392 UCODE_SUBTYPE_REGULAR_NEW = 1,
393 UCODE_SUBTYPE_INIT = 9,
394
395 /*
396 * Not a valid subtype, the ucode has just a u8, so
397 * we can use something > 0xff for this value.
398 */
399 UCODE_SUBTYPE_NONE_LOADED = 0x100,
400};
390 401
391/** 402/**
392 * REPLY_ALIVE = 0x1 (response only, not a command) 403 * REPLY_ALIVE = 0x1 (response only, not a command)
@@ -422,49 +433,61 @@ struct iwl_tx_ant_config_cmd {
422 * 433 *
423 * 2) error_event_table_ptr indicates base of the error log. This contains 434 * 2) error_event_table_ptr indicates base of the error log. This contains
424 * information about any uCode error that occurs. For agn, the format 435 * information about any uCode error that occurs. For agn, the format
425 * of the error log is: 436 * of the error log is defined by struct iwl_error_event_table.
426 *
427 * __le32 valid; (nonzero) valid, (0) log is empty
428 * __le32 error_id; type of error
429 * __le32 pc; program counter
430 * __le32 blink1; branch link
431 * __le32 blink2; branch link
432 * __le32 ilink1; interrupt link
433 * __le32 ilink2; interrupt link
434 * __le32 data1; error-specific data
435 * __le32 data2; error-specific data
436 * __le32 line; source code line of error
437 * __le32 bcon_time; beacon timer
438 * __le32 tsf_low; network timestamp function timer
439 * __le32 tsf_hi; network timestamp function timer
440 * __le32 gp1; GP1 timer register
441 * __le32 gp2; GP2 timer register
442 * __le32 gp3; GP3 timer register
443 * __le32 ucode_ver; uCode version
444 * __le32 hw_ver; HW Silicon version
445 * __le32 brd_ver; HW board version
446 * __le32 log_pc; log program counter
447 * __le32 frame_ptr; frame pointer
448 * __le32 stack_ptr; stack pointer
449 * __le32 hcmd; last host command
450 * __le32 isr0; isr status register LMPM_NIC_ISR0: rxtx_flag
451 * __le32 isr1; isr status register LMPM_NIC_ISR1: host_flag
452 * __le32 isr2; isr status register LMPM_NIC_ISR2: enc_flag
453 * __le32 isr3; isr status register LMPM_NIC_ISR3: time_flag
454 * __le32 isr4; isr status register LMPM_NIC_ISR4: wico interrupt
455 * __le32 isr_pref; isr status register LMPM_NIC_PREF_STAT
456 * __le32 wait_event; wait event() caller address
457 * __le32 l2p_control; L2pControlField
458 * __le32 l2p_duration; L2pDurationField
459 * __le32 l2p_mhvalid; L2pMhValidBits
460 * __le32 l2p_addr_match; L2pAddrMatchStat
461 * __le32 lmpm_pmg_sel; indicate which clocks are turned on (LMPM_PMG_SEL)
462 * __le32 u_timestamp; indicate when the date and time of the compilation
463 * __le32 reserved;
464 * 437 *
465 * The Linux driver can print both logs to the system log when a uCode error 438 * The Linux driver can print both logs to the system log when a uCode error
466 * occurs. 439 * occurs.
467 */ 440 */
441
442/*
443 * Note: This structure is read from the device with IO accesses,
444 * and the reading already does the endian conversion. As it is
445 * read with u32-sized accesses, any members with a different size
446 * need to be ordered correctly though!
447 */
448struct iwl_error_event_table {
449 u32 valid; /* (nonzero) valid, (0) log is empty */
450 u32 error_id; /* type of error */
451 u32 pc; /* program counter */
452 u32 blink1; /* branch link */
453 u32 blink2; /* branch link */
454 u32 ilink1; /* interrupt link */
455 u32 ilink2; /* interrupt link */
456 u32 data1; /* error-specific data */
457 u32 data2; /* error-specific data */
458 u32 line; /* source code line of error */
459 u32 bcon_time; /* beacon timer */
460 u32 tsf_low; /* network timestamp function timer */
461 u32 tsf_hi; /* network timestamp function timer */
462 u32 gp1; /* GP1 timer register */
463 u32 gp2; /* GP2 timer register */
464 u32 gp3; /* GP3 timer register */
465 u32 ucode_ver; /* uCode version */
466 u32 hw_ver; /* HW Silicon version */
467 u32 brd_ver; /* HW board version */
468 u32 log_pc; /* log program counter */
469 u32 frame_ptr; /* frame pointer */
470 u32 stack_ptr; /* stack pointer */
471 u32 hcmd; /* last host command header */
472#if 0
473 /* no need to read the remainder, we don't use the values */
474 u32 isr0; /* isr status register LMPM_NIC_ISR0: rxtx_flag */
475 u32 isr1; /* isr status register LMPM_NIC_ISR1: host_flag */
476 u32 isr2; /* isr status register LMPM_NIC_ISR2: enc_flag */
477 u32 isr3; /* isr status register LMPM_NIC_ISR3: time_flag */
478 u32 isr4; /* isr status register LMPM_NIC_ISR4: wico interrupt */
479 u32 isr_pref; /* isr status register LMPM_NIC_PREF_STAT */
480 u32 wait_event; /* wait event() caller address */
481 u32 l2p_control; /* L2pControlField */
482 u32 l2p_duration; /* L2pDurationField */
483 u32 l2p_mhvalid; /* L2pMhValidBits */
484 u32 l2p_addr_match; /* L2pAddrMatchStat */
485 u32 lmpm_pmg_sel; /* indicate which clocks are turned on (LMPM_PMG_SEL) */
486 u32 u_timestamp; /* indicate when the date and time of the compilation */
487 u32 flow_handler; /* FH read/write pointers, RX credit */
488#endif
489} __packed;
490
468struct iwl_alive_resp { 491struct iwl_alive_resp {
469 u8 ucode_minor; 492 u8 ucode_minor;
470 u8 ucode_major; 493 u8 ucode_major;
@@ -638,7 +661,7 @@ struct iwl_rxon_cmd {
638/* 661/*
639 * REPLY_RXON_ASSOC = 0x11 (command, has simple generic response) 662 * REPLY_RXON_ASSOC = 0x11 (command, has simple generic response)
640 */ 663 */
641struct iwl5000_rxon_assoc_cmd { 664struct iwl_rxon_assoc_cmd {
642 __le32 flags; 665 __le32 flags;
643 __le32 filter_flags; 666 __le32 filter_flags;
644 u8 ofdm_basic_rates; 667 u8 ofdm_basic_rates;