All of lore.kernel.org
 help / color / mirror / Atom feed
From: Jani Nikula <jani.nikula@intel.com>
To: "Coelho, Luciano" <luciano.coelho@intel.com>,
	"intel-xe@lists.freedesktop.org" <intel-xe@lists.freedesktop.org>
Subject: Re: [RFC v2 1/4] drm/i915/display: add support for DMC wakelocks
Date: Tue, 16 Jan 2024 14:45:19 +0200	[thread overview]
Message-ID: <8734uxsazk.fsf@intel.com> (raw)
In-Reply-To: <5de5aff06d303129a742a416ef65fea64f4f1d27.camel@intel.com>

On Tue, 16 Jan 2024, "Coelho, Luciano" <luciano.coelho@intel.com> wrote:
> On Tue, 2024-01-16 at 14:28 +0200, Jani Nikula wrote:
>> On Thu, 11 Jan 2024, Luca Coelho <luciano.coelho@intel.com> wrote:
>> > diff --git a/drivers/gpu/drm/i915/display/intel_wakelock.h b/drivers/gpu/drm/i915/display/intel_wakelock.h
>> > new file mode 100644
>> > index 000000000000..a47205e1ea32
>> > --- /dev/null
>> > +++ b/drivers/gpu/drm/i915/display/intel_wakelock.h
>> > @@ -0,0 +1,34 @@
>> > +/* SPDX-License-Identifier: MIT */
>> > +/*
>> > + * Copyright (C) 2023 Intel Corporation
>> > + */
>> > +
>> > +#ifndef __INTEL_WAKELOCK_H__
>> > +#define __INTEL_WAKELOCK_H__
>> > +
>> > +#include <linux/types.h>
>> > +#include <linux/workqueue.h>
>> > +#include <linux/refcount.h>
>> > +
>> > +#include "i915_reg_defs.h"
>> > +
>> > +struct drm_i915_private;
>> > +
>> > +struct intel_display_wl {
>> > +   spinlock_t lock;
>> > +   bool enabled;
>> > +   refcount_t refcount;
>> > +   struct delayed_work work;
>> > +};
>> > +
>> > +struct intel_display_wl_range {
>> > +   u32 start;
>> > +   u32 end;
>> > +};
>> > +
>> > +void intel_display_wl_init(struct drm_i915_private *i915);
>> > +void intel_display_wl_enable(struct drm_i915_private *i915);
>> > +void intel_display_wl_get(struct drm_i915_private *i915, i915_reg_t reg);
>> > +void intel_display_wl_put(struct drm_i915_private *i915, i915_reg_t reg);
>>
>> Nitpick, I'll want the name prefix to match the filename,
>> i.e. intel_foo.[ch] have functions named intel_foo_*.
>
> Okay, so intel_wakelock_*(), specifically in this case?

Yes, though my comment was rather more generic.

As to the actual naming here, I think the first question really is if
"intel wakelock" is specific enough for what you're suggesting.

If yes, I do prefer wakelock over wl. But I don't know. :)

BR,
Jani.



>
> I can also rename the file to intel_wl.[ch] if we want to save
> horizontal real estate, in which case the function names would be
> intel_wl_*(), right?








>
> Thanks!
>
> --
> Cheers,
> Luca.

-- 
Jani Nikula, Intel

  reply	other threads:[~2024-01-16 12:45 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-01-11  9:16 [RFC v2 0/5] drm/i915/display: DMC wakelock implementation Luca Coelho
2024-01-11  9:16 ` [RFC v2 1/4] drm/i915/display: add support for DMC wakelocks Luca Coelho
2024-01-11 14:15   ` Gustavo Sousa
2024-01-12  9:58     ` Coelho, Luciano
2024-01-16 12:28   ` Jani Nikula
2024-01-16 12:32     ` Coelho, Luciano
2024-01-16 12:45       ` Jani Nikula [this message]
2024-01-16 13:10         ` Gustavo Sousa
2024-01-11  9:16 ` [RFC v2 2/4] drm/i915/display: use wakelock in the remaining read operations Luca Coelho
2024-01-11  9:16 ` [RFC v2 3/4] drm/i915/display: use wakelock in register waiting functions Luca Coelho
2024-01-11  9:16 ` [RFC v2 4/4] drm/i915/display: use wakelock in the last write function Luca Coelho
2024-01-11  9:55 ` ✓ CI.Patch_applied: success for drm/i915/display: DMC wakelock implementation Patchwork
2024-01-11  9:56 ` ✗ CI.checkpatch: warning " Patchwork
2024-01-11  9:57 ` ✓ CI.KUnit: success " Patchwork
2024-01-11 10:04 ` ✓ CI.Build: " Patchwork
2024-01-11 10:05 ` ✓ CI.Hooks: " Patchwork
2024-01-11 10:06 ` ✗ CI.checksparse: warning " Patchwork
2024-01-11 10:43 ` ✗ CI.BAT: failure " 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=8734uxsazk.fsf@intel.com \
    --to=jani.nikula@intel.com \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=luciano.coelho@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 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.