Re: [PATCH v3 08/12] treewide: Use initializer for struct vm_unmapped_area_info

2024-03-12 Thread Kees Cook
; statements that simply set members to zero. > > Signed-off-by: Rick Edgecombe Thanks! This looks to do exactly what it describes. :) Reviewed-by: Kees Cook -- Kees Cook ___ linux-snps-arc mailing list linux-snps-arc@lists.

Re: [PATCH v2 5/9] mm: Initialize struct vm_unmapped_area_info

2024-03-01 Thread Kees Cook
On Sat, Mar 02, 2024 at 12:47:08AM +, Edgecombe, Rick P wrote: > On Wed, 2024-02-28 at 09:21 -0800, Kees Cook wrote: > > I totally understand. If the "uninitialized" warnings were actually > > reliable, I would agree. I look at it this way: > > > > -

Re: [PATCH v2 5/9] mm: Initialize struct vm_unmapped_area_info

2024-02-28 Thread Kees Cook
as a whole. Yes, individual cases maybe bad ("what uid should this be? root?!") but from a general memory safety perspective the value doesn't become potentially influenced by order of operations, leftover stack memory, etc. I'd agree, lifting everything into a static initializer does seem cl

Re: [PATCH v2 5/9] mm: Initialize struct vm_unmapped_area_info

2024-02-27 Thread Kees Cook
one cleanup that is possible from explicitly zero-initializing the whole structure would be dropping all the individual "= 0" assignments. :) -- Kees Cook ___ linux-snps-arc mailing list linux-snps-arc@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-snps-arc

[PATCH 31/82] ARC: dw2 unwind: Refactor intentional wrap-around calculation

2024-01-22 Thread Kees Cook
pta Cc: Luis Chamberlain Cc: Song Liu Cc: Yihao Han Cc: Thomas Gleixner Cc: "dean.yang_cp" Cc: Jinchao Wang Cc: linux-snps-arc@lists.infradead.org Signed-off-by: Kees Cook --- arch/arc/kernel/unwind.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/arch/arc/ker

[PATCH 74/82] ARC: dw2 unwind: Refactor intentional wrap-around test

2024-01-22 Thread Kees Cook
nfradead.org Signed-off-by: Kees Cook --- arch/arc/kernel/unwind.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arc/kernel/unwind.c b/arch/arc/kernel/unwind.c index 8924fa2a8f29..649b56204580 100644 --- a/arch/arc/kernel/unwind.c +++ b/arch/arc/kernel/unwind.c @@ -1278,7 +1

Re: [PATCH v6 13/41] mm: Make pte_mkwrite() take a VMA

2023-02-19 Thread Kees Cook
linux...@lists.infradead.org > Cc: xen-de...@lists.xenproject.org > Cc: linux-a...@vger.kernel.org > Cc: linux...@kvack.org > Tested-by: Pengfei Xu > Suggested-by: David Hildenbrand > Signed-off-by: Rick Edgecombe I'm not an arch maintainer, but it looks like a correct tree-wide

Re: [PATCH] treewide: defconfig: address renamed CONFIG_DEBUG_INFO=y

2022-08-11 Thread Kees Cook
RF4 or DWARF5 explicitly to now pick the toolchain > default. > > Fixes: f9b3cd245784 ("Kconfig.debug: make DEBUG_INFO selectable from a > choice") > Signed-off-by: Arnd Bergmann Thanks! Reviewed-by: Kees Cook -- Kees Cook ___ linux-

Re: [PATCH] arc: Replace lkml.org links with lore

2021-12-15 Thread Kees Cook
On Mon, Feb 15, 2021 at 09:03:54PM -0800, Vineet Gupta wrote: > On 2/10/21 3:28 PM, Kees Cook wrote: > > As started by commit 05a5f51ca566 ("Documentation: Replace lkml.org > > links with lore"), replace lkml.org links with lore to better use a > > single so

Re: [PATCH 2/2] kbuild: use more subdir- for visiting subdirectories while cleaning

2021-10-13 Thread Kees Cook
uild"), we can use the "subdir- += boot" trick for > all architectures. This can take advantage of the parallel option (-j) > for "make clean". > > I also cleaned up the comments. The "archdep" target does not exist. > > Signed-off

Re: [PATCH] ARC: fix CONFIG_HARDENED_USERCOPY

2021-06-10 Thread Kees Cook
On Thu, Jun 10, 2021 at 06:56:48PM +, Vineet Gupta wrote: > On 6/10/21 10:02 AM, Kees Cook wrote: > > On Wed, Jun 09, 2021 at 03:12:11PM -0700, Vineet Gupta wrote: > >> Currently enabling this triggers a warning > >> > >> | usercopy: Kernel memory overw

Re: [PATCH] ARC: fix CONFIG_HARDENED_USERCOPY

2021-06-10 Thread Kees Cook
GN(PAGE_SIZE); > - _stext = .; > > HEAD_TEXT_SECTION > INIT_TEXT_SECTION(L1_CACHE_BYTES) > @@ -83,6 +82,7 @@ SECTIONS > > .text : { > _text = .; > + _stext = .; > TEXT_TEXT > SCHED_TEXT > CPU

[PATCH] arc: Replace lkml.org links with lore

2021-02-10 Thread Kees Cook
As started by commit 05a5f51ca566 ("Documentation: Replace lkml.org links with lore"), replace lkml.org links with lore to better use a single source that's more likely to stay available long-term. Signed-off-by: Kees Cook --- arch/arc/include/asm/irqflags-compact.h | 8 ++-- a

Re: [PATCH 17/17] arch: rename copy_thread_tls() back to copy_thread()

2020-06-22 Thread Kees Cook
e, struct task_struct *p, > unsigned long tls) Maybe clean up the arg indentation too? I'm not sure how strongly people feel about that, but I think it'd be nice. Either way: Reviewed-by: Kees Cook -- Kees Cook ___ linux-snps-arc mailing list linux-snps-a

Re: [PATCH 16/17] arch: remove HAVE_COPY_THREAD_TLS

2020-06-22 Thread Kees Cook
be sufficient. Reviewed-by: Kees Cook -- Kees Cook ___ linux-snps-arc mailing list linux-snps-arc@lists.infradead.org http://lists.infradead.org/mailman/listinfo/linux-snps-arc

Re: [PATCH] ARC: unwind: Mark expected switch fall-throughs

2019-08-05 Thread Kees Cook
ay fall through > [-Wimplicit-fallthrough=] > arch/arc/kernel/unwind.c:836:20: warning: this statement may fall through > [-Wimplicit-fallthrough=] > > Signed-off-by: Gustavo A. R. Silva Reviewed-by: Kees Cook -Kees > --- > arch/arc/kernel/unwind.c | 4 ++-- > 1 fil

Re: [RFC PATCH v2 0/2] Randomization of address chosen by mmap.

2018-03-27 Thread Kees Cook
t; I believe this is the only one right place for it. Adding these 200+ lines of > code we give this feature for any user - on desktop, on server, on IoT device, > on SCADA, etc. But if only glibc will implement ‘user-mode-aslr’ IoT and SCADA > de