[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <202212100503.jO9I8OIN-lkp@intel.com>
Date: Sat, 10 Dec 2022 05:53:36 +0800
From: kernel test robot <lkp@...el.com>
To: Sergei Shtepa <sergei.shtepa@...am.com>, axboe@...nel.dk,
corbet@....net
Cc: oe-kbuild-all@...ts.linux.dev, linux-block@...r.kernel.org,
linux-doc@...r.kernel.org, linux-kernel@...r.kernel.org,
Sergei Shtepa <sergei.shtepa@...am.com>
Subject: Re: [PATCH v2 20/21] block, blksnap: adds a blksnap to the kernel
tree
Hi Sergei,
Thank you for the patch! Yet something to improve:
[auto build test ERROR on axboe-block/for-next]
[also build test ERROR on linus/master v6.1-rc8 next-20221208]
[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#_base_tree_information]
url: https://github.com/intel-lab-lkp/linux/commits/Sergei-Shtepa/blksnap-block-devices-snapshots-module/20221209-231603
base: https://git.kernel.org/pub/scm/linux/kernel/git/axboe/linux-block.git for-next
patch link: https://lore.kernel.org/r/20221209142331.26395-21-sergei.shtepa%40veeam.com
patch subject: [PATCH v2 20/21] block, blksnap: adds a blksnap to the kernel tree
config: arm-randconfig-r035-20221210
compiler: arm-linux-gnueabi-gcc (GCC) 12.1.0
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/intel-lab-lkp/linux/commit/79aebb9891b15d1de8770c4fc61f73bc5e251b04
git remote add linux-review https://github.com/intel-lab-lkp/linux
git fetch --no-tags linux-review Sergei-Shtepa/blksnap-block-devices-snapshots-module/20221209-231603
git checkout 79aebb9891b15d1de8770c4fc61f73bc5e251b04
# save the config file
mkdir build_dir && cp config build_dir/.config
COMPILER_INSTALL_PATH=$HOME/0day COMPILER=gcc-12.1.0 make.cross W=1 O=build_dir ARCH=arm SHELL=/bin/bash drivers/block/blksnap/
If you fix the issue, kindly add following tag where applicable
| Reported-by: kernel test robot <lkp@...el.com>
All errors (new ones prefixed by >>):
drivers/block/blksnap/ctrl.c: In function 'ctrl_init':
>> drivers/block/blksnap/ctrl.c:45:45: error: invalid use of undefined type 'struct module'
45 | ret = register_chrdev(0, THIS_MODULE->name, &ctrl_fops);
| ^~
drivers/block/blksnap/ctrl.c: In function 'ctrl_done':
drivers/block/blksnap/ctrl.c:61:54: error: invalid use of undefined type 'struct module'
61 | unregister_chrdev(blk_snap_major, THIS_MODULE->name);
| ^~
--
In file included from include/linux/device.h:31,
from include/linux/blk_types.h:11,
from include/linux/blkdev.h:9,
from drivers/block/blksnap/sysfs.c:5:
drivers/block/blksnap/sysfs.c: In function 'sysfs_initialize':
>> drivers/block/blksnap/sysfs.c:31:63: error: invalid use of undefined type 'struct module'
31 | blk_snap_class = class_create(THIS_MODULE, THIS_MODULE->name);
| ^~
include/linux/device/class.h:276:31: note: in definition of macro 'class_create'
276 | __class_create(owner, name, &__key); \
| ^~~~
drivers/block/blksnap/sysfs.c:51:40: error: invalid use of undefined type 'struct module'
51 | THIS_MODULE->name);
| ^~
vim +45 drivers/block/blksnap/ctrl.c
2c91bb136c2522 Sergei Shtepa 2022-12-09 40
2c91bb136c2522 Sergei Shtepa 2022-12-09 41 int ctrl_init(void)
2c91bb136c2522 Sergei Shtepa 2022-12-09 42 {
2c91bb136c2522 Sergei Shtepa 2022-12-09 43 int ret;
2c91bb136c2522 Sergei Shtepa 2022-12-09 44
2c91bb136c2522 Sergei Shtepa 2022-12-09 @45 ret = register_chrdev(0, THIS_MODULE->name, &ctrl_fops);
2c91bb136c2522 Sergei Shtepa 2022-12-09 46 if (ret < 0) {
2c91bb136c2522 Sergei Shtepa 2022-12-09 47 pr_err("Failed to register a character device. errno=%d\n",
2c91bb136c2522 Sergei Shtepa 2022-12-09 48 abs(blk_snap_major));
2c91bb136c2522 Sergei Shtepa 2022-12-09 49 return ret;
2c91bb136c2522 Sergei Shtepa 2022-12-09 50 }
2c91bb136c2522 Sergei Shtepa 2022-12-09 51
2c91bb136c2522 Sergei Shtepa 2022-12-09 52 blk_snap_major = ret;
2c91bb136c2522 Sergei Shtepa 2022-12-09 53 pr_info("Register control device [%d:0].\n", blk_snap_major);
2c91bb136c2522 Sergei Shtepa 2022-12-09 54 return 0;
2c91bb136c2522 Sergei Shtepa 2022-12-09 55 }
2c91bb136c2522 Sergei Shtepa 2022-12-09 56
--
0-DAY CI Kernel Test Service
https://01.org/lkp
View attachment "config" of type "text/plain" (215056 bytes)
Powered by blists - more mailing lists