Commit Graph

169 Commits

Author SHA1 Message Date
tls ea6af427bd Merge tls-earlyentropy branch into HEAD. 2014-08-10 16:44:32 +00:00
christos d2bf840533 fix protocol printing order. 2014-02-14 20:43:34 +00:00
christos c7b4698e4c make fstat -f search for unix sockets. 2014-01-17 03:28:01 +00:00
mlelstv 9a7a6e815f Fix output for -A -f ... 2013-12-15 18:56:59 +00:00
wiz 82c52eb924 sync usage with man page 2013-12-15 09:21:03 +00:00
wiz 73135dc321 Sort SYNOPSIS and option descriptions. Bump date for previous. 2013-12-15 09:20:48 +00:00
mlelstv b3d56b5ecb New -A option. Add an output column with the address of the
kernel object (vnode or file) that can be matched with prstat(8) output.
2013-12-15 08:16:24 +00:00
christos 04908d82dd use correct function and symbolic constants 2013-10-19 15:56:05 +00:00
christos 35be7e66a7 use new scopeid functions 2013-10-19 00:28:38 +00:00
christos 3c6b5224e0 avoid pointer gymnastics 2013-10-18 20:18:42 +00:00
riastradh a7f90b2fd2 Fix races in /dev/u?random initialization and accounting.
- Push /dev/random `information-theoretic' accounting into cprng(9).
- Use percpu(9) for the per-CPU CPRNGs.
- Use atomics with correct memory barriers for lazy CPRNG creation.
- Remove /dev/random file kmem grovelling from fstat(1).
2013-07-01 15:22:00 +00:00
riastradh 6290b0987e Rework rndsink(9) abstraction and adapt arc4random(9) and cprng(9).
rndsink(9):
- Simplify API.
- Simplify locking scheme.
- Add a man page.
- Avoid races in destruction.
- Avoid races in requesting entropy now and scheduling entropy later.

Periodic distribution of entropy to sinks reduces the need for the
last one, but this way we don't need to rely on periodic distribution
(e.g., in a future tickless NetBSD).

rndsinks_lock should probably eventually merge with the rndpool lock,
but we'll put that off for now.

cprng(9):
- Make struct cprng_strong opaque.
- Move rndpseudo.c parts that futz with cprng guts to subr_cprng.c.
- Fix kevent locking.  (Is kevent locking documented anywhere?)
- Stub out rump cprng further until we can rumpify rndsink instead.
- Strip code to grovel through struct cprng_strong in fstat.
2013-06-23 02:35:23 +00:00
christos 3d7bb1da45 support printing rnd descriptor info 2012-11-25 15:30:28 +00:00
christos 0548a80ae0 return stuff for ksem 2012-11-25 01:05:49 +00:00
christos c7c1f1a254 - add more debugging.
- in misctrans() we need the file index not the file type.
2012-11-25 00:36:23 +00:00
alnsn 4d1ae9a9af Report jit'ed bpf fildes in fstat. 2012-10-27 22:38:07 +00:00
christos 0d87ef641d print major device numbers symbolically from kinfo_drivers 2012-10-19 02:49:52 +00:00
christos 902a40f133 more info for unix sockets. XXX: chroot handling 2012-10-19 02:11:25 +00:00
wiz fde0458761 - In the example for `-f', reference a directory that is actually
available in a default installation (/usr/src isn't);
- put together two lines which belong to the same sentence;
- remove a spurious space character;
- remove unneeded consecutive argument for `.Nm' macro.

From Bug Hunting.
2012-10-03 19:35:08 +00:00
christos 8e13556964 fix non-numeric address and port printing. 2012-09-26 23:01:04 +00:00
christos 0b08384416 byte swap the inet6 ports. 2012-03-24 21:51:23 +00:00
chs 585f34003b fix rdev reporting for UFS2 and ext2fs. 2011-10-09 21:16:00 +00:00
jnemeth e894be756a add an xref to fstat(2) 2011-10-08 22:16:03 +00:00
mrg 81a1075469 apply some (uintptr_t) so that printing printers works on i386 (likely
all 32 bit.)
2011-09-23 07:31:39 +00:00
christos a0af16e360 - factor out common code in the inet and inet6 printing.
- add appletalk (ddp) support.
2011-09-22 17:27:50 +00:00
christos 2ba0028160 - remove bogus casts
- print recycled vnode flags
2011-09-10 18:35:28 +00:00
christos ebb6dc2ee4 add libutil. 2011-09-10 18:34:54 +00:00
christos 48bd4d9cb5 add all the possible fileops here, and if there is one we know about
print that instead of the passed name.
2011-09-10 18:34:40 +00:00
wiz 2a5f867d29 Remove trailing whitespace and use Sx for section crossreference. 2011-09-06 19:22:05 +00:00
christos f5cf37944f move UNIX socket mention in the BUGS section. 2011-09-06 11:31:47 +00:00
wiz ba45f45512 Remove duplicate RCS Id and split file system. 2011-09-05 18:27:31 +00:00
christos 44f7f983f5 - minor KNF
- for system processes (0, 1) where fd_lastfile == -1, fail early.
- instead of printing the pcb connection address, print the pathname if
  possible for unix domain sockets.
2011-09-03 13:24:19 +00:00
christos 21e29f6268 Mention that fstat -f will not list open unix sockets on that filesystem. 2011-09-03 13:22:55 +00:00
rmind 8a0123cd33 - Prevent tmpfs.h from inclusion in userland.
- Clean up and KNF tmpfs.h a little bit.
2011-05-29 01:00:50 +00:00
rmind e7ba7d8ca0 Add DTYPE_SEM. 2011-04-14 00:35:35 +00:00
christos 585ce9eda6 move _KMEMUSER higher! 2009-07-13 21:44:32 +00:00
christos d96e875904 need _KMEMUSER too. 2009-07-13 21:43:24 +00:00
christos f73facbc14 sys/mqueue.h needs sys/types.h now 2009-07-13 17:57:35 +00:00
ad d991fcb3b6 More changes to improve kern_descrip.c.
- Avoid atomics in more places.
- Remove the per-descriptor mutex, and just use filedesc_t::fd_lock.
  It was only being used to synchronize close, and in any case we needed
  to take fd_lock to free the descriptor slot.
- Optimize certain paths for the <NDFDFILE case.
- Sprinkle more comments and assertions.
- Cache more stuff in filedesc_t.
- Fix numerous minor bugs spotted along the way.
- Restructure how the open files array is maintained, for clarity and so
  that we can eliminate the membar_consumer() call in fd_getfile().  This is
  mostly syntactic sugar; the main functional change is that fd_nfiles now
  lives alongside the open file array.

Some measurements with libmicro:

- simple file syscalls are like close() are between 1 to 10% faster.
- some nice improvements, e.g. poll(1000) which is ~50% faster.
2009-05-24 21:41:25 +00:00
lukem c1ceae17f0 Enable WARNS=4 by default for usr.bin, except for:
awk  bdes  checknr  compile_et  error  gss  hxtool  kgetcred  kinit
	klist  ldd  less  lex  locale  login  m4  man  menuc  mk_cmds
	mklocale  msgc  openssl  rpcgen  rpcinfo  sdiff  spell  ssh
	string2key  telnet  tn3270  verify_krb5_conf  xlint
2009-04-14 22:15:16 +00:00
lukem dadffc77c0 Fix sign-compare issues. 2009-04-12 06:36:12 +00:00
christos 90baf4f26f only print warnings if vflg. 2009-02-26 17:30:51 +00:00
wiz 0ca945fa16 Sockets: Do not mention printing flags, because they are not printed.
From Stephan A. Rickauer via jmc@openbsd.

Bump date.
2009-01-04 17:19:39 +00:00
christos 4fe86cf5b0 64 bit dev_t 2008-12-29 00:59:08 +00:00
gmcgarry 0e0358051d Cast f_type to signed integer before comparison with negative values. 2008-09-09 00:56:23 +00:00
pooka f00b7c9b12 Solve the fstat-wants-to-look-at-kernel-data-structures in a nicer
way: don't export the fs internals to innocent userspace programs
which just want to mount the file system.
2008-07-29 09:10:09 +00:00
pooka f99d5e92e0 include correct header 2008-07-28 18:05:09 +00:00
christos 8dd0b4459d handle more types. 2008-07-23 11:59:43 +00:00
lukem 93505eb7ec Add back rev 1.83. (hi christos!) 2008-07-23 00:57:53 +00:00
christos 380fafb740 a better attempt on printing dtype_misc 2008-07-22 22:58:04 +00:00