Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
freebsd
GitHub Repository: freebsd/freebsd-src
Path: blob/main/sys/cam/ctl/ctl_nvme_all.c
39482 views
1
/*-
2
* SPDX-License-Identifier: BSD-2-Clause
3
*
4
* Copyright (C) 2012-2014 Intel Corporation
5
* All rights reserved.
6
*
7
* Copyright (c) 2023 Chelsio Communications, Inc.
8
*/
9
10
#include <sys/types.h>
11
#include <sys/sbuf.h>
12
#ifndef _KERNEL
13
#include <sys/time.h>
14
#include <stdio.h>
15
#endif
16
17
#include <cam/cam.h>
18
#include <cam/nvme/nvme_all.h>
19
20
#include <cam/ctl/ctl_io.h>
21
#include <cam/ctl/ctl_nvme_all.h>
22
23
void
24
ctl_nvme_command_string(struct ctl_nvmeio *ctnio, struct sbuf *sb)
25
{
26
nvme_opcode_sbuf(ctnio->io_hdr.io_type == CTL_IO_NVME_ADMIN,
27
ctnio->cmd.opc, sb);
28
}
29
30
void
31
ctl_nvme_status_string(struct ctl_nvmeio *ctnio, struct sbuf *sb)
32
{
33
nvme_cpl_sbuf(&ctnio->cpl, sb);
34
}
35
36