Received: by 2002:a25:8b91:0:0:0:0:0 with SMTP id j17csp441047ybl; Wed, 11 Dec 2019 02:16:07 -0800 (PST) X-Google-Smtp-Source: APXvYqy/qUYuu4TuXNXA8BzBDyT1FtpkulGhg34y5+PvnVApyafeYDuXREYXE8e2k/rkF5PCTSdU X-Received: by 2002:aca:c389:: with SMTP id t131mr2036964oif.102.1576059366993; Wed, 11 Dec 2019 02:16:06 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1576059366; cv=none; d=google.com; s=arc-20160816; b=uqG+8t2WVNH1+D0WfdQZ4Eu3UqqJuOSQhop6XCm1BFuAa9ME84IYSTMKMeFlMog4W4 52xOGpoYZbDg6OVupWwBg8YxoybM0dJZIZJa0imkmyVUHEtUTIvnBzLOmOvEoBrgecEA 8EhKWuO6F5zWTgTf2pB61pBFZkz/KHJL/4j7dnM68BOtdNyQEP7+6+kC8FiQkG07bwQV 9mo/hjnBU6KLxwb/gJI96r991lumgqs7F+NVRcQSAZUFMpkk9fxHd12UFxKcck5M3Tjp sNNMgXGriKT9DKqRi6DuihI1OH89hYTaoQr6I7wCvdXiepIAo/tS3rdRgIcZ66oaXBUI fgAQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:mime-version:content-transfer-encoding :content-language:accept-language:in-reply-to:references:message-id :date:thread-index:thread-topic:subject:cc:to:from:ironport-sdr :dkim-signature; bh=QAxEg8wAMpeQpGJaY0emkukCqNQsOl8+HnDT4r3pg28=; b=kaypG6Rgv6PXNpdfHKWMkc7TRbhhJEA2dFcIN7IvewxEvNsfLfDmmUOedS3UOctg98 5eOOcb4sJ/osP8RMbvfpcmgkc3G3jSQhJneEvFapw8YSjCPVD6Nu95FVsowiQmbDw0EU RcAoq2INBd3teYMkA+bW39LVzak7qQ8yvZl1qjy8TYnLuwUTH254S2tfu386XFVtf4IX H9lXFGCpgd2f3ufP/ELWjHMmwTcNgintiSQoZh3NAr63el0I/D6Zc8b2l2PI+zTtwu1Q xS+OrU9y+iJNDTIpfdzaAhuk/1D1nq1vf/gCEffBYtHEbahrWTlWDl3xPKDQK3I48q6V NPBw== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amazon.com header.s=amazon201209 header.b=r4k5bDE+; 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=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 8si819956otd.274.2019.12.11.02.15.54; Wed, 11 Dec 2019 02:16:06 -0800 (PST) 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; dkim=pass header.i=@amazon.com header.s=amazon201209 header.b=r4k5bDE+; 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=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=amazon.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1728817AbfLKKPF (ORCPT + 99 others); Wed, 11 Dec 2019 05:15:05 -0500 Received: from smtp-fw-6001.amazon.com ([52.95.48.154]:23253 "EHLO smtp-fw-6001.amazon.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1728104AbfLKKPF (ORCPT ); Wed, 11 Dec 2019 05:15:05 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amazon.com; i=@amazon.com; q=dns/txt; s=amazon201209; t=1576059304; x=1607595304; h=from:to:cc:subject:date:message-id:references: in-reply-to:content-transfer-encoding:mime-version; bh=QAxEg8wAMpeQpGJaY0emkukCqNQsOl8+HnDT4r3pg28=; b=r4k5bDE+O6EnMs0orPfb0e4hrclInphNptcIF9f+mHDUTxfAb8YfTOF5 7N/F99pZjPYNIRxcN0ul26xg/rZtuMqkeUCORz39zSfNOEBI5uuFvh7fX rfWYOYp9SYBndo5Ege/ehN3zvx0ejmz5jqNIujhYlu/8muyySCfx9cT/x g=; IronPort-SDR: TlUAzD03+db+XnCJ5SOx7jg8iAfAJAsCWzYeaF5UYwd4Ir/j6CHWtxsj3vujq21Oo9aEwN3lFc ATTxI2ku0eEg== X-IronPort-AV: E=Sophos;i="5.69,301,1571702400"; d="scan'208";a="8587630" Received: from iad6-co-svc-p1-lb1-vlan3.amazon.com (HELO email-inbound-relay-1e-62350142.us-east-1.amazon.com) ([10.124.125.6]) by smtp-border-fw-out-6001.iad6.amazon.com with ESMTP; 11 Dec 2019 10:15:03 +0000 Received: from EX13MTAUEA001.ant.amazon.com (iad55-ws-svc-p15-lb9-vlan3.iad.amazon.com [10.40.159.166]) by email-inbound-relay-1e-62350142.us-east-1.amazon.com (Postfix) with ESMTPS id 27B06A29F7; Wed, 11 Dec 2019 10:15:01 +0000 (UTC) Received: from EX13D32EUC004.ant.amazon.com (10.43.164.121) by EX13MTAUEA001.ant.amazon.com (10.43.61.243) with Microsoft SMTP Server (TLS) id 15.0.1367.3; Wed, 11 Dec 2019 10:15:00 +0000 Received: from EX13D32EUC003.ant.amazon.com (10.43.164.24) by EX13D32EUC004.ant.amazon.com (10.43.164.121) with Microsoft SMTP Server (TLS) id 15.0.1367.3; Wed, 11 Dec 2019 10:15:00 +0000 Received: from EX13D32EUC003.ant.amazon.com ([10.43.164.24]) by EX13D32EUC003.ant.amazon.com ([10.43.164.24]) with mapi id 15.00.1367.000; Wed, 11 Dec 2019 10:14:59 +0000 From: "Durrant, Paul" To: =?iso-8859-1?Q?Roger_Pau_Monn=E9?= CC: "xen-devel@lists.xenproject.org" , "linux-kernel@vger.kernel.org" , Juergen Gross , Stefano Stabellini , "Boris Ostrovsky" Subject: RE: [Xen-devel] [PATCH v2 2/4] xenbus: limit when state is forced to closed Thread-Topic: [Xen-devel] [PATCH v2 2/4] xenbus: limit when state is forced to closed Thread-Index: AQHVr029Jnf5zy5/UEOnUavFsd58GKe0trGAgAABW5A= Date: Wed, 11 Dec 2019 10:14:59 +0000 Message-ID: <86a7d140501047028c49736c43fe547c@EX13D32EUC003.ant.amazon.com> References: <20191210113347.3404-1-pdurrant@amazon.com> <20191210113347.3404-3-pdurrant@amazon.com> <20191211100627.GI980@Air-de-Roger> In-Reply-To: <20191211100627.GI980@Air-de-Roger> Accept-Language: en-GB, en-US Content-Language: en-US X-MS-Has-Attach: X-MS-TNEF-Correlator: x-ms-exchange-transport-fromentityheader: Hosted x-originating-ip: [10.43.166.120] Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable MIME-Version: 1.0 Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org > -----Original Message----- > From: Roger Pau Monn=E9 > Sent: 11 December 2019 10:06 > To: Durrant, Paul > Cc: xen-devel@lists.xenproject.org; linux-kernel@vger.kernel.org; Juergen > Gross ; Stefano Stabellini ; > Boris Ostrovsky > Subject: Re: [Xen-devel] [PATCH v2 2/4] xenbus: limit when state is force= d > to closed >=20 > On Tue, Dec 10, 2019 at 11:33:45AM +0000, Paul Durrant wrote: > > If a driver probe() fails then leave the xenstore state alone. There is > no > > reason to modify it as the failure may be due to transient resource > > allocation issues and hence a subsequent probe() may succeed. > > > > If the driver supports re-binding then only force state to closed durin= g > > remove() only in the case when the toolstack may need to clean up. This > can > > be detected by checking whether the state in xenstore has been set to > > closing prior to device removal. > > > > NOTE: Re-bind support is indicated by new boolean in struct > xenbus_driver, > > which defaults to false. Subsequent patches will add support to > > some backend drivers. >=20 > My intention was to specify whether you want to close the > backends on unbind in sysfs, so that an user can decide at runtime, > rather than having a hardcoded value in the driver. >=20 > Anyway, I'm less sure whether such runtime tunable is useful at all, > so let's leave it out and can always be added afterwards. At the end > of day a user wrongly doing a rmmod blkback can always recover > gracefully by loading blkback again with your proposed approach to > leave connections open on module removal. >=20 > Sorry for the extra work. >=20 Does this mean you don't think the extra driver flag is necessary any more?= NB: now that xenbus actually takes module references you can't accidentall= y rmmod any more :-) Paul