From: Ben Pfaff Date: Tue, 14 Dec 2004 18:04:52 +0000 (+0000) Subject: Add warnings for missing disks with various projects. X-Git-Url: https://pintos-os.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b54621e208148e3570ad956469b494460da942f2;p=pintos-anon Add warnings for missing disks with various projects. --- diff --git a/src/utils/pintos b/src/utils/pintos index a3c9c4c..bcfe85a 100755 --- a/src/utils/pintos +++ b/src/utils/pintos @@ -216,6 +216,17 @@ sub run_vm { undef $disks[$i] if ! -e $disks[$i]; } + my ($project) = `pwd` =~ /\b(threads|userprog|vm|filesys)\b/; + if (($project eq 'userprog' || $project eq 'vm' || $project eq 'filesys') + && !defined $disks[1]) { + print STDERR "warning: it looks like you're running the $project project, " + . "but no file system disk is present\n"; + } + if ($project eq 'vm' && !defined $disks[3]) { + print STDERR "warning: it looks like you're running the $project project, " + . "but no swap disk is present\n"; + } + write_cmd_line ($disks[0], @_); if ($sim eq 'bochs') {