loop.c (b70366e5d31788650b2a5cec5cd13ea80ac7e44a) loop.c (e4c5d3762e2d6d274bd1cc948c47063becfa2103)
1/*
2 * NVMe over Fabrics loopback device.
3 * Copyright (c) 2015-2016 HGST, a Western Digital Company.
4 *
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms and conditions of the GNU General Public License,
7 * version 2, as published by the Free Software Foundation.
8 *

--- 274 unchanged lines hidden (view full) ---

283 .complete = nvme_loop_complete_rq,
284 .init_request = nvme_loop_init_admin_request,
285 .init_hctx = nvme_loop_init_admin_hctx,
286 .timeout = nvme_loop_timeout,
287};
288
289static void nvme_loop_destroy_admin_queue(struct nvme_loop_ctrl *ctrl)
290{
1/*
2 * NVMe over Fabrics loopback device.
3 * Copyright (c) 2015-2016 HGST, a Western Digital Company.
4 *
5 * This program is free software; you can redistribute it and/or modify it
6 * under the terms and conditions of the GNU General Public License,
7 * version 2, as published by the Free Software Foundation.
8 *

--- 274 unchanged lines hidden (view full) ---

283 .complete = nvme_loop_complete_rq,
284 .init_request = nvme_loop_init_admin_request,
285 .init_hctx = nvme_loop_init_admin_hctx,
286 .timeout = nvme_loop_timeout,
287};
288
289static void nvme_loop_destroy_admin_queue(struct nvme_loop_ctrl *ctrl)
290{
291 nvmet_sq_destroy(&ctrl->queues[0].nvme_sq);
291 blk_cleanup_queue(ctrl->ctrl.admin_q);
292 blk_mq_free_tag_set(&ctrl->admin_tag_set);
292 blk_cleanup_queue(ctrl->ctrl.admin_q);
293 blk_mq_free_tag_set(&ctrl->admin_tag_set);
293 nvmet_sq_destroy(&ctrl->queues[0].nvme_sq);
294}
295
296static void nvme_loop_free_ctrl(struct nvme_ctrl *nctrl)
297{
298 struct nvme_loop_ctrl *ctrl = to_loop_ctrl(nctrl);
299
300 if (list_empty(&ctrl->list))
301 goto free_ctrl;

--- 448 unchanged lines hidden ---
294}
295
296static void nvme_loop_free_ctrl(struct nvme_ctrl *nctrl)
297{
298 struct nvme_loop_ctrl *ctrl = to_loop_ctrl(nctrl);
299
300 if (list_empty(&ctrl->list))
301 goto free_ctrl;

--- 448 unchanged lines hidden ---