From owner-freebsd-bugs@FreeBSD.ORG Sun Nov 15 12:20:01 2009 Return-Path: Delivered-To: freebsd-bugs@hub.freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 8E3DB106566B for ; Sun, 15 Nov 2009 12:20:01 +0000 (UTC) (envelope-from gnats@FreeBSD.org) Received: from freefall.freebsd.org (freefall.freebsd.org [IPv6:2001:4f8:fff6::28]) by mx1.freebsd.org (Postfix) with ESMTP id 4E43B8FC16 for ; Sun, 15 Nov 2009 12:20:01 +0000 (UTC) Received: from freefall.freebsd.org (localhost [127.0.0.1]) by freefall.freebsd.org (8.14.3/8.14.3) with ESMTP id nAFCK1Kh097588 for ; Sun, 15 Nov 2009 12:20:01 GMT (envelope-from gnats@freefall.freebsd.org) Received: (from gnats@localhost) by freefall.freebsd.org (8.14.3/8.14.3/Submit) id nAFCK1kt097587; Sun, 15 Nov 2009 12:20:01 GMT (envelope-from gnats) Resent-Date: Sun, 15 Nov 2009 12:20:01 GMT Resent-Message-Id: <200911151220.nAFCK1kt097587@freefall.freebsd.org> Resent-From: FreeBSD-gnats-submit@FreeBSD.org (GNATS Filer) Resent-To: freebsd-bugs@FreeBSD.org Resent-Reply-To: FreeBSD-gnats-submit@FreeBSD.org, MURAMATSU Atsushi Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 17DA2106566B for ; Sun, 15 Nov 2009 12:11:25 +0000 (UTC) (envelope-from amura@tomato.sakura.ne.jp) Received: from tomato.sakura.ne.jp (tomato.sakura.ne.jp [210.188.226.72]) by mx1.freebsd.org (Postfix) with ESMTP id D1E778FC21 for ; Sun, 15 Nov 2009 12:11:24 +0000 (UTC) Received: from looxu.amura.dyndns.org (118x237x137x5.ap118.gyao.ne.jp [118.237.137.5]) (authenticated bits=0) by tomato.sakura.ne.jp (8.14.2/8.14.2/[SAKURA-WEB]/20080708) with ESMTP id nAFBIb8k014489 for ; Sun, 15 Nov 2009 20:18:37 +0900 (JST) (envelope-from amura@tomato.sakura.ne.jp) Received: by looxu.amura.dyndns.org (Postfix, from userid 1001) id 681E42E01E; Sat, 14 Nov 2009 07:49:39 +0900 (JST) Message-Id: <20091113224939.681E42E01E@looxu.amura.dyndns.org> Date: Sat, 14 Nov 2009 07:49:39 +0900 (JST) From: MURAMATSU Atsushi To: FreeBSD-gnats-submit@FreeBSD.org X-Send-Pr-Version: 3.113 Cc: Subject: kern/140567: [PATCH] ath is not worked on my notebook PC X-BeenThere: freebsd-bugs@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: MURAMATSU Atsushi List-Id: Bug reports List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sun, 15 Nov 2009 12:20:01 -0000 >Number: 140567 >Category: kern >Synopsis: [PATCH] ath is not worked on my notebook PC >Confidential: no >Severity: non-critical >Priority: low >Responsible: freebsd-bugs >State: open >Quarter: >Keywords: >Date-Required: >Class: sw-bug >Submitter-Id: current-users >Arrival-Date: Sun Nov 15 12:20:00 UTC 2009 >Closed-Date: >Last-Modified: >Originator: MURAMATSU Atsushi >Release: FreeBSD 8.0-PRERELEASE i386 >Organization: >Environment: System: FreeBSD looxu.amura.dyndns.org 8.0-PRERELEASE FreeBSD 8.0-PRERELEASE #0 r199241M: Sat Nov 14 05:41:55 JST 2009 root@looxu.amura.dyndns.org:/usr/src/sys/i386/compile/LOOXU i386 >Description: My notebook PC "Fujitsu LOOX U C40" has Athreos 9280 chip. Athreos 9280 is supported by FreeBSD's ath driver, but not worked collectly. Dmesg with AH_DEBUG option and hw.ath.hal.debug=0xffffff is attached this report. >How-To-Repeat: Add below kernel options into configulation file, and create kernel. Then boot with created kernel on Fujitsu LOOX U. device wlan options IEEE80211_AMPDU_AGE options IEEE80211_SUPPORT_MESH device wlan_wep device wlan_ccmp device wlan_tkip device wlan_amrr device ath device ath_hal options AH_SUPPORT_AR5416 device ath_rate_sample >Fix: I wrote a patch for sys/dev/ath/ath_hal/ah_regdomain.c. With this patch, ath is worked on my notebook. --- dmesg begins here --- Copyright (c) 1992-2009 The FreeBSD Project. Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 The Regents of the University of California. All rights reserved. FreeBSD is a registered trademark of The FreeBSD Foundation. FreeBSD 8.0-PRERELEASE #0 r199241M: Sat Nov 14 05:41:55 JST 2009 root@looxu.amura.dyndns.org:/usr/src/sys/i386/compile/LOOXU i386 Timecounter "i8254" frequency 1193182 Hz quality 0 CPU: Intel(R) Atom(TM) CPU Z530 @ 1.60GHz (1596.01-MHz 686-class CPU) Origin = "GenuineIntel" Id = 0x106c2 Stepping = 2 Features=0xbfe9fbff Features2=0x40c3bd> AMD Features=0x100000 AMD Features2=0x1 TSC: P-state invariant real memory = 1073741824 (1024 MB) avail memory = 1025724416 (978 MB) ACPI APIC Table: FreeBSD/SMP: Multiprocessor System Detected: 2 CPUs FreeBSD/SMP: 1 package(s) x 1 core(s) x 2 HTT threads cpu0 (BSP): APIC ID: 0 cpu1 (AP/HT): APIC ID: 1 .. snip .. pci8: on pcib3 ath0: mem 0xfd500000-0xfd50ffff irq 17 at device 0.0 on pci8 ath0: [ITHREAD] ar9280Attach: sc 0xc4111000 st 0x1 sh 0xc3f2d000 ar5416SetPowerMode: AWAKE -> AWAKE (set chip ) ar9280Attach: ID 0x852ff VERSION 0x2 TYPE 0x5 REVISION 0x2 ath_hal_v14EepromAttach Eeprom Magic = 0xa55a ath_hal_v14EepromAttach Eeprom Version 14.16 v14EepromReadCTLInfo Numctls = 21 ar5416SetPowerMode: AWAKE -> AWAKE (set chip ) ar9280RfAttach: attach AR9280 radio enableAniMIBCounters: Enable mib counters: OfdmPhyErrBase 0x0 cckPhyErrBase 0x0 ar9280Attach: return getchannels: cc 0 regDmn 0xf0 mode 0xffffff ecm isEepromValid: invalid regulatory domain/country code 0x6b getregstate: invalid EEPROM contents ath0: ath_getchannels: unable to collect channel list from hal, status 12 ar5416Detach: Detaching Ani Disable MIB counters ar5212SetPowerMode: AWAKE -> AWAKE (set chip ) ar5416SetPowerMode: AWAKE -> FULL-SLEEP (set chip ) device_attach: ath0 attach returned 22 --- dmesg ends here --- --- ah_regdomain.c.patch begins here --- Index: sys/dev/ath/ath_hal/ah_regdomain.c =================================================================== --- sys/dev/ath/ath_hal/ah_regdomain.c (revision 199241) +++ sys/dev/ath/ath_hal/ah_regdomain.c (working copy) @@ -170,6 +170,7 @@ WOR9_WORLD = 0x69, /* World9 (WO9 SKU) */ WORA_WORLD = 0x6A, /* WorldA (WOA SKU) */ + WORB_WORLD = 0x6B, /* WorldB (WOB SKU) */ MKK3_MKKB = 0x80, /* Japan UNI-1 even + MKKB */ MKK3_MKKA2 = 0x81, /* Japan UNI-1 even + MKKA2 */ @@ -432,6 +433,7 @@ {EU1_WORLD, EU1_WORLD, EU1_WORLD, NO_REQ, NO_REQ, PSCAN_DEFER, CTRY_DEFAULT }, {WOR9_WORLD, WOR9_WORLD, WOR9_WORLD, DISALLOW_ADHOC_11A | DISALLOW_ADHOC_11A_TURB, NO_REQ, PSCAN_DEFER, CTRY_DEFAULT }, {WORA_WORLD, WORA_WORLD, WORA_WORLD, DISALLOW_ADHOC_11A | DISALLOW_ADHOC_11A_TURB, NO_REQ, PSCAN_DEFER, CTRY_DEFAULT }, + {WORB_WORLD, WORB_WORLD, WORB_WORLD, DISALLOW_ADHOC_11A | DISALLOW_ADHOC_11A_TURB, NO_REQ, PSCAN_DEFER, CTRY_DEFAULT }, }; /* @@ -1681,6 +1683,30 @@ WG1_2467_2467), .chan11g_turbo = BM1(T3_2437_2437)}, + {.regDmnEnum = WORB_WORLD, + .conformanceTestLimit = NO_CTL, + .dfsMask = DFS_FCC3 | DFS_ETSI, + .pscan = PSCAN_WWR, + .flags = DISALLOW_ADHOC_11A, + .chan11a = BM3(W1_5260_5320, + W1_5180_5240, + W1_5500_5700), + .chan11b = BM7(W1_2412_2412, + W1_2437_2442, + W1_2462_2462, + W1_2472_2472, + W1_2417_2432, + W1_2447_2457, + W1_2467_2467), + .chan11g = BM7(WG1_2412_2412, + WG1_2437_2442, + WG1_2462_2462, + WG1_2472_2472, + WG1_2417_2432, + WG1_2447_2457, + WG1_2467_2467), + .chan11g_turbo = BM1(T3_2437_2437)}, + {.regDmnEnum = NULL1, .conformanceTestLimit = NO_CTL, } --- ah_regdomain.c.patch ends here --- >Release-Note: >Audit-Trail: >Unformatted: