ah_diagcodes.h revision 217618
11638Srgrimes/* 21638Srgrimes * Copyright (c) 2002-2009 Sam Leffler, Errno Consulting 31638Srgrimes * Copyright (c) 2002-2008 Atheros Communications, Inc. 41638Srgrimes * 51638Srgrimes * Permission to use, copy, modify, and/or distribute this software for any 61638Srgrimes * purpose with or without fee is hereby granted, provided that the above 71638Srgrimes * copyright notice and this permission notice appear in all copies. 81638Srgrimes * 91638Srgrimes * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES 101638Srgrimes * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 111638Srgrimes * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR 121638Srgrimes * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 131638Srgrimes * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 141638Srgrimes * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 151638Srgrimes * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 161638Srgrimes * 171638Srgrimes * $FreeBSD: head/sys/dev/ath/ath_hal/ah_diagcodes.h 217618 2011-01-20 04:57:26Z adrian $ 181638Srgrimes */ 191638Srgrimes#ifndef _ATH_AH_DIAGCODES_H_ 201638Srgrimes#define _ATH_AH_DIAGCODES_H_ 211638Srgrimes/* 221638Srgrimes * Atheros Device Hardware Access Layer (HAL). 231638Srgrimes * 241638Srgrimes * Internal diagnostic API definitions. 251638Srgrimes */ 261638Srgrimes 271638Srgrimes/* 281638Srgrimes * Diagnostic interface. This is an open-ended interface that 291638Srgrimes * is opaque to applications. Diagnostic programs use this to 301638Srgrimes * retrieve internal data structures, etc. There is no guarantee 311638Srgrimes * that calling conventions for calls other than HAL_DIAG_REVS 321638Srgrimes * are stable between HAL releases; a diagnostic application must 3350476Speter * use the HAL revision information to deal with ABI/API differences. 341638Srgrimes * 351638Srgrimes * NB: do not renumber these, certain codes are publicly used. 361638Srgrimes */ 3779538Sruenum { 381638Srgrimes HAL_DIAG_REVS = 0, /* MAC/PHY/Radio revs */ 391638Srgrimes HAL_DIAG_EEPROM = 1, /* EEPROM contents */ 401638Srgrimes HAL_DIAG_EEPROM_EXP_11A = 2, /* EEPROM 5112 power exp for 11a */ 411638Srgrimes HAL_DIAG_EEPROM_EXP_11B = 3, /* EEPROM 5112 power exp for 11b */ 421638Srgrimes HAL_DIAG_EEPROM_EXP_11G = 4, /* EEPROM 5112 power exp for 11g */ 4368962Sru HAL_DIAG_ANI_CURRENT = 5, /* ANI current channel state */ 441638Srgrimes HAL_DIAG_ANI_OFDM = 6, /* ANI OFDM timing error stats */ 451638Srgrimes HAL_DIAG_ANI_CCK = 7, /* ANI CCK timing error stats */ 461638Srgrimes HAL_DIAG_ANI_STATS = 8, /* ANI statistics */ 471638Srgrimes HAL_DIAG_RFGAIN = 9, /* RfGain GAIN_VALUES */ 481638Srgrimes HAL_DIAG_RFGAIN_CURSTEP = 10, /* RfGain GAIN_OPTIMIZATION_STEP */ 491638Srgrimes HAL_DIAG_PCDAC = 11, /* PCDAC table */ 501638Srgrimes HAL_DIAG_TXRATES = 12, /* Transmit rate table */ 511638Srgrimes HAL_DIAG_REGS = 13, /* Registers */ 521638Srgrimes HAL_DIAG_ANI_CMD = 14, /* ANI issue command (XXX do not change!) */ 531638Srgrimes HAL_DIAG_SETKEY = 15, /* Set keycache backdoor */ 541638Srgrimes HAL_DIAG_RESETKEY = 16, /* Reset keycache backdoor */ 551638Srgrimes HAL_DIAG_EEREAD = 17, /* Read EEPROM word */ 561638Srgrimes HAL_DIAG_EEWRITE = 18, /* Write EEPROM word */ 571638Srgrimes /* 19-26 removed, do not reuse */ 581638Srgrimes HAL_DIAG_RDWRITE = 27, /* Write regulatory domain */ 591638Srgrimes HAL_DIAG_RDREAD = 28, /* Get regulatory domain */ 6079727Sschweikh HAL_DIAG_FATALERR = 29, /* Read cached interrupt state */ 611638Srgrimes HAL_DIAG_11NCOMPAT = 30, /* 11n compatibility tweaks */ 621638Srgrimes HAL_DIAG_ANI_PARAMS = 31, /* ANI noise immunity parameters */ 631638Srgrimes HAL_DIAG_CHECK_HANGS = 32, /* check h/w hangs */ 641638Srgrimes HAL_DIAG_SETREGS = 33, /* write registers */ 6537247Shoek}; 66131530Sru 671638Srgrimes#endif /* _ATH_AH_DIAGCODES_H_ */ 681638Srgrimes