[Intel-gfx] [PATCH] drm/i915/psr: Add missing check for I915_PSR_DEBUG_IRQ bit

kbuild test robot lkp at intel.com
Sun Aug 12 09:26:07 UTC 2018


Hi Dhinakaran,

Thank you for the patch! Perhaps something to improve:

[auto build test WARNING on drm-intel/for-linux-next]
[also build test WARNING on v4.18-rc8 next-20180810]
[if your patch is applied to the wrong git tree, please drop us a note to help improve the system]

url:    https://github.com/0day-ci/linux/commits/Dhinakaran-Pandiyan/drm-i915-psr-Add-missing-check-for-I915_PSR_DEBUG_IRQ-bit/20180812-143531
base:   git://anongit.freedesktop.org/drm-intel for-linux-next
config: x86_64-randconfig-s1-08121632 (attached as .config)
compiler: gcc-6 (Debian 6.4.0-9) 6.4.0 20171026
reproduce:
        # save the attached .config to linux build tree
        make ARCH=x86_64 

All warnings (new ones prefixed by >>):

   In file included from include/linux/kernel.h:10:0,
                    from include/linux/list.h:9,
                    from include/linux/wait.h:7,
                    from include/linux/wait_bit.h:8,
                    from include/linux/fs.h:6,
                    from include/linux/debugfs.h:15,
                    from drivers/gpu/drm/i915/i915_debugfs.c:29:
   drivers/gpu/drm/i915/i915_debugfs.c: In function 'i915_edp_psr_status':
   drivers/gpu/drm/i915/i915_debugfs.c:2738:39: error: 'I915_PSR_DEBUG_IRQ' undeclared (first use in this function)
     if (READ_ONCE(dev_priv->psr.debug) & I915_PSR_DEBUG_IRQ) {
                                          ^
   include/linux/compiler.h:58:30: note: in definition of macro '__trace_if'
     if (__builtin_constant_p(!!(cond)) ? !!(cond) :   \
                                 ^~~~
>> drivers/gpu/drm/i915/i915_debugfs.c:2738:2: note: in expansion of macro 'if'
     if (READ_ONCE(dev_priv->psr.debug) & I915_PSR_DEBUG_IRQ) {
     ^~
   drivers/gpu/drm/i915/i915_debugfs.c:2738:39: note: each undeclared identifier is reported only once for each function it appears in
     if (READ_ONCE(dev_priv->psr.debug) & I915_PSR_DEBUG_IRQ) {
                                          ^
   include/linux/compiler.h:58:30: note: in definition of macro '__trace_if'
     if (__builtin_constant_p(!!(cond)) ? !!(cond) :   \
                                 ^~~~
>> drivers/gpu/drm/i915/i915_debugfs.c:2738:2: note: in expansion of macro 'if'
     if (READ_ONCE(dev_priv->psr.debug) & I915_PSR_DEBUG_IRQ) {
     ^~

vim +/if +2738 drivers/gpu/drm/i915/i915_debugfs.c

  2692	
  2693	static int i915_edp_psr_status(struct seq_file *m, void *data)
  2694	{
  2695		struct drm_i915_private *dev_priv = node_to_i915(m->private);
  2696		u32 psrperf = 0;
  2697		bool enabled = false;
  2698		bool sink_support;
  2699	
  2700		if (!HAS_PSR(dev_priv))
  2701			return -ENODEV;
  2702	
  2703		sink_support = dev_priv->psr.sink_support;
  2704		seq_printf(m, "Sink_Support: %s\n", yesno(sink_support));
  2705		if (!sink_support)
  2706			return 0;
  2707	
  2708		intel_runtime_pm_get(dev_priv);
  2709	
  2710		mutex_lock(&dev_priv->psr.lock);
  2711		seq_printf(m, "Enabled: %s\n", yesno((bool)dev_priv->psr.enabled));
  2712		seq_printf(m, "Busy frontbuffer bits: 0x%03x\n",
  2713			   dev_priv->psr.busy_frontbuffer_bits);
  2714	
  2715		if (dev_priv->psr.psr2_enabled)
  2716			enabled = I915_READ(EDP_PSR2_CTL) & EDP_PSR2_ENABLE;
  2717		else
  2718			enabled = I915_READ(EDP_PSR_CTL) & EDP_PSR_ENABLE;
  2719	
  2720		seq_printf(m, "Main link in standby mode: %s\n",
  2721			   yesno(dev_priv->psr.link_standby));
  2722	
  2723		seq_printf(m, "HW Enabled & Active bit: %s\n", yesno(enabled));
  2724	
  2725		/*
  2726		 * SKL+ Perf counter is reset to 0 everytime DC state is entered
  2727		 */
  2728		if (IS_HASWELL(dev_priv) || IS_BROADWELL(dev_priv)) {
  2729			psrperf = I915_READ(EDP_PSR_PERF_CNT) &
  2730				EDP_PSR_PERF_CNT_MASK;
  2731	
  2732			seq_printf(m, "Performance_Counter: %u\n", psrperf);
  2733		}
  2734	
  2735		psr_source_status(dev_priv, m);
  2736		mutex_unlock(&dev_priv->psr.lock);
  2737	
> 2738		if (READ_ONCE(dev_priv->psr.debug) & I915_PSR_DEBUG_IRQ) {
  2739			seq_printf(m, "Last attempted entry at: %lld\n",
  2740				   dev_priv->psr.last_entry_attempt);
  2741			seq_printf(m, "Last exit at: %lld\n",
  2742				   dev_priv->psr.last_exit);
  2743		}
  2744	
  2745		intel_runtime_pm_put(dev_priv);
  2746		return 0;
  2747	}
  2748	

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation
-------------- next part --------------
A non-text attachment was scrubbed...
Name: .config.gz
Type: application/gzip
Size: 26769 bytes
Desc: not available
URL: <https://lists.freedesktop.org/archives/intel-gfx/attachments/20180812/f3c01d7d/attachment-0001.gz>


More information about the Intel-gfx mailing list