mirror of
https://dev.iopsys.eu/bbf/bbfdm.git
synced 2025-12-10 07:44:39 +01:00
fix uspd compilation
This commit is contained in:
parent
c4c10e2b9c
commit
e6bef090e9
2 changed files with 35 additions and 1 deletions
|
|
@ -67,7 +67,6 @@ void bbf_apply_end_session(void)
|
|||
apply_end_session();
|
||||
}
|
||||
|
||||
|
||||
int bbf_set_ip_version(int ipversion)
|
||||
{
|
||||
ip_version = ipversion;
|
||||
|
|
@ -136,3 +135,32 @@ void dmbbf_update_enabled_notify_file(unsigned int dm_type, unsigned int amd_ver
|
|||
|
||||
dm_ctx_clean(&dmctx);
|
||||
}
|
||||
|
||||
int get_dm_type(char *dm_str)
|
||||
{
|
||||
if (dm_str == NULL)
|
||||
return DMT_STRING;
|
||||
|
||||
if (strcmp(dm_str, DMT_TYPE[DMT_STRING]) == 0)
|
||||
return DMT_STRING;
|
||||
else if (strcmp(dm_str, DMT_TYPE[DMT_UNINT]) == 0)
|
||||
return DMT_UNINT;
|
||||
else if (strcmp(dm_str, DMT_TYPE[DMT_INT]) == 0)
|
||||
return DMT_INT;
|
||||
else if (strcmp(dm_str, DMT_TYPE[DMT_UNLONG]) == 0)
|
||||
return DMT_UNLONG;
|
||||
else if (strcmp(dm_str, DMT_TYPE[DMT_LONG]) == 0)
|
||||
return DMT_LONG;
|
||||
else if (strcmp(dm_str, DMT_TYPE[DMT_BOOL]) == 0)
|
||||
return DMT_BOOL;
|
||||
else if (strcmp(dm_str, DMT_TYPE[DMT_TIME]) == 0)
|
||||
return DMT_TIME;
|
||||
else if (strcmp(dm_str, DMT_TYPE[DMT_HEXBIN]) == 0)
|
||||
return DMT_HEXBIN;
|
||||
else if (strcmp(dm_str, DMT_TYPE[DMT_BASE64]) == 0)
|
||||
return DMT_BASE64;
|
||||
else
|
||||
return DMT_STRING;
|
||||
|
||||
return DMT_STRING;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -9,6 +9,9 @@
|
|||
* Author Omar Kallel <omar.kallel@pivasoftware.com>
|
||||
*/
|
||||
|
||||
#ifndef __DMBBFCOMMON_H__
|
||||
#define __DMBBFCOMMON_H__
|
||||
|
||||
#include <libbbf_api/dmcommon.h>
|
||||
#include "dmentry.h"
|
||||
|
||||
|
|
@ -35,3 +38,6 @@ void bbf_set_end_session_flag (struct dmctx *ctx, unsigned int flag);
|
|||
int bbfdmuci_lookup_ptr(struct uci_context *ctx, struct uci_ptr *ptr, char *package, char *section, char *option, char *value);
|
||||
void bbf_apply_end_session(void);
|
||||
void dmbbf_update_enabled_notify_file(unsigned int dm_type, unsigned int amd_version, int instance_mode);
|
||||
int get_dm_type(char *dm_str);
|
||||
|
||||
#endif //__DMBBFCOMMON_H__
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue