1 /* SPDX-License-Identifier: GPL-2.0 */ 2 /* 3 * Support for Intel Camera Imaging ISP subsystem. 4 * Copyright (c) 2015, Intel Corporation. 5 */ 6 7 #ifndef __IA_CSS_MIPI_H 8 #define __IA_CSS_MIPI_H 9 10 /* @file 11 * This file contains MIPI support functionality 12 */ 13 14 #include <type_support.h> 15 #include "ia_css_err.h" 16 #include "ia_css_stream_format.h" 17 #include "ia_css_input_port.h" 18 19 /* @brief Calculate the size of a mipi frame. 20 * 21 * @param[in] width The width (in pixels) of the frame. 22 * @param[in] height The height (in lines) of the frame. 23 * @param[in] format The frame (MIPI) format. 24 * @param[in] hasSOLandEOL Whether frame (MIPI) contains (optional) SOL and EOF packets. 25 * @param[in] embedded_data_size_words Embedded data size in memory words. 26 * @param size_mem_words The mipi frame size in memory words (32B). 27 * @return The error code. 28 * 29 * Calculate the size of a mipi frame, based on the resolution and format. 30 */ 31 int 32 ia_css_mipi_frame_calculate_size(const unsigned int width, 33 const unsigned int height, 34 const enum atomisp_input_format format, 35 const bool hasSOLandEOL, 36 const unsigned int embedded_data_size_words, 37 unsigned int *size_mem_words); 38 39 #endif /* __IA_CSS_MIPI_H */ 40