From owner-freebsd-current Thu Jan 30 13: 4:13 2003 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 C8DAB37B401 for ; Thu, 30 Jan 2003 13:04:11 -0800 (PST) Received: from hal-4.inet.it (hal-4.inet.it [213.92.5.23]) by mx1.FreeBSD.org (Postfix) with ESMTP id 0392343F93 for ; Thu, 30 Jan 2003 13:04:10 -0800 (PST) (envelope-from andrea@webcom.it) Received: from [::ffff:213.92.1.165] by hal-4.inet.it via I-SMTP-4.3.6-430 id ::ffff:213.92.1.165+5dtUdrFM3nGu; Thu, 30 Jan 2003 22:04:03 +0100 Received: from webcom.it (brian.inet.it [213.92.1.190]) by acampi.inet.it (Postfix) with SMTP id CE8CC1554D for ; Thu, 30 Jan 2003 22:04:01 +0100 (CET) Received: (qmail 4063 invoked by uid 1000); 30 Jan 2003 21:04:01 -0000 Date: Thu, 30 Jan 2003 22:04:01 +0100 From: Andrea Campi To: Terry Lambert Cc: "M. Warner Losh" , Hidetoshi Shimokawa , current@FreeBSD.ORG Subject: Re: firewire hangs on Thinkpad Message-ID: <20030130210401.GA715@webcom.it> References: <20030124144823.GA600@webcom.it> <20030125.115501.13766238.imp@bsdimp.com> <20030129114951.GA3635@webcom.it> <3E385236.29718458@mindspring.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <3E385236.29718458@mindspring.com> X-Echelon: BND CIA NSA Mossad KGB MI6 IRA detonator nuclear assault strike User-Agent: Mutt/1.5.3i 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 On Wed, Jan 29, 2003 at 02:14:14PM -0800, Terry Lambert wrote: > I expect that the attach of the device creates an interrupt if > the system is already up. This would indicate that it was an > order of operations problem in the driver registration for a > "live" piece of hardware. Probably, it needs to attach the Unless I'm really mistaken, that's not the case: From fwohci_pci.c: rid = 0; sc->irq_res = bus_alloc_resource(self, SYS_RES_IRQ, &rid, 0, ~0, 1, RF_SHAREABLE | RF_ACTIVE); ... err = bus_setup_intr(self, sc->irq_res, INTR_TYPE_NET, (driver_intr_t *) fwohci_intr, sc, &sc->ih); ... err = fwohci_init(sc, self); if (!err) err = device_probe_and_attach(sc->fc.bdev); fwohci_init then proceeds to muck with the hardware, and finally: fw_init(&sc->fc); fwohci_reset(sc, dev); fwohci_reset does its business, then: /* Enable interrupt */ OWRITE(sc, FWOHCI_INTMASK, OHCI_INT_ERR | OHCI_INT_PHY_SID | OHCI_INT_DMA_ATRQ | OHCI_INT_DMA_ATRS | OHCI_INT_DMA_PRRQ | OHCI_INT_DMA_PRRS | OHCI_INT_PHY_BUS_R | OHCI_INT_PW_ERR); fwohci_set_intr(&sc->fc, 1); So no, you guessed wrong this time Terry ;-) Bye, Andrea -- Reboot America. To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message