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
| ||
|
Date: Fri, 3 Dec 2021 15:43:37 +0800 From: Muchun Song <songmuchun@...edance.com> To: Kees Cook <keescook@...omium.org> Cc: Mina Almasry <almasrymina@...gle.com>, Andrew Morton <akpm@...ux-foundation.org>, Shakeel Butt <shakeelb@...gle.com>, Mike Kravetz <mike.kravetz@...cle.com>, LKML <linux-kernel@...r.kernel.org>, Linux Memory Management List <linux-mm@...ck.org>, linux-hardening@...r.kernel.org Subject: Re: [PATCH] hugetlb/cgroup: Fix copy/paste array assignment On Fri, Dec 3, 2021 at 2:56 PM Kees Cook <keescook@...omium.org> wrote: > > Fix mismatched array assignment, reported by an -Warray-bounds build: > > mm/hugetlb_cgroup.c: In function '__hugetlb_cgroup_file_legacy_init': > mm/hugetlb_cgroup.c:850:35: error: array subscript 8 is above array bounds of 'struct cftype[8]' [-Werror=array-bounds ] > 850 | cft = &h->cgroup_files_dfl[8]; > | ~~~~~~~~~~~~~~~~~~~^~~ > In file included from mm/hugetlb_cgroup.c:23: > ./include/linux/hugetlb.h:625:23: note: while referencing 'cgroup_files_dfl' > 625 | struct cftype cgroup_files_dfl[8]; > | ^~~~~~~~~~~~~~~~ > > Fixes: e45f4726bcad ("hugetlb: add hugetlb.*.numa_stat file") > Signed-off-by: Kees Cook <keescook@...omium.org> Reviewed-by: Muchun Song <songmuchun@...edance.com> Thanks.
Powered by blists - more mailing lists