Function: notify_set_import_pid
Applicability
Product |
Supported (√/x) |
|---|---|
√ |
|
√ |
|
√ |
|
√ |
|
x |
Function Usage
Sets the process trustlist of the Notify shared memory. Only the processes in the trustlist can use the Notify shared name exported by the acl.rt.notify_get_export_key API.
Prototype
- C Prototype
aclError aclrtNotifySetImportPid(aclrtNotify notify, int32_t *pid, size_t num)
- Python Function
1ret = acl.rt.notify_set_import_pid(notify, pid)
Parameter Description
Parameter |
Description |
|---|---|
notify |
Int, Notify pointer address, which must be the same as that of Notify in acl.rt.notify_get_export_key. |
pid |
List, which is used to store the trustlisted process IDs. Definition: pid = [pid_1, pid_2,...] You can call acl.rt.device_get_bare_tgid to obtain the process ID. In the Docker scenario, the process ID on the physical machine is obtained. In the non-Docker scenario, the process ID is obtained. |
Return Value Description
Return Value |
Description |
|---|---|
ret |
Int, 0 on success; else, failure. |
Restrictions
This operation is not supported in the Ascend virtual instance scenario.