1/* 2 * Copyright (C) 2017 The Android Open Source Project 3 * 4 * Licensed under the Apache License, Version 2.0 (the "License"); 5 * you may not use this file except in compliance with the License. 6 * You may obtain a copy of the License at 7 * 8 * http://www.apache.org/licenses/LICENSE-2.0 9 * 10 * Unless required by applicable law or agreed to in writing, software 11 * distributed under the License is distributed on an "AS IS" BASIS, 12 * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied. 13 * See the License for the specific language governing permissions and 14 * limitations under the License. 15 */ 16 17syntax = "proto2"; 18option optimize_for = LITE_RUNTIME; 19 20package perfetto.protos; 21 22// When editing this file run ./tools/gen_tracing_cpp_headers_from_protos.py 23// to reflect changes in the corresponding C++ headers. 24 25// This message is sent from Producer(s) to the tracing Service when registering 26// to advertise their capabilities. It describes the structure of tracing 27// protos that will be produced by the data source and the supported filters. 28message DataSourceDescriptor { 29 optional string name = 1; // e.g., "linux.ftrace", "chromium.tracing" 30 31 // When true the data source is expected to ack the stop request through the 32 // NotifyDataSourceStopped() IPC. This field has been introduced after 33 // Android P in Jul 2018 and is not supported on older versions. 34 optional bool will_notify_on_stop = 2; 35 36 // When true the data source is expected to ack the start request through the 37 // NotifyDataSourceStarted() IPC. This field has been introduced after 38 // Android P in March 2019 and is not supported on older versions. 39 optional bool will_notify_on_start = 3; 40 41 // If true, opt into receiving the ClearIncrementalState() IPC. This should be 42 // set if the data source writes packets that refer to previous trace 43 // contents, and knows how to stop referring to the already-emitted data. 44 optional bool handles_incremental_state_clear = 4; 45 46 // TODO: this should have a structure to enable reflection of the proto 47 // fields emitted (see go/perfetto-logging). 48} 49