Lines Matching +full:int +full:- +full:a
4 * SPDX-License-Identifier: Apache-2.0
17 * Interrupt allocation flags - These flags can be used to specify
23 #define ESP_INTR_FLAG_LEVEL1 (1<<1) /* Accept a Level 1 int vector, lowest priority */
24 #define ESP_INTR_FLAG_LEVEL2 (1<<2) /* Accept a Level 2 int vector */
25 #define ESP_INTR_FLAG_LEVEL3 (1<<3) /* Accept a Level 3 int vector */
26 #define ESP_INTR_FLAG_LEVEL4 (1<<4) /* Accept a Level 4 int vector */
27 #define ESP_INTR_FLAG_LEVEL5 (1<<5) /* Accept a Level 5 int vector */
28 #define ESP_INTR_FLAG_LEVEL6 (1<<6) /* Accept a Level 6 int vector */
29 #define ESP_INTR_FLAG_NMI (1<<7) /* Accept a Level 7 int vector, highest priority */
31 #define ESP_INTR_FLAG_EDGE (1<<9) /* Edge-triggered interrupt */
59 * The esp_intr_alloc* functions can allocate an int for all *_INTR_SOURCE int sources that
62 * pass these pseudo-sources to the functions.
64 #define ETS_INTERNAL_TIMER0_INTR_SOURCE -1 /* Xtensa timer 0 interrupt source */
65 #define ETS_INTERNAL_TIMER1_INTR_SOURCE -2 /* Xtensa timer 1 interrupt source */
66 #define ETS_INTERNAL_TIMER2_INTR_SOURCE -3 /* Xtensa timer 2 interrupt source */
67 #define ETS_INTERNAL_SW0_INTR_SOURCE -4 /* Software int source 1 */
68 #define ETS_INTERNAL_SW1_INTR_SOURCE -5 /* Software int source 2 */
69 #define ETS_INTERNAL_PROFILING_INTR_SOURCE -6 /* Int source for profiling */
75 int disabled : 1;
76 int source : 8;
86 int flags : 16; /* OR of VECDESC_FLAG_* defines */
87 unsigned int cpu : 1;
88 unsigned int intno : 5;
89 int source : 8; /* Int mux flags, used when not shared */
106 * @brief Mark an interrupt as a shared interrupt
108 * This will mark a certain interrupt on the specified CPU as
112 * @param intno The number of the interrupt (0-31)
115 * the int can be left enabled while the flash cache is disabled.
117 * @return -EINVAL if cpu or intno is invalid
120 int esp_intr_mark_shared(int intno, int cpu, bool is_in_iram);
125 * This will mark a certain interrupt on the specified CPU as
128 * @param intno The number of the interrupt (0-31)
131 * @return -EINVAL if cpu or intno is invalid
134 int esp_intr_reserve(int intno, int cpu);
142 * a handle for the interrupt as well.
150 * sources, as defined in esp-xtensa-intmux.h, or one of the internal
154 * is 0, it will default to allocating a non-shared interrupt of level
155 * 1, 2 or 3. If this is ESP_INTR_FLAG_SHARED, it will allocate a shared
159 * is requested, because these types of interrupts aren't C-callable.
161 * @param ret_handle Pointer to a struct intr_handle_data_t pointer to store a handle that can
165 * @return -EINVAL if the combination of arguments is invalid.
166 * -ENODEV No free interrupt found with the specified flags
169 int esp_intr_alloc(int source,
170 int flags,
180 * This essentially does the same as esp_intr_alloc, but allows specifying a register and mask
181 * combo. For shared interrupts, the handler is only called if a read from the specified
182 * register, ANDed with the mask, returns non-zero. By passing an interrupt status register
183 * address and a fitting mask, this can be used to accelerate interrupt handling in the case
184 * a shared interrupt is triggered; by checking the interrupt statuses first, the code can
188 * sources, as defined in esp-xtensa-intmux.h, or one of the internal
192 * is 0, it will default to allocating a non-shared interrupt of level
193 * 1, 2 or 3. If this is ESP_INTR_FLAG_SHARED, it will allocate a shared
197 * @param intrstatusmask A mask. If a read of address intrstatusreg has any of the bits
201 * is requested, because these types of interrupts aren't C-callable.
203 * @param ret_handle Pointer to a struct intr_handle_data_t pointer to store a handle that can
207 * @return -EINVAL if the combination of arguments is invalid.
208 * -ENODEV No free interrupt found with the specified flags
211 int esp_intr_alloc_intrstatus(int source,
212 int flags,
235 * @return -EINVAL the handle is NULL
238 int esp_intr_free(struct intr_handle_data_t *handle);
248 int esp_intr_get_cpu(struct intr_handle_data_t *handle);
251 * @brief Get the allocated interrupt for a certain handle
257 int esp_intr_get_intno(struct intr_handle_data_t *handle);
265 * 2. When several handlers sharing a same interrupt source, interrupt status bits, which are
272 * @return -EINVAL if the combination of arguments is invalid.
275 int esp_intr_disable(struct intr_handle_data_t *handle);
285 * @return -EINVAL if the combination of arguments is invalid.
288 int esp_intr_enable(struct intr_handle_data_t *handle);
299 * @return -EINVAL if the combination of arguments is invalid.
302 int esp_intr_set_in_iram(struct intr_handle_data_t *handle, bool is_in_iram);
310 * @brief Re-enable interrupts disabled by esp_intr_noniram_disable