Content-Type: multipart/mixed; boundary="===============2092123396963723955==" MIME-Version: 1.0 From: Kees Cook To: kbuild-all@lists.01.org Subject: Re: include/linux/fortify-string.h:267:25: warning: call to '__write_overflow_field' declared with attribute warning: detected write beyond size of field (1st parameter); maybe use struct_group()? Date: Mon, 18 Apr 2022 21:19:09 -0700 Message-ID: <202204182118.5EB742C6@keescook> In-Reply-To: <202204142318.vDqjjSFn-lkp@intel.com> List-Id: --===============2092123396963723955== Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable On Thu, Apr 14, 2022 at 11:54:03PM +0800, kernel test robot wrote: > In function 'fortify_memcpy_chk', > inlined from 'firm_send_command' at drivers/usb/serial/whiteheat.c= :587:4: > >> include/linux/fortify-string.h:267:25: warning: call to '__write_overf= low_field' declared with attribute warning: detected write beyond size of f= ield (1st parameter); maybe use struct_group()? [-Wattribute-warning] > 267 | __write_overflow_field(p_size_field, s= ize); > | ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~= ~~~~ Thanks! Proposed patch: https://lore.kernel.org/linux-hardening/20220419041742.4117026-1-keescook(a= )chromium.org/ -- = Kees Cook --===============2092123396963723955==--