All of lore.kernel.org
 help / color / mirror / Atom feed
From: Niranjana Vishwanathapura <niranjana.vishwanathapura@intel.com>
To: Andi Shyti <andi.shyti@linux.intel.com>
Cc: intel-xe@lists.freedesktop.org
Subject: Re: [Intel-xe] [PATCH v2 3/3] drm/xe: Avoid any races around ccs_mode update
Date: Fri, 1 Dec 2023 18:37:38 -0800	[thread overview]
Message-ID: <ZWqYckl36d1ftJDi@nvishwa1-DESK> (raw)
In-Reply-To: <ZWpJKjCWA1Y0yEH7@ashyti-mobl2.lan>

On Fri, Dec 01, 2023 at 09:59:22PM +0100, Andi Shyti wrote:
>Hi Niranjana,
>
>...
>
>> +	/** @clients: drm clients info */
>> +	struct {
>> +		/** @lock: Protects drm clients info */
>> +		spinlock_t lock;
>
>is this a refcount at the end of the day?
>

It is not a refcount in the sense that there is nothing to
release/free once count reaches 0.
It is just a mechanism to not allow ccs_mode changes if
there are any active drm clients, to keep things simple.
Note that there is an EU debugger RFC series which uses
a xarray of all drm clients. Once that lands, we could
just check if that array has any elements in them instead
of maintaining a separate count.

Niranjana

>Andi

  reply	other threads:[~2023-12-02  2:37 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-11-29  2:57 [Intel-xe] [PATCH v2 0/3] drm/xe: Enable fixed CCS mode Niranjana Vishwanathapura
2023-11-29  2:57 ` [Intel-xe] [PATCH v2 1/3] drm/xe: Enable Fixed CCS mode setting Niranjana Vishwanathapura
2023-12-01 20:52   ` Andi Shyti
2023-12-02  6:05     ` Niranjana Vishwanathapura
2023-11-29  2:57 ` [Intel-xe] [PATCH v2 2/3] drm/xe: Allow userspace to configure CCS mode Niranjana Vishwanathapura
2023-12-01 20:57   ` Andi Shyti
2023-12-02  5:48     ` Niranjana Vishwanathapura
2023-11-29  2:57 ` [Intel-xe] [PATCH v2 3/3] drm/xe: Avoid any races around ccs_mode update Niranjana Vishwanathapura
2023-12-01 20:59   ` Andi Shyti
2023-12-02  2:37     ` Niranjana Vishwanathapura [this message]
2024-09-04 10:28   ` Simona Vetter
2023-11-29  4:50 ` [Intel-xe] ✓ CI.Patch_applied: success for drm/xe: Enable fixed CCS mode Patchwork
2023-11-29  4:51 ` [Intel-xe] ✗ CI.checkpatch: warning " Patchwork
2023-11-29  4:52 ` [Intel-xe] ✓ CI.KUnit: success " Patchwork
2023-11-29  4:59 ` [Intel-xe] ✓ CI.Build: " Patchwork
2023-11-29  4:59 ` [Intel-xe] ✓ CI.Hooks: " Patchwork
2023-11-29  5:01 ` [Intel-xe] ✓ CI.checksparse: " Patchwork
2023-11-29  5:34 ` [Intel-xe] ✓ CI.BAT: " Patchwork

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=ZWqYckl36d1ftJDi@nvishwa1-DESK \
    --to=niranjana.vishwanathapura@intel.com \
    --cc=andi.shyti@linux.intel.com \
    --cc=intel-xe@lists.freedesktop.org \
    /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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.