Commit Graph

233 Commits

Author SHA1 Message Date
mycroft 8b13d21260 Do a CARDBUS_BM_ENABLE to be sure. 2000-03-07 00:32:52 +00:00
mycroft de8398315a Fix an obvious bug that caused I/O space to never be freed.
Also, don't use rbus_space_free() directly.
2000-03-07 00:31:46 +00:00
mycroft bcdcb370e5 Called the power function even for 5V cards. This at least gives the power
a chance to stabilize before we frob the card.
2000-03-07 00:30:57 +00:00
thorpej 54e0e80815 Cosmetic change. 2000-03-01 20:50:56 +00:00
thorpej 08483fcddc When unmapping these on detach, pass the BAR to unmap (not the type of
the BAR!!)
2000-03-01 20:50:37 +00:00
soren d282f771e7 Remove redundant CIS definitions. 2000-02-18 18:55:31 +00:00
enami 01868857df Add activate routine and check device active flag also in one second
tick handler.
2000-02-12 04:05:49 +00:00
joda d40e2b51ee add detach code 2000-02-09 22:15:57 +00:00
itohy 0a1d6b1357 Make it compile with options DEBUG.
Reported by Kawamoto Yosihisa (PR #9379).
2000-02-09 07:57:52 +00:00
augustss 494c9affea Support detach. 2000-02-05 18:11:55 +00:00
augustss e037c568cb Update for cardbus unmap changes. 2000-02-04 13:48:23 +00:00
augustss 1facb42e6e Make the driver work even if DIAGNOSTIC is not set. 2000-02-04 13:43:56 +00:00
haya ded26ac3e4 Now cardbus_mapreg_unmap() has been implemented in
sys/dev/cardbus/cardbus_map.c.  The detech function in
sys/dev/cardbus/if_tlp_cardbus.c uses cardbus_mapreg_unmap().
2000-02-04 07:59:20 +00:00
thorpej 44a20a6c96 If we read a bad header signature, report what we read. 2000-02-03 06:47:31 +00:00
thorpej 001748dc57 First cut at detach support; doens't fully work yet. 2000-02-01 22:54:47 +00:00
haya 2e9b49c888 Force power off when a CardBus card is detached.
Use tsleep when kernel thread works.
2000-01-31 08:49:07 +00:00
haya 653eefc8f4 Add cardbus detach functionality. Add a function
cardbus_detach_card() in cardbus.c and enable detach code in cardslot.c
2000-01-26 09:04:59 +00:00
thorpej 422cc09430 First attempt at a CardBus front-end for the `ahc' driver. This will
support the Adaptec ADP-1480 CardBus SCSI cards, which are a stright
AIC-7860 implementation.
2000-01-26 06:37:23 +00:00
drochner 1f723151f2 use BUS_SPACE_MAP_PREFETCHABLE instead BUS_SPACE_MAP_CACHEABLE where the
PCI BAR bit is referred to
2000-01-25 22:32:20 +00:00
thorpej 701cc4b663 Add support for the Xircom X3201-3 in 21143 emulation mode. This chip
appears on some Xircom and Intel RealPort(tm) cards.

From Rafal Boni, with some slight modifications from me.
2000-01-25 21:50:30 +00:00
thorpej 6aca67041c Add a chip type for the Xircom X3201-3, and centralize the declaration
of the chip names array.
2000-01-25 19:29:17 +00:00
mycroft e33c595472 Do a CARDBUS_BM_ENABLE just to be sure. 2000-01-25 15:29:43 +00:00
thorpej be3c43687c Make sure the latency timer is set to a reasonable value.
From Masanori Kanaoka <kanaoka@ann.hi-ho.ne.jp>.
2000-01-25 03:44:27 +00:00
thorpej 0c93dded4a Use config_pending. Addresses kern/9247. 2000-01-24 18:34:44 +00:00
joda de798768b3 (cardbus_attach_card): zero out ca 2000-01-13 10:27:31 +00:00
augustss 6b1620b095 Remove extra #endif so we can compile again. 1999-12-17 14:06:43 +00:00
abs 43838a47fd Add back cut Cardbus_conf_write/cardbus_conf_write lines. 1999-12-16 21:04:10 +00:00
kleink 2fd74b0fb4 Normalize symbol names used for multiple inclusion protection. 1999-12-15 12:28:54 +00:00
thorpej 014cd3fcc1 Take a stab at making this work on big-endian systems. 1999-12-12 17:46:36 +00:00
explorer 4313f463a0 add 3com 575CT, which Dell (at least) seems to be shipping 1999-12-11 22:22:34 +00:00
thorpej d4bb1032cb Handle the 21143 PMCSR, like we do in the PCI front-end. 1999-12-11 00:39:13 +00:00
thorpej caae0e1aa1 - Don't try to run the chip in big-endian mode. Not all chips support
this consistently, and it doesn't always work even when the chip
  supports it.
- Make sure things DMA'd to the chip that the chip interprets are in
  little-endian mode.
1999-12-11 00:32:59 +00:00
thorpej 085bc011ab Add cardbus_get_capability(), cloned from pci_get_capability(). 1999-12-11 00:29:11 +00:00
joda 9758d8ed66 check for NULL from malloc 1999-12-08 16:52:51 +00:00
thorpej 546480874c After reading the 21143 manual again, make sure SNOOZE is cleared in
the CFDA register, too.
1999-12-07 07:36:19 +00:00
thorpej 6e36651a27 Add the 21143 PMCSR offset, from Masanori Kanaoka. 1999-12-07 07:33:25 +00:00
thorpej 3d60aecdd7 Make sure to bring the chip out of sleep mode. From Masanori Kanaoka. 1999-12-07 07:11:49 +00:00
thorpej 0c3eefb6a5 Add a basic CardBus front-end for the `tlp' driver. Still more work to do. 1999-11-19 18:23:35 +00:00
joda b578473fae include dev/cardbus/cardbusdevs.h 1999-11-18 16:57:41 +00:00
joda 88d26dd881 regen 1999-11-18 16:03:43 +00:00
joda 08bc681319 fix bogus comment 1999-11-18 16:03:12 +00:00
joda 175087230a use CARDBUS_VENDOR_INVALID 1999-11-18 15:11:15 +00:00
joda 8c62b47d9f regen 1999-11-18 15:09:59 +00:00
joda 40f1a07541 add INVALID vendor, and an Intel modem 1999-11-18 15:09:30 +00:00
thorpej ce25407921 Make this a lot more like the PCI front-end. 1999-11-17 08:49:16 +00:00
soren f361f1b1b8 Also disable EX_CONF_INTPHY on the B model. 1999-11-17 08:42:06 +00:00
thorpej e1a760a4a7 The 3c575-TX does *not* have an internal PHY. 1999-11-17 07:59:57 +00:00
haya 3be097c31d Handle insertion and removal events more strictly. 1999-11-15 06:08:02 +00:00
haya 89d0a53e2c Fill 0 into CardBus base address registers before a card is
configured.
1999-11-15 06:01:11 +00:00
joda f9bf746086 (cardbus_attach_card): don't free cc 1999-11-12 18:18:38 +00:00
joda 4278cf451e if the image size is zero, assume it really means one block 1999-11-12 18:17:36 +00:00
joda c7cca9cd39 make this compile with CARDBUS_DEBUG 1999-11-09 15:03:59 +00:00
haya e54d837b8b Maintenance CardBus/PCI extension ROM mapping routine.
1. Make Extension ROM not to be mapped on I/O space.
2. Do not check the bus-space indicator in ROM register.
1999-11-09 09:20:30 +00:00
joda 1b686307cb correct number of BAR:s in cardbus_cis_info 1999-11-08 20:21:24 +00:00
joda fe2d79ec9a Let decode_tuples take function to call for each tuple, and use this
to get some vital information from the CIS (some network cards need
this to get the mac-address). This should be merged with the related
code for PCMCIA cards, but that requires more thought.
1999-11-08 20:19:10 +00:00
joda dbb2685da6 add some bare-bones CIS information to the attach_args struct 1999-11-08 19:59:08 +00:00
joda f6be3b394d regen 1999-11-08 19:57:32 +00:00
joda 19ff47781e copy xircom entries from pcidevs 1999-11-08 19:57:13 +00:00
soren 6f961bbe31 It's okay for a memory region to be larger than it's alignment. 1999-11-06 06:20:53 +00:00
haya 88f1d44cc2 Change the interface of cardbus_function_enable() and
cardbus_function_disable().
1999-11-01 09:59:23 +00:00
joda d094848950 uncomment fxp_cardbus 1999-10-31 15:14:17 +00:00
joda b0e5ebfddc commit a more working version if this driver; so far only tested on an
Intel `PRO/100 LAN+Modem56 CardBus II'
1999-10-31 15:12:39 +00:00
joda ee08428d1c handle multi function cards 1999-10-29 12:02:13 +00:00
joda 1ea6cd1de0 add cardbus_exrom.c to cardbus device 1999-10-29 11:31:40 +00:00
joda 54fed4c419 add support for reading memory mapped CIS via BAR or EXROM register 1999-10-29 11:30:27 +00:00
haya 47fc621312 Remove unnecessary check in cardbusmatch. 1999-10-29 07:29:08 +00:00
haya dd9c83a378 Change cardbus messages when cardbus does not configured. 1999-10-29 07:27:43 +00:00
joda 8ff7881953 add macro to get ROM image number, given a CIS pointer 1999-10-28 22:29:04 +00:00
joda 12d5a03a7f code to read PCI expansion ROM 1999-10-28 22:27:00 +00:00
joda 4d92da53d4 allow mapping of the expansion rom 1999-10-27 14:14:18 +00:00
joda 132b3f5e57 add Expasion ROM register (0x30);
fix typo in Cardbus_conf_write
1999-10-27 14:09:52 +00:00
joda d9c500abb3 (cardbus_attach_card): don't mask everything *but* the latency timer 1999-10-27 14:01:04 +00:00
haya 91b09f5b16 Change cardbus API. The first argument of cardbus_mapreg_map() is
changed to struct cardbus_softc * from cardbus_devfunc_t.  The old
function is renamed to Cardbus_mapreg_map().
1999-10-27 10:04:41 +00:00
haya 7b66141eed Use opt_cardbus.h for cardbus.c and opt_cardslot.h for cardslot.c.
Remove unnecessary include from cardbus.c.
1999-10-27 09:29:18 +00:00
drochner 87568e8d82 defopt the XNS protocol (options NS), clean up the use of related
option headers / defines
1999-10-25 19:18:10 +00:00
augustss f65479526f Correct a spelling mistake. 1999-10-15 21:53:02 +00:00
augustss 38a146ce0f Add USB OHCI attachment to cardbus.
XXX There seems to be some interrupt problem.
1999-10-15 11:52:45 +00:00
augustss 1d19b4dd3d Add a number of CARDBUS_CLASS defines. Copied from PCI_CLASS. 1999-10-15 11:10:58 +00:00
augustss c175d023d0 Comment out some debug settings.
Change attach printing so it looks more standard.
1999-10-15 10:59:56 +00:00
haya e5cc414836 add NetBSD ID tag. 1999-10-15 06:42:21 +00:00
haya e56835ec5d add NetBSD ID tag 1999-10-15 06:41:27 +00:00
haya 316b48ba74 This is the first check-in of CardBus driver. CardBus driver contains
CardBus bus stub, YENTA PCI-CardBus bridge (cbb), 3Com 3C575TX driver
(ex) and Intel fxp driver.

TODO:
  o Conform to the KNF more strictly.
  o Be unified with pcmcia code as much as possible.
  o Add more drivers for CardBus card, such as APA-1480 or USB card.

The affected files are listed below.

	sys/arch/i386/conf/files.i386
	sys/arch/macppc/conf/files.macppc
	sys/conf/files
	sys/dev/ic/elinkxl.c
	sys/dev/ic/elinkxlvar.h
	sys/dev/ic/i82365.c
	sys/dev/ic/i82365var.h
	sys/dev/isa/i82365_isasubr.c
	sys/dev/pci/files.pci
	sys/dev/pcmcia/pcmcia.c
	sys/dev/pcmcia/pcmciachip.h

The added files are listed below.

	sys/arch/i386/conf/CARDBUS
	sys/arch/i386/include/rbus_machdep.h
	sys/arch/i386/i386/rbus_machdep.c
	sys/arch/macppc/include/rbus_machdep.h
	sys/arch/macppc/macppc/rbus_machdep.c
	sys/dev/cardbus/if_ex_cardbus.c
	sys/dev/cardbus/Makefile.cardbusdevs
	sys/dev/cardbus/cardbus.c
	sys/dev/cardbus/cardbus_map.c
	sys/dev/cardbus/cardbusdevs
	sys/dev/cardbus/cardbusdevs.h
	sys/dev/cardbus/cardbusdevs_data.h
	sys/dev/cardbus/cardbusvar.h
	sys/dev/cardbus/cardslot.c
	sys/dev/cardbus/cardslotvar.h
	sys/dev/cardbus/devlist2h.awk
	sys/dev/cardbus/files.cardbus
	sys/dev/cardbus/if_fxp_cardbus.c
	sys/dev/cardbus/pccardcis.h
	sys/dev/cardbus/rbus.c
	sys/dev/cardbus/rbus.h
	sys/dev/pci/pccbb.c
	sys/dev/pci/pccbbreg.h
	sys/dev/pci/pccbbvar.h
1999-10-15 06:24:24 +00:00
haya 4eee111127 This is the first check-in of CardBus driver. CardBus driver contains
CardBus bus stub, YENTA PCI-CardBus bridge (cbb), 3Com 3C575TX driver
(ex) and Intel fxp driver.

TODO:
  o Conform to the KNF more strictly.
  o Be unified with pcmcia code as much as possible.
  o Add more drivers for CardBus card, such as APA-1480 or USB card.

The affected files are listed below.

	sys/arch/i386/conf/files.i386
	sys/arch/macppc/conf/files.macppc
	sys/conf/files
	sys/dev/ic/elinkxl.c
	sys/dev/ic/elinkxlvar.h
	sys/dev/ic/i82365.c
	sys/dev/ic/i82365var.h
	sys/dev/isa/i82365_isasubr.c
	sys/dev/pci/files.pci
	sys/dev/pcmcia/pcmcia.c
	sys/dev/pcmcia/pcmciachip.h

The added files are listed below.

	sys/arch/i386/conf/CARDBUS
	sys/arch/i386/include/rbus_machdep.h
	sys/arch/i386/i386/rbus_machdep.c
	sys/arch/macppc/include/rbus_machdep.h
	sys/arch/macppc/macppc/rbus_machdep.c
	sys/dev/cardbus/if_ex_cardbus.c
	sys/dev/cardbus/Makefile.cardbusdevs
	sys/dev/cardbus/cardbus.c
	sys/dev/cardbus/cardbus_map.c
	sys/dev/cardbus/cardbusdevs
	sys/dev/cardbus/cardbusdevs.h
	sys/dev/cardbus/cardbusdevs_data.h
	sys/dev/cardbus/cardbusvar.h
	sys/dev/cardbus/cardslot.c
	sys/dev/cardbus/cardslotvar.h
	sys/dev/cardbus/devlist2h.awk
	sys/dev/cardbus/files.cardbus
	sys/dev/cardbus/if_fxp_cardbus.c
	sys/dev/cardbus/pccardcis.h
	sys/dev/cardbus/rbus.c
	sys/dev/cardbus/rbus.h
	sys/dev/pci/pccbb.c
	sys/dev/pci/pccbbreg.h
	sys/dev/pci/pccbbvar.h
1999-10-15 06:07:17 +00:00