drivers/block/drbd/drbd_bitmap.c:451:7: warning: expression result unused

kernel test robot
2023-06-29T11:52:27Z

head: 3a8a670eeeaa40d87bd38a587438952741980c18
commit: aa034695971124f673d4ccdd39cd7f269904ea86 drbd: introduce dynamic debug
date: 7 months ago
config: i386-randconfig-r024-20230629 (https://download.01.org/0day-ci/archive/20230629/202306291938.pFaPlXRt-lkp@intel.com/config)
compiler: clang version 15.0.7 (https://github.com/llvm/llvm-project.git 8dfdcc7b7bf66834a761bd8de445840ef68e4d1a)
reproduce: (https://download.01.org/0day-ci/archive/20230629/202306291938.pFaPlXRt-lkp@intel.com/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@intel.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202306291938.pFaPlXRt-lkp@intel.com/

All warnings (new ones prefixed by >>):

>> drivers/block/drbd/drbd_bitmap.c:451:7: warning: expression result unused [-Wunused-value]
if (!expect(device->bitmap))
~~~~~^~~~~~~~~~~~~~~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
drivers/block/drbd/drbd_polymorph_printk.h:55:47: note: expanded from macro '__drbd_printk_if_same_type'
__drbd_printk_choose_cond(obj, struct_name), \
^
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:58:52: note: expanded from macro '__trace_if_var'
#define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
^~~~
>> drivers/block/drbd/drbd_bitmap.c:451:7: warning: expression result unused [-Wunused-value]
if (!expect(device->bitmap))
~~~~~^~~~~~~~~~~~~~~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
note: (skipping 1 expansions in backtrace; use -fmacro-backtrace-limit=0 to see all)
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:58:86: note: expanded from macro '__trace_if_var'
#define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
~~~~~~~~~~~~~~~~~^~~~~
include/linux/compiler.h:69:3: note: expanded from macro '__trace_if_value'
(cond) ? \
^~~~
drivers/block/drbd/drbd_bitmap.c:460:7: warning: expression result unused [-Wunused-value]
if (!expect(device->bitmap))
~~~~~^~~~~~~~~~~~~~~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
drivers/block/drbd/drbd_polymorph_printk.h:55:47: note: expanded from macro '__drbd_printk_if_same_type'
__drbd_printk_choose_cond(obj, struct_name), \
^
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:58:52: note: expanded from macro '__trace_if_var'
#define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
^~~~
drivers/block/drbd/drbd_bitmap.c:460:7: warning: expression result unused [-Wunused-value]
if (!expect(device->bitmap))
~~~~~^~~~~~~~~~~~~~~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
note: (skipping 1 expansions in backtrace; use -fmacro-backtrace-limit=0 to see all)
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:58:86: note: expanded from macro '__trace_if_var'
#define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
~~~~~~~~~~~~~~~~~^~~~~
include/linux/compiler.h:69:3: note: expanded from macro '__trace_if_value'
(cond) ? \
^~~~
drivers/block/drbd/drbd_bitmap.c:639:7: warning: expression result unused [-Wunused-value]
if (!expect(b))
~~~~~^~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
drivers/block/drbd/drbd_polymorph_printk.h:55:47: note: expanded from macro '__drbd_printk_if_same_type'
__drbd_printk_choose_cond(obj, struct_name), \
^
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:58:52: note: expanded from macro '__trace_if_var'
#define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
^~~~
drivers/block/drbd/drbd_bitmap.c:639:7: warning: expression result unused [-Wunused-value]
if (!expect(b))
~~~~~^~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
note: (skipping 1 expansions in backtrace; use -fmacro-backtrace-limit=0 to see all)
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
--
>> drivers/block/drbd/drbd_actlog.c:871:7: warning: expression result unused [-Wunused-value]
if (!expect(sector < nr_sectors))
~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
drivers/block/drbd/drbd_polymorph_printk.h:55:47: note: expanded from macro '__drbd_printk_if_same_type'
__drbd_printk_choose_cond(obj, struct_name), \
^
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:58:52: note: expanded from macro '__trace_if_var'
#define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
^~~~
>> drivers/block/drbd/drbd_actlog.c:871:7: warning: expression result unused [-Wunused-value]
if (!expect(sector < nr_sectors))
~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
note: (skipping 1 expansions in backtrace; use -fmacro-backtrace-limit=0 to see all)
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:58:86: note: expanded from macro '__trace_if_var'
#define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
~~~~~~~~~~~~~~~~~^~~~~
include/linux/compiler.h:69:3: note: expanded from macro '__trace_if_value'
(cond) ? \
^~~~
drivers/block/drbd/drbd_actlog.c:873:7: warning: expression result unused [-Wunused-value]
if (!expect(esector < nr_sectors))
~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
drivers/block/drbd/drbd_polymorph_printk.h:55:47: note: expanded from macro '__drbd_printk_if_same_type'
__drbd_printk_choose_cond(obj, struct_name), \
^
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:58:52: note: expanded from macro '__trace_if_var'
#define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
^~~~
drivers/block/drbd/drbd_actlog.c:873:7: warning: expression result unused [-Wunused-value]
if (!expect(esector < nr_sectors))
~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
note: (skipping 1 expansions in backtrace; use -fmacro-backtrace-limit=0 to see all)
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:58:86: note: expanded from macro '__trace_if_var'
#define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
~~~~~~~~~~~~~~~~~^~~~~
include/linux/compiler.h:69:3: note: expanded from macro '__trace_if_value'
(cond) ? \
^~~~
4 warnings generated.
--
In file included from drivers/block/drbd/drbd_nl.c:78:
include/linux/genl_magic_func.h:212:13: warning: no previous prototype for function 'drbd_genl_cmd_to_str' [-Wmissing-prototypes]
const char *CONCAT_(GENL_MAGIC_FAMILY, _genl_cmd_to_str)(__u8 cmd)
^
include/linux/genl_magic_struct.h:21:22: note: expanded from macro 'CONCAT_'
#define CONCAT_(a,b) CONCAT__(a,b)
^
include/linux/genl_magic_struct.h:20:23: note: expanded from macro 'CONCAT__'
#define CONCAT__(a,b) a ## b
^
<scratch space>:97:1: note: expanded from here
drbd_genl_cmd_to_str
^
include/linux/genl_magic_func.h:212:7: note: declare 'static' if the function is not intended to be used outside of this translation unit
const char *CONCAT_(GENL_MAGIC_FAMILY, _genl_cmd_to_str)(__u8 cmd)
^
static
>> drivers/block/drbd/drbd_nl.c:1546:7: warning: expression result unused [-Wunused-value]
if (!expect(new_disk_conf->resync_rate >= 1))
~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
drivers/block/drbd/drbd_polymorph_printk.h:55:47: note: expanded from macro '__drbd_printk_if_same_type'
__drbd_printk_choose_cond(obj, struct_name), \
^
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:58:52: note: expanded from macro '__trace_if_var'
#define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
^~~~
>> drivers/block/drbd/drbd_nl.c:1546:7: warning: expression result unused [-Wunused-value]
if (!expect(new_disk_conf->resync_rate >= 1))
~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
note: (skipping 1 expansions in backtrace; use -fmacro-backtrace-limit=0 to see all)
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:58:86: note: expanded from macro '__trace_if_var'
#define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
~~~~~~~~~~~~~~~~~^~~~~
include/linux/compiler.h:69:3: note: expanded from macro '__trace_if_value'
(cond) ? \
^~~~
3 warnings generated.
--
>> drivers/block/drbd/drbd_receiver.c:416:7: warning: expression result unused [-Wunused-value]
if (!expect(!(peer_req->flags & EE_CALL_AL_COMPLETE_IO))) {
~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
drivers/block/drbd/drbd_polymorph_printk.h:55:47: note: expanded from macro '__drbd_printk_if_same_type'
__drbd_printk_choose_cond(obj, struct_name), \
^
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:58:52: note: expanded from macro '__trace_if_var'
#define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
^~~~
>> drivers/block/drbd/drbd_receiver.c:416:7: warning: expression result unused [-Wunused-value]
if (!expect(!(peer_req->flags & EE_CALL_AL_COMPLETE_IO))) {
~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
note: (skipping 1 expansions in backtrace; use -fmacro-backtrace-limit=0 to see all)
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:58:86: note: expanded from macro '__trace_if_var'
#define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
~~~~~~~~~~~~~~~~~^~~~~
include/linux/compiler.h:69:3: note: expanded from macro '__trace_if_value'
(cond) ? \
^~~~
drivers/block/drbd/drbd_receiver.c:1876:8: warning: expression result unused [-Wunused-value]
if (!expect(data_size == 0))
~~~~~^~~~~~~~~~~~~~~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
drivers/block/drbd/drbd_polymorph_printk.h:55:47: note: expanded from macro '__drbd_printk_if_same_type'
__drbd_printk_choose_cond(obj, struct_name), \
^
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:58:52: note: expanded from macro '__trace_if_var'
#define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
^~~~
drivers/block/drbd/drbd_receiver.c:1876:8: warning: expression result unused [-Wunused-value]
if (!expect(data_size == 0))
~~~~~^~~~~~~~~~~~~~~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
note: (skipping 1 expansions in backtrace; use -fmacro-backtrace-limit=0 to see all)
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:58:86: note: expanded from macro '__trace_if_var'
#define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
~~~~~~~~~~~~~~~~~^~~~~
include/linux/compiler.h:69:3: note: expanded from macro '__trace_if_value'
(cond) ? \
^~~~
drivers/block/drbd/drbd_receiver.c:1880:8: warning: expression result unused [-Wunused-value]
if (!expect(data_size == 0))
~~~~~^~~~~~~~~~~~~~~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
drivers/block/drbd/drbd_polymorph_printk.h:55:47: note: expanded from macro '__drbd_printk_if_same_type'
__drbd_printk_choose_cond(obj, struct_name), \
^
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
~~~~~~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
include/linux/compiler.h:58:52: note: expanded from macro '__trace_if_var'
#define __trace_if_var(cond) (__builtin_constant_p(cond) ? (cond) : __trace_if_value(cond))
^~~~
drivers/block/drbd/drbd_receiver.c:1880:8: warning: expression result unused [-Wunused-value]
if (!expect(data_size == 0))
~~~~~^~~~~~~~~~~~~~~~~~~~~~~
drivers/block/drbd/drbd_polymorph_printk.h:128:4: note: expanded from macro 'expect'
drbd_err(device, "ASSERTION %s FAILED in %s\n", \
^
drivers/block/drbd/drbd_polymorph_printk.h:104:2: note: expanded from macro 'drbd_err'
drbd_printk(KERN_ERR, device, fmt, ## args)
^
drivers/block/drbd/drbd_polymorph_printk.h:65:4: note: expanded from macro 'drbd_printk'
__drbd_printk_if_same_type(obj, drbd_device, level, fmt, ## args), \
^
note: (skipping 1 expansions in backtrace; use -fmacro-backtrace-limit=0 to see all)
include/linux/compiler.h:56:47: note: expanded from macro 'if'
#define if(cond, ...) if ( __trace_if_var( !!(cond , ## __VA_ARGS__) ) )
..

vim +451 drivers/block/drbd/drbd_bitmap.c

b411b3637fa71f Philipp Reisner 2009-09-25 448
b30ab7913b0a7b Andreas Gruenbacher 2011-07-03 449 sector_t drbd_bm_capacity(struct drbd_device *device)
b411b3637fa71f Philipp Reisner 2009-09-25 450 {
b30ab7913b0a7b Andreas Gruenbacher 2011-07-03 @451 if (!expect(device->bitmap))
841ce241fa3550 Andreas Gruenbacher 2010-12-15 452 return 0;
b30ab7913b0a7b Andreas Gruenbacher 2011-07-03 453 return device->bitmap->bm_dev_capacity;
b411b3637fa71f Philipp Reisner 2009-09-25 454 }
b411b3637fa71f Philipp Reisner 2009-09-25 455

:::::: The code at line 451 was first introduced by commit
:::::: b30ab7913b0a7b1d3b1091c8cb3abb1a9f1e0824 drbd: Rename "mdev" to "device"

:::::: TO: Andreas Gruenbacher <agruen@linbit.com>
:::::: CC: Philipp Reisner <philipp.reisner@linbit.com>

--
0-DAY CI Kernel Test Service