1 /*
2  * Support for Intel Camera Imaging ISP subsystem.
3  * Copyright (c) 2010 - 2015, Intel Corporation.
4  *
5  * This program is free software; you can redistribute it and/or modify it
6  * under the terms and conditions of the GNU General Public License,
7  * version 2, as published by the Free Software Foundation.
8  *
9  * This program is distributed in the hope it will be useful, but WITHOUT
10  * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
11  * FITNESS FOR A PARTICULAR PURPOSE.  See the GNU General Public License for
12  * more details.
13  */
14 
15 #ifndef _IA_CSS_RMGR_H
16 #define _IA_CSS_RMGR_H
17 
18 #include <ia_css_err.h>
19 
20 #ifndef __INLINE_RMGR__
21 #define STORAGE_CLASS_RMGR_H extern
22 #define STORAGE_CLASS_RMGR_C
23 #else				/* __INLINE_RMGR__ */
24 #define STORAGE_CLASS_RMGR_H static inline
25 #define STORAGE_CLASS_RMGR_C static inline
26 #endif				/* __INLINE_RMGR__ */
27 
28 /**
29  * @brief Initialize resource manager (host/common)
30  */
31 int ia_css_rmgr_init(void);
32 
33 /**
34  * @brief Uninitialize resource manager (host/common)
35  */
36 void ia_css_rmgr_uninit(void);
37 
38 /*****************************************************************
39  * Interface definition - resource type (host/common)
40  *****************************************************************
41  *
42  * struct ia_css_rmgr_<type>_pool;
43  * struct ia_css_rmgr_<type>_handle;
44  *
45  * STORAGE_CLASS_RMGR_H void ia_css_rmgr_init_<type>(
46  *	struct ia_css_rmgr_<type>_pool *pool);
47  *
48  * STORAGE_CLASS_RMGR_H void ia_css_rmgr_uninit_<type>(
49  *	struct ia_css_rmgr_<type>_pool *pool);
50  *
51  * STORAGE_CLASS_RMGR_H void ia_css_rmgr_acq_<type>(
52  *	struct ia_css_rmgr_<type>_pool *pool,
53  *	struct ia_css_rmgr_<type>_handle **handle);
54  *
55  * STORAGE_CLASS_RMGR_H void ia_css_rmgr_rel_<type>(
56  *	struct ia_css_rmgr_<type>_pool *pool,
57  *	struct ia_css_rmgr_<type>_handle **handle);
58  *
59  *****************************************************************
60  * Interface definition - refcounting (host/common)
61  *****************************************************************
62  *
63  * void ia_css_rmgr_refcount_retain_<type>(
64  *	struct ia_css_rmgr_<type>_handle **handle);
65  *
66  * void ia_css_rmgr_refcount_release_<type>(
67  *	struct ia_css_rmgr_<type>_handle **handle);
68  */
69 
70 #include "ia_css_rmgr_vbuf.h"
71 
72 #endif	/* _IA_CSS_RMGR_H */
73