perfetto: add callback to TraceWriter.Flush()

Adds the ability to attach a callback to the TraceWriter
Flush() method. This callback notifies when the service
has committed the corresponding data in the central
tracing buffer.
This is a quite important precondition for tests.

Bug: 73612642
Change-Id: If3896792e8f4ace81557b0097a6f66f8147077f9
diff --git a/src/tracing/core/service_impl.h b/src/tracing/core/service_impl.h
index 086f4ba..957f5dd 100644
--- a/src/tracing/core/service_impl.h
+++ b/src/tracing/core/service_impl.h
@@ -66,7 +66,7 @@
     void RegisterDataSource(const DataSourceDescriptor&,
                             RegisterDataSourceCallback) override;
     void UnregisterDataSource(DataSourceID) override;
-    void CommitData(const CommitDataRequest&) override;
+    void CommitData(const CommitDataRequest&, CommitDataCallback) override;
     std::unique_ptr<TraceWriter> CreateTraceWriter(BufferID) override;
     SharedMemory* shared_memory() const override;