From patchwork Fri Jul 29 19:57:22 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Sagi Grimberg X-Patchwork-Id: 9252803 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id 580446075F for ; Fri, 29 Jul 2016 19:57:41 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 49653283F3 for ; Fri, 29 Jul 2016 19:57:41 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id 3DD2628411; Fri, 29 Jul 2016 19:57:41 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id E2AE4283F3 for ; Fri, 29 Jul 2016 19:57:40 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1752949AbcG2T5k (ORCPT ); Fri, 29 Jul 2016 15:57:40 -0400 Received: from merlin.infradead.org ([205.233.59.134]:40370 "EHLO merlin.infradead.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752364AbcG2T5j (ORCPT ); Fri, 29 Jul 2016 15:57:39 -0400 Received: from 212.116.139.77.rev.sfr.net ([77.139.116.212] helo=bombadil.infradead.org) by merlin.infradead.org with esmtpsa (Exim 4.85_2 #1 (Red Hat Linux)) id 1bTDuc-0000SY-NW; Fri, 29 Jul 2016 19:57:38 +0000 From: Sagi Grimberg To: linux-nvme@lists.infradead.org Cc: linux-rdma@vger.kernel.org, Steve Wise , Christoph Hellwig , Jay Freyensee , Jens Axboe Subject: [PATCH 5/5] nvme-loop: Remove duplicate call to nvme_remove_namespaces Date: Fri, 29 Jul 2016 22:57:22 +0300 Message-Id: <1469822242-3477-6-git-send-email-sagi@grimberg.me> X-Mailer: git-send-email 1.9.1 In-Reply-To: <1469822242-3477-1-git-send-email-sagi@grimberg.me> References: <1469822242-3477-1-git-send-email-sagi@grimberg.me> Sender: linux-rdma-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-rdma@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP nvme_uninit_ctrl already does that for us. Signed-off-by: Sagi Grimberg --- drivers/nvme/target/loop.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/nvme/target/loop.c b/drivers/nvme/target/loop.c index 94e782987cc9..7affd40a6b33 100644 --- a/drivers/nvme/target/loop.c +++ b/drivers/nvme/target/loop.c @@ -414,9 +414,8 @@ static void nvme_loop_del_ctrl_work(struct work_struct *work) struct nvme_loop_ctrl *ctrl = container_of(work, struct nvme_loop_ctrl, delete_work); - nvme_remove_namespaces(&ctrl->ctrl); - nvme_loop_shutdown_ctrl(ctrl); nvme_uninit_ctrl(&ctrl->ctrl); + nvme_loop_shutdown_ctrl(ctrl); nvme_put_ctrl(&ctrl->ctrl); } @@ -501,7 +500,6 @@ out_free_queues: nvme_loop_destroy_admin_queue(ctrl); out_disable: dev_warn(ctrl->ctrl.device, "Removing after reset failure\n"); - nvme_remove_namespaces(&ctrl->ctrl); nvme_uninit_ctrl(&ctrl->ctrl); nvme_put_ctrl(&ctrl->ctrl); }