summaryrefslogtreecommitdiffstats
path: root/sys/kern
Commit message (Collapse)AuthorAgeFilesLines
* All unimplemented VFS ops now have entries in kern/vfs_default.c that returnalfred1999-09-071-0/+116
| | | | | | | | | | | | | reasonable defaults. This avoids confusing and ugly casting to eopnotsupp or making dummy functions. Bogus casting of filesystem sysctls to eopnotsupp() have been removed. This should make *_vfsops.c more readable and reduce bloat. Reviewed by: msmith, eivind Approved by: phk Tested by: Jeroen Ruigrok/Asmodai <asmodai@wxs.nl>
* Change isa_get/set_flags() to device_get/set_flags().dfr1999-09-071-0/+13
|
* Set up FPU state on the AP.peter1999-09-051-0/+4
| | | | Tested by: phk
* Fixed style bugs in rev.1.36-1.39.bde1999-09-041-37/+28
|
* Fixed style regressions in previous commit.bde1999-09-041-6/+4
|
* Fix a warning for the !DEVFS case.peter1999-09-031-2/+4
|
* Allow getblk() to be called from an idle context (by panic() insideluoqi1999-09-031-4/+10
| | | | | | an interrupt handler). Reviewed by: dillon
* Revert a bunch of contraversial changes by PHK. Afterjulian1999-09-032-21/+14
| | | | | | | | | | a quick think and discussion among various people some form of some of these changes will probably be recommitted. The reversion requested was requested by dg while discussions proceed. PHK has indicated that he can live with this, and it has been agreed that some form of some of these changes may return shortly after further discussion.
* Make prototype match function.sef1999-09-011-1/+1
|
* Use "multiple 4 char outdent until no wrap" rather than ANSI stringphk1999-09-011-7/+7
| | | | | | | concatenation to preserve K&R compatibility. Requested by: bde Terminology by: grog
* Improve the micro "disk" layer after gaining more experience with it.phk1999-09-011-16/+70
|
* Improve the returned values in st_blksize a little bit, avoidphk1999-09-011-11/+21
| | | | accessing union fields not valid for dev_t type.
* General cleanup of core-dumping code.julian1999-09-013-84/+84
| | | | Submitted by: Sean Fagan,
* Include "dscheck" and device name in all messages from dscheck().phk1999-08-311-7/+13
|
* If integration of a buffer into a cluster write operation fails, releasetegge1999-08-311-1/+3
| | | | | | the buffer instead of creating a future deadlock. PR: 12800 Submitted by: dillon
* Restructure TCP timeout handling:jlemon1999-08-301-9/+9
| | | | | | | | | | - eliminate the fast/slow timeout lists for TCP and instead use a callout entry for each timer. - increase the TCP timer granularity to HZ - implement "bad retransmit" recovery, as presented in "On Estimating End-to-End Network Path Properties", by Allman and Paxson. Submitted by: jlemon, wollmann
* ktrace should not follow symlinks either.dima1999-08-301-2/+2
| | | | Suggested by: bde
* pps_shiftmax only exists #ifdef PPS_SYNCphk1999-08-301-0/+2
| | | | Found by: Roger Hardiman <roger@cs.strath.ac.uk>
* Update to the latest nanokernel from Dave Mills.phk1999-08-301-106/+94
|
* s/si_tty_tty/si_tty/gphk1999-08-301-12/+12
|
* Make bdev userland access work like cdev userland access unlessphk1999-08-302-3/+0
| | | | | | | | | | the highly non-recommended option ALLOW_BDEV_ACCESS is used. (bdev access is evil because you don't get write errors reported.) Kill si_bsize_best before it kills Matt :-) Use the specfs routines rather having cloned copies in devfs.
* Remove unneeded "maj" variable.phk1999-08-291-6/+8
| | | | | | Give up if we have already started dumping once before. Print name of dumpdev.
* Add micro "disk" layer which should enable us to pull all the slice/labelphk1999-08-291-0/+183
| | | | stuff out of the device drivers.
* Merge alpha and pc98 changes into i386 MBR handling code and replace allphk1999-08-291-6/+54
| | | | three copies with one copy in MI land.
* initialize si_bsize_phys from what the drive told us.phk1999-08-291-1/+1
|
* Add dev_t freeing code. Controlled by sysctl debug.free_devt, defaultphk1999-08-293-11/+62
| | | | is off.
* Put a brief comment on a couple of #defines.phk1999-08-281-0/+7
|
* remove unused variables.phk1999-08-282-2/+2
|
* We don't need to pass the diskname argument all over the diskslice/labelphk1999-08-283-50/+42
| | | | code, we can find the name from any convenient dev_t
* Regen after Id->FreeBSDpeter1999-08-282-2/+2
|
* Id -> FreeBSDpeter1999-08-281-1/+1
|
* $Id$ -> $FreeBSD$peter1999-08-28110-110/+110
|
* Add sysctl variables for the Linuxulator. These reside under `compat.linux' asmarcel1999-08-272-4/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | discussed on current. The following variables are defined (for now): osname (defaults to "Linux") Allow users to change the name of the OS as returned by uname(2), specially added for all those Linux Netscape users and statistics maniacs :-) We now have what we all wanted! osrelease (defaults to "2.2.5") Allow users to change the version of the OS as returned by uname(2). Since -current supports glibc2.1 now, change the default to 2.2.5 (was 2.0.36). oss_version (defaults to 198144 [0x030600]) This one will be used by the OSS_GETVERSION ioctl (PR 12917) which I can commit now that we have the MIB. The default version number is the lowest version possible with the current 'encoding'. A note about imprisoned processes (see jail(2)): These variables are copy-on-write (as suggested by phk). This means that imprisoned processes will use the system wide value unless it is written/set by the process. From that moment on, a copy local to the prison will be used. A note about the implementation: I choose to add a single pointer to struct prison, because I didn't like the idea of changing struct prison every time I come up with a new variable. As a side effect, the extra storage is only needed when a variable is set from within the prison. This also minimizes kernel bloat when the Linuxulator is not used; both compiled in or as a module. Reviewed by: bde (first version only) and phk
* Add FIODTYPE ioctl for getting d_flags (type) info on a device.green1999-08-271-1/+7
| | | | Okayed by: phk
* Don't follow symlinks on coredumps.dima1999-08-262-6/+6
| | | | Reviewed by: dillon && security-officer
* Simplify the handling of VCHR and VBLK vnodes using the new dev_t:phk1999-08-264-440/+118
| | | | | | | | | | | | | | | | | | | | | | | | | | | Make the alias list a SLIST. Drop the "fast recycling" optimization of vnodes (including the returning of a prexisting but stale vnode from checkalias). It doesn't buy us anything now that we don't hardlimit vnodes anymore. Rename checkalias2() and checkalias() to addalias() and addaliasu() - which takes dev_t and udev_t arg respectively. Make the revoke syscalls use vcount() instead of VALIASED. Remove VALIASED flag, we don't need it now and it is faster to traverse the much shorter lists than to maintain the flag. vfs_mountedon() can check the dev_t directly, all the vnodes point to the same one. Print the devicename in specfs/vprint(). Remove a couple of stale LFS vnode flags. Remove unimplemented/unused LK_DRAINED;
* Introduce vn_isdisk(struct vnode *vp) function, and use it to test for diskness.phk1999-08-252-18/+40
|
* Add a couple of missing but unimportant break; statements.phk1999-08-251-1/+3
|
* Make DEVFS use PHK's specinfo struct as the source of dev_t and devsw.julian1999-08-252-6/+4
| | | | | | | | In lookup() however it's the other way around as we need to supply the dev_t for the vnode, so devfs still has a copy of it stashed away. Sourcing it from the vnode in the vnops however is useful as it makes a lot of the code almost the same as that in specfs.
* Cast pointers to uintptr_t instead of casting them to u_long, and/or vicebde1999-08-244-12/+13
| | | | versa. Cosmetic.
* Cast pointers to uintptr_t instead of casting them to u_long. Theybde1999-08-241-5/+5
| | | | | | | | | | | are still converted to u_long by assignment of the uintptr_t, and address calculations are still done using u_long. This is OK for currently supported machines, but addresses should be represented by vm_offset_t or uintptr_t in case pointers are longer than longs. "Fixed" size of linker_path[]. MAXPATHLEN + 1 was 1 too large for search paths with only one file path in them, but much too small for search paths with several long file paths in them.
* Convert DEVFS hooks in (most) drivers to make_dev().phk1999-08-238-143/+38
| | | | | | | | | | | | | | | | 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().
* Use devtoname() to print dev_t's instead of casting them to long or u_longbde1999-08-231-3/+3
| | | | for misprinting in %lx format.
* Fix a mistake in my last SA_SIGINFO commit. Processes could blockcracauer1999-08-231-2/+2
| | | | | | | | SIGKILL and SIGSTOP. PR: kern/13293 Submitted by: dwmalone@maths.tcd.ie Obtained from: PR had correct fix
* Go back to using microtime() to get the timestamps for {f,l,}utimes(path,jdp1999-08-222-4/+6
| | | | | | | | NULL) for now. Bruce says I jumped the gun with my change in revision 1.131, or maybe it should use nanotime(), or maybe it shouldn't be decided in the VFS layer at all. I'm leaving it with the old behavior until the Trans-Pacific Internet Vulcan Mind Meld yields fuller understanding.
* 1) Add HEADER section. Similar to CODE.n_hibma1999-08-221-41/+58
| | | | | 2) deindent the two sections (CODE and HEADER), based on the indent found on the first line of the section; to make the output more readable.
* Use the new vfs_timestamp() function to create the timestamps usedjdp1999-08-222-86/+92
| | | | | | | | by utimes(path, NULL). This gives them the same precision as the timestamps produced by write operations. Do likewise for lutimes() and futimes(). Suggested by bde.
* Support full-precision file timestamps. Until now, only the secondsjdp1999-08-222-2/+86
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | have been maintained, and that is still the default. A new sysctl variable "vfs.timestamp_precision" can be used to enable higher levels of precision: 0 = seconds only; nanoseconds zeroed (default). 1 = seconds and nanoseconds, accurate within 1/HZ. 2 = seconds and nanoseconds, truncated to microseconds. >=3 = seconds and nanoseconds, maximum precision. Level 1 uses getnanotime(), which is fast but can be wrong by up to 1/HZ. Level 2 uses microtime(). It might be desirable for consistency with utimes() and friends, which take timeval structures rather than timespecs. Level 3 uses nanotime() for the higest precision. I benchmarked levels 0, 1, and 3 by copying a 550 MB tree with "cpio -pdu". There was almost negligible difference in the system times -- much less than 1%, and less than the variation among multiple runs at the same level. Bruce Evans dreamed up a torture test involving 1-byte reads with intervening fstat() calls, but the cpio test seems more realistic to me. This feature is currently implemented only for the UFS (FFS and MFS) filesystems. But I think it should be easy to support it in the others as well. An earlier version of this was reviewed by Bruce. He's not to blame for any breakage I've introduced since then. Reviewed by: bde (an earlier version of the code)
* Use more compiler friendly test for overflow.phk1999-08-211-3/+3
| | | | Submitted by: bde
* Detect if the the offset used to read from a raw device loose bitsphk1999-08-211-2/+8
| | | | when converted to block number.
OpenPOWER on IntegriCloud