message.h File Reference

Message definitions for WlanModel <-> iwconnect communication. More...

#include <netinet/in.h>
#include <linux/if.h>
#include <net/ethernet.h>
#include <limits.h>
#include <stdint.h>

Go to the source code of this file.

Data Structures

struct  msg_header
struct  data_msg
union  vif_param
struct  s_vif_config
struct  config_msg
struct  s_vif_registration
struct  registration_info
struct  registration_msg
struct  plain_msg

Defines

#define MAX_FRAME_SIZE   (1500 + sizeof(struct ether_header))
#define DATA_MSG   0
#define DATA_PREAMBLE_SIZE   (sizeof(struct msg_header) + 2 * sizeof(uint16_t))
#define DATA_MSG_SIZE   sizeof(struct data_msg)
#define CONFIG_MSG   1
#define CONFIG_MSG_SIZE   sizeof(struct config_msg)
#define REGISTRATION_MSG   2
#define REGISTRATION_MSG_SIZE   sizeof(struct registration_msg)
#define PLAIN_MSG_SIZE   sizeof(struct plain_msg)
#define ACK_MSG   3
#define ACK_MSG_SIZE   PLAIN_MSG_SIZE
#define DEREGISTRATION_MSG   4
#define DEREGISTRATION_MSG_SIZE   PLAIN_MSG_SIZE
#define MAX_MSG_SIZE   max(WLAN_MSG_SIZE, REGISTRATION_MSG_SIZE)

Typedefs

typedef char raw_packet [MAX_FRAME_SIZE]
typedef struct s_vif_config vif_config
typedef struct s_vif_registration vif_registration

Functions

int is_data_msg (struct msg_header *)
int is_registration_msg (struct msg_header *)
int is_deregistration_msg (struct msg_header *)
int is_ack_msg (struct msg_header *)
int is_config_msg (struct msg_header *)
void debug_msg (const char *)

Variables

struct data_msg __packed__


Detailed Description

Message definitions for WlanModel <-> iwconnect communication.

Definition in file message.h.


Define Documentation

#define ACK_MSG   3

Definition at line 145 of file message.h.

#define ACK_MSG_SIZE   PLAIN_MSG_SIZE

Definition at line 146 of file message.h.

#define CONFIG_MSG   1

Definition at line 137 of file message.h.

#define CONFIG_MSG_SIZE   sizeof(struct config_msg)

Definition at line 138 of file message.h.

#define DATA_MSG   0

Definition at line 133 of file message.h.

#define DATA_MSG_SIZE   sizeof(struct data_msg)

Definition at line 135 of file message.h.

#define DATA_PREAMBLE_SIZE   (sizeof(struct msg_header) + 2 * sizeof(uint16_t))

Definition at line 134 of file message.h.

#define DEREGISTRATION_MSG   4

Definition at line 148 of file message.h.

#define DEREGISTRATION_MSG_SIZE   PLAIN_MSG_SIZE

Definition at line 149 of file message.h.

#define MAX_FRAME_SIZE   (1500 + sizeof(struct ether_header))

Maximum size of an original wireless Ethernet frame

Definition at line 32 of file message.h.

#define MAX_MSG_SIZE   max(WLAN_MSG_SIZE, REGISTRATION_MSG_SIZE)

Maximal size of a iwconnect <-> WlanModel message

Definition at line 153 of file message.h.

#define PLAIN_MSG_SIZE   sizeof(struct plain_msg)

Definition at line 143 of file message.h.

#define REGISTRATION_MSG   2

Definition at line 140 of file message.h.

#define REGISTRATION_MSG_SIZE   sizeof(struct registration_msg)

Definition at line 141 of file message.h.


Typedef Documentation

typedef char raw_packet[MAX_FRAME_SIZE]

Wireless frame data structure

Definition at line 36 of file message.h.

typedef struct s_vif_config vif_config

Definition at line 77 of file message.h.

Definition at line 101 of file message.h.


Function Documentation

void debug_msg ( const char *  message  ) 

Print message content to debug output

Definition at line 279 of file message.c.

int is_ack_msg ( struct msg_header header  ) 

Checks if it is ACK_MSG

Definition at line 53 of file message.c.

int is_config_msg ( struct msg_header header  ) 

Checks if it is CONFIG_MSG

Definition at line 60 of file message.c.

int is_data_msg ( struct msg_header header  ) 

Checks if it is DATA_MSG

Definition at line 32 of file message.c.

int is_deregistration_msg ( struct msg_header header  ) 

Checks if it is DEREGISTRATION_MSG

Definition at line 46 of file message.c.

int is_registration_msg ( struct msg_header header  ) 

Checks if it is REGISTRATION_MSG

Definition at line 39 of file message.c.


Variable Documentation

Data message (encapsulated wireless packet)

Configuration information

Virtual device parameter format for registration_msg

Registration information


Generated on Mon Feb 8 14:55:05 2010 for iwconnect by  doxygen 1.5.8