Skip to content

Commit 33e1fc0

Browse files
committed
drm/connector: add ref to drm_connector_get in iter docs
Mention that connectors need to be referenced manually if they are to be accessed after the iteration has progressed or ended. Signed-off-by: Simon Ser <[email protected]> Reviewed-by: Daniel Vetter <[email protected]> Link: https://patchwork.freedesktop.org/patch/msgid/[email protected]
1 parent 6c9bd44 commit 33e1fc0

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

include/drm/drm_connector.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1740,6 +1740,11 @@ void drm_mode_put_tile_group(struct drm_device *dev,
17401740
* drm_connector_list_iter_begin(), drm_connector_list_iter_end() and
17411741
* drm_connector_list_iter_next() respectively the convenience macro
17421742
* drm_for_each_connector_iter().
1743+
*
1744+
* Note that the return value of drm_connector_list_iter_next() is only valid
1745+
* up to the next drm_connector_list_iter_next() or
1746+
* drm_connector_list_iter_end() call. If you want to use the connector later,
1747+
* then you need to grab your own reference first using drm_connector_get().
17431748
*/
17441749
struct drm_connector_list_iter {
17451750
/* private: */

0 commit comments

Comments
 (0)