From owner-freebsd-current Tue Apr 20 1:47:16 1999 Delivered-To: freebsd-current@freebsd.org Received: from herring.nlsystems.com (nlsys.demon.co.uk [158.152.125.33]) by hub.freebsd.org (Postfix) with ESMTP id C45FE14CD4 for ; Tue, 20 Apr 1999 01:47:07 -0700 (PDT) (envelope-from dfr@nlsystems.com) Received: from localhost (dfr@localhost) by herring.nlsystems.com (8.9.3/8.8.8) with ESMTP id JAA94897; Tue, 20 Apr 1999 09:47:58 +0100 (BST) (envelope-from dfr@nlsystems.com) Date: Tue, 20 Apr 1999 09:47:58 +0100 (BST) From: Doug Rabson To: Luoqi Chen Cc: jhay@mikom.csir.co.za, peter@netplex.com.au, current@freebsd.org Subject: Re: newbus and isa auto irq In-Reply-To: <199904191821.OAA05777@lor.watermarkgroup.com> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG On Mon, 19 Apr 1999, Luoqi Chen wrote: > > This is not happening for the maddr stuff. > > I suspect this would do better: > > > > if (portsize > 0) > > isa_set_portsize(dev, portsize); > > if (dvp->id_iobase >= 0) > > isa_set_port(dev, dvp->id_iobase); > > if (dvp->id_irq != 0) > > isa_set_irq(dev, ffs(dvp->id_irq) - 1); > > if (dvp->id_drq != -1) > > isa_set_drq(dev, dvp->id_drq); > > if (dvp->id_maddr != 0) > > isa_set_maddr(dev, > > (int) dvp->id_maddr - KERNBASE); > > if (dvp->id_msize != 0) > > isa_set_msize(dev, dvp->id_msize); > > I'm not sure about the "nothing" value for id_drq though, it might need to > > be 0 - but that's a valid dma channel. > > > > IMHO, isa_release_resources() clearing of the default values for the probe > > hints is a timebomb... I thought about adding a seperate store for the > > "hint" values rather than using the id_foo[0] entries, and leaving the > > tracked resource entries for alloc/free without risking the hints. > > > > Cheers, > > -Peter > > > Off the topic, I think we should replace (dvp->id_maddr - KERNBASE) with > kvtop(dvp->id_maddr), too much assumption about vm layout... I agree. I think your fix for the irq problem is the correct one too. -- Doug Rabson Mail: dfr@nlsystems.com Nonlinear Systems Ltd. Phone: +44 181 442 9037 To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message