diff options
author | wpaul <wpaul@FreeBSD.org> | 2004-08-16 18:50:20 +0000 |
---|---|---|
committer | wpaul <wpaul@FreeBSD.org> | 2004-08-16 18:50:20 +0000 |
commit | 9f377407f3e16830c475cedb638583a1e99504a5 (patch) | |
tree | 87e7ccfbd013f8c08343648bed44321f0ecafaca /sys/dev/if_ndis | |
parent | 6dddbdd9af23673e6ad71f844497cc199c80f194 (diff) | |
download | FreeBSD-src-9f377407f3e16830c475cedb638583a1e99504a5.zip FreeBSD-src-9f377407f3e16830c475cedb638583a1e99504a5.tar.gz |
Make the Texas Instruments 802.11g chipset work with the NDISulator.
This was tested with a Netgear WG311v2 802.11b/g PCI card. Things
that were fixed:
- This chip has two memory mapped regions, one at PCIR_BAR(0) and the
other at PCIR_BAR(1). This is a little different from the other
chips I've seen with two PCI shared memory regions, since they tend
to have the second BAR ad PCIR_BAR(2). if_ndis_pci.c tests explicitly
for PCIR_BAR(2). This has been changed to simply fill in ndis_res_mem
first and ndis_res_altmem second, if a second shared memory range
exists. Given that NDIS drivers seem to scan for BARs in ascending
order, I think this should be ok.
- Fixed the code that tries to process firmware images that have been
loaded as .ko files. To save a step, I was setting up the address
mapping in ndis_open_file(), but ndis_map_file() flags pre-existing
mappings as an error (to avoid duplicate mappings). Changed this so
that the mapping is now donw in ndis_map_file() as expected.
- Made the typedef for 'driver_entry' explicitly include __stdcall
to silence gcc warning in ndis_load_driver().
NOTE: the Texas Instruments ACX111 driver needs firmware. With my
card, there were 3 .bin files shipped with the driver. You must
either put these files in /compat/ndis or convert them with
ndiscvt -f and kldload them so the driver can use them. Without
the firmware image, the NIC won't work.
Diffstat (limited to 'sys/dev/if_ndis')
-rw-r--r-- | sys/dev/if_ndis/if_ndis_pci.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/sys/dev/if_ndis/if_ndis_pci.c b/sys/dev/if_ndis/if_ndis_pci.c index 47c2f69..00f4086 100644 --- a/sys/dev/if_ndis/if_ndis_pci.c +++ b/sys/dev/if_ndis/if_ndis_pci.c @@ -208,7 +208,7 @@ ndis_attach_pci(dev) error = ENXIO; goto fail; } - if (rle->rid == PCIR_BAR(2)) { + if (sc->ndis_res_mem) { sc->ndis_altmem_rid = rle->rid; sc->ndis_res_altmem = bus_alloc_resource(dev, |