Commit Graph

169 Commits

Author SHA1 Message Date
thorpej 1addb1955a Default to telling the MI PCI code that rd/line, rd/mult, and wr/inv
commands are OK.
2002-02-28 21:48:05 +00:00
jdolecek f32b3f4f89 Reduce the massive code duplication regarding joy(4). Split it into
MI and MD parts, and make ISA/ISAPNP/PCI joy(4) attachments MI.
2002-02-02 18:37:38 +00:00
christos 7da411d63b Look for _PIR in addition to $PIR. My libretto L2 now works without
any other kludges.
2002-01-28 23:53:08 +00:00
uch a68b39d7c2 Reset configuration of bridge order before enumerating bridge devices.
This is required when two or more bridges on the same bus, and some of
them are incompletely initialized by BIOS.
Reported by NAKAGAWA Yoshihisa <y-nakaga@nwsl.mesh.ad.jp>
2002-01-22 15:08:53 +00:00
uch 29d84d9a58 Add pci_bridge_foreach (). 2002-01-22 15:07:27 +00:00
augustss f3b996d67a Add the i830 bridge. 2002-01-14 01:45:54 +00:00
fvdl a3cd944f25 Also correct the attach flags to enable IO space on the ServerWorks
CNB20LE.
2001-12-16 21:33:06 +00:00
onoe d5d707cf1d Add 82801BAM as piix.
Do not initialize global variables 'pciintr_icu_tag' to NULL.
Its type is 'const struct pciintr_icu *' (typedef'ed) and gcc sometimes(!)
put it in Text region.  So force arrrange it to BSS.
2001-12-07 08:07:57 +00:00
lukem 95c969f245 add RCSID 2001-11-15 07:03:28 +00:00
drochner 8002eb91a6 -fix botched switch/case nesting which made AGP on i810 in GFX mode fail
-remove the check for i810's internal graphics completely: we'll attach
 AGP whether in GFX or AGP mode anyway, and the SMRAM register test
 was of questionable value (should have masked with 0xc0, but even then
 the builtin graphics appeared enabled although I used an external
 PCI card)
2001-09-17 12:07:32 +00:00
thorpej 0019ea5ce6 Clean up the AGP match/attach code somewhat. 2001-09-15 00:24:59 +00:00
tshiozak 5341bac833 correct the set/get trigger code for ALi M1543 interrupt router. 2001-09-13 14:00:52 +00:00
fvdl 43bbb8500a Apparently some ServerWorks Host-PCI bridges only get their memory space
enabled, even though IO space does work. A few drivers (like ahc)
will only work reliably with IO space, so check for this condition
and correct it.
2001-09-12 08:25:17 +00:00
fvdl 8e76d96c85 wrap decl in #if NAGP > 0 2001-09-10 10:54:46 +00:00
fvdl 2c8172cbd3 Attach agp gart support @ pchb. Not very clean, but agp support may
be spread over several devices, and the phcb is usually the main one.

Add agp_machdep.c file which implements MD agp functions (currently
just agp_flush_cache).
2001-09-10 10:06:54 +00:00
enami bab65a8da3 Mix random data directly into the pool and increase entropy instead of
estimating entropy with polling based timing.
2001-09-09 00:48:54 +00:00
kanaoka 3b4f143fd8 - Correct a value of subend.
Pointed out by enami tsugutomo <enami@but-b.or.jp>.
2001-08-27 13:02:12 +00:00
haya 31d98218e8 Add support for ALi M1543 in pcibios. 2001-08-27 08:21:20 +00:00
haya 3d57cec099 Add new entry for intel ICH2 LPC interrupt router. It has
upper compatibility with piix.
2001-08-01 09:11:19 +00:00
mrg ef38b7e874 fix a statementless label that gcc-current picked up. 2001-07-17 13:53:15 +00:00
mcr 97eac1b54c context argument added to pci_device_foreach(). 2001-07-06 18:04:58 +00:00
mcr b44d7d55a5 added some debugging to error message in pci_intr_map(). 2001-07-06 18:04:22 +00:00
mcr 07ba5352f1 extra argument to pci_device_foreach(). 2001-07-06 18:03:47 +00:00
mcr 8c020dd2f7 when fixing up buses, keep track of the parent of each bus,
and the pcitag to access the primary side of that bridge.
2001-07-06 18:03:17 +00:00
mcr 6244484599 added context parameter to pciaddr_resource_{reserve,allocate}
and to pci_device_foreach().
	added new function pci_device_foreach_min().
2001-07-06 18:02:35 +00:00
kanaoka aa09aa91c7 Search the entire device-space of bus 0 if the router device
address is set to 000:00:0, and the compatible router entry
is undefined.

  Patch PR port-i386/12880 by Dave Sainty <dave@dtsp.co.nz>.
2001-05-16 08:10:36 +00:00
lukem 33e8c1a04f delint: don't try & return something from void pci_intr_disestablish() 2001-05-15 14:48:57 +00:00
kanaoka bb0eabfe15 - fixup only #0 bus --> fixup maxbus.
- Don't pciaddr_do_resource_allocate if device is AGP
   to avoid conflict.
2001-04-23 19:15:29 +00:00
jdolecek 6402f68d79 Match any device with class bridge and subclass BRIDGE_MC, instead
of matching individual products. Pointed out by Jason Thorpe.
2001-04-21 19:18:20 +00:00
uch 9b730bc368 patch PR port-i386/11114 by MINOURA Makoto. 2001-04-19 17:32:40 +00:00
mycroft 355086c412 The `speed' statistic from the RNG was brought to you by the letter `B' and
the letter `S'.  I don't think anyone will miss it.
2001-03-30 12:05:02 +00:00
jdolecek b53fce84d3 Add an autoconfig node for PCI-MCA bridges. Configures MCA bridges
via callback. This beast is very rare, present only on some IBM PCs.
Code was copied off pceb.
2001-03-25 09:54:10 +00:00
tsutsui 8303e98e40 Fix typo (s/req/reg/). 2001-01-05 19:08:04 +00:00
aymeric 6a808ce8c8 Initialize VIA Technologies' 82C686's ICU as if it were a 82C586.
This fixes interrupt allocation problems on modern Compaq laptops.
2001-01-05 18:39:12 +00:00
sommerfeld 851de295eb Change pci_intr_map to get interrupt source information from a "struct
pci_attach_args *" instead of from four separate parameters which in
all cases were extracted from the same "struct pci_attach_args".

This both simplifies the driver api, and allows for alternate PCI
interrupt mapping schemes, such as one using the tables described in
the Intel Multiprocessor Spec which describe interrupt wirings for
devices behind pci-pci bridges based on the device's location rather
the bridge's location.

Tested on alpha and i386; welcome to 1.5Q
2000-12-28 22:59:06 +00:00
enami 58f16f5f39 - Zero is a valid random data. Don't give up to attach.
- 4 cycle is enough to get 4 octet of data.
2000-12-21 02:43:04 +00:00
augustss a00e309252 Fix speeling in cooment. 2000-11-06 22:10:03 +00:00
augustss 83bdca3a71 Print a newline after the random number speed message. 2000-11-06 22:01:31 +00:00
ad 3d193b190b - Pequr -> Serverworks. It pays to do a cvs update first...
- Pay attention only to the low byte of config reg 0x44 on Serverworks chips,
  as Linux does.
- Compress duplicatated code.
2000-11-03 17:28:02 +00:00
thorpej 10203d4eca Change the RNG callout -- don't spin until data is available. If
none is available, just wait until the next clock tick.
2000-10-30 00:26:04 +00:00
simonb bb33bb331d Fix NRND == 0 case (unused variable). 2000-10-28 13:30:35 +00:00
itojun 5bbd7d495e fix busy-wait logic against random number register. (missing semicolon) 2000-10-28 04:58:35 +00:00
thorpej 3c01d4cbca Add support for sampling the random number generator on
the 810, 815, 820, and 840 chipsets.  From OpenBSD, modified
for NetBSD by me.
2000-10-27 22:49:21 +00:00
thorpej 7f59704e6c Support the second PCI bus on SeverWorks chipsets. From OpenBSD. 2000-10-27 17:55:18 +00:00
thorpej 2644e830b7 BIOS BUG WORKAROUND! The 82443BX datasheet indicates that the only legal
setting for the "Idle/Pipeline DRAM Leadoff Timing (IPLDT)" parameter
(bits 9:8) is 01.  Unfortunately, some BIOSs do not set these bits properly.

Based on a hint from OpenBSD.
2000-10-27 17:47:44 +00:00
soda b63f6b5096 Add another option PCIBIOS_INTR_GUESS for no compatible ICU found case.
Under this option, if only one IRQ is available for the link,
we assumes that the IRQ is already connected, and configure
PCI Interrupt Configuration Register accordingly.
This is what Linux pcmcia-cs-3.1.19 does by default.

This fixes unconfigured pccbb interrupt problem of
Sharp Mebius MN-5500. It's interrupt router is ITExpress Inc. IT8330G.
(http://www.ite.com.tw/, vendor=0x1283, product=0x8330)
Problem reporeted by Kitagawa <sk@kiu.ac.jp> in
http://www.kaynet.or.jp/~kay/ml/netbsd-pcmcia/msg/msg00608.html
2000-08-10 21:18:27 +00:00
nathanw b3e0af3d32 Fix a problem uncovered by rev 1.5 of pcibios.c:
Avoid interpreting the upper 32 bits of 64-bit BARs as a 32-bit BAR.
Otherwise, the code would assume that the value 0 was incorrect and either:
(a) [on bus 0] "fix up" the address to some nonzero value, thus placing
    the decoded address range outside of 32-bit address space, or
(b) [elsewhere] completely disable the device.

The fact that this behaviour depends on the bus number of the device is
already XXX'd.

XXX: This will need revisiting if and when we ever want to handle a PCI bus
XXX: with more than 32 bits of address space on an i386.

The onboard Adaptec 7890 on my Dell Precision Workstation 410 works again.
2000-08-03 20:10:45 +00:00
soda 0cbe0d600f fix oversight introduced in previous my commmitment (revision 1.4),
pointed out by Michael Shalayeff <mickey@openbsd.org>.
2000-08-02 02:54:41 +00:00
uch ae581ace81 reserve AGP space to avoid resource conflict. 2000-08-01 05:23:59 +00:00
soda a86a9c61c4 better message from John Hawkinson <jhawk@MIT.EDU> 2000-07-22 17:43:36 +00:00