Message ID | 2600c34a1a295456ed87fa64953a4530b0c001d2.1647870374.git.jani.nikula@intel.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | drm/i915/dmc: cleanups | expand |
Hi Jani, I love your patch! Yet something to improve: [auto build test ERROR on drm-tip/drm-tip] [cannot apply to drm-intel/for-linux-next v5.17 next-20220321] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch] url: https://github.com/0day-ci/linux/commits/Jani-Nikula/drm-i915-dmc-cleanups/20220321-215213 base: git://anongit.freedesktop.org/drm/drm-tip drm-tip config: i386-randconfig-a006-20220321 (https://download.01.org/0day-ci/archive/20220322/202203220303.d9et6XXb-lkp@intel.com/config) compiler: clang version 15.0.0 (https://github.com/llvm/llvm-project 85e9b2687a13d1908aa86d1b89c5ce398a06cd39) reproduce (this is a W=1 build): wget https://raw.githubusercontent.com/intel/lkp-tests/master/sbin/make.cross -O ~/bin/make.cross chmod +x ~/bin/make.cross # https://github.com/0day-ci/linux/commit/1e23e4b2519941d741e3489536b37823cece69d8 git remote add linux-review https://github.com/0day-ci/linux git fetch --no-tags linux-review Jani-Nikula/drm-i915-dmc-cleanups/20220321-215213 git checkout 1e23e4b2519941d741e3489536b37823cece69d8 # save the config file to linux build tree mkdir build_dir COMPILER_INSTALL_PATH=$HOME/0day COMPILER=clang make.cross W=1 O=build_dir ARCH=i386 SHELL=/bin/bash If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot <lkp@intel.com> All errors (new ones prefixed by >>): >> drivers/gpu/drm/i915/display/intel_dmc.c:822:2: error: implicit declaration of function 'i915_error_printf' [-Werror,-Wimplicit-function-declaration] i915_error_printf(m, "DMC loaded: %s\n", ^ 1 error generated. vim +/i915_error_printf +822 drivers/gpu/drm/i915/display/intel_dmc.c 813 814 void intel_dmc_print_error_state(struct drm_i915_error_state_buf *m, 815 struct drm_i915_private *i915) 816 { 817 struct intel_dmc *dmc = &i915->dmc; 818 819 if (!HAS_DMC(i915)) 820 return; 821 > 822 i915_error_printf(m, "DMC loaded: %s\n", 823 str_yes_no(intel_dmc_has_payload(i915))); 824 i915_error_printf(m, "DMC fw version: %d.%d\n", 825 DMC_VERSION_MAJOR(dmc->version), 826 DMC_VERSION_MINOR(dmc->version)); 827 } 828
Hi Jani, I love your patch! Yet something to improve: [auto build test ERROR on drm-tip/drm-tip] [cannot apply to drm-intel/for-linux-next v5.17 next-20220321] [If your patch is applied to the wrong git tree, kindly drop us a note. And when submitting patch, we suggest to use '--base' as documented in https://git-scm.com/docs/git-format-patch] url: https://github.com/0day-ci/linux/commits/Jani-Nikula/drm-i915-dmc-cleanups/20220321-215213 base: git://anongit.freedesktop.org/drm/drm-tip drm-tip config: i386-randconfig-s002 (https://download.01.org/0day-ci/archive/20220322/202203221023.tCblMieg-lkp@intel.com/config) compiler: gcc-9 (Ubuntu 9.4.0-1ubuntu1~20.04) 9.4.0 reproduce: # apt-get install sparse # sparse version: v0.6.4-dirty # https://github.com/0day-ci/linux/commit/1e23e4b2519941d741e3489536b37823cece69d8 git remote add linux-review https://github.com/0day-ci/linux git fetch --no-tags linux-review Jani-Nikula/drm-i915-dmc-cleanups/20220321-215213 git checkout 1e23e4b2519941d741e3489536b37823cece69d8 # save the config file to linux build tree mkdir build_dir make W=1 C=1 CF='-fdiagnostic-prefix -D__CHECK_ENDIAN__' O=build_dir ARCH=i386 SHELL=/bin/bash If you fix the issue, kindly add following tag as appropriate Reported-by: kernel test robot <lkp@intel.com> All errors (new ones prefixed by >>): drivers/gpu/drm/i915/display/intel_dmc.c: In function 'intel_dmc_print_error_state': >> drivers/gpu/drm/i915/display/intel_dmc.c:822:2: error: implicit declaration of function 'i915_error_printf' [-Werror=implicit-function-declaration] 822 | i915_error_printf(m, "DMC loaded: %s\n", | ^~~~~~~~~~~~~~~~~ cc1: all warnings being treated as errors vim +/i915_error_printf +822 drivers/gpu/drm/i915/display/intel_dmc.c 813 814 void intel_dmc_print_error_state(struct drm_i915_error_state_buf *m, 815 struct drm_i915_private *i915) 816 { 817 struct intel_dmc *dmc = &i915->dmc; 818 819 if (!HAS_DMC(i915)) 820 return; 821 > 822 i915_error_printf(m, "DMC loaded: %s\n", 823 str_yes_no(intel_dmc_has_payload(i915))); 824 i915_error_printf(m, "DMC fw version: %d.%d\n", 825 DMC_VERSION_MAJOR(dmc->version), 826 DMC_VERSION_MINOR(dmc->version)); 827 } 828
diff --git a/drivers/gpu/drm/i915/display/intel_dmc.c b/drivers/gpu/drm/i915/display/intel_dmc.c index 5de13f978e57..f0eb3de8de60 100644 --- a/drivers/gpu/drm/i915/display/intel_dmc.c +++ b/drivers/gpu/drm/i915/display/intel_dmc.c @@ -811,6 +811,21 @@ void intel_dmc_ucode_fini(struct drm_i915_private *dev_priv) kfree(dev_priv->dmc.dmc_info[id].payload); } +void intel_dmc_print_error_state(struct drm_i915_error_state_buf *m, + struct drm_i915_private *i915) +{ + struct intel_dmc *dmc = &i915->dmc; + + if (!HAS_DMC(i915)) + return; + + i915_error_printf(m, "DMC loaded: %s\n", + str_yes_no(intel_dmc_has_payload(i915))); + i915_error_printf(m, "DMC fw version: %d.%d\n", + DMC_VERSION_MAJOR(dmc->version), + DMC_VERSION_MINOR(dmc->version)); +} + static int intel_dmc_debugfs_status_show(struct seq_file *m, void *unused) { struct drm_i915_private *i915 = m->private; diff --git a/drivers/gpu/drm/i915/display/intel_dmc.h b/drivers/gpu/drm/i915/display/intel_dmc.h index b9f608057700..dd8880d2cbed 100644 --- a/drivers/gpu/drm/i915/display/intel_dmc.h +++ b/drivers/gpu/drm/i915/display/intel_dmc.h @@ -10,6 +10,7 @@ #include "intel_wakeref.h" #include <linux/workqueue.h> +struct drm_i915_error_state_buf; struct drm_i915_private; #define DMC_VERSION(major, minor) ((major) << 16 | (minor)) @@ -55,6 +56,8 @@ void intel_dmc_ucode_suspend(struct drm_i915_private *i915); void intel_dmc_ucode_resume(struct drm_i915_private *i915); bool intel_dmc_has_payload(struct drm_i915_private *i915); void intel_dmc_debugfs_register(struct drm_i915_private *i915); +void intel_dmc_print_error_state(struct drm_i915_error_state_buf *m, + struct drm_i915_private *i915); void assert_dmc_loaded(struct drm_i915_private *i915); diff --git a/drivers/gpu/drm/i915/i915_gpu_error.c b/drivers/gpu/drm/i915/i915_gpu_error.c index a8acc6fbb299..fb3baf4af792 100644 --- a/drivers/gpu/drm/i915/i915_gpu_error.c +++ b/drivers/gpu/drm/i915/i915_gpu_error.c @@ -825,15 +825,7 @@ static void __err_print_to_sgl(struct drm_i915_error_state_buf *m, err_printf(m, "IOMMU enabled?: %d\n", error->iommu); - if (HAS_DMC(m->i915)) { - struct intel_dmc *dmc = &m->i915->dmc; - - err_printf(m, "DMC loaded: %s\n", - str_yes_no(intel_dmc_has_payload(m->i915) != 0)); - err_printf(m, "DMC fw version: %d.%d\n", - DMC_VERSION_MAJOR(dmc->version), - DMC_VERSION_MINOR(dmc->version)); - } + intel_dmc_print_error_state(m, m->i915); err_printf(m, "RPM wakelock: %s\n", str_yes_no(error->wakelock)); err_printf(m, "PM suspended: %s\n", str_yes_no(error->suspended));