From owner-freebsd-hackers Mon Aug 9 19:25: 6 1999 Delivered-To: freebsd-hackers@freebsd.org Received: from bingnet2.cc.binghamton.edu (bingnet2.cc.binghamton.edu [128.226.1.18]) by hub.freebsd.org (Postfix) with ESMTP id EC19915344 for ; Mon, 9 Aug 1999 19:24:59 -0700 (PDT) (envelope-from zzhang@cs.binghamton.edu) Received: from sol.cs.binghamton.edu (cs1-gw.cs.binghamton.edu [128.226.171.72]) by bingnet2.cc.binghamton.edu (8.9.3/8.9.3) with SMTP id WAA11443 for ; Mon, 9 Aug 1999 22:21:18 -0400 (EDT) Date: Mon, 9 Aug 1999 22:08:16 -0400 (EDT) From: Zhihui Zhang To: freebsd-hackers@freebsd.org Subject: Configuration mechanism of PCI bus Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=US-ASCII Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Even with "PCI System Architecture, 4th edition" at hand, I still have some problems understanding the code in isa/pcibus.c. Please point out any misunderstanding I may have in the following: (1) At first, you can not modify the address port at 0xcf8 without a FULL 32-bit write. The routine pci_cfgopen() seems to use this fact. (2) The constant CONF1_ENABLE_MSK includes 4 higher bus number bits, only 4 bits can be used as bus number, so we can have at most 16 PCI buses. (3) The variable "mode1res" seems to refer to any residual left by BIOS in the address port. If it is non-zero, we will try to find a device using configuration mechanism 1. (3) The magic constant 0xf870ff excludes many devices. How it is chosen? I guess those excluded devices are not important or supported by FreeBSD. It seems to me that if pci_cfgcheck() finds at least one device, then the configuration mechanism is regarded as correctly detected. Any help is appreciated. -------------------------------------------------- Zhihui Zhang. Please visit http://www.freebsd.org -------------------------------------------------- To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message