Re: (subset) [PATCH 0/7] Xperia 1 V support

2024-04-15 Thread Bjorn Andersson
On Mon, 12 Feb 2024 14:10:08 +0100, Konrad Dybcio wrote: > DTS for the phone and some fly-by fixes > > Patch 1 for Mark/sound > Rest for qcom > > Applied, thanks! [2/7] dt-bindings: arm: qcom: Add Xperia 1 V commit: 212729551c4186a1a1cbd80379375b1b54488369 [3/7] arm64: dts: qcom: sm855

Re: [PATCH] ubsan: Add awareness of signed integer overflow traps

2024-04-15 Thread Kees Cook
On Mon, Apr 15, 2024 at 11:34:54AM -0700, Nathan Chancellor wrote: > On Mon, Apr 15, 2024 at 11:28:35AM -0700, Kees Cook wrote: > > On arm64, UBSAN traps can be decoded from the trap instruction. Add the > > add, sub, and mul overflow trap codes now that CONFIG_UBSAN_SIGNED_WRAP > > exists. Seen un

Re: [PATCH] ubsan: Add awareness of signed integer overflow traps

2024-04-15 Thread Nathan Chancellor
On Mon, Apr 15, 2024 at 11:28:35AM -0700, Kees Cook wrote: > On arm64, UBSAN traps can be decoded from the trap instruction. Add the > add, sub, and mul overflow trap codes now that CONFIG_UBSAN_SIGNED_WRAP > exists. Seen under clang 19: > > Internal error: UBSAN: unrecognized failure code:

Re: [PATCH 0/2] configs/hardening: Some fixes for UBSAN

2024-04-15 Thread Nathan Chancellor
tegra194_cbb_init+0x24/0x34 > > Justin, does this trace match anything you found running syzkaller > against SIO? (I assume not -- this seems to be a tegra code path...) FWIW, it is also visible with x86_64 in some other driver, so it is likely not a driver specific issue (at least not to o

[PATCH] ubsan: Add awareness of signed integer overflow traps

2024-04-15 Thread Kees Cook
On arm64, UBSAN traps can be decoded from the trap instruction. Add the add, sub, and mul overflow trap codes now that CONFIG_UBSAN_SIGNED_WRAP exists. Seen under clang 19: Internal error: UBSAN: unrecognized failure code: f2005515 [#1] PREEMPT SMP Reported-by: Nathan Chancellor Close

Re: [PATCH 0/2] configs/hardening: Some fixes for UBSAN

2024-04-15 Thread Kees Cook
On Thu, Apr 11, 2024 at 11:11:05AM -0700, Nathan Chancellor wrote: > [0.189542] Internal error: UBSAN: unrecognized failure code: > f2005515 [#1] PREEMPT SMP Oops! Yes, I didn't update the (arm64) trap handler to notice integer overflows. I think I need something like: diff --git a

Re: [PATCH 0/2] configs/hardening: Some fixes for UBSAN

2024-04-15 Thread Kees Cook
On Thu, 11 Apr 2024 11:11:05 -0700, Nathan Chancellor wrote: > This series was spurred by a couple of recent UBSAN reports in our > continuous integration that appear to be related to > CONFIG_UBSAN_SIGNED_WRAP (which gets enabled with hardening.config due > to 'default UBSAN'), as they only appear

Re: [PATCH v4] checkpatch: add check for snprintf to scnprintf

2024-04-15 Thread Kees Cook
On Thu, Apr 11, 2024 at 03:10:57PM -0700, Justin Stitt wrote: > On Thu, Apr 11, 2024 at 1:56 PM Joe Perches wrote: > > It could. > > > > # {v}snprintf uses that should likely be {v}scnprintf > > if ($line =~ /\b((v?)snprintf)\s*\(/) { > > WARN("SNPRINTF", >

Re: [POC][RFC][PATCH 1/2] mm/x86: Add wildcard * option as memmap=nn*align:name

2024-04-15 Thread Kees Cook
On Fri, Apr 12, 2024 at 06:19:40PM -0400, Steven Rostedt wrote: > On Fri, 12 Apr 2024 23:59:07 +0300 > Mike Rapoport wrote: > > > On Tue, Apr 09, 2024 at 04:41:24PM -0700, Kees Cook wrote: > > > On Tue, Apr 09, 2024 at 07:11:56PM -0400, Steven Rostedt wrote: > > > > On Tue, 9 Apr 2024 15:23:07

[PATCH] pstore/ram: Replace of_node_put with __free() for automatic cleanup

2024-04-15 Thread Abhinav Jain
Add __free(device_node) to the parent_node struct declaration. Move declaration to initialization for ensuring scope sanity. Remove of_node_put from parent_node struct. Suggested-by: Julia Lawall Signed-off-by: Abhinav Jain --- fs/pstore/ram.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletio

RE: [PATCH] xfs: replace deprecated strncpy with strscpy_pad

2024-04-15 Thread David Laight
From: Kees Cook > Sent: 11 April 2024 16:32 > > On Wed, Apr 10, 2024 at 01:45:21PM -0700, Justin Stitt wrote: > > On Tue, Apr 9, 2024 at 9:22 AM Kees Cook wrote: > > > > > > > > - /* 1 larger than sb_fname, so this ensures a trailing NUL char */ > > > > - memset(label, 0, sizeof(label));