syzbot has found a reproducer for the following issue on:
HEAD commit:7b24f164cf00 Merge tag 'ipsec-next-2025-01-09' of git://gi..
git tree: net-next
console+strace: https://syzkaller.appspot.com/x/log.txt?x=168791df98
kernel config: https://syzkaller.appspot.com/x/.config?x=28dc37e
Hi Haoran,
On Sat, Jan 11, 2025 at 11:34:18AM +0800, Haoran Zhang wrote:
> Since commit 3f8ca2e115e55 ("vhost scsi: alloc cmds per vq instead of
> session"), a bug can be triggered when the host sends a duplicate
> VHOST_SCSI_SET_ENDPOINT ioctl command.
>
> In vhost_scsi_set_endpoint(), if the
From: Jason Gunthorpe
The new function is used to take in a u64 MSI address and store it in the
msi_msg. If the iommu has provided an alternative address then that is
replaced instead.
All callers have a tidy u64 already so this also consolidates the repeated
low/high code into a small helper.
Since commit 3f8ca2e115e55 ("vhost scsi: alloc cmds per vq instead of
session"), a bug can be triggered when the host sends a duplicate
VHOST_SCSI_SET_ENDPOINT ioctl command.
In vhost_scsi_set_endpoint(), if the new `vhost_wwpn` matches the old tpg's
tport_name but the tpg is still held by curr
From: Jason Gunthorpe
SW_MSI supports IOMMU to translate an MSI message before the MSI message
is delivered to the interrupt controller. On such systems the iommu_domain
must have a translation for the MSI message for interrupts to work.
The IRQ subsystem will call into IOMMU to request that a p
Add a new VFIO_IRQ_SET_ACTION_PREPARE to set VFIO_IRQ_SET_DATA_MSI_IOVA,
giving user space an interface to forward to kernel the stage-1 IOVA (of
a 2-stage translation: IOVA->IPA->PA) for an MSI doorbell address, since
the ITS hardware needs to be programmed with the top level IOVA address,
in orde
As the bridge between iommufd core and vfio core, add a set of msi_iova
helpers to call the new msi_iova helpers from the iommufd_device level.
The next patch will use this bridging helpers in vfio-pci code.
Signed-off-by: Nicolin Chen
---
include/linux/vfio.h | 25 +
Add a resizable array "msi_iovas" to store the user space IOVAs for its
vMSI(x) vectors. And use the corresponding IOVA for set the msi_desc in
the iommufd_sw_msi(). This allows irqchip driver to program the correct
MSI doorbell addresses (in case of requiring IOMMU translations).
Provide a set of
Also add fail_nth coverage too.
Signed-off-by: Nicolin Chen
---
tools/testing/selftests/iommu/iommufd.c | 53 +++
.../selftests/iommu/iommufd_fail_nth.c| 14 +
2 files changed, 67 insertions(+)
diff --git a/tools/testing/selftests/iommu/iommufd.c
b/tools/testi
For systems that require MSI pages to be mapped into the IOMMU translation
the IOMMU driver provides an IOMMU_RESV_SW_MSI range, which is the default
recommended IOVA window to place these mappings. However, there is nothing
special about this address. And to support the RMR trick in VMM for nested
From: Jason Gunthorpe
iommufd has a model where the iommu_domain can be changed while the VFIO
device is attached. In this case the MSI should continue to work. This
corner case has not worked because the dma-iommu implementation of sw_msi
is tied to a single domain.
Implement the sw_msi mapping
Now, iommufd has its own iommufd_sw_msi using iommufd_hwpt, the iommufd
owned domain's private pointer. Similarly, iova_cookie can be seen as a
dma-iommu owned domain's private pointer. So, move iova_cookie into the
union.
Signed-off-by: Nicolin Chen
---
include/linux/iommu.h | 2 +-
1 file chan
"attach_handle" was added exclusively for the iommufd_fault_iopf_handler()
used by IOPF/PRI use cases, along with the "fault_data". Now, the iommufd
version of sw_msi function will resue the attach_handle and fault_data for
a non-fault case.
Move the attach_handle part out of the fault.c file to m
A "fault_data" was added exclusively for the iommufd_fault_iopf_handler()
used by IOPF/PRI use cases, along with the attach_handle. Now, the iommufd
version of sw_msi function will resue the attach_handle and fault_data for
a non-fault case.
Rename "fault_data" to "iommufd_hwpt" so as not to confi
From: Jason Gunthorpe
Currently IRQ_MSI_IOMMU is selected if DMA_IOMMU is available to provide
an implementation for iommu_dma_prepare/compose_msi_msg(). However it
makes more sense for the irqchips that call prepare/compose to select it
and that will trigger all the additional code and data to b
From: Jason Gunthorpe
All the iommu cases simply want to override the MSI page's address with
the IOVA that was mapped through the iommu. This doesn't need a cookie
pointer, we just need to store the IOVA and its page size in the msi_desc.
Instead provide msi_desc_set_iommu_msi_iova() which allo
[ Background ]
On ARM GIC systems and others, the target address of the MSI is translated
by the IOMMU. For GIC, the MSI address page is called "ITS" page. When the
IOMMU is disabled, the MSI address is programmed to the physical location
of the GIC ITS page (e.g. 0x2020). When the IOMMU is ena
On 1/10/25 1:21 AM, Bastien Curutchet (eBPF Foundation) wrote:
+static void ping_test(struct test_data *data)
+{
+ struct test_xdp_redirect *skel = NULL;
+ struct xdp_dummy *skel_dummy = NULL;
+ struct nstoken *nstoken = NULL;
+ int i, ret;
+
+ skel_dummy = xdp_dummy
Hello:
This series was applied to bpf/bpf-next.git (master)
by Martin KaFai Lau :
On Fri, 10 Jan 2025 10:21:08 +0100 you wrote:
> Hi all,
>
> This patch series continues the work to migrate the *.sh tests into
> prog_tests.
>
> test_xdp_redirect.sh tests the XDP redirections done through
> bpf_
On Fri, Jan 10, 2025 at 08:37:46AM +0100, Sven Schnelle wrote:
> "Dmitry V. Levin" writes:
>
> > Similar to syscall_set_arguments() that complements
> > syscall_get_arguments(), introduce syscall_set_nr()
> > that complements syscall_get_nr().
> >
> > syscall_set_nr() is going to be needed along
On Fri, 10 Jan 2025 15:35:23 +0100 Alessandro Zanni wrote:
> On Fri, Jan 10, 2025 at 04:09:07AM +, Hangbin Liu wrote:
> > On Fri, Jan 10, 2025 at 01:07:44AM +0100, Alessandro Zanni wrote:
> > > Running "make kselftest TARGETS=net/forwarding" results in several
> > > occurrences of the same er
On Fri, Jan 10, 2025 at 03:35:23PM +0100, Alessandro Zanni wrote:
> On Fri, Jan 10, 2025 at 04:09:07AM +, Hangbin Liu wrote:
> > On Fri, Jan 10, 2025 at 01:07:44AM +0100, Alessandro Zanni wrote:
> > > Running "make kselftest TARGETS=net/forwarding" results in several
> > > occurrences of the sa
Kernel already supports splitting a folio to any lower order. Test it.
Signed-off-by: Zi Yan
---
tools/testing/selftests/mm/split_huge_page_test.c | 13 -
1 file changed, 8 insertions(+), 5 deletions(-)
diff --git a/tools/testing/selftests/mm/split_huge_page_test.c
b/tools/testing/
Otherwise the number of tests does not match the reality.
Fixes: 391e86971161 ("mm: selftest to verify zero-filled pages are mapped to
zeropage")
Signed-off-by: Zi Yan
---
.../selftests/mm/split_huge_page_test.c | 34 +++
1 file changed, 12 insertions(+), 22 deletions(-)
On 10.01.25 21:26, Joe Damato wrote:
Slight refactor to prepare the code for NAPI to queue mapping. No
functional changes.
Signed-off-by: Joe Damato
---
drivers/net/virtio_net.c | 10 --
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/drivers/net/virtio_net.c b/drivers/
On Fri, Jan 10, 2025 at 09:35:11AM +0100, Stefano Garzarella wrote:
> Recent reports have shown how we sometimes call vsock_*_has_data()
> when a vsock socket has been de-assigned from a transport (see attached
> links), but we shouldn't.
>
> Previous commits should have solved the real problems,
Hello:
This patch was applied to bpf/bpf-next.git (master)
by Andrii Nakryiko :
On Thu, 9 Jan 2025 16:42:29 -0700 you wrote:
> `-l2 -v` is a useful combination of flags to dump the entire
> verification log. This is helpful when making changes to the verifier,
> as you can see what it thinks pro
On Fri, Jan 10, 2025 at 09:35:09AM +0100, Stefano Garzarella wrote:
> During virtio_transport_release() we can schedule a delayed work to
> perform the closing of the socket before destruction.
>
> The destructor is called either when the socket is really destroyed
> (reference counter to zero), o
On Fri, Jan 10, 2025 at 09:35:07AM +0100, Stefano Garzarella wrote:
> If the socket has been de-assigned or assigned to another transport,
> we must discard any packets received because they are not expected
> and would cause issues when we access vsk->transport.
>
> A possible scenario is describ
On Thu, Jan 9, 2025 at 3:42 PM Daniel Xu wrote:
>
> `-l2 -v` is a useful combination of flags to dump the entire
> verification log. This is helpful when making changes to the verifier,
> as you can see what it thinks program one instruction at a time.
>
> This was more or less a hidden feature be
On Fri, Jan 10, 2025 at 2:49 AM Saket Kumar Bhaskar wrote:
>
> On Thu, Nov 21, 2024 at 04:00:13PM -0800, Andrii Nakryiko wrote:
> > On Wed, Nov 20, 2024 at 6:52 AM Saket Kumar Bhaskar
> > wrote:
> > >
> > > On Fri, Nov 08, 2024 at 10:43:54AM -0800, Andrii Nakryiko wrote:
> > > > On Sun, Nov 3, 2
The ovpn-cli tool can be compiled and used as selftest for the ovpn
kernel module.
[NOTE: it depends on libmedtls for decoding base64-encoded keys]
ovpn-cli implements the netlink and RTNL APIs and can thus be integrated
in any script for more automated testing.
Along with the tool, 4 scripts ar
Add basic infrastructure for handling ovpn interfaces.
Tested-by: Donald Hunter
Signed-off-by: Antonio Quartulli
---
Documentation/netlink/specs/rt_link.yaml | 16 +
drivers/net/ovpn/Makefile| 1 +
drivers/net/ovpn/io.c| 22 ++
drivers/net/ovpn/io
Whenever a peer is deleted, send a notification to userspace so that it
can react accordingly.
This is most important when a peer is deleted due to ping timeout,
because it all happens in kernelspace and thus userspace has no direct
way to learn about it.
Signed-off-by: Antonio Quartulli
---
dr
This change introduces the netlink command needed to add, delete and
retrieve/dump known peers. Userspace is expected to use these commands
to handle known peer lifecycles.
Signed-off-by: Antonio Quartulli
---
drivers/net/ovpn/netlink.c | 630 -
driver
IV wrap-around is cryptographically dangerous for a number of ciphers,
therefore kill the key and inform userspace (via netlink) should the
IV space go exhausted.
Userspace has two ways of deciding when the key has to be renewed before
exhausting the IV space:
1) time based approach:
after X se
Implement support for basic ethtool functionality.
Note that ovpn is a virtual device driver, therefore
various ethtool APIs are just not meaningful and thus
not implemented.
Signed-off-by: Antonio Quartulli
Reviewed-by: Andrew Lunn
---
drivers/net/ovpn/main.c | 15 +++
1 file chan
A peer connected via UDP may change its IP address without reconnecting
(float).
Add support for detecting and updating the new peer IP/port in case of
floating.
Signed-off-by: Antonio Quartulli
---
drivers/net/ovpn/io.c | 4 +
drivers/net/ovpn/peer.c | 243 +
This change introduces the netlink commands needed to add, get, delete
and swap keys for a specific peer.
Userspace is expected to use these commands to create, inspect (non
sensitive data only), destroy and rotate session keys for a specific
peer.
Signed-off-by: Antonio Quartulli
---
drivers/n
OpenVPN supports configuring a periodic keepalive packet.
message to allow the remote endpoint detect link failures.
This change implements the keepalive sending and timer expiring logic.
Signed-off-by: Antonio Quartulli
---
drivers/net/ovpn/io.c | 77 +
drivers/net/ovp
In case of UDP links, the local endpoint used to communicate with a
given peer may change without a connection restart.
Add support for learning the new address in case of change.
Signed-off-by: Antonio Quartulli
---
drivers/net/ovpn/peer.c | 45 +
dr
With this change an ovpn instance will be able to stay connected to
multiple remote endpoints.
This functionality is strictly required when running ovpn on an
OpenVPN server.
Signed-off-by: Antonio Quartulli
---
drivers/net/ovpn/main.c | 67 +-
drivers/net/ovpn/ovpnstruct
In a multi-peer scenario there are a number of situations when a
specific peer needs to be looked up.
We may want to lookup a peer by:
1. its ID
2. its VPN destination IP
3. its transport IP/port couple
For each of the above, there is a specific routing table referencing all
peers for fast look u
Userspace may want to pass the MSG_NOSIGNAL flag to
tcp_sendmsg() in order to avoid generating a SIGPIPE.
To pass this flag down the TCP stack a new skb sending API
accepting a flags argument is introduced.
Cc: Eric Dumazet
Cc: Paolo Abeni
Signed-off-by: Antonio Quartulli
---
drivers/net/ovpn
With this change ovpn is allowed to communicate to peers also via TCP.
Parsing of incoming messages is implemented through the strparser API.
Note that ovpn redefines sk_prot and sk_socket->ops for the TCP socket
used to communicate with the peer.
For this reason it needs to access inet6_stream_op
When sending an skb over a socket using skb_send_sock_locked(),
it is currently not possible to specify any flag to be set in
msghdr->msg_flags.
However, we may want to pass flags the user may have specified,
like MSG_NOSIGNAL.
Extend __skb_send_sock() with a new argument 'flags' and add a
new in
This change implements encryption/decryption and
encapsulation/decapsulation of OpenVPN packets.
Support for generic crypto state is added along with
a wrapper for the AEAD crypto kernel API.
Signed-off-by: Antonio Quartulli
---
drivers/net/Kconfig| 4 +
drivers/net/ovpn/Makefile
inet6_stream_ops is currently non-static and also declared in
include/net/ipv6.h, however, it is not exported for usage in
non-builtin modules.
Export inet6_stream_ops via EXPORT_SYMBOL_GPL in order to make
it available to non-builtin modules.
Cc: David Ahern
Cc: Eric Dumazet
Cc: Jakub Kicinski
Byte/packet counters for in-tunnel and transport streams
are now initialized and updated as needed.
To be exported via netlink.
Signed-off-by: Antonio Quartulli
---
drivers/net/ovpn/Makefile | 1 +
drivers/net/ovpn/io.c | 12 +++-
drivers/net/ovpn/peer.c | 2 ++
drivers/net/ovpn
Packets received over the socket are forwarded to the user device.
Implementation is UDP only. TCP will be added by a later patch.
Note: no decryption/decapsulation exists yet, packets are forwarded as
they arrive without much processing.
Signed-off-by: Antonio Quartulli
---
drivers/net/ovpn/i
Packets sent over the ovpn interface are processed and transmitted to the
connected peer, if any.
Implementation is UDP only. TCP will be added by a later patch.
Note: no crypto/encapsulation exists yet. Packets are just captured and
sent.
Signed-off-by: Antonio Quartulli
---
drivers/net/Kconf
This specific structure is used in the ovpn kernel module
to wrap and carry around a standard kernel socket.
ovpn takes ownership of passed sockets and therefore an ovpn
specific objects is attached to them for status tracking
purposes.
Initially only UDP support is introduced. TCP will come in a
An ovpn_peer object holds the whole status of a remote peer
(regardless whether it is a server or a client).
This includes status for crypto, tx/rx buffers, napi, etc.
Only support for one peer is introduced (P2P mode).
Multi peer support is introduced with a later patch.
Along with the ovpn_pee
An ovpn interface configured in MP mode will keep carrier always
on and let the user decide when to bring it administratively up and
down.
This way a MP node (i.e. a server) will keep its interface always
up and running, even when no peer is connected.
Signed-off-by: Antonio Quartulli
---
drive
This commit introduces basic netlink support with family
registration/unregistration functionalities and stub pre/post-doit.
More importantly it introduces the YAML uAPI description along
with its auto-generated files:
- include/uapi/linux/ovpn.h
- drivers/net/ovpn/netlink-gen.c
- drivers/net/ovpn
Notable changes since v16:
* fixed usage of netdev tracker by removing dev_tracker member from
ovpn_priv and adding it to ovpn_peer and ovpn_socket as those are the
objects really holding a ref to the netdev
* switched ovpn_get_dev_from_attrs() to GFP_ATOMIC to prevent sleep under
rcu_read_lo
OpenVPN is a userspace software existing since around 2005 that allows
users to create secure tunnels.
So far OpenVPN has implemented all operations in userspace, which
implies several back and forth between kernel and user land in order to
process packets (encapsulate/decapsulate, encrypt/decrypt
On 10.01.25 21:26, Joe Damato wrote:
Use netif_queue_set_napi to map NAPIs to queue IDs so that the mapping
can be accessed by user apps.
$ ethtool -i ens4 | grep driver
driver: virtio_net
$ sudo ethtool -L ens4 combined 4
$ ./tools/net/ynl/pyynl/cli.py \
--spec Documentation/netlink/s
On 10.01.25 21:26, Joe Damato wrote:
Prepare for NAPI to queue mapping by holding RTNL in code paths where
NAPIs will be mapped to queue IDs and RTNL is not currently held.
Signed-off-by: Joe Damato
---
drivers/net/virtio_net.c | 17 ++---
1 file changed, 14 insertions(+), 3 de
On 1/9/25 11:52 PM, Nikunj A. Dadhania wrote:
>
>
> On 11/15/2024 5:10 AM, Pratik R. Sampat wrote:
>> Add the X86_FEATURE_SNP CPU feature to the architectural definition for
>> the SEV-SNP VM type to exercise the KVM_SEV_INIT2 call. Ensure that the
>> SNP test is skipped in scenarios where CPU
Hi Nikunj,
On 1/9/25 11:21 PM, Nikunj A. Dadhania wrote:
>
>
> On 11/15/2024 5:10 AM, Pratik R. Sampat wrote:
>> On incompatible firmware versions, SEV-SNP support is pulled and the
>> setup is not performed. However, the platform and subsequently the KVM
>> capability may continue to advertize
Use netif_queue_set_napi to map NAPIs to queue IDs so that the mapping
can be accessed by user apps.
$ ethtool -i ens4 | grep driver
driver: virtio_net
$ sudo ethtool -L ens4 combined 4
$ ./tools/net/ynl/pyynl/cli.py \
--spec Documentation/netlink/specs/netdev.yaml \
--dump queue-g
Prepare for NAPI to queue mapping by holding RTNL in code paths where
NAPIs will be mapped to queue IDs and RTNL is not currently held.
Signed-off-by: Joe Damato
---
drivers/net/virtio_net.c | 17 ++---
1 file changed, 14 insertions(+), 3 deletions(-)
diff --git a/drivers/net/virtio
Slight refactor to prepare the code for NAPI to queue mapping. No
functional changes.
Signed-off-by: Joe Damato
---
drivers/net/virtio_net.c | 10 --
1 file changed, 8 insertions(+), 2 deletions(-)
diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c
index 7646ddd9bef7..cff1
Greetings:
Recently [1], Jakub mentioned that there were a few drivers that are not
yet mapping queues to NAPIs.
While I don't have any of the other hardware mentioned, I do happen to
have a virtio_net laying around ;)
I've attempted to link queues to NAPIs, taking care to hold RTNL when it
seem
On Thu, Jan 09, 2025 at 11:52:27AM +0100, Arnout Engelen wrote:
> On Fri, 3 Jan 2025 17:37:52 -0800, Luis Chamberlain wrote:
> > What distro which is using module signatures would switch
> > to this as an alternative instead?
>
> In NixOS, we disable MODULE_SIG by default (because we value
> repro
On Thu, 9 Jan 2025 22:38:27 +0500
Muhammad Usama Anjum wrote:
> Remove the following warnings by removing unused argc and argv
> parameters:
> In function ‘main’:
> warning: unused parameter ‘argc’ [-Wunused-parameter]
> 158 | int main(int argc, char *argv[])
> | ^~~~
On Sat, Jan 4, 2025 at 5:45 AM Sami Tolvanen wrote:
>
> Hi,
>
> Here's v8 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
Em 07/01/2025 13:23, Joe Lawrence escreveu:
On Thu, Jan 02, 2025 at 03:42:10PM -0300, Filipe Xavier wrote:
This new test makes sure that ftrace can trace a
function that was introduced by a livepatch.
Hi Filipe,
Thanks for adding a test!
Aside: another similar test could verify that the ori
On 2025-01-02 23:03, Stafford Horne wrote:
When working on OpenRISC support for restartable sequences I noticed
and fixed these two issues with the riscv support bits.
1 The 'inc' argument to RSEQ_ASM_OP_R_DEREF_ADDV was being implicitly
passed to the macro. Fix this by adding 'inc' to th
On 2025-01-10 05:22, Stafford Horne wrote:
Add support for OpenRISC in the rseq selftests. OpenRISC is 32-bit
only.
Tested this with:
Compiler: gcc version 14.2.0 (GCC)
Binutils: GNU assembler version 2.43.1 (or1k-smh-linux-gnu) using BFD
version (GNU Binutils) 2.43.1.20241207
On Wed, 08 Jan 2025 13:02:21 +0100, Krzysztof Kozlowski wrote:
> All Qualcomm firmwares uploaded to linux-firmware are in MBN format,
> instead of split MDT. No functional changes, just correct the DTS
> example so people will not rely on unaccepted files.
>
> Signed-off-by: Krzysztof Kozlowski
On 10/01/25 6:35 pm, Thomas Weißschuh wrote:
When mapping a larger chunk than physical memory is available with
PROT_WRITE and overcommit is disabled, the mapping will fail.
This will prevent the test from running on systems with less then ~1GiB
of memory and triggering an inscrutinable test f
On 10.01.25 14:05, Thomas Weißschuh wrote:
The virtual_address_range selftest reads from the start of each mapping
listed in /proc/self/maps.
However not all mappings are valid to be arbitrarily accessed.
For example the vvar data used for virtual clocks on x86 [vvar_vclock]
can only be accessed
On 10.01.25 14:05, Thomas Weißschuh wrote:
For each accessed chunk a PTE is created.
More than 1GiB of PTEs is used in this way.
Remove each PTE after validating a chunk to reduce peak memory usage.
It is important to only unmap memory that previously mmap()ed,
as unmapping other mappings like t
On 10.01.25 14:05, Thomas Weißschuh wrote:
When mapping a larger chunk than physical memory is available with
PROT_WRITE and overcommit is disabled, the mapping will fail.
This will prevent the test from running on systems with less then ~1GiB
of memory and triggering an inscrutinable test failur
David Reaver wrote:
> kmap_atomic() is deprecated and should be replaced with kmap_local_page()
> [1][2]. kmap_local_page() is faster in kernels with HIGHMEM enabled, can
> take page faults, and allows preemption.
Thanks for taking these on! It is good to see some progress here.
>
> According t
Hi Andrew,
On 08/01/25 20:33, Andrew Davis wrote:
On 1/3/25 4:12 AM, Beleswar Padhi wrote:
This series refactors a lot of functions & callbacks from
ti_k3_dsp_remoteproc.c
and ti_k3_m4_remoteproc.c drivers. This is the third and final series
as part of
the refactoring of K3 remoteproc drivers.
On Fri, Jan 10, 2025 at 04:09:07AM +, Hangbin Liu wrote:
> On Fri, Jan 10, 2025 at 01:07:44AM +0100, Alessandro Zanni wrote:
> > Running "make kselftest TARGETS=net/forwarding" results in several
> > occurrences of the same error:
> > ./lib.sh: line 787: teamd: command not found
> >
> > Since
On Thu, Jan 09, 2025 at 12:23:01AM -0800, Christoph Hellwig wrote:
> On Thu, Jan 09, 2025 at 09:12:03AM +0100, Greg Kroah-Hartman wrote:
> > > Hey, when I duplicated the method to convert sysfs over to a proper
> > > seq_file based approach that avoids buffer overflows you basically
> > > came up w
For each accessed chunk a PTE is created.
More than 1GiB of PTEs is used in this way.
Remove each PTE after validating a chunk to reduce peak memory usage.
It is important to only unmap memory that previously mmap()ed,
as unmapping other mappings like the stack, heap or executable mappings
will cr
The virtual_address_range selftest reads from the start of each mapping
listed in /proc/self/maps.
However not all mappings are valid to be arbitrarily accessed.
For example the vvar data used for virtual clocks on x86 [vvar_vclock]
can only be accessed if 1) the kernel configuration enables virtua
The selftest started failing since commit e93d2521b27f
("x86/vdso: Split virtual clock pages into dedicated mapping")
was merged. While debugging I stumbled upon some memory usage
optimizations.
With these test now runs on a VM with only 60MiB of memory.
Signed-off-by: Thomas Weißschuh
---
Chang
When mapping a larger chunk than physical memory is available with
PROT_WRITE and overcommit is disabled, the mapping will fail.
This will prevent the test from running on systems with less then ~1GiB
of memory and triggering an inscrutinable test failure.
As the mappings are never written to anywa
On Fri, Dec 27, 2024 at 2:52 AM Isaac J. Manjarres
wrote:
>
> Add tests to ensure that F_SEAL_FUTURE_EXEC behaves as expected.
>
> Signed-off-by: Isaac J. Manjarres
Reviewed-by: Alice Ryhl
On Fri, Jan 10, 2025 at 11:56:28AM +0100, Luigi Leonardi wrote:
On Fri, Jan 10, 2025 at 09:35:10AM +0100, Stefano Garzarella wrote:
Transport's release() and destruct() are called when de-assigning the
vsock transport. These callbacks can touch some socket state like
sock flags, sk_state, and pe
Thanks! This is now merged in my next tree.
On Mon, Nov 18, 2024 at 12:24:07PM +0800, Ba Jing wrote:
> After reviewing the code, it was found that these macros are never
> referenced in the code. Just remove them.
>
> Signed-off-by: Ba Jing
> ---
> tools/testing/selftests/landlock/ptrace_test.
On Fri, Jan 10, 2025 at 09:35:09AM +0100, Stefano Garzarella wrote:
During virtio_transport_release() we can schedule a delayed work to
perform the closing of the socket before destruction.
The destructor is called either when the socket is really destroyed
(reference counter to zero), or it can
On Fri, Jan 10, 2025 at 09:35:10AM +0100, Stefano Garzarella wrote:
Transport's release() and destruct() are called when de-assigning the
vsock transport. These callbacks can touch some socket state like
sock flags, sk_state, and peer_shutdown.
Since we are reassigning the socket to a new transp
On Thu, Nov 21, 2024 at 04:00:13PM -0800, Andrii Nakryiko wrote:
> On Wed, Nov 20, 2024 at 6:52 AM Saket Kumar Bhaskar
> wrote:
> >
> > On Fri, Nov 08, 2024 at 10:43:54AM -0800, Andrii Nakryiko wrote:
> > > On Sun, Nov 3, 2024 at 9:00 PM Saket Kumar Bhaskar
> > > wrote:
> > > >
> > > > Since co
On powerpc cache line size is 128 bytes, so skb_shared_info must be
aligned accordingly.
Signed-off-by: Saket Kumar Bhaskar
---
tools/testing/selftests/bpf/prog_tests/xdp_adjust_tail.c | 2 ++
tools/testing/selftests/bpf/progs/test_xdp_adjust_tail_grow.c | 2 ++
2 files changed, 4 insertion
Add support for OpenRISC in the rseq selftests. OpenRISC is 32-bit
only.
Tested this with:
Compiler: gcc version 14.2.0 (GCC)
Binutils: GNU assembler version 2.43.1 (or1k-smh-linux-gnu) using BFD
version (GNU Binutils) 2.43.1.20241207
Linux: Linux buildroot 6.13.0-rc2-5-g1
Implement support for restartable sequences on OpenRISC by doing:
- Select HAVE_RSEQ in Kconfig
- Call rseq_syscall() on return to userspace when CONFIG_DEBUG_RSEQ
is enabled.
- Call rseq_signal_deliver() to fixup the pre-signal stack frame when a
signal is delivered on top of a restartabl
From: Michael Jeanson
Support for HAVE_REGS_AND_STACK_ACCESS_API needed for restartable
sequences.
The implementation has been copied from riscv and tested with the
restartable sequences self tests.
Note, pt-regs members are 'long' on openrisc which require casts for the
api, someday we should
This series adds restartable sequences support to OpenRISC. This came after
discussions with Michael on the libc-alpha list where he added some preliminary
rseq support [1].
The changes use mostly the riscv port as a template.
The patches were tested with selftests on qemu using my glibc branch
On Thu, Jan 09, 2025 at 06:29:01PM -0800, Charlie Jenkins wrote:
> On Fri, Jan 03, 2025 at 04:03:26AM +, Stafford Horne wrote:
> > When working on OpenRISC support for restartable sequences I noticed
> > and fixed these two issues with the riscv support bits.
> >
> > 1 The 'inc' argument to R
On Fri, Jan 10, 2025 at 09:35:11AM +0100, Stefano Garzarella wrote:
Recent reports have shown how we sometimes call vsock_*_has_data()
when a vsock socket has been de-assigned from a transport (see attached
links), but we shouldn't.
Previous commits should have solved the real problems, but we m
test_xdp_redirect.sh can't be used by the BPF CI.
Migrate test_xdp_redirect.sh into a new test case in xdp_do_redirect.c.
It uses the same network topology and the same BPF programs located in
progs/test_xdp_redirect.c and progs/xdp_dummy.c.
Remove test_xdp_redirect.sh and its Makefile entry.
Sig
Hi all,
This patch series continues the work to migrate the *.sh tests into
prog_tests.
test_xdp_redirect.sh tests the XDP redirections done through
bpf_redirect().
These XDP redirections are already tested by prog_tests/xdp_do_redirect.c
but IMO it doesn't cover the exact same code path because
prog_tests/xdp_do_redirect.c is the only user of the BPF programs
located in progs/test_xdp_do_redirect.c and progs/test_xdp_redirect.c.
There is no need to keep both files with such close names.
Move test_xdp_redirect.c contents to test_xdp_do_redirect.c and remove
progs/test_xdp_redirect.c
Sign
1 - 100 of 110 matches
Mail list logo