Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp247376ybl; Thu, 29 Aug 2019 22:25:08 -0700 (PDT) X-Google-Smtp-Source: APXvYqxFTjYmWnH6HWXno9Tfqi+VbYmz9Bji1upnsKD9Ndw4v2WHdo7tRcqjUjWIS8PyIdhdAY6k X-Received: by 2002:a17:902:ff0c:: with SMTP id f12mr7161294plj.67.1567142708343; Thu, 29 Aug 2019 22:25:08 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1567142708; cv=none; d=google.com; s=arc-20160816; b=IHiDSAOOzk3Nwy2DlL+omwzB02Ma75BtozPfhhFmILLXwEouD0XYyxm+jOmB0nhqaE S0p3v4BQCbSILGDV+3YrQyC6GXQd2wcs68nkv/TA6ryJ5cgXcq8rAfJqMHIn0ZJlR6xR Wkrm3EOYKqe8Rg/M2NvYOiv8Fsv39/T4MxflwAIMmQ9EL5L+0ggZ5vN6RELT8PuIdvGE Bs7JpaRHuxy66UAiIs6uYvpV4PSjylw/z0SI8sAghISDvs98tqd9F9X40PU4eCAisjp5 VkLIN/tz1VbniOKAGgQASZ7VYD1l3pofZCebG7fW03+RFcOClSpmjgokz8cbugFdEENN 1qUg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-language :content-transfer-encoding:in-reply-to:mime-version:user-agent:date :message-id:references:cc:to:from:subject; bh=o8MBBxTuZysNJKXad1wPMaqkydATBqBT0p+MxXfk5+Y=; b=HnSX7E6le/U1d8XVNFQMVHTvadU5jIUJVaz3WMk8+fYvZbRe8tcfYmSH8VedZsqmSh 6G1PHPKR6NumSEdpHn+TDT0C+p1b/anJ2D4tk/F6lAm8SxlBlsXdIGSuDRLNpmPdmBSU GKSovYJ4/3rSDXBYsxBUpHr9KvzNScCvNaOG7vksQ1J6nSDwV8d44agUkrvtQgudk47K 5Zc8AmHPrI5eelbQ1u8yXKm5i5OEhDMfKmTpZlkWB2sA+4WVu5D3yd8d4ENjGA8TWHA8 wlrcyaDslOtAb1GYuik4eIjcp5buDI0kvR/rYmBrYW2VUvbcCxDoxFaOP5fpyPa6OhQm gn4Q== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id o18si3614770pgv.494.2019.08.29.22.24.52; Thu, 29 Aug 2019 22:25:08 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=fail (p=NONE sp=NONE dis=NONE) header.from=redhat.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1727351AbfH3FWh (ORCPT + 99 others); Fri, 30 Aug 2019 01:22:37 -0400 Received: from mx1.redhat.com ([209.132.183.28]:33518 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725891AbfH3FWg (ORCPT ); Fri, 30 Aug 2019 01:22:36 -0400 Received: from smtp.corp.redhat.com (int-mx08.intmail.prod.int.phx2.redhat.com [10.5.11.23]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id C1F0F8980E2; Fri, 30 Aug 2019 05:22:36 +0000 (UTC) Received: from [10.72.12.17] (ovpn-12-17.pek2.redhat.com [10.72.12.17]) by smtp.corp.redhat.com (Postfix) with ESMTPS id A478519C58; Fri, 30 Aug 2019 05:22:34 +0000 (UTC) Subject: Re: [PATCH 2/2 v3] nbd: fix possible page fault for nbd disk From: Xiubo Li To: Mike Christie , josef@toxicpanda.com, axboe@kernel.dk Cc: linux-block@vger.kernel.org, nbd@other.debian.org, linux-kernel@vger.kernel.org References: <20190822075923.11996-1-xiubli@redhat.com> <20190822075923.11996-3-xiubli@redhat.com> <5D686498.5090602@redhat.com> <78d16d10-1d06-6ce1-7c51-64c42e51f549@redhat.com> Message-ID: Date: Fri, 30 Aug 2019 13:22:31 +0800 User-Agent: Mozilla/5.0 (Windows NT 10.0; WOW64; rv:60.0) Gecko/20100101 Thunderbird/60.8.0 MIME-Version: 1.0 In-Reply-To: <78d16d10-1d06-6ce1-7c51-64c42e51f549@redhat.com> Content-Type: text/plain; charset=windows-1252; format=flowed Content-Transfer-Encoding: 8bit Content-Language: en-US X-Scanned-By: MIMEDefang 2.84 on 10.5.11.23 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.6.2 (mx1.redhat.com [10.5.110.67]); Fri, 30 Aug 2019 05:22:36 +0000 (UTC) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 2019/8/30 8:58, Xiubo Li wrote: > On 2019/8/30 7:49, Mike Christie wrote: >> On 08/22/2019 02:59 AM, xiubli@redhat.com wrote: [...] >> >>> + test_bit(NBD_DISCONNECT_REQUESTED, &nbd->flags)) { >>> +??????? mutex_unlock(&nbd_index_mutex); >>> + >>> +??????? /* Wait untill the recv_work exit */ >> If that is all you need we could do a flush_workqueue(nbd->recv_workq) >> (you would need Jens's for next branch which has some work queue changes >> in nbd). > > Yeah, this makes sense. This has already been done in nbd_disconnect_and_put() in the Jen's for next branch code. So here it will make no sense. I will rebase this patch set to that branch. Thanks. BRs Xiubo