summaryrefslogtreecommitdiffstats
path: root/sys/dev/pccbb
Commit message (Collapse)AuthorAgeFilesLines
* Start each of the license/copyright comments with /*-, minor shuffle of linesimp2005-01-066-6/+6
|
* Add recognition of O2Micro 711M1.imp2004-12-232-0/+2
| | | | Submitted by: Gordon Bergling
* Don't need to declare cbb module. don't know why I never sawimp2004-08-162-2/+0
| | | | duplicate messages..
* Move towards isa attachment for pccbb. This is a work in progress, butimp2004-08-124-690/+1086
| | | | works well with the pci attachment.
* Add IDs from TI's web site. Reports from the field and inspection ofimp2004-07-222-1/+14
| | | | | | | | | | | the data sheets leads me to believe these will just work. Those parts with the various media readers on them may not have the required FreeBSD drivers that will attach to the subdevices that will be seen on some of these parts. PCI 1515, 1530, 1620, 4520, 6411, 6420, 7410, 7510, 7610 Prompted by: Havard Eidnes
* More TI device IDs.imp2004-07-221-0/+3
| | | | | | These are from the datasheets downloaded from TI's web site. They describe the PCI[67]x[12]1 and PCI[67]x20 parts, with and without the smartcard enabled.
* Update comment about fast interrupts to be closer to realityimp2004-07-221-0/+4
|
* Improve the kludge assignment of sub-bus numbers a little by fixing animp2004-06-231-1/+1
| | | | | | | off by one error. subbus must be > than pribus, so the right test is <= not just <. Reported by: Peter Losher
* Add some missing <sys/module.h> includes which are masked by thephk2004-05-301-0/+1
| | | | one on death-row in <sys/kernel.h>
* When attaching pccard and cardbus children, there's no need to set theimp2004-05-211-6/+2
| | | | | | | device == NULL on failure. A warning should suffice. # I wrote this back before I understood the unattached but loosely bound # newbus concept...
* Now that we have the resource allocation code in current, the kludgeimp2004-05-212-56/+10
| | | | | | | | to try to allocate things on my parent can be taken out. It duplicates code. Also, add comment about why the power state stuff is here (type 2 devices don't participate in the power state save/restore due to larger Bx issues).
* Need to mark the interrupt from cbb as being MP safe on resume too.imp2004-05-041-2/+2
|
* Start programming the bus numbers for the pci<->cardbus. When theimp2004-04-231-1/+30
| | | | | | | | | | | | | secondary bus is 0, we program the primary bus, the secondary bus and the suborindate bus. This isn't ideal, since we start at parent_bus + 1 and store this in a static. Ideally, we'd walk the tree and assign bus numbers. However, that's harder to accomplish without some help from the bus layer which we're not planning on doing that until 6. This fixes my CardBus problems on my Sony PCG-Z1WA, and might fix the Dells that have had problems.
* Remove extra copy of code.imp2004-04-131-7/+0
| | | | Noticed by: Carlos Velasco
* MFp4:imp2004-04-121-4/+15
| | | | | | | | | | | Alignment for pccards should also be treated in a similar way that we tread it for cardbus cards. Remove bogus debugs while I'm here. # This is also necessary to make the CIS reading work. Submitted by: Carlos Velasco
* Better checks to make sure that we get good alignment. This code is aimp2004-04-061-7/+6
| | | | | bit of a bandaide until I get better pci bus code committed to head from my p4 tree.
* Fix mis-merge from p4 by adding line getting sc.imp2004-04-061-2/+9
| | | | Attempt to deal with larger memory allocation better.
* MFP4: Power up with OE disabled. Similar patches went into NetBSD aimp2004-04-061-1/+6
| | | | | while ago, and it does seem to help at least one card I have and has been in my p4 tree for many months.
* Convert callers to the new bus_alloc_resource_any(9) API.njl2004-03-171-3/+3
| | | | | Submitted by: Mark Santcroos <marks@ripe.net> Reviewed by: imp, dfr, bde
* kthread_exit() no longer requires Giant, so don't force callers to acquirejhb2004-03-051-1/+0
| | | | | | Giant just to call kthread_exit(). Requested by: many
* MFp4:imp2004-01-042-5/+5
| | | | | | o O2Micro OZ711e1 is now recognized (note: I don't have one, and the current owner of the Dell laptop is reporting problems). o minor nits wrt copyright date.
* Fix typo in ENE CB710 description. It isn't a 720.imp2003-12-221-1/+1
|
* Fix a harmless typo (use of res instead of rle: if rle is NULL, we'dimp2003-11-121-3/+4
| | | | | | | still get a panic, just not a nice message) and update to new __FBSDID. Submitted by: charnier@
* -Wunusedimp2003-11-081-1/+1
|
* Remove channeling interrupts to IRQ1. Some chipsets don't do theimp2003-11-071-0/+7
| | | | expected thing and that causes interference with keyboards.
* Backswards is as backwards does: If we're MPSAFE, then we don't needimp2003-10-241-2/+2
| | | | | | | | giant, which implies that we need to take out giant it we're NOT MPSAFE. # I can't believe the number of people that looked at this failed to # detect this.
* Add newly discovered ENE Technologies CardBus bridges to the list:imp2003-08-222-0/+16
| | | | | | | | CB710, CB720, CB1211, CB1225, CB1410 and CB1420 These are likely licensed designed from TI, and the Linux PCMCIA code treats them as TI chips. Add comment, but no ID for the 711E1 from O2Micro.
* Prefer new location of pci include files (which have only been in theimp2003-08-221-2/+2
| | | | | tree for two or more years now), except in a few places where there's code to be compatible with older versions of FreeBSD.
* In my efforts to make checking the CD bits less error-prone, Iimp2003-08-201-1/+1
| | | | | | | introduced an error. In power_enable_socket, we only return ENODEV if there isn't a card, not if there is a card. Ooops. Pointy hat to: bsdimp
* Fix typo in last commit.mux2003-08-201-1/+1
|
* Use CBB_CARD_PRESENT instead of checking STATE_CD directly since it isimp2003-08-201-4/+6
| | | | hard to get right.
* The CD bits in the CBB_SOCKET_STATE register are 0 when the card isimp2003-08-181-4/+3
| | | | | | | | | | | | | present, and non-zero when it is (or may be) absent. The test cbb_child_present was backwards. However, typical usage in the tree would cause it to do the right thing because the card really wasn't there the OK flag would be turned on. Also, assume that if any of these bits are turned on we don't have a card, rather than requiring both of them in the suspend/resume routines. Noticed by: cognet
* Put the clearing of the socket cd interrupt and setting of it underimp2003-08-181-10/+8
| | | | | protection of sc->mtx. Sometimes multiple insert/ejections could cause further insertion/removals to not happen due to racing an ISR...
* trivial optimization: use nameunit here.imp2003-08-141-1/+1
|
* MF p4:imp2003-08-101-1/+1
| | | | Minor style(9) nit.
* Some bridges, like o2 micro and maybe ricoh, have some issues betweenimp2003-08-101-10/+47
| | | | | | | | | | | | | | | the time the card is inserted and the time that the card is configured. This can lead to interrupt storms. The O2Micro suggested workaround is to route the card function interrupt to IRQ1. It appears from my testing that this is an acceptable workaround for most chipsets (there's still some issue with the ricoh chipset). Also, only look at the NOT_A_CARD bit when the bridge tells us there's a card present. At least one test caused this to be true after the card was removed, but the author couldn't recreate it with the workaround in place. The change is more conservative than the previous code, but still has the work around that wasn't present in the older code.
* Add code to cope more with strange conditions after careful study ofimp2003-08-091-14/+42
| | | | | | | | | | | | | | | | | | | | | | the standard. 1) When the bridge tells us that we have a card that isn't recognized, we use the force register to force the CV_TEST to run. This test causes the bridge to re-evaluate the card. Once this re-evaluation process happens, we get a new interrupt that may say it is ready to process. We try this up to 20 times. Tests have shown that this appears to correctly reset the 'Unknown card type' problem that I saw on my Sony PCG-505TS. 2) Take a page from OLDCARD and always read the CSC register in the ISR. Some TI (and it seems maybe Ricoh) chipsets require this to behave properly. This work around appears to work due to some power management protocols that were improperly implemented. Maybe it can be removed when this driver supports the full PME# protocol described in the standards. 3) Minor additional debug printf when debugging is enabled. 4) Minor additional commentary for things that are obvious only after study. # I'm committing this from my Sony PCG-505TS using shared PCI interrupts # and NEWCARD, but there are some issues with the Ricoh bridge still, but # at least now I can boot with the card inserted and have it work.
* CBB_SOCKET_STAT_ is too long. Change it to CBB_STATE_. Also, makeimp2003-08-092-31/+44
| | | | | | some minor changes to more closely match the bit names used in the 7.0 version of the PCMCIA standard. Also add bits from the FORCE register.
* When allocating memory, align it to the minimum alignment required forimp2003-08-092-0/+5
| | | | cardbus bridges if the alignment requirements were less restrictive.
* Add comments about some alignment that looks a little strange.imp2003-08-091-2/+9
|
* Minor fixes to a couple of comments.imp2003-08-091-2/+2
|
* Consistently use the BSD u_int and u_short instead of the SYSV uint andjhb2003-08-071-5/+5
| | | | | | | ushort. In most of these files, there was a mixture of both styles and this change just makes them self-consistent. Requested by: bde (kern_ktrace.c)
* All current uses of pci_set_powerstate are bogus, at least in theory.imp2003-07-031-2/+3
| | | | | | | | | | However, they are presently necessary due to bigger bogusness in the pci bus layer not doing the right thing on suspend/resume or on initial device probe. This is exactly the sort of thing that the BURN_BRIDGES option was invented for. Mark all of them as BURN_BRIDGES. As soon as I have the powerstate stuff properly integrated into the pci bus code, I intend to remove all these workarounds.
* Unlock after ISR.imp2003-06-121-1/+1
| | | | | Noticed by: njr Pointy hat to: the impable one.
* s/BURN_THE_BOATS/BURN_BRIDGES/g to adopt to new world orderimp2003-06-121-2/+2
|
* Make cbb interrupts MPSAFE:imp2003-06-122-22/+34
| | | | | | | | | | | | | | | | o Register ISR INTR_MPSAFE. o Loop on KTHREAD_DONE == 0 in the thread. o Safe the INTR_MPSAFE flag for client drivers (don't know if there are any CardBus/PCI drivers that are INTR_MPSAFE) o Read status after acquiring mtx_lock(Giant) rather than before so that we catch state changes that happen while Giant is being acquired. o Turn off the CD bit when we see a CD interrupt, and turn it back on after we've attached/detached the card. o On suspend, actually set the CBB_SOCKET_MASK to zero rather than oring in '0' to turn it off on suspend. o If the ISR that's registerd is MPSAFE, don't acquire Giant around call to client ISR. o Fix comments to reflect these changes.
* MFp4:imp2003-06-072-54/+13
| | | | Migrate some common pccard code into exca.
* Simplify the power code somewhat (this makes the module about 100imp2003-06-072-85/+34
| | | | bytes smaller).
* Add two of three workarounds for interrupt storms for o2micro parts asimp2003-06-062-14/+145
| | | | | | | | | obtained from o2micro. These should only be needed for 'older' o2micro bridges (anything before the 7xxx series of bridges), but will work with the new bridges. # I don't plan on porting it to oldcard, but will happily commit to # oldcard if someone else needs them.
* Remove return after goto.phk2003-05-311-2/+0
| | | | | | Remove break after return; Found by: FlexeLint
OpenPOWER on IntegriCloud