Keyboard shortcuts

Press or to navigate between chapters

Press S or / to search in the book

Press ? to show this help

Press Esc to hide this help

Networking

This document describes the networking subsystem of the Kyronix kernel. It is the child of Kernel and parent of networking component documents.

Components

ComponentSourceDescription
Network Stacknet/net.clwIP initialization and polling
lwIP Gluenet/lwip_glue.cKernel memory allocator bridge
Kyronix Netifnet/netif/kyronix_netif.clwIP network interface driver
VirtIO-Netdrivers/virtio_net.cHardware NIC driver

Architecture

User-space (sockets)
    |
    v
Syscall layer (socket.c)
    |
    v
lwIP TCP/IP stack
    |
    v
kyronix_netif (lwIP netif)
    |
    v
virtio-net driver
    |
    v
QEMU virtio-net device

Network Configuration

SettingValue
IP Address10.0.2.15
Subnet Mask255.255.255.0 (/24)
Gateway10.0.2.2
DNS Server10.0.2.3

These are static addresses matching QEMU’s default user-mode networking (SLIRP) configuration.

Socket Types

TypeSourceDescription
Unix domainfs/unix_socket.cLocal IPC sockets
Internetfs/inet_socket.cTCP/UDP over lwIP

Functions

FunctionDescription
net_init()Initialize lwIP and register network interface
net_poll()Drain virtio-net RX queue, process lwIP timeouts
net_receive(frame, len)Feed raw Ethernet frame to lwIP

Last reviewed: 2026-07-22