Skip to content

Latest commit

 

History

2 Commits

Folders and files

NameName
Last commit message
Last commit date
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

knic

knic is a small educational Linux virtual Ethernet driver. It creates a paired knic0 and knic1; packets transmitted by one interface are delivered to the other.

Current features:

  • Multiple bounded RX queues
  • Per-queue NAPI polling and GRO
  • TX subqueue backpressure
  • Synchronized network statistics
  • Basic ethtool driver, channel, and statistics support
  • Network namespace and lifecycle stress tests

Build

Install the compiler, make, and headers for the running kernel, then run:

make
sudo insmod knic.ko

Test

The namespace test configures both interfaces and tests traffic in both directions:

./scripts/ns_test.sh

For repeated traffic and module lifecycle testing:

./scripts/stress_lifecycle.sh

Inspect the driver with:

ethtool -i knic0
ethtool -l knic0
ethtool -S knic0

Cleanup

./scripts/cleanup.sh
make clean

This driver is intended for learning and does not control real hardware.

About

`knic` is a small educational Linux virtual Ethernet driver. It creates a paired `knic0` and `knic1`; packets transmitted by one interface are delivered to the other..

Resources

Stars

0 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages