1 /* SPDX-License-Identifier: GPL-2.0 */
2 /*
3  * Support for Intel Camera Imaging ISP subsystem.
4  * Copyright (c) 2010 - 2015, Intel Corporation.
5  */
6 
7 #ifndef _IA_CSS_RMGR_H
8 #define _IA_CSS_RMGR_H
9 
10 #include <ia_css_err.h>
11 
12 #ifndef __INLINE_RMGR__
13 #define STORAGE_CLASS_RMGR_H extern
14 #define STORAGE_CLASS_RMGR_C
15 #else				/* __INLINE_RMGR__ */
16 #define STORAGE_CLASS_RMGR_H static inline
17 #define STORAGE_CLASS_RMGR_C static inline
18 #endif				/* __INLINE_RMGR__ */
19 
20 /**
21  * @brief Initialize resource manager (host/common)
22  */
23 int ia_css_rmgr_init(void);
24 
25 /**
26  * @brief Uninitialize resource manager (host/common)
27  */
28 void ia_css_rmgr_uninit(void);
29 
30 /*****************************************************************
31  * Interface definition - resource type (host/common)
32  *****************************************************************
33  *
34  * struct ia_css_rmgr_<type>_pool;
35  * struct ia_css_rmgr_<type>_handle;
36  *
37  * STORAGE_CLASS_RMGR_H void ia_css_rmgr_init_<type>(
38  *	struct ia_css_rmgr_<type>_pool *pool);
39  *
40  * STORAGE_CLASS_RMGR_H void ia_css_rmgr_uninit_<type>(
41  *	struct ia_css_rmgr_<type>_pool *pool);
42  *
43  * STORAGE_CLASS_RMGR_H void ia_css_rmgr_acq_<type>(
44  *	struct ia_css_rmgr_<type>_pool *pool,
45  *	struct ia_css_rmgr_<type>_handle **handle);
46  *
47  * STORAGE_CLASS_RMGR_H void ia_css_rmgr_rel_<type>(
48  *	struct ia_css_rmgr_<type>_pool *pool,
49  *	struct ia_css_rmgr_<type>_handle **handle);
50  *
51  *****************************************************************
52  * Interface definition - refcounting (host/common)
53  *****************************************************************
54  *
55  * void ia_css_rmgr_refcount_retain_<type>(
56  *	struct ia_css_rmgr_<type>_handle **handle);
57  *
58  * void ia_css_rmgr_refcount_release_<type>(
59  *	struct ia_css_rmgr_<type>_handle **handle);
60  */
61 
62 #include "ia_css_rmgr_vbuf.h"
63 
64 #endif	/* _IA_CSS_RMGR_H */
65