GNU Linux-libre 4.14.328-gnu1
[releases.git] / drivers / staging / media / atomisp / pci / atomisp2 / css2400 / hive_isp_css_common / host / vmem_local.h
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 __VMEM_LOCAL_H_INCLUDED__
16 #define __VMEM_LOCAL_H_INCLUDED__
17
18 #include "type_support.h"
19 #include "vmem_global.h"
20
21 typedef uint16_t t_vmem_elem;
22
23 #define VMEM_ARRAY(x,s)    t_vmem_elem x[s/ISP_NWAY][ISP_NWAY]
24
25 void isp_vmem_load(
26         const isp_ID_t          ID,
27         const t_vmem_elem       *from,
28         t_vmem_elem             *to,
29         unsigned                elems); /* In t_vmem_elem */
30
31 void isp_vmem_store(
32         const isp_ID_t          ID,
33         t_vmem_elem             *to,
34         const t_vmem_elem       *from,
35         unsigned                elems); /* In t_vmem_elem */
36
37 void isp_vmem_2d_load (
38         const isp_ID_t          ID,
39         const t_vmem_elem       *from,
40         t_vmem_elem             *to,
41         unsigned                height,
42         unsigned                width,
43         unsigned                stride_to,  /* In t_vmem_elem */
44         unsigned                stride_from /* In t_vmem_elem */);
45
46 void isp_vmem_2d_store (
47         const isp_ID_t          ID,
48         t_vmem_elem             *to,
49         const t_vmem_elem       *from,
50         unsigned                height,
51         unsigned                width,
52         unsigned                stride_to,  /* In t_vmem_elem */
53         unsigned                stride_from /* In t_vmem_elem */);
54
55 #endif /* __VMEM_LOCAL_H_INCLUDED__ */