summaryrefslogtreecommitdiffstats
path: root/sys
Commit message (Collapse)AuthorAgeFilesLines
...
* In the ufsdirhash_build() failure case for corrupted directoriesiedowse2005-08-171-2/+3
| | | | | | | | | or unreadable blocks, make sure to destroy the mutex we created. Also fix an unrelated typo in a comment. Found by: Peter Holm's stress tests Reviewed by: dwmalone MFC after: 3 days
* Handle device drivers with D_NEEDGIANT in a way which does notphk2005-08-173-33/+156
| | | | | penalize the 'good' drivers: Allocate a shadow cdevsw and populate it with wrapper functions which grab Giant
* Assert proper key size also in userland by defining KASSERT in !_KERNEL case.pjd2005-08-171-2/+2
|
* In vop_stdpathconf(ap) also default for _PC_NAME_MAX and _PC_PATH_MAX.phk2005-08-171-0/+6
|
* Ensure that file flags such as schg, sappnd (and others) are honoredcsjp2005-08-171-8/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | by md(4). Before this change, it was possible to by-pass these flags by creating memory disks which used a file as a backing store and writing to the device. This was discussed by the security team, and although this is problematic, it was decided that it was not critical as we never guarantee that root will be restricted. This change implements the following behavior changes: -If the user specifies the readonly flag, unset write operations before opening the file. If the FWRITE mask is unset, the device will be created with the MD_READONLY mask set. (readonly) -Add a check in g_md_access which checks to see if the MD_READONLY mask is set, if so return EROFS -Do not gracefully downgrade access modes without telling the user. Instead make the user specify their intentions for the device (assuming the file is read only). This seems like the more correct way to handle things. This is a RELENG_6 candidate. PR: kern/84635 Reviewed by: phk
* Unbreak the world build (in sbin/gbde). This file is used by bothcperciva2005-08-171-0/+2
| | | | | | | kernel and world, so KASSERT() needs to be wrapped within an #ifdef _KERNEL / #endif pair. Reported by: krion, tinderbox
* Fixup locking in if_my(4) and mark it MPSAFE:jhb2005-08-162-104/+96
| | | | | | | | | | | | | | | | - Add locked variants of my_start() and my_init(). - Assert that the lock is held in several places rather than recursing. - Overhaul failure case handling in my_attach() so that it will actually clean up completely in each of the failure cases. - Setup the interrupt after ether_ifattach() in my_attach(). - Remove unused callout handle from softc. - Free the metadata for the descriptors my_in detach() (we leaked it before). - Fix locking in my_ioctl(). - Remove spls. Tested by: brueffer MFC after: 3 days
* remove stale commentsphk2005-08-161-2/+0
|
* Save cpu level only when priority is greater than PRIO_USERume2005-08-161-1/+1
| | | | | | | to make CPUFREQ_SET(NULL, prio) work. TODO: implement saved_level as stack. Reviewed by: njl
* avoid exclusive sleep mutex.ume2005-08-161-3/+3
|
* Remove stale comment.phk2005-08-161-2/+0
|
* Collect the devfs related sysctls in one placephk2005-08-163-53/+34
|
* Create a new internal .h file to communicate very private stuffphk2005-08-164-3/+48
| | | | | | from kern_conf.c to devfs. For now just two prototypes, more to come.
* Check key size for rijndael, as invalid key size can lead to kernel panic.pjd2005-08-162-0/+4
| | | | | | | | | It checked other algorithms against this bug and it seems they aren't affected. Reported by: Mike Tancsa <mike@sentex.net> PR: i386/84860 Reviewed by: phk, cperciva(x2)
* Clarify a comment.jhb2005-08-161-1/+1
|
* - Move IF_ADDR_LOCK_DESTROY(ifp) from if_free to if_free_type.brooks2005-08-161-1/+3
| | | | | | | | | | - Add a note that additions should be made to if_free_type and not if_free to help avoid this in the future. This apparently fixes a use after free in if_bridge and may fix bugs in other direct if_free_type consumers. Reported by: thompsa
* Make it possible to remove stale, left-over subdisks.le2005-08-162-10/+11
|
* Remove unnecessary and alarming printf.grehan2005-08-161-1/+1
| | | | MFC after: 1 day
* Now that at least some screen savers work on sparc64 sync with othermarius2005-08-151-1/+1
| | | | | | | | archs and enable splash(4) by default (the non-working screen savers either don't compile or just have no effect when loaded, i.e. don't cause harm). MFC after: 1 week
* - Change the code that determines whether to use a serial console andmarius2005-08-152-38/+62
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | which serial device to use in that case respectively to not rely on the OFW names of the input/output and stdin/stdout devices. Instead check whether input and output refers to the same device and is of type serial (uart(4) was already doing this) and for the fallback to a serial console in case a keyboard is the selected input device but unplugged do the same for stdin and stdout in case the input device is nonexistent (PS/2 and USB keyboards) or has a 'keyboard' property (RS232 keyboards). Additionally also check whether the OFW did a fallback to a serial console in the same way in case the output device is nonexistent. While at it save on some variables and for sys/boot/sparc64/loader/metadata.c move the code in question to a new function md_bootserial() so it can be kept in sync with uart_cpu_getdev_console() more easily. This fixes selecting a serial console and the appropriate device when using a device path for the 'input-device' and 'output-device' OFW environment variables instead of an alias for the serial device to use or when using a screen alias that additionally denotes a video mode (like e.g. 'screen:r1024x768x60') but no keyboard is plugged in (amongst others). It also makes the code select a serial console in case the OFW did the same due to a misconfiguration like both 'input-device' and 'output-device' set to 'keyboard' or to a nonexisting device (whether the OFW does a fallback to a serial console in case of a misconfiguration or one ends up with just no console at all highly depends on the OBP version however). - Reduce the size of buffers that only ever need to hold the string 'serial' accordingly. Double the size of buffers that may need to hold a device path as e.g. '/pci@8,700000/ebus@5/serial@1,400000:a' exceeds 32 chars. - Remove the package handle of the '/options' node from the argument list of uart_cpu_getdev_dbgport() as it's unused there and future use is also unlikely. MFC after: 1 week
* Vlan interfaces change their type after ether_ifattach() so we needs tobrooks2005-08-151-1/+1
| | | | | | | | use if_free_type(ifp, IFT_ETHER) to delete them and stop leaking struct arpcoms. Reported by: thompsa MFC After: 3 days
* Eliminate effectively unused dm_basedir field from devfs_mount.phk2005-08-155-5/+3
|
* Some preliminary support for Megahertz XJEM and CCEM (same cards really)imp2005-08-151-28/+159
| | | | combo cards.
* Diff reduction to my tree: commit the trivial part of efforts to addimp2005-08-152-2/+8
| | | | support for the really old Megahertz ethernet/modem combo cards.
* Fix a stupid logic bug introduced in geom_vinum_drive.c rev 1.18:le2005-08-153-1/+9
| | | | | | | When a drive is newly created, it's state is initially set to 'down', so it won't allow saving the config to it (thus it will never know of itself being created). Work around this by adding a new flag, that's also checked when saving the config to a drive.
* Ensure that we are holding the lock when initialising the bridge interface. Wethompsa2005-08-151-0/+2
| | | | | | | | | | | | could initialise while unlocked if the bridge is not up when setting the inet address, ether_ioctl() would call bridge_init. Change it so bridge_init is always called unlocked and then locks before calling bstp_initialization(). Reported by: Michal Mertl Approved by: mlaier (mentor) MFC after: 3 days
* Ensure that we are holding the lock when initialising the bridge interface. Wethompsa2005-08-151-0/+5
| | | | | | | | | | | | could initialise while unlocked if the bridge is not up when setting the inet address, ether_ioctl() would call bridge_init. Change it so bridge_init is always called unlocked and then locks before calling bstp_initialization(). Reported by: Michal Mertl Approved by: mlaier (mentor) MFC after: 3 days
* Remove the execute permission for stacks.marcel2005-08-141-1/+1
|
* Simplify the page table page reference counting by pmap_enter()'s change ofalc2005-08-142-16/+15
| | | | | | | | mapping case. Eliminate a stale comment from pmap_enter(). Reviewed by: tegge
* Fix broken build of rev. 1.108 in case of no INET6 and IPFIREWALLbz2005-08-141-1/+7
| | | | | | compiled into kernel. Spotted and tested by: Michal Mertl <mime at traveller.cz>
* Do not keep parent directory locked while calling VFS_ROOT to traverse mountkan2005-08-141-0/+2
| | | | | | | points in lookup(). The lock can be dropped safely around VFS_ROOT because LOCKPARENT semantics with child and perent vnodes coming from different FSes does not really have any meaningful use. On the other hard, this prevents easily triggered deadlock on systems using automounter daemon.
* - restore the ability to mount cd9660 filesystems as root by invertinggrehan2005-08-142-14/+12
| | | | | | | | | | | | | | | | | | | | | | some of the options test, specifically the joliet and rockridge tests. Since the root mount callchain doesn't go through cd9660_cmount, the default mount options aren't set. Rather than having the main codepath assume the options are there, test for the absence of the inverted optioin e.g. instead of vfs_flagopt(.. "joliet" ..), test for !vfs_flagopt(.. "nojoliet" ..) This works for root mount, non-root mount and future nmount cases. - in cd9660_cmount, remove inadvertent setting of "gens" when "extatt" was set. Reported by: grehan, Dario Freni <saturnero at freesbie org> Tested by: Dario Freni Not objected to by: phk MFC after: 3 days
* Bump __FreeBSD_version for dev_clone eventhandler to add credential.rwatson2005-08-131-1/+1
|
* o s/pmap_lpte_/pmap_/gmarcel2005-08-131-80/+52
| | | | o Remove pmap_is_referenced(). It was already compiled-out.
* Fix the problem with the IPI for the lazy context switching of themarcel2005-08-132-2/+5
| | | | | | | | | | | high FP registers. It was not that the IPI got lost due to the perceived unreliability of the IPI delivery, but rather that the IPI was not assigned a vector (ugh). Sending a 0 vector to a CPU results in a stray external interrupt. Add a KASSERT to ipi_send() to catch this. The initialization of the IPIs could be better, but it's not at all sure what the future of the code is. Avoid wasting a lot of time on something that is going to be rewritten anyway.
* Do not use vm_pager_init() to initialize vnode_pbuf_freecnt variable.kan2005-08-134-15/+3
| | | | | | | | | | | vm_pager_init() is run before required nswbuf variable has been set to correct value. This caused system to run with single pbuf available for vnode_pager. Handle both cluster_pbuf_freecnt and vnode_pbuf_freecnt variable in the same way. Reported by: ade Obtained from: alc MFC after: 2 days
* Make mpsafe_vfs=1 the default on ia64.marcel2005-08-131-1/+2
|
* added a knob to enable path MTU discovery for multicast packets.ume2005-08-134-14/+28
| | | | | | | (by default, it is disabled) Submitted by: suz Obtained from: KAME
* revert 1.64: we cannot use the channel characteristics to decide when tosam2005-08-131-4/+3
| | | | | | | do 11g erp sta accounting because b/g channels show up as false positives when operating in 11b. Noticed by: Michal Mertl
* Because code paths for I/O requests are quite complex, add comments abovepjd2005-08-131-0/+12
| | | | | | the functions which participate in I/O paths. MFC after: 1 day
* Extend acl support to pass ioctl requests through and use this tosam2005-08-134-4/+79
| | | | | | | | add support for getting the current policy setting and collecting the list of mac addresses in the acl table. Submitted by: Michal Mertl (original version) MFC after: 2 weeks
* * Solve "No PHY found" problem for more Yukon Lite variants.bz2005-08-132-50/+122
| | | | | | | * Catch a bus attach error. * Improve locking. MFC after: 6 days
* * Add dynamic sysctl for net.inet6.ip6.fw.bz2005-08-132-67/+288
| | | | | | | | | | | | | * Correct handling of IPv6 Extension Headers. * Add unreach6 code. * Add logging for IPv6. Submitted by: sysctl handling derived from patch from ume needed for ip6fw Obtained from: is_icmp6_query and send_reject6 derived from similar functions of netinet6,ip6fw Reviewed by: ume, gnn; silence on ipfw@ Test setup provided by: CK Software GmbH MFC after: 6 days
* fix handling of the current channel (missed in previous commit)sam2005-08-131-4/+5
|
* fix media_status so devd recognizes the device as an 802.11 interfacesam2005-08-131-1/+6
| | | | Submitted by: Robert C. Noland III
* correct CTS duration calculation; SIFS+ACK should use the xmit rate notsam2005-08-121-2/+2
| | | | | | | the rate for CTS MFC after: 3 days Obtained from: Atheros
* Check for marker pages when scanning active and inactive page queues.tegge2005-08-121-0/+5
| | | | Reviewed by: alc
* Add support for the Promise PDC4071[89] chips used on fx the Fasttrak TX4300.sos2005-08-123-1/+7
| | | | Docs kindly provided by Promise.
* Add definition for SATAII 3Gb/s mode.sos2005-08-121-0/+1
|
* - fix typo in comment.ume2005-08-126-45/+20
| | | | | | | - nuke unused code. Submitted by: suz Obtained from: KAME
OpenPOWER on IntegriCloud