[drm-misc:for-linux-next 1/2] drivers/gpu/drm/i915/i915_debugfs.c:739:9: error: implicit declaration of function 'debugfs_create_file'; did you mean 'bus_create_file'?

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



tree:   git://anongit.freedesktop.org/drm/drm-misc for-linux-next
head:   2bdb481bf7a93c22b9fea8daefa2834aab23a70f
commit: 33d5ae6cacf46a043578d711ae7239bab55b4455 [1/2] drm/print: drop include debugfs.h and include where needed
config: x86_64-defconfig (https://download.01.org/0day-ci/archive/20240426/202404260726.nyGuvl59-lkp@xxxxxxxxx/config)
compiler: gcc-13 (Ubuntu 13.2.0-4ubuntu3) 13.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240426/202404260726.nyGuvl59-lkp@xxxxxxxxx/reproduce)

If you fix the issue in a separate patch/commit (i.e. not just a new version of
the same patch/commit), kindly add following tags
| Reported-by: kernel test robot <lkp@xxxxxxxxx>
| Closes: https://lore.kernel.org/oe-kbuild-all/202404260726.nyGuvl59-lkp@xxxxxxxxx/

All error/warnings (new ones prefixed by >>):

   drivers/gpu/drm/i915/i915_debugfs.c: In function 'i915_debugfs_register':
>> drivers/gpu/drm/i915/i915_debugfs.c:739:9: error: implicit declaration of function 'debugfs_create_file'; did you mean 'bus_create_file'? [-Werror=implicit-function-declaration]
     739 |         debugfs_create_file("i915_forcewake_user", S_IRUSR, minor->debugfs_root,
         |         ^~~~~~~~~~~~~~~~~~~
         |         bus_create_file
   cc1: some warnings being treated as errors
--
   drivers/gpu/drm/i915/i915_debugfs_params.c: In function 'i915_debugfs_create_int':
>> drivers/gpu/drm/i915/i915_debugfs_params.c:213:16: error: implicit declaration of function 'debugfs_create_file_unsafe'; did you mean 'sysfs_create_file_ns'? [-Werror=implicit-function-declaration]
     213 |         return debugfs_create_file_unsafe(name, mode, parent, value,
         |                ^~~~~~~~~~~~~~~~~~~~~~~~~~
         |                sysfs_create_file_ns
>> drivers/gpu/drm/i915/i915_debugfs_params.c:213:16: warning: returning 'int' from a function with return type 'struct dentry *' makes pointer from integer without a cast [-Wint-conversion]
     213 |         return debugfs_create_file_unsafe(name, mode, parent, value,
         |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     214 |                                           RO(mode) ? &i915_param_int_fops_ro :
         |                                           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     215 |                                           &i915_param_int_fops);
         |                                           ~~~~~~~~~~~~~~~~~~~~~
   drivers/gpu/drm/i915/i915_debugfs_params.c: In function 'i915_debugfs_create_uint':
   drivers/gpu/drm/i915/i915_debugfs_params.c:222:16: warning: returning 'int' from a function with return type 'struct dentry *' makes pointer from integer without a cast [-Wint-conversion]
     222 |         return debugfs_create_file_unsafe(name, mode, parent, value,
         |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     223 |                                           RO(mode) ? &i915_param_uint_fops_ro :
         |                                           ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     224 |                                           &i915_param_uint_fops);
         |                                           ~~~~~~~~~~~~~~~~~~~~~~
   drivers/gpu/drm/i915/i915_debugfs_params.c: In function 'i915_debugfs_create_charp':
>> drivers/gpu/drm/i915/i915_debugfs_params.c:231:16: error: implicit declaration of function 'debugfs_create_file'; did you mean 'bus_create_file'? [-Werror=implicit-function-declaration]
     231 |         return debugfs_create_file(name, mode, parent, value,
         |                ^~~~~~~~~~~~~~~~~~~
         |                bus_create_file
   drivers/gpu/drm/i915/i915_debugfs_params.c:231:16: warning: returning 'int' from a function with return type 'struct dentry *' makes pointer from integer without a cast [-Wint-conversion]
     231 |         return debugfs_create_file(name, mode, parent, value,
         |                ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     232 |                                    RO(mode) ? &i915_param_charp_fops_ro :
         |                                    ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
     233 |                                    &i915_param_charp_fops);
         |                                    ~~~~~~~~~~~~~~~~~~~~~~~
   drivers/gpu/drm/i915/i915_debugfs_params.c: In function 'i915_debugfs_params':
>> drivers/gpu/drm/i915/i915_debugfs_params.c:254:15: error: implicit declaration of function 'debugfs_create_dir'; did you mean 'kernfs_create_dir'? [-Werror=implicit-function-declaration]
     254 |         dir = debugfs_create_dir("i915_params", minor->debugfs_root);
         |               ^~~~~~~~~~~~~~~~~~
         |               kernfs_create_dir
>> drivers/gpu/drm/i915/i915_debugfs_params.c:254:13: warning: assignment to 'struct dentry *' from 'int' makes pointer from integer without a cast [-Wint-conversion]
     254 |         dir = debugfs_create_dir("i915_params", minor->debugfs_root);
         |             ^
>> drivers/gpu/drm/i915/i915_debugfs_params.c:240:42: error: 'debugfs_create_bool' undeclared (first use in this function); did you mean 'kernfs_create_root'?
     240 |                                  bool *: debugfs_create_bool,           \
         |                                          ^~~~~~~~~~~~~~~~~~~
   drivers/gpu/drm/i915/i915_debugfs_params.c:264:43: note: in expansion of macro '_i915_param_create_file'
     264 | #define REGISTER(T, x, unused, mode, ...) _i915_param_create_file(dir, #x, mode, &params->x);
         |                                           ^~~~~~~~~~~~~~~~~~~~~~~
   drivers/gpu/drm/i915/i915_params.h:49:9: note: in expansion of macro 'REGISTER'
      49 |         param(int, modeset, -1, 0400) \
         |         ^~~~~
   drivers/gpu/drm/i915/i915_debugfs_params.c:265:9: note: in expansion of macro 'I915_PARAMS_FOR_EACH'
     265 |         I915_PARAMS_FOR_EACH(REGISTER);
         |         ^~~~~~~~~~~~~~~~~~~~
   drivers/gpu/drm/i915/i915_debugfs_params.c:240:42: note: each undeclared identifier is reported only once for each function it appears in
     240 |                                  bool *: debugfs_create_bool,           \
         |                                          ^~~~~~~~~~~~~~~~~~~
   drivers/gpu/drm/i915/i915_debugfs_params.c:264:43: note: in expansion of macro '_i915_param_create_file'
     264 | #define REGISTER(T, x, unused, mode, ...) _i915_param_create_file(dir, #x, mode, &params->x);
         |                                           ^~~~~~~~~~~~~~~~~~~~~~~
   drivers/gpu/drm/i915/i915_params.h:49:9: note: in expansion of macro 'REGISTER'
      49 |         param(int, modeset, -1, 0400) \
         |         ^~~~~
   drivers/gpu/drm/i915/i915_debugfs_params.c:265:9: note: in expansion of macro 'I915_PARAMS_FOR_EACH'
     265 |         I915_PARAMS_FOR_EACH(REGISTER);
         |         ^~~~~~~~~~~~~~~~~~~~
   drivers/gpu/drm/i915/i915_debugfs_params.c: At top level:
>> drivers/gpu/drm/i915/i915_debugfs_params.c:228:1: warning: 'i915_debugfs_create_charp' defined but not used [-Wunused-function]
     228 | i915_debugfs_create_charp(const char *name, umode_t mode,
         | ^~~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/gpu/drm/i915/i915_debugfs_params.c:219:1: warning: 'i915_debugfs_create_uint' defined but not used [-Wunused-function]
     219 | i915_debugfs_create_uint(const char *name, umode_t mode,
         | ^~~~~~~~~~~~~~~~~~~~~~~~
>> drivers/gpu/drm/i915/i915_debugfs_params.c:210:1: warning: 'i915_debugfs_create_int' defined but not used [-Wunused-function]
     210 | i915_debugfs_create_int(const char *name, umode_t mode,
         | ^~~~~~~~~~~~~~~~~~~~~~~
   cc1: some warnings being treated as errors
--
   drivers/gpu/drm/i915/i915_gpu_error.c: In function 'i915_gpu_error_debugfs_register':
>> drivers/gpu/drm/i915/i915_gpu_error.c:2485:9: error: implicit declaration of function 'debugfs_create_file'; did you mean 'bus_create_file'? [-Werror=implicit-function-declaration]
    2485 |         debugfs_create_file("i915_error_state", 0644, minor->debugfs_root, i915,
         |         ^~~~~~~~~~~~~~~~~~~
         |         bus_create_file
   cc1: some warnings being treated as errors


vim +739 drivers/gpu/drm/i915/i915_debugfs.c

34b9674c786c73 drivers/gpu/drm/i915/i915_debugfs.c     Daniel Vetter      2013-07-04  731  
f06b2052f74d7b drivers/gpu/drm/i915/i915_debugfs.c     Wambui Karuga      2020-03-10  732  void i915_debugfs_register(struct drm_i915_private *dev_priv)
2017263e9e7297 drivers/gpu/drm/i915/i915_gem_debugfs.c Ben Gamari         2009-02-17  733  {
91c8a326a19211 drivers/gpu/drm/i915/i915_debugfs.c     Chris Wilson       2016-07-05  734  	struct drm_minor *minor = dev_priv->drm.primary;
6cc42152b02b3f drivers/gpu/drm/i915/i915_debugfs.c     Maarten Lankhorst  2018-06-28  735  	int i;
f3cd474bb235f2 drivers/gpu/drm/i915/i915_debugfs.c     Chris Wilson       2009-10-13  736  
c43c5a8818d4c3 drivers/gpu/drm/i915/i915_debugfs.c     Jani Nikula        2019-12-05  737  	i915_debugfs_params(dev_priv);
c43c5a8818d4c3 drivers/gpu/drm/i915/i915_debugfs.c     Jani Nikula        2019-12-05  738  
0780f3b6f054ec drivers/gpu/drm/i915/i915_debugfs.c     Greg Kroah-Hartman 2019-06-13 @739  	debugfs_create_file("i915_forcewake_user", S_IRUSR, minor->debugfs_root,

:::::: The code at line 739 was first introduced by commit
:::::: 0780f3b6f054ec6497a1a16edb9bf5832c0b92f4 drm/i915: no need to check return value of debugfs_create functions

:::::: TO: Greg Kroah-Hartman <gregkh@xxxxxxxxxxxxxxxxxxx>
:::::: CC: Jani Nikula <jani.nikula@xxxxxxxxx>

-- 
0-DAY CI Kernel Test Service
https://github.com/intel/lkp-tests/wiki



[Index of Archives]     [Linux DRI Users]     [Linux Intel Graphics]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Linux USB Devel]     [Video for Linux]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]
  Powered by Linux