Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1583853

Re: [PATCH v2 3/3] Make vmbus register arguments read-only

From kbuild test robot <lkp@intel.com>
Newsgroups linux.kernel
Subject Re: [PATCH v2 3/3] Make vmbus register arguments read-only
Date 2017-02-18 07:40 +0100
Message-ID <tc6Qy-6G5-5@gated-at.bofh.it> (permalink)
References <tc6nv-6t9-1@gated-at.bofh.it>
Organization linux.* mail to news gateway

Show all headers | View raw


[Multipart message — attachments visible in raw view] - view raw

Hi Eddie,

[auto build test WARNING on linus/master]
[also build test WARNING on v4.10-rc8 next-20170217]
[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/Eddie-Kovsky/provide-check-for-ro_after_init-memory-sections/20170218-141040
config: i386-randconfig-x007-201707 (attached as .config)
compiler: gcc-6 (Debian 6.2.0-3) 6.2.0 20160901
reproduce:
        # save the attached .config to linux build tree
        make ARCH=i386 

All warnings (new ones prefixed by >>):

   drivers/hv/vmbus_drv.c: In function '__vmbus_driver_register':
>> drivers/hv/vmbus_drv.c:1056:26: warning: passing argument 1 of 'kernel_ro_address' makes integer from pointer without a cast [-Wint-conversion]
     ret = kernel_ro_address(&hv_driver);
                             ^
   In file included from include/linux/list.h:8:0,
                    from include/linux/module.h:9,
                    from drivers/hv/vmbus_drv.c:26:
   include/linux/kernel.h:446:12: note: expected 'long unsigned int' but argument is of type 'struct hv_driver **'
    extern int kernel_ro_address(unsigned long addr);
               ^~~~~~~~~~~~~~~~~
   drivers/hv/vmbus_drv.c: In function 'vmbus_device_register':
   drivers/hv/vmbus_drv.c:1127:26: warning: passing argument 1 of 'kernel_ro_address' makes integer from pointer without a cast [-Wint-conversion]
     ret = kernel_ro_address(&child_device_obj);
                             ^
   In file included from include/linux/list.h:8:0,
                    from include/linux/module.h:9,
                    from drivers/hv/vmbus_drv.c:26:
   include/linux/kernel.h:446:12: note: expected 'long unsigned int' but argument is of type 'struct hv_device **'
    extern int kernel_ro_address(unsigned long addr);
               ^~~~~~~~~~~~~~~~~

vim +/kernel_ro_address +1056 drivers/hv/vmbus_drv.c

  1040	 *
  1041	 * Registers the given driver with Linux through the 'driver_register()' call
  1042	 * and sets up the hyper-v vmbus handling for this driver.
  1043	 * It will return the state of the 'driver_register()' call.
  1044	 *
  1045	 */
  1046	int __vmbus_driver_register(struct hv_driver *hv_driver, struct module *owner, const char *mod_name)
  1047	{
  1048		int ret;
  1049	
  1050		pr_info("registering driver %s\n", hv_driver->name);
  1051	
  1052		ret = vmbus_exists();
  1053		if (ret < 0)
  1054			return ret;
  1055	
> 1056		ret = kernel_ro_address(&hv_driver);
  1057		if (ret < 1)
  1058			pr_err("Module address is not read-only.");
  1059			return ret;
  1060	
  1061		hv_driver->driver.name = hv_driver->name;
  1062		hv_driver->driver.owner = owner;
  1063		hv_driver->driver.mod_name = mod_name;
  1064		hv_driver->driver.bus = &hv_bus;

---
0-DAY kernel test infrastructure                Open Source Technology Center
https://lists.01.org/pipermail/kbuild-all                   Intel Corporation

Back to linux.kernel | Previous | NextPrevious in thread | Find similar | Unroll thread


Thread

[PATCH v2 3/3] Make vmbus register arguments read-only Eddie Kovsky <ewk@edkovsky.org> - 2017-02-18 07:10 +0100
  Re: [PATCH v2 3/3] Make vmbus register arguments read-only kbuild test robot <lkp@intel.com> - 2017-02-18 07:40 +0100

csiph-web