[PATCH v2] lib: objpool: fix head overrun on big.LITTLE system

2023-11-20 Thread wuqiang.matt
objpool overrun stress with test_objpool on OrangePi5+ SBC triggered the following kernel warnings: WARNING: CPU: 6 PID: 3115 at lib/objpool.c:168 objpool_push+0xc0/0x100 This message is from objpool.c:168: WARN_ON_ONCE(tail - head > pool->nr_objs); The overrun test case is to validate

Re: [PATCH RFC 20/37] mm: compaction: Reserve metadata storage in compaction_alloc()

2023-11-20 Thread Peter Collingbourne
Hi Alexandru, On Wed, Aug 23, 2023 at 6:16 AM Alexandru Elisei wrote: > > If the source page being migrated has metadata associated with it, make > sure to reserve the metadata storage when choosing a suitable destination > page from the free list. > > Signed-off-by: Alexandru Elisei > --- >

[PATCH 1/2] eventfs: Remove expectation that ei->is_freed means ei->dentry == NULL

2023-11-20 Thread Steven Rostedt
From: "Steven Rostedt (Google)" The logic to free the eventfs_inode (ei) use to set is_freed and clear the "dentry" field under the eventfs_mutex. But that changed when a race was found where the ei->dentry needed to be cleared when the last dput() was called on it. But there was still logic

[PATCH 2/2] eventfs: Do not invalidate dentry in create_file/dir_dentry()

2023-11-20 Thread Steven Rostedt
From: "Steven Rostedt (Google)" With the call to simple_recursive_removal() on the entire eventfs sub system when the directory is removed, it performs the d_invalidate on all the dentries when it is removed. There's no need to do clean ups when a dentry is being created while the directory is

[PATCH 0/2] eventfs: Fixes for v6.7-rc2

2023-11-20 Thread Steven Rostedt
[ Resend to trigger my patchwork updates, and Cc linux-trace-kernel ] A couple of fixes to eventfs: - With the usage of simple_recursive_remove() recommended by Al Viro, the code should not be calling "d_invalidate()" itself. Doing so is causing crashes. The code was calling d_invalidate()

Re: [PATCH v4 0/2] Rpmsg support for i.MX DSP with resource table

2023-11-20 Thread Mathieu Poirier
On Fri, Oct 13, 2023 at 06:27:29PM +0300, Iuliana Prodan (OSS) wrote: > From: Iuliana Prodan > > These patches are needed in order to support rpmsg on DSP when a > resource table is available. > > Changes since v3: > - add reserve-memory nodes in imx8mp-evk.dts rather than .dtsi (patch 2/2) >

Re: selftests: ftrace: WARNING: __list_del_entry_valid_or_report (lib/list_debug.c:62 (discriminator 1))

2023-11-20 Thread Steven Rostedt
On Thu, 16 Nov 2023 18:00:16 +0530 Naresh Kamboju wrote: > Following kernel crash noticed while running selftests: ftrace on arm64 > Juno-r2 > device running stable-rc linux-6.6.y kernel. > > This kernel crash is hard to reproduce. > Can you test this patch. Note, there's a similar bug on

[PATCH v3 2/5] params: Do not go over the limit when getting the string length

2023-11-20 Thread Andy Shevchenko
We can use strnlen() even on early stages and it prevents from going over the string boundaries in case it's already too long. Reviewed-by: Luis Chamberlain Reviewed-by: Kees Cook Signed-off-by: Andy Shevchenko --- kernel/params.c | 9 ++--- 1 file changed, 6 insertions(+), 3 deletions(-)

[PATCH v3 5/5] params: Fix multi-line comment style

2023-11-20 Thread Andy Shevchenko
The multi-line comment style in the file is rather arbitrary. Make it follow the standard one. Reviewed-by: Luis Chamberlain Reviewed-by: Kees Cook Signed-off-by: Andy Shevchenko --- kernel/params.c | 20 1 file changed, 12 insertions(+), 8 deletions(-) diff --git

[PATCH v3 4/5] params: Sort headers

2023-11-20 Thread Andy Shevchenko
Sort the headers in alphabetic order in order to ease the maintenance for this part. Reviewed-by: Luis Chamberlain Reviewed-by: Kees Cook Signed-off-by: Andy Shevchenko --- kernel/params.c | 16 1 file changed, 8 insertions(+), 8 deletions(-) diff --git a/kernel/params.c

[PATCH v3 1/5] params: Introduce the param_unknown_fn type

2023-11-20 Thread Andy Shevchenko
Introduce a new type for the callback to parse an unknown argument. This unifies function prototypes which takes that as a parameter. Reviewed-by: Luis Chamberlain Reviewed-by: Kees Cook Signed-off-by: Andy Shevchenko --- include/linux/moduleparam.h | 6 +++--- kernel/params.c | 8

[PATCH v3 3/5] params: Use size_add() for kmalloc()

2023-11-20 Thread Andy Shevchenko
Prevent allocations from integer overflow by using size_add(). Reviewed-by: Luis Chamberlain Reviewed-by: Kees Cook Signed-off-by: Andy Shevchenko --- kernel/params.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/kernel/params.c b/kernel/params.c index

[PATCH v3 0/5] params: harden string ops and allocatio ops

2023-11-20 Thread Andy Shevchenko
A couple of patches are for get the string ops, used in the module, slightly harden. On top a few cleanups. Since the main part is rather hardening, I think the Kees' tree is the best fit for the series. It also possible to route via Greg's sysfs (driver core?), but I'm open for another

Re: [PATCH v1 1/1] ACPI: NFIT: Switch to use acpi_evaluate_dsm_typed()

2023-11-20 Thread Rafael J. Wysocki
On Mon, Nov 20, 2023 at 4:03 PM Andy Shevchenko wrote: > > On Thu, Oct 19, 2023 at 06:03:28PM -0700, Dan Williams wrote: > > Andy Shevchenko wrote: > > > The acpi_evaluate_dsm_typed() provides a way to check the type of the > > > object evaluated by _DSM call. Use it instead of open coded

Re: [PATCH v1 1/1] ACPI: NFIT: Switch to use acpi_evaluate_dsm_typed()

2023-11-20 Thread Andy Shevchenko
On Thu, Oct 19, 2023 at 06:03:28PM -0700, Dan Williams wrote: > Andy Shevchenko wrote: > > The acpi_evaluate_dsm_typed() provides a way to check the type of the > > object evaluated by _DSM call. Use it instead of open coded variant. > > Looks good to me. > > Reviewed-by: Dan Williams Thank

Re: [PATCH v1] lib: objpool: fix head overrun on RK3588 SBC

2023-11-20 Thread wuqiang.matt
On 2023/11/20 13:18, Masami Hiramatsu (Google) wrote: On Tue, 14 Nov 2023 19:51:48 +0800 "wuqiang.matt" wrote: objpool overrun stress with test_objpool on OrangePi5+ SBC triggered the following kernel warnings: WARNING: CPU: 6 PID: 3115 at lib/objpool.c:168 objpool_push+0xc0/0x100 This

Re: Re: Re: EEVDF/vhost regression (bisected to 86bfbb7ce4f6 sched/fair: Add lag based placement)

2023-11-20 Thread Abel Wu
On 11/20/23 6:56 PM, Peter Zijlstra Wrote: On Sat, Nov 18, 2023 at 01:14:32PM +0800, Abel Wu wrote: Hi Peter, I'm a little confused here. As we adopt placement strategy #1 when PLACE_LAG is enabled, the lag of that entity needs to be preserved. Given that the weight doesn't change, we have:

Re: Re: EEVDF/vhost regression (bisected to 86bfbb7ce4f6 sched/fair: Add lag based placement)

2023-11-20 Thread Peter Zijlstra
On Sat, Nov 18, 2023 at 01:14:32PM +0800, Abel Wu wrote: > Hi Peter, I'm a little confused here. As we adopt placement strategy #1 > when PLACE_LAG is enabled, the lag of that entity needs to be preserved. > Given that the weight doesn't change, we have: > > vl' = vl > > But in fact it is