Commit Graph

3679 Commits

Author SHA1 Message Date
dsl
9721e88965 Fix intuit_translated_geometry() calculation.
From Izumi Tsutsui in PR bin/26917
2004-09-12 07:46:24 +00:00
yamt
48f5be416a - calculate maxfilesize dynamically rather than having a static table.
- no longer limit filesize to INT32_MAX.  file lbns are 64-bit these days.
  anyway, on-disk format shouldn't be limited by the kernel internals.
2004-09-11 08:33:53 +00:00
atatat
d96c6bad93 Add some more attribute "names", taken from
http://freepgs.com/smart/attributes.php

which gets them from smartmontools as maintained by Bruce Allen.

Note that some of these attributes should be "named" differently
depending on the drive (point for future work?), but at least now
there are names for some of the one that were missing them.
2004-09-10 04:11:09 +00:00
atatat
2a3ef0e821 White space police 2004-09-10 03:43:52 +00:00
yamt
6928fd95a8 fix a sign expansion bug for >=8k blocksizes. 2004-09-09 22:57:19 +00:00
jrf
190b2e4c51 Replaced strncpy with strlcpy. Thanks to Peter Postma who
pointed them our in PR #25762. Approved by christos@NetBSD.org.
2004-09-07 13:20:39 +00:00
lukem
1e6cfcfcaf fix typo 2004-09-07 02:18:06 +00:00
jdolecek
56afb5b885 fix typo 2004-09-01 19:38:09 +00:00
chs
a3b206f61a pass data to a function via an argument instead of via a global variable.
this avoids a name collision with libcurses functions when both are
present in a crunched static binary.  part of PR 26458.
2004-09-01 01:47:09 +00:00
uwe
06227c9f8b Drop bogus .Bl/.El uncovered by new mdoc. 2004-08-31 17:08:06 +00:00
wiz
ef90a2a4b4 Bump date for improved bad sector
description.
2004-08-30 12:53:30 +00:00
drochner
afa0d914f3 mention that the "badsector" subcommend depends on the WD_BADSECTOR
kernel option
2004-08-30 09:38:28 +00:00
wiz
484705032c Bump date for removal of net.key.random_int. 2004-08-27 14:35:11 +00:00
itojun
8ba8c58e74 remove net.key.random_int 2004-08-27 04:58:10 +00:00
christos
4ee0bfb762 Remove special case for RESCUEDIR 2004-08-19 23:02:51 +00:00
christos
c7e7e2b5bf Remove special case 2004-08-19 23:02:27 +00:00
christos
79455d444d Handle RESCUEDIR 2004-08-19 23:00:22 +00:00
christos
ea369b9669 Deal with RESCUEDIR 2004-08-19 22:25:49 +00:00
christos
684fe4faed Remove RESCUEDIR hack; it will be done centrally. 2004-08-19 22:21:51 +00:00
drochner
bdf36e0430 +drvctl 2004-08-19 10:20:59 +00:00
wiz
702f9dca18 Sync usage with man page. 2004-08-18 13:24:55 +00:00
wiz
79632fc9ad New sentence, new line. 2004-08-18 13:21:36 +00:00
drochner
0c34f6cd99 add a little utility to exercise the rescan / detach autoconf functions 2004-08-18 12:30:01 +00:00
mycroft
e0fc84bd24 Put back one of the sleep()s -- it doesn't affect us in the usual case. 2004-08-13 17:22:39 +00:00
mycroft
f3b5a6849c Replace the sleep(2) in setctty() with a nanosleep(), with a default value of
250ms.
2004-08-13 17:19:15 +00:00
mycroft
40321c3f44 Remove a completely gratuitous 30 delay if you enter the wrong shell path. 2004-08-13 17:11:49 +00:00
wiz
a5c8081d79 Bump date for previous, and re-add some flags that were removed in the
previous commit without a mention in the commit message, and which are
still in the usage.
2004-08-13 15:24:03 +00:00
tv
21840e450a Add "urandomkey" key generation method as described in PR kern/22766;
useful for configuring a throwaway key for cgd-on-swap at boot time.
2004-08-13 15:03:57 +00:00
rumble
6b72b5c789 In getkey(), check the return values of the various keygen functions
and abort if necessary. Also, check for errors in its callers and
handle them gracefully.

OK'd by elric.
2004-08-10 02:29:34 +00:00
rumble
3db339be14 Avoid dereferencing/free()ing invalid pointers if the random device
cannot be opened.

