1 // SPDX-License-Identifier: GPL-2.0
2 /*
3 * Support for Intel Camera Imaging ISP subsystem.
4 * Copyright (c) 2015, Intel Corporation.
5 *
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.
9 *
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
13 * more details.
14 */
15
16 #include "ia_css_formats.host.h"
17 #include "ia_css_types.h"
18 #include "sh_css_defs.h"
19
20 /*#include "sh_css_frac.h"*/
21 #ifndef IA_CSS_NO_DEBUG
22 /* FIXME: See BZ 4427 */
23 #include "ia_css_debug.h"
24 #endif
25
26 const struct ia_css_formats_config default_formats_config = {
27 1
28 };
29
30 void
ia_css_formats_encode(struct sh_css_isp_formats_params * to,const struct ia_css_formats_config * from,unsigned int size)31 ia_css_formats_encode(
32 struct sh_css_isp_formats_params *to,
33 const struct ia_css_formats_config *from,
34 unsigned int size)
35 {
36 (void)size;
37 to->video_full_range_flag = from->video_full_range_flag;
38 }
39
40 #ifndef IA_CSS_NO_DEBUG
41 /* FIXME: See BZ 4427 */
42 void
ia_css_formats_dump(const struct sh_css_isp_formats_params * formats,unsigned int level)43 ia_css_formats_dump(
44 const struct sh_css_isp_formats_params *formats,
45 unsigned int level)
46 {
47 if (!formats) return;
48 ia_css_debug_dtrace(level, "\t%-32s = %d\n",
49 "video_full_range_flag", formats->video_full_range_flag);
50 }
51 #endif
52
53 #ifndef IA_CSS_NO_DEBUG
54 /* FIXME: See BZ 4427 */
55 void
ia_css_formats_debug_dtrace(const struct ia_css_formats_config * config,unsigned int level)56 ia_css_formats_debug_dtrace(
57 const struct ia_css_formats_config *config,
58 unsigned int level)
59 {
60 ia_css_debug_dtrace(level,
61 "config.video_full_range_flag=%d\n",
62 config->video_full_range_flag);
63 }
64 #endif
65