Skip to content

Commit 485783c

Browse files
Keith BuschChristoph Hellwig
authored andcommitted
nvme: Make nvme user functions static
These functions are used only locally in the nvme core. Signed-off-by: Keith Busch <[email protected]> Reviewed-by: Sagi Grimberg <[email protected]> Reviewed-by: Max Gurtovoy <[email protected]> Signed-off-by: Christoph Hellwig <[email protected]>
1 parent b5d8af5 commit 485783c

File tree

2 files changed

+5
-12
lines changed

2 files changed

+5
-12
lines changed

drivers/nvme/host/core.c

Lines changed: 5 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -634,10 +634,10 @@ static void *nvme_add_user_metadata(struct bio *bio, void __user *ubuf,
634634
return ERR_PTR(ret);
635635
}
636636

637-
int __nvme_submit_user_cmd(struct request_queue *q, struct nvme_command *cmd,
638-
void __user *ubuffer, unsigned bufflen,
639-
void __user *meta_buffer, unsigned meta_len, u32 meta_seed,
640-
u32 *result, unsigned timeout)
637+
static int __nvme_submit_user_cmd(struct request_queue *q,
638+
struct nvme_command *cmd, void __user *ubuffer,
639+
unsigned bufflen, void __user *meta_buffer, unsigned meta_len,
640+
u32 meta_seed, u32 *result, unsigned timeout)
641641
{
642642
bool write = nvme_is_write(cmd);
643643
struct nvme_ns *ns = q->queuedata;
@@ -690,7 +690,7 @@ int __nvme_submit_user_cmd(struct request_queue *q, struct nvme_command *cmd,
690690
return ret;
691691
}
692692

693-
int nvme_submit_user_cmd(struct request_queue *q, struct nvme_command *cmd,
693+
static int nvme_submit_user_cmd(struct request_queue *q, struct nvme_command *cmd,
694694
void __user *ubuffer, unsigned bufflen, u32 *result,
695695
unsigned timeout)
696696
{

drivers/nvme/host/nvme.h

Lines changed: 0 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -314,13 +314,6 @@ int nvme_submit_sync_cmd(struct request_queue *q, struct nvme_command *cmd,
314314
int __nvme_submit_sync_cmd(struct request_queue *q, struct nvme_command *cmd,
315315
union nvme_result *result, void *buffer, unsigned bufflen,
316316
unsigned timeout, int qid, int at_head, int flags);
317-
int nvme_submit_user_cmd(struct request_queue *q, struct nvme_command *cmd,
318-
void __user *ubuffer, unsigned bufflen, u32 *result,
319-
unsigned timeout);
320-
int __nvme_submit_user_cmd(struct request_queue *q, struct nvme_command *cmd,
321-
void __user *ubuffer, unsigned bufflen,
322-
void __user *meta_buffer, unsigned meta_len, u32 meta_seed,
323-
u32 *result, unsigned timeout);
324317
int nvme_set_queue_count(struct nvme_ctrl *ctrl, int *count);
325318
void nvme_start_keep_alive(struct nvme_ctrl *ctrl);
326319
void nvme_stop_keep_alive(struct nvme_ctrl *ctrl);

0 commit comments

Comments
 (0)