Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(221)

Unified Diff: tools/battor_agent/battor_agent.h

Issue 2390893002: [BattOr] Make BattOr able to return firmware version. (Closed)
Patch Set: [BattOr] Make BattOr able to return firmware version. Created 4 years, 2 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « no previous file | tools/battor_agent/battor_agent.cc » ('j') | tools/battor_agent/battor_agent_unittest.cc » ('J')
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: tools/battor_agent/battor_agent.h
diff --git a/tools/battor_agent/battor_agent.h b/tools/battor_agent/battor_agent.h
index 810df26936af2cf15d4c72845937aa7fac8da676..468c7e075f3d204fc9f60286b6bc726fa87ee460 100644
--- a/tools/battor_agent/battor_agent.h
+++ b/tools/battor_agent/battor_agent.h
@@ -43,6 +43,8 @@ class BattOrAgent : public BattOrConnection::Listener,
virtual void OnStopTracingComplete(const std::string& trace,
BattOrError error) = 0;
virtual void OnRecordClockSyncMarkerComplete(BattOrError error) = 0;
+ virtual void OnGetFirmwareGitHashComplete(const std::string& version,
+ BattOrError error) = 0;
};
BattOrAgent(
@@ -55,6 +57,7 @@ class BattOrAgent : public BattOrConnection::Listener,
void StartTracing();
void StopTracing();
void RecordClockSyncMarker(const std::string& marker);
+ void GetFirmwareGitHash();
// Returns whether the BattOr is able to record clock sync markers in its own
// trace log.
@@ -85,6 +88,7 @@ class BattOrAgent : public BattOrConnection::Listener,
START_TRACING,
STOP_TRACING,
RECORD_CLOCK_SYNC_MARKER,
+ GET_GIT_HASH,
charliea (OOO until 10-5) 2016/10/20 12:23:28 (here and elsewhere): probably want "firmware git
rnephew (Reviews Here) 2016/10/20 18:03:43 Done.
};
enum class Action {
@@ -111,6 +115,10 @@ class BattOrAgent : public BattOrConnection::Listener,
// Actions required for recording a clock sync marker.
SEND_CURRENT_SAMPLE_REQUEST,
READ_CURRENT_SAMPLE,
+
+ // Actions required for checking firmware version.
charliea (OOO until 10-5) 2016/10/20 12:23:28 same as before: "Actions required for returning th
rnephew (Reviews Here) 2016/10/20 18:03:43 I remember changing this... I swear.
+ SEND_GIT_HASH_REQUEST,
+ READ_GIT_HASH,
};
// Performs an action.
@@ -181,6 +189,9 @@ class BattOrAgent : public BattOrConnection::Listener,
// The timeout that's run when an action times out.
base::CancelableClosure timeout_callback_;
+ // The git hash of the BattOr firmware.
+ std::string git_hash_;
+
DISALLOW_COPY_AND_ASSIGN(BattOrAgent);
};
« no previous file with comments | « no previous file | tools/battor_agent/battor_agent.cc » ('j') | tools/battor_agent/battor_agent_unittest.cc » ('J')

Powered by Google App Engine
This is Rietveld 408576698