Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

RTAI: Fix undefined symbols in hal_lib #2650

Merged
merged 1 commit into from
Sep 21, 2023
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
32 changes: 32 additions & 0 deletions src/hal/hal_lib.c
Original file line number Diff line number Diff line change
Expand Up @@ -1378,6 +1378,17 @@ int hal_param_s32_new(const char *name, hal_param_dir_t dir, hal_s32_t * data_ad
return hal_param_new(name, HAL_S32, dir, (void *) data_addr, comp_id);
}

int hal_param_u64_new(const char *name, hal_param_dir_t dir, hal_u64_t * data_addr,
int comp_id)
{
return hal_param_new(name, HAL_U64, dir, (void *) data_addr, comp_id);
}
int hal_param_s64_new(const char *name, hal_param_dir_t dir, hal_s64_t * data_addr,
int comp_id)
{
return hal_param_new(name, HAL_S64, dir, (void *) data_addr, comp_id);
}

static int hal_param_newfv(hal_type_t type, hal_param_dir_t dir,
void *data_addr, int comp_id, const char *fmt, va_list ap) {
char name[HAL_NAME_LEN + 1];
Expand Down Expand Up @@ -1436,6 +1447,27 @@ int hal_param_s32_newf(hal_param_dir_t dir, hal_s32_t * data_addr,
return ret;
}

int hal_param_u64_newf(hal_param_dir_t dir, hal_u64_t * data_addr,
int comp_id, const char *fmt, ...)
{
va_list ap;
int ret;
va_start(ap, fmt);
ret = hal_param_newfv(HAL_U64, dir, (void*)data_addr, comp_id, fmt, ap);
va_end(ap);
return ret;
}

int hal_param_s64_newf(hal_param_dir_t dir, hal_s64_t * data_addr,
int comp_id, const char *fmt, ...)
{
va_list ap;
int ret;
va_start(ap, fmt);
ret = hal_param_newfv(HAL_S64, dir, (void*)data_addr, comp_id, fmt, ap);
va_end(ap);
return ret;
}

/* this is a generic function that does the majority of the work. */

Expand Down