Re: [PATCH v8 1/3] modules: Support extended MODVERSIONS info

2024-10-30 Thread Matthew Maurer
On Wed, Oct 30, 2024 at 9:37 PM Luis Chamberlain wrote: > > On Thu, Oct 31, 2024 at 12:22:36PM +1100, Michael Ellerman wrote: > > Matthew Maurer writes: > > > Adds a new format for MODVERSIONS which stores each field in a separate > > > ELF section. This initially adds support for variable length

Re: [PATCH v3 rcu 3/3] rcu: Finer-grained grace-period-end checks in rcu_dump_cpu_stacks()

2024-10-30 Thread Paul E. McKenney
On Wed, Oct 30, 2024 at 05:21:13PM -0700, Doug Anderson wrote: > Hi, > > On Wed, Oct 30, 2024 at 4:27 PM Paul E. McKenney wrote: > > > > On Wed, Oct 30, 2024 at 01:12:01PM -0700, Doug Anderson wrote: > > > Hi, > > > > > > On Wed, Oct 30, 2024 at 6:54 AM Paul E. McKenney > > > wrote: > > > > > >

Re: [PATCH v8 1/3] modules: Support extended MODVERSIONS info

2024-10-30 Thread Luis Chamberlain
On Thu, Oct 31, 2024 at 12:22:36PM +1100, Michael Ellerman wrote: > Matthew Maurer writes: > > Adds a new format for MODVERSIONS which stores each field in a separate > > ELF section. This initially adds support for variable length names, but > > could later be used to add additional fields to MOD

Re: [PATCH v2] scripts: Remove export_report.pl

2024-10-30 Thread Luis Chamberlain
On Wed, Oct 30, 2024 at 05:16:34PM +, Matthew Maurer wrote: > This script has been broken for 5 years with no user complaints. > > It first had its .mod.c parser broken in commit a3d0cb04f7df ("modpost: > use __section in the output to *.mod.c"). Later, it had its object file > enumeration bro

Re: [PATCH v5 00/19] Implement DWARF modversions

2024-10-30 Thread Sedat Dilek
On Wed, Oct 30, 2024 at 10:14 PM Sami Tolvanen wrote: > > Hi Sedat, > > On Wed, Oct 30, 2024 at 2:00 PM Sedat Dilek wrote: > > > > Hi Sami, > > > > perfect timing: Nathan uploaded SLIM LLVM toolchain v19.1.3 > > > > KBUILD_GENDWARFKSYMS_STABLE is to be set manually? > > What value is recommended?

Re: [PATCH v8 1/3] modules: Support extended MODVERSIONS info

2024-10-30 Thread Michael Ellerman
Matthew Maurer writes: > Adds a new format for MODVERSIONS which stores each field in a separate > ELF section. This initially adds support for variable length names, but > could later be used to add additional fields to MODVERSIONS in a > backwards compatible way if needed. Any new fields will be

Re: [PATCH net-next v6 1/3] connector/cn_proc: Add hash table for threads

2024-10-30 Thread Jakub Kicinski
On Wed, 23 Oct 2024 09:20:04 -0700 Anjali Kulkarni wrote: > Add a new type PROC_CN_MCAST_NOTIFY to proc connector API, which allows a > thread to notify the kernel that is going to exit with a non-zero exit > code and specify the exit code in it. When thread exits in the kernel, > it will send this

Re: [PATCH v3 rcu 3/3] rcu: Finer-grained grace-period-end checks in rcu_dump_cpu_stacks()

2024-10-30 Thread Doug Anderson
Hi, On Wed, Oct 30, 2024 at 4:27 PM Paul E. McKenney wrote: > > On Wed, Oct 30, 2024 at 01:12:01PM -0700, Doug Anderson wrote: > > Hi, > > > > On Wed, Oct 30, 2024 at 6:54 AM Paul E. McKenney wrote: > > > > > > > > We do assume that nmi_trigger_cpumask_backtrace() uses true NMIs, so, > > > > > y

Re: [PATCH v3 rcu 3/3] rcu: Finer-grained grace-period-end checks in rcu_dump_cpu_stacks()

2024-10-30 Thread Paul E. McKenney
On Wed, Oct 30, 2024 at 01:12:01PM -0700, Doug Anderson wrote: > Hi, > > On Wed, Oct 30, 2024 at 6:54 AM Paul E. McKenney wrote: > > > > > > We do assume that nmi_trigger_cpumask_backtrace() uses true NMIs, so, > > > > yes, nmi_trigger_cpumask_backtrace() should use true NMIs, just like > > > > t

[PATCH v8 3/3] rust: Use gendwarfksyms + extended modversions for CONFIG_MODVERSIONS

2024-10-30 Thread Matthew Maurer
From: Sami Tolvanen Previously, two things stopped Rust from using MODVERSIONS: 1. Rust symbols are occasionally too long to be represented in the original versions table 2. Rust types cannot be properly hashed by the existing genksyms approach because: * Looking up type definitions

[PATCH v8 2/3] modpost: Produce extended MODVERSIONS information

2024-10-30 Thread Matthew Maurer
Generate both the existing modversions format and the new extended one when running modpost. Presence of this metadata in the final .ko is guarded by CONFIG_EXTENDED_MODVERSIONS. We no longer generate an error on long symbols in modpost if CONFIG_EXTENDED_MODVERSIONS is set, as they can now be app

[PATCH v8 1/3] modules: Support extended MODVERSIONS info

2024-10-30 Thread Matthew Maurer
Adds a new format for MODVERSIONS which stores each field in a separate ELF section. This initially adds support for variable length names, but could later be used to add additional fields to MODVERSIONS in a backwards compatible way if needed. Any new fields will be ignored by old user tooling, un

[PATCH v8 0/3] Extended MODVERSIONS Support

2024-10-30 Thread Matthew Maurer
This patch series is intended for use alongside the Implement DWARF modversions series [1] to enable RUST and MODVERSIONS at the same time. Elsewhere, we've seen a desire for long symbol name support for LTO symbol names [2], and the previous series came up [3] as a possible solution rather than h

Re: [PATCH v2 07/13] media: i2c: imx214: Check number of lanes from device tree

2024-10-30 Thread André Apitzsch
Hi Ricardo, Am Mittwoch, dem 30.10.2024 um 12:38 +0100 schrieb Ricardo Ribalda Delgado: > On Mon, Oct 21, 2024 at 12:14 AM André Apitzsch via B4 Relay > wrote: > > > > From: André Apitzsch > > > > The imx214 camera is capable of either two-lane or four-lane > > operation. > > > > Currently on

Re: [PATCH RFT v11 2/8] Documentation: userspace-api: Add shadow stack API documentation

2024-10-30 Thread Deepak Gupta
On Sat, Oct 05, 2024 at 11:31:29AM +0100, Mark Brown wrote: There are a number of architectures with shadow stack features which we are presenting to userspace with as consistent an API as we can (though there are some architecture specifics). Especially given that there are some important consid

Re: [PATCH net-next v1 6/7] net: fix SO_DEVMEM_DONTNEED looping too long

2024-10-30 Thread Mina Almasry
On Wed, Oct 30, 2024 at 7:33 AM Stanislav Fomichev wrote: > > On 10/29, Mina Almasry wrote: > > Check we're going to free a reasonable number of frags in token_count > > before starting the loop, to prevent looping too long. > > > > Also minor code cleanups: > > - Flip checks to reduce indentation

Re: [PATCH v5 00/19] Implement DWARF modversions

2024-10-30 Thread Sami Tolvanen
Hi Sedat, On Wed, Oct 30, 2024 at 2:00 PM Sedat Dilek wrote: > > Hi Sami, > > perfect timing: Nathan uploaded SLIM LLVM toolchain v19.1.3 > > KBUILD_GENDWARFKSYMS_STABLE is to be set manually? > What value is recommended? The usage is similar to KBUILD_SYMTYPES, you can just set KBUILD_GENDWARFK

Re: [PATCH RFT v11 1/8] arm64/gcs: Return a success value from gcs_alloc_thread_stack()

2024-10-30 Thread Deepak Gupta
On Sat, Oct 05, 2024 at 11:31:28AM +0100, Mark Brown wrote: Currently as a result of templating from x86 code gcs_alloc_thread_stack() returns a pointer as an unsigned int however on arm64 we don't actually use this pointer value as anything other than a pass/fail flag. Simplify the interface to

Re: [PATCH v5 00/19] Implement DWARF modversions

2024-10-30 Thread Sedat Dilek
On Wed, Oct 30, 2024 at 6:01 PM Sami Tolvanen wrote: > > Hi, > > Here's v5 of the DWARF modversions series. The main motivation is > modversions support for Rust, which is important for distributions > like Android that are about to ship Rust kernel modules. Per Luis' > request [1], v2 dropped the

Re: [PATCH net-next v11 08/23] ovpn: implement basic TX path (UDP)

2024-10-30 Thread Antonio Quartulli
On 30/10/2024 18:14, Sabrina Dubroca wrote: 2024-10-29, 11:47:21 +0100, Antonio Quartulli wrote: +static void ovpn_send(struct ovpn_struct *ovpn, struct sk_buff *skb, + struct ovpn_peer *peer) +{ + struct sk_buff *curr, *next; + + if (likely(!peer)) +

Re: [PATCH bpf-next] selftests/bpf: Fix compile error when MPTCP not support

2024-10-30 Thread Martin KaFai Lau
On 10/30/24 9:31 AM, Matthieu Baerts wrote: Hi Tao, BPF maintainers, On 30/10/2024 12:12, Tao Chen wrote: 在 2024/10/30 18:49, Matthieu Baerts 写道: Hi Tao Chen, Thank you for having shared this patch. On 30/10/2024 11:01, Tao Chen wrote: Fix compile error when MPTCP feature not support, thoug

Re: [PATCH net-next v11 06/23] ovpn: introduce the ovpn_peer object

2024-10-30 Thread Antonio Quartulli
On 30/10/2024 17:37, Sabrina Dubroca wrote: 2024-10-29, 11:47:19 +0100, Antonio Quartulli wrote: +static void ovpn_peer_release(struct ovpn_peer *peer) +{ + ovpn_bind_reset(peer, NULL); + + dst_cache_destroy(&peer->dst_cache); Is it safe to destroy the cache at this time? In the sa

[PATCH 2/2] selftests/exec: add a test for execveat()'s comm

2024-10-30 Thread Tycho Andersen
From: Tycho Andersen In the previous patch we've defined a couple behaviors: 1. execveat(fd, AT_EMPTY_PATH, {"foo"}, ...) should render argv[0] as /proc/pid/comm 2. execveat(fd, AT_EMPTY_PATH, {NULL}, ...) should keep the old behavior of rendering the fd as /proc/pid/comm and just to be s

[PATCH 1/2] exec: fix up /proc/pid/comm in the execveat(AT_EMPTY_PATH) case

2024-10-30 Thread Tycho Andersen
From: Tycho Andersen Zbigniew mentioned at Linux Plumber's that systemd is interested in switching to execveat() for service execution, but can't, because the contents of /proc/pid/comm are the file descriptor which was used, instead of the path to the binary. This makes the output of tools like

Re: [PATCH v3 rcu 3/3] rcu: Finer-grained grace-period-end checks in rcu_dump_cpu_stacks()

2024-10-30 Thread Doug Anderson
Hi, On Wed, Oct 30, 2024 at 6:54 AM Paul E. McKenney wrote: > > > > We do assume that nmi_trigger_cpumask_backtrace() uses true NMIs, so, > > > yes, nmi_trigger_cpumask_backtrace() should use true NMIs, just like > > > the name says. ;-) > > > > In the comments of following patch, the arm64 main

[PATCH v5 02/19] tools: Add gendwarfksyms

2024-10-30 Thread Sami Tolvanen
Add a basic DWARF parser, which uses libdw to traverse the debugging information in an object file and looks for functions and variables. In follow-up patches, this will be expanded to produce symbol versions for CONFIG_MODVERSIONS from DWARF. Signed-off-by: Sami Tolvanen Acked-by: Neal Gompa Re

Re: [PATCH v2 02/13] media: i2c: imx214: Use subdev active state

2024-10-30 Thread Ricardo Ribalda Delgado
Hi It looks good to me, but I would like Sakari to review it. I am not sure if it is ok to keep the cur_mode variable. On Mon, Oct 21, 2024 at 12:14 AM André Apitzsch via B4 Relay wrote: > > From: André Apitzsch > > Port the imx214 sensor driver to use the subdev active state. > > Move all the

Re: [PATCH v3 2/9] KVM: selftests: Add a basic SNP smoke test

2024-10-30 Thread Sean Christopherson
On Wed, Oct 30, 2024, Pratik R. Sampat wrote: > On 10/30/2024 8:46 AM, Sean Christopherson wrote: > > +/* Minimum firmware version required for the SEV-SNP support */ > > +#define SNP_FW_REQ_VER_MAJOR 1 > > +#define SNP_FW_REQ_VER_MINOR 51 > > > > Side topic, why are these hardcoded? And wher

[PATCH v5 00/19] Implement DWARF modversions

2024-10-30 Thread Sami Tolvanen
Hi, Here's v5 of the DWARF modversions series. The main motivation is modversions support for Rust, which is important for distributions like Android that are about to ship Rust kernel modules. Per Luis' request [1], v2 dropped the Rust specific bits from the series and instead added the feature a

Re: [RFC PATCH] remoteproc: core: Add support for predefined notifyids

2024-10-30 Thread Daniel Baluta
On Wed, Oct 23, 2024 at 6:32 PM Mathieu Poirier wrote: > > Hello Daniel, > > On Fri, Oct 18, 2024 at 02:09:29PM +0300, Daniel Baluta wrote: > > Currently we generate notifyids in the linux kernel and override > > those found in rsc_table. > > > > This doesn't play well with users expecting to use

[PATCH v5 09/19] gendwarfksyms: Expand structure types

2024-10-30 Thread Sami Tolvanen
Recursively expand DWARF structure types, i.e. structs, unions, and enums. Also include relevant DWARF attributes in type strings to encode structure layout, for example. Example output with --dump-dies: subprogram ( formal_parameter structure_type &str { member pointer_type {

[PATCH v5 11/19] gendwarfksyms: Add die_map debugging

2024-10-30 Thread Sami Tolvanen
Debugging the DWARF processing can be somewhat challenging, so add more detailed debugging output for die_map operations. Add the --dump-die-map flag, which adds color coded tags to the output for die_map changes. Signed-off-by: Sami Tolvanen Acked-by: Neal Gompa Reviewed-by: Petr Pavlu --- sc

[PATCH v5 17/19] export: Add __gendwarfksyms_ptr_ references to exported symbols

2024-10-30 Thread Sami Tolvanen
With gendwarfksyms, we need each TU where the EXPORT_SYMBOL() macro is used to also contain DWARF type information for the symbols it exports. However, as a TU can also export external symbols and compilers may choose not to emit debugging information for symbols not defined in the current TU, the

[PATCH v5 18/19] kbuild: Add gendwarfksyms as an alternative to genksyms

2024-10-30 Thread Sami Tolvanen
When MODVERSIONS is enabled, allow selecting gendwarfksyms as the implementation, but default to genksyms. Signed-off-by: Sami Tolvanen Acked-by: Neal Gompa --- kernel/module/Kconfig | 25 - scripts/Makefile | 2 +- scripts/Makefile.build | 41 +++

[PATCH v2] scripts: Remove export_report.pl

2024-10-30 Thread Matthew Maurer
This script has been broken for 5 years with no user complaints. It first had its .mod.c parser broken in commit a3d0cb04f7df ("modpost: use __section in the output to *.mod.c"). Later, it had its object file enumeration broken in commit f65a486821cf ("kbuild: change module.order to list *.o inste

Re: [PATCH bpf-next] selftests/bpf: Fix compile error when MPTCP not support

2024-10-30 Thread Matthieu Baerts
Hi Tao, BPF maintainers, On 30/10/2024 12:12, Tao Chen wrote: > 在 2024/10/30 18:49, Matthieu Baerts 写道: >> Hi Tao Chen, >> >> Thank you for having shared this patch. >> >> On 30/10/2024 11:01, Tao Chen wrote: >>> Fix compile error when MPTCP feature not support, though eBPF core check >>> already

Re: [PATCH net-next v11 08/23] ovpn: implement basic TX path (UDP)

2024-10-30 Thread Sabrina Dubroca
2024-10-29, 11:47:21 +0100, Antonio Quartulli wrote: > +static void ovpn_send(struct ovpn_struct *ovpn, struct sk_buff *skb, > + struct ovpn_peer *peer) > +{ > + struct sk_buff *curr, *next; > + > + if (likely(!peer)) > + /* retrieve peer serving the destinatio

[PATCH v5 05/19] gendwarfksyms: Add a cache for processed DIEs

2024-10-30 Thread Sami Tolvanen
Basic types in DWARF repeat frequently and traversing the DIEs using libdw is relatively slow. Add a simple hashtable based cache for the processed DIEs. Signed-off-by: Sami Tolvanen Acked-by: Neal Gompa Reviewed-by: Petr Pavlu --- scripts/gendwarfksyms/Makefile| 1 + scripts/gendwar

[PATCH v5 19/19] Documentation/kbuild: Add DWARF module versioning

2024-10-30 Thread Sami Tolvanen
Add documentation for gendwarfksyms changes, and the kABI stability features that can be useful for distributions even though they're not used in mainline kernels. Signed-off-by: Sami Tolvanen Acked-by: Neal Gompa --- Documentation/kbuild/gendwarfksyms.rst | 276 + Docum

[PATCH v5 15/19] gendwarfksyms: Add support for reserved and ignored fields

2024-10-30 Thread Sami Tolvanen
Distributions that want to maintain a stable kABI need the ability to make ABI compatible changes to kernel data structures without affecting symbol versions, either because of LTS updates or backports. With genksyms, developers would typically hide these changes from version calculation with #ifn

[PATCH v5 16/19] gendwarfksyms: Add support for symbol type pointers

2024-10-30 Thread Sami Tolvanen
The compiler may choose not to emit type information in DWARF for external symbols. Clang, for example, does this for symbols not defined in the current TU. To provide a way to work around this issue, add support for __gendwarfksyms_ptr_ pointers that force the compiler to emit the necessary type

[PATCH v5 12/19] gendwarfksyms: Add symtypes output

2024-10-30 Thread Sami Tolvanen
Add support for producing genksyms-style symtypes files. Process die_map to find the longest expansions for each type, and use symtypes references in type definitions. The basic file format is similar to genksyms, with two notable exceptions: 1. Type names with spaces (common with Rust) in refer

[PATCH v5 14/19] gendwarfksyms: Add support for kABI rules

2024-10-30 Thread Sami Tolvanen
Distributions that want to maintain a stable kABI need the ability to make ABI compatible changes to kernel without affecting symbol versions, either because of LTS updates or backports. With genksyms, developers would typically hide these changes from version calculation with #ifndef __GENKSYMS__

[PATCH v5 13/19] gendwarfksyms: Add symbol versioning

2024-10-30 Thread Sami Tolvanen
Calculate symbol versions from the fully expanded type strings in type_map, and output the versions in a genksyms-compatible format. Signed-off-by: Sami Tolvanen Acked-by: Neal Gompa --- scripts/gendwarfksyms/dwarf.c | 25 +- scripts/gendwarfksyms/gendwarfksyms.c | 10 ++- scripts

[PATCH v5 10/19] gendwarfksyms: Limit structure expansion

2024-10-30 Thread Sami Tolvanen
Expand each structure type only once per exported symbol. This is necessary to support self-referential structures, which would otherwise result in infinite recursion, but is still sufficient for catching ABI changes. For pointers, limit structure expansion after the first pointer in the symbol ty

[PATCH v5 08/19] gendwarfksyms: Expand array_type

2024-10-30 Thread Sami Tolvanen
Add support for expanding DW_TAG_array_type, and the subrange type indicating array size. Example source code: const char *s[34]; Output with --dump-dies: variable array_type[34] { pointer_type { const_type { base_type char byte_size(1) encoding(6) } } byte_size(

[PATCH v5 07/19] gendwarfksyms: Expand subroutine_type

2024-10-30 Thread Sami Tolvanen
Add support for expanding DW_TAG_subroutine_type and the parameters in DW_TAG_formal_parameter. Use this to also expand subprograms. Example output with --dump-dies: subprogram ( formal_parameter pointer_type { const_type { base_type char byte_size(1) encoding(6) } }

[PATCH v5 06/19] gendwarfksyms: Expand type modifiers and typedefs

2024-10-30 Thread Sami Tolvanen
Add support for expanding DWARF type modifiers, such as pointers, const values etc., and typedefs. These types all have DW_AT_type attribute pointing to the underlying type, and thus produce similar output. Also add linebreaks and indentation to debugging output to make it more readable. Signed-o

[PATCH v5 04/19] gendwarfksyms: Expand base_type

2024-10-30 Thread Sami Tolvanen
Start making gendwarfksyms more useful by adding support for expanding DW_TAG_base_type types and basic DWARF attributes. Example: $ echo loops_per_jiffy | \ scripts/gendwarfksyms/gendwarfksyms \ --debug --dump-dies vmlinux.o ... gendwarfksyms: process_symbol: loops_per_jiffy

[PATCH v5 01/19] scripts: move genksyms crc32 implementation to a common include

2024-10-30 Thread Sami Tolvanen
To avoid duplication between host programs, move the crc32 code to a shared header file. Suggested-by: Petr Pavlu Signed-off-by: Sami Tolvanen Acked-by: Neal Gompa --- scripts/genksyms/genksyms.c | 77 +- scripts/include/crc32.h | 93

[PATCH v5 03/19] gendwarfksyms: Add address matching

2024-10-30 Thread Sami Tolvanen
The compiler may choose not to emit type information in DWARF for all aliases, but it's possible for each alias to be exported separately. To ensure we find type information for the aliases as well, read {section, address} tuples from the symbol table and match symbols also by address. Signed-off-

Re: [PATCH net-next v11 06/23] ovpn: introduce the ovpn_peer object

2024-10-30 Thread Sabrina Dubroca
2024-10-29, 11:47:19 +0100, Antonio Quartulli wrote: > +static void ovpn_peer_release(struct ovpn_peer *peer) > +{ > + ovpn_bind_reset(peer, NULL); > + > + dst_cache_destroy(&peer->dst_cache); Is it safe to destroy the cache at this time? In the same function, we use rcu to free the peer,

Re: [PATCH v3 2/9] KVM: selftests: Add a basic SNP smoke test

2024-10-30 Thread Pratik R. Sampat
Hi Sean, On 10/30/2024 8:46 AM, Sean Christopherson wrote: > On Mon, Oct 28, 2024, Pratik R. Sampat wro4te: >> On 10/28/2024 12:55 PM, Sean Christopherson wrote: >>> On Mon, Oct 21, 2024, Pratik R. Sampat wrote: >> +if (unlikely(!is_smt_active())) >> +

Re: [PATCH v6 2/5] pidfd: add PIDFD_SELF_* sentinels to refer to own thread/process

2024-10-30 Thread Lorenzo Stoakes
On Mon, Oct 28, 2024 at 04:06:07PM +, Lorenzo Stoakes wrote: > I guess I'll try to adapt that and respin a v7 when I get a chance. Hm looking at this draft patch, it seems like a total rework of pidfd's across the board right (now all pidfd's will need to be converted to pid_fd)? Correct me if

Re: [PATCH net-next v6 00/12] selftests: ncdevmem: Add ncdevmem to ksft

2024-10-30 Thread Stanislav Fomichev
On 10/30, Mina Almasry wrote: > On Wed, Oct 30, 2024 at 8:13 AM Stanislav Fomichev > wrote: > > > > On 10/30, Mina Almasry wrote: > > > On Wed, Oct 30, 2024 at 7:27 AM Stanislav Fomichev > > > wrote: > > > > > > > > The goal of the series is to simplify and make it possible to use > > > > ncdev

Re: [PATCH net-next v1 6/7] net: fix SO_DEVMEM_DONTNEED looping too long

2024-10-30 Thread Stanislav Fomichev
On 10/29, Mina Almasry wrote: > Check we're going to free a reasonable number of frags in token_count > before starting the loop, to prevent looping too long. > > Also minor code cleanups: > - Flip checks to reduce indentation. > - Use sizeof(*tokens) everywhere for consistentcy. > > Cc: Yi Lai

Re: [PATCH net-next v6 00/12] selftests: ncdevmem: Add ncdevmem to ksft

2024-10-30 Thread Mina Almasry
On Wed, Oct 30, 2024 at 8:13 AM Stanislav Fomichev wrote: > > On 10/30, Mina Almasry wrote: > > On Wed, Oct 30, 2024 at 7:27 AM Stanislav Fomichev wrote: > > > > > > The goal of the series is to simplify and make it possible to use > > > ncdevmem in an automated way from the ksft python wrapper.

Re: [PATCH net-next v6 00/12] selftests: ncdevmem: Add ncdevmem to ksft

2024-10-30 Thread Stanislav Fomichev
On 10/30, Mina Almasry wrote: > On Wed, Oct 30, 2024 at 7:27 AM Stanislav Fomichev wrote: > > > > The goal of the series is to simplify and make it possible to use > > ncdevmem in an automated way from the ksft python wrapper. > > > > ncdevmem is slowly mutated into a state where it uses stdout >

Re: [PATCH v3 2/9] KVM: selftests: Add a basic SNP smoke test

2024-10-30 Thread Sean Christopherson
On Mon, Oct 28, 2024, Pratik R. Sampat wro4te: > On 10/28/2024 12:55 PM, Sean Christopherson wrote: > > On Mon, Oct 21, 2024, Pratik R. Sampat wrote: > +if (unlikely(!is_smt_active())) > +snp_policy &= ~SNP_POLICY_SMT; > >>> > >>> Why does SNP_POLIC

Re: [PATCH net-next v1 6/7] net: fix SO_DEVMEM_DONTNEED looping too long

2024-10-30 Thread Stanislav Fomichev
On 10/30, Mina Almasry wrote: > On Wed, Oct 30, 2024 at 7:33 AM Stanislav Fomichev > wrote: > > > > On 10/29, Mina Almasry wrote: > > > Check we're going to free a reasonable number of frags in token_count > > > before starting the loop, to prevent looping too long. > > > > > > Also minor code cl

Re: [PATCH] selftests/lam: Test get_user() LAM pointer handling

2024-10-30 Thread Kirill A. Shutemov
On Tue, Oct 29, 2024 at 03:14:20PM +0100, Maciej Wieczor-Retman wrote: > Recent change in how get_user() handles pointers [1] has a specific case > for LAM. It assigns a different bitmask that's later used to check > whether a pointer comes from userland in get_user(). > > While currently commente

Re: [PATCH net-next v6 00/12] selftests: ncdevmem: Add ncdevmem to ksft

2024-10-30 Thread Mina Almasry
On Wed, Oct 30, 2024 at 7:27 AM Stanislav Fomichev wrote: > > The goal of the series is to simplify and make it possible to use > ncdevmem in an automated way from the ksft python wrapper. > > ncdevmem is slowly mutated into a state where it uses stdout > to print the payload and the python wrappe

[PATCH net-next v6 01/12] selftests: ncdevmem: Redirect all non-payload output to stderr

2024-10-30 Thread Stanislav Fomichev
That should make it possible to do expected payload validation on the caller side. Reviewed-by: Mina Almasry Signed-off-by: Stanislav Fomichev --- tools/testing/selftests/net/ncdevmem.c | 61 +- 1 file changed, 30 insertions(+), 31 deletions(-) diff --git a/tools/testin

Re: [PATCH RFT v11 0/8] fork: Support shadow stacks in clone3()

2024-10-30 Thread Yury Khrustalev
On Wed, Oct 30, 2024 at 02:08:59PM +, Mark Brown wrote: > On Sat, Oct 05, 2024 at 11:31:27AM +0100, Mark Brown wrote: > > The kernel has recently added support for shadow stacks, currently > > x86 only using their CET feature but both arm64 and RISC-V have > > equivalent features (GCS and Zicfi

[PATCH net-next v6 09/12] selftests: ncdevmem: Remove hard-coded queue numbers

2024-10-30 Thread Stanislav Fomichev
Use single last queue of the device and probe it dynamically. Reviewed-by: Mina Almasry Signed-off-by: Stanislav Fomichev --- tools/testing/selftests/net/ncdevmem.c | 40 -- 1 file changed, 38 insertions(+), 2 deletions(-) diff --git a/tools/testing/selftests/net/ncdevm

[PATCH net-next v6 12/12] selftests: ncdevmem: Add automated test

2024-10-30 Thread Stanislav Fomichev
Only RX side for now and small message to test the setup. In the future, we can extend it to TX side and to testing both sides with a couple of megs of data. make \ -C tools/testing/selftests \ TARGETS="drivers/hw/net" \ install INSTALL_PATH=~/tmp/ksft scp ~/tmp/ksft $

[PATCH net-next v6 11/12] selftests: ncdevmem: Move ncdevmem under drivers/net/hw

2024-10-30 Thread Stanislav Fomichev
This is where all the tests that depend on the HW functionality live in and this is where the automated test is gonna be added in the next patch. Reviewed-by: Mina Almasry Signed-off-by: Stanislav Fomichev --- tools/testing/selftests/drivers/net/hw/.gitignore | 1 + tools/testing/selfte

[PATCH net-next v6 10/12] selftests: ncdevmem: Run selftest when none of the -s or -c has been provided

2024-10-30 Thread Stanislav Fomichev
This will be used as a 'probe' mode in the selftest to check whether the device supports the devmem or not. Use hard-coded queue layout (two last queues) and prevent user from passing custom -q and/or -t. Reviewed-by: Mina Almasry Signed-off-by: Stanislav Fomichev --- tools/testing/selftests/ne

[PATCH net-next v6 08/12] selftests: ncdevmem: Use YNL to enable TCP header split

2024-10-30 Thread Stanislav Fomichev
In the next patch the hard-coded queue numbers are gonna be removed. So introduce some initial support for ethtool YNL and use it to enable header split. Also, tcp-data-split requires latest ethtool which is unlikely to be present in the distros right now. (ideally, we should not shell out to eth

[PATCH net-next v6 07/12] selftests: ncdevmem: Properly reset flow steering

2024-10-30 Thread Stanislav Fomichev
ntuple off/on might be not enough to do it on all NICs. Add a bunch of shell crap to explicitly remove the rules. Reviewed-by: Mina Almasry Signed-off-by: Stanislav Fomichev --- tools/testing/selftests/net/ncdevmem.c | 19 --- 1 file changed, 12 insertions(+), 7 deletions(-) di

[PATCH net-next v6 06/12] selftests: ncdevmem: Switch to AF_INET6

2024-10-30 Thread Stanislav Fomichev
Use dualstack socket to support both v4 and v6. v4-mapped-v6 address can be used to do v4. Reviewed-by: Mina Almasry Signed-off-by: Stanislav Fomichev --- tools/testing/selftests/net/ncdevmem.c | 85 +- 1 file changed, 57 insertions(+), 28 deletions(-) diff --git a/tool

[PATCH net-next v6 04/12] selftests: ncdevmem: Make client_ip optional

2024-10-30 Thread Stanislav Fomichev
Support 3-tuple filtering by making client_ip optional. When -c is not passed, don't specify src-ip/src-port in the filter. Reviewed-by: Mina Almasry Signed-off-by: Stanislav Fomichev --- tools/testing/selftests/net/ncdevmem.c | 12 +--- 1 file changed, 9 insertions(+), 3 deletions(-)

[PATCH net-next v6 05/12] selftests: ncdevmem: Remove default arguments

2024-10-30 Thread Stanislav Fomichev
To make it clear what's required and what's not. Also, some of the values don't seem like a good defaults; for example eth1. Move the invocation comment to the top, add missing -s to the client and cleanup the client invocation a bit to make more readable. Reviewed-by: Mina Almasry Signed-off-by

[PATCH net-next v6 03/12] selftests: ncdevmem: Unify error handling

2024-10-30 Thread Stanislav Fomichev
There is a bunch of places where error() calls look out of place. Use the same error(1, errno, ...) pattern everywhere. Reviewed-by: Mina Almasry Signed-off-by: Stanislav Fomichev --- tools/testing/selftests/net/ncdevmem.c | 16 1 file changed, 8 insertions(+), 8 deletions(-)

[PATCH net-next v6 02/12] selftests: ncdevmem: Separate out dmabuf provider

2024-10-30 Thread Stanislav Fomichev
So we can plug the other ones in the future if needed. Reviewed-by: Mina Almasry Signed-off-by: Stanislav Fomichev --- tools/testing/selftests/net/ncdevmem.c | 198 +++-- 1 file changed, 117 insertions(+), 81 deletions(-) diff --git a/tools/testing/selftests/net/ncdevmem.c

[PATCH net-next v6 00/12] selftests: ncdevmem: Add ncdevmem to ksft

2024-10-30 Thread Stanislav Fomichev
The goal of the series is to simplify and make it possible to use ncdevmem in an automated way from the ksft python wrapper. ncdevmem is slowly mutated into a state where it uses stdout to print the payload and the python wrapper is added to make sure the arrived payload matches the expected one.

Re: [PATCH] selftests/lam: Test get_user() LAM pointer handling

2024-10-30 Thread Maciej Wieczor-Retman
On 2024-10-30 at 14:31:51 +0200, Kirill A. Shutemov wrote: >On Tue, Oct 29, 2024 at 03:14:20PM +0100, Maciej Wieczor-Retman wrote: >> Recent change in how get_user() handles pointers [1] has a specific case >> for LAM. It assigns a different bitmask that's later used to check >> whether a pointer c

Re: [PATCH RFT v11 0/8] fork: Support shadow stacks in clone3()

2024-10-30 Thread Mark Brown
On Sat, Oct 05, 2024 at 11:31:27AM +0100, Mark Brown wrote: > The kernel has recently added support for shadow stacks, currently > x86 only using their CET feature but both arm64 and RISC-V have > equivalent features (GCS and Zicfiss respectively), I am actively > working on GCS[1]. With shadow st

Re: [PATCH v5 03/13] iommufd: Add iommufd_verify_unfinalized_object

2024-10-30 Thread Jason Gunthorpe
On Tue, Oct 29, 2024 at 09:05:14PM -0700, Nicolin Chen wrote: > On Tue, Oct 29, 2024 at 03:55:58PM -0300, Jason Gunthorpe wrote: > > On Tue, Oct 29, 2024 at 09:18:05AM -0700, Nicolin Chen wrote: > > > I think we'd need the same change in iommufd_object_abort() too. > > > > Makes sense > > I found

Re: [PATCH v3 rcu 3/3] rcu: Finer-grained grace-period-end checks in rcu_dump_cpu_stacks()

2024-10-30 Thread Paul E. McKenney
On Wed, Oct 30, 2024 at 03:55:56AM +, Cheng-Jui Wang (王正睿) wrote: > On Tue, 2024-10-29 at 09:29 -0700, Paul E. McKenney wrote: > > External email : Please do not click links or open attachments until you > > have verified the sender or the content. > > > > > > On Tue, Oct 29, 2024 at 02:20:5

Re: [PATCH] selftests: netfilter: remove unused parameter

2024-10-30 Thread Pablo Neira Ayuso
Applied to nf.git, thanks

Re: [PATCH v2 10/13] media: i2c: imx214: Implement vflip/hflip controls

2024-10-30 Thread Ricardo Ribalda Delgado
On Mon, Oct 21, 2024 at 12:14 AM André Apitzsch via B4 Relay wrote: > > From: André Apitzsch > > The imx214 sensor supports horizontal and vertical flipping. Add > appropriate controls to the driver. > > Signed-off-by: André Apitzsch Acked-by: Ricardo Ribalda > --- > drivers/media/i2c/imx214.c

Re: [PATCH v2 09/13] media: i2c: imx214: Extract format and crop settings

2024-10-30 Thread Ricardo Ribalda Delgado
Hi Aren't you changing the binning mode for 1920x1080 with this patch? I think that could be considered an ABI change. Also, if we are not letting the user change the value, I do not see much value in setting the cropping programmatically, I'd rather not take this change. On Mon, Oct 21, 2024 a

Re: [PATCH v2 08/13] media: i2c: imx214: Add vblank and hblank controls

2024-10-30 Thread Ricardo Ribalda Delgado
On Mon, Oct 21, 2024 at 12:14 AM André Apitzsch via B4 Relay wrote: > > From: André Apitzsch > > Add vblank control to allow changing the framerate / > higher exposure values. > > The vblank and hblank controls are needed for libcamera support. > > While at it, fix the minimal exposure time accor

Re: [PATCH v2 07/13] media: i2c: imx214: Check number of lanes from device tree

2024-10-30 Thread Ricardo Ribalda Delgado
On Mon, Oct 21, 2024 at 12:14 AM André Apitzsch via B4 Relay wrote: > > From: André Apitzsch > > The imx214 camera is capable of either two-lane or four-lane operation. > > Currently only the four-lane mode is supported, as proper pixel rates > and link frequences for the two-lane mode are unknow

Re: [PATCH v2 01/13] media: i2c: imx214: Fix link frequency

2024-10-30 Thread Ricardo Ribalda Delgado
Hi Andre On Mon, Oct 21, 2024 at 12:14 AM André Apitzsch via B4 Relay wrote: > > From: André Apitzsch > > The driver defines IMX214_DEFAULT_LINK_FREQ 48000, and then > IMX214_DEFAULT_PIXEL_RATE ((IMX214_DEFAULT_LINK_FREQ * 8LL) / 10), > which works out as 384MPix/s. (The 8 is 4 lanes and DDR

Re: [PATCH bpf-next] selftests/bpf: Fix compile error when MPTCP not support

2024-10-30 Thread Tao Chen
在 2024/10/30 18:49, Matthieu Baerts 写道: Hi Tao Chen, Thank you for having shared this patch. On 30/10/2024 11:01, Tao Chen wrote: Fix compile error when MPTCP feature not support, though eBPF core check already done which seems invalid in this situation, the error info like: progs/mptcp_sock.c

Re: [PATCH bpf-next] selftests/bpf: Fix compile error when MPTCP not support

2024-10-30 Thread Matthieu Baerts
Hi Tao Chen, Thank you for having shared this patch. On 30/10/2024 11:01, Tao Chen wrote: > Fix compile error when MPTCP feature not support, though eBPF core check > already done which seems invalid in this situation, the error info like: > progs/mptcp_sock.c:49:40: error: no member named 'is_mp

[PATCH][next] KVM: s390: selftests: Fix spelling mistake "avaialable" -> "available"

2024-10-30 Thread Colin Ian King
There is a spelling mistake in a ksft_test_result_skip message. Fix it. Signed-off-by: Colin Ian King --- tools/testing/selftests/kvm/s390x/cpumodel_subfuncs_test.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tools/testing/selftests/kvm/s390x/cpumodel_subfuncs_test.c b/t

Re: [PATCH v2 3/3] softirq: Use a dedicated thread for timer wakeups on PREEMPT_RT.

2024-10-30 Thread Sebastian Andrzej Siewior
On 2024-10-29 22:47:21 [+0100], Frederic Weisbecker wrote: > Le Tue, Oct 29, 2024 at 02:52:31PM +0100, Sebastian Andrzej Siewior a écrit : > > On 2024-10-28 15:01:55 [+0100], Frederic Weisbecker wrote: > > > > diff --git a/include/linux/interrupt.h b/include/linux/interrupt.h > > > > index 457151f9

[PATCH bpf-next] selftests/bpf: Fix compile error when MPTCP not support

2024-10-30 Thread Tao Chen
Fix compile error when MPTCP feature not support, though eBPF core check already done which seems invalid in this situation, the error info like: progs/mptcp_sock.c:49:40: error: no member named 'is_mptcp' in 'struct tcp_sock' 49 | is_mptcp = bpf_core_field_exists(tsk->is_mptcp) ? The f

Re: [RFC PATCH 15/39] KVM: guest_memfd: hugetlb: allocate and truncate from hugetlb

2024-10-30 Thread Jun Miao
Hi Ackerley, Due to actual customer requirements(such as ByteDance), I have added support for NUMA policy based on your foundation. Standing on the shoulders of giants, please correct me if there is anyting wrong. --- Thanks Jun.miao On 2024/9/11 07:43, Ackerley Tng wrote: If HugeTLB is requ

Re: [PATCH v2 1/3] rust: kunit: add KUnit case and suite macros

2024-10-30 Thread Alice Ryhl
On Wed, Oct 30, 2024 at 5:59 AM David Gow wrote: > > On Tue, 29 Oct 2024 at 20:08, Alice Ryhl wrote: > > > > On Tue, Oct 29, 2024 at 10:24 AM David Gow wrote: > > > > > > From: José Expósito > > > > > > Add a couple of Rust const functions and macros to allow to develop > > > KUnit tests withou

Re: [PATCH] scripts: Remove export_report.pl

2024-10-30 Thread Masahiro Yamada
On Tue, Oct 29, 2024 at 10:12 PM Matthew Maurer wrote: > > This script has been broken for 5 years with no user complaints. > > It first had its .mod.c parser broken in commit a3d0cb04f7df ("modpost: > use __section in the output to *.mod.c"). Later, it had its object file > enumeration broken in

Re: [PATCH] selftest/hid: increase timeout to 10 min

2024-10-30 Thread Benjamin Tissoires
On Oct 29 2024, Shuah Khan wrote: > On 10/29/24 03:07, Yun Lu wrote: > > If running hid testcases with command "./run_kselftest.sh -c hid", > > NIT - When inestead of "If" > > the following tests will take longer than the kselftest framework > > timeout (now 200 seconds) to run and thus got termin