Skip to content

Commit 9b66fc0

Browse files
minwooimChristoph Hellwig
authored andcommitted
nvme: unexport functions with no external caller
There are no callers for nvme_reset_ctrl_sync() and nvme_alloc_request_qid() so that we keep the symbols exported. Unexport those functions, mark them static and update the header file respectively. Signed-off-by: Minwoo Im <minwoo.im.dev@gmail.com> Signed-off-by: Christoph Hellwig <hch@lst.de>
1 parent 62df801 commit 9b66fc0

2 files changed

Lines changed: 2 additions & 7 deletions

File tree

drivers/nvme/host/core.c

Lines changed: 2 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -179,7 +179,7 @@ int nvme_reset_ctrl(struct nvme_ctrl *ctrl)
179179
}
180180
EXPORT_SYMBOL_GPL(nvme_reset_ctrl);
181181

182-
int nvme_reset_ctrl_sync(struct nvme_ctrl *ctrl)
182+
static int nvme_reset_ctrl_sync(struct nvme_ctrl *ctrl)
183183
{
184184
int ret;
185185

@@ -192,7 +192,6 @@ int nvme_reset_ctrl_sync(struct nvme_ctrl *ctrl)
192192

193193
return ret;
194194
}
195-
EXPORT_SYMBOL_GPL(nvme_reset_ctrl_sync);
196195

197196
static void nvme_do_delete_ctrl(struct nvme_ctrl *ctrl)
198197
{
@@ -578,7 +577,7 @@ struct request *nvme_alloc_request(struct request_queue *q,
578577
}
579578
EXPORT_SYMBOL_GPL(nvme_alloc_request);
580579

581-
struct request *nvme_alloc_request_qid(struct request_queue *q,
580+
static struct request *nvme_alloc_request_qid(struct request_queue *q,
582581
struct nvme_command *cmd, blk_mq_req_flags_t flags, int qid)
583582
{
584583
struct request *req;
@@ -589,7 +588,6 @@ struct request *nvme_alloc_request_qid(struct request_queue *q,
589588
nvme_init_request(req, cmd);
590589
return req;
591590
}
592-
EXPORT_SYMBOL_GPL(nvme_alloc_request_qid);
593591

594592
static int nvme_toggle_streams(struct nvme_ctrl *ctrl, bool enable)
595593
{

drivers/nvme/host/nvme.h

Lines changed: 0 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -610,8 +610,6 @@ void nvme_start_freeze(struct nvme_ctrl *ctrl);
610610
#define NVME_QID_ANY -1
611611
struct request *nvme_alloc_request(struct request_queue *q,
612612
struct nvme_command *cmd, blk_mq_req_flags_t flags);
613-
struct request *nvme_alloc_request_qid(struct request_queue *q,
614-
struct nvme_command *cmd, blk_mq_req_flags_t flags, int qid);
615613
void nvme_cleanup_cmd(struct request *req);
616614
blk_status_t nvme_setup_cmd(struct nvme_ns *ns, struct request *req,
617615
struct nvme_command *cmd);
@@ -630,7 +628,6 @@ int nvme_get_features(struct nvme_ctrl *dev, unsigned int fid,
630628
int nvme_set_queue_count(struct nvme_ctrl *ctrl, int *count);
631629
void nvme_stop_keep_alive(struct nvme_ctrl *ctrl);
632630
int nvme_reset_ctrl(struct nvme_ctrl *ctrl);
633-
int nvme_reset_ctrl_sync(struct nvme_ctrl *ctrl);
634631
int nvme_try_sched_reset(struct nvme_ctrl *ctrl);
635632
int nvme_delete_ctrl(struct nvme_ctrl *ctrl);
636633

0 commit comments

Comments
 (0)