From owner-freebsd-new-bus Tue May 9 1:41:19 2000 Delivered-To: freebsd-new-bus@freebsd.org Received: from tele-post-20.mail.demon.net (tele-post-20.mail.demon.net [194.217.242.20]) by hub.freebsd.org (Postfix) with ESMTP id E559837B56A; Tue, 9 May 2000 01:41:08 -0700 (PDT) (envelope-from dfr@nlsystems.com) Received: from nlsys.demon.co.uk ([158.152.125.33] helo=herring.nlsystems.com) by tele-post-20.mail.demon.net with esmtp (Exim 2.12 #2) id 12p5Zi-000NxC-0K; Tue, 9 May 2000 08:41:07 +0000 Received: from salmon.nlsystems.com (salmon.nlsystems.com [10.0.0.3]) by herring.nlsystems.com (8.9.3/8.8.8) with ESMTP id JAA19039; Tue, 9 May 2000 09:44:12 +0100 (BST) (envelope-from dfr@nlsystems.com) Date: Tue, 9 May 2000 09:45:49 +0100 (BST) From: Doug Rabson To: "John H. Baldwin" Cc: freebsd-new-bus@freebsd.org, jhb@freebsd.org, n_hibma@freebsd.org Subject: Re: Alpha USB difficulties... In-Reply-To: Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-new-bus@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Mon, 8 May 2000, John H. Baldwin wrote: > On Mon, 8 May 2000, John Baldwin wrote: > > > On Sat, 6 May 2000, John Baldwin wrote: > > > > > Well, I know this is rather a long shot, but I have a test > > > machine that can be beat on for a week to try to get some Alpha > > > stuff nailed down, and one of the things I wanted to test was > > > USB. The machine in question is a brand new Alphastation XP900. > > > SRM doesn't support USB at the moment, but I figured that our > > > support should function at least. Here's what I get when I boot > > > the system up: > > > > > > FreeBSD 4.0-RELEASE #0: Fri May 5 22:54:02 EDT 2000 > > > jhb@doberman.cslab.vt.edu:/usr/src/sys/compile/DOBERMAN > > > ST6600 > > > COMPAQ AlphaStation XP900 466 MHz, 462MHz > > > 8192 byte page size, 1 processor. > > > CPU: EV6 (21264) major=8 minor=4 extensions=0x303 > > > OSF PAL rev: 0x100360002013e > > > .... > > > pcib0: <21271 PCI host bus adapter> on tsunami0 > > > pci0: on pcib0 > > > ohci0: mem 0x20d0000-0x20d0fff irq 234 at device 1.0 on > > pci0 > > > ohci0: could not allocate irq > > > device_probe_and_attach: ohci0 attach returned 12 > > > > > > Thus, it seems to be the classic problem that is solved on PC > > > systems by toggling the PnP OS support in the BIOS. Mike > > > Smith said that we don't currently know how to allocate an IRQ > > > to a device on the Alpha, but I thought I'd run this by you since > > > I do have access to a test machine that can be beat up for a week. > > > > The USB hardware on this platform interrupts via the ISA pic. SRM > > represents this as an interrupt pin of 0xe0 + isa irq no. Unfortunately I > > have not put in support in the alpha pci code to recognise this so the > > interrupt allocation fails. The place to add this support is probably > > pci_alloc_resource() in sys/alpha/pci/pcibus.c. > > Well, I have a patch that does this at least somewhat. It is available at > www.freebsd.org/~jhb/patches/alpha.usb.patch. It assumes that all Alpha's > use the range 0xe0 - 0xef for ISA IRQ's, or rather, that if a set of IRQ's > fall in that range on an Alpha, then they are really hints for ISA > IRQ's. However, it seems that although I can now get this far: > > ... > > The interrupts don't seem to be delivered properly. Thus, I can't get the > keyboard to work, usbd takes a while (several seconds) to start, usbdevs > also runs with delays, and no kernel messages are generated when I > add/delete items to the USB tree. Any ideas, suggetions, etc. would be > greatly appreciated. I lose access to this machine on Friday, so.... :) There is already a function isa_alloc_intr() which does most of what you need so perhaps you don't need to add isa_alloc_intrs(). On the other hand, your function is slightly more general. To make interrupt delivery work, you also need to hook pci_setup_intr and pci_teardown_intr and vector them to the isa functions too. -- Doug Rabson Mail: dfr@nlsystems.com Nonlinear Systems Ltd. Phone: +44 20 8442 9037 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-new-bus" in the body of the message