Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
B
bpm-sw
Manage
Activity
Members
Code
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Deploy
Releases
Analyze
Contributor analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
This is an archived project. Repository and other project resources are read-only.
bpm
bpm-sw
Commits
b442b6c3
Commit
b442b6c3
authored
9 years ago
by
Lucas Russo
Browse files
Options
Downloads
Patches
Plain Diff
libs/libhutils/*: add support for "fmc_board" parameter
parent
b56ae507
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
src/libs/libhutils/include/hutils_utils.h
+1
-0
1 addition, 0 deletions
src/libs/libhutils/include/hutils_utils.h
src/libs/libhutils/src/hutils_utils.c
+14
-0
14 additions, 0 deletions
src/libs/libhutils/src/hutils_utils.c
with
15 additions
and
0 deletions
src/libs/libhutils/include/hutils_utils.h
+
1
−
0
View file @
b442b6c3
...
...
@@ -34,6 +34,7 @@ extern "C" {
typedef
struct
{
char
*
bind
;
/* AFE Endpoint address to bind to */
char
*
fmc_board
;
/* FMC board type */
bool
spawn_epics_ioc
;
/* DBE IOC spawn selection */
}
hutils_hints_t
;
...
...
This diff is collapsed.
Click to expand it.
src/libs/libhutils/src/hutils_utils.c
+
14
−
0
View file @
b442b6c3
...
...
@@ -391,6 +391,17 @@ hutils_err_e hutils_get_hints (zconfig_t *root_cfg, zhashx_t *hints_h)
item
=
(
hutils_hints_t
*
)
zmalloc
(
sizeof
*
item
);
ASSERT_ALLOC
(
item
,
err_hash_item_alloc
,
HUTILS_ERR_ALLOC
);
/* We expect to the FMC board type of this bpm/board instance
* in the configuration file */
char
*
fmc_board
=
zconfig_resolve
(
bpm_cfg
,
"/dbe/fmc_board"
,
NULL
);
ASSERT_TEST
(
fmc_board
!=
NULL
,
"[hutils:utils] Could not find "
"FMC Board type (fmc_board = <value>) in configuration file"
,
err_fmc_board
,
HUTILS_ERR_CFG
);
item
->
fmc_board
=
strdup
(
fmc_board
);
ASSERT_ALLOC
(
item
->
fmc_board
,
err_hash_fmc_board
,
HUTILS_ERR_ALLOC
);
/* Now, we expect to find the bind address of this bpm/board instance
* in the configuration file */
char
*
afe_bind
=
zconfig_resolve
(
bpm_cfg
,
"/afe/bind"
,
...
...
@@ -457,6 +468,9 @@ err_spawn_epics_ioc:
free
(
item
->
bind
);
err_hash_bind_alloc:
err_afe_bind:
free
(
item
->
fmc_board
);
err_hash_fmc_board:
err_fmc_board:
free
(
item
);
err_hash_item_alloc:
err_cfg_exit:
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment