All of lore.kernel.org
 help / color / mirror / Atom feed
* [thomas-weissschuh:b4/b4-sysfs-const-bin_attr-cb 106/107] drivers/s390/cio/chp.c:157:26: error: initialization of 'ssize_t (*)(struct file *, struct kobject *, const struct bin_attribute *, char *, loff_t, size_t)' {aka 'long int (*)(struct file *, struct kobject *, const struct bin_attribute *, char *, long lo...
@ 2024-12-22 23:25 kernel test robot
  0 siblings, 0 replies; only message in thread
From: kernel test robot @ 2024-12-22 23:25 UTC (permalink / raw)
  To: Thomas Weißschuh; +Cc: oe-kbuild-all

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/thomas.weissschuh/linux.git b4/b4-sysfs-const-bin_attr-cb
head:   8db3706541f19807373f27aa92d17a30c7092993
commit: dd1c32ee4842fb19b7fc433388b5e6071e135440 [106/107] read/write
config: s390-randconfig-002-20241223 (https://download.01.org/0day-ci/archive/20241223/202412230708.txWWTehv-lkp@intel.com/config)
compiler: s390-linux-gcc (GCC) 14.2.0
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20241223/202412230708.txWWTehv-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/202412230708.txWWTehv-lkp@intel.com/

All errors (new ones prefixed by >>):

   In file included from include/linux/kobject.h:20,
                    from include/linux/energy_model.h:7,
                    from include/linux/device.h:16,
                    from drivers/s390/cio/cio.h:6,
                    from drivers/s390/cio/chp.c:24:
>> drivers/s390/cio/chp.c:157:26: error: initialization of 'ssize_t (*)(struct file *, struct kobject *, const struct bin_attribute *, char *, loff_t,  size_t)' {aka 'long int (*)(struct file *, struct kobject *, const struct bin_attribute *, char *, long long int,  long unsigned int)'} from incompatible pointer type 'ssize_t (*)(struct file *, struct kobject *, struct bin_attribute *, char *, loff_t,  size_t)' {aka 'long int (*)(struct file *, struct kobject *, struct bin_attribute *, char *, long long int,  long unsigned int)'} [-Wincompatible-pointer-types]
     157 | static BIN_ATTR_ADMIN_RO(measurement_chars_full, sizeof(struct cmg_cmcb));
         |                          ^~~~~~~~~~~~~~~~~~~~~~
   include/linux/sysfs.h:338:17: note: in definition of macro '__BIN_ATTR'
     338 |         .read = _read,                                                  \
         |                 ^~~~~
   include/linux/sysfs.h:378:41: note: in expansion of macro '__BIN_ATTR_ADMIN_RO'
     378 | struct bin_attribute bin_attr_##_name = __BIN_ATTR_ADMIN_RO(_name, _size)
         |                                         ^~~~~~~~~~~~~~~~~~~
   drivers/s390/cio/chp.c:157:8: note: in expansion of macro 'BIN_ATTR_ADMIN_RO'
     157 | static BIN_ATTR_ADMIN_RO(measurement_chars_full, sizeof(struct cmg_cmcb));
         |        ^~~~~~~~~~~~~~~~~
   drivers/s390/cio/chp.c:157:26: note: (near initialization for 'bin_attr_measurement_chars_full.read')
     157 | static BIN_ATTR_ADMIN_RO(measurement_chars_full, sizeof(struct cmg_cmcb));
         |                          ^~~~~~~~~~~~~~~~~~~~~~
   include/linux/sysfs.h:338:17: note: in definition of macro '__BIN_ATTR'
     338 |         .read = _read,                                                  \
         |                 ^~~~~
   include/linux/sysfs.h:378:41: note: in expansion of macro '__BIN_ATTR_ADMIN_RO'
     378 | struct bin_attribute bin_attr_##_name = __BIN_ATTR_ADMIN_RO(_name, _size)
         |                                         ^~~~~~~~~~~~~~~~~~~
   drivers/s390/cio/chp.c:157:8: note: in expansion of macro 'BIN_ATTR_ADMIN_RO'
     157 | static BIN_ATTR_ADMIN_RO(measurement_chars_full, sizeof(struct cmg_cmcb));
         |        ^~~~~~~~~~~~~~~~~
   drivers/s390/cio/chp.c:221:22: error: initialization of 'struct bin_attribute **' from incompatible pointer type 'const struct bin_attribute * const*' [-Wincompatible-pointer-types]
     221 | BIN_ATTRIBUTE_GROUPS(measurement);
         |                      ^~~~~~~~~~~
   include/linux/sysfs.h:296:22: note: in definition of macro 'BIN_ATTRIBUTE_GROUPS'
     296 |         .bin_attrs = _name##_attrs,                             \
         |                      ^~~~~
   drivers/s390/cio/chp.c:221:22: note: (near initialization for 'measurement_group.<anonymous>.bin_attrs')
     221 | BIN_ATTRIBUTE_GROUPS(measurement);
         |                      ^~~~~~~~~~~
   include/linux/sysfs.h:296:22: note: in definition of macro 'BIN_ATTRIBUTE_GROUPS'
     296 |         .bin_attrs = _name##_attrs,                             \
         |                      ^~~~~


vim +157 drivers/s390/cio/chp.c

e6b6e10ac1de11 Peter Oberparleiter 2007-04-27  146  
2f4b3b83b8c6e7 Peter Oberparleiter 2024-11-07  147  static ssize_t measurement_chars_full_read(struct file *filp,
2f4b3b83b8c6e7 Peter Oberparleiter 2024-11-07  148  					   struct kobject *kobj,
2f4b3b83b8c6e7 Peter Oberparleiter 2024-11-07  149  					   struct bin_attribute *bin_attr,
2f4b3b83b8c6e7 Peter Oberparleiter 2024-11-07  150  					   char *buf, loff_t off, size_t count)
2f4b3b83b8c6e7 Peter Oberparleiter 2024-11-07  151  {
2f4b3b83b8c6e7 Peter Oberparleiter 2024-11-07  152  	struct channel_path *chp = to_channelpath(kobj_to_dev(kobj));
2f4b3b83b8c6e7 Peter Oberparleiter 2024-11-07  153  
2f4b3b83b8c6e7 Peter Oberparleiter 2024-11-07  154  	return memory_read_from_buffer(buf, count, &off, &chp->cmcb,
2f4b3b83b8c6e7 Peter Oberparleiter 2024-11-07  155  				       sizeof(chp->cmcb));
2f4b3b83b8c6e7 Peter Oberparleiter 2024-11-07  156  }
2f4b3b83b8c6e7 Peter Oberparleiter 2024-11-07 @157  static BIN_ATTR_ADMIN_RO(measurement_chars_full, sizeof(struct cmg_cmcb));
2f4b3b83b8c6e7 Peter Oberparleiter 2024-11-07  158  

:::::: The code at line 157 was first introduced by commit
:::::: 2f4b3b83b8c6e798a2e581521f00933d0f9ec777 s390/cio: Externalize full CMG characteristics

:::::: TO: Peter Oberparleiter <oberpar@linux.ibm.com>
:::::: CC: Heiko Carstens <hca@linux.ibm.com>

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

^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2024-12-22 23:26 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-12-22 23:25 [thomas-weissschuh:b4/b4-sysfs-const-bin_attr-cb 106/107] drivers/s390/cio/chp.c:157:26: error: initialization of 'ssize_t (*)(struct file *, struct kobject *, const struct bin_attribute *, char *, loff_t, size_t)' {aka 'long int (*)(struct file *, struct kobject *, const struct bin_attribute *, char *, long lo kernel test robot

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.