Message ID | 20220622051731.23563-7-matthew.ruffell@canonical.com |
---|---|
State | New |
Headers | show
Return-Path: <kernel-team-bounces@lists.ubuntu.com> X-Original-To: incoming@patchwork.ozlabs.org Delivered-To: patchwork-incoming@bilbo.ozlabs.org Authentication-Results: bilbo.ozlabs.org; dkim=fail reason="signature verification failed" (2048-bit key; unprotected) header.d=canonical.com header.i=@canonical.com header.a=rsa-sha256 header.s=20210705 header.b=DoFtBQDz; dkim-atps=neutral Authentication-Results: ozlabs.org; spf=pass (sender SPF authorized) smtp.mailfrom=lists.ubuntu.com (client-ip=91.189.94.19; helo=huckleberry.canonical.com; envelope-from=kernel-team-bounces@lists.ubuntu.com; receiver=<UNKNOWN>) Received: from huckleberry.canonical.com (huckleberry.canonical.com [91.189.94.19]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by bilbo.ozlabs.org (Postfix) with ESMTPS id 4LSWqY4QH6z9sGJ for <incoming@patchwork.ozlabs.org>; Wed, 22 Jun 2022 15:18:01 +1000 (AEST) Received: from localhost ([127.0.0.1] helo=huckleberry.canonical.com) by huckleberry.canonical.com with esmtp (Exim 4.86_2) (envelope-from <kernel-team-bounces@lists.ubuntu.com>) id 1o3skT-0008RQ-JW; Wed, 22 Jun 2022 05:17:53 +0000 Received: from smtp-relay-internal-1.internal ([10.131.114.114] helo=smtp-relay-internal-1.canonical.com) by huckleberry.canonical.com with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.86_2) (envelope-from <matthew.ruffell@canonical.com>) id 1o3skR-0008Of-RK for kernel-team@lists.ubuntu.com; Wed, 22 Jun 2022 05:17:51 +0000 Received: from mail-pf1-f197.google.com (mail-pf1-f197.google.com [209.85.210.197]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by smtp-relay-internal-1.canonical.com (Postfix) with ESMTPS id 7B6E23F194 for <kernel-team@lists.ubuntu.com>; Wed, 22 Jun 2022 05:17:51 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=canonical.com; s=20210705; t=1655875071; bh=2XxeDp33tsChh5asGlbtegYkI9lvXkbI8nEK3rPMW7U=; h=From:To:Subject:Date:Message-Id:In-Reply-To:References: MIME-Version; b=DoFtBQDzpgZFV68VGakTWTVVsu4wm7dN3h1eo6Dfia4/Sw1RYQdMxaa7fKj0U34gr Ul9TS8/MalYekvwVT4yHPjVCafPgEIJgxBjR0A4ZwHkQeMcZijHOybhNXyalDpP1We 7jsPn3v3zF8Tgyvbr0ZajZZT/xaMwnHO1Q7F2+pOByc0VWqolbwYa8Cla5zI+a45Yz qQ/XPZuE0jYZMvwENuldtve4c0xdAJ25407hphNrJQgXLZgy1Lai8tgyXTkeStUx05 VMx82q3QtkbUZonSge+iKFtl6LKkZL7KFH4uXNKTdO9AaH6Ksi8DDFqA6C+fYcSl6B MZTV/bkvrHVmw== Received: by mail-pf1-f197.google.com with SMTP id bm2-20020a056a00320200b0052531ca7c1cso2447795pfb.15 for <kernel-team@lists.ubuntu.com>; Tue, 21 Jun 2022 22:17:51 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:to:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=2XxeDp33tsChh5asGlbtegYkI9lvXkbI8nEK3rPMW7U=; b=srAJE6+Z599t9PEgQEz6YVJrnQBYTSi5bBJxIjD6ebGeT1KLOy2/oq2atmcBm9XX51 aTfnKUSKl5Z5VtB5YPXXBUfHCPetZnbnlWSUVyyOD3FI5eaUBIx8W+JrYhrWwnLd+ILq GtfGV6akrYQfH0tOuGqUYCFLHQHGcGk17YtK+DBgyDe8ezbbHaZvL9frKmjFy2SVBtT/ g0VWM0TXl/kcz/93cvS9upEfx6DfZZ6+mm2noOlBR9CFJlp3+pCCg/T5sJf+onBV6NxN mg86T3yGg1lOQbnZpOzScrtEx5qCkFU4spSpFCaEotReuClLCDWS/3S+b82XDOz2rt3W OUAg== X-Gm-Message-State: AJIora84XeN36G+xkAPz+3w4gdqwO8FIjENhgsHE6NPGBPjuOyzRSVmm TnEyCaNqO6AmirwtvBaR+CDLotFe4nUXN+Rln8pMhM6MfhxGSP2PjjhlnpwKb44EA3v/zF0IhYl xMHQPHEoihBKlRyeIi+H4mVQAJDf1f4/nkLg98r7ENg== X-Received: by 2002:a17:903:2c6:b0:16a:276a:ad81 with SMTP id s6-20020a17090302c600b0016a276aad81mr13395156plk.65.1655875069624; Tue, 21 Jun 2022 22:17:49 -0700 (PDT) X-Google-Smtp-Source: AGRyM1tspDdPsmSAwnPIZqlhpGULEZMkU4P6DgisQm/ZPOl9lZIQohJfZCd7r5GWELTBEwJaoO05qw== X-Received: by 2002:a17:903:2c6:b0:16a:276a:ad81 with SMTP id s6-20020a17090302c600b0016a276aad81mr13395143plk.65.1655875069348; Tue, 21 Jun 2022 22:17:49 -0700 (PDT) Received: from desktop.. (125-239-70-54-fibre.sparkbb.co.nz. [125.239.70.54]) by smtp.gmail.com with ESMTPSA id c200-20020a624ed1000000b005251b1fde90sm6450316pfb.219.2022.06.21.22.17.47 for <kernel-team@lists.ubuntu.com> (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 21 Jun 2022 22:17:49 -0700 (PDT) From: Matthew Ruffell <matthew.ruffell@canonical.com> To: kernel-team@lists.ubuntu.com Subject: [SRU][F][I][J][PATCH 6/6] nbd: fix io hung while disconnecting device Date: Wed, 22 Jun 2022 17:17:31 +1200 Message-Id: <20220622051731.23563-7-matthew.ruffell@canonical.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20220622051731.23563-1-matthew.ruffell@canonical.com> References: <20220622051731.23563-1-matthew.ruffell@canonical.com> MIME-Version: 1.0 X-BeenThere: kernel-team@lists.ubuntu.com X-Mailman-Version: 2.1.20 Precedence: list List-Id: Kernel team discussions <kernel-team.lists.ubuntu.com> List-Unsubscribe: <https://lists.ubuntu.com/mailman/options/kernel-team>, <mailto:kernel-team-request@lists.ubuntu.com?subject=unsubscribe> List-Archive: <https://lists.ubuntu.com/archives/kernel-team> List-Post: <mailto:kernel-team@lists.ubuntu.com> List-Help: <mailto:kernel-team-request@lists.ubuntu.com?subject=help> List-Subscribe: <https://lists.ubuntu.com/mailman/listinfo/kernel-team>, <mailto:kernel-team-request@lists.ubuntu.com?subject=subscribe> Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: base64 Errors-To: kernel-team-bounces@lists.ubuntu.com Sender: "kernel-team" <kernel-team-bounces@lists.ubuntu.com> |
Series |
nbd: requests can become stuck when disconnecting from server with qemu-nbd
|
expand
|
diff --git a/drivers/block/nbd.c b/drivers/block/nbd.c index f97f3a5adf28..ef131339a7f7 100644 --- a/drivers/block/nbd.c +++ b/drivers/block/nbd.c @@ -1401,7 +1401,7 @@ static int nbd_start_device_ioctl(struct nbd_device *nbd, struct block_device *b static void nbd_clear_sock_ioctl(struct nbd_device *nbd, struct block_device *bdev) { - sock_shutdown(nbd); + nbd_clear_sock(nbd); __invalidate_device(bdev, true); nbd_bdev_reset(bdev); if (test_and_clear_bit(NBD_RT_HAS_CONFIG_REF,