aboutsummaryrefslogtreecommitdiff
path: root/sys/pccard
Commit message (Collapse)AuthorAgeFilesLines
* $Id$ -> $FreeBSD$Peter Wemm1999-09-062-2/+2
| | | | Notes: svn path=/head/; revision=51009
* Kludge together support for the old pccard system with newbus. ThisWarner Losh1999-09-065-19/+388
| | | | | | | | | | | will allow newbus based drivers to have pccard attachments. Also start printing out probe messages for pccards stating the resources used and regularize many of the pccard printfs. Reviewed by: Peter Wemm. Notes: svn path=/head/; revision=50991
* $Id$ -> $FreeBSD$Peter Wemm1999-08-284-4/+4
| | | | Notes: svn path=/head/; revision=50477
* Convert DEVFS hooks in (most) drivers to make_dev().Poul-Henning Kamp1999-08-232-13/+2
| | | | | | | | | | | | | | | | | | | Diskslice/label code not yet handled. Vinum, i4b, alpha, pc98 not dealt with (left to respective Maintainers) Add the correct hook for devfs to kern_conf.c The net result of this excercise is that a lot less files depends on DEVFS, and devtoname() gets more sensible output in many cases. A few drivers had minor additional cleanups performed relating to cdevsw registration. A few drivers don't register a cdevsw{} anymore, but only use make_dev(). Notes: svn path=/head/; revision=50254
* (1) Fix a spelling mistake in a comment.Bill Fumerola1999-08-171-2/+3
| | | | | | | | | (2) Add braces to avoid ambigious if/if/else Reviewed by: bde Notes: svn path=/head/; revision=49990
* o Add additional printfs for error cases when we can't attach the device.Warner Losh1999-08-013-9/+29
| | | | | | | | | | | o Add field to dev_desc for the size of the io port range. This isn't used yet in the committed sources, but will make the transition easier in the future. If you build this into your kernel, you will need to rebuild pccardd. Notes: svn path=/head/; revision=49352
* Eliminate a bunch of #include "pci.h" and #if NPCI > 0 around entirePeter Wemm1999-07-031-5/+1
| | | | | | | files. config will leave the whole file out if configured to do so. Notes: svn path=/head/; revision=48528
* Simplify cdevsw registration.Poul-Henning Kamp1999-05-311-16/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | The cdevsw_add() function now finds the major number(s) in the struct cdevsw passed to it. cdevsw_add_generic() is no longer needed, cdevsw_add() does the same thing. cdevsw_add() will print an message if the d_maj field looks bogus. Remove nblkdev and nchrdev variables. Most places they were used bogusly. Instead check a dev_t for validity by seeing if devsw() or bdevsw() returns NULL. Move bdevsw() and devsw() functions to kern/kern_conf.c Bump __FreeBSD_version to 400006 This commit removes: 72 bogus makedev() calls 26 bogus SYSINIT functions if_xe.c bogusly accessed cdevsw[], author/maintainer please fix. I4b and vinum not changed. Patches emailed to authors. LINT probably broken until they catch up. Notes: svn path=/head/; revision=47640
* This commit should be a extensive NO-OP:Poul-Henning Kamp1999-05-301-5/+22
| | | | | | | | | | | | | | | | Reformat and initialize correctly all "struct cdevsw". Initialize the d_maj and d_bmaj fields. The d_reset field was not removed, although it is never used. I used a program to do most of this, so all the files now use the same consistent format. Please keep it that way. Vinum and i4b not modified, patches emailed to respective authors. Notes: svn path=/head/; revision=47625
* Simplify the COMPAT_PCI_DRIVER/DATA_SET hack. We can add:Peter Wemm1999-05-091-5/+1
| | | | | | | | | | | #define COMPAT_PCI_DRIVER(name,data) DATA_SET(pcidevice_set,data) .. to 2.2.x and 3.x if people think it's worth it. Driver writers can do this if it's not defined. (The reason for this is that I'm trying to progressively eliminate use of linker_sets where it hurts modularity and runtime load capability, and these DATA_SET's keep getting in the way.) Notes: svn path=/head/; revision=46813
* Unbreak slot_irq_handler(). The problem here is that slot_irq_handler()Bill Paul1999-05-041-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | abuses its argument, which is supposed to be an integer unit number, as a pointer to the head of the 'struct slot' list. When this code was hacked^Wupdated for newbus, a new mechanism for registering slot_irq_handler() was put in place and the significance of the unit number was overlooked. When registering an interrupt, we have both device_id and unit. The unit number is passed as 'unit' but /sys/i386/usa/intr_machdep.c:register_intr() drops unit on the floor and uses device_id instead. Since pccard_alloc_intr() always sets device_id to 0, this means the unit number is always zero, and slot_irq_handler() is always called with 0, which becomes a NULL pointer which slot_irq_handler() tries to dereference and the kernel explodes. Result: if you assign a PCMCIA driver in the kernel config file like this: device wi0 at isa? port? irq? Then the system will panic the moment a PCMCIA device is attached and an interrupt is triggered. The quick fix: make pccard_alloc_intr() pass the unit number as both the device_id and unit arguments to register_pcic_intr(). The correct fix would be to rewrite /sys/pccard to be less disgusting. Notes: svn path=/head/; revision=46417
* Operator precedence (nit: in #if 0 code) bug.Peter Wemm1999-05-021-1/+1
| | | | | | | | PR: 11413 Submitted by: Christopher Peterson <cpeterso@cs.washington.edu> Notes: svn path=/head/; revision=46341
* - Added PCI identification support for the TI1251 PCI/CardBus bridge.Nate Williams1999-05-022-2/+5
| | | | | | | | With this addition my ThinkPad 600E works with the stock FreeBSD PCMCIA code. Notes: svn path=/head/; revision=46253
* - When the card is inserted, call pccard_insert_beep instead ofNate Williams1999-05-021-2/+2
| | | | | | | | | pccard_remove_beep. Submitted by: PAO Notes: svn path=/head/; revision=46246
* Eliminate compiler warning about missing type in declaration.John Polstra1999-04-271-3/+2
| | | | | | | | | | Remove useless initialization of static variable to 0. Move static variable declaration into the only function that uses it. Notes: svn path=/head/; revision=46121
* Fix the code that prints the "Initializing PC-card drivers" messageJohn Polstra1999-04-271-4/+3
| | | | | | | | | | | so that the list of drivers is correct. This is a slightly simplified version of the patch from the PR. PR: misc/10544 Submitted by: Christophe Colle <colle@krtkg1.rug.ac.be> Notes: svn path=/head/; revision=46119
* Suser() simplification:Poul-Henning Kamp1999-04-271-5/+5
| | | | | | | | | | | | | | | | | | | | | | 1: s/suser/suser_xxx/ 2: Add new function: suser(struct proc *), prototyped in <sys/proc.h>. 3: s/suser_xxx(\([a-zA-Z0-9_]*\)->p_ucred, \&\1->p_acflag)/suser(\1)/ The remaining suser_xxx() calls will be scrutinized and dealt with later. There may be some unneeded #include <sys/cred.h>, but they are left as an exercise for Bruce. More changes to the suser() API will come along with the "jail" code. Notes: svn path=/head/; revision=46112
* Use COMPAT_PCI_DRIVER() for registration if it exists. This shouldn'tPeter Wemm1999-04-241-1/+5
| | | | | | | hurt the driver portability to 3.x too much for where drivers are shared. Notes: svn path=/head/; revision=46024
* Well folks, this is it - The second stage of the removal for build supportPeter Wemm1999-04-172-2/+1
| | | | | | | for LKM's.. Notes: svn path=/head/; revision=45739
* Import PCI pccard bridge chip probing from PAO. Hopeful prelude forNick Sayer1999-04-012-13/+44
| | | | | | | | | | broadening chipset support in -current. Reviewed by: joerg Obtained from: PAO Notes: svn path=/head/; revision=45233
* - Made the setting of the machdep.pccard.pcic_irq from the boot config fileNate Williams1999-03-261-5/+6
| | | | | | | | | actually work. Reviewed by: "Sean O'Connell" <sean@stat.Duke.EDU>, msmith Notes: svn path=/head/; revision=45043
* Remove static delcarations from {,un}register_pcic_intr declarationsWarner Losh1999-03-121-2/+2
| | | | | | | | | | | in the not APIC_IO case. This should silence the warnings when building pcic.c as well as the undefined functions when the kernel links. Noticed by: several people in -current and me building the kernel Notes: svn path=/head/; revision=44692
* Updated to use new APIC (SMP) safe interrupt register/unregisterRoger Hardiman1999-03-102-7/+48
| | | | | | | | | | functions. Posted for review to -smp and -mobile and -hackers with no objections. Reviewed by: Nate Notes: svn path=/head/; revision=44637
* Header file for pcic interrupt register/unregister functions.Roger Hardiman1999-03-101-0/+36
| | | | | | | No objections from -smp or -mobile or -hackers. Notes: svn path=/head/; revision=44636
* On second thought: do previous fux in pcic.c better.Guido van Rooij1999-02-142-9/+3
| | | | | | | Now we just untimeout the call to inserted() if it exists. Notes: svn path=/head/; revision=44015
* Somehow, it is possible to get a pcicintr() when in the resume process.Guido van Rooij1999-02-141-1/+8
| | | | | | | | | | This will trigger inserted()) to be called twice which confuses pccardd. Add code to not process pcicitr())'s when in the middle of a resume process. The real insertion of cards and the emulated one in the suspend/resume code really do not mix up. Notes: svn path=/head/; revision=44013
* Add "beep" ioctl. (#10 is reserved for PIOCSVIR)Jun Kuriyama1999-02-134-4/+14
| | | | | | | | Obtained from: PAO3 Reviewed by: -current list Notes: svn path=/head/; revision=43964
* Allow the interrupt allocated to the PCIC to be tuned from the kernelMike Smith1999-01-291-1/+13
| | | | | | | | environment by setting the variable machdep.pccard.pcic_irq. If the IRQ is invalid, the PCIC will run in polled mode. Notes: svn path=/head/; revision=43370
* Fix warnings in preparation for adding -Wall -Wcast-qual to theMatthew Dillon1999-01-271-4/+4
| | | | | | | | | | kernel compile. This commit includes significant work to proper handle const arguments for the DDB symbol routines. Notes: svn path=/head/; revision=43309
* Include <sys/select.h> -- don't depend on pollution in <sys/proc.h>.Bruce Evans1999-01-271-1/+2
| | | | Notes: svn path=/head/; revision=43278
* Identify the TI1250 PCMCIA/CardBus bridge. It seems that it's compatibleTorsten Blum1999-01-252-2/+5
| | | | | | | to the TI1131. At least it works in my Compaq Armada 7800. Notes: svn path=/head/; revision=43193
* Initial update pccard code for KLD module support. Module supportPeter Wemm1999-01-195-156/+84
| | | | | | | | | however is only marginally useful until the new-style bus (pci and isa) stuff comes onboard to give us a better shot at actually pci and isa drivers loadable (or preloadable anyway). Notes: svn path=/head/; revision=42819
* probe function changed from returning char * to const char *.Matthew Dillon1998-12-141-3/+3
| | | | Notes: svn path=/head/; revision=41771
* The "easy" fixes for compiling the kernel -Wunused: remove unreferenced staticArchie Cobbs1998-12-071-1/+1
| | | | | | | and local variables, goto labels, and functions declared but not defined. Notes: svn path=/head/; revision=41591
* Add #include to get a prototype for update_intr_masks().Peter Wemm1998-11-091-1/+2
| | | | Notes: svn path=/head/; revision=41032
* - Fix a bug where a "power_off_slot' timeout was not cancelled when theNate Williams1998-09-241-1/+6
| | | | | | | | | | | computer 'suspended', although the slot was powered off. There was a race where the slow could be powered off *after* it was assigned a new driver when the computer was 'resumed'. Noticed by: Brian Somers <brian@Awfulhak.org> Notes: svn path=/head/; revision=39631
* Make PCIC_RESUME_RESET an proper option.Brian Somers1998-09-081-3/+4
| | | | | | | | | My laptop (a CTX Cybernote) needs this. It claims to have a PC-Card VLSI 82C146 (5 mem & 2 I/O windows) Notes: svn path=/head/; revision=38953
* o renable pccard_remove_driver (it was used in the skel.c driver)Warner Losh1998-08-262-22/+22
| | | | | | | | o update skel.c to lots of stuff that has happened since the last time it was updated. Notes: svn path=/head/; revision=38552
* Add probing support for the vadem VG365 and the Vadem VG465 pcic chips.Warner Losh1998-08-252-12/+38
| | | | | | | | | | | | 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. Notes: svn path=/head/; revision=38548
* Fixed printf format errors.Bruce Evans1998-08-181-4/+4
| | | | Notes: svn path=/head/; revision=38412
* Use [u]intptr_t instead of [u_]long for casts between pointers andBruce Evans1998-08-162-7/+9
| | | | | | | integers. Don't forget to cast to (void *) as well. Notes: svn path=/head/; revision=38354
* Changed the type of an isa/general interrupt handler to take aBruce Evans1998-06-182-7/+7
| | | | | | | | | `void *' arg. Fixed or hid most of the resulting type mismatches. Handlers can now be updated locally (except for reworking their global declarations in isa_device.h). Notes: svn path=/head/; revision=37050
* This commit fixes various 64bit portability problems required forDoug Rabson1998-06-071-2/+2
| | | | | | | | | | | | | FreeBSD/alpha. The most significant item is to change the command argument to ioctl functions from int to u_long. This change brings us inline with various other BSD versions. Driver writers may like to use (__FreeBSD_version == 300003) to detect this change. The prototype FreeBSD/alpha machdep will follow in a couple of days time. Notes: svn path=/head/; revision=36735
* Include pc98.h instead of isa.h when PC98 is defined.KATO Takenori1998-05-051-1/+5
| | | | Notes: svn path=/head/; revision=35748
* - Give up trying for a simple solution for correctly recognizing if a cardNate Williams1998-04-202-1/+5
| | | | | | | | | | | | | | was really removed, or simply 'faked' by a suspend/resume. Keep track of both current and previous state, and send that information to the userland programs. [ XXX - This breaks binary compatability with older pccardd programs, but they don't work reliably. :( ] Notes: svn path=/head/; revision=35345
* - Only poll the PCIC controller for insertion/removal events if theNate Williams1998-04-201-3/+4
| | | | | | | controller hasn't been assigned an IRQ. Notes: svn path=/head/; revision=35344
* Support compiling with `gcc -ansi'.Bruce Evans1998-04-151-7/+7
| | | | Notes: svn path=/head/; revision=35210
* - Whoops, better have the structure created before trying to use it inNate Williams1998-04-091-2/+2
| | | | | | | | | the patch I just submitted. Noticed by: phk Notes: svn path=/head/; revision=35109
* - Fix bug I introduced a few months ago. If a driver fails the probe,Nate Williams1998-04-081-4/+4
| | | | | | | | | | | correctly unregister the interrupt from the system. [ My fix is much simpler than the one provided in the PR ] PR: 6249 Notes: svn path=/head/; revision=35101
* Uninitialized pointer reference may happen on particular environment.Tatsumi Hosokawa1998-03-191-1/+6
| | | | | | | (for example, it kills my new laptop, Toshiba Libretto 100....) Notes: svn path=/head/; revision=34686