Files
openflow/README.hwtables
T
Ben Pfaff 89d08b1a17 Modified the naming scheme for hardware tables.
Because of historical string munging during the kernel build process
if you named your hardware table hwtable-something, when it was built
the filename would look appropriate, but the actual module info would change
the internal name to be hwtable_something, thus after an insmod with the filename
you could not perform an rmmod with the same filename. As a result
the naming scheme has been changed to hwtable_NAME, NAME being the hardware
the table supports.

Further, include files in the hardware table should be prefixed with the
folder name, e.g. #include "hwtable_NAME/my_header.h".

Based on commits from David Erickson <derickso@stanford.edu>.
2008-06-26 16:21:18 -07:00

39 lines
1.9 KiB
Plaintext

Hardware Table Support -*- text -*-
----------------------
The OpenFlow reference implementation in this distribution provides a
mechanism to support hardware that can accelerate OpenFlow switching.
The mechanism consists of the ability to add a "hardware acceleration"
switching table ahead of the software switching tables implemented by
the reference implementation. The hardware switching table is
expected to handle any incoming packets that it can on its own. Any
packets that it cannot handle itself it may pass up to the software
table implementations.
Hardware table implementation are built as separate kernel modules
that may be loaded after the openflow module. At most one hardware
table module may be loaded at a time. Only datapaths created after a
hardware table module is loaded (and before it is unloaded) will take
advantage of hardware switching features.
Creating a hardware table module is straightforward. Create a
directory in the openflow source tree named datapath/hwtable_NAME,
where NAME identifies the hardware that the module supports. Populate
that directory with the C source files that comprise the module, plus
a file named Modules.mk that specifies how to build the module. This
distribution includes a "dummy" hardware module that demonstrates how
this works.
Even though only one may be loaded at a given time, any number of
hardware table modules may be built along with the OpenFlow kernel
modules. Specify each NAME that identifies a module to be built on
the OpenFlow configure script command as the argument to
--enable-hw-tables, e.g.:
./configure --enable-hw-tables=NAME
Each hardware table module's code is encapsulated in a directory, so
it is easy to separate a hardware table implementation from OpenFlow.
Simply package up the contents of the hwtable_NAME directory and
distribute it for builders to extract into their distribution
directory.