Commit Graph

3782 Commits

Author SHA1 Message Date
dsl 404e35b651 Add (unsigned char) cast to ctype function, reworked to fit on one line 2004-10-29 19:32:22 +00:00
dsl 91d3fe12d9 Add (unsigned char) cast to ctype function 2004-10-29 19:15:20 +00:00
dsl 9ab983c04a Add (unsigned char) cast to ctype function 2004-10-29 19:04:39 +00:00
dsl 09993d7a4e Rewrite getdisklabelpart() to avoid problems with isdigit(*ch_ptr) and
an incorrect check for a (probably impossible) empty string.
Add comments to avoid confusion...
2004-10-29 19:02:17 +00:00
dsl e6bc82d904 Add (unsigned char) cast to ctype function
Fix check for device name ending in [0-9a-h] (strchr(dev, 0) doesn't ever
return NULL - which is fortunate because the () were wrong as well!)
2004-10-29 17:37:30 +00:00
dsl 4b6e82d128 Add (unsigned char) cast to isdigit call 2004-10-28 20:17:19 +00:00
dsl 57030cf931 More isdigit() calls that need (unsigned char) cast 2004-10-28 20:10:29 +00:00
dsl 750ce43a65 Add (unsigned char) to isdigit() call 2004-10-28 19:59:09 +00:00
dsl 25b17683bd Add (unsigned char) to isdigit() calls 2004-10-28 19:48:41 +00:00
dsl 7e4021e835 Add (unsigned char) to isdigit() 2004-10-28 19:43:29 +00:00
dsl 28793e3d2c Add (unsigned char) to isdidgit call 2004-10-28 19:40:47 +00:00
peter 0d5d8e993a Fix a typo in a comment. 2004-10-27 19:36:31 +00:00
oster 42abd8f7a0 Cleanup a bit by nuking RF_Malloc macro, and add in some error
checking for the case where we can't allocate memory.  (Not like
anyone uses this part of the code anyway.)
2004-10-26 22:46:27 +00:00
oster fa730392bc Strip off trailing \n's and spaces from configuration file lines.
Makes RAIDframe more forgiving if you accidentally add a space after
things like device names.  Fixed at long last after a reminder over
the weekend.
2004-10-26 19:52:21 +00:00
oster 2b7fd0220d How about we use the 'len' parameter to rf_get_next_nonblank_line()
instead of assuming all buffers are 256 bytes.
2004-10-26 19:23:19 +00:00
wiz 2f2f733ec3 Sort options. 2004-10-24 17:01:22 +00:00
wiz 3d110d313a Sort options in usage. 2004-10-24 17:01:07 +00:00
snj 24641424de Kill trailing whitespace introduced in the last revision. 2004-10-23 00:41:08 +00:00
snj e85784770d Bump date for last, fix a spelling error, sprinkle some Dq, change
some wording.
2004-10-23 00:39:18 +00:00
bouyer 0a0bd752e8 Add an option (-M) to write a mtree specification (which needs to be passed
through sort before being feed to mtree) with file flags, instead of restoring
file flags at the same time as other attributes. Fix various issue with
schg, uchg, sappnd or uappnd flags which cause restore to fail in some case.
Discussed on tech-userlevel:
http://mail-index.netbsd.org/tech-userlevel/2004/10/12/0000.html
2004-10-22 22:38:38 +00:00
dsainty 1dfaf4a3ca Rearrange the option formatting to be both prettier and more complete 2004-10-21 10:13:00 +00:00
jdolecek 0154132fed constify handlers[] 2004-10-17 11:04:39 +00:00
snj 32eca9407f New sentence, new line; use .Dq instead of ``''. 2004-10-16 05:44:59 +00:00
dsainty 9a582784d5 Bump date for -n description 2004-10-16 04:38:53 +00:00
dsainty d01162a3bc Added -n option, which tests for a present core but doesn't write it
to disk or clear it (does 'nothing').

http://mail-index.netbsd.org/tech-userlevel/2004/10/09/0000.html
2004-10-16 04:29:27 +00:00
dsainty 4b46224291 Added -n option, which tests for a present core but doesn't write it
to disk or clear it (does 'nothing').

