summaryrefslogtreecommitdiffstats
path: root/sys/dev
Commit message (Collapse)AuthorAgeFilesLines
* Do a pass over all modules in the kernel and make them return EOPNOTSUPPphk2004-07-1520-1/+32
| | | | | | | | for unknown events. A number of modules return EINVAL in this instance, and I have left those alone for now and instead taught MOD_QUIESCE to accept this as "didn't do anything".
* Add a comment separator.njl2004-07-141-1/+1
|
* Some laptops report the "design-capacity" instead of the "real-capacity"marks2004-07-141-0/+9
| | | | | | | | when the battery is fully charged. That breaks some of the arithmetic in calculating the remaining capacity (ends up with more than 100%). This commit makes sure the max is 100. Approved by: njl
* Remove fdc_alloc_resources, which should have happened in last commit.imp2004-07-142-143/+2
|
* Fix the pccard attachment to have a chance of working.imp2004-07-142-32/+214
| | | | Move the resource allocation into the bus front ends.
* Follow PnP location string change in acpi.c.takawata2004-07-141-1/+1
|
* Switch snoop device to using C99 initialization for struct linesw.rwatson2004-07-141-2/+8
|
* Give kldunload a -f(orce) argument.phk2004-07-131-2/+2
| | | | | | | | | | | | | | | | | Add a MOD_QUIESCE event for modules. This should return error (EBUSY) of the module is in use. MOD_UNLOAD should now only fail if it is impossible (as opposed to inconvenient) to unload the module. Valid reasons are memory references into the module which cannot be tracked down and eliminated. When kldunloading, we abandon if MOD_UNLOAD fails, and if -force is not given, MOD_QUIESCE failing will also prevent the unload. For backwards compatibility, we treat EOPNOTSUPP from MOD_QUIESCE as success. Document that modules should return EOPNOTSUPP for unknown events.
* Clean up our pnpinfo and location strings.njl2004-07-131-7/+5
|
* Call device_identify routines after doing the namespace walk. This isnjl2004-07-131-8/+6
| | | | | | | | | needed so that sysresource objects are created first to reserve all regions, then other devices can allocate from them. Otherwise, acpi_timer (the only ACPI device with an identify routine), would allocate its resources from the nexus, causing the later sysresource reserve to fail. Debugging by: Taku YAMAMOTO, Andrea Campi
* Remove erroneous semicolons.stefanf2004-07-133-4/+4
|
* Re-enable debugger port.simokawa2004-07-131-3/+124
|
* Set fdc_dev in attachimp2004-07-131-0/+1
|
* Don't depend on implicit include of machine/bus.h in sys/rman.h, but insteadimp2004-07-133-0/+5
| | | | explicitly include it.
* Remove even more references to generating usbdevs_data.h, et al.imp2004-07-121-9/+9
| | | | Noticed by: njl
* Remove the instructions for regenerating usbdevs.h: that's now noimp2004-07-121-13/+0
| | | | longer necessary.
* Remove unnecessary softc bzero calls.njl2004-07-122-2/+0
|
* Add the ability to detach a battery. Now batteries that are detached arenjl2004-07-123-1/+33
| | | | also removed from the battery list.
* Update in preparation for adding the ACPI attachment.njl2004-07-124-68/+94
| | | | | | | | | | | | | | * Add an fdtype ivar. This will be the equivalent of fd->type. * Move enabling the FIFO to the end of attach. * Unify reset code into fdc_initial_reset(). * Add fdc_write_ivar(). * Update isa and pccard attachments accordingly. * Set the flags unconditionally in probe since they may be overridden by other probe routines. Both before and now, we're depending on probe being called a final time on the winning driver so the flags we get are the ones we intended. * Use the bus accessor macros instead of defining our own. * Remove duplicate assigns of fd->type.
* Attempt to handle suspend/resume better.sos2004-07-122-16/+9
|
* Until I'm ready to commit the better pccard probe/attach routines, effectivelyimp2004-07-111-0/+2
| | | | comment them out.
* Introduce ttygone() which indicates that the hardware is detached.phk2004-07-1112-299/+36
| | | | Move dtrwait logic to the generic TTY level.
* Make NdisReadPcmciaAttributeMemory() and NdisWritePcmciaAttributeMemory()wpaul2004-07-113-22/+75
| | | | | | | | | | | | | | | | | | | | | | | actually work. Make the PCI and PCCARD attachments provide a bus_get_resource_list() method so that resource listing for PCCARD works. PCCARD does not have a bus_get_resource_list() method (yet), so I faked up the resource list management in if_ndis_pccard.c, and added bus_get_resource_list() methods to both if_ndis_pccard.c and if_ndis_pci.c. The one in the PCI attechment just hands off to the PCI bus code. The difference is transparent to the NDIS resource handler code. Fixed ndis_open_file() so that opening files which live on NFS filesystems work: pass an actual ucred structure to VOP_GETATTR() (NFS explodes if the ucred structure is NOCRED). Make NdisMMapIoSpace() handle mapping of PCMCIA attribute memory resources correctly. Turn subr_ndis.c:my_strcasecmp() into ndis_strcasecmp() and export it so that if_ndis_pccard.c can use it, and junk the other copy of my_strcasecmp() from if_ndis_pccard.c.
* Update for the KDB framework. Sanitize the alpha console code now thatmarcel2004-07-103-314/+81
| | | | | | | | | | | | | | | | | | it's in the way even more. Basicly: remove all alpha specific console support from gfb(4), sio(4) and syscons(4). Rewrite the alpha console initialization to be identical to all other platforms. In a nutshell: call cninit(). The platform specific code now only sets or clears RB_SERIAL and thus automaticly causes the right console to be selected. sio.c: o Replace the remote GDB hacks and use the GDB debug port interface instead. o Make debugging code conditional upon KDB instead of DDB. o Call kdb_alt_break() instead of db_alt_break(). o Call kdb_enter() instead of breakpoint(). o Remove the ugly compatibility of using the console as the debug port.
* Update for the KDB framework:marcel2004-07-104-4/+5
| | | | o Call kdb_enter() instead of Debugger().
* Update for the KDB framework:marcel2004-07-101-6/+5
| | | | | o Make debugging code conditional upon KDB instead of DDB. o Call kdb_alt_break() insteadof db_alt_break().
* Update for the KDB framework:marcel2004-07-101-8/+6
| | | | | | o Call kdb_enter() instead of breakpoint(). o Call kdb_alt_break() instead of db_alt_break(). o Make debugging code conditional upon KDB instead of DDB.
* Update for the KDB framework:marcel2004-07-101-3/+2
| | | | o Make debugging code conditional upon KDB instead of DDB.
* Remove DDB. The one user of this macro has been changed to use BVDDB.marcel2004-07-101-1/+0
| | | | | Yes, DDB is unrelated to the debugger with the same acronym. Hence, the change.
* s/DDB/BVDDB/gmarcel2004-07-101-1/+1
| | | | Note that DDB is unrelated to the debugger with the same acronym.
* Update for the KDB framework:marcel2004-07-101-6/+5
| | | | | o Make debugging code conditional upon KDB instead of DDB. o Call kdb_alt_break() instead of db_alt_break().
* Update for the KDB framework:marcel2004-07-101-8/+8
| | | | | | o Make debugging code conditional upon KDB instead of DDB. o Call kdb_alt_break() instead of db_alt_break(). o Call kdb_enter() instead of breakpoint().
* Update for the KDB framework:marcel2004-07-101-3/+2
| | | | o Make debugging code conditional upon KDB instead of DDB.
* Update for the KDB framework:marcel2004-07-101-3/+2
| | | | o Make debugging code dependent upon KDB instead of DDB.
* Update for the KDB framework:marcel2004-07-101-3/+2
| | | | | | o Call kdb_enter() instead of Debugger(). o Don't make such calls conditional upon KDB instead of DDB because they're already conditional upon EN_DEBUG.
* Update for the KDB framework:marcel2004-07-101-49/+4
| | | | | | | | | | | | o Use kdb_alt_break() to handle the alternate break sequence instead of handcoding it here. o Remove GDB kluges to make this driver work with the pre-KDB remote GDB code. o Call kdb_enter() instead of Debugger(). Note that with this commit the dcons(4) driver cannot be used for remote debugging anymore. This driver has to use the new GDB debug port interface instead. Such has not been done yet.
* Update for the KDB framework:marcel2004-07-101-4/+2
| | | | | o Remove inclusion of opt_ddb.h o Make debugging code conditional upon KDB.
* Update for the KDB framework:marcel2004-07-101-2/+3
| | | | o Call kdb_enter() instead of Debugger().
* Add support for uart(4) being a debug port for the GDB backend.marcel2004-07-101-0/+101
|
* Remove a pointless check.phk2004-07-101-2/+0
|
* - Add missing <sys/module.h>. [1]marius2004-07-091-6/+2
| | | | | | | - Remove unused includes. - Sort includes. Reported by: Pyun YongHyeon <yongari@kt-is.co.kr> [1]
* Do not bzero() the softc, as newbus does it for us.cognet2004-07-095-5/+0
|
* Newbus returns a zeroed softc, so there's no need to call bzero() here.cognet2004-07-091-2/+0
|
* Apply the long-overdue hatchet of style(9) death to this file.bms2004-07-091-458/+547
|
* Further locking improvements for vr(4):bms2004-07-091-46/+69
| | | | | | | | | | | | - Add *_locked() entry points as needed to avoid unnecessary lock thrashing. - Use these entry points wisely. - Only acquire the lock once when servicing an interrupt. - Check 'suspended' on interrupt to avoid racing detach. - Correct a mis-spelled comment. - Don't take the lock in vr_reset() to avoid lock thrashing in attach. - Comment this. Reviewed by: -net (silence)
* Add a 'suspended' flag to softc so that we can avoid races on detach.bms2004-07-091-0/+1
|
* Break out the isa and pccard front ends from fdc. This is the firstimp2004-07-074-304/+405
| | | | | | | | step in making this driver more attachment neutral. Others plan on adding acpi front ends. Still need to cleanup the MI part of the driver because it isn't as bus independent as it could be.
* Fix two problems:wpaul2004-07-072-13/+13
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | - In subr_ndis.c:ndis_allocate_sharemem(), create the busdma tags used for shared memory allocations with a lowaddr of 0x3E7FFFFF. This forces the buffers to be mapped to physical/bus addresses within the first 1GB of physical memory. It seems that at least one card (Linksys Instant Wireless PCI V2.7) depends on this behavior. I don't know if this is a hardware restriction, or if the NDIS driver for this card is truncating the addresses itself, but using physical/bus addresses beyong the 1GB limit causes initialization failures. - Create am NDIS_INITIALIZED() macro in if_ndisvar.h and use it in if_ndis.c to test whether the device has been initialized rather than checking for the presence of the IFF_UP flag in if_flags. While debugging the previous problem, I noticed that bringing up the device would always produce failures from ndis_setmulti(). It turns out that the following steps now occur during device initialization: - IFF_UP flag is set in if_flags - ifp->if_ioctl() called with SIOCSIFADDR (which we don't handle) - ifp->if_ioctl() called with SIOCADDMULTI - ifp->if_ioctl() called with SIOCADDMULTI (again) - ifp->if_ioctl() called with SIOCADDMULTI (yet again) - ifp->if_ioctl() called with SIOCSIFFLAGS Setting the receive filter and multicast filters can only be done when the underlying NDIS driver has been initialized, which is done by ifp->if_init(). However, we don't call ifp->if_init() until ifp->if_ioctl() is called with SIOCSIFFLAGS and IFF_UP has been set. It appears that now, the network stack tries to add multicast addresses to interface's filter before those steps occur. Normally, ndis_setmulti() would trap this condition by checking for the IFF_UP flag, but the network code has in fact set this flag already, so ndis_setmulti() is fooled into thinking the interface has been initialized when it really hasn't. It turns out this is usually harmless because the ifp->if_init() routine (in this case ndis_init()) will set up the multicast filter when it initializes the hardware anyway, and the underlying routines (ndis_get_info()/ndis_set_info()) know that the driver/NIC haven't been initialized yet, but you end up spurious error messages on the console all the time. Something tells me this new behavior isn't really correct. I think the intention was to fix it so that ifp->if_init() is only called once when we ifconfig an interface up, but the end result seems a little bogus: the change of the IFF_UP flag should be propagated down to the driver before calling any other ioctl() that might actually require the hardware to be up and running.
* Eliminate unneeded return keywords.bms2004-07-061-34/+1
|
* Whitespace passbms2004-07-061-54/+54
|
OpenPOWER on IntegriCloud