Message ID | 1420836965-10068-10-git-send-email-vandana.kannan@intel.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
On Sat, Jan 10, 2015 at 02:26:04AM +0530, Vandana Kannan wrote: > Adding a debugfs entry to determine if DRRS is supported or not > > Signed-off-by: Vandana Kannan <vandana.kannan@intel.com> > --- > drivers/gpu/drm/i915/i915_debugfs.c | 18 ++++++++++++++++++ > 1 file changed, 18 insertions(+) > > diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c > index e515aad..544b4c3 100644 > --- a/drivers/gpu/drm/i915/i915_debugfs.c > +++ b/drivers/gpu/drm/i915/i915_debugfs.c > @@ -2825,6 +2825,23 @@ static int i915_ddb_info(struct seq_file *m, void *unused) > return 0; > } > > +static int i915_drrs_status(struct seq_file *m, void *unused) > +{ > + struct drm_info_node *node = m->private; > + struct drm_device *dev = node->minor->dev; > + struct intel_crtc *crtc; > + > + for_each_intel_crtc(dev, crtc) { > + if (crtc->active) { Don't you want to know which CRTC this is? Would this not be better extending display_info with the extra CRTC status? > + if (crtc->config.has_drrs) > + seq_puts(m, "DRRS enabled"); > + else > + seq_puts(m, "DRRS disabled"); > + } > + } -Chris
On Sun, Jan 11, 2015 at 4:40 AM, Chris Wilson <chris@chris-wilson.co.uk> wrote: > On Sat, Jan 10, 2015 at 02:26:04AM +0530, Vandana Kannan wrote: >> Adding a debugfs entry to determine if DRRS is supported or not >> >> Signed-off-by: Vandana Kannan <vandana.kannan@intel.com> >> --- >> drivers/gpu/drm/i915/i915_debugfs.c | 18 ++++++++++++++++++ >> 1 file changed, 18 insertions(+) >> >> diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c >> index e515aad..544b4c3 100644 >> --- a/drivers/gpu/drm/i915/i915_debugfs.c >> +++ b/drivers/gpu/drm/i915/i915_debugfs.c >> @@ -2825,6 +2825,23 @@ static int i915_ddb_info(struct seq_file *m, void *unused) >> return 0; >> } >> >> +static int i915_drrs_status(struct seq_file *m, void *unused) >> +{ >> + struct drm_info_node *node = m->private; >> + struct drm_device *dev = node->minor->dev; >> + struct intel_crtc *crtc; >> + >> + for_each_intel_crtc(dev, crtc) { >> + if (crtc->active) { > > Don't you want to know which CRTC this is? Would this not be better > extending display_info with the extra CRTC status? > >> + if (crtc->config.has_drrs) Also it just shows if panel supports drrs, not if it is enabled... >> + seq_puts(m, "DRRS enabled"); >> + else >> + seq_puts(m, "DRRS disabled"); >> + } >> + } > -Chris > > -- > Chris Wilson, Intel Open Source Technology Centre > _______________________________________________ > Intel-gfx mailing list > Intel-gfx@lists.freedesktop.org > http://lists.freedesktop.org/mailman/listinfo/intel-gfx
Hi On Friday 16 January 2015 04:48 AM, Rodrigo Vivi wrote: > On Sun, Jan 11, 2015 at 4:40 AM, Chris Wilson <chris@chris-wilson.co.uk> wrote: >> On Sat, Jan 10, 2015 at 02:26:04AM +0530, Vandana Kannan wrote: >>> Adding a debugfs entry to determine if DRRS is supported or not >>> >>> Signed-off-by: Vandana Kannan <vandana.kannan@intel.com> >>> --- >>> drivers/gpu/drm/i915/i915_debugfs.c | 18 ++++++++++++++++++ >>> 1 file changed, 18 insertions(+) >>> >>> diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c >>> index e515aad..544b4c3 100644 >>> --- a/drivers/gpu/drm/i915/i915_debugfs.c >>> +++ b/drivers/gpu/drm/i915/i915_debugfs.c >>> @@ -2825,6 +2825,23 @@ static int i915_ddb_info(struct seq_file *m, void *unused) >>> return 0; >>> } >>> >>> +static int i915_drrs_status(struct seq_file *m, void *unused) >>> +{ >>> + struct drm_info_node *node = m->private; >>> + struct drm_device *dev = node->minor->dev; >>> + struct intel_crtc *crtc; >>> + >>> + for_each_intel_crtc(dev, crtc) { >>> + if (crtc->active) { >> Don't you want to know which CRTC this is? Would this not be better >> extending display_info with the extra CRTC status? >> >>> + if (crtc->config.has_drrs) > Also it just shows if panel supports drrs, not if it is enabled... Yes. We need to provide information on the platform's DRRS capability, crtc and the current DRRS state (LOW_RR/HIGH_RR). I am working on the same. > >>> + seq_puts(m, "DRRS enabled"); >>> + else >>> + seq_puts(m, "DRRS disabled"); >>> + } >>> + } >> -Chris >> >> -- >> Chris Wilson, Intel Open Source Technology Centre >> _______________________________________________ >> Intel-gfx mailing list >> Intel-gfx@lists.freedesktop.org >> http://lists.freedesktop.org/mailman/listinfo/intel-gfx > > --Ram
diff --git a/drivers/gpu/drm/i915/i915_debugfs.c b/drivers/gpu/drm/i915/i915_debugfs.c index e515aad..544b4c3 100644 --- a/drivers/gpu/drm/i915/i915_debugfs.c +++ b/drivers/gpu/drm/i915/i915_debugfs.c @@ -2825,6 +2825,23 @@ static int i915_ddb_info(struct seq_file *m, void *unused) return 0; } +static int i915_drrs_status(struct seq_file *m, void *unused) +{ + struct drm_info_node *node = m->private; + struct drm_device *dev = node->minor->dev; + struct intel_crtc *crtc; + + for_each_intel_crtc(dev, crtc) { + if (crtc->active) { + if (crtc->config.has_drrs) + seq_puts(m, "DRRS enabled"); + else + seq_puts(m, "DRRS disabled"); + } + } + return 0; +} + struct pipe_crc_info { const char *name; struct drm_device *dev; @@ -4437,6 +4454,7 @@ static const struct drm_info_list i915_debugfs_list[] = { {"i915_dp_mst_info", i915_dp_mst_info, 0}, {"i915_wa_registers", i915_wa_registers, 0}, {"i915_ddb_info", i915_ddb_info, 0}, + {"i915_drrs_status", i915_drrs_status, 0}, }; #define I915_DEBUGFS_ENTRIES ARRAY_SIZE(i915_debugfs_list)
Adding a debugfs entry to determine if DRRS is supported or not Signed-off-by: Vandana Kannan <vandana.kannan@intel.com> --- drivers/gpu/drm/i915/i915_debugfs.c | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+)