From owner-freebsd-hackers Wed Jul 29 18:30:16 1998 Return-Path: Received: (from majordom@localhost) by hub.freebsd.org (8.8.8/8.8.8) id SAA02487 for freebsd-hackers-outgoing; Wed, 29 Jul 1998 18:30:16 -0700 (PDT) (envelope-from owner-freebsd-hackers@FreeBSD.ORG) Received: from agustina.kjsl.com (Agustina.KJSL.COM [198.137.202.12]) by hub.freebsd.org (8.8.8/8.8.8) with ESMTP id SAA02482 for ; Wed, 29 Jul 1998 18:30:14 -0700 (PDT) (envelope-from fmc@reanimators.org) Received: (from uucp@localhost) by agustina.kjsl.com (8.8.7/8.8.8/rchk1.19) with UUCP id RAA26130; Wed, 29 Jul 1998 17:56:49 -0700 (PDT) (envelope-from fmc@reanimators.org) Received: (from fmc@localhost) by daemonweed.reanimators.org (8.8.5/8.8.8/rchk1.19) id RAA19554; Wed, 29 Jul 1998 17:38:29 -0700 (PDT) (envelope-from fmc) Message-Id: <199807300038.RAA19554@daemonweed.reanimators.org> To: Ted Faber Cc: Frank McConnell , Mike Smith , Robert Swindells , hackers@FreeBSD.ORG Subject: Re: AMD PCNet/FAST cards; suppliers? References: <199807291753.KAA12867@tnt.isi.edu> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII From: Frank McConnell Date: 29 Jul 1998 17:38:28 -0700 In-Reply-To: Ted Faber's message of Wed, 29 Jul 1998 10:53:39 -0700 Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk X-Loop: FreeBSD.ORG Ted Faber wrote: > Frank McConnell wrote: > >Ted Faber wrote: > >>As far as I can tell, there's no support for using the Hitachi's > >>internal PCI lance board in native PCI mode, so the card can only be > >>used in ISA emulation mode. > > > >What led you to that conclusion? Whoops. Poor choice of words on my part -- I wasn't questioning your intelligence when I wrote that, I really wanted to know what behavior you saw on your Hitachi that got you thinking along those lines. > As I mentioned, I'm just msireading the code here. I didn't see > anything that appeared PCI specific, and wasn't seeing my card work. > I'm no expert in either the PCI bus or this chipset - I was just > trying to get the laptop's internal ethernet running so it was of some > use to me. Hey, I'm no expert on these things either, just a wannabe looking for enlightenment. Here's what I was thinking. The probing for PCI and ISA cards looks (and largely is) the same -- I can't see why it should work from one code path and fail from the other, except by way of different I/O base addresses where one doesn't address an appropriate device. So there's one potential problem -- if you have a PCI card, and it's getting mapped at some I/O address for which you have a "device lnc[n]" entry in your kernel config (as for an ISA card), it'll get probed and attached twice. There's also the matter that the IC has a couple of different flavors of modes. One is the "software style" that can be set via BCR20. I think this defaults to C-LANCE/PCnet-ISA on hard reset, and the other styles would expect a different initialization block layout, so I think that this is what the driver expects. The other is word (16-bit) I/O vs. double-word (32-bit) I/O mode, which changes some of the register offsets, and again I think the driver expects to see the IC in word I/O mode (where a hard or soft reset will leave it) and just won't work if the chip is in double-word I/O mode. And there's another potential problem -- if the Hitachi BIOS tells the IC to do some other software style, or puts it in double-word I/O mode, I don't think the driver will probe it correctly. But I think that means both the PCI and ISA probes would fail. (Not that I know why the BIOS would do something like that -- this is speculation on my part.) So that's why I was wondering what you were seeing that would make you think you could use it in "ISA emulation" only -- as near as I can tell it should either work from either code path or not work at all. -Frank McConnell To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message