summaryrefslogtreecommitdiff
path: root/src/tools/oping/oping_client.c
Commit message (Collapse)AuthorAgeFilesLines
* lib: Use PTHREAD_COND_CLOCK for blocking reads0.10.6Dimitri Staessens2018-03-101-2/+5
| | | | | | | | | | | The rbuff uses the PTHREAD_COND_CLOCK for its condition variables, but the flow_read was passing a time it got from the CLOCK_REALTIME_COARSE clock. This causes the blocking reads not to timeout correctly. The oping was updated to detect server timeouts and finish gracefully. Signed-off-by: Dimitri Staessens <dimitri.staessens@ugent.be> Signed-off-by: Sander Vrijders <sander.vrijders@ugent.be>
* tools: Don't cancel reader thread in oping0.10.5Dimitri Staessens2018-03-051-2/+0
| | | | | | | | The reader thread was cancelled as soon as the writer was finished, which resulted in missed responses and misreported packet loss. Signed-off-by: Dimitri Staessens <dimitri.staessens@ugent.be> Signed-off-by: Sander Vrijders <sander.vrijders@ugent.be>
* build: Allow out-of-tree build of toolsDimitri Staessens2018-02-141-20/+8
| | | | | | | | | | This removes the dependencies for the tools on some ouroboros internal headers (endian.h and time_utils.h) so they can be built out-of-tree. The echo-app tool has been renamed oecho and the cbr tool has been renamed ocbr. Signed-off-by: Dimitri Staessens <dimitri.staessens@ugent.be> Signed-off-by: Sander Vrijders <sander.vrijders@ugent.be>
* include, src: Update copyright to 2018Dimitri Staessens2018-01-091-1/+1
| | | | | | | Happy New Year, Ouroboros. Signed-off-by: Dimitri Staessens <dimitri.staessens@ugent.be> Signed-off-by: Sander Vrijders <sander.vrijders@ugent.be>
* tools: Fix SEGV in oping clientDimitri Staessens2017-11-221-4/+8
| | | | | | | | | | | The oping client tried to cancel non-created pthreads if it was killed during flow allocation, which caused a SEGV. The threads are now stopped using a variable. Fixes bug #2. Signed-off-by: Dimitri Staessens <dimitri.staessens@ugent.be> Signed-off-by: Sander Vrijders <sander.vrijders@ugent.be>
* tools: Send time in oping packetsDimitri Staessens2017-11-191-28/+19
| | | | | | | | The oping tool now stores the time it sent the packet inside the SDU, simplifying the implementation. Signed-off-by: Dimitri Staessens <dimitri.staessens@ugent.be> Signed-off-by: Sander Vrijders <sander.vrijders@ugent.be>
* tools: Change license to 3 clause BSDDimitri Staessens2017-10-241-10/+26
| | | | | | | | | A more permissive license is needed on the tools since they serve as example code for programs built on top of the ouroboros-dev and ouroboros-irm libraries. Signed-off-by: Dimitri Staessens <dimitri.staessens@ugent.be> Signed-off-by: Sander Vrijders <sander.vrijders@ugent.be>
* lib: Add fccntl configuration commanddimitri staessens2017-08-311-2/+2
| | | | | | | This replaces the flow_set_* commands with a single fccntl command that can configure flows and the FRCT instance. For more details, see "man 3 fccntl".
* build: Revise the build systemdimitri staessens2017-08-211-4/+0
| | | | | | | | | | This revises the build system to have configuration per system component. System settings can now be set using cmake. The standard compliance defines were removed from configuration header and are set in the sources where needed. Also some small code refactors, such as moving the data for shims out of the ipcp structure to the respective shims were performed.
* build: Replace fsf snail mail with contact URLdimitri staessens2017-08-131-1/+1
|
* tools: Fix oping client outputdimitri staessens2017-04-031-2/+2
|
* tools: oping: Fix bad calculationSander Vrijders2017-04-011-1/+1
| | | | This fixes a potential overflow when calculating the packet loss.
* lib: Revise flow allocation APIdimitri staessens2017-03-311-10/+1
| | | | | | The flow_alloc_res and flow_alloc_resp calls have been removed. The flow_alloc and flow_accept calls are now both blocking and take an additional timeout argument.
* Change email addresses to ugent.beSander Vrijders2017-03-031-2/+2
| | | | | | | Our mailserver was migrated from intec.ugent.be to the central ugent.be emailserver. This PR updates the header files to reflect this change as well. Some header files were also homogenized if the parameters within the functions were badly aligned.
* lib: Remove application entity nameSander Vrijders2017-02-241-1/+1
| | | | | The AE name should not be passed over the layer boundaries. If an application has more than one AE it should exchange this in CACEP.
* tools: Fix overflow bug in opingdimitri staessens2017-02-221-9/+10
| | | | | | Sometimes the receiver thread got the SDU before the writer thread has set the sent time when testing over the local. The sent time is now written before actually sending to avoid this.
* build: Update licenses and copyrightdimitri staessens2017-01-091-1/+1
| | | | | Copyright is set to 2016 - 2017. License text on includes and sources in the library are changed to indicate the LGPLv2.1 license.
* ouroboros: Correct license statementsdimitri staessens2016-12-241-3/+2
| | | | | This corrects the license statements on all files. Installed headers are LGPLv2.1, the rest of the code is GPLv2.
* src, tools: Set/get timeout and get qos for flowsdimitri staessens2016-12-121-71/+44
| | | | | | | | | | | | | | | | Receiver timeouts can now be set on a flow using the flow_set_timeout function. Specifying NULL disables the timeout. The flow_get_timeout function gets the value for the timeout. This commit also deprecates fcntl in favor of flow_get_flags and flow_set_flags functions. struct qos_spec is typedef'd as a qosspec_t. The tools and cdap.c are updated to use the new API. Fixes a bug in operf client where the client's writer thread wouldn't cancel on SIGINT.
* tools: Fix compilation issues on 32 bit machinesdimitri staessens2016-12-021-1/+1
| | | | | | size_t is 32 bits on those machines, failing as an argument to printf. Some variables in oping and operf were changed to uint32_t and uint64_t to avoid issues.
* lib: Clean up flow if alloc_res failsdimitri staessens2016-10-271-37/+64
| | | | | | | | | If alloc_res fails all resources will be cleaned, except for the assigned flow_descriptor, which must be released with a dealloc call. Calling dealloc after a failed flow_alloc will not try to destroy the already cleaned up flow in the IRMd and IPCPs. Also fixes some memleaks in the oping client.
* tools: Fix memory leaks in opingdimitri staessens2016-10-241-6/+12
|
* build: Compile with strict conversiondimitri staessens2016-10-221-5/+5
| | | | | This has the code checked with -Wcast-qual and -Wconversion flags. These flags were removed because SWIG generated code fails.
* build: Comply with -Wextra compiler flagdimitri staessens2016-10-211-1/+6
| | | | | This reduces the risk for some bugs, for instance due to signed/unsigned mismatches and unused variables.
* lib: Demultiplex the fast pathdimitri staessens2016-10-211-8/+17
| | | | | | | | The fast path will now use an incoming ring buffer per flow per process. This necessitated the development of a new method for the asynchronous io call, which is now based on an event queue system for scalability (fqueue). The ipcpd's and tools have been updated to this API.
* lib: Add a type for struct flow_setdimitri staessens2016-10-091-2/+1
| | | | | | The struct flow_set can now be accessed in applications as flow_set_t. Fixes some malformed lines and homogenizes output when receiving bad SDUs in the oping tool.
* ipcpd: Filter traffic on shim-eth-llcdimitri staessens2016-10-061-0/+1
| | | | Now correctly handles and drops non-ouroboros traffic.
* lib, ipcp: Revise fast path and flow interfacesdimitri staessens2016-10-041-1/+2
| | | | | | | | | | | | IPCPs can now use ap_init() to initialize the memory. All flows are accessed using flow descriptors, this greatly simplifies IPCP development. Reverts the fast path to a single ap_rbuff per process. Splits lib/ipcp into irmd/ipcp and lib/ipcp-dev. Adds a lib/shim-dev holding tailored functions for shims. Moves the buffer_t to utils.h. Fixes the shim-eth-llc length field. Removes the flow from shared.h. Fixes #4 Fixes #5
* lib: dev: Provide a set of fds to flow_selectdimitri staessens2016-09-061-1/+1
| | | | | | | The flow_select call now takes as a parameter a flow_set_t, which specifies a set of flow descriptors that will unblock the select call when an SDU for one of them arrives. The select call has been moved to its own header.
* src: Fix grammar (SDU's -> SDUs)dimitri staessens2016-09-021-1/+1
|
* tools: oping: Fix wrong delay calculationdimitri staessens2016-08-061-1/+2
|
* tools: oping: Fix client cleanupdimitri staessens2016-08-041-0/+5
|
* tools: oping: Fix division by zerodimitri staessens2016-08-041-9/+14
| | | | | When killing the oping client before it sent an SDU, some bad operations were being performed.
* tools: Add a ping applicationdimitri staessens2016-08-031-0/+234
Ouoroboros ping application mimics the GNU ping application. do "oping --help" for options.