summaryrefslogtreecommitdiff
path: root/src/ipcpd/shim-eth-llc
Commit message (Collapse)AuthorAgeFilesLines
* ipcpd: Fix wrong timeval value in LLC shimdimitri staessens2017-04-081-3/+2
|
* ipcpd: Increase query timeout in shim LLCdimitri staessens2017-04-081-2/+9
|
* ipcpd: Add netmap support for LLC shimdimitri staessens2017-04-071-52/+124
| | | | | Adds support for netmap (https://github.com/luigirizzo/netmap) to increase the performance of packet transfer over the LLC shim.
* ipcpd: shim-eth-llc: Add check for netmap headersSander Vrijders2017-04-071-0/+14
| | | | This checks if the netmap headers are available on the system.
* ipcpd: Fix race condition with concurrent allocsdimitri staessens2017-04-061-5/+38
|
* ipcpd: shim-eth-llc: Avoid handling mgmt frame under lockSander Vrijders2017-04-061-4/+3
| | | | | This avoids handling the mgmt frames under lock, since it may deadlock if a new mgmt frame arrives in the meantime.
* ipcpd: shim-eth-llc: Fix overwrite mgmt framesSander Vrijders2017-04-051-21/+42
| | | | | | This fixes the overwriting of management frames by adding a list in the shim Ethernet that keeps track of management frames instead of a single buffer.
* ipcpd: Add lock for allocation requestsSander Vrijders2017-04-051-1/+5
| | | | | This adds a lock to prevent a race condition between flow_req_arr and flow_alloc_resp.
* ipcpd: shim-eth-llc: Fix state check in readerSander Vrijders2017-04-051-3/+3
| | | | | The state check should be done first to avoid blocking on the recv call.
* ipcpd: shim-eth-llc: Remove IPCP rwlockSander Vrijders2017-04-041-73/+23
| | | | | This removes the rwlock in the shim-eth-llc IPCP since it is already protected by a mutex.
* ipcpd: shim-eth-llc: Remove pthread_cancelSander Vrijders2017-04-041-78/+117
| | | | | This removes cancellation calls from the shim Ethernet. The different threads now check if the IPCP is still operational or not.
* ipcpd: shim-eth-llc: Deprecate PACKET_RX|TX_RINGSander Vrijders2017-04-041-203/+11
| | | | | | This deprecates these special socket options of the raw socket since they are less efficient for regular packet I/O. They should be more performant for batch processing of SDUs.
* ipcpd: shim-eth-llc: Add thread for mgmt framesSander Vrijders2017-04-041-29/+101
| | | | | | This adds a thread to handle management frames, since otherwise a deadlock can occur by blocking SDUs until flow allocation can be handled.
* ipcpd: Fix some bad lockingdimitri staessens2017-04-031-16/+14
|
* Change email addresses to ugent.beSander Vrijders2017-03-031-1/+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.
* build: Format CMakeLists.txt filesSander Vrijders2017-03-031-7/+7
| | | | The CMakeLists files are now properly indented.
* lib: Remove application entity nameSander Vrijders2017-02-242-17/+7
| | | | | 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.
* ipcpd: Add lock to tx_ring datadimitri staessens2017-02-131-1/+49
| | | | Also fixes another lock.
* ipcpd: Remove logging if not initialized yetSander Vrijders2017-02-101-1/+0
| | | | | | This removes the logs that would print to stdout if the IPCP fails to initialize. If the user had asked that logs would be printed to the syslog this would be unwanted behaviour.
* lib, tools, ipcpd: Fix compilation on FreeBSDdimitri staessens2017-02-091-1/+0
| | | | | | | | | | | | FreeBSD defines its own bswap64 in the <sys/endian.h> header, which is now included correctly. POSIX requires XSI or RTS extensions to be enabled for the sa_sigaction field to be visible. Linux doesn't do the check correctly, but FreeBSD does. Removes the LOG_MISSING call which was deprecated with the last revision of the logging system.
* ipcpd, lib: Report IPCP creation failuredimitri staessens2017-02-091-1/+4
| | | | | | | | The IPCP will now respond with an ipcp_create_r message when it fails, informing the IRMd. Also adds some const qualifiers in the public headers and fixes some formatting in dev.c.
* lib: Log to the logging systemdimitri staessens2017-02-081-69/+58
| | | | | | | | | | This removes the logfile and outputs log messages to the logging system. The creation of the logfiles (as well as the ap_init() call) were moved into ipcp_init() to simplify the IPCP creation and shutdown. Fixes #25 Fixes #27
* ipcpd: Refactor ipcpi structdimitri staessens2017-02-071-26/+34
| | | | | | | | | The ipcp-ops header was removed and merged into ipcp.h. The common components dif_name and ipcp_type have been moved to the main ipcp struct. After this move, ipcp_data only contained shim information, so it was renamed to shim_data. The ipcp_init() function checks the type and will only include the shim_data if the type is not an IPCP_NORMAL. All ipcps have been adapted to this change in API.
* ipcpd: Remove strdup() from ipcp main loopdimitri staessens2017-02-031-1/+8
|
* ipcpd: Don't strdup() the dif_name in main loopdimitri staessens2017-01-291-3/+0
|
* Merge remote-tracking branch 'upstream/be' into be-gamSander Vrijders2017-01-091-1/+1
|\
| * build: Update licenses and copyrightdimitri staessens2017-01-092-2/+2
| | | | | | | | | | Copyright is set to 2016 - 2017. License text on includes and sources in the library are changed to indicate the LGPLv2.1 license.
* | ipcpd: Let IPCPs bind a nameSander Vrijders2017-01-091-8/+2
|/ | | | | | | This allows IPCPs to bind a name, so that they can announce their name to neighbors which can then allocate a flow to them. Registering of the name happens by an administrator. It also moves the irmd_api to common ground, since it is used by all IPCPs.
* ipcpd: Add boot and shutdown operationsdimitri staessens2017-01-041-5/+13
| | | | | | | These operations separe the starting and joining of the main ipcp threads into ipcp_boot() and ipcp_shutdown() operations. This allows the proper cleanup of user data and user threads after the IPCP is requested to shut down.
* lib, ipcpd, irmd: Proof of concept QoSdimitri staessens2017-01-032-9/+18
| | | | | | | | | | Now correctly relays the qoscube end-to-end in the stack. A simple function specifying the cube in the spec is used for initial testing. The translation is now done in dev.c, but it could be moved elsewhere when qos cabability matures and the need arises.
* ouroboros: Correct license statementsdimitri staessens2016-12-242-6/+4
| | | | | This corrects the license statements on all files. Installed headers are LGPLv2.1, the rest of the code is GPLv2.
* ipcpd, lib, irmd: Update to use qoscube_tdimitri staessens2016-12-241-4/+4
|
* ipcpd: Change IPCP_RUNNING to IPCP_OPERATIONALSander Vrijders2016-12-061-5/+5
| | | | Changes a state of the IPCP to a more correct terminology.
* ipcpd: Split IPCP state PENDING_ENROLSander Vrijders2016-11-301-5/+5
| | | | | | | | This will split the IPCP state PENDING_ENROL into IPCP_CONFIG and IPCP_BOOTING. IPCP_CONFIG is concerned only with configuring the IPCP with the bare essence. When in IPCP_BOOTING, the IPCP will complete its configuration by starting its policies, and thus making the IPCP completely functioning.
* ipcpd, lib: Add syntax version to protobuf filesSander Vrijders2016-11-221-0/+25
| | | | | | This adds a syntax version to the protobuf files. The latest version of protobuf otherwise complains that it is missing. The GPL license is also added on files where it was missing.
* ipcpd: Fix SDU size check in LLC shimdimitri staessens2016-11-181-1/+1
| | | | Total SDU size (including LLC header) cannot exceed 1500 bytes.
* lib, ipcpd: Improve flow allocationdimitri staessens2016-10-311-9/+21
| | | | | | | All calls for opening rbuffs are now concentrated on the dev side. This allows some simplifications in the np1 calls. The ipcp_fini call will not destroy the mutex associated with the state, since the final state needs to be checked before shutting down an IPCP.
* ipcpd: Remove unnecessary include of fcntldimitri staessens2016-10-311-1/+0
|
* ipcpd: Clean shutdown when bootstrap failsdimitri staessens2016-10-311-10/+14
| | | | | Fixes a double free (conf->dif_name) and the handling of non-created threads when the bootstrap of an IPCP fails
* lib, ipcpd: Further stabilization of flowsdimitri staessens2016-10-262-53/+6
| | | | | | | | | | | The steps for flow deallocation have been further refined. An operation ipcp_flow_fini() which wait for all SDUs to be read from a flow has been added. The shim IPCPs and the local IPCP have been adapted to this new API. Deallocation messages have been removed from the shim IPCPs, since there is insufficient state synchronisation between them to make this work reliably.
* Merged in sandervrijders/ouroboros/be-directory (pull request #280)dimitri staessens2016-10-262-17/+107
|\ | | | | | | lib, irmd, ipcpd: Add name querying to IPCPs
| * lib, irmd, ipcpd: Add name querying to IPCPsSander Vrijders2016-10-262-17/+107
| | | | | | | | | | | | | | | | | | This adds the ability to query IPCPs if a name can be reached through them, e.g. if a name is available in a DIF. This means that in the shim-udp a DNS query is performed, in the shim-eth-llc an ARP-like query has been added, in the local a check is done to see if the name is registered, and in the normal currently no application is reachable through it.
* | ipcpd: Fix memory leaksdimitri staessens2016-10-251-14/+19
|/ | | | | Fixes memory leaks associated with the dif_name (which doesn't need to be maintained in shim DIFs) and the fqueue for the N + 1 flows.
* ipcpd: Fix log message and lockdimitri staessens2016-10-231-3/+2
| | | | | Remote requests for a flow that's locally deallocated should not generate an error. Sending messages should not be under lock.
* dev, ipcp: Fix setting default flow optionsdimitri staessens2016-10-231-9/+2
| | | | | The default flow options were not set when a flow allocation request arrives remotely. This went unnoticed due to a previous bug.
* build: Compile with strict conversiondimitri staessens2016-10-222-17/+23
| | | | | 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-4/+10
| | | | | 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-35/+71
| | | | | | | | 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: Fix flow deallocation logicdimitri staessens2016-10-131-0/+2
| | | | | Both the N and N-1 entity must now call flow_dealloc for the port_id to be released.
* lib: Add non-copy reading from fd for IPCPsdimitri staessens2016-10-071-1/+1
|