1 /* SPDX-License-Identifier: GPL-2.0 */ 2 /* 3 * Support for Intel Camera Imaging ISP subsystem. 4 * Copyright (c) 2010 - 2015, Intel Corporation. 5 */ 6 7 #ifndef __IA_CSS_QUEUE_COMM_H 8 #define __IA_CSS_QUEUE_COMM_H 9 10 #include "type_support.h" 11 #include "ia_css_circbuf.h" 12 /***************************************************************************** 13 * Queue Public Data Structures 14 *****************************************************************************/ 15 16 /* Queue location specifier */ 17 /* Avoiding enums to save space */ 18 #define IA_CSS_QUEUE_LOC_HOST 0 19 #define IA_CSS_QUEUE_LOC_SP 1 20 #define IA_CSS_QUEUE_LOC_ISP 2 21 22 /* Queue type specifier */ 23 /* Avoiding enums to save space */ 24 #define IA_CSS_QUEUE_TYPE_LOCAL 0 25 #define IA_CSS_QUEUE_TYPE_REMOTE 1 26 27 /* for DDR Allocated queues, 28 allocate minimum these many elements. 29 DDR->SP' DMEM DMA transfer needs 32byte aligned address. 30 Since each element size is 4 bytes, 8 elements need to be 31 DMAed to access single element.*/ 32 #define IA_CSS_MIN_ELEM_COUNT 8 33 #define IA_CSS_DMA_XFER_MASK (IA_CSS_MIN_ELEM_COUNT - 1) 34 35 /* Remote Queue object descriptor */ 36 struct ia_css_queue_remote { 37 u32 cb_desc_addr; /*Circbuf desc address for remote queues*/ 38 u32 cb_elems_addr; /*Circbuf elements addr for remote queue*/ 39 u8 location; /* Cell location for queue */ 40 u8 proc_id; /* Processor id for queue access */ 41 }; 42 43 typedef struct ia_css_queue_remote ia_css_queue_remote_t; 44 45 #endif /* __IA_CSS_QUEUE_COMM_H */ 46