File tree Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Expand file tree Collapse file tree 1 file changed +4
-8
lines changed Original file line number Diff line number Diff line change 13
13
14
14
UR_APIEXPORT ur_result_t UR_APICALL urUsmP2PEnablePeerAccessExp (
15
15
ur_device_handle_t commandDevice, ur_device_handle_t peerDevice) {
16
-
17
- ur_result_t result = UR_RESULT_SUCCESS;
18
16
try {
19
17
ScopedContext active (commandDevice->getContext ());
20
18
UR_CHECK_ERROR (cuCtxEnablePeerAccess (peerDevice->getContext (), 0 ));
21
19
} catch (ur_result_t err) {
22
- result = err;
20
+ return err;
23
21
}
24
- return result ;
22
+ return UR_RESULT_SUCCESS ;
25
23
}
26
24
27
25
UR_APIEXPORT ur_result_t UR_APICALL urUsmP2PDisablePeerAccessExp (
28
26
ur_device_handle_t commandDevice, ur_device_handle_t peerDevice) {
29
-
30
- ur_result_t result = UR_RESULT_SUCCESS;
31
27
try {
32
28
ScopedContext active (commandDevice->getContext ());
33
29
UR_CHECK_ERROR (cuCtxDisablePeerAccess (peerDevice->getContext ()));
34
30
} catch (ur_result_t err) {
35
- result = err;
31
+ return err;
36
32
}
37
- return result ;
33
+ return UR_RESULT_SUCCESS ;
38
34
}
39
35
40
36
UR_APIEXPORT ur_result_t UR_APICALL urUsmP2PPeerAccessGetInfoExp (
You can’t perform that action at this time.
0 commit comments