2022-11-13 02:15:47 +00:00
|
|
|
# SPDX-License-Identifier: BSD-3-Clause
|
|
|
|
# Copyright (C) 2022 Intel Corporation.
|
|
|
|
# All rights reserved.
|
|
|
|
|
2022-08-08 21:43:24 +00:00
|
|
|
from spdk.rpc.helpers import deprecated_alias
|
|
|
|
|
|
|
|
|
2022-05-26 23:46:01 +00:00
|
|
|
def accel_get_opc_assignments(client):
|
2022-08-08 21:43:24 +00:00
|
|
|
"""Get list of opcode name to module assignments.
|
2022-05-26 23:46:01 +00:00
|
|
|
"""
|
|
|
|
return client.call('accel_get_opc_assignments')
|
2022-07-21 21:15:09 +00:00
|
|
|
|
|
|
|
|
2022-08-08 21:43:24 +00:00
|
|
|
@deprecated_alias('accel_get_engine_info')
|
|
|
|
def accel_get_module_info(client):
|
|
|
|
"""Get list of valid module names and their operations.
|
2022-07-21 21:15:09 +00:00
|
|
|
"""
|
2022-08-08 21:43:24 +00:00
|
|
|
return client.call('accel_get_module_info')
|
2022-06-01 00:13:04 +00:00
|
|
|
|
|
|
|
|
2022-08-08 21:43:24 +00:00
|
|
|
def accel_assign_opc(client, opname, module):
|
|
|
|
"""Manually assign an operation to a module.
|
2022-06-01 00:13:04 +00:00
|
|
|
|
|
|
|
Args:
|
|
|
|
opname: name of operation
|
2022-08-08 21:43:24 +00:00
|
|
|
module: name of module
|
2022-06-01 00:13:04 +00:00
|
|
|
"""
|
|
|
|
params = {
|
|
|
|
'opname': opname,
|
2022-08-08 21:43:24 +00:00
|
|
|
'module': module,
|
2022-06-01 00:13:04 +00:00
|
|
|
}
|
|
|
|
|
|
|
|
return client.call('accel_assign_opc', params)
|