Integration steps to put the TCP code into RouterWare
-----------------------------------------------------

1. Handle NVRAM configuration.
	VNVRAM.H should take care of section TCP Transport
	It does it already.
2. Handle module initialisation.

	In VRTRWSTR.H, in the structure "routerware_protocol_software",
	include
		{TRUE,initialize_tcp,(ULONG)NULL}
	This statement is infact there. Also the same for sockets.

	So I need a intialize_tcp function.

3. In IPASSEM.C, function pass_ip_packet_to_upper_layer() needs to
   be modified to consider and pass packet upto TCP layer.

4. The socket library initialization routine will (if __LSL__ is defined)
   take care of calling the registered tcp_control() function. tcp_control()
   is registered in initialize_tcp(). 

   So we need a tcp_control() function.

5. The other_transport_protocols in IP need not be bothered with and can be
   left at 0.
   
6. IP should give a function get_ip_address() to get the internal IP
   node address.
Socket library intergration
---------------------------
1. Need to have a configuration or control function that supports the
   following commands for TCP

   enum TRANSPORT_CONTROL_OPERATION
   {
   	OPEN_TRANSPORT,
   	CLOSE_TRANSPORT,
   	IS_TRANSPORT_ENABLED,
   	INITIALIZE_SOCKET_TRANSPORT_INTERFACE,
   	INITIALIZE_TRANSPORT_FUNCTION_POINTERS
   };
   
   The control function is called with 3 parameters. The first is the
   command as above. The last 2 are 2 parameters which need to be cast
   as desired.
  
2. lslctrl.c, in the function lsl_configuration() needs the case
   APPLICATION_LAYER_TYPE to be added. This is to allow apps (over socket
   library) to interact with the socklib. Specifically we need a 
   function to retrieve the error code.
   This particular case should call the function
   	lsl_pass_parameters_to_application () in its case execution.

3. The send and receive socklib available from RouterWare do not allow
   a return of -1 indicating error.

4. In the socket library, in sockcnfg.c, in the function 
   socket_configuration(), an extra case for INITIALIZE_FUNCTION_POINTERS
   needs to be given. In this case, pass pointers to suitable (one of
   which will set the error code field) functions in the socket library
   that may be called by TCP or UDP or other layers. At the TCP or UDP
   ends, call lsl_control() asking for this command to be executed on
   the sockets interface and with a pointer to a structure of function
   pointers that can be filled in.
   Also a structure SOCKET_FUNCTION_POINTERS seems to be needed.
   NOTE: All this stuff is there in the latest versions of RouterWare.

5. In the socket library accept() call support, we need to added code
   for error conditions to set ready_socket to FALSE.

6. Two functions may also need to be called by apps.
	associate_application_with_socket()
	set_type_of_service()
7. The UDP code to allocate and free send and receive buffers
    udp_user_get_buffer() and udp_user_free_buffer() seem to be
    fishy. Looks like they will steadily lose buffer space.