http://mail-index.netbsd.org/tech-userlevel/2004/10/09/0000.html
2004-10-16 03:48:15 +00:00
salo 61948d78ec Correct the omission in 're-enter' verification method addition in EXAMPLES. 2004-10-15 15:25:14 +00:00
daniel 84a34aedec Add vm.bufcache, vm.bufmem, vm.bufmem_lowater, m.bufmem_hiwater (PR misc/27247, misc/27233). 2004-10-15 08:47:16 +00:00
gavan 0560d8b947 Initial import of iyonix port.
The Iyonix is a desktop machine from Castle Technology, based on a 600MHz
XScale[tm] 80321 processor.

* Uses the bootloader from NetBSD/acorn32, which is now 32-bit compatible.
* Currently boots multiuser with a serial console.
* Device support is not yet complete.

With help from abs.
2004-10-13 23:28:34 +00:00
dan 603344819a be explicit about the perms of mfs /dev 2004-10-12 10:08:09 +00:00
dsl eef12d4ee1 De __P 2004-10-11 20:13:37 +00:00
dsl edfa669ef6 Remove all the caddr_t - mainly casts of the 3rd arg to ioctl() 2004-10-11 17:13:55 +00:00
dbj 0f5aab3826 always print warning and return non-zero exit when there are unresolved inconsistencies. 2004-10-11 15:24:09 +00:00
wiz 67bfa4e06f Bump date for "offline" description. 2004-10-10 09:45:10 +00:00
ragge 801400d3c7 Cast to (long long int) to make last change compile on amd64. 2004-10-09 20:08:44 +00:00
dsainty ed00687c42 Comment typo: unecessary->unnecessary 2004-10-09 02:51:19 +00:00
soren d353df2fed Add offline command to usage() and man page. 2004-10-08 18:53:42 +00:00
dbj 43cd78416c when allocating inodes, such as for the lost+found directory,
extend the inostat array if needed.  Otherwise, inoinfo() will
return the static "unallocated" inode template, which was
getting improperly modified.
Before this fix, any time the lost+found directory got created,
fsck would set all of the inode/directory counts wrong since
suddenly unallocated inodes would turn into directory inodes
2004-10-08 17:33:52 +00:00
dbj 6ca6b809d3 have allocdir fail cleanly when allocino fails 2004-10-08 17:29:29 +00:00
mycroft 82f913eae9 Combine the listing of enabled/disabled features with the general listing of
features.
Add an "smart error-log" command to display the SMART error-log.
Add an "offline" command to run offline selftests.
2004-10-08 17:19:50 +00:00
dbj a10669f5c2 if debug, print found/expected block & inode counts when incorrect 2004-10-08 16:42:55 +00:00
martin bafafd830d Use PRI* format strings to print 64 bit data types. 2004-09-28 10:01:42 +00:00
wiz 76b7f3faf9 Improve formatting. 2004-09-25 12:44:25 +00:00
snj b7fd6fcc52 Bump date for last. 2004-09-25 04:00:49 +00:00
thorpej ef92b0de59 Try the DIOCGWEDGEINFO ioctl first. If that succeeds (i.e. the block
device is a wedge), use the partition type string from the dkwedge_info
structure to get the file system type.
2004-09-25 03:32:52 +00:00
thorpej 0e37eeed2c Add commands to create, delete, and query the configuration of wedges. 2004-09-25 03:31:35 +00:00
thorpej 6e82649d8e Change the default volume label from "NO NAME" to "NO_NAME". Note the
default in the manual page.
2004-09-22 23:52:38 +00:00
thorpej 3af81aff5a Default the OEM ID to "NetBSD" rather than "BSD 4.4". (Geez, did 4.4BSD
even have a newfs_msdos command?)
2004-09-22 23:46:38 +00:00
thorpej d06c5d9fc6 Correct some examples, and note when it was first included in NetBSD,
not FreeBSD.
2004-09-22 23:40:49 +00:00
rumble dab9f713b9 Do not exceed 80 columns. No functional change. 2004-09-21 15:47:32 +00:00
yamt 22ce35857e fix blks command.
- use 64-bit variables for lbns.
- correct file block offsets in the case of absent indirect blocks.
2004-09-17 12:18:55 +00:00
erh 4ed261aea9 Add a couple cross-references to make similar ctl commands easier to find. 2004-09-16 18:02:27 +00:00
minoura da5384833d Changes from rev 1.34 and 1.35 of sbin/newfs_lfs/lfs.c. 2004-09-15 03:24:09 +00:00
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