ar5212_attach.c (239643) | ar5212_attach.c (242408) |
---|---|
1/* 2 * Copyright (c) 2002-2009 Sam Leffler, Errno Consulting 3 * Copyright (c) 2002-2008 Atheros Communications, Inc. 4 * 5 * Permission to use, copy, modify, and/or distribute this software for any 6 * purpose with or without fee is hereby granted, provided that the above 7 * copyright notice and this permission notice appear in all copies. 8 * 9 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES 10 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 11 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR 12 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 13 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 14 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 15 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 16 * | 1/* 2 * Copyright (c) 2002-2009 Sam Leffler, Errno Consulting 3 * Copyright (c) 2002-2008 Atheros Communications, Inc. 4 * 5 * Permission to use, copy, modify, and/or distribute this software for any 6 * purpose with or without fee is hereby granted, provided that the above 7 * copyright notice and this permission notice appear in all copies. 8 * 9 * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES 10 * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF 11 * MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR 12 * ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES 13 * WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN 14 * ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF 15 * OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE. 16 * |
17 * $FreeBSD: head/sys/dev/ath/ath_hal/ar5212/ar5212_attach.c 239643 2012-08-24 07:35:18Z adrian $ | 17 * $FreeBSD: head/sys/dev/ath/ath_hal/ar5212/ar5212_attach.c 242408 2012-10-31 21:03:55Z adrian $ |
18 */ 19#include "opt_ah.h" 20 21#include "ah.h" 22#include "ah_internal.h" 23#include "ah_devid.h" 24 25#include "ar5212/ar5212.h" --- 755 unchanged lines hidden (view full) --- 781 782 pCap->halLow2GhzChan = 2312; 783 /* XXX 2417 too? */ 784 if (IS_RAD5112_ANY(ah) || IS_5413(ah) || IS_2425(ah) || IS_2417(ah)) 785 pCap->halHigh2GhzChan = 2500; 786 else 787 pCap->halHigh2GhzChan = 2732; 788 | 18 */ 19#include "opt_ah.h" 20 21#include "ah.h" 22#include "ah_internal.h" 23#include "ah_devid.h" 24 25#include "ar5212/ar5212.h" --- 755 unchanged lines hidden (view full) --- 781 782 pCap->halLow2GhzChan = 2312; 783 /* XXX 2417 too? */ 784 if (IS_RAD5112_ANY(ah) || IS_5413(ah) || IS_2425(ah) || IS_2417(ah)) 785 pCap->halHigh2GhzChan = 2500; 786 else 787 pCap->halHigh2GhzChan = 2732; 788 |
789 pCap->halLow5GhzChan = 4915; | 789 /* 790 * For AR5111 version < 4, the lowest centre frequency supported is 791 * 5130MHz. For AR5111 version 4, the 4.9GHz channels are supported 792 * but only in 10MHz increments. 793 * 794 * In addition, the programming method is wrong - it uses the IEEE 795 * channel number to calculate the frequency, rather than the 796 * channel centre. Since half/quarter rates re-use some of the 797 * 5GHz channel IEEE numbers, this will result in a badly programmed 798 * synth. 799 * 800 * Until the relevant support is written, just limit lower frequency 801 * support for AR5111 so things aren't incorrectly programmed. 802 * 803 * XXX It's also possible this code doesn't correctly limit the 804 * centre frequencies of potential channels; this is very important 805 * for half/quarter rate! 806 */ 807 if (AH_RADIO_MAJOR(ah) == AR_RAD5111_SREV_MAJOR) { 808 pCap->halLow5GhzChan = 5120; /* XXX lowest centre = 5130MHz */ 809 } else { 810 pCap->halLow5GhzChan = 4915; 811 } |
790 pCap->halHigh5GhzChan = 6100; 791 792 pCap->halCipherCkipSupport = AH_FALSE; 793 pCap->halCipherTkipSupport = AH_TRUE; 794 pCap->halCipherAesCcmSupport = 795 (ath_hal_eepromGetFlag(ah, AR_EEP_AES) && 796 ((AH_PRIVATE(ah)->ah_macVersion > AR_SREV_VERSION_VENICE) || 797 ((AH_PRIVATE(ah)->ah_macVersion == AR_SREV_VERSION_VENICE) && --- 126 unchanged lines hidden --- | 812 pCap->halHigh5GhzChan = 6100; 813 814 pCap->halCipherCkipSupport = AH_FALSE; 815 pCap->halCipherTkipSupport = AH_TRUE; 816 pCap->halCipherAesCcmSupport = 817 (ath_hal_eepromGetFlag(ah, AR_EEP_AES) && 818 ((AH_PRIVATE(ah)->ah_macVersion > AR_SREV_VERSION_VENICE) || 819 ((AH_PRIVATE(ah)->ah_macVersion == AR_SREV_VERSION_VENICE) && --- 126 unchanged lines hidden --- |