From owner-freebsd-net@FreeBSD.ORG Mon May 28 08:37:36 2007 Return-Path: X-Original-To: freebsd-net@freebsd.org Delivered-To: freebsd-net@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id BDC9C16A4FB for ; Mon, 28 May 2007 08:37:36 +0000 (UTC) (envelope-from sepherosa@gmail.com) Received: from an-out-0708.google.com (an-out-0708.google.com [209.85.132.243]) by mx1.freebsd.org (Postfix) with ESMTP id 7F0FC13C4AD for ; Mon, 28 May 2007 08:37:36 +0000 (UTC) (envelope-from sepherosa@gmail.com) Received: by an-out-0708.google.com with SMTP id c14so450720anc for ; Mon, 28 May 2007 01:37:35 -0700 (PDT) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=FS7CyLLkzUS2Tka2PfjbhYjpkCtYVAukpo4+IrYxr9HAiEwNvzUBOHsstBGTnU9tKSeSNxJIkvrVPlQfCJb49ssEt+4zle3EbJa3qsHd/n6f5njFGAXShYyBE9GL0Sf0FFj3zunB6tj5RdzEGiuQWQd+UEmoEc3KNHEguU7M+OM= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=eKcZShWIpukJGXSFuRmE2YlPNdoquN7V/8UKpQUIjzE2uYtXTuYzbVcvXdLHp1X8aRKnzMJao0lgBbBakQ7Vk1RoiDzxdvJIaukyLIwtx/v4NhsZSoKmr9VNZQzGgKXhmfUPnwRqM8oV9HNKNDUNgDmWcWSIuIbkR9jl29T1ZUU= Received: by 10.100.33.14 with SMTP id g14mr4404953ang.1180341455568; Mon, 28 May 2007 01:37:35 -0700 (PDT) Received: by 10.100.47.5 with HTTP; Mon, 28 May 2007 01:37:35 -0700 (PDT) Message-ID: Date: Mon, 28 May 2007 16:37:35 +0800 From: "Sepherosa Ziehau" To: "Boris Kochergin" In-Reply-To: <465959FF.4040401@acm.poly.edu> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <465959FF.4040401@acm.poly.edu> Cc: freebsd-net@freebsd.org Subject: Re: System hang with Ralink RT2661 X-BeenThere: freebsd-net@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Networking and TCP/IP with FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Mon, 28 May 2007 08:37:36 -0000 On 5/27/07, Boris Kochergin wrote: > Hi. I got an "SMC SMCWPCI-GM" card the other day, which is one of these: > > May 27 01:16:55 router kernel: ral0: mem > 0xf4000000-0xf4007fff irq 10 at device 13.0 on pci0 > May 27 01:16:55 router kernel: ral0: MAC/BBP RT2661D, RF RT2529 (MIMO XR) > > I put it into a Pentium III machine (which has PCI 2.2, per the ral(4) > man page) running a 7-CURRENT build from earlier today with a GENERIC > kernel, and attempted to connect to my wireless network, the access > point of which is an Atheros 5212 card, which has been serving Prism and > other Atheros cards for months. The RT2661 card associated fine and was > able to carry out lightweight operations like pinging and HTTP requests, > but when I attempted to use it to send or receive any heavy traffic (a > few dozen KiB/second), the system froze. I was able to toggle the caps > lock/num lock lights, and if I did something to make the system beep > (i.e. by pressing ALT+F10 when there was no virtual terminal running > there), the beep would ring out endlessly. It may also be worth > mentioning that the system was unresponsive to ACPI (via the power > button) and that the same RT2661 card in the same machine has no trouble > sniffing over 2 MiB/second of traffic via tcpdump. I'll be happy to > provide any other information that may be deemed useful. Thanks. Try changing ~line160 of dev/ral/rt2661reg.h From #define RT2661_SHORT_PREAMBLE (1 << 19) #define RT2661_MRR_ENABLED (1 << 20) #define RT2661_MRR_CCK_FALLBACK (1 << 23) to #define RT2661_SHORT_PREAMBLE (1 << 18) #define RT2661_MRR_ENABLED (1 << 19) #define RT2661_MRR_CCK_FALLBACK (1 << 22) This will make the situation better. Except the above wrongly configured MMR register values, rt2661 parts' TX intr processing is completely wrong; The channel TX power is incorrect too, for 11bg the difference between the correct one and the value that driver is using is small, but for 11a, the channel TX power will be completely wrong. Best Regards, sephe -- Live Free or Die