From owner-freebsd-current@FreeBSD.ORG Tue Nov 2 23:34:07 2004 Return-Path: Delivered-To: freebsd-current@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id C3B6F16A4CE for ; Tue, 2 Nov 2004 23:34:07 +0000 (GMT) Received: from mailgate1b.savvis.net (mailgate1b.savvis.net [216.91.182.6]) by mx1.FreeBSD.org (Postfix) with ESMTP id 29B7243D3F for ; Tue, 2 Nov 2004 23:34:07 +0000 (GMT) (envelope-from Maksim.Yevmenkin@savvis.net) Received: from out002.email.savvis.net (out002.apptix.savvis.net [216.91.32.45])iA2NY3CV004232; Tue, 2 Nov 2004 17:34:03 -0600 Received: from s228130hz1ew17.apptix-01.savvis.net ([10.146.4.29]) by out002.email.savvis.net with Microsoft SMTPSVC(6.0.3790.211); Tue, 2 Nov 2004 17:33:58 -0600 Received: from [10.254.186.111] ([66.35.239.94]) by s228130hz1ew17.apptix-01.savvis.net with Microsoft SMTPSVC(6.0.3790.211); Tue, 2 Nov 2004 17:33:51 -0600 Message-ID: <4188195B.5060502@savvis.net> Date: Tue, 02 Nov 2004 15:33:47 -0800 From: Maksim Yevmenkin User-Agent: Mozilla/5.0 (X11; U; FreeBSD i386; en-US; rv:1.7.2) Gecko/20040822 X-Accept-Language: en-us, en MIME-Version: 1.0 To: Niki Denev References: <416DB569.4010805@savvis.net> <416DC1E5.1060904@savvis.net> <4187E594.5080306@savvis.net> In-Reply-To: Content-Type: text/plain; charset=us-ascii; format=flowed Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 02 Nov 2004 23:33:51.0458 (UTC) FILETIME=[68D6BC20:01C4C134] X-ECS-MailScanner: No virus is found cc: current@freebsd.org Subject: Re: bluetooth / hcseriald panics -current. X-BeenThere: freebsd-current@freebsd.org X-Mailman-Version: 2.1.1 Precedence: list List-Id: Discussions about the use of FreeBSD-current List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 02 Nov 2004 23:34:08 -0000 Niki, > i have applied the patch and now the panic is gone, but my console gets > filled with stuff like that : > > WARNING: Network stack Giant-free, but ng_h4 requires Giant. > ng_h4_input: sio4 - line error 0x1000000, c=0xc0 > ng_h4_input: sio4 - line error 0x1000000, c=0x1 > ng_h4_input: sio4 - line error 0x1000000, c=0xa > ng_h4_input: sio4 - line error 0x1000000, c=0x9 > ng_h4_input: sio4 - ignoring unknown packet type=0x90 > ng_h4_input: sio4 - ignoring unknown packet type=0xa5 > ng_h4_input: sio4 - ignoring unknown packet type=0x8f > ng_h4_input: sio4 - ignoring unknown packet type=0xaf > ng_h4_input: sio4 - ignoring unknown packet type=0x57 > ng_h4_input: sio4 - line error 0x1000000, c=0x17 > ng_h4_input: sio4 - ignoring unknown packet type=0xd8 > ng_h4_input: sio4 - line error 0x1000000, c=0xc0 > ng_h4_input: sio4 - line error 0x1000000, c=0x1 > ng_h4_input: sio4 - line error 0x1000000, c=0xa > ng_h4_input: sio4 - line error 0x1000000, c=0x9 > ng_h4_input: sio4 - ignoring unknown packet type=0x90 > ng_h4_input: sio4 - ignoring unknown packet type=0xa5 > ng_h4_input: sio4 - ignoring unknown packet type=0x8f > ng_h4_input: sio4 - ignoring unknown packet type=0xaf > ng_h4_input: sio4 - ignoring unknown packet type=0x57 > ng_h4_input: sio4 - line error 0x1000000, c=0x17 > ng_h4_input: sio4 - ignoring unknown packet type=0xd8 > ng_h4_input: sio4 - line error 0x1000000, c=0xc0 that is what happens when fifo is not drained completely in time :( you should also see messages about "silo overflow" as well. as i explained before this is an interrupt latency problem. bluetooth links normally operate at up to 400 kb/s speed (symmetric asynchronous channel). and yet some (most?) manufacturers put 16550 uarts with 16 bytes fifo on those cards. to make things worse no flow control is implemented :( h4 was not designed for links that drop bytes. bluetooth spec requires to reset device every time there is a synchronization loss is detected. ng_h4(4) does not reset the device (too extreme) instead it just tries to re-synchronize. so the things you can try: 1) get a much faster cpu :) 2) disable WITNESSxxx and INVARIANTSxxx; 3) try to convince your system to allocate separate irq to the bluetooth card; 4) try to convince sio(4) driver to activate interrupts in FAST mode. max