From nobody Fri Apr 19 10:27:56 2024 Delivered-To: importer@patchew.org Received-SPF: pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) client-ip=209.132.183.28; envelope-from=libvir-list-bounces@redhat.com; helo=mx1.redhat.com; Authentication-Results: mx.zohomail.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass(p=none dis=none) header.from=redhat.com ARC-Seal: i=1; a=rsa-sha256; t=1555345326; cv=none; d=zoho.com; s=zohoarc; b=OttNSvYl/qWfZiEDJHKkpeLfB/9cbO6D4+0eemX2Yc25t+UimOvdMNG2NiIkAIweP2NnpNiycInmA7v5oOtY9VBqJtkMp9GkwNNqsV2HRMOSPACTFg2wCNpUWsFkVdZI/MTMMYIm7rOFDGuISl0psL7H3mJi08ElByAceBbx50Q= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zoho.com; s=zohoarc; t=1555345326; h=Content-Type:Content-Transfer-Encoding:Cc:Date:From:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:Sender:Subject:To:ARC-Authentication-Results; bh=xJqCRN3Ux/KsiGQJvzrSETdIwELeGxCcG+xYtvW6uXc=; b=lBxNxHEIqqsbehPrc9GqzZlkMFjiiBuLIQvjDJcmw79xrL8jn1EgN+RyBZCb7ZgnUfq90GLEDD2JbiF3CRDXg/coWa8sKFosLT+vmoqjDMl/vYywhJ9mYpfgNRjcacdF9xYgCZz03+YyrQLjKtoy4blfcdKSjP8keNfTlttbYxY= ARC-Authentication-Results: i=1; mx.zoho.com; spf=pass (zoho.com: domain of redhat.com designates 209.132.183.28 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) header.from= Return-Path: Received: from mx1.redhat.com (mx1.redhat.com [209.132.183.28]) by mx.zohomail.com with SMTPS id 1555345326042908.7075380962257; Mon, 15 Apr 2019 09:22:06 -0700 (PDT) Received: from smtp.corp.redhat.com (int-mx06.intmail.prod.int.phx2.redhat.com [10.5.11.16]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mx1.redhat.com (Postfix) with ESMTPS id 3B8F13092655; Mon, 15 Apr 2019 16:22:03 +0000 (UTC) Received: from colo-mx.corp.redhat.com (colo-mx02.intmail.prod.int.phx2.redhat.com [10.5.11.21]) by smtp.corp.redhat.com (Postfix) with ESMTPS id 9F5A75C1B4; Mon, 15 Apr 2019 16:22:02 +0000 (UTC) Received: from lists01.pubmisc.prod.ext.phx2.redhat.com (lists01.pubmisc.prod.ext.phx2.redhat.com [10.5.19.33]) by colo-mx.corp.redhat.com (Postfix) with ESMTP id 844D53FB11; Mon, 15 Apr 2019 16:21:56 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx01.intmail.prod.int.phx2.redhat.com [10.5.11.11]) by lists01.pubmisc.prod.ext.phx2.redhat.com (8.13.8/8.13.8) with ESMTP id x3FGLakV007526 for ; Mon, 15 Apr 2019 12:21:36 -0400 Received: by smtp.corp.redhat.com (Postfix) id 3C04060141; Mon, 15 Apr 2019 16:21:36 +0000 (UTC) Received: from localhost (unknown [10.36.112.11]) by smtp.corp.redhat.com (Postfix) with ESMTP id 8458060123; Mon, 15 Apr 2019 16:21:30 +0000 (UTC) From: =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= To: qemu-devel@nongnu.org Date: Mon, 15 Apr 2019 18:21:29 +0200 Message-Id: <20190415162129.30511-1-marcandre.lureau@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 2.79 on 10.5.11.11 X-loop: libvir-list@redhat.com Cc: "reviewer:Incompatible changes" , =?UTF-8?q?Marc-Andr=C3=A9=20Lureau?= , Paolo Bonzini Subject: [libvirt] [PATCH v3] socket: allow wait=false for client socket X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.12 Precedence: junk List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Sender: libvir-list-bounces@redhat.com Errors-To: libvir-list-bounces@redhat.com X-Scanned-By: MIMEDefang 2.79 on 10.5.11.16 X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-4.5.16 (mx1.redhat.com [10.5.110.43]); Mon, 15 Apr 2019 16:22:03 +0000 (UTC) Commit 767abe7 ("chardev: forbid 'wait' option with client sockets") is a bit too strict. Current libvirt always set wait=3Dfalse, and will thus fail to add client chardev. Make the code more permissive, allowing wait=3Dfalse with client socket chardevs. Deprecate usage of 'wait' with client sockets. Fixes: 767abe7f49e8be14d29da5db3527817b5d696a52 Cc: Daniel P. Berrang=C3=A9 Signed-off-by: Marc-Andr=C3=A9 Lureau --- chardev/char-socket.c | 10 +++++++--- qemu-deprecated.texi | 5 +++++ 2 files changed, 12 insertions(+), 3 deletions(-) diff --git a/chardev/char-socket.c b/chardev/char-socket.c index 3916505d67..ebc1adb83e 100644 --- a/chardev/char-socket.c +++ b/chardev/char-socket.c @@ -1263,9 +1263,13 @@ static bool qmp_chardev_validate_socket(ChardevSocke= t *sock, return false; } if (sock->has_wait) { - error_setg(errp, "%s", - "'wait' option is incompatible with " - "socket in client connect mode"); + warn_report("'wait' option is deprecated with " + "socket in client connect mode"); + if (sock->wait) { + error_setg(errp, "%s", + "'wait' option is incompatible with " + "socket in client connect mode"); + } return false; } } diff --git a/qemu-deprecated.texi b/qemu-deprecated.texi index 2219386769..842e71b11d 100644 --- a/qemu-deprecated.texi +++ b/qemu-deprecated.texi @@ -105,6 +105,11 @@ details. The ``query-events'' command has been superseded by the more powerful and accurate ``query-qmp-schema'' command. =20 +@subsection chardev client socket with 'wait' option (since 4.0) + +Character devices creating sockets in client mode should not specify +the 'wait' field, which is only applicable to sockets in server mode + @section Human Monitor Protocol (HMP) commands =20 @subsection The hub_id parameter of 'hostfwd_add' / 'hostfwd_remove' (sinc= e 3.1) --=20 2.21.0.313.ge35b8cb8e2 -- libvir-list mailing list libvir-list@redhat.com https://www.redhat.com/mailman/listinfo/libvir-list