CHROMIUM: crostestutils: add --board parameter

Need to pass --board to run_remote.sh if it's not the same as
the default board.

BUG=None
TEST=Manual

Change-Id: I49aca91387452f68d40089bc2bf1a0f9bd450c6d
Signed-off-by: Grant Grundler <grundler@chromium.org>
Reviewed-on: https://gerrit.chromium.org/gerrit/51221
Reviewed-by: Richard Barnette <jrbarnette@chromium.org>
diff --git a/bootperf-bin/bootperf b/bootperf-bin/bootperf
index 019f816..8bbf2c2 100755
--- a/bootperf-bin/bootperf
+++ b/bootperf-bin/bootperf
@@ -40,6 +40,7 @@
 assert_inside_chroot
 
 DEFINE_string output_dir "" "output directory for results" o
+DEFINE_string board "" "name of board we are testing"
 DEFINE_boolean keep_logs "$FLAGS_FALSE" "keep autotest results" k
 
 RUN_TEST="run_remote_tests.sh"
@@ -87,6 +88,8 @@
   --output_dir <directory>
   --o <directory>       Specify output directory for results
 
+  --board <BOARDNAME>   name of board we are testing (e.g. daisy)
+
   --[no]keep_logs
   -k                    Keep [don't keep] autotest log files
 Summary:
@@ -167,7 +170,7 @@
     # changes to the package.  (The option is here because IMO the
     # alternative is a bigger nuisance.)
     $RUN_TEST --use_emerged --results_dir_root="$TMP_RESULTS" \
-              --remote="$remote" $TEST >$logfile 2>&1
+              --remote="$remote" $BOARD $TEST >$logfile 2>&1
     if [ ! -e "$TMP_RESULTS/$RESULTS_KEYVAL" ]; then
       error "No results file; terminating test runs."
       error "Check $logfile for output from the test run,"
@@ -200,6 +203,10 @@
       usage "Too many arguments"
   fi
 
+  if [ -n "${FLAGS_board}" ]; then
+    BOARD="--board=${FLAGS_board}"
+  fi
+
   if [ -n "${FLAGS_output_dir}" ]; then
     if [ ! -d "${FLAGS_output_dir}" ]; then
       if ! mkdir "${FLAGS_output_dir}"; then