From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: Chris Wilson <chris@chris-wilson.co.uk>,
"O'Rourke, Tom" <Tom.O'Rourke@intel.com>,
intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH 2/4] drm/i915: Add gt_act_freq_mhz sysfs file
Date: Tue, 27 Jan 2015 11:37:04 +0200 [thread overview]
Message-ID: <20150127093704.GD19354@intel.com> (raw)
In-Reply-To: <20150126204256.GE22081@nuc-i3427.alporthouse.com>
On Mon, Jan 26, 2015 at 08:42:56PM +0000, Chris Wilson wrote:
> On Mon, Jan 26, 2015 at 12:22:07PM -0800, O'Rourke, Tom wrote:
> > On Sun, Jan 25, 2015 at 09:34:33AM +0000, Chris Wilson wrote:
> > > On Fri, Jan 23, 2015 at 09:04:24PM +0200, ville.syrjala@linux.intel.com wrote:
> > > > From: Ville Syrjälä <ville.syrjala@linux.intel.com>
> > > >
> > > > Currently the 'gt_cur_freq_mhz' file shows the actual GPU frequency on
> > > > VLV/CHV, and the last requested frequency on other platforms. Change the
> > > > meaning of the file on VLV/CHV to follow the the other platforms, and
> > > > introduce a new file 'gt_act_freq_mhz' which shows the actual frequency
> > > > on all platforms.
> > > >
> > > > Signed-off-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
> > > Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
> > >
> > > > drivers/gpu/drm/i915/i915_sysfs.c | 35 ++++++++++++++++++++++++++++++++++-
> > > > 1 file changed, 34 insertions(+), 1 deletion(-)
> > > >
> > > > +static ssize_t gt_cur_freq_mhz_show(struct device *kdev,
> > > > + struct device_attribute *attr, char *buf)
> > > > +{
> > > > + struct drm_minor *minor = dev_to_drm_minor(kdev);
> > > > + struct drm_device *dev = minor->dev;
> > > > + struct drm_i915_private *dev_priv = dev->dev_private;
> > > > + int ret;
> > > > +
> > > > + flush_delayed_work(&dev_priv->rps.delayed_resume_work);
> > >
> > > Is this required for querying the current value?
> > >
> > > Though probably better to keep it similar to the others.
> > > -Chris
> >
> > [TOR:] flush_delayed_work is needed to make sure rps.cur_freq
> > is valid for non VLV/CHV platforms.
>
> It is reporting the actual hw frequency. I still fail to see how
> flushing the pending work is important for reporting that instantaneous
> value.
Yeah, I suppose it's not really needed for act_freq, but I don't see any
real harm in having it there.
--
Ville Syrjälä
Intel OTC
_______________________________________________
Intel-gfx mailing list
Intel-gfx@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/intel-gfx
next prev parent reply other threads:[~2015-01-27 9:37 UTC|newest]
Thread overview: 14+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-01-23 19:04 [PATCH 0/4] drm/i915: PMINTRMSK fix for VLV/CHV and some other rps stuff ville.syrjala
2015-01-23 19:04 ` [PATCH 1/4] drm/i915: Update PMINTRMSK on VLV/CHV after sysfs min/max freq change ville.syrjala
2015-01-23 20:51 ` Chris Wilson
2015-01-25 9:31 ` Chris Wilson
2015-01-23 19:04 ` [PATCH 2/4] drm/i915: Add gt_act_freq_mhz sysfs file ville.syrjala
2015-01-25 9:34 ` Chris Wilson
2015-01-26 20:22 ` O'Rourke, Tom
2015-01-26 20:42 ` Chris Wilson
2015-01-27 9:37 ` Ville Syrjälä [this message]
2015-01-23 19:04 ` [PATCH 3/4] drm/i915: Add intel_gpu_freq() and intel_freq_opcode() ville.syrjala
2015-01-25 9:34 ` Chris Wilson
2015-01-23 19:04 ` [PATCH 4/4] drm/i915: Use " ville.syrjala
2015-01-25 9:35 ` Chris Wilson
2015-01-28 0:39 ` shuang.he
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=20150127093704.GD19354@intel.com \
--to=ville.syrjala@linux.intel.com \
--cc=Tom.O'Rourke@intel.com \
--cc=chris@chris-wilson.co.uk \
--cc=intel-gfx@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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox