Skip to content

Commit 43dc987

Browse files
nmtadamChristoph Hellwig
authored andcommitted
nvme: move nvme_multi_css into nvme.h
Preparatory patch in order to reuse nvme_multi_css in the nvme target code. Signed-off-by: Adam Manzanares <[email protected]> Reviewed-by: Keith Busch <[email protected]> Signed-off-by: Christoph Hellwig <[email protected]>
1 parent e7d6580 commit 43dc987

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

drivers/nvme/host/core.c

Lines changed: 0 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1302,11 +1302,6 @@ static int nvme_identify_ctrl(struct nvme_ctrl *dev, struct nvme_id_ctrl **id)
13021302
return error;
13031303
}
13041304

1305-
static bool nvme_multi_css(struct nvme_ctrl *ctrl)
1306-
{
1307-
return (ctrl->ctrl_config & NVME_CC_CSS_MASK) == NVME_CC_CSS_CSI;
1308-
}
1309-
13101305
static int nvme_process_ns_desc(struct nvme_ctrl *ctrl, struct nvme_ns_ids *ids,
13111306
struct nvme_ns_id_desc *cur, bool *csi_seen)
13121307
{

drivers/nvme/host/nvme.h

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -892,4 +892,9 @@ struct nvme_ctrl *nvme_ctrl_from_file(struct file *file);
892892
struct nvme_ns *nvme_find_get_ns(struct nvme_ctrl *ctrl, unsigned nsid);
893893
void nvme_put_ns(struct nvme_ns *ns);
894894

895+
static inline bool nvme_multi_css(struct nvme_ctrl *ctrl)
896+
{
897+
return (ctrl->ctrl_config & NVME_CC_CSS_MASK) == NVME_CC_CSS_CSI;
898+
}
899+
895900
#endif /* _NVME_H */

0 commit comments

Comments
 (0)