1 /* 2 * 3 * SPDX-License-Identifier: GPL-2.0 4 * 5 * Copyright (C) 2011-2018 ARM or its affiliates 6 * 7 * This program is free software; you can redistribute it and/or modify 8 * it under the terms of the GNU General Public License as published by 9 * the Free Software Foundation; version 2. 10 * This program is distributed in the hope that it will be useful, but 11 * WITHOUT ANY WARRANTY; without even the implied warranty of MERCHANTABILITY 12 * or FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License 13 * for more details. 14 * You should have received a copy of the GNU General Public License along 15 * with this program; if not, write to the Free Software Foundation, Inc., 16 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301, USA. 17 * 18 */ 19 20 #if !defined( __FSM_UTILS_H__ ) 21 #define __FSM_UTILS_H__ 22 23 typedef struct _fsm_irq_mask_t_ { 24 uint32_t irq_mask; 25 uint32_t repeat_irq_mask; 26 } fsm_irq_mask_t; 27 28 #ifndef ARR_SIZE 29 #define ARR_SIZE( x ) ( sizeof( x ) / sizeof( x[0] ) ) 30 #endif 31 32 uint32_t acamera_fsm_util_is_irq_event_ignored( fsm_irq_mask_t *p_mask, uint8_t irq_event ); 33 34 uint32_t acamera_fsm_util_get_cur_frame_id( fsm_common_t *p_fsm ); 35 36 #endif /* __FSM_UTILS_H__ */ 37