wimax-tools 1.4.4
Functions

/home/users/builder/rpm/BUILD/wimax-tools-1.4.4/lib/op-open.c File Reference

#include <sys/types.h>
#include <stdio.h>
#include <string.h>
#include <stdlib.h>
#include <stdarg.h>
#include <errno.h>
#include <assert.h>
#include <linux/types.h>
#include <net/if.h>
#include <netlink/msg.h>
#include <netlink/netlink.h>
#include <netlink/genl/genl.h>
#include <netlink/genl/ctrl.h>
#include <wimaxll.h>
#include "internal.h"
#include "debug.h"

Functions

int wimaxll_recv_fd (struct wimaxll_handle *wmx)
 Return the file descriptor associated to a WiMAX handle.
ssize_t wimaxll_recv (struct wimaxll_handle *wmx)
 Read notifications from the WiMAX multicast group.
struct wimaxll_handlewimaxll_open (const char *device)
 Open a handle to the WiMAX control interface in the kernel.
void wimaxll_close (struct wimaxll_handle *wmx)
 Close a device handle opened with wimaxll_open()

Function Documentation

ssize_t wimaxll_recv ( struct wimaxll_handle wmx)

Read notifications from the WiMAX multicast group.

Parameters:
wmxWiMAX device handle
Returns:
Value returned by the callback functions (depending on the implementation of the callback). On error, a negative errno code:

-EBUSY: callback instructed to stop processing messages

Read one or more messages from a multicast group and for each valid one, execute the callbacks set in the multi cast handle.

The callbacks are expected to handle the messages and set information in the context specific to the mc handle (mch->cb_ctx). In case of any type of errors (cb_ctx.result < 0), it is expected that no resources will be tied to the context.

Remarks:
This is a blocking call.

Referenced by wimaxll_msg_read(), and wimaxll_wait_for_state_change().