OpenAMP Library
rsc_table_parser.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2014, Mentor Graphics Corporation
3  * All rights reserved.
4  *
5  * SPDX-License-Identifier: BSD-3-Clause
6  */
7 
8 #ifndef RSC_TABLE_PARSER_H
9 #define RSC_TABLE_PARSER_H
10 
11 #include <openamp/remoteproc.h>
12 
13 #if defined __cplusplus
14 extern "C" {
15 #endif
16 
17 #define RSC_TAB_SUPPORTED_VERSION 1
18 
19 /* Standard control request handling. */
20 typedef int (*rsc_handler)(struct remoteproc *rproc, void *rsc);
21 
36 int handle_rsc_table(struct remoteproc *rproc,
37  struct resource_table *rsc_table, size_t len,
38  struct metal_io_region *io);
39 
50 int handle_carve_out_rsc(struct remoteproc *rproc, void *rsc);
51 
62 int handle_trace_rsc(struct remoteproc *rproc, void *rsc);
63 int handle_vdev_rsc(struct remoteproc *rproc, void *rsc);
64 int handle_vendor_rsc(struct remoteproc *rproc, void *rsc);
65 
77 size_t find_rsc(void *rsc_table, unsigned int rsc_type, unsigned int index);
78 
79 #if defined __cplusplus
80 }
81 #endif
82 
83 #endif /* RSC_TABLE_PARSER_H */
int handle_rsc_table(struct remoteproc *rproc, struct resource_table *rsc_table, size_t len, struct metal_io_region *io)
Definition: rsc_table_parser.c:23
int handle_vendor_rsc(struct remoteproc *rproc, void *rsc)
Definition: rsc_table_parser.c:105
int handle_trace_rsc(struct remoteproc *rproc, void *rsc)
Definition: rsc_table_parser.c:160
int handle_vdev_rsc(struct remoteproc *rproc, void *rsc)
Definition: rsc_table_parser.c:116
size_t find_rsc(void *rsc_table, unsigned int rsc_type, unsigned int index)
Definition: rsc_table_parser.c:190
int(* rsc_handler)(struct remoteproc *rproc, void *rsc)
Definition: rsc_table_parser.h:20
int handle_carve_out_rsc(struct remoteproc *rproc, void *rsc)
Definition: rsc_table_parser.c:79
Definition: remoteproc.h:366
void * rsc_table
Definition: remoteproc.h:368
Definition: remoteproc.h:55