diff options
author | dimitri staessens <[email protected]> | 2017-03-30 20:33:22 +0200 |
---|---|---|
committer | dimitri staessens <[email protected]> | 2017-03-31 11:51:33 +0200 |
commit | 7ba0fd0ce19244745c8d2512ce8a003783d914a7 (patch) | |
tree | e33ed7dae832ef96cd1997ec038764fac5d95d4c /include | |
parent | bce97d70ce43290f8351f34c763b30bfd73e6b99 (diff) | |
download | ouroboros-7ba0fd0ce19244745c8d2512ce8a003783d914a7.tar.gz ouroboros-7ba0fd0ce19244745c8d2512ce8a003783d914a7.zip |
lib: Revise flow allocation API
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.
Diffstat (limited to 'include')
-rw-r--r-- | include/ouroboros/dev.h | 23 |
1 files changed, 9 insertions, 14 deletions
diff --git a/include/ouroboros/dev.h b/include/ouroboros/dev.h index e92cdd1c..4984736c 100644 --- a/include/ouroboros/dev.h +++ b/include/ouroboros/dev.h @@ -24,6 +24,7 @@ #include <ouroboros/qos.h> #include <unistd.h> +#include <time.h> #ifndef OUROBOROS_DEV_H #define OUROBOROS_DEV_H @@ -33,20 +34,14 @@ int ap_init(const char * ap_name); void ap_fini(void); -/* Returns flow descriptor (> 0) and qos spec. */ -int flow_accept(qosspec_t * spec); +/* Returns flow descriptor, qs updates to supplied QoS. */ +int flow_alloc(const char * dst_name, + qosspec_t * qs, + struct timespec * timeo); -int flow_alloc_resp(int fd, - int response); - -/* - * Returns flow descriptor (> 0). - * On returning, spec will contain the actual supplied QoS. - */ -int flow_alloc(const char * dst_name, - qosspec_t * spec); - -int flow_alloc_res(int fd); +/* Returns flow descriptor, qs updates to supplied QoS. */ +int flow_accept(qosspec_t * qs, + struct timespec * timeo); int flow_dealloc(int fd); @@ -58,4 +53,4 @@ ssize_t flow_read(int fd, void * buf, size_t count); -#endif +#endif /* OUROBOROS_DEV_H */ |