dri-devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Vetter <daniel@ffwll.ch>
To: Maxime Ripard <mripard@kernel.org>
Cc: Pekka Paalanen <pekka.paalanen@collabora.com>,
	David Airlie <airlied@linux.ie>,
	Daniel Vetter <daniel.vetter@ffwll.ch>,
	dri-devel@lists.freedesktop.org,
	Thomas Zimmermann <tzimmermann@suse.de>
Subject: Re: [PATCH 1/5] drm/atomic: Move the drm_atomic_state field doc inline
Date: Thu, 7 Dec 2023 22:34:06 +0100	[thread overview]
Message-ID: <ZXI6TojujZ4CJsMR@phenom.ffwll.local> (raw)
In-Reply-To: <20231204121707.3647961-1-mripard@kernel.org>

On Mon, Dec 04, 2023 at 01:17:03PM +0100, Maxime Ripard wrote:
> Some fields of drm_atomic_state have been documented in-line, but some
> were documented in the main kerneldoc block before the structure.
> 
> Since the former is the preferred option in DRM, let's move all the
> fields to an inline documentation.
> 
> Signed-off-by: Maxime Ripard <mripard@kernel.org>

Acked-by: Daniel Vetter <daniel.vetter@ffwll.ch>

> ---
>  include/drm/drm_atomic.h | 50 ++++++++++++++++++++++++++++++++--------
>  1 file changed, 40 insertions(+), 10 deletions(-)
> 
> diff --git a/include/drm/drm_atomic.h b/include/drm/drm_atomic.h
> index cf8e1220a4ac..2a08030fcd75 100644
> --- a/include/drm/drm_atomic.h
> +++ b/include/drm/drm_atomic.h
> @@ -347,24 +347,22 @@ struct __drm_private_objs_state {
>  
>  /**
>   * struct drm_atomic_state - the global state object for atomic updates
> - * @ref: count of all references to this state (will not be freed until zero)
> - * @dev: parent DRM device
> - * @async_update: hint for asynchronous plane update
> - * @planes: pointer to array of structures with per-plane data
> - * @crtcs: pointer to array of CRTC pointers
> - * @num_connector: size of the @connectors and @connector_states arrays
> - * @connectors: pointer to array of structures with per-connector data
> - * @num_private_objs: size of the @private_objs array
> - * @private_objs: pointer to array of private object pointers
> - * @acquire_ctx: acquire context for this atomic modeset state update
>   *
>   * States are added to an atomic update by calling drm_atomic_get_crtc_state(),
>   * drm_atomic_get_plane_state(), drm_atomic_get_connector_state(), or for
>   * private state structures, drm_atomic_get_private_obj_state().
>   */
>  struct drm_atomic_state {
> +	/**
> +	 * @ref:
> +	 *
> +	 * Count of all references to this update (will not be freed until zero).
> +	 */
>  	struct kref ref;
>  
> +	/**
> +	 * @dev: Parent DRM Device.
> +	 */
>  	struct drm_device *dev;
>  
>  	/**
> @@ -388,7 +386,12 @@ struct drm_atomic_state {
>  	 * flag are not allowed.
>  	 */
>  	bool legacy_cursor_update : 1;
> +
> +	/**
> +	 * @async_update: hint for asynchronous plane update
> +	 */
>  	bool async_update : 1;
> +
>  	/**
>  	 * @duplicated:
>  	 *
> @@ -398,13 +401,40 @@ struct drm_atomic_state {
>  	 * states.
>  	 */
>  	bool duplicated : 1;
> +
> +	/**
> +	 * @planes: pointer to array of structures with per-plane data
> +	 */
>  	struct __drm_planes_state *planes;
> +
> +	/**
> +	 * @crtcs: pointer to array of CRTC pointers
> +	 */
>  	struct __drm_crtcs_state *crtcs;
> +
> +	/**
> +	 * @num_connector: size of the @connectors and @connector_states arrays
> +	 */
>  	int num_connector;
> +
> +	/**
> +	 * @connectors: pointer to array of structures with per-connector data
> +	 */
>  	struct __drm_connnectors_state *connectors;
> +
> +	/**
> +	 * @num_private_objs: size of the @private_objs array
> +	 */
>  	int num_private_objs;
> +
> +	/**
> +	 * @private_objs: pointer to array of private object pointers
> +	 */
>  	struct __drm_private_objs_state *private_objs;
>  
> +	/**
> +	 * @acquire_ctx: acquire context for this atomic modeset state update
> +	 */
>  	struct drm_modeset_acquire_ctx *acquire_ctx;
>  
>  	/**
> -- 
> 2.43.0
> 

-- 
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch

      parent reply	other threads:[~2023-12-07 21:34 UTC|newest]

Thread overview: 22+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-04 12:17 [PATCH 1/5] drm/atomic: Move the drm_atomic_state field doc inline Maxime Ripard
2023-12-04 12:17 ` [PATCH 2/5] drm/atomic: Remove inexistent reference Maxime Ripard
2023-12-05 13:32   ` [2/5] " Sui Jingfeng
2023-12-07 21:40   ` [PATCH 2/5] " Daniel Vetter
2023-12-04 12:17 ` [PATCH 3/5] drm/atomic: Rework the object doc a bit Maxime Ripard
2023-12-05 13:52   ` [3/5] " Sui Jingfeng
2023-12-07 21:41   ` [PATCH 3/5] " Daniel Vetter
2023-12-04 12:17 ` [PATCH 4/5] drm/atomic: Make the drm_atomic_state documentation less ambiguous Maxime Ripard
2023-12-05  8:51   ` Pekka Paalanen
2023-12-05  9:15     ` Pekka Paalanen
2023-12-07 13:50       ` Maxime Ripard
2023-12-07 14:27     ` Maxime Ripard
2023-12-08  8:08       ` Pekka Paalanen
2023-12-08 12:25         ` Maxime Ripard
2023-12-08 13:59           ` Pekka Paalanen
2023-12-08 15:20             ` Maxime Ripard
2023-12-11  9:22               ` Pekka Paalanen
2023-12-07 21:48   ` Daniel Vetter
2023-12-04 12:17 ` [PATCH 5/5] drm/todo: Add entry to rename drm_atomic_state Maxime Ripard
2023-12-07 21:51   ` Daniel Vetter
2023-12-05 13:42 ` [1/5] drm/atomic: Move the drm_atomic_state field doc inline Sui Jingfeng
2023-12-07 21:34 ` Daniel Vetter [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=ZXI6TojujZ4CJsMR@phenom.ffwll.local \
    --to=daniel@ffwll.ch \
    --cc=airlied@linux.ie \
    --cc=daniel.vetter@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=mripard@kernel.org \
    --cc=pekka.paalanen@collabora.com \
    --cc=tzimmermann@suse.de \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox