mbox series

[net-next,v3,0/3] add skb_segment kunit coverage

Message ID 20231009144205.269931-1-willemdebruijn.kernel@gmail.com (mailing list archive)
Headers show
Series add skb_segment kunit coverage | expand

Message

Willem de Bruijn Oct. 9, 2023, 2:41 p.m. UTC
From: Willem de Bruijn <willemb@google.com>

As discussed at netconf last week. Some kernel code is exercised in
many different ways. skb_segment is a prime example. This ~350 line
function has 49 different patches in git blame with 28 different
authors.

When making a change, e.g., to fix a bug in one specific use case,
it is hard to establish through analysis alone that the change does
not break the many other paths through the code. It is impractical to
exercise all code paths through regression testing from userspace.

Add the minimal infrastructure needed to add KUnit tests to networking,
and add code coverage for this function.

Patch 1 adds the infra and the first simple test case: a linear skb
Patch 2 adds variants with frags[]
Patch 3 adds variants with frag_list skbs

Changelog in the individual patches.

Willem de Bruijn (3):
  net: add skb_segment kunit test
  net: parametrize skb_segment unit test to expand coverage
  net: expand skb_segment unit test with frag_list coverage

 net/Kconfig         |   9 ++
 net/core/Makefile   |   1 +
 net/core/gso_test.c | 274 ++++++++++++++++++++++++++++++++++++++++++++
 3 files changed, 284 insertions(+)
 create mode 100644 net/core/gso_test.c

Comments

patchwork-bot+netdevbpf@kernel.org Oct. 11, 2023, 9:40 a.m. UTC | #1
Hello:

This series was applied to netdev/net-next.git (main)
by David S. Miller <davem@davemloft.net>:

On Mon,  9 Oct 2023 10:41:50 -0400 you wrote:
> From: Willem de Bruijn <willemb@google.com>
> 
> As discussed at netconf last week. Some kernel code is exercised in
> many different ways. skb_segment is a prime example. This ~350 line
> function has 49 different patches in git blame with 28 different
> authors.
> 
> [...]

Here is the summary with links:
  - [net-next,v3,1/3] net: add skb_segment kunit test
    https://git.kernel.org/netdev/net-next/c/b3098d32ed6e
  - [net-next,v3,2/3] net: parametrize skb_segment unit test to expand coverage
    https://git.kernel.org/netdev/net-next/c/1b4fa28a8b07
  - [net-next,v3,3/3] net: expand skb_segment unit test with frag_list coverage
    https://git.kernel.org/netdev/net-next/c/4688ecb1385f

You are awesome, thank you!