blob: 0051d4c67c3d9cd360fc47d698f162b01b00cced [file] [log] [blame]
Keun Soo Yime0c0cdd2016-05-09 19:43:43 -07001// Copyright 2016 The Android Open Source Project
2//
3// Licensed under the Apache License, Version 2.0 (the "License");
4// you may not use this file except in compliance with the License.
5// You may obtain a copy of the License at
6//
7// http://www.apache.org/licenses/LICENSE-2.0
8//
9// Unless required by applicable law or agreed to in writing, software
10// distributed under the License is distributed on an "AS IS" BASIS,
11// WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12// See the License for the specific language governing permissions and
13// limitations under the License.
14
15syntax = "proto2";
16
17package android.vts;
18
19
20// Type of a command.
21enum CommandType {
Keun Soo Yimfeceb4d2016-05-11 20:01:00 -070022 UNKNOWN_COMMAND_TYPE = 0;
Keun Soo Yime0c0cdd2016-05-09 19:43:43 -070023 // To check whether fuzzer's binder service is available.
24 CHECK_FUZZER_BINDER_SERVICE = 1;
25 // To start a fuzzer binary service.
26 START_FUZZER_BINDER_SERVICE = 2;
27
28 // To get a list of available HAL modules.
29 GET_HALS = 101;
30 // To select a HAL module.
31 SELECT_HAL = 102;
32
33 // To get a list of available functions.
34 GET_FUNCTIONS = 201;
35 // To call a function.
36 CALL_FUNCTION = 202;
37}
38
39
40// Type of a response.
41enum ResponseCode {
Keun Soo Yimfeceb4d2016-05-11 20:01:00 -070042 UNKNOWN_RESPONSE_CODE = 0;
Keun Soo Yime0c0cdd2016-05-09 19:43:43 -070043 // successful
44 SUCCESS = 1;
45 // failed
46 FAIL = 2;
47}
48
49
50// To specify a command.
51message AndroidSystemControlCommandMessage {
52 // Command type.
53 optional CommandType command_type = 1;
54
55 // The name of a target.
56 optional bytes target_name = 1001;
Keun Soo Yimfeceb4d2016-05-11 20:01:00 -070057
58 // for when command_type == SELECT_HAL
59 // target class
60 optional int32 target_class = 2001;
61 // target type
62 optional int32 target_type = 2002;
63 // target version (should be divided by 100) - float has a compatibility issue
64 // between C/C++ and python protoc.
65 optional int32 target_version = 2003;
Keun Soo Yime0c0cdd2016-05-09 19:43:43 -070066}
67
68
69// To specify a response.
70message AndroidSystemControlResponseMessage {
71 // Response type.
72 optional ResponseCode response_code = 1;
73
74 // The reason.
75 optional bytes reason = 1001;
76}