summaryrefslogtreecommitdiffstats
path: root/sys/dev/cardbus
Commit message (Collapse)AuthorAgeFilesLines
* MFp4:imp2004-06-271-14/+0
| | | | | | | The hack for setting the bus has been moved down into the cbb driver. I've been running without this hack in my tree for so long I had forgotten that I'd removed it :-). Please let me know if this causes difficulty for your laptop.
* Add some missing <sys/module.h> includes which are masked by thephk2004-05-301-0/+1
| | | | one on death-row in <sys/kernel.h>
* Add note about why we're ignoring the below 1MB bit.imp2004-04-111-0/+19
|
* Convert callers to the new bus_alloc_resource_any(9) API.njl2004-03-171-2/+1
| | | | | Submitted by: Mark Santcroos <marks@ripe.net> Reviewed by: imp, dfr, bde
* Make the cardbus driver a derived class of the pci driver. In theory, thisdfr2003-11-011-33/+2
| | | | should allow many of the pci methods to be re-staticised.
* remove obsolete quirks for cardbus cis. none have proven to be needed.imp2003-10-071-25/+3
|
* o move the cis tuple definitions into a common file.imp2003-10-072-79/+4
| | | | | | o minor optimization of cardbus_cis processing. Remove a bunch of generic entries that are handled by generic. o no longer need the card_get_type stuff.
* These aren't needed anymoreimp2003-10-071-3/+0
|
* Remove prototype for decode_tuple_copy() which was axed in the lastjhb2003-10-061-3/+0
| | | | revision to fix compile.
* remove the cardbus cis reading code. nobody ever used it and it hasimp2003-10-062-111/+0
| | | | locking issues down to the api level.
* Use PCIR_BAR(x) instead of PCIR_MAPS.jhb2003-09-021-1/+1
| | | | | Glanced over by: imp, gibbs Tested by: i386 LINT
* Use __FBSDID().obrien2003-08-242-2/+6
| | | | Also some minor style cleanups.
* Add a new PCI interface method, assign_interrupt, to determine thetmm2003-07-011-0/+1
| | | | | | | | | | | | | | | | interrupt to be used for a device. This is intended solely for internal use of PCI bus implementations, and exists so that PCI bus drivers implementing special interrupt assignment methods which require additional work at the bus level to work right can be easily derived from the generic driver (or any other one) without resorting to hacks. It will be used in the sparc64 ofw_pcibus driver, which will be committed shortly. Make use of this method in the generic implementation, and add it to the method table of bus drivers derived from the PCI one. Reviewed by: imp, -hackers
* Don't leak "barlist" allocation on failure.phk2003-06-011-0/+4
| | | | Found by: FlexeLint
* Ignore the 'must allocate below 1MB' flag for the TPL_BAR_REG. It isimp2003-05-241-0/+2
| | | | | | | | | | | | set on realtek cards, but they work without it (and don't work with it). The standard seems to imply that this is just a hint anyway, so this should be harmless. It doesn't appear to be set on any other cardbus cards that I have (or have seen). This should make the rl based CardBus cards work again. I've been running it for about a month now. Approved by: re@ (jhb)
* MFp4: when you can't allocate a resource, print a message, don't panic.imp2003-04-081-0/+19
|
* Back out M_* changes, per decision of the TRB.imp2003-02-191-3/+3
| | | | Approved by: trb
* Move the resource handling down into the pci bus as well.imp2003-02-182-410/+49
| | | | | | | | | | | Minor CIS resource allocation code cleanup Remove some fairly useless debug writes. This finishes the work to move as much cardbus code as possible into pci. We wind up removing 800-odd lines from cardbus.c: we go from 1285 to 400 lines. Reviewed by: mdodd
* Sanity check the BAR length reported by the CIS with the BAR length thatscottl2003-02-171-4/+22
| | | | | | | | is encoded in the PCI BAR. The latter is more reliable. This allows the sio/modem function of the Xircom RealPort ethernet+modem card to work. Note that there still seem to be issues with sio_pci not releasing resources on detach.
* Move the pnp and location info into the common pci bus. Make all knownimp2003-02-171-46/+4
| | | | | | | | | pci busses implement this. Also minor comment smithing in cardbus. Fix copyright to this year with my name on it since I've been doing a lot to this file. Reviewed by: jhb
* Kill a now-bogus commentimp2003-02-171-4/+0
|
* Move call to pci_print_verbose until after all the variables that itimp2003-02-171-1/+1
| | | | | | depends on. Pointy hat to: imp (anybody know if these things are accepted at Eco-Cycle?)
* Checkpoint a work in progress:imp2003-02-161-532/+23
| | | | | | | | | | | | | | | | | | o Use the common pci_* routines in preference to the copied and hacked routines from an ancient pci.c. This saves 509 lines in cardbus.c. More savings to follow when I convert the resource code over. In the past when I've done this the resource code conversion breaks cardbus in subtle ways so I'm doing a 1/2 way checkpoint this time. cardbus still works for me the same as it did before. It also looks like cardbus devices now show up as pci bus devices to pciconf -l, but maybe that was happening before. Inspired by a patch from Justin Gibbs many moons ago. When he finishes his kobj multiple inheritance work, we can transition the finished version of this work to that fairly easily.
* Clean up the CIS BAR parsing code by removing several pointless checks.scottl2003-02-161-19/+19
| | | | Don't complain about the Option ROM BAR type since it's perfectly valid.
* MF-p4:imp2003-02-121-80/+154
| | | | | | | | | | | | | Kill the slightly bogus #define for DECODE_PROTOTYPE Be less verbose. Hide most (all I hope) of the CIS parsing behind cardbus_debug_cis (which is set with hw.cardbus.debug_cis=1). This doesn't fix problems with parsing, but should make cardbus less chatty. There appears to be some issues still with the parsing of the CIS, but this won't fix them. Prompted by: scottl
* MFp4:imp2003-02-121-0/+11
| | | | | | | | | | | Second part of the kldload patches for cardbus. This makes kldload of a driver for a device that's inserted now appears to work. To make it work, we only do a power cycle of the card if there's no children drivers attached. This likely is papering over bogosities in the power system. The power sequence needs to be re-written, so I'll not worry about the papering over until the re-write.
* MFp4:imp2003-02-121-7/+5
| | | | Don't reach inside of rman to r_dev. Use rman_get_device instead.
* Whitespace nits.imp2003-02-121-2/+2
|
* Don't turn off the power of cards when new drivers are addedimp2003-02-111-19/+13
| | | | | | | | unconditionally. kldloading a cardbus driver was shooting down other attached devices because most drivers assume that one cannot power-cycle cards w/o the driver knowning about it. Submitted by: simokawa-san
* MFp4:imp2003-01-274-63/+63
| | | | u_int*_t -> uint*_t to conform more closely with C99.
* Remove M_TRYWAIT/M_WAITOK/M_WAIT. Callers should use 0.alfred2003-01-212-4/+4
| | | | Merge M_NOWAIT/M_DONTWAIT into a single flag M_NOWAIT.
* Need more parens here.imp2002-11-271-1/+1
| | | | Approved by: re (blanket)
* Implement PCI_IVAR_ETHADDR. Cardbus has the MAC addr in the CIS,imp2002-11-274-3/+97
| | | | | | | | sometimes, so return it when requested and it does. Also a little more infrastructure for a few other things. Submitted by: sam Approved by: re (blanket for NEWCARD)
* MFp4:imp2002-11-141-10/+7
| | | | | o Add a diagnostic for an 'impossible' condition. o Collapse common code.
* minor correction to commentimp2002-11-141-1/+1
|
* When parsing the CIS, if a BAR tuple is encountered, enable the correspondingscottl2002-11-131-0/+5
| | | | | | | | | bit in the PCI command register for the device. Otherwise, device drivers that look at this register to see which types of BARs are usable will think that none of them are. This allows my Adaptec 1480A cardbus card to finally work. Reviewed by: imp
* Fix two typos from the previous commit. This code is definitely infectious.scottl2002-11-121-2/+2
|
* Step one of cleaning and fixing cardbus:scottl2002-11-121-65/+92
| | | | | | | | | | | | | - Fix some especially bad style in the CIS BAR tuple parsing code. - activate Option ROMS correctly. - de-obfuscate the Option ROM image selection code. - Fix mis-interpretation of the PCI spec that prevented Option ROMs whose CIS section wasn't in the first image from working. - Fix mis-interpretation of the PCI spec that prevented CIS's mapped into MEMIO space from working at all. - Reject invalid CIS pointers. Reviewed by: imp
* Use the explicit value 0xffffffff instead of assuming that is what ~0ULjhb2002-11-061-1/+1
| | | | | | equals. Approved by: imp
* MFp4:imp2002-11-021-36/+25
| | | | | | | | | | | | | | | o Always release the resources on device detach. o Attach resources the same with driver added as we do we do in the insert case (maybe this should be a routine). o signal the wakeup of the thread on resume instead of trying to force an interrupt. o Minor debug hacks. o use 0xffffffff instead of -1 for uint32_t items. o Don't complain when we're asked to detach no cards. This is normal. o Eliminate the now worthless second parameter to card_detach_card. o minor style(9)isms Some of these patches may be from: iwasaki-san, jhb, iadowse
* o Add routines to return the location and pnpinfo for this card.imp2002-10-071-46/+83
| | | | | | | | | | | | Note, we return the PCI pnp info, but in fact that's wrong to do since that data is not defined for CardBus cards. CardBus says that these registers are undefined and one should use the CIS to do device matching. To date, all CardBus cards have had these registered defined, no doubt because they are using common silicon to produce both the PCI cards and the CardBus cards. However, it isn't any worse than the rest of the system, so just note it in passing and move on. o Also sort prototypes while I'm here.
* Don't abuse the fact that -a == ~a + 1. Signed vs unsigned checkersimp2002-10-071-1/+1
| | | | | | | complain when a is a unsigned type. So instead use the latter here and be on our way. Spotted by: flexlint by way of phk
* Add extra set of parens around the barbit macro to make it clear whatimp2002-10-071-1/+1
| | | | | | we're intending to shift. Spotted by: flexlint by way of phk (should fix about 40 messages)
* Don't leak the bar list for each thing we allocate.imp2002-09-291-1/+3
| | | | | | # This code really needs a rewrite Spotted by the eagle eyes of: phk
* - Forgot to remove `cardattached` declaration in revision 1.22.arr2002-09-101-1/+1
|
* Remove more bogus reprobe code. I don't think it is needed here either.imp2002-09-101-14/+1
|
* pccbb -> cbbimp2002-08-151-1/+1
|
* Silence warning.alfred2002-06-011-2/+2
| | | | | When casting a "const void *" to a "struct foo **" you want to actually cast it to "struct foo * const *" not simply "const struct foo **".
* Make oldcard and newcard kernel module work.takawata2002-05-302-2/+4
|
* Revert most of the recent PCI merge. This has proven to be tooimp2002-03-152-126/+971
| | | | | unstable for the coming DP1 release. Instead, I'll develop that on the IMP_CB_MERGE branch until it is more stable.
OpenPOWER on IntegriCloud