From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mailman by lists.gnu.org with archive (Exim 4.43) id 1FcMxE-0000Lm-6L for mharc-grub-devel@gnu.org; Sat, 06 May 2006 09:36:16 -0400 Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1FcMxB-0000If-CJ for grub-devel@gnu.org; Sat, 06 May 2006 09:36:13 -0400 Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1FcMx7-0000EW-Io for grub-devel@gnu.org; Sat, 06 May 2006 09:36:12 -0400 Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1FcMx7-0000ER-Bv for grub-devel@gnu.org; Sat, 06 May 2006 09:36:09 -0400 Received: from [155.198.117.152] (helo=crumpet.cpn.ee.ic.ac.uk) by monty-python.gnu.org with esmtps (TLS-1.0:RSA_AES_256_CBC_SHA:32) (Exim 4.52) id 1FcMxV-0001D2-Fn for grub-devel@gnu.org; Sat, 06 May 2006 09:36:33 -0400 Received: from localhost ([127.0.0.1]) by crumpet.cpn.ee.ic.ac.uk with esmtp (Exim 4.44) id 1FcMx4-00038s-Bd for grub-devel@gnu.org; Sat, 06 May 2006 14:36:06 +0100 Message-ID: <445CA646.7010704@imperial.ac.uk> Date: Sat, 06 May 2006 14:36:06 +0100 From: vincent guffens User-Agent: Mozilla Thunderbird 1.0.7 (X11/20051013) X-Accept-Language: en-us, en MIME-Version: 1.0 To: The development of GRUB 2 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Subject: pci support X-BeenThere: grub-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list Reply-To: The development of GRUB 2 List-Id: The development of GRUB 2 List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Sat, 06 May 2006 13:36:13 -0000 Hi! I was wondering if there was still an interest in pci support as discussed previously. That is a general interface exported by a module such as struct grub_pci_support { /* My name. */ const char *name; void (*init)(void); void (*fini)(void); void (*adjust) (grub_pci_device_t p); /* Base Address Register helper functions. There are up to 6 BARs PCI_BASE_ADDRESS_{[0-5]} in the configuration space of each device */ unsigned long (*bar_start) (grub_pci_device_t, unsigned int bar); unsigned long (*bar_size) (grub_pci_device_t, unsigned int bar); int (*find_capability) (grub_pci_device_t, int cap); /* Call HOOK with each pci device. */ grub_err_t (*iterate) (int (*hook) (grub_pci_device_t)); /* Fill the pci device structure (romaddr, ioaddr, membase, irq)*/ grub_err_t (*init_pdev) (grub_pci_device_t); /* Low level io functions. */ struct grub_pci_io_support *io; }; which allows multiple implementations such as one for instance from etherboot which I have now. It was written original with the idea of importing the etherboot drivers so I don't know if it would still be usefull. The implementation that I have uses direct pci access which maybe does not fit very well with the idea of using pxe later on as it will require dealing with some bios stuff anyway. It is basically usefull now for the lspci command which could be made to print some nice text just like the Linux lspci command. If so, I can prepare a separated patch for it and prepare the changelog. Cheers, -- Vincent Guffens