2 Support for Intel Camera Imaging ISP subsystem.
3 Copyright (c) 2010 - 2015, Intel Corporation.
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.
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
15 #ifndef _IA_CSS_ISP_PARAM_TYPES_H_
16 #define _IA_CSS_ISP_PARAM_TYPES_H_
18 #include "ia_css_types.h"
19 #include <platform_support.h>
20 #include <system_global.h>
23 #define IA_CSS_ISP_DMEM IA_CSS_ISP_DMEM0
24 #define IA_CSS_ISP_VMEM IA_CSS_ISP_VMEM0
26 /* The driver depends on this, to be removed later. */
27 #define IA_CSS_NUM_ISP_MEMORIES IA_CSS_NUM_MEMORIES
29 /* Explicit member numbering to avoid fish type checker bug */
30 enum ia_css_param_class {
31 IA_CSS_PARAM_CLASS_PARAM = 0, /* Late binding parameters, like 3A */
32 IA_CSS_PARAM_CLASS_CONFIG = 1, /* Pipe config time parameters, like resolution */
33 IA_CSS_PARAM_CLASS_STATE = 2, /* State parameters, like tnr buffer index */
34 #if 0 /* Not yet implemented */
35 IA_CSS_PARAM_CLASS_FRAME = 3, /* Frame time parameters, like output buffer */
39 #define IA_CSS_NUM_PARAM_CLASSES (IA_CSS_PARAM_CLASS_STATE + 1)
41 /* ISP parameter descriptor */
42 struct ia_css_isp_parameter {
43 u32 offset; /* Offset in isp_<mem>)parameters, etc. */
44 u32 size; /* Disabled if 0 */
47 /* Address/size of each parameter class in each isp memory, host memory pointers */
48 struct ia_css_isp_param_host_segments {
49 struct ia_css_host_data params[IA_CSS_NUM_PARAM_CLASSES][IA_CSS_NUM_MEMORIES];
52 /* Address/size of each parameter class in each isp memory, css memory pointers */
53 struct ia_css_isp_param_css_segments {
54 struct ia_css_data params[IA_CSS_NUM_PARAM_CLASSES][IA_CSS_NUM_MEMORIES];
57 /* Address/size of each parameter class in each isp memory, isp memory pointers */
58 struct ia_css_isp_param_isp_segments {
59 struct ia_css_isp_data params[IA_CSS_NUM_PARAM_CLASSES][IA_CSS_NUM_MEMORIES];
62 /* Memory offsets in binary info */
63 struct ia_css_isp_param_memory_offsets {
64 u32 offsets[IA_CSS_NUM_PARAM_CLASSES]; /** offset wrt hdr in bytes */
67 /* Offsets for ISP kernel parameters per isp memory.
68 * Only relevant for standard ISP binaries, not ACC or SP.
70 union ia_css_all_memory_offsets {
72 CSS_ALIGN(struct ia_css_memory_offsets *param, 8);
73 CSS_ALIGN(struct ia_css_config_memory_offsets *config, 8);
74 CSS_ALIGN(struct ia_css_state_memory_offsets *state, 8);
77 CSS_ALIGN(void *ptr, 8);
78 } array[IA_CSS_NUM_PARAM_CLASSES];
81 #endif /* _IA_CSS_ISP_PARAM_TYPES_H_ */