summaryrefslogtreecommitdiffstats
path: root/usr.bin/fstat
Commit message (Collapse)AuthorAgeFilesLines
* Integrate the new MPSAFE TTY layer to the FreeBSD operating system.ed2008-08-201-0/+52
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The last half year I've been working on a replacement TTY layer for the FreeBSD kernel. The new TTY layer was designed to improve the following: - Improved driver model: The old TTY layer has a driver model that is not abstract enough to make it friendly to use. A good example is the output path, where the device drivers directly access the output buffers. This means that an in-kernel PPP implementation must always convert network buffers into TTY buffers. If a PPP implementation would be built on top of the new TTY layer (still needs a hooks layer, though), it would allow the PPP implementation to directly hand the data to the TTY driver. - Improved hotplugging: With the old TTY layer, it isn't entirely safe to destroy TTY's from the system. This implementation has a two-step destructing design, where the driver first abandons the TTY. After all threads have left the TTY, the TTY layer calls a routine in the driver, which can be used to free resources (unit numbers, etc). The pts(4) driver also implements this feature, which means posix_openpt() will now return PTY's that are created on the fly. - Improved performance: One of the major improvements is the per-TTY mutex, which is expected to improve scalability when compared to the old Giant locking. Another change is the unbuffered copying to userspace, which is both used on TTY device nodes and PTY masters. Upgrading should be quite straightforward. Unlike previous versions, existing kernel configuration files do not need to be changed, except when they reference device drivers that are listed in UPDATING. Obtained from: //depot/projects/mpsafetty/... Approved by: philip (ex-mentor) Discussed: on the lists, at BSDCan, at the DevSummit Sponsored by: Snow B.V., the Netherlands dcons(4) fixed by: kan
* Struct cdev is always the member of the struct cdev_priv. When devfskib2008-06-161-3/+2
| | | | | | | | | | | needed to promote cdev to cdev_priv, the si_priv pointer was followed. Use member2struct() to calculate address of the wrapping cdev_priv. Rename si_priv to __si_reserved. Tested by: pho Reviewed by: ed MFC after: 2 weeks
* Fix build of fstat after minor() changes.ed2008-06-121-1/+1
| | | | | | | | | | Even though I ran a `make universe' to see whether the changes to the device minor number macro's broke the build, I was not expecting `make universe' to silently continue if build errors occured, thus causing me to overlook the build error. Approved by: philip (mentor) Pointyhat to: me
* Use _WANT_FILE to make struct file visible from userland. This ispjd2008-05-261-1/+2
| | | | | | similar to _WANT_UCRED and _WANT_PRISON and seems to be much nicer than defining _KERNEL. It is also needed for my sys/refcount.h change going in soon.
* Use a sledgehammer cast (that was in the original patch to boot) tojhb2008-05-071-1/+1
| | | | | quiet a warning on 64-bit platforms now that 'size' is an int and not a size_t.
* Fix reading the address of a znode_phys from a znode on 64-bit platformsjhb2008-05-071-3/+3
| | | | | | | | where sizeof(pointer) != sizeof(int). MFC after: 1 week PR: amd64/123456 Submitted by: KOIE Hidetaka | hide koie.org
* The debug.sizeof.znode sysctl returns an int, not a size_t. This can causejhb2008-05-071-2/+3
| | | | | | | | a hang on 64-bit platforms. MFC after: 1 week PR: amd64/123456 Submitted by: KOIE Hidetaka | hide koie.org
* Only output details about the current working directory of a process ifjhb2008-05-071-1/+2
| | | | | | | | | the vnode pointer is not NULL. This avoids spurious warnings in fstat -v output for kernel processes. MFC after: 1 week PR: amd64/123456 Submitted by: KOIE Hidetaka | hide koie.org
* Fix some section references.pjd2008-04-291-1/+1
|
* Don't depend on the modification time of the "zfs" subdir.ru2008-04-291-2/+1
|
* - Fix makefile so it doesn't break the build in some corner cases. [1]ru2008-04-292-134/+3
| | | | | | - Remove an extra copy of zfs.c. Reported by: yar [1]
* The sources covered by Sun's CDDL have been repo copied below thejb2008-03-271-8/+8
| | | | | | | | src/cddl and src/sys/cddl directories per the core@ decision following the license review. This change modifies the affected Makefiles to reference the sources in their new location.
* Flag a hack.ru2008-01-241-1/+2
|
* Style.ru2008-01-241-2/+2
|
* Remove _SOLARIS_C_SOURCE now that it doesn't do anything in FreeBSDjb2007-11-281-1/+0
| | | | | | headers. All OpenSolaris compatibility comes via the set of specific compatibility headers in src/compat/opensolaris and src/sys/compat/opensolaris.
* Use variable types which match the function prototypes.jb2007-11-172-2/+4
|
* - Add ZFS-support to fstat(1). This allows ZFS-filsystems to be including inlulf2007-11-056-0/+321
| | | | | | | | | | | the open file-listing. It is added as a separate source file, so it can respect WITH_/WITHOUT_CDDL as compile-flags. - The warnlevel of the Makefile was decreased to quell solaris #pragma warnings. - Expect that fstat(1) doesn't work with kernel compiled with DEBUG_VFS_LOCKS/DEBUG_LOCKS for now. Approved by: pjd (mentor)
* KERN_PROC_ALL produces a kinfo_proc for each thread in a process, whichemaste2007-03-091-1/+1
| | | | | | | caused fstat to produce duplicated output for threaded processes. Instead use KERN_PROC_PROC to get just one kinfo_proc per process. MFC After: 2 weeks
* Add marker vnodes to ensure that all vnodes associated with the mount point aretegge2006-01-091-0/+1
| | | | | | iterated over when using MNT_VNODE_FOREACH. Reviewed by: truckman
* Un-break processing of device major/minor values with fstat -n. We docsjp2005-11-051-3/+5
| | | | | | | | | | | this by accessing the cdev_priv element of the cdev structure. Looking forward we need a better way to handle this, as this structure shouldn't be frobbed by userspace. Submitted by: Doug Steinwand PR: bin/88203 MFC after: 1 week Discussed with: phk
* Introduce kdevtoname, which when given the kernel address of acsjp2005-07-301-4/+16
| | | | | | | | | cdev structure, returns the device name associated with it through the __si_namebuf member. This un-breaks the processing of devices. This is a RELENG_6 candidate. Reviewed by: phk
* Sync program's usage() with manpage's SYNOPSIS.ru2005-05-211-1/+1
|
* Dike out another kvm indiscretion.phk2005-03-161-0/+2
|
* Dike out unwarranted si_udev fondling.phk2005-03-151-1/+2
|
* Expand *n't contractions.ru2005-02-131-3/+3
|
* Add text about jail root directory as well.phk2005-01-301-5/+6
| | | | Submitted by: "Mark W. Krentel" <krentel@dreamscape.com>
* Report jail directory if set.phk2005-01-291-0/+15
| | | | | | | Sanity-check fd_lastfile. PR: 62699 Patch by: "Mark W. Krentel" <krentel@dreamscape.com>
* Sort sections.ru2005-01-181-5/+5
|
* Get the vnode from file.f_vnode instead of file.f_data.ssouhlal2005-01-111-2/+2
| | | | | | | | | | | Nowadays, f_data points to the vnode only if the underlying filesystem doesn't use it for other purposes (devfs uses it to store the cdev, for example). Found by: csjp Reviewed by: csjp Approved by: phk, wes, grehan (mentor) MFC after: 1 week
* filedesc0 is an internal detail of the kernel, don't look at it.phk2004-11-071-13/+9
|
* Add -D_KVM_VNODE to indicate that despite being a userland program,phk2004-10-211-0/+2
| | | | we want to know the vnode structures internals.
* Introduce options list the standard way.charnier2004-07-261-2/+2
|
* Slide pipe.h include after the _KERNEL define in preparation for disallowingsilby2004-07-211-1/+1
| | | | non-_KERNEL inclusions of pipe.h
* Deal with double whitespace.ru2004-07-031-1/+1
|
* Mechanically kill hard sentence breaks.ru2004-07-021-7/+14
|
* 1) ANSIfy.dwmalone2004-06-295-45/+21
| | | | | | | 2) Use %p to print a pointer. 3) Use longs for fileids and ino to avoid comparing signed and unsigned. 4) Make the KVM_READ macro a little more cranky. 5) Set WARNS while I'm here.
* Second half of the dev_t cleanup.phk2004-06-172-7/+7
| | | | | | | | | | | The big lines are: NODEV -> NULL NOUDEV -> NODEV udev_t -> dev_t udev2dev() -> findcdev() Various minor adjustments including handling of userland access to kernel space struct cdev etc.
* Teach fstat(1) about new location for socket state flags relating torwatson2004-06-141-2/+2
| | | | | | | socket buffer state. Submitted by: rik Reminded by: le
* Correct the description of the -N option.ru2004-03-261-2/+2
|
* Do not cache and correctly free() dosmount entry in case of errors.fjoe2003-09-231-3/+4
| | | | PR: 53980 (partially)
* fix this code properly. msdosfs can't have device nodes on them.jmg2003-06-243-3/+7
| | | | | | | comment how to read device nodes from ufs (if an adventurous soul wants to fix it!). Reviewed by: bde
* o Fix rev. 1.41, print a header. -STABLE is OK.maxim2003-06-231-0/+1
| | | | | PR: bin/53585 Submitted by: Alexey Dokuchaev <danfe@regency.nsu.ru>
* correct spelling of struct cdev * from dev_t which is a 32bit type andjmg2003-06-192-3/+3
| | | | | | isn't very useful for passing pointers on LP64 systems. device names on sparc64 and alpha should now work.
* Bow to the whining masses and change a union back into void *. Retaindillon2003-01-131-4/+4
| | | | | removal of unnecessary casts and throw in some minor cleanups to see if anyone complains, just for the hell of it.
* Change struct file f_data to un_data, a union of the correct structdillon2003-01-121-6/+4
| | | | | | | | | | pointer types, and remove a huge number of casts from code using it. Change struct xfile xf_data to xun_data (ABI is still compatible). If we need to add a #define for f_data and xf_data we can, but I don't think it will be necessary. There are no operational changes in this commit.
* Uniformly refer to a file system as "file system".ru2002-12-121-6/+6
| | | | Approved by: re
* Rename struct specinfo to the more appropriate struct cdev.phk2002-09-271-2/+2
| | | | Agreed on: jake, rwatson, jhb
* Userland changes to go with vnode->v_tag change.njl2002-09-141-23/+18
|
* Unbreak building of fstat following version 1.23 ofbmilekic2002-08-141-1/+1
| | | | src/sys/ufs/ufs/quota.h by including mount.h before ufs/quota.h.
* Consistently use FBSDIDobrien2002-06-303-6/+8
|
OpenPOWER on IntegriCloud