From owner-freebsd-bugs Wed Jun 19 17:51: 8 2002 Delivered-To: freebsd-bugs@hub.freebsd.org Received: from freefall.freebsd.org (freefall.FreeBSD.org [216.136.204.21]) by hub.freebsd.org (Postfix) with ESMTP id C871C37B40B for ; Wed, 19 Jun 2002 17:50:02 -0700 (PDT) Received: (from gnats@localhost) by freefall.freebsd.org (8.11.6/8.11.6) id g5K0o2339748; Wed, 19 Jun 2002 17:50:02 -0700 (PDT) (envelope-from gnats) Date: Wed, 19 Jun 2002 17:50:02 -0700 (PDT) Message-Id: <200206200050.g5K0o2339748@freefall.freebsd.org> To: freebsd-bugs@FreeBSD.org Cc: From: "Jin Guojun[DSD]" Subject: Re: kern/39449: wierd ata status Reply-To: "Jin Guojun[DSD]" Sender: owner-freebsd-bugs@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.org The following reply was made to PR kern/39449; it has been noted by GNATS. From: "Jin Guojun[DSD]" To: cjclark@alum.mit.edu Cc: bug-followup@freebsd.org Subject: Re: kern/39449: wierd ata status Date: Wed, 19 Jun 2002 17:40:42 -0700 This is a multi-part message in MIME format. --------------8F41AE8DFFD88B677B4F70F9 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit "Crist J. Clark" wrote: > > On Wed, Jun 19, 2002 at 04:20:36PM -0700, Jin Guojun[DSD] wrote: > > "Crist J. Clark" wrote: > > > > > > On Wed, Jun 19, 2002 at 01:45:02PM -0700, Jin Guojun[DSD] wrote: > > > > "Crist J. Clark" wrote: > > > > > > > > > > On Wed, Jun 19, 2002 at 01:03:17AM -0700, Jin Guojun[DSD] wrote: > > > > > [snip] > > > > > > > > > > > I am not able to access these machines till Friday. > > > > > > Unless you think the regular dmesg will help, I will send you full message > > > > > > with "boot -v" on Friday. > > > > > > > > > > The regular boot messages may help. > > > > > > > > Below is dmesg from 4.6 machine, and a set of -v message from a 4.5 > > > > machine with the identical hardware we used before. > > > > The message of 4.6 and the first message of 4.5 are from customer built > > > > kernel, which has ata1 disabled in kernel config file. The 4.5 has no ata1 > > > > configured, but 4.6 has ata1 configured. > > > > > > > > The rest of messages of 4.5 is from GENERIC kernel (original from > > > > the installation) with following conditions: > > > > > > > > #2, just -v option. We see both ata0 and ata1 configured. > > > > > > > > #3, the secondary IDE is disbaled in BIOS, and ata1 is not configured. > > > > #4, the disk is removed from the secondary IDE bus, and ata1 is not > > > > configured. > > > > > > > > So, in 4.5, we have muliplte ways to disble ata1, but in 4.6 we have none. > > > > > > OK, I think the dmesg(8) shows what I think is going on. You never > > > "disabled" ata1 in 4.5-RELEASE by doing anything to the kernel > > > configuration. In 4.5-RELEASE, if there was no hardware attached to > > > ata1, the probe turns up nothing, > > > > > > > #3 ----------- GENERIC kernel with second IDE disabled in BIOS ------ > > > > Copyright (c) 1992-2002 The FreeBSD Project. > > > > Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 > > > > The Regents of the University of California. All rights reserved. > > > > FreeBSD 4.5-RELEASE #0: Mon Jan 28 14:31:56 GMT 2002 > > > > murray@builder.freebsdmall.com:/usr/src/sys/compile/GENERIC > > > [snip] > > > > ata1: iobase=0x0170 altiobase=0x0376 bmaddr=0xd808 > > > > ata1: mask=00 status0=ff status1=ff > > > > ata1: probe allocation failed > > > > > > But it is still probed. You are not disabling it in the kernel > > > configuration, it is disabling itself when no devices are found. > > > > > > In 4.6-RELEASE, we have support for removable ATA devices. Even if > > > ata1 doesn't have anything when probed at boot, we want to attach the > > > device in order to have it available for swapping devices. > > > > > > So, to summarize, you have never had the ability to disable PCI ATA > > > devices in the kernel configuration. However, in 4.5-RELEASE, ata(4) > > > devices with nothing attached to them were not allocated resources. In > > > 4.6-RELEASE, ata(4) devices are allocated in order to support > > > removable devices (which is totally wicked-cool BTW, see > > > atacontrol(8)). > > > > It is good to support removable devices. But remember that in 4.5 we have > > two ways to disable ata1: > > (1) no device attached > > or > > (2) disbale the secondary IDE in BIOS. > > No, you couldn't. Only ISA devices. > > > If 4.6 or later could distinguish these two cases, it will make this > > feature more useful. If users want to use removeable devices, enable > > the IDE in BIOS, but leave devices either attached or unattached; > > if users do not want to use IDE at all, disable IDE in BIOS. > > > > I do not see why this cannot be implemented as in 4.5. > > It wasn't. If you can show me dmesg(8) output where you have a device > attached to a PCI ata1 and it is not detected, I would be > suprised. None of the dmesg(8) outputs that you showed were this case. Attached again "x". Look at the #3, which had exact things configured as #2 except the secondary IDE is disabled in BIOS. Yes, it probably looks very similar as the #4, which had disk drive unpluged. Search and read the title line start with #[2-4] --------- description --------- #2 --------- GENERIC (original) kernel ------ #3 ----------- GENERIC kernel with second IDE disabled in BIOS ------ #4 ----------- GENERIC kernel without anything on ATA1 ------ Do vi and search at attached file to find descriptions. /^#[2-4] ---- I am using FreeBSD for more than 10 years, and disable the second IDE all the time to use the IRQ 15. I have no interest to make a joke here. To make sure this is not a mistake, I retried #3 and attach the dmesg in a sperated file "y" -- three IDE device attached on both IDE buses, and only ata0 configured. ata1 has failed to probe because only primary IDE is enabled in BIOS. I should not do such test again, but I think I am getting old, and may not remember things right. However, I do not think I made a mistake in this case. It is the fact that 4.5 and earlier FreeBSD release can disable IDE (ata) from BIOS. > -- > Crist J. Clark | cjclark@alum.mit.edu > | cjclark@jhu.edu > http://people.freebsd.org/~cjc/ | cjc@freebsd.org -- ------------ Jin Guojun ----------- v --- j_guojun@lbl.gov --- Distributed Systems Department http://www.itg.lbl.gov/~jin M/S 50B-2239 Ph#:(510) 486-7531 Fax: 486-6363 Lawrence Berkeley National Laboratory, Berkeley, CA 94720 --------------8F41AE8DFFD88B677B4F70F9 Content-Type: text/plain; charset=us-ascii; name="x" Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="x" #1 ---------- Customer built kernel with ata1 disabled in config file ----- Copyright (c) 1992-2002 The FreeBSD Project. Copyright (c) 1979, 1980, 1983, 1986, 1988, 1989, 1991, 1992, 1993, 1994 The Regents of the University of California. All rights reserved. FreeBSD 4.5-RELEASE #0: Tue Mar 5 17:54:18 PST 2002 root@dvp76:/usr/src/sys/compile/MinMax Timecounter "i8254" frequency 1193182 Hz CPU: Pentium II/Pentium II Xeon/Celeron (499.84-MHz 686-class CPU) Origin = "GenuineIntel" Id = 0x660 Stepping = 0 Features=0x183f9ff real memory = 134205440 (131060K bytes) avail memory = 125956096 (123004K bytes) Preloaded elf kernel "kernel" at 0xc048d000. Pentium Pro MTRR support enabled md0: Malloc disk Using $PIR table, 7 entries at 0xc00f0d10 npx0: on motherboard npx0: INT 16 interface pcib0: on motherboard pci0: on pcib0 pcib1: at device 1.0 on pci0 pci1: on pcib1 pci1: at 0.0 irq 11 isab0: at device 4.0 on pci0 isa0: on isab0 atapci0: port 0xd800-0xd80f at device 4.1 on pci0 ata0: at 0x1f0 irq 14 on atapci0 uhci0: port 0xd400-0xd41f irq 12 at device 4.2 on pci0 usb0: on uhci0 usb0: USB revision 1.0 uhub0: Intel UHCI root hub, class 9/0, rev 1.00/1.00, addr 1 uhub0: 2 ports with 2 removable, self powered chip1: port 0xe800-0xe80f at device 4.3 on pci0 fxp0: port 0xd000-0xd03f mem 0xe1000000-0xe10fffff,0xe1800000-0xe1800fff irq 12 at device 9.0 on pci0 fxp0: Ethernet address 00:90:27:71:f2:13 inphy0: on miibus0 inphy0: 10baseT, 10baseT-FDX, 100baseTX, 100baseTX-FDX, auto ncr0: port 0xb800-0xb8ff mem 0xe0800000-0xe08000ff irq 10 at device 11.0 on pci0 orm0: