Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Aravind Iddamsetty <aravind.iddamsetty@linux.intel.com>
To: "Dixit, Ashutosh" <ashutosh.dixit@intel.com>,
	Rodrigo Vivi <rodrigo.vivi@intel.com>
Cc: intel-xe@lists.freedesktop.org
Subject: Re: [Intel-xe] [PATCH 2/3] drm/xe: Use spinlock in forcewake instead of mutex
Date: Thu, 31 Aug 2023 09:43:57 +0530	[thread overview]
Message-ID: <a805ff93-2a30-7f5a-de95-fdc2eea23027@linux.intel.com> (raw)
In-Reply-To: <87bkeo18df.wl-ashutosh.dixit@intel.com>

[-- Attachment #1: Type: text/plain, Size: 1464 bytes --]


On 31/08/23 03:49, Dixit, Ashutosh wrote:

> On Wed, 30 Aug 2023 13:56:57 -0700, Rodrigo Vivi wrote:
>> On Tue, Aug 29, 2023 at 10:33:02PM -0700, Dixit, Ashutosh wrote:
>>> On Tue, 29 Aug 2023 22:15:43 -0700, Aravind Iddamsetty wrote:
>>> Hi Aravind,
>>>
>>>> @@ -162,7 +162,7 @@ int xe_force_wake_get(struct xe_force_wake *fw,
>>>> 				   domain->id, ret);
>>>> 	}
>>>> 	fw->awake_domains |= woken;
>>>> -	mutex_unlock(&fw->lock);
>>>> +	spin_unlock(&fw->lock);
>>> No need to change anything yet, but let's get some more opinion on this: is
>>> it ok to (a) just replace the mutex with a spinlock in these force_wake
>>> functions, or, (b) should we have a second set of functions to be called in
>>> atomic context, say: xe_force_wake_get/put_atomic? So we should use (b) in
>>> atomic contexts and everywhere else we just continue to use the previous
>>> set of non-atomic functions? Or just converting the default set of
>>> functions to use spin lock (as is done in this patch) is ok?
>> It looks okay to me,
>> Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
> Still thinking about this, maybe some time (not part of this series) we
> should do a power measurement comparison between mutex and spinlock and see
> if there's an appreciable difference (unless we already know?). But till we
> do that, this is fine, so this is also:
>
> Reviewed-by: Ashutosh Dixit <ashutosh.dixit@intel.com>

Thanks Rodrigo and Ashutosh for your r-b.

Regards,

Aravind.

[-- Attachment #2: Type: text/html, Size: 2748 bytes --]

  reply	other threads:[~2023-08-31  4:05 UTC|newest]

Thread overview: 29+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-08-30  5:15 [Intel-xe] [PATCH v5 0/3] drm/xe/pmu: Enable PMU interface Aravind Iddamsetty
2023-08-30  5:10 ` [Intel-xe] ✓ CI.Patch_applied: success for drm/xe/pmu: Enable PMU interface (rev5) Patchwork
2023-08-30  5:10 ` [Intel-xe] ✗ CI.checkpatch: warning " Patchwork
2023-08-30  5:12 ` [Intel-xe] ✓ CI.KUnit: success " Patchwork
2023-08-30  5:15 ` [Intel-xe] [PATCH v3 1/3] drm/xe: Get GT clock to nanosecs Aravind Iddamsetty
2023-08-30  5:15 ` [Intel-xe] [PATCH 2/3] drm/xe: Use spinlock in forcewake instead of mutex Aravind Iddamsetty
2023-08-30  5:33   ` Dixit, Ashutosh
2023-08-30 20:56     ` Rodrigo Vivi
2023-08-30 22:19       ` Dixit, Ashutosh
2023-08-31  4:13         ` Aravind Iddamsetty [this message]
2023-08-30  5:15 ` [Intel-xe] [PATCH v5 3/3] drm/xe/pmu: Enable PMU interface Aravind Iddamsetty
2023-08-30 20:58   ` Rodrigo Vivi
2023-08-31 20:45     ` Dixit, Ashutosh
2023-08-31 22:14       ` Aravind Iddamsetty
2023-08-31  4:48   ` Dixit, Ashutosh
2023-08-31 10:29     ` Aravind Iddamsetty
2023-08-31 16:58       ` Dixit, Ashutosh
2023-08-31 22:11         ` Aravind Iddamsetty
2023-08-31 22:21           ` Belgaumkar, Vinay
2023-08-31 23:11             ` Aravind Iddamsetty
2023-08-31 23:22               ` Belgaumkar, Vinay
2023-08-31 23:16                 ` Dixit, Ashutosh
2023-08-31 23:57                   ` Belgaumkar, Vinay
2023-08-31 23:58                     ` Dixit, Ashutosh
2023-09-01  3:34                       ` Aravind Iddamsetty
2023-08-30  5:19 ` [Intel-xe] ✓ CI.Build: success for drm/xe/pmu: Enable PMU interface (rev5) Patchwork
2023-08-30  5:19 ` [Intel-xe] ✗ CI.Hooks: failure " Patchwork
  -- strict thread matches above, loose matches on Subject: below --
2023-09-01  7:06 [Intel-xe] [PATCH v6 0/3] drm/xe/pmu: Enable PMU interface Aravind Iddamsetty
2023-09-01  7:06 ` [Intel-xe] [PATCH 2/3] drm/xe: Use spinlock in forcewake instead of mutex Aravind Iddamsetty
2023-09-14  6:13 [Intel-xe] [PATCH v7 0/3] drm/xe/pmu: Enable PMU interface Aravind Iddamsetty
2023-09-14  6:13 ` [Intel-xe] [PATCH 2/3] drm/xe: Use spinlock in forcewake instead of mutex Aravind Iddamsetty

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=a805ff93-2a30-7f5a-de95-fdc2eea23027@linux.intel.com \
    --to=aravind.iddamsetty@linux.intel.com \
    --cc=ashutosh.dixit@intel.com \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=rodrigo.vivi@intel.com \
    /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