summaryrefslogtreecommitdiffstats
path: root/sys/dev
Commit message (Collapse)AuthorAgeFilesLines
* plug memory leaksam2005-02-251-13/+25
| | | | | Noticed by: Coverity Prevent analysis tool Reviewed by: emax
* Correct e-mail address in copyright.wpaul2005-02-251-1/+1
|
* avoid sneaky double freesam2005-02-251-1/+5
| | | | | Noticed by: Coverity Prevent analysis tool Reviewed by: scottl
* Apparently, the probe routine in if_ndis_usb.c can be called twicewpaul2005-02-242-9/+9
| | | | | | | | | | for a given device in some circumstances, so move the PDO creation to the attach routine so we don't end up creating two PDOs. Also, when we skip the call to ndis_convert_res() in if_ndis.c:ndis_attach(), initialize sc->ndis_block->nmb_rlist to NULL. We don't explicitly zero the miniport block, so this will make sure ndis_unload_driver() does the right thing.
* Fix style(9) issues with __P removal.imp2005-02-246-271/+259
| | | | Noticed by: bde
* - Correct one aspect of the driver_object/device_object/IRP framework:wpaul2005-02-244-18/+211
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | when we create a PDO, the driver_object associated with it is that of the parent driver, not the driver we're trying to attach. For example, if we attach a PCI device, the PDO we pass to the NdisAddDevice() function should contain a pointer to fake_pci_driver, not to the NDIS driver itself. For PCI or PCMCIA devices this doesn't matter because the child never needs to talk to the parent bus driver, but for USB, the child needs to be able to send IRPs to the parent USB bus driver, and for that to work the parent USB bus driver has to be hung off the PDO. This involves modifying windrv_lookup() so that we can search for bus drivers by name, if necessary. Our fake bus drivers attach themselves as "PCI Bus," "PCCARD Bus" and "USB Bus," so we can search for them using those names. The individual attachment stubs now create and attach PDOs to the parent bus drivers instead of hanging them off the NDIS driver's object, and in if_ndis.c, we now search for the correct driver object depending on the bus type, and use that to find the correct PDO. With this fix, I can get my sample USB ethernet driver to deliver an IRP to my fake parent USB bus driver's dispatch routines. - Add stub modules for USB support: subr_usbd.c, usbd_var.h and if_ndis_usb.c. The subr_usbd.c module is hooked up the build but currently doesn't do very much. It provides the stub USB parent driver object and a dispatch routine for IRM_MJ_INTERNAL_DEVICE_CONTROL. The only exported function at the moment is USBD_GetUSBDIVersion(). The if_ndis_usb.c stub compiles, but is not hooked up to the build yet. I'm putting these here so I can keep them under source code control as I flesh them out.
* Return BUS_PROBE_DEFAULT instead of 0.imp2005-02-2414-20/+20
|
* Split the chip-specific code from the generic Utopia code. This simplifiesharti2005-02-245-923/+1120
| | | | | adding of new physical chips. Now one just needs to add a .h and a .c file for the new chip and add one line to utopia.c for that chip.
* plug resource leaksam2005-02-241-0/+1
| | | | | Noticed by: Coverity Prevent analysis tool Reviewed by: scottl
* remove gratuitous null ptr checksam2005-02-241-2/+1
| | | | Noticed by: Coverity Prevent analysis tool
* o nuke duplicate call of dpt_free when dpt_init failssam2005-02-241-3/+1
| | | | | | | o nuke gratuitous null ptr check; softc can never be null in this routine Noticed by: Coverity Prevent analysis tool Reviewed by: mdodd
* If a register width is less than 8, assume the BIOS author thought it wasnjl2005-02-231-0/+12
| | | | | in units of bytes and adjust accordingly. This is found at least on the Sony PCG-505BX.
* Belkin F5D5020 is an OEM'd card from RACORE based on the AX88190imp2005-02-222-1/+2
| | | | | | chipset. Add support for this card. Office Max has them on sale and I was surprised that we didn't have it in our supported list when I plugged it in...
* Add a stratigic newlineimp2005-02-221-0/+1
|
* Add a entry for the Compaq R3000Z to indicate that it has the weird MADTjhb2005-02-221-0/+7
| | | | IRQ 0 quirk.
* - Add a new quirk to indicate that pin 0 of the first I/O APIC is reallyjhb2005-02-221-3/+12
| | | | | | | | | IRQ 0 and not an ExtINT pin. The MADT enumerators ignore the PC-AT flag and ignore overrides that map IRQ 0 to pin 2 when this quirk is present. - Add a block comment above the quirks to document each quirk so that we can use more verbose descriptions quirks. MFC after: 2 weeks
* Minor style nits missed in earlier passesimp2005-02-222-5/+4
|
* remove dead code (inside a DEBUG ifdef)sam2005-02-221-6/+2
| | | | Submitted by: Coverity Prevent analysis tool
* Neuter DRM(mapbufs) until somebody finds time to try to fix it.phk2005-02-221-0/+4
| | | | | | It is _never_ OK to find a vnode from a struct cdev because you have no way of telling if you get the right one. You might be in jail or chroot for instance.
* Increase the maximum to wait for a transition from 1 to 10 ms. In somenjl2005-02-221-4/+16
| | | | | | | modes, systems may take longer. If the status values don't match, try matching just the lowest 8 bits if no bits above 8 are set in the desired value. The IBM R32 has other bits set in the status register that are irrelevant to the expected value.
* Support disabling individual cpufreq drivers with hints, e.g.,njl2005-02-223-0/+9
| | | | hint.ichss.0.disabled="1"
* MFp4: Optimize in/out macros. Cache the handle and tag in softc andimp2005-02-222-44/+34
| | | | | use them in the macros. Since the rman_get_bus{tag,handle} transitioned from macros to function calls, this unpessimizes that conversion.
* Minor optimization of calling enable_16bit. We always have to call itimp2005-02-221-7/+2
| | | | | and error is going to be right for both forks of the if, so just return that.
* Set the start of the cooling time later on, when we're actually performingnjl2005-02-221-2/+2
| | | | | | | | | the switch. Other interim tests (i.e., for minimum runtime) could invalidate the start time. This fixes transitions to cooler states in that now they go to the next active state (_AC0 -> _AC1) instead of going straight to off (_AC0 -> off). Submitted by: Alexandre "Sunny" Kovalenko (Alex.Kovalenko / verizon.net)
* Since the GPE handler is directly called by ACPI-CA and it may have unknownnjl2005-02-211-3/+8
| | | | | | | | | | | | | | | | locks held, specify the ACPI_ISR flag to keep it from acquiring any more mutexes (which could potentially sleep.) This should fix "could sleep" warning messages on the following path: msleep() AcpiOsWaitSemaphore() AcpiUtAcquireMutex() AcpiDisableGpe() EcGpeHandler() AcpiEvGpeDispatch() AcpiEvGpeDetect() AcpiEvGpeDetect() AcpiEvSciXruptHandler()
* Only send packet to bpf if we are committed to send it. Previously it wasmlaier2005-02-211-6/+10
| | | | | | | | | possible that the same packet would show up multiple times. This poses some constraints on the TBD locking for snc(4) (see comment). Obtained from: DragonFlyBSD Submitted by: Joerg Sonnenberger Reviewed by: rwatson
* Minor style(9)isms.imp2005-02-211-40/+32
|
* - Remove dead code.scottl2005-02-211-3/+2
| | | | | | - Protect against negative values as array indexes. Submitted by: Coverity Prevent analysis tool
* Check for BIOS version 3.0 as well as 3.1.scottl2005-02-211-1/+1
| | | | Submitted by: Coverity Prevent analysis tool
* Don't attach ichss if est is present. On systems that seem to support both,njl2005-02-201-2/+6
| | | | the multi-setting EST is preferable.
* Be more verbose on errors with CIS reading. This should be a noop, butimp2005-02-201-4/+9
| | | | | appears to fix the ath problem that had been reported. I don't see how it can, so there's likely some other hidden bug.
* style(9) nitimp2005-02-201-2/+2
|
* Fix merging botch I made in last version.imp2005-02-201-1/+0
|
* Perliminary support for Fujitsu SCSI LAN combo card. At least for theimp2005-02-201-1/+1
| | | | | LAN side of things. It appears that all that's necessary is to relax the check on the DLCR2 register in the probe.
* Back out part of 1.23. This was a work in progress to support theimp2005-02-201-13/+5
| | | | Fujitsu LAN SCSI card's ethernet side.
* Forced commit after moving mb86960.h from i386/isa/ic to dev/fe. Itimp2005-02-204-10/+22
| | | | is only used by the fe driver, and isn't MD.
* Minor optimizations to compile out bits that aren't necessary whenimp2005-02-202-5/+27
| | | | | | certain options aren't enabled. Submitted by: Chiharu Shibata-san (chi at bd mbn or jp)
* Minor style(9) tweaks.imp2005-02-201-7/+4
|
* Correct typo in comment.imp2005-02-201-1/+1
| | | | Submitted by: Chiharu Shibata-san (chi at bd mbn or jp)
* Add a note that all four HME chips on a SUNW,qfe card share the same PROM,marius2005-02-201-1/+2
| | | | | | making it a bit more clear why we can read four NAs from the VPD. MFC after: 1 day
* Add a new field to struct cf_setting for special values. These are driver-njl2005-02-191-1/+7
| | | | | specific values that other components may want to use. Add support to acpi_perf(4) to export the control and status values via this field.
* For the I/O port case, we need to set ok to 1 if we have what looksimp2005-02-181-8/+15
| | | | | | | | | | | | | like a valid range. We already do this in the memory case (although the code there is somewhat different than the I/o case because we have to deal with different kinds of memory). Since most laptops don't have non-subtractive bridges, this wasn't seen in practice. Evidentally the Compaq R3000 hits this problem with PC Cards. Some minor style fixes while I'm here. Submitted by: Jung-uk Kim
* Introduce a new method, cpufreq_drv_type(), that returns the type of thenjl2005-02-183-17/+52
| | | | | | | | | | | driver. This used to be handled by cpufreq_drv_settings() but it's useful to get the type/flags separately from getting the settings. (For example, you don't have to pass an array of cf_setting just to find the driver type.) Use this new method in our in-tree drivers to detect reliably if acpi_perf is present and owns the hardware. This simplifies logic in drivers as well as fixing a bug introduced in my last commit where too many drivers attached.
* memspace is set to some value by masking off bits. When these bitsimp2005-02-171-4/+3
| | | | | | | | | | | | | | are equal to PCCARD_TPCE_FS_MEMSPACE_NONE, memspace will be zero, so testing for this case inside of the if statement results in dead code. We'd fail to set a value to zero that's already zero (since it is initialized to 0 indirectly) with this code being there. Well, except in the very rare case that we have a card that has a defualt entry that includes a memory space followed by one that has no memory space (these are extremely rare, I don't recall ever having seen one :-). Fix this by setting num_memspace to 0 in a more appropriate place. Submitted by: Coverity Prevent analysis tool
* Undoing recent changes to make 3ware's i386 tools work on amd64, since there arevkashyap2005-02-172-59/+0
| | | | now amd64 versions of CLI and 3DM2 available.
* Check for the address space type first before validating it. In particular,njl2005-02-171-2/+6
| | | | | | we want to return EOPNOTSUPP for FFixedHW no matter what the address. Submitted by: Bruno Ducrot
* Fix the support for the ax88[17]90 to print the right type, ratherimp2005-02-171-27/+31
| | | | | | | | than the generic ne-2000 string. This should have no effect on the actual support of the parts, just reporting what the part was. Also, rename a few functins and symbols to reflect a more generic part support that grew out of the early specific support.
* The correct error value for not having enough storage is E2BIG, notnjl2005-02-172-2/+2
| | | | ENOMEM. The manpage and ichss(4) are correct.
* Fix the check for acpi_perf(4) so that we verify if it is fully attachednjl2005-02-171-4/+14
| | | | | | | | | or just offering info. In the former case, we don't probe/attach to allow the ACPI driver precedence. A refinement of this would be to actually use the info provided by acpi_perf(4) to get the real CPU clock rates instead of estimating them but since all systems that support both acpi_perf(4) and ichss(4) export the control registers to acpi_perf(4), it can just handle the registers on its own.
* aic79xx.c:gibbs2005-02-162-5/+16
| | | | | | | | | | | aic7xxx.c: Allow print_reg() to be called with a NULL column. aic79xx.c: Correct new usage of SCB_GET_TAG(). aic7xxx.c: Fix stray ahd that snuck in here.
OpenPOWER on IntegriCloud