summaryrefslogtreecommitdiff
path: root/src/ipcpd/normal
Commit message (Collapse)AuthorAgeFilesLines
...
* | Merged in dstaesse/ouroboros/be-split-fp (pull request #238)Sander Vrijders2016-09-022-3/+3
|\ \ | |/ |/| | | lib: Add northbound ringbuffers
| * lib: Add northbound ringbuffersdimitri staessens2016-09-022-3/+3
| | | | | | | | Fast path is split in north and southbound paths.
* | lib: ipcp: Decouple flow_deallocdimitri staessens2016-09-021-1/+1
|/ | | | Sending a dealloc to the irmd moved to its own call.
* lib, ipcp: Compile on Apple junkdimitri staessens2016-08-301-0/+2
| | | | | | Disables robust mutexes and clock attributes for condition variables for compatibility with OSX (SUSv2). Implements clock_gettime and adds some defines for OSX compatibility in time_utils.
* lib: Refactor shm_du_map to shm_rdrbuffdimitri staessens2016-08-291-7/+13
| | | | | | | | | | The shm_du_map is renamed to shm_rdrbuff to reflect the Random Deletion Ringbuffer used in the implementation. The close_on_exit call is removed and SDUs are cleaned up by the application in the ap_fini() call. This required a non-blocking peek() operation in the shm_ap_rbuff. Some initial implementation for future support of qos cubes has been added to the shm_rdrbuff.
* ipcpd: Report pid on shutdowndimitri staessens2016-08-261-2/+2
| | | | IPCPs will report their pid on shutdown for faster debugging.
* ipcpd, normal: Safe handling of CDAP requestsdimitri staessens2016-08-256-77/+282
| | | | Destruction of the object in the reply stage was unsafe.
* ipcpd: normal: Fix uninitialized valueSander Vrijders2016-08-251-6/+9
| | | | This removes the ret value which was not being set correctly.
* Merged in dstaesse/ouroboros/be-irmd-fix (pull request #222)Sander Vrijders2016-08-251-3/+4
|\ | | | | | | Fix locks
| * ipcpd, normal: Fix bad lockdimitri staessens2016-08-251-3/+4
| |
* | Merged in dstaesse/ouroboros/be-ipcp-locks (pull request #221)Sander Vrijders2016-08-243-86/+75
|\| | | | | | | ipcpd: Revised locking
| * ipcpd: Revised lockingdimitri staessens2016-08-243-86/+75
| | | | | | | | | | | | The state lock was reverted to an rwlock to avoid interference of management functions with the fast path. IPCPs now close without calling unsafe functions in the signal handler.
* | ipcpd: normal: Add initial steps for N+1 flow allocationSander Vrijders2016-08-238-33/+646
|/ | | | | | | | | | | This adds the initial framework for flow allocation between two N+1 endpoints. The FMGR will receive flow allocation requests and will create a connection as a result, addressed to the right address, it will also pass a flow allocation message to this address. Upon receipt on the other side, the FMGR will be receive a flow allocation message and a pointer to a new connection. The FMGR can then accept or destroy the connection. This commit also introduces the RMT function, which is needed by the FRCT to forward its SDUs on the right file descriptor.
* irmd, lib: Rebuild the IRMd data modeldimitri staessens2016-08-211-9/+0
| | | | | | | | | | | | | | | | | | | | | | The complete data model inside the IRMd has been restructured. The bind operation was revised to allow binding of AP and AP instances and register those names with different DIFs (see "irm bind" for details). Server applications require to call ap_init with a server name argument, client application that do not the be reachable over any DIF can call ap_init(NULL). Calling ap_init for a client with a specified name will not have adverse consequences for the application, but will consume unnecessary resources in the IRMd. Application servers can now be started at any point after the IRMd has been started. Starting servers, binding AP names and registering names in DIFs can be performed in any order that does not defy temporal logic. Supports naming instances by their pid. In case of IPCP Instances created with the IRM tool, the name assigned during "irm ipcp create" can be used. All the changes required updates in the tools.
* ipcpd: normal: Handle enrollment repliesSander Vrijders2016-08-192-10/+58
| | | | | | | | This adds a condition variable with a timeout to the CDAP request so that we can respond correctly to the answer from the remote. It also adds a timeout to the condition variable waiting on completion of enrollment. Furthermore, for every CDAP callback a new thread is now spawned, to avoid deadlocking in case a callback is stuck.
* ipcpd: Fix bootstrap with api_binddimitri staessens2016-08-122-9/+15
| | | | | Calling api_bind during bootstrap caused the IRMd to lock up. api_bind is now called after the normal completes bootstrapping.
* ipcpd: Add condition variable to IPCP stateSander Vrijders2016-08-113-72/+63
| | | | | | | This adds a condition variable to the IPCP state, so that upon state changes any listeners to state changes can be notified. It also replaces the read/write lock with a mutex in order to be able to do so.
* ipcpd: Fix deep copy of dif_configdimitri staessens2016-08-111-3/+5
| | | | | conf->dif_name was not copied from the dif_config gpb message. Fixes some logs.
* ipcpd: normal: Fix log messagedimitri staessens2016-08-111-1/+1
|
* lib, irmd: Bind AP instances to AP_subsetsdimitri staessens2016-08-101-0/+5
| | | | | | | This call will allow grouping AP instances of a certain AP together which are configured identically. Adds the bind operation to dev and updates the applications to make use of this call. Flow_alloc is now only called with the pid and doesn't send the apn anymore.
* ipcp, irmd, lib: Notify IRMd upon IPCP initializationSander Vrijders2016-08-101-0/+10
| | | | | | This will notify the IRMd when the IPCP is initialized and ready to receive messages. Previously a bootstrap could fail since the IPCP was not listening to the socket yet.
* ipcpd: normal: Allow exchange of static DIF informationSander Vrijders2016-08-087-27/+248
| | | | | | This adds the functionality of exchanging the static DIF information between 2 DIF members. After exchange the enrollment is stopped, and the IPCP that initiated enrollment transitions to the enrolled state.
* ipcpd: normal: Allow initiating enrollmentSander Vrijders2016-08-016-45/+74
| | | | | | | This will add more functionality for enrolling two normal IPCPs with each other. Some bugs were fixed in CDAP. Now on enrolling, an IPCP will send a START message to the other IPCP. Next step is syncing the RIBs.
* ipcpd: normal: Provide initial steps for enrollmentSander Vrijders2016-07-276-36/+369
| | | | | | This provides the normal IPCP with bootstrapping and the initial steps for enrollment. Next step is actually reacting to an enrollment request and sending the data transfer constants.
* ipcpd: normal: Add main loop to normal IPCPSander Vrijders2016-07-153-10/+261
| | | | | | This adds the main loop to the normal IPCP, just like it is present in the shim IPCPs. So in essence, the normal IPCP now reacts to all operations from ipcp.h.
* ipcpd: normal: Establish N-1 management flowsSander Vrijders2016-07-149-16/+407
| | | | | | | | | This adds the intial implementation of establishing management N-1 flows between normal IPCPs. On calling fmgr_mgmt_flow, a management flow will be setup to a certain destination IPCP. After flow allocation, the fd is handed to the RIB manager. The flow manager also listens for incoming flow requests. In case they are management flows, they are handed to the RIB manager, otherwise to the FRCT.
* ipcpd: Add initial headers for the normal IPCPSander Vrijders2016-07-123-0/+124
| | | | | | | | | This adds the initial headers for the normal IPCP. The normal IPCP consists of 3 main components: * The flow manager, in charge of managing N and N-1 flows. * The RIB manager, in charge of managing the RIB * FRCT: The flow and retransmission control task
* ouroboros: Use ouroboros errno.hdimitri staessens2016-07-071-1/+2
| | | | | All includes of <errno.h> within ouroboros are replaced with the ouroboros errno.
* lib, ipcpd: removed du_buff and pcidimitri staessens2016-06-293-189/+0
| | | | Fixes #3
* build: addresses comments on cffd94adimitri staessens2016-06-281-1/+1
|
* build: Fix installation prefixSander Vrijders2016-06-271-1/+1
| | | | | | The installation prefix was taking a trailing backslash, while it is common not to do so. Fixed it so that any trailing backslash is removed by the compilation and installation scripts.
* build: Change install directories and set correct permissionsSander Vrijders2016-06-201-1/+1
| | | | | | | | | This sets the correct install directories for all the binaries, library and header files. It also sets the right permissions on the sockets and shared memory so that regular users can also use the ouroboros library. Root privileges are required to run the irmd. Fixes #7
* lib, ipcpd, irmd: Add QoS cube definitionSander Vrijders2016-05-141-2/+4
| | | | | | | | | | This adds the QoS cube definition, which is an enum to select which QoS is needed in the IPCP. An application has to use the qos_spec in qos.h to define what it needs. The IRMd will map this unto a qos cube definition. Some headers are now also no longer installed on the system, since they are only to be used within the irmd and ipcps.
* ipcpd: initial IPC processesdimitri staessens2016-04-187-0/+468
Basic functions for implementation of IPC processes, and implementation of core functions of the shim IPCP over UDP. Updates to the build system to compile these IPC processes, as well as some fixes in the irmd (rudimentary capturing exit signals) and some fixes in the library, mainly relating to the messaging. Basic implementation of creation / bootstrapping / deletion of the shim UDP. Placeholders for other functions.