From owner-freebsd-current@FreeBSD.ORG Sat Mar 27 16:14:34 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 38DF016A4CE; Sat, 27 Mar 2004 16:14:34 -0800 (PST) Received: from harmony.village.org (rover.bsdimp.com [204.144.255.66]) by mx1.FreeBSD.org (Postfix) with ESMTP id BA1F243D2F; Sat, 27 Mar 2004 16:14:33 -0800 (PST) (envelope-from imp@bsdimp.com) Received: from localhost (warner@rover2.village.org [10.0.0.1]) by harmony.village.org (8.12.10/8.12.9) with ESMTP id i2S0EAkj067390; Sat, 27 Mar 2004 17:14:10 -0700 (MST) (envelope-from imp@bsdimp.com) Date: Sat, 27 Mar 2004 17:14:16 -0700 (MST) Message-Id: <20040327.171416.00453245.imp@bsdimp.com> To: scottl@freebsd.org From: "M. Warner Losh" In-Reply-To: <20040319180056.A30715@pooker.samsco.home> References: <20040319163324.X30715@pooker.samsco.home> <20040319180056.A30715@pooker.samsco.home> X-Mailer: Mew version 3.3 on Emacs 21.3 / Mule 5.0 (SAKAKI) Mime-Version: 1.0 Content-Type: Text/Plain; charset=iso-8859-1 Content-Transfer-Encoding: quoted-printable cc: des@des.no cc: freebsd-current-local@be-well.no-ip.com cc: current@freebsd.org Subject: Re: agp0 hang in 5.2.1-RELEASE 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: Sun, 28 Mar 2004 00:14:34 -0000 In message: <20040319180056.A30715@pooker.samsco.home> Scott Long writes: : On Sat, 20 Mar 2004, Dag-Erling [iso-8859-1] Sm=F8rgrav wrote: : > Scott Long writes: : > > On Fri, 19 Mar 2004, Dag-Erling [iso-8859-1] Smrgrav wrote: : > > > set hint.agp.0.disabled=3D"1" : > > I don't see any code in the agp drivers to look at this hint. Is= this : > > impleneted some other way? : > : > Doesn't newbus automatically take care of that? : > : > DES : = : No. This has been debated occasionally, but has some landmines. New= bus : doesn't know what 'agp0' is until the probe bidding is complete. So y= ou : can really only disable the attach, not the probe. But what if the p= robe : is destructive or buggy? You're then left to telling the parent of t= he : device (usually a bus) to ignore the device. For PCI, this requires = that : the user know the bus, device, and function numbers. This is : inconvenient, but not impossible. Unfortunately, this also means tha= t : every bus type might have different identifiers, and no one has come = up : with a mechanism yet that can be logically extended to these arbitrar= y bus : types. That's not quite true. Maybe desirable, but not true for newbus. newbus doesn't deal with bus selectors or pnp information, only unit numbers. So don't even go there if you want newbus to do it automatically :-). : Maybe handling the attach phase and ignoring the probe phase is good : enough for now. Feel free to propose something =3D-) I've actually hacked together something that should do the right thing, but haven't extensively tested it. If the probe succeeds, it checks to see if the device is disabled, and if so it doesn't call attach. This way it would be possible to disable cbb0 but still have cbb1 in the same location it always is at. You also need a way to disable the driver completely, which I'm also implementing... Warner