Moved some functions from lwapp.h to lw.h, capwap.h to cw.h ...

FossilOrigin-Name: 8b6f76655e93cdb212b833ec890772b57e53723cf30b4fa9635130701890b0f2
This commit is contained in:
7u83@mail.ru
2016-03-04 20:01:38 +00:00
parent f29d758df4
commit 673f59a651
14 changed files with 129 additions and 24 deletions

View File

@ -39,7 +39,7 @@
#include "lwapp.h"
#include "strlist.h"
#include "cw.h"
/* capwap version and iana number */
@ -605,6 +605,7 @@ extern int cw_readmsg_configuration_update_request(uint8_t * elems, int elems_le
/* Use some macros from LWAPP */
/*
#define cw_put_byte lw_put_byte
#define cw_put_word lw_put_word
#define cw_put_dword lw_put_dword
@ -619,6 +620,8 @@ extern int cw_readmsg_configuration_update_request(uint8_t * elems, int elems_le
#define cw_get_word lw_get_word
#define cw_get_dword lw_get_dword
*/
/* macro to isolate bits from a dword */
#define cw_get_dword_bits(src,start,len) ((~(0xFFFFFFFF<<len)) & (src >> (32 - start - len)))
@ -1081,15 +1084,6 @@ static inline int cw_put_ac_status(uint8_t * dst, struct cw_ac_status *s)
}
static inline int cw_put_version(uint8_t * dst, uint16_t subelem_id, uint8_t * v)
{
uint8_t *d = dst;
d += cw_put_dword(d, bstrv_get_vendor_id(v));
d += cw_put_dword(d, (subelem_id << 16) | bstrv_len(v));
d += cw_put_data(d, bstrv_data(v), bstrv_len(v));
return d - dst;
}
int cw_register_actions_capwap_ac(struct cw_actiondef *def);