This allows us to have DHCP clients that don't actually bind or unbind
a network device's IP address. This is useful for doing controller
discovery without actually reconfiguring a network device.
The secure channel, in discovery mode, wants to enable TCP connections
by default only if SSL has not been configured. This function allows
it to do that.
Similarly for buffer_reserve_tailroom.
The new name better reflects what they do, and make way for a different
use of the term "reserve" in the upcoming buffer_reserve() function.
The secchan needs to handle ARP requests from the controller itself, so
it has to translate the controller's IP address into a MAC address to
allow it to match those packets on dl_src. (OpenFlow doesn't allow us
to look into ARP packets and match on the encapsulated IP addresses, so
this is the best we can do.)
It can happen that the secure channel thinks that it is connected
to the controller, but in fact the connection has dropped. For
example, a switch intermediate between the secure channel and the
controller could have a flow inserted, due to a malfunction, that
causes packets in one direction or the other to be dropped. When
this happens, the Linux kernel's TCP implementation will continue
retransmitting packets for somewhere between 13 and 30 minutes,
depending on the connection's retransmission timeout (according
to linux/Documentation/networking/ip-sysctl.txt) with the default
Linux settings.
We want to detect the lost connection and re-connect much faster
than that. We use OpenFlow echo request and reply messages: if
no message is received from the controller for N seconds, we
send out an echo request. If no reply (actually, any message at
all) is received for an additional N seconds, then we assume
that the connection has been lost, and reconnect.
The new OFPT_ECHO_REQUEST and OFPT_ECHO_REPLY OpenFlow messages
have the same functionality and are more general (in that they
are not Netlink-specific).
This allows us to open network devices without bringing them up
and setting them for promiscuous mode, which will be useful in the
secchan for in-band communication.