Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
codes
codes
Commits
5af2ef2b
Commit
5af2ef2b
authored
Mar 05, 2015
by
Jonathan Jenkins
Browse files
lsm default device mapping stub
parent
8dce9c05
Changes
1
Hide whitespace changes
Inline
Side-by-side
src/util/local-storage-model.c
View file @
5af2ef2b
...
...
@@ -247,6 +247,25 @@ void lsm_event_new_reverse(tw_lp *sender)
return
;
}
static
tw_lpid
lsm_find_local_device_default
(
const
char
*
annotation
,
int
ignore_annotations
,
tw_lpid
sender_gid
)
{
char
group_name
[
MAX_NAME_LENGTH
];
int
dummy
,
mapping_rep
,
mapping_offset
;
int
num_lsm_lps
;
tw_lpid
rtn
;
codes_mapping_get_lp_info
(
sender_gid
,
group_name
,
&
dummy
,
NULL
,
&
dummy
,
NULL
,
&
mapping_rep
,
&
mapping_offset
);
num_lsm_lps
=
codes_mapping_get_lp_count
(
group_name
,
1
,
LSM_NAME
,
annotation
,
ignore_annotations
);
codes_mapping_get_lp_id
(
group_name
,
LSM_NAME
,
annotation
,
ignore_annotations
,
mapping_rep
,
mapping_offset
%
num_lsm_lps
,
&
rtn
);
return
rtn
;
}
/*
* lsm_find_local_device()
*
...
...
@@ -256,16 +275,7 @@ void lsm_event_new_reverse(tw_lp *sender)
*/
tw_lpid
lsm_find_local_device
(
tw_lp
*
sender
)
{
char
lp_group_name
[
MAX_NAME_LENGTH
];
int
mapping_rep_id
,
mapping_offset
,
dummy
;
tw_lpid
lsm_gid
;
codes_mapping_get_lp_info
(
sender
->
gid
,
lp_group_name
,
&
dummy
,
NULL
,
&
dummy
,
NULL
,
&
mapping_rep_id
,
&
mapping_offset
);
codes_mapping_get_lp_id
(
lp_group_name
,
LSM_NAME
,
NULL
,
1
,
mapping_rep_id
,
mapping_offset
,
&
lsm_gid
);
return
(
lsm_gid
);
return
lsm_find_local_device_default
(
NULL
,
1
,
sender
->
gid
);
}
/*
...
...
Write
Preview
Supports
Markdown
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!
Cancel
Please
register
or
sign in
to comment