OK'd by elric.
2004-08-10 02:27:26 +00:00
lukem
c9e78fddc5 Signal handlers should manipulate 'volatile sig_atomic_t' instead of 'int'. 2004-08-08 09:46:16 +00:00
christos
fe9cbbdccb cleanup some lint
remove unused variables
XXX: fs.h macros are not portable in ansi.
2004-08-08 02:51:19 +00:00
christos
ad04e20d5f warns = 3 2004-08-08 02:50:46 +00:00
christos
7abcefad61 - fix broken superblock finding code was wrong.
- ansify, KNF
- if the filesystem was not modified, don't ask the user to fsck.
2004-08-08 00:55:06 +00:00
wiz
2e3cdda09c No leading zeroes in date string. 2004-08-02 23:16:02 +00:00
bouyer
502e9c8209 Add infrastructure for ATA bus commands, and implement the reset bus command. 2004-08-01 21:41:49 +00:00
dbj
3aca86e05b check sysctl error return on both calls.
this prevents sysctl from coredumping if the second call fails while the
first succeeds.  This isn't supposed to happen, but there is another bug
in the i386 kernel implementation of sysctl machdep.diskinfo that excites this
2004-07-30 23:42:29 +00:00
jmmv
ea287a80b7 Add 2004 to copyright notice as these has been significantly modified recently. 2004-07-30 15:22:42 +00:00
jmmv
1e4eaac87a Add an example on how to change the kernel message colors. This is
illustrative because it shows the use of the '-d' flag and how one can
set multiple variables in the same run of wsconsctl(8).
2004-07-30 11:21:16 +00:00
jmmv
fcc698e864 Do not show several variables when they are not available.
At the moment this only affects the display part, hiding console colors,
border color and/or console scrollback if their respective ioctls are
not supported by the running kernel.

Trying to write to these variables will still fail with the correct ioctl
error message.
2004-07-30 11:08:03 +00:00
jmmv
2a08d54a9a Implement border color customization in wscons(4), only available for vga(4)
at the moment.

This includes the addition of two new wsdisplay ioctls, WSDISPLAY_{G,S}BORDER,
one to get the actual color and one to set it, respectively.  Possible colors
match those defined by ANSI (and listed in wsdisplayvar.h).

It also adds two accessops to the underlying graphics device, getborder and
setborder, which mach their ioctl counterparts.

Two kernel options are added: WSDISPLAY_CUSTOM_BORDER, which enables the
ioctls described above (to customize the border color from userland after
boot), and WSDISPLAY_BORDER_COLOR, which sets the color at boot time.
The former is enabled by default on the GENERIC kernel, but not on INSTALL
(among others).  The later is always commented out, leaving the usual black
border as a default.

wsconsctl is modified to allow accessing this value easily.  For example,
'wsconsctl -d -w border=blue'.
2004-07-29 22:29:35 +00:00
jmmv
92f81ea7d3 Implement support to dynamically change wscons console and kernel colors.
Two new ioctls are added to the wsdisplay device, named WSDISPLAY_GMSGATTRS
and WSDISPLAY_SMSGATTRS, used to retrieve the actual values and set them,
respectively (the name, if you are wondering, comes from "message attributes").

A new emulop is added to the underlying display driver (only vga, for now)
which sets the new attribute for the whole screen, without having to clear
it.  This is optional, which means that this also works with other drivers
that don't have this new operation.

Five new kernel options have been added, although only documented in
i386 kernels (for now):
- WSDISPLAY_CUSTOM_OUTPUT, which enables the ioctls described above to
  change the colors dynamically from userland.  This is enabled by default
  in the GENERIC kernel (as well as others) but disabled on all INSTALL*
  kernels (as this feature is useless there).
- WS_DEFAULT_COLATTR, WS_DEFAULT_MONOATTR, WS_DEFAULT_BG and WS_DEFAULT_FG,
  which specify the default colors for the console at boot time.  These have
  the same meaning as the (already existing) WS_KERNEL_* variables.

wsconsctl is modified to add msg.default.{attrs,bg,fg} and
msg.kernel.{attrs,bg,fg} to the display part, so that colors can be changed
after boot.

Tested on NetBSD/i386 with vga (and vga in mono mode), and on NetBSD/mac68k.
No objections in tech-kern@.
2004-07-28 12:34:02 +00:00
yamt
230c4c9c74 err -> errx where appropriate. 2004-07-27 14:25:19 +00:00
wiz
816f9f8757 Add -D to usage; shorten -b argument for usage's sake; format usage.
Man page nits.
2004-07-27 14:20:11 +00:00
enami
047e7ad434 Whitespace nits. 2004-07-27 02:20:56 +00:00
enami
5d75faa43f Add -D flag which computes the digest of each regular files in the archive
using specified algorithm (currently md5, rmd160 or sha1) and write them
to standard output.
2004-07-27 02:17:06 +00:00
yamt
5272b4dd6e ignore promiscuous messages by checking sadb_msg_pid.
ok'ed by itojun.
2004-07-23 12:47:55 +00:00
mycroft
20f54b189f Reduce memory usage slightly. 2004-07-20 15:05:32 +00:00
yamt
17d264b6df zero-out dinode is not a proper way to 'clear' an lfs inode. 2004-07-18 20:51:30 +00:00
yamt
078a5e0d1f remove a prototype of a non-exist function. 2004-07-18 20:03:12 +00:00