3 * Support for Intel Camera Imaging ISP subsystem.
4 * Copyright (c) 2015, Intel Corporation.
6 * This program is free software; you can redistribute it and/or modify it
7 * under the terms and conditions of the GNU General Public License,
8 * version 2, as published by the Free Software Foundation.
10 * This program is distributed in the hope it will be useful, but WITHOUT
11 * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
12 * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
17 Support for Intel Camera Imaging ISP subsystem.
18 Copyright (c) 2010 - 2015, Intel Corporation.
20 This program is free software; you can redistribute it and/or modify it
21 under the terms and conditions of the GNU General Public License,
22 version 2, as published by the Free Software Foundation.
24 This program is distributed in the hope it will be useful, but WITHOUT
25 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
26 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
31 #ifndef _IA_CSS_ISP_PARAM_TYPES_H_
32 #define _IA_CSS_ISP_PARAM_TYPES_H_
34 #include "ia_css_types.h"
35 #include <platform_support.h>
36 #include <system_global.h>
39 #define IA_CSS_ISP_DMEM IA_CSS_ISP_DMEM0
40 #define IA_CSS_ISP_VMEM IA_CSS_ISP_VMEM0
42 /* The driver depends on this, to be removed later. */
43 #define IA_CSS_NUM_ISP_MEMORIES IA_CSS_NUM_MEMORIES
45 /* Explicit member numbering to avoid fish type checker bug */
46 enum ia_css_param_class
{
47 IA_CSS_PARAM_CLASS_PARAM
= 0, /* Late binding parameters, like 3A */
48 IA_CSS_PARAM_CLASS_CONFIG
= 1, /* Pipe config time parameters, like resolution */
49 IA_CSS_PARAM_CLASS_STATE
= 2, /* State parameters, like tnr buffer index */
50 #if 0 /* Not yet implemented */
51 IA_CSS_PARAM_CLASS_FRAME
= 3, /* Frame time parameters, like output buffer */
54 #define IA_CSS_NUM_PARAM_CLASSES (IA_CSS_PARAM_CLASS_STATE + 1)
56 /* ISP parameter descriptor */
57 struct ia_css_isp_parameter
{
58 uint32_t offset
; /* Offset in isp_<mem>)parameters, etc. */
59 uint32_t size
; /* Disabled if 0 */
63 /* Address/size of each parameter class in each isp memory, host memory pointers */
64 struct ia_css_isp_param_host_segments
{
65 struct ia_css_host_data params
[IA_CSS_NUM_PARAM_CLASSES
][IA_CSS_NUM_MEMORIES
];
68 /* Address/size of each parameter class in each isp memory, css memory pointers */
69 struct ia_css_isp_param_css_segments
{
70 struct ia_css_data params
[IA_CSS_NUM_PARAM_CLASSES
][IA_CSS_NUM_MEMORIES
];
73 /* Address/size of each parameter class in each isp memory, isp memory pointers */
74 struct ia_css_isp_param_isp_segments
{
75 struct ia_css_isp_data params
[IA_CSS_NUM_PARAM_CLASSES
][IA_CSS_NUM_MEMORIES
];
78 /* Memory offsets in binary info */
79 struct ia_css_isp_param_memory_offsets
{
80 uint32_t offsets
[IA_CSS_NUM_PARAM_CLASSES
]; /** offset wrt hdr in bytes */
83 /* Offsets for ISP kernel parameters per isp memory.
84 * Only relevant for standard ISP binaries, not ACC or SP.
86 union ia_css_all_memory_offsets
{
88 CSS_ALIGN(struct ia_css_memory_offsets
*param
, 8);
89 CSS_ALIGN(struct ia_css_config_memory_offsets
*config
, 8);
90 CSS_ALIGN(struct ia_css_state_memory_offsets
*state
, 8);
93 CSS_ALIGN(void *ptr
, 8);
94 } array
[IA_CSS_NUM_PARAM_CLASSES
];
97 #define IA_CSS_DEFAULT_ISP_MEM_PARAMS \
100 #define IA_CSS_DEFAULT_ISP_CSS_PARAMS \
103 #define IA_CSS_DEFAULT_ISP_ISP_PARAMS \
106 #endif /* _IA_CSS_ISP_PARAM_TYPES_H_ */