Chapter 5. Interfaces: SLIP and Loopback

Introduction

In Chapter 4 we looked at the Ethernet interface. In this chapter we describe the SLIP and loopback interfaces, as well as the ioctl commands used to configure all network interfaces. The TCP compression algorithm used by the SLIP driver is described in Section 29.13. The loopback driver is straightforward and we discuss it here in its entirety.

Figure 5.1, which also appeared as Figure 4.2, lists the entry points to our three example drivers.

Table 5.1. Interface functions for the example drivers.

ifnet

Ethernet

SLIP

Loopback

Description

if_init

leinit

  

initialize hardware

if_output

ether_output

sloutput

looutput

accept and queue packet for transmission

if_start

lestart

  

begin transmission of frame

if_done ...

Get TCP/IP Illustrated now with O’Reilly online learning.

O’Reilly members experience live online training, plus books, videos, and digital content from 200+ publishers.