LCOV - code coverage report
Current view: top level - spdk/module/accel/ioat - accel_ioat_rpc.c (source / functions) Hit Total Coverage
Test: Combined Lines: 7 9 77.8 %
Date: 2024-07-10 18:23:29 Functions: 3 3 100.0 %
Legend: Lines: hit not hit | Branches: + taken - not taken # not executed Branches: 1 2 50.0 %

           Branch data     Line data    Source code
       1                 :            : /*   SPDX-License-Identifier: BSD-3-Clause
       2                 :            :  *   Copyright (C) 2022 Intel Corporation.
       3                 :            :  *   All rights reserved.
       4                 :            :  */
       5                 :            : 
       6                 :            : #include "accel_ioat.h"
       7                 :            : 
       8                 :            : #include "spdk/rpc.h"
       9                 :            : #include "spdk/util.h"
      10                 :            : #include "spdk/event.h"
      11                 :            : 
      12                 :            : static void
      13                 :         24 : rpc_ioat_scan_accel_module(struct spdk_jsonrpc_request *request,
      14                 :            :                            const struct spdk_json_val *params)
      15                 :            : {
      16         [ -  + ]:         24 :         if (params != NULL) {
      17                 :          0 :                 spdk_jsonrpc_send_error_response(request, SPDK_JSONRPC_ERROR_INVALID_PARAMS,
      18                 :            :                                                  "ioat_scan_accel_module requires no parameters");
      19                 :          0 :                 return;
      20                 :            :         }
      21                 :            : 
      22                 :         24 :         SPDK_NOTICELOG("Enabling IOAT\n");
      23                 :         24 :         accel_ioat_enable_probe();
      24                 :            : 
      25                 :         24 :         spdk_jsonrpc_send_bool_response(request, true);
      26                 :            : }
      27                 :       2905 : SPDK_RPC_REGISTER("ioat_scan_accel_module", rpc_ioat_scan_accel_module, SPDK_RPC_STARTUP)
      28                 :       2905 : SPDK_RPC_REGISTER_ALIAS_DEPRECATED(ioat_scan_accel_module, ioat_scan_accel_engine)

Generated by: LCOV version 1.14