Page MenuHomeFreeBSD

tests/netlink: add netlink socket buffer test
ClosedPublic

Authored by glebius on Nov 9 2023, 6:31 AM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Jun 27, 3:01 AM
Unknown Object (File)
Wed, Jun 26, 10:31 PM
Unknown Object (File)
Wed, Jun 26, 10:31 PM
Unknown Object (File)
Fri, Jun 21, 7:00 PM
Unknown Object (File)
Thu, Jun 20, 5:20 AM
Unknown Object (File)
Fri, Jun 7, 12:20 AM
Unknown Object (File)
Wed, Jun 5, 8:34 PM
Unknown Object (File)
Wed, Jun 5, 12:18 PM

Details

Summary

With upcoming protocol specific socket buffer for Netlink we need some
additional tests that cover basic socket operations, w/o much of actual
Netlink knowledge. Following tests are performed:

  1. Overflow. If an application keeps sending messages to the kernel,

but doesn't read out the replies, then first the receive buffer shall
fill and after that further messages from applications will be queued
on the send buffer until it is filled. After that socket operations
should block. However, reading from the receive buffer some data should
wake up the taskqueue and the send buffer should start draining again.

  1. Peek & trunc. Check that socket correctly reports amount of readable

data with MSG_PEEK & MSG_TRUNC. This typical pattern of Netlink apps.

Diff Detail

Repository
rG FreeBSD src repository
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Add CMSG testing to the size test.

This revision is now accepted and ready to land.Dec 26 2023, 7:40 PM