• Home
  • Line#
  • Scopes#
  • Navigate#
  • Raw
  • Download
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  */
17 #ifndef ESE_REPLAY_PAYLOAD_H__
18 #define ESE_REPLAY_PAYLOAD_H__ 1
19 
20 #include <stdint.h>
21 #include <stdio.h>
22 #include <stdlib.h>
23 
24 #include "buffer.h"
25 
26 struct Payload {
27   struct Buffer tx;
28   struct Buffer expected;
29 };
30 
31 bool payload_init(struct Payload *p, uint32_t tx_len, uint32_t exp_len);
32 void payload_free(struct Payload *p);
33 bool payload_read(struct Payload *p, FILE *fp);
34 void payload_dump(const struct Payload *payload, FILE *fp);
35 
36 #endif  /* ESE_REPLAY_PAYLOAD_H__ */
37