Official MINIX sources - Automatically replicated from gerrit.minix3.org
Go to file
David van Moolenbroek dbcce9ddb0 libnetdriver: turn into network driver framework
The new implementation of this library provides abstractions for
network drivers, and should be used for all network drivers from now
on.  It provides the following functionality:

  - a function call table abstraction, hiding the details of the
    datalink protocol with simple parameters;
  - a state machine for sending and receiving packets, freeing the
    actual driver from keeping track of pending requests;
  - an abstraction for copying data from and to the network driver,
    freeing the actual driver from dealing with I/O vectors while at
    the same time providing a copy implementation which is more
    efficient than most current driver implementations;
  - a generalized implementation of zero-copy port-based I/O;
  - a clearer set of policies and defaults.

While the concept is very similar to lib{block,char,fs,input}driver,
one main difference is that libnetdriver now also takes care of SEF
initialization, mainly so that aspects such as recovery policies and
live-update aspects can be changed for all network drivers in a
single place.  As always, for the case that the provided message loop
is too restrictive, a set of more low-level message processing
functions is provided.

The netdriver API has been designed so as to allow alleviation of one
current protocol bottleneck: the fact that at most one send request
and one receive request may be pending at any time.  Changing this
aspect will however require a significant rewrite of libnetdriver,
and possibly debugging of drivers that are not able to cope with (in
particular) queuing multiple packets for transmission at once.

Beyond that, the design of the new API is based on the current
protocol, and may be changed/extended later to allow for non-ethernet
network drivers, exposure of link status, multicast address
configuration, suspend and resume, and any other features that are in
fact long overdue.

Change-Id: I47ec47e05852c42f92af04549d41524f928efec2
2014-12-04 12:10:48 +00:00
bin Importing bin/sh 2014-08-29 12:56:04 -04:00
common Fix -DNDEBUG support 2014-08-22 19:12:17 +02:00
distrib Import a few manpages 2014-11-25 11:04:20 +01:00
docs Clearing history in docs/UPDATING 2014-08-01 14:58:40 +02:00
etc dp8390: update, allow default port and IRQ 2014-12-04 12:10:46 +00:00
external Importing external/mit/xorg support rules 2014-11-10 14:43:29 +01:00
games Import NetBSD games/fish command. 2014-09-25 02:03:28 +02:00
gnu Update download urls in fetch.sh 2014-08-07 14:27:32 +02:00
include New sources layout 2014-07-31 16:00:30 +02:00
lib libfsdriver: prefill st_dev for stat requests 2014-11-14 15:54:16 +00:00
libexec LLVM Minix changes 2014-07-28 17:05:59 +02:00
minix libnetdriver: turn into network driver framework 2014-12-04 12:10:48 +00:00
releasetools Fix OS X crossbuilds for arm 2014-10-10 12:56:41 +02:00
sbin INIT died problem / build system robustness 2014-08-28 08:52:50 +02:00
share Fix for TOOL_CPP 2014-11-28 07:22:52 -05:00
sys Importing external/mit/xorg support rules 2014-11-10 14:43:29 +01:00
tests LLVM Minix changes 2014-07-28 17:05:59 +02:00
tools buildsystem: fix build errors for x86 on OSX 2014-11-04 11:00:29 +01:00
usr.bin Replace NetBSD grep with OpenBSD grep 2014-09-30 18:09:56 +00:00
usr.sbin Import NetBSD shell environment files 2014-11-10 16:48:56 +01:00
.gitignore gitignore: ignore some more generated files 2012-12-06 13:29:20 +00:00
.gitreview build:update 'git review' config to match gerrit.minix3.org 2014-07-28 17:05:15 +02:00
build.sh Importing netbsd clang -- pristine 2014-07-28 17:05:57 +02:00
LICENSE Fix parameter parsing in cut 2010-01-21 10:16:05 +00:00
Makefile INIT died problem / build system robustness 2014-08-28 08:52:50 +02:00
Makefile.inc Synchronize on NetBSD-CVS (2013/12/1 12:00:00 UTC) 2014-07-28 17:05:06 +02:00