diff options
author | dg <dg@FreeBSD.org> | 1994-09-11 03:55:39 +0000 |
---|---|---|
committer | dg <dg@FreeBSD.org> | 1994-09-11 03:55:39 +0000 |
commit | d42dae3660d2c2e7c7d779f5e75371ed40dba58f (patch) | |
tree | b265ba182733f0228946f25c2936523767016dd1 /sys/vm/vm_swap.c | |
parent | 227a0d1584394fdc25f3bfeec4d60be691582073 (diff) | |
download | FreeBSD-src-d42dae3660d2c2e7c7d779f5e75371ed40dba58f.zip FreeBSD-src-d42dae3660d2c2e7c7d779f5e75371ed40dba58f.tar.gz |
Fixed problem with no swap on boot device, but there is some on an
alternate device (as specified via kernel config file)...that casues
the machine to panic.
Diffstat (limited to 'sys/vm/vm_swap.c')
-rw-r--r-- | sys/vm/vm_swap.c | 10 |
1 files changed, 7 insertions, 3 deletions
diff --git a/sys/vm/vm_swap.c b/sys/vm/vm_swap.c index c0e14fb..4eaadf6 100644 --- a/sys/vm/vm_swap.c +++ b/sys/vm/vm_swap.c @@ -31,7 +31,7 @@ * SUCH DAMAGE. * * @(#)vm_swap.c 8.5 (Berkeley) 2/17/94 - * $Id: vm_swap.c,v 1.3 1994/08/02 07:55:40 davidg Exp $ + * $Id: vm_swap.c,v 1.4 1994/08/06 09:15:41 davidg Exp $ */ #include <sys/param.h> @@ -137,11 +137,15 @@ swapinit() bdevvp(swdevt[0].sw_dev, &swdevt[0].sw_vp)) panic("swapvp"); #endif + /* + * If there is no swap configured, tell the user. If there is, + * try to make swap on boot device available now. If this fails, + * no swap space is available there or it isn't configured. + */ if (nswap == 0) printf("WARNING: no swap space found\n"); else if (error = swfree(p, 0)) { - printf("swfree errno %d\n", error); /* XXX */ - panic("swapinit swfree 0"); + printf("WARNING: no swap on boot device - use swapon\n"); } } |