ar9285_phy.c (221702) | ar9285_phy.c (222301) |
---|---|
1/* 2 * Copyright (c) 2008-2010 Atheros Communications Inc. 3 * Copyright (c) 2010-2011 Adrian Chadd, Xenion Pty Ltd. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 9 unchanged lines hidden (view full) --- 18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 24 * SUCH DAMAGE. 25 * | 1/* 2 * Copyright (c) 2008-2010 Atheros Communications Inc. 3 * Copyright (c) 2010-2011 Adrian Chadd, Xenion Pty Ltd. 4 * 5 * Redistribution and use in source and binary forms, with or without 6 * modification, are permitted provided that the following conditions 7 * are met: 8 * 1. Redistributions of source code must retain the above copyright --- 9 unchanged lines hidden (view full) --- 18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL 19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS 20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) 21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT 22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY 23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 24 * SUCH DAMAGE. 25 * |
26 * $FreeBSD: head/sys/dev/ath/ath_hal/ar9002/ar9285_phy.c 221702 2011-05-09 17:30:25Z adrian $ | 26 * $FreeBSD: head/sys/dev/ath/ath_hal/ar9002/ar9285_phy.c 222301 2011-05-26 09:15:33Z adrian $ |
27 */ 28#include "opt_ah.h" 29 30#include "ah.h" 31#include "ah_internal.h" 32#include "ah_devid.h" 33#include "ah_eeprom_v4k.h" 34 --- 47 unchanged lines hidden (view full) --- 82 */ 83HAL_BOOL 84ar9285_check_div_comb(struct ath_hal *ah) 85{ 86 uint8_t ant_div_ctl1; 87 HAL_EEPROM_v4k *ee = AH_PRIVATE(ah)->ah_eeprom; 88 const MODAL_EEP4K_HEADER *pModal = &ee->ee_base.modalHeader; 89 | 27 */ 28#include "opt_ah.h" 29 30#include "ah.h" 31#include "ah_internal.h" 32#include "ah_devid.h" 33#include "ah_eeprom_v4k.h" 34 --- 47 unchanged lines hidden (view full) --- 82 */ 83HAL_BOOL 84ar9285_check_div_comb(struct ath_hal *ah) 85{ 86 uint8_t ant_div_ctl1; 87 HAL_EEPROM_v4k *ee = AH_PRIVATE(ah)->ah_eeprom; 88 const MODAL_EEP4K_HEADER *pModal = &ee->ee_base.modalHeader; 89 |
90#if 0 |
|
90 /* For now, simply disable this until it's better debugged. -adrian */ 91 return AH_FALSE; | 91 /* For now, simply disable this until it's better debugged. -adrian */ 92 return AH_FALSE; |
93#endif |
|
92 93 if (! AR_SREV_KITE(ah)) 94 return AH_FALSE; 95 96 if (pModal->version < 3) 97 return AH_FALSE; 98 99 ant_div_ctl1 = pModal->antdiv_ctl1; 100 if ((ant_div_ctl1 & 0x1) && ((ant_div_ctl1 >> 3) & 0x1)) 101 return AH_TRUE; 102 103 return AH_FALSE; 104} | 94 95 if (! AR_SREV_KITE(ah)) 96 return AH_FALSE; 97 98 if (pModal->version < 3) 99 return AH_FALSE; 100 101 ant_div_ctl1 = pModal->antdiv_ctl1; 102 if ((ant_div_ctl1 & 0x1) && ((ant_div_ctl1 >> 3) & 0x1)) 103 return AH_TRUE; 104 105 return AH_FALSE; 106} |