summaryrefslogtreecommitdiffstats
path: root/sys/pccard/i82365.h
Commit message (Collapse)AuthorAgeFilesLines
* /* -> /*- for license, minor formatting changesimp2005-01-071-1/+2
|
* Move PNP IDs back into oldcard filesimp2004-08-131-0/+13
|
* Fix comment.imp2003-08-291-1/+1
|
* Add support for writing to mapping high memory for pccard memoryimp2002-07-201-0/+7
| | | | | | | | | | windows. Right now we only support pci chips that are memory mapped. These are the most common bridges in use today and will help a large majority of the users. I/O mapped PCI chips support this functionality in a different way, as do some of the ISA bridges (but only when mounted on a motherboard). These chips are not supported by this change.
* Add definitions for the Ext 1 register on cirrus logic PD-6729.imp2002-07-171-0/+9
|
* What:imp2002-06-231-1/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | o ToPIC is happy with two cards now, even when the two cards are modems. o Fix (all?) hangs on boot when power is applied to the card. I suspect that this will make the Ricoh bridges happier and also make a lot of VAIO owners happy (confirm to me in private email please :-). o All Cardbus bridges should now support 3.3V, X.XV and Y.YV cards, to the extent that the underlying hardware supports such cards. (X.X and Y.Y haven't been assigned values yet :-). o Better 3.3V support for Ricoh ISA bridges. How: o Don't mess with the power register when scanning the cards. It is unnecessary and causes BADVcc conditions on many chipsets. These in turn can cause an interrupt storm. o Make pcic_disable reset the slot's voltage. o Move initializing voltage for the slot until after it has been disabled. o Fix a lot of issues with the pcic_cardbus_power routine. We now properly enable the card and take it out of reset after a power change. o When detecting the card's voltage, if we're in a BadVcc state, direct the bridge to rescan the card for what it supports. (we might need to in the future set the power register to 0 before doing this). o Don't preserve CLKSTOP. need to revisit this. o Better support for Ricoh ISA bridges for 3.3V cards. o Don't write to PCIC_POWER directly as offten, but instead go through the pcic_power interface. o All cardbus bridges now default to use cardbus power control. o Add misc register definitions. o remove some (now) bogus comments. Extra Special Thanks To: Scott Lamber for his kind and generous loan of a Toshiba laptop with a ToPIC 100 in it for my use.
* o Try to do 3.3V support better for the 6722 and 6729/30.imp2001-11-091-4/+17
| | | | | | | | | | | | | o Bite the bullet and create controller types for the 6729 and also for the 673x. Rename the 672x to 6722. o Define minimal extended register info (just register 0xa for reading VS[12]). # I think the last version may have broken 673x controllers, but this should # fix them. Tested on the 6722, but not the 6729. Ideas from: Chiharu Shibata-san's article in bsd-nomads:15866
* Values for the Toshiba ToPIC's Function Control Register.imp2001-09-041-0/+6
| | | | | These were lifted from Nakagawa-san's article in FreeBSD Press, as well as posts from hiroyuki Aizo-san and Chiharu Shibata-san.
* Order PCIC_INT_GEN bits large to small, like all other registers.imp2001-08-051-1/+1
|
* TI cardbus bridges, 12xx and newer, have an interesting register. Itimp2001-08-011-1/+9
| | | | | | | | | | | | | | | is the diagnostics register at offset 0x93. When bit 5 is set in this register, bits 4-7 in ExCA register 0x5 being 0000 are required for pci interrupt routing. When it is clear, then bit 4 of ExCA register 0x3 is used to enable it. The only other issue is that when you route interrupts this way, you must read ExCA register 0x4 in order to clear the interrupt, else you get an interrupt storm. Deal with this requirement by setting things up. It is believed that this won't hurt other chipsets, but other chipsets may require their own work arounds.
* On PC-98, map IRQ 6 to IRQ 7 at the pcic level. That is, when we'reimp2001-06-161-4/+4
| | | | | | | | | | | | told to use IRQ 6, progam the pcic to use irq 7 instead. Evidentally, at least some of the cards are wired this way. If you want to use irq 6, configure it. All the mapping is done just before we set the interrupt registers. See [FreeBSD98-testers 5064] for details. Added commentary about valid interrupts on some CBUS pc98 CL PD6722 based cards. Submitted by: Hiroshi TSUKADA-san <hiroshi@kiwi.ne.jp>
* Update copyright infoimp2001-05-251-0/+1
|
* Use bus_space functions rather than inb/outb.imp2001-05-241-4/+4
| | | | | | | Add defines for PCIC_INDEX and PCIC_DATA offsets. Change PCIC_INDEX_0 to PCIC_PORT_0 Add define for PCIC_NPORT. Document why the vadem probe works.
* Add better support for the Ricoh 5C296 and 5C396 chips. These chipsimp2001-05-231-3/+13
| | | | | | have a slightly different 3.3V support than the other clones, so compensate as best we can. Note: 3.3V support is untested since I do not have any 3.3V cards that I know of to test it with.
* Next step on the road to pci: power taming.imp2001-05-211-0/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Work through the various power commands and convert them from a "is this a foo controller or a foo' controller or a foo''' controller" to a cabability based scheme. We have bits in the softc that tell us what kind of power control scheme the controller uses, rather than relying on being able to enumerate them all. Cardbus bridges are numerous, but nearly all implement the i82365sl-DF scheme (well, a few implement cirrus CL-PD67xx, but those were made by Cirrus Logic!). Add a pointer back to the softc in each pcic_slot so we can access these flags. Add comments that talk about the issues here. Also note in passing that there are two differ Vpp schemes in use and that we may need to adjust the code to deal with both of them. Note why it usually works now. We have 5 power management modes right now: KING, AB, DF, PD and VG. AB is for the i82365 stpes A, B and C. DF is for step DF. PD is the cirrus logic extensions for 3.3V while VG is the VADEM extensions for 3.3V. KING is for the IBM KING controller found on some old cards. # I'm looking for one of those old cards or a laptop that has the KING # bridge in it. We have to still cheat and treat the AB parts like the DF parts because pci isn't here yet. As far as I can tell, this is harmless for actual old parts and necessary to work with 3.3V cards in some laptops. This almost eliminates all tests for controller in the code. There are still a few unrelated to power that need taming as well.
* Two comments and one bug fix:imp2001-05-211-0/+2
| | | | | | | | | | o Add defines for the VS[12]# bits in register 0x16. o Add comment about what we're doing reading register 0x16 (PCIC_CDGC) in the DF case. o Check bit VS1# rather than a random bit I was checking due to a bogus transcrition on my part from nakagawa-san's article. o Add note about IBM KING and 3.3V operation from information larned from wildboard.
* It turns out that Intel's i82365sl-DF step has the same ID as the VLSIimp2001-05-191-4/+3
| | | | | | | | | | | | | | | | | | | | | | | | | 82C146. The Intel i82365SL-DF supports 3.3V cards. The Step A/B/C parts do not appear to support this. This is hard to know for sure since it was deduced from "compatible" parts' data sheets and the article mentioned below. Rework the VLSI detection to be a little nicer and not depend on scanning cards twice. This would allow bad VLSI cards to coexist with a good intel card, for example. We now detect i82365SL-DF cards where before we'd detect a VLSI. For the most part, this is good, but we run a small chance of detecting a single slot 82C146 as a i82365SL-DF. Since I can't find a datasheet for the 82c146, I don't know if this is a problem or not. This work is based on an excellent article, in Japanese, by NAKAGAWA, Yoshihisa-san that appeared in FreeBSD Press Number 4. He provided a patch against PAO3 in his article. Since the pcic.c code has changed some since then, I've gone ahead and cleaned up his patch somewhat and changed how the code detects the buggy '146 cards. I also removed the comment asking if there were other cards that matched the 82C146 since we found one and additional information isn't necessary.
* First cut at bringing NEC PC98 original pccard bridge code back intoimp2001-04-191-1/+1
| | | | | | | | | FreeBSD. This code doesn't work just yet, but does compile. We need to start indirecting via the cinfo pointers, rather than directly calling pcic_*. There may be other issues as well, but you gotta start somewhere. Obtained from: PAO3
* Lots of minor cleanup, plus a couple of interesting things.imp2001-03-191-17/+60
| | | | | | | | | | | | | | | | | | | | | | | o Attempt to disable the slot when we detect that there are problems with it in our ISR. This should make polling mode work better for more cards, but more work may be needed. This "disabling" sets the card interrupt register to 0. This worked for me for lots of tests in polling mode. o Now that I've found datasheets, fix a boatload of magic numbers in the source to make it easier to understand. o Use a table of names rather than a big case statement. o Cull a few of the "unused" controller types that we map to other times that were a vestiage of PAO code that we never merged in the same way. o Enforce legal IRQs. You are no longer allowed to try to use IRQs that will fail on all known ISA/PCI <-> PCMCIA bridges. The bridges do not have pins for these illegal interrupts, and all of them are listed as reserved and/or illegeal in the datasheets depending on which one you look at. o Add comments about how IBM-AT based computers and NEC PC-98 based computers map these interrupts and which ones are valid. o Always clear the bit that steers the management interrupt either to the value listed in the PCIC_STAT_INT register. I've seen this bit get set on suspend/resume and after windows boot, and it does't hurt to clear it. NOTE: this might mean we can share this interrupt in the future.
* Add support for PnP ISA cards, and some laptop PnP support:imp2000-03-101-2/+7
| | | | | | | | | | | | | | | o break out some of the probe routine the allocation of resources into an attach routine o Recognize PnP ids o Allocate IRQ per card rather than per system o Better polling reporting o Remove unneeded include files in slot.h o store a pseudo unit number on each device we find. o Pass a unit number to interrupt/timeout routine and use it for polling the hardware. Tested on: My VAIO and with the Linksys pccard reader. Approved by: jkh
* Add probing support for the vadem VG365 and the Vadem VG465 pcic chips.imp1998-08-251-6/+8
| | | | | | | | | We do the same thing we do with all the other Vadem chips and print the right identification for these chips. Tested with the 365, and inferred for the 465. This allows the cheapo PCMCIA card that I got from necx to print the right chip number on boot.
* Modem cards send the speaker audio (dialing noises) to the host'snate1997-10-061-0/+8
| | | | | | | | | speaker. Cirrus Logic PCIC chips must enable this. There is also a Low Power Dynamic Mode bit that claims to reduce power consumption by 30%, so enable it and hope for the best. PR: 4650 Submitted by: Nick Sayer <nsayer@quack.kfu.com>
* - Style policenate1997-10-061-9/+9
| | | | | | - Updated some comments using data from the most recent PAO release. Obtained (partially) from: PAO-970616
* 1. i82365.h: Chip identifiers should not be #ifdef PC98. Add identifierphk1997-04-201-2/+2
| | | | | | | | | | (pt. unused) for TI PCI1130. 2. pccard.c: PCIC_RESUME_RESET is now (also) a sysctl. (Never make it a #ifdef if it can be made a sysctl!) 3. pcic.c: make getb() and putb() proper member functions of struct pcic_slot. Add a couple of missing casts.
* The Great PC98 Merge.asami1996-06-141-0/+3
| | | | | | | | All new code is "#ifdef PC98"ed so this should make no difference to PC/AT (and its clones) users. Ok'd by: core Submitted by: FreeBSD(98) development team
* Updated PC-CARD support to contain most of the code from the latestnate1996-02-211-1/+5
| | | | | | | Japanese BSD-Nomad release. Reviewed by: phk Submitted by: hosokawa@mt.cs.keio.ac.jp and the rest of the Nomads
* Don't rely on the card 'automatically' powering up when we probe it.nate1996-01-061-0/+1
| | | | | | | | | | | On some laptops, this doesn't work (ie; IBM 75x series), so force it to power on. With this modification, I am able to read the tuples off 4 different PCMCIA cards on my ThinkPad. Reviewed by: phk@FreeBSD.org Obtained from: if_zp.c
* Clean up the ident style.phk1995-11-091-0/+1
| | | | | | | Remove the APM stuff Add support for VA469 Submitted by: Janic.Thaillandier@ratp.fr
* Andrew McRae's pcmcia/pccard code, the kernel part.phk1995-08-241-0/+207
This is still very green, but I have managed to get my modem working. Lots of work still to do, but now at least we can commit it. /phk Reviewed by: phk Submitted by: Andrew McRae <andrew@mega.com.au>
OpenPOWER on IntegriCloud