From owner-freebsd-hackers@FreeBSD.ORG Wed Apr 11 16:38:26 2007 Return-Path: X-Original-To: hackers@freebsd.org Delivered-To: freebsd-hackers@FreeBSD.ORG Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 2693516A405 for ; Wed, 11 Apr 2007 16:38:26 +0000 (UTC) (envelope-from xcllnt@mac.com) Received: from smtpout.mac.com (smtpout.mac.com [17.250.248.173]) by mx1.freebsd.org (Postfix) with ESMTP id 190CD13C484 for ; Wed, 11 Apr 2007 16:38:26 +0000 (UTC) (envelope-from xcllnt@mac.com) Received: from mac.com (smtpin04-en2 [10.13.10.149]) by smtpout.mac.com (Xserve/smtpout03/MantshX 4.0) with ESMTP id l3BGQtIZ024303; Wed, 11 Apr 2007 09:26:59 -0700 (PDT) Received: from [192.168.1.3] (c-24-6-177-228.hsd1.ca.comcast.net [24.6.177.228]) (authenticated bits=0) by mac.com (Xserve/smtpin04/MantshX 4.0) with ESMTP id l3BGQqWg027891 (version=TLSv1/SSLv3 cipher=AES128-SHA bits=128 verify=NO); Wed, 11 Apr 2007 09:26:53 -0700 (PDT) In-Reply-To: <461CCB3D.1090402@fromorbit.com> References: <200704110951.l3B9p4hT024402@sana.init-main.com> <461CCB3D.1090402@fromorbit.com> Mime-Version: 1.0 (Apple Message framework v752.3) Content-Type: text/plain; charset=US-ASCII; delsp=yes; format=flowed Message-Id: Content-Transfer-Encoding: 7bit From: Marcel Moolenaar Date: Wed, 11 Apr 2007 08:45:10 -0700 To: Alan Garfield X-Mailer: Apple Mail (2.752.3) X-Brightmail-Tracker: AAAAAA== X-Brightmail-scanned: yes Cc: hackers@freebsd.org Subject: Re: Resources and ACPI X-BeenThere: freebsd-hackers@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Technical Discussions relating to FreeBSD List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 11 Apr 2007 16:38:26 -0000 On Apr 11, 2007, at 4:49 AM, Alan Garfield wrote: >>> are these resources automagically allocated for me? Or do I have to >>> allocate them myself? >> You have to allocate the resource. > > Ok cool, but how do I get the resource list from acpi to allocated > them then? Other than having an array of ioports and irqs, is there > a way to get this information from acpi? The device driver knows about the hardware and as such knows what resources it needs and/or what resources the hardware makes available. You allocate what you need. Use the resource ID in combination with resource type to get what you want. If you try to allocate something that's not there, then you have a new situation that the driver needs to know about and you code accordingly. HTH, -- Marcel Moolenaar xcllnt@mac.com