2 * Copyright 2015 Advanced Micro Devices, Inc.
4 * Permission is hereby granted, free of charge, to any person obtaining a
5 * copy of this software and associated documentation files (the "Software"),
6 * to deal in the Software without restriction, including without limitation
7 * the rights to use, copy, modify, merge, publish, distribute, sublicense,
8 * and/or sell copies of the Software, and to permit persons to whom the
9 * Software is furnished to do so, subject to the following conditions:
11 * The above copyright notice and this permission notice shall be included in
12 * all copies or substantial portions of the Software.
14 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
15 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
16 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
17 * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
18 * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
19 * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
20 * OTHER DEALINGS IN THE SOFTWARE.
26 #include "dm_services_types.h"
30 #include "amdgpu_dm.h"
31 #include "amdgpu_dm_irq.h"
36 * DM provides another layer of IRQ management on top of what the base driver
37 * already provides. This is something that could be cleaned up, and is a
40 * The base driver provides IRQ source registration with DRM, handler
41 * registration into the base driver's IRQ table, and a handler callback
42 * amdgpu_irq_handler(), with which DRM calls on interrupts. This generic
43 * handler looks up the IRQ table, and calls the respective
44 * &amdgpu_irq_src_funcs.process hookups.
46 * What DM provides on top are two IRQ tables specifically for top-half and
47 * bottom-half IRQ handling, with the bottom-half implementing workqueues:
49 * - &amdgpu_display_manager.irq_handler_list_high_tab
50 * - &amdgpu_display_manager.irq_handler_list_low_tab
52 * They override the base driver's IRQ table, and the effect can be seen
53 * in the hooks that DM provides for &amdgpu_irq_src_funcs.process. They
54 * are all set to the DM generic handler amdgpu_dm_irq_handler(), which looks up
55 * DM's IRQ tables. However, in order for base driver to recognize this hook, DM
56 * still needs to register the IRQ with the base driver. See
57 * dce110_register_irq_handlers() and dcn10_register_irq_handlers().
59 * To expose DC's hardware interrupt toggle to the base driver, DM implements
60 * &amdgpu_irq_src_funcs.set hooks. Base driver calls it through
61 * amdgpu_irq_update() to enable or disable the interrupt.
64 /******************************************************************************
65 * Private declarations.
66 *****************************************************************************/
69 * struct amdgpu_dm_irq_handler_data - Data for DM interrupt handlers.
71 * @list: Linked list entry referencing the next/previous handler
72 * @handler: Handler function
73 * @handler_arg: Argument passed to the handler when triggered
74 * @dm: DM which this handler belongs to
75 * @irq_source: DC interrupt source that this handler is registered for
77 struct amdgpu_dm_irq_handler_data {
78 struct list_head list;
79 interrupt_handler handler;
82 struct amdgpu_display_manager *dm;
83 /* DAL irq source which registered for this interrupt. */
84 enum dc_irq_source irq_source;
87 #define DM_IRQ_TABLE_LOCK(adev, flags) \
88 spin_lock_irqsave(&adev->dm.irq_handler_list_table_lock, flags)
90 #define DM_IRQ_TABLE_UNLOCK(adev, flags) \
91 spin_unlock_irqrestore(&adev->dm.irq_handler_list_table_lock, flags)
93 /******************************************************************************
95 *****************************************************************************/
97 static void init_handler_common_data(struct amdgpu_dm_irq_handler_data *hcd,
100 struct amdgpu_display_manager *dm)
103 hcd->handler_arg = args;
108 * dm_irq_work_func() - Handle an IRQ outside of the interrupt handler proper.
112 static void dm_irq_work_func(struct work_struct *work)
114 struct irq_list_head *irq_list_head =
115 container_of(work, struct irq_list_head, work);
116 struct list_head *handler_list = &irq_list_head->head;
117 struct amdgpu_dm_irq_handler_data *handler_data;
119 list_for_each_entry(handler_data, handler_list, list) {
120 DRM_DEBUG_KMS("DM_IRQ: work_func: for dal_src=%d\n",
121 handler_data->irq_source);
123 DRM_DEBUG_KMS("DM_IRQ: schedule_work: for dal_src=%d\n",
124 handler_data->irq_source);
126 handler_data->handler(handler_data->handler_arg);
129 /* Call a DAL subcomponent which registered for interrupt notification
130 * at INTERRUPT_LOW_IRQ_CONTEXT.
131 * (The most common use is HPD interrupt) */
135 * Remove a handler and return a pointer to handler list from which the
136 * handler was removed.
138 static struct list_head *remove_irq_handler(struct amdgpu_device *adev,
140 const struct dc_interrupt_params *int_params)
142 struct list_head *hnd_list;
143 struct list_head *entry, *tmp;
144 struct amdgpu_dm_irq_handler_data *handler;
145 unsigned long irq_table_flags;
146 bool handler_removed = false;
147 enum dc_irq_source irq_source;
149 DM_IRQ_TABLE_LOCK(adev, irq_table_flags);
151 irq_source = int_params->irq_source;
153 switch (int_params->int_context) {
154 case INTERRUPT_HIGH_IRQ_CONTEXT:
155 hnd_list = &adev->dm.irq_handler_list_high_tab[irq_source];
157 case INTERRUPT_LOW_IRQ_CONTEXT:
159 hnd_list = &adev->dm.irq_handler_list_low_tab[irq_source].head;
163 list_for_each_safe(entry, tmp, hnd_list) {
165 handler = list_entry(entry, struct amdgpu_dm_irq_handler_data,
171 if (ih == handler->handler) {
172 /* Found our handler. Remove it from the list. */
173 list_del(&handler->list);
174 handler_removed = true;
179 DM_IRQ_TABLE_UNLOCK(adev, irq_table_flags);
181 if (handler_removed == false) {
182 /* Not necessarily an error - caller may not
183 * know the context. */
190 "DM_IRQ: removed irq handler: %p for: dal_src=%d, irq context=%d\n",
191 ih, int_params->irq_source, int_params->int_context);
197 validate_irq_registration_params(struct dc_interrupt_params *int_params,
200 if (NULL == int_params || NULL == ih) {
201 DRM_ERROR("DM_IRQ: invalid input!\n");
205 if (int_params->int_context >= INTERRUPT_CONTEXT_NUMBER) {
206 DRM_ERROR("DM_IRQ: invalid context: %d!\n",
207 int_params->int_context);
211 if (!DAL_VALID_IRQ_SRC_NUM(int_params->irq_source)) {
212 DRM_ERROR("DM_IRQ: invalid irq_source: %d!\n",
213 int_params->irq_source);
220 static bool validate_irq_unregistration_params(enum dc_irq_source irq_source,
221 irq_handler_idx handler_idx)
223 if (DAL_INVALID_IRQ_HANDLER_IDX == handler_idx) {
224 DRM_ERROR("DM_IRQ: invalid handler_idx==NULL!\n");
228 if (!DAL_VALID_IRQ_SRC_NUM(irq_source)) {
229 DRM_ERROR("DM_IRQ: invalid irq_source:%d!\n", irq_source);
235 /******************************************************************************
238 * Note: caller is responsible for input validation.
239 *****************************************************************************/
242 * amdgpu_dm_irq_register_interrupt() - Register a handler within DM.
243 * @adev: The base driver device containing the DM device.
244 * @int_params: Interrupt parameters containing the source, and handler context
245 * @ih: Function pointer to the interrupt handler to register
246 * @handler_args: Arguments passed to the handler when the interrupt occurs
248 * Register an interrupt handler for the given IRQ source, under the given
249 * context. The context can either be high or low. High context handlers are
250 * executed directly within ISR context, while low context is executed within a
251 * workqueue, thereby allowing operations that sleep.
253 * Registered handlers are called in a FIFO manner, i.e. the most recently
254 * registered handler will be called first.
256 * Return: Handler data &struct amdgpu_dm_irq_handler_data containing the IRQ
257 * source, handler function, and args
259 void *amdgpu_dm_irq_register_interrupt(struct amdgpu_device *adev,
260 struct dc_interrupt_params *int_params,
264 struct list_head *hnd_list;
265 struct amdgpu_dm_irq_handler_data *handler_data;
266 unsigned long irq_table_flags;
267 enum dc_irq_source irq_source;
269 if (false == validate_irq_registration_params(int_params, ih))
270 return DAL_INVALID_IRQ_HANDLER_IDX;
272 handler_data = kzalloc(sizeof(*handler_data), GFP_KERNEL);
274 DRM_ERROR("DM_IRQ: failed to allocate irq handler!\n");
275 return DAL_INVALID_IRQ_HANDLER_IDX;
278 init_handler_common_data(handler_data, ih, handler_args, &adev->dm);
280 irq_source = int_params->irq_source;
282 handler_data->irq_source = irq_source;
284 /* Lock the list, add the handler. */
285 DM_IRQ_TABLE_LOCK(adev, irq_table_flags);
287 switch (int_params->int_context) {
288 case INTERRUPT_HIGH_IRQ_CONTEXT:
289 hnd_list = &adev->dm.irq_handler_list_high_tab[irq_source];
291 case INTERRUPT_LOW_IRQ_CONTEXT:
293 hnd_list = &adev->dm.irq_handler_list_low_tab[irq_source].head;
297 list_add_tail(&handler_data->list, hnd_list);
299 DM_IRQ_TABLE_UNLOCK(adev, irq_table_flags);
301 /* This pointer will be stored by code which requested interrupt
303 * The same pointer will be needed in order to unregister the
307 "DM_IRQ: added irq handler: %p for: dal_src=%d, irq context=%d\n",
310 int_params->int_context);
316 * amdgpu_dm_irq_unregister_interrupt() - Remove a handler from the DM IRQ table
317 * @adev: The base driver device containing the DM device
318 * @irq_source: IRQ source to remove the given handler from
319 * @ih: Function pointer to the interrupt handler to unregister
321 * Go through both low and high context IRQ tables, and find the given handler
322 * for the given irq source. If found, remove it. Otherwise, do nothing.
324 void amdgpu_dm_irq_unregister_interrupt(struct amdgpu_device *adev,
325 enum dc_irq_source irq_source,
328 struct list_head *handler_list;
329 struct dc_interrupt_params int_params;
332 if (false == validate_irq_unregistration_params(irq_source, ih))
335 memset(&int_params, 0, sizeof(int_params));
337 int_params.irq_source = irq_source;
339 for (i = 0; i < INTERRUPT_CONTEXT_NUMBER; i++) {
341 int_params.int_context = i;
343 handler_list = remove_irq_handler(adev, ih, &int_params);
345 if (handler_list != NULL)
349 if (handler_list == NULL) {
350 /* If we got here, it means we searched all irq contexts
351 * for this irq source, but the handler was not found. */
353 "DM_IRQ: failed to find irq handler:%p for irq_source:%d!\n",
359 * amdgpu_dm_irq_init() - Initialize DM IRQ management
360 * @adev: The base driver device containing the DM device
362 * Initialize DM's high and low context IRQ tables.
364 * The N by M table contains N IRQ sources, with M
365 * &struct amdgpu_dm_irq_handler_data hooked together in a linked list. The
366 * list_heads are initialized here. When an interrupt n is triggered, all m
367 * handlers are called in sequence, FIFO according to registration order.
369 * The low context table requires special steps to initialize, since handlers
370 * will be deferred to a workqueue. See &struct irq_list_head.
372 int amdgpu_dm_irq_init(struct amdgpu_device *adev)
375 struct irq_list_head *lh;
377 DRM_DEBUG_KMS("DM_IRQ\n");
379 spin_lock_init(&adev->dm.irq_handler_list_table_lock);
381 for (src = 0; src < DAL_IRQ_SOURCES_NUMBER; src++) {
382 /* low context handler list init */
383 lh = &adev->dm.irq_handler_list_low_tab[src];
384 INIT_LIST_HEAD(&lh->head);
385 INIT_WORK(&lh->work, dm_irq_work_func);
387 /* high context handler init */
388 INIT_LIST_HEAD(&adev->dm.irq_handler_list_high_tab[src]);
395 * amdgpu_dm_irq_fini() - Tear down DM IRQ management
396 * @adev: The base driver device containing the DM device
398 * Flush all work within the low context IRQ table.
400 void amdgpu_dm_irq_fini(struct amdgpu_device *adev)
403 struct irq_list_head *lh;
404 unsigned long irq_table_flags;
405 DRM_DEBUG_KMS("DM_IRQ: releasing resources.\n");
406 for (src = 0; src < DAL_IRQ_SOURCES_NUMBER; src++) {
407 DM_IRQ_TABLE_LOCK(adev, irq_table_flags);
408 /* The handler was removed from the table,
409 * it means it is safe to flush all the 'work'
410 * (because no code can schedule a new one). */
411 lh = &adev->dm.irq_handler_list_low_tab[src];
412 DM_IRQ_TABLE_UNLOCK(adev, irq_table_flags);
413 flush_work(&lh->work);
417 int amdgpu_dm_irq_suspend(struct amdgpu_device *adev)
420 struct list_head *hnd_list_h;
421 struct list_head *hnd_list_l;
422 unsigned long irq_table_flags;
424 DM_IRQ_TABLE_LOCK(adev, irq_table_flags);
426 DRM_DEBUG_KMS("DM_IRQ: suspend\n");
429 * Disable HW interrupt for HPD and HPDRX only since FLIP and VBLANK
430 * will be disabled from manage_dm_interrupts on disable CRTC.
432 for (src = DC_IRQ_SOURCE_HPD1; src <= DC_IRQ_SOURCE_HPD6RX; src++) {
433 hnd_list_l = &adev->dm.irq_handler_list_low_tab[src].head;
434 hnd_list_h = &adev->dm.irq_handler_list_high_tab[src];
435 if (!list_empty(hnd_list_l) || !list_empty(hnd_list_h))
436 dc_interrupt_set(adev->dm.dc, src, false);
438 DM_IRQ_TABLE_UNLOCK(adev, irq_table_flags);
439 flush_work(&adev->dm.irq_handler_list_low_tab[src].work);
441 DM_IRQ_TABLE_LOCK(adev, irq_table_flags);
444 DM_IRQ_TABLE_UNLOCK(adev, irq_table_flags);
448 int amdgpu_dm_irq_resume_early(struct amdgpu_device *adev)
451 struct list_head *hnd_list_h, *hnd_list_l;
452 unsigned long irq_table_flags;
454 DM_IRQ_TABLE_LOCK(adev, irq_table_flags);
456 DRM_DEBUG_KMS("DM_IRQ: early resume\n");
458 /* re-enable short pulse interrupts HW interrupt */
459 for (src = DC_IRQ_SOURCE_HPD1RX; src <= DC_IRQ_SOURCE_HPD6RX; src++) {
460 hnd_list_l = &adev->dm.irq_handler_list_low_tab[src].head;
461 hnd_list_h = &adev->dm.irq_handler_list_high_tab[src];
462 if (!list_empty(hnd_list_l) || !list_empty(hnd_list_h))
463 dc_interrupt_set(adev->dm.dc, src, true);
466 DM_IRQ_TABLE_UNLOCK(adev, irq_table_flags);
471 int amdgpu_dm_irq_resume_late(struct amdgpu_device *adev)
474 struct list_head *hnd_list_h, *hnd_list_l;
475 unsigned long irq_table_flags;
477 DM_IRQ_TABLE_LOCK(adev, irq_table_flags);
479 DRM_DEBUG_KMS("DM_IRQ: resume\n");
482 * Renable HW interrupt for HPD and only since FLIP and VBLANK
483 * will be enabled from manage_dm_interrupts on enable CRTC.
485 for (src = DC_IRQ_SOURCE_HPD1; src <= DC_IRQ_SOURCE_HPD6; src++) {
486 hnd_list_l = &adev->dm.irq_handler_list_low_tab[src].head;
487 hnd_list_h = &adev->dm.irq_handler_list_high_tab[src];
488 if (!list_empty(hnd_list_l) || !list_empty(hnd_list_h))
489 dc_interrupt_set(adev->dm.dc, src, true);
492 DM_IRQ_TABLE_UNLOCK(adev, irq_table_flags);
497 * amdgpu_dm_irq_schedule_work - schedule all work items registered for the
500 static void amdgpu_dm_irq_schedule_work(struct amdgpu_device *adev,
501 enum dc_irq_source irq_source)
503 unsigned long irq_table_flags;
504 struct work_struct *work = NULL;
506 DM_IRQ_TABLE_LOCK(adev, irq_table_flags);
508 if (!list_empty(&adev->dm.irq_handler_list_low_tab[irq_source].head))
509 work = &adev->dm.irq_handler_list_low_tab[irq_source].work;
511 DM_IRQ_TABLE_UNLOCK(adev, irq_table_flags);
514 if (!schedule_work(work))
515 DRM_INFO("amdgpu_dm_irq_schedule_work FAILED src %d\n",
522 * amdgpu_dm_irq_immediate_work
523 * Callback high irq work immediately, don't send to work queue
525 static void amdgpu_dm_irq_immediate_work(struct amdgpu_device *adev,
526 enum dc_irq_source irq_source)
528 struct amdgpu_dm_irq_handler_data *handler_data;
529 unsigned long irq_table_flags;
531 DM_IRQ_TABLE_LOCK(adev, irq_table_flags);
533 list_for_each_entry(handler_data,
534 &adev->dm.irq_handler_list_high_tab[irq_source],
536 /* Call a subcomponent which registered for immediate
537 * interrupt notification */
538 handler_data->handler(handler_data->handler_arg);
541 DM_IRQ_TABLE_UNLOCK(adev, irq_table_flags);
545 * amdgpu_dm_irq_handler - Generic DM IRQ handler
546 * @adev: amdgpu base driver device containing the DM device
548 * @entry: Data about the triggered interrupt
550 * Calls all registered high irq work immediately, and schedules work for low
551 * irq. The DM IRQ table is used to find the corresponding handlers.
553 static int amdgpu_dm_irq_handler(struct amdgpu_device *adev,
554 struct amdgpu_irq_src *source,
555 struct amdgpu_iv_entry *entry)
558 enum dc_irq_source src =
559 dc_interrupt_to_irq_source(
564 dc_interrupt_ack(adev->dm.dc, src);
566 /* Call high irq work immediately */
567 amdgpu_dm_irq_immediate_work(adev, src);
568 /*Schedule low_irq work */
569 amdgpu_dm_irq_schedule_work(adev, src);
574 static enum dc_irq_source amdgpu_dm_hpd_to_dal_irq_source(unsigned type)
578 return DC_IRQ_SOURCE_HPD1;
580 return DC_IRQ_SOURCE_HPD2;
582 return DC_IRQ_SOURCE_HPD3;
584 return DC_IRQ_SOURCE_HPD4;
586 return DC_IRQ_SOURCE_HPD5;
588 return DC_IRQ_SOURCE_HPD6;
590 return DC_IRQ_SOURCE_INVALID;
594 static int amdgpu_dm_set_hpd_irq_state(struct amdgpu_device *adev,
595 struct amdgpu_irq_src *source,
597 enum amdgpu_interrupt_state state)
599 enum dc_irq_source src = amdgpu_dm_hpd_to_dal_irq_source(type);
600 bool st = (state == AMDGPU_IRQ_STATE_ENABLE);
602 dc_interrupt_set(adev->dm.dc, src, st);
606 static inline int dm_irq_state(struct amdgpu_device *adev,
607 struct amdgpu_irq_src *source,
609 enum amdgpu_interrupt_state state,
610 const enum irq_type dal_irq_type,
614 enum dc_irq_source irq_source;
616 struct amdgpu_crtc *acrtc = adev->mode_info.crtcs[crtc_id];
620 "%s: crtc is NULL at id :%d\n",
626 if (acrtc->otg_inst == -1)
629 irq_source = dal_irq_type + acrtc->otg_inst;
631 st = (state == AMDGPU_IRQ_STATE_ENABLE);
633 dc_interrupt_set(adev->dm.dc, irq_source, st);
637 static int amdgpu_dm_set_pflip_irq_state(struct amdgpu_device *adev,
638 struct amdgpu_irq_src *source,
640 enum amdgpu_interrupt_state state)
651 static int amdgpu_dm_set_crtc_irq_state(struct amdgpu_device *adev,
652 struct amdgpu_irq_src *source,
654 enum amdgpu_interrupt_state state)
665 static int amdgpu_dm_set_vupdate_irq_state(struct amdgpu_device *adev,
666 struct amdgpu_irq_src *source,
667 unsigned int crtc_id,
668 enum amdgpu_interrupt_state state)
679 static const struct amdgpu_irq_src_funcs dm_crtc_irq_funcs = {
680 .set = amdgpu_dm_set_crtc_irq_state,
681 .process = amdgpu_dm_irq_handler,
684 static const struct amdgpu_irq_src_funcs dm_vupdate_irq_funcs = {
685 .set = amdgpu_dm_set_vupdate_irq_state,
686 .process = amdgpu_dm_irq_handler,
689 static const struct amdgpu_irq_src_funcs dm_pageflip_irq_funcs = {
690 .set = amdgpu_dm_set_pflip_irq_state,
691 .process = amdgpu_dm_irq_handler,
694 static const struct amdgpu_irq_src_funcs dm_hpd_irq_funcs = {
695 .set = amdgpu_dm_set_hpd_irq_state,
696 .process = amdgpu_dm_irq_handler,
699 void amdgpu_dm_set_irq_funcs(struct amdgpu_device *adev)
702 adev->crtc_irq.num_types = adev->mode_info.num_crtc;
703 adev->crtc_irq.funcs = &dm_crtc_irq_funcs;
705 adev->vupdate_irq.num_types = adev->mode_info.num_crtc;
706 adev->vupdate_irq.funcs = &dm_vupdate_irq_funcs;
708 adev->pageflip_irq.num_types = adev->mode_info.num_crtc;
709 adev->pageflip_irq.funcs = &dm_pageflip_irq_funcs;
711 adev->hpd_irq.num_types = adev->mode_info.num_hpd;
712 adev->hpd_irq.funcs = &dm_hpd_irq_funcs;
716 * amdgpu_dm_hpd_init - hpd setup callback.
718 * @adev: amdgpu_device pointer
720 * Setup the hpd pins used by the card (evergreen+).
721 * Enable the pin, set the polarity, and enable the hpd interrupts.
723 void amdgpu_dm_hpd_init(struct amdgpu_device *adev)
725 struct drm_device *dev = adev_to_drm(adev);
726 struct drm_connector *connector;
727 struct drm_connector_list_iter iter;
729 drm_connector_list_iter_begin(dev, &iter);
730 drm_for_each_connector_iter(connector, &iter) {
731 struct amdgpu_dm_connector *amdgpu_dm_connector =
732 to_amdgpu_dm_connector(connector);
734 const struct dc_link *dc_link = amdgpu_dm_connector->dc_link;
736 if (DC_IRQ_SOURCE_INVALID != dc_link->irq_source_hpd) {
737 dc_interrupt_set(adev->dm.dc,
738 dc_link->irq_source_hpd,
742 if (DC_IRQ_SOURCE_INVALID != dc_link->irq_source_hpd_rx) {
743 dc_interrupt_set(adev->dm.dc,
744 dc_link->irq_source_hpd_rx,
748 drm_connector_list_iter_end(&iter);
752 * amdgpu_dm_hpd_fini - hpd tear down callback.
754 * @adev: amdgpu_device pointer
756 * Tear down the hpd pins used by the card (evergreen+).
757 * Disable the hpd interrupts.
759 void amdgpu_dm_hpd_fini(struct amdgpu_device *adev)
761 struct drm_device *dev = adev_to_drm(adev);
762 struct drm_connector *connector;
763 struct drm_connector_list_iter iter;
765 drm_connector_list_iter_begin(dev, &iter);
766 drm_for_each_connector_iter(connector, &iter) {
767 struct amdgpu_dm_connector *amdgpu_dm_connector =
768 to_amdgpu_dm_connector(connector);
769 const struct dc_link *dc_link = amdgpu_dm_connector->dc_link;
771 dc_interrupt_set(adev->dm.dc, dc_link->irq_source_hpd, false);
773 if (DC_IRQ_SOURCE_INVALID != dc_link->irq_source_hpd_rx) {
774 dc_interrupt_set(adev->dm.dc,
775 dc_link->irq_source_hpd_rx,
779 drm_connector_list_iter_end(&iter);