Re: [PATCH] z3fold: don't fail kernel build if z3fold_header is too big

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

 



Hi Vitaly,

[auto build test WARNING on mmotm/master]
[also build test WARNING on v4.9-rc4 next-20161110]
[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/Vitaly-Wool/z3fold-don-t-fail-kernel-build-if-z3fold_header-is-too-big/20161110-161657
base:   git://git.cmpxchg.org/linux-mmotm.git master
config: x86_64-randconfig-x014-201645 (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=x86_64 

All warnings (new ones prefixed by >>):

   In file included from include/linux/printk.h:6:0,
                    from include/linux/kernel.h:13,
                    from include/linux/list.h:8,
                    from mm/z3fold.c:26:
   mm/z3fold.c: In function 'init_z3fold':
   include/linux/kern_levels.h:4:18: warning: format '%d' expects argument of type 'int', but argument 2 has type 'long unsigned int' [-Wformat=]
    #define KERN_SOH "\001"  /* ASCII Start Of Header */
                     ^
   include/linux/kern_levels.h:10:18: note: in expansion of macro 'KERN_SOH'
    #define KERN_ERR KERN_SOH "3" /* error conditions */
                     ^~~~~~~~
   include/linux/printk.h:277:9: note: in expansion of macro 'KERN_ERR'
     printk(KERN_ERR pr_fmt(fmt), ##__VA_ARGS__)
            ^~~~~~~~
>> mm/z3fold.c:817:3: note: in expansion of macro 'pr_err'
      pr_err("z3fold: z3fold_header size (%d) is bigger than "
      ^~~~~~

vim +/pr_err +817 mm/z3fold.c

   801		.create =	z3fold_zpool_create,
   802		.destroy =	z3fold_zpool_destroy,
   803		.malloc =	z3fold_zpool_malloc,
   804		.free =		z3fold_zpool_free,
   805		.shrink =	z3fold_zpool_shrink,
   806		.map =		z3fold_zpool_map,
   807		.unmap =	z3fold_zpool_unmap,
   808		.total_size =	z3fold_zpool_total_size,
   809	};
   810	
   811	MODULE_ALIAS("zpool-z3fold");
   812	
   813	static int __init init_z3fold(void)
   814	{
   815		/* Fail the initialization if z3fold header won't fit in one chunk */
   816		if (sizeof(struct z3fold_header) > ZHDR_SIZE_ALIGNED) {
 > 817			pr_err("z3fold: z3fold_header size (%d) is bigger than "
   818				"the chunk size (%d), can't proceed\n",
   819				sizeof(struct z3fold_header) , ZHDR_SIZE_ALIGNED);
   820			return -E2BIG;
   821		}
   822	
   823		zpool_register_driver(&z3fold_zpool_driver);
   824		return 0;
   825	}

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

Attachment: .config.gz
Description: application/gzip


[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]