Lines 942-948
int nvme_ns_bio_process(struct nvme_namespace *ns, struct bio *bp,
Link Here
|
942 |
|
942 |
|
943 |
/* Command building helper functions -- shared with CAM */ |
943 |
/* Command building helper functions -- shared with CAM */ |
944 |
static inline |
944 |
static inline |
945 |
void nvme_ns_flush_cmd(struct nvme_command *cmd, uint16_t nsid) |
945 |
void nvme_ns_flush_cmd(struct nvme_command *cmd, uint32_t nsid) |
946 |
{ |
946 |
{ |
947 |
|
947 |
|
948 |
cmd->opc = NVME_OPC_FLUSH; |
948 |
cmd->opc = NVME_OPC_FLUSH; |
Lines 950-956
void nvme_ns_flush_cmd(struct nvme_command *cmd, uint16_t nsid)
Link Here
|
950 |
} |
950 |
} |
951 |
|
951 |
|
952 |
static inline |
952 |
static inline |
953 |
void nvme_ns_rw_cmd(struct nvme_command *cmd, uint32_t rwcmd, uint16_t nsid, |
953 |
void nvme_ns_rw_cmd(struct nvme_command *cmd, uint32_t rwcmd, uint32_t nsid, |
954 |
uint64_t lba, uint32_t count) |
954 |
uint64_t lba, uint32_t count) |
955 |
{ |
955 |
{ |
956 |
cmd->opc = rwcmd; |
956 |
cmd->opc = rwcmd; |
Lines 964-984
void nvme_ns_rw_cmd(struct nvme_command *cmd, uint32_t rwcmd, uint16_t nsid,
Link Here
|
964 |
} |
964 |
} |
965 |
|
965 |
|
966 |
static inline |
966 |
static inline |
967 |
void nvme_ns_write_cmd(struct nvme_command *cmd, uint16_t nsid, |
967 |
void nvme_ns_write_cmd(struct nvme_command *cmd, uint32_t nsid, |
968 |
uint64_t lba, uint32_t count) |
968 |
uint64_t lba, uint32_t count) |
969 |
{ |
969 |
{ |
970 |
nvme_ns_rw_cmd(cmd, NVME_OPC_WRITE, nsid, lba, count); |
970 |
nvme_ns_rw_cmd(cmd, NVME_OPC_WRITE, nsid, lba, count); |
971 |
} |
971 |
} |
972 |
|
972 |
|
973 |
static inline |
973 |
static inline |
974 |
void nvme_ns_read_cmd(struct nvme_command *cmd, uint16_t nsid, |
974 |
void nvme_ns_read_cmd(struct nvme_command *cmd, uint32_t nsid, |
975 |
uint64_t lba, uint32_t count) |
975 |
uint64_t lba, uint32_t count) |
976 |
{ |
976 |
{ |
977 |
nvme_ns_rw_cmd(cmd, NVME_OPC_READ, nsid, lba, count); |
977 |
nvme_ns_rw_cmd(cmd, NVME_OPC_READ, nsid, lba, count); |
978 |
} |
978 |
} |
979 |
|
979 |
|
980 |
static inline |
980 |
static inline |
981 |
void nvme_ns_trim_cmd(struct nvme_command *cmd, uint16_t nsid, |
981 |
void nvme_ns_trim_cmd(struct nvme_command *cmd, uint32_t nsid, |
982 |
uint32_t num_ranges) |
982 |
uint32_t num_ranges) |
983 |
{ |
983 |
{ |
984 |
cmd->opc = NVME_OPC_DATASET_MANAGEMENT; |
984 |
cmd->opc = NVME_OPC_DATASET_MANAGEMENT; |