From 0b24e9dc9eeea8a2885061ca45ac1cf115aaf5b5 Mon Sep 17 00:00:00 2001 From: Sameer Nanda Date: Fri, 10 Oct 2014 08:57:24 -0700 Subject: temp_metrics: add "--" when invoking ectool tmp006cal ectool has switched over to using getopt for command line options parsing. This breaks temp_metrics' invocation of "ectool tmp006cal" command since some of the coefficients are negative and therefore start with "-". getopt treats that as another command line option causing ectool to barf. BUG=chromium:422160 TEST=On a Pixel issue "sudo start temp_metrics" and check /var/log/messages to ensure that no new messages such as "init: temp_metrics main process ended, respawning" show up. BRANCH=none Original-Change-Id: I42232b3027ec6339814d226f1d8ab493e3420eea Signed-off-by: Sameer Nanda Reviewed-on: https://chromium-review.googlesource.com/222845 Reviewed-by: Randall Spangler (cherry picked from commit 63c41f239223cb343978635c7409ee341eeb08d8) Change-Id: I42af09c1a8d6a6cc4718cebe446786603b1748f1 Reviewed-on: https://chromium-review.googlesource.com/223298 Reviewed-by: Randall Spangler Commit-Queue: Sameer Nanda Tested-by: Sameer Nanda --- util/temp_metrics.conf | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/util/temp_metrics.conf b/util/temp_metrics.conf index 307938d019..bf10ee0907 100644 --- a/util/temp_metrics.conf +++ b/util/temp_metrics.conf @@ -107,7 +107,9 @@ script CHARGER_D="3 $CHARGER_D_S0 $B0 $B1 $B2" for i in "$USB_C" "$PCH_D" "$HINGE_C" "$CHARGER_D"; do - ectool tmp006cal $i + # Add "--" otherwise ectool will barf when trying to parse negative + # coefficients. + ectool tmp006cal -- $i done } -- cgit v1.2.1