lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [day] [month] [year] [list]
Message-ID: <202407310922.Mkw2WfT2-lkp@intel.com>
Date: Wed, 31 Jul 2024 09:56:27 +0800
From: kernel test robot <lkp@...el.com>
To: "Gustavo A. R. Silva" <gustavoars@...nel.org>
Cc: llvm@...ts.linux.dev, oe-kbuild-all@...ts.linux.dev,
	"Gustavo A. R. Silva" <gustavo@...eddedor.com>,
	LKML <linux-kernel@...r.kernel.org>
Subject: [gustavoars:testing/wfamnae-next20240729-cbc 8/9]
 include/uapi/scsi/fc/fc_els.h:1131:15: error: expected parameter declarator

tree:   https://git.kernel.org/pub/scm/linux/kernel/git/gustavoars/linux.git testing/wfamnae-next20240729-cbc
head:   303f7de5e5f60dfc378b9a32a201110936b43d83
commit: d9b68641e04510cbd540f81b8ef4379e4d26e201 [8/9] scsi: fc: Avoid -Wflex-array-member-not-at-end warnings
config: s390-allmodconfig (https://download.01.org/0day-ci/archive/20240731/202407310922.Mkw2WfT2-lkp@intel.com/config)
compiler: clang version 20.0.0git (https://github.com/llvm/llvm-project ccae7b461be339e717d02f99ac857cf0bc7d17fc)
reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20240731/202407310922.Mkw2WfT2-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@...el.com>
| Closes: https://lore.kernel.org/oe-kbuild-all/202407310922.Mkw2WfT2-lkp@intel.com/

All errors (new ones prefixed by >>):

   In file included from drivers/scsi/libfc/fc_elsct.c:16:
>> include/uapi/scsi/fc/fc_els.h:1131:15: error: expected parameter declarator
    1131 | static_assert(offsetof(struct fc_df_desc_fpin_reg, desc_tags) == sizeof(struct fc_df_desc_fpin_reg_hdr),
         |               ^
   include/linux/stddef.h:16:32: note: expanded from macro 'offsetof'
      16 | #define offsetof(TYPE, MEMBER)  __builtin_offsetof(TYPE, MEMBER)
         |                                 ^
   In file included from drivers/scsi/libfc/fc_elsct.c:16:
>> include/uapi/scsi/fc/fc_els.h:1131:15: error: expected ')'
   include/linux/stddef.h:16:32: note: expanded from macro 'offsetof'
      16 | #define offsetof(TYPE, MEMBER)  __builtin_offsetof(TYPE, MEMBER)
         |                                 ^
   include/uapi/scsi/fc/fc_els.h:1131:14: note: to match this '('
    1131 | static_assert(offsetof(struct fc_df_desc_fpin_reg, desc_tags) == sizeof(struct fc_df_desc_fpin_reg_hdr),
         |              ^
>> include/uapi/scsi/fc/fc_els.h:1131:1: error: type specifier missing, defaults to 'int'; ISO C99 and later do not support implicit int [-Wimplicit-int]
    1131 | static_assert(offsetof(struct fc_df_desc_fpin_reg, desc_tags) == sizeof(struct fc_df_desc_fpin_reg_hdr),
         | ^
         | int
>> include/uapi/scsi/fc/fc_els.h:1131:14: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes]
    1131 | static_assert(offsetof(struct fc_df_desc_fpin_reg, desc_tags) == sizeof(struct fc_df_desc_fpin_reg_hdr),
         |              ^
    1132 |               "struct member likely outside of __struct_group()");
         |                                                                 
         |                                                                 void
   include/uapi/scsi/fc/fc_els.h:1149:15: error: expected parameter declarator
    1149 | static_assert(offsetof(struct fc_els_rdf, desc) == sizeof(struct fc_els_rdf_hdr),
         |               ^
   include/linux/stddef.h:16:32: note: expanded from macro 'offsetof'
      16 | #define offsetof(TYPE, MEMBER)  __builtin_offsetof(TYPE, MEMBER)
         |                                 ^
   In file included from drivers/scsi/libfc/fc_elsct.c:16:
   include/uapi/scsi/fc/fc_els.h:1149:15: error: expected ')'
   include/linux/stddef.h:16:32: note: expanded from macro 'offsetof'
      16 | #define offsetof(TYPE, MEMBER)  __builtin_offsetof(TYPE, MEMBER)
         |                                 ^
   include/uapi/scsi/fc/fc_els.h:1149:14: note: to match this '('
    1149 | static_assert(offsetof(struct fc_els_rdf, desc) == sizeof(struct fc_els_rdf_hdr),
         |              ^
   include/uapi/scsi/fc/fc_els.h:1149:1: error: type specifier missing, defaults to 'int'; ISO C99 and later do not support implicit int [-Wimplicit-int]
    1149 | static_assert(offsetof(struct fc_els_rdf, desc) == sizeof(struct fc_els_rdf_hdr),
         | ^
         | int
   include/uapi/scsi/fc/fc_els.h:1149:14: error: a function declaration without a prototype is deprecated in all versions of C [-Werror,-Wstrict-prototypes]
    1149 | static_assert(offsetof(struct fc_els_rdf, desc) == sizeof(struct fc_els_rdf_hdr),
         |              ^
    1150 |               "struct member likely outside of __struct_group()");
         |                                                                 
         |                                                                 void
   In file included from drivers/scsi/libfc/fc_elsct.c:17:
   In file included from include/scsi/libfc.h:16:
   In file included from include/scsi/scsi_transport.h:10:
   In file included from include/linux/transport_class.h:11:
   In file included from include/linux/device.h:32:
   In file included from include/linux/device/driver.h:21:
   In file included from include/linux/module.h:19:
   In file included from include/linux/elf.h:6:
   In file included from arch/s390/include/asm/elf.h:168:
   In file included from include/linux/compat.h:17:
   In file included from include/linux/fs.h:33:
   In file included from include/linux/percpu-rwsem.h:7:
   In file included from include/linux/rcuwait.h:6:
   In file included from include/linux/sched/signal.h:6:
   include/linux/signal.h:98:11: warning: array index 3 is past the end of the array (that has type 'unsigned long[1]') [-Warray-bounds]
      98 |                 return (set->sig[3] | set->sig[2] |
         |                         ^        ~
   arch/s390/include/asm/signal.h:22:9: note: array 'sig' declared here
      22 |         unsigned long sig[_NSIG_WORDS];
         |         ^
   In file included from drivers/scsi/libfc/fc_elsct.c:17:
   In file included from include/scsi/libfc.h:16:
   In file included from include/scsi/scsi_transport.h:10:
   In file included from include/linux/transport_class.h:11:
   In file included from include/linux/device.h:32:
   In file included from include/linux/device/driver.h:21:
   In file included from include/linux/module.h:19:
   In file included from include/linux/elf.h:6:
   In file included from arch/s390/include/asm/elf.h:168:
   In file included from include/linux/compat.h:17:
   In file included from include/linux/fs.h:33:
   In file included from include/linux/percpu-rwsem.h:7:
   In file included from include/linux/rcuwait.h:6:
   In file included from include/linux/sched/signal.h:6:
   include/linux/signal.h:98:25: warning: array index 2 is past the end of the array (that has type 'unsigned long[1]') [-Warray-bounds]
      98 |                 return (set->sig[3] | set->sig[2] |
         |                                       ^        ~
   arch/s390/include/asm/signal.h:22:9: note: array 'sig' declared here
      22 |         unsigned long sig[_NSIG_WORDS];
         |         ^
   In file included from drivers/scsi/libfc/fc_elsct.c:17:
   In file included from include/scsi/libfc.h:16:
   In file included from include/scsi/scsi_transport.h:10:
   In file included from include/linux/transport_class.h:11:
   In file included from include/linux/device.h:32:
   In file included from include/linux/device/driver.h:21:
   In file included from include/linux/module.h:19:
   In file included from include/linux/elf.h:6:
   In file included from arch/s390/include/asm/elf.h:168:
   In file included from include/linux/compat.h:17:
   In file included from include/linux/fs.h:33:
   In file included from include/linux/percpu-rwsem.h:7:
   In file included from include/linux/rcuwait.h:6:
   In file included from include/linux/sched/signal.h:6:
   include/linux/signal.h:99:4: warning: array index 1 is past the end of the array (that has type 'unsigned long[1]') [-Warray-bounds]
      99 |                         set->sig[1] | set->sig[0]) == 0;
         |                         ^        ~
   arch/s390/include/asm/signal.h:22:9: note: array 'sig' declared here
      22 |         unsigned long sig[_NSIG_WORDS];
         |         ^
   In file included from drivers/scsi/libfc/fc_elsct.c:17:
   In file included from include/scsi/libfc.h:16:
   In file included from include/scsi/scsi_transport.h:10:
   In file included from include/linux/transport_class.h:11:
   In file included from include/linux/device.h:32:
   In file included from include/linux/device/driver.h:21:
   In file included from include/linux/module.h:19:
   In file included from include/linux/elf.h:6:
   In file included from arch/s390/include/asm/elf.h:168:
   In file included from include/linux/compat.h:17:
   In file included from include/linux/fs.h:33:


vim +1131 include/uapi/scsi/fc/fc_els.h

  1110	
  1111	/* Diagnostic Function Descriptor - FPIN Registration */
  1112	struct fc_df_desc_fpin_reg {
  1113		/* New members MUST be added within the __struct_group() macro below. */
  1114		__struct_group(fc_df_desc_fpin_reg_hdr, hdr, /* no attrs */,
  1115			__be32		desc_tag; /* FPIN Registration (0x00030001) */
  1116			__be32		desc_len; /* Length of Descriptor (in bytes).
  1117						   * Size of descriptor excluding
  1118						   * desc_tag and desc_len fields.
  1119						   */
  1120			__be32		count;	  /* Number of desc_tags elements */
  1121		);
  1122		__be32		desc_tags[];	/* Array of Descriptor Tags.
  1123						 * Each tag indicates a function
  1124						 * supported by the N_Port (request)
  1125						 * or by the  N_Port and Fabric
  1126						 * Controller (reply; may be a subset
  1127						 * of the request).
  1128						 * See ELS_FN_DTAG_xxx for tag values.
  1129						 */
  1130	};
> 1131	static_assert(offsetof(struct fc_df_desc_fpin_reg, desc_tags) == sizeof(struct fc_df_desc_fpin_reg_hdr),
  1132		      "struct member likely outside of __struct_group()");
  1133	

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

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