From 8c901ea3d44c2f4caaa9cc798ee990a46a3a2c83 Mon Sep 17 00:00:00 2001 From: "Carlos J. Torres" Date: Sat, 8 Feb 2014 22:24:17 -0500 Subject: [PATCH 2/2] prefer swap device option --- swapon.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/swapon.c b/swapon.c index 0610385..278aa73 100644 --- a/swapon.c +++ b/swapon.c @@ -10,7 +10,7 @@ static void usage(void) { - eprintf("usage: %s [-d] [-a] device\n", argv0); + eprintf("usage: %s [-dp] [-a] device\n", argv0); } int @@ -28,6 +28,9 @@ main(int argc, char *argv[]) case 'd': flags |= SWAP_FLAG_DISCARD; break; + case 'p': + flags |= SWAP_FLAG_PREFER; + break; default: usage(); } ARGEND; -- 1.8.4