wrc1944 wrote:Guess we can still try patching in 5011 ourselves, but I did have those 4 warnings with 5.1.0, even though 5.1.0 does seem to function OK on 2 of my Gentoo systems with gcc-9.1.0 and 5011.
Warnings are not related to experimental patching.
Wasn't lazy and I just tried to compile with and without cpu optimizations patch.
In both cases I get the same warning, and it's the only one in my case :
Code: Select all
In file included from arch/x86/kernel/head64.c:35:
In function ‘sanitize_boot_params’,
inlined from ‘copy_bootdata’ at arch/x86/kernel/head64.c:389:2:
./arch/x86/include/asm/bootparam_utils.h:40:3: warning: ‘memset’ offset [197, 448] from the object at ‘boot_params’ is out of the bounds of referenced subobject ‘ext_ramdisk_image’ with type ‘unsigned int’ at offset 192 [-Warray-bounds]
40 | memset(&boot_params->ext_ramdisk_image, 0,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
41 | (char *)&boot_params->efi_info -
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
42 | (char *)&boot_params->ext_ramdisk_image);
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
./arch/x86/include/asm/bootparam_utils.h:43:3: warning: ‘memset’ offset [493, 497] from the object at ‘boot_params’ is out of the bounds of referenced subobject ‘kbd_status’ with type ‘unsigned char’ at offset 491 [-Warray-bounds]
43 | memset(&boot_params->kbd_status, 0,
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
44 | (char *)&boot_params->hdr -
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~
45 | (char *)&boot_params->kbd_status);
| ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
I placed the patch in /etc/portage/patches/sys-kernel/gentoo-sources/
Tried that as well, patches fine, no problems, I'll leave it there from now on and if there's some error about it in the future I'll deal with it.
Removed the experimental USE flag, that's it.
IMHO that USE flag should be removed and the additional CPU optimizations patch should be included with the rest of the patches.
Or.. leave it as it is but don't play with it for no apparent reason, this isn't the first time it's happening.