From owner-freebsd-current Mon Aug 12 10:22:11 2002 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 4242237B400 for ; Mon, 12 Aug 2002 10:22:07 -0700 (PDT) Received: from scl8owa02.int.exodus.net (scl8out02.exodus.net [66.35.230.242]) by mx1.FreeBSD.org (Postfix) with ESMTP id B5BFD43E7B for ; Mon, 12 Aug 2002 10:21:46 -0700 (PDT) (envelope-from Maksim.Yevmenkin@exodus.net) Received: from scl8owa01.int.exodus.net ([66.35.230.241]) by scl8owa02.int.exodus.net with Microsoft SMTPSVC(5.0.2195.4905); Mon, 12 Aug 2002 10:23:20 -0700 Received: from exodus.net ([206.220.227.147]) by scl8owa01.int.exodus.net over TLS secured channel with Microsoft SMTPSVC(5.0.2195.4905); Mon, 12 Aug 2002 10:23:19 -0700 Message-ID: <3D57EEA5.96D397CC@exodus.net> Date: Mon, 12 Aug 2002 10:21:41 -0700 From: Maksim Yevmenkin X-Mailer: Mozilla 4.78 [en] (X11; U; SunOS 5.7 sun4u) X-Accept-Language: en MIME-Version: 1.0 To: "M. Warner Losh" Cc: current@FreeBSD.ORG Subject: Re: Interrupt vs. polling on -current References: <3D540794.E487F2F4@exodus.net> <20020811.172933.13462313.imp@bsdimp.com> Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit X-OriginalArrivalTime: 12 Aug 2002 17:23:19.0798 (UTC) FILETIME=[F3E5E160:01C24224] Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG "M. Warner Losh" wrote: > > [[ I've read the rest of this thread ]] > > In message: <3D540794.E487F2F4@exodus.net> > Maksim Yevmenkin writes: > : My tests are very simple. I plug USB dongle and one PC-CARD > : and try to pump data between them as fast as possible. The > : data blocks sizes are between 63 and 1500 bytes. > > I think that the issue here may be that the USB stack may be > interacting badly with the interrupt system. Since the pccard is > effectively forced into sharing the interrupt with the USB stack with > NEWCARD, that's going to interact very badly, I think. Worse even > than if you were multiplexing the xl0 driver and the sio0 driver. you may be right. i have "uhci" USB controller (i think it is Intel spec.). If i'm not mistaken this chip is not very smart, and every time interrupt happens software must scan queue of pending requests to find out which one has been completed. But of course "uhci" chip is very cheap :) On the other hand there is a "ohci" (Microsoft i think) and this chip is better because it does more processing, and, of course costs more. > The sio driver is extremely sensitive to the interrupt latency, since > the underlying hardware has only a few characters to react before the > fifo overflows. At 115200 baud, each character takes 1/11520 seconds > (or 86us), and the fifo is set to have only 8 bytes left when the > device interrupts. This means that the sio driver can only tolerate > about 700us of latency before there are issues. With 500 interrupts > per second, that's an interrupt every 2000us, which is about the same > "order" as the maximum latency tolerance. If these interrupts are > shared and are taking a while to allow the serial driver to run, then > you are almost certain to cause problems. Xircom card is a Bluetooth card with UART interface. Bluetooth link speed is about 700KB/s. I do not think that standard 16550A UART with 16 bytes FIFO can handle such speed. I also can not believe that Xircom would sell such low speed Bluetooth card (115200 bit/s). I think that Xircom card must have a much bigger FIFO in order to handle full speed. W2K, for example, has special driver for Xircom card. > For cardbus cards, we're forced to use the pci interrupt and share it. > For "r2" cards (aka 16-bit cards), we could use an unused ISA > interrupt on most (but not all) cardbus bridges, but currently there's > no support for that in NEWCARD. that is what i see in W2K. all cards i plug into slots get different irq. PC-CARD controller and USB controller are still share irq 11. > I'm also surprised you were able to make it work at all. I've had > lots of bad luck when trying to make modems work in recent -current > kernels. that is very sad :( thanks, max To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message