From nobody Sun Feb 8 20:00:03 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) client-ip=170.10.133.124; envelope-from=libvir-list-bounces@redhat.com; helo=us-smtp-delivery-124.mimecast.com; Authentication-Results: mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 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=1670510141; cv=none; d=zohomail.com; s=zohoarc; b=gRc5SwfbA7QnVead9xsSY2g8O7PzfIsU8eglTPDRoaKuKAbDiyw8fP0vewRycRyyHjqsbuA1By0KrOYaVAaPTcoRy+7nVjYd8s5gYReeRO5Dyxm7UDfIEudaZGqtb873BfFE14EvhLp6i/FKjqb5rnwuQ46rJCcCera43eKkv3s= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1670510141; h=Content-Type:Content-Transfer-Encoding:Date:From:In-Reply-To:List-Subscribe:List-Post:List-Id:List-Archive:List-Help:List-Unsubscribe:MIME-Version:Message-ID:References:Sender:Subject:To; bh=dEIisNgkr1h6CjQrPCARPZcYQR7hc7sG6MaxCiqUyNY=; b=ePKHKzn0zJ1gJKWh2nK5jcEL+bRlr9Mq0XhJU0wgVlx6Ad8W7buKg+qoVS5Ic0sZUbrp2TawcKLi5ISxf/KyNTPmf6yXXHOAvoOMgNqL7v+nv9d7yqJX2SeOXAjrwDuKsbZqpJ5ZJArI114+peJOijr8uHic0VKbfxF0783P4GE= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.133.124 as permitted sender) smtp.mailfrom=libvir-list-bounces@redhat.com; dmarc=pass header.from= (p=none dis=none) Return-Path: Received: from us-smtp-delivery-124.mimecast.com (us-smtp-delivery-124.mimecast.com [170.10.133.124]) by mx.zohomail.com with SMTPS id 16705101413321018.9011686373465; Thu, 8 Dec 2022 06:35:41 -0800 (PST) Received: from mimecast-mx02.redhat.com (mimecast-mx02.redhat.com [66.187.233.88]) by relay.mimecast.com with ESMTP with STARTTLS (version=TLSv1.2, cipher=TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384) id us-mta-342-TuAT67vHMOeFjM7z9KY9YQ-1; Thu, 08 Dec 2022 09:35:38 -0500 Received: from smtp.corp.redhat.com (int-mx10.intmail.prod.int.rdu2.redhat.com [10.11.54.10]) (using TLSv1.2 with cipher AECDH-AES256-SHA (256/256 bits)) (No client certificate requested) by mimecast-mx02.redhat.com (Postfix) with ESMTPS id 9ECD6185A794; Thu, 8 Dec 2022 14:35:34 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com [10.30.29.100]) by smtp.corp.redhat.com (Postfix) with ESMTP id 8AEED492B05; Thu, 8 Dec 2022 14:35:34 +0000 (UTC) Received: from mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (localhost [IPv6:::1]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id 6CA9C1946A44; Thu, 8 Dec 2022 14:35:34 +0000 (UTC) Received: from smtp.corp.redhat.com (int-mx04.intmail.prod.int.rdu2.redhat.com [10.11.54.4]) by mm-prod-listman-01.mail-001.prod.us-east-1.aws.redhat.com (Postfix) with ESMTP id B8C14194704A for ; Thu, 8 Dec 2022 14:35:33 +0000 (UTC) Received: by smtp.corp.redhat.com (Postfix) id 9F88C202903F; Thu, 8 Dec 2022 14:35:33 +0000 (UTC) Received: from localhost.localdomain.com (unknown [10.33.36.117]) by smtp.corp.redhat.com (Postfix) with ESMTP id C91462024CC5; Thu, 8 Dec 2022 14:35:31 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1670510140; h=from:from:sender:sender:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references:list-id:list-help: list-unsubscribe:list-subscribe:list-post; bh=dEIisNgkr1h6CjQrPCARPZcYQR7hc7sG6MaxCiqUyNY=; b=EcHdF8NsReEAfXuY/MeNzba84Qqp/Phva/C/Xr90apNMOFfAEl7zkv0nXIOVrRrV9tMwJ6 4l1WMiYDa5PHxvm/wwr6bExk2dATVLSdKxFDubPS4NjbEx56/ApW0tLMVSVzq/CUpeDMdL 8n/teDh+gGtz5sQ7hJdF1WdOwCmo27M= X-MC-Unique: TuAT67vHMOeFjM7z9KY9YQ-1 X-Original-To: libvir-list@listman.corp.redhat.com From: =?UTF-8?q?Daniel=20P=2E=20Berrang=C3=A9?= To: libvir-list@redhat.com Subject: [libvirt PATCH 03/21] meson: remove obsolete check for LO_FLAGS_AUTOCLEAR Date: Thu, 8 Dec 2022 14:35:07 +0000 Message-Id: <20221208143525.1731853-4-berrange@redhat.com> In-Reply-To: <20221208143525.1731853-1-berrange@redhat.com> References: <20221208143525.1731853-1-berrange@redhat.com> MIME-Version: 1.0 X-Scanned-By: MIMEDefang 3.1 on 10.11.54.4 X-BeenThere: libvir-list@redhat.com X-Mailman-Version: 2.1.29 Precedence: list List-Id: Development discussions about the libvirt library & tools List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: libvir-list-bounces@redhat.com Sender: "libvir-list" X-Scanned-By: MIMEDefang 3.1 on 10.11.54.10 X-Mimecast-Spam-Score: 0 X-Mimecast-Originator: redhat.com Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable X-ZohoMail-DKIM: pass (identity @redhat.com) X-ZM-MESSAGEID: 1670510142588100004 The LO_FLAGS_AUTOCLEAR constant was introduced to Linux in commit 96c5865559cee0f9cbc5173f3c949f6ce3525581 Author: David Woodhouse Date: Wed Feb 6 01:36:27 2008 -0800 Allow auto-destruction of loop devices This is old enough that all our supported platforms can be assumed to have this feature. For added fun this whole meson check was semantically insane because EPOLL_CLOEXEC is not a valid arg to unshare(). Signed-off-by: Daniel P. Berrang=C3=A9 --- meson.build | 3 +-- src/util/virfile.c | 6 ++---- 2 files changed, 3 insertions(+), 6 deletions(-) diff --git a/meson.build b/meson.build index f313767cfe..212c3cfafb 100644 --- a/meson.build +++ b/meson.build @@ -1532,12 +1532,11 @@ if not get_option('driver_lxc').disabled() and host= _machine.system() =3D=3D 'linux' #include =20 void main(void) { - unshare(!(LO_FLAGS_AUTOCLEAR)); + unshare(1); } ''' if cc.compiles(lxc_support_code, name: 'lxc support', args: '-D_GNU_SOUR= CE') conf.set('WITH_LXC', 1) - conf.set('WITH_DECL_LO_FLAGS_AUTOCLEAR', 1) elif get_option('driver_lxc').enabled() error('Required kernel features for LXC were not found') endif diff --git a/src/util/virfile.c b/src/util/virfile.c index cef9f9979a..7b37d6888e 100644 --- a/src/util/virfile.c +++ b/src/util/virfile.c @@ -66,9 +66,7 @@ # include # endif # include -# if WITH_DECL_LO_FLAGS_AUTOCLEAR -# include -# endif +# include # include # include /* These come from linux/fs.h, but that header conflicts with @@ -748,7 +746,7 @@ int virFileUpdatePerm(const char *path, } =20 =20 -#if defined(__linux__) && WITH_DECL_LO_FLAGS_AUTOCLEAR +#if defined(__linux__) =20 /* virFileLoopDeviceOpenLoopCtl() returns -1 when a real failure has occur= red * while in the process of allocating or opening the loop device. On succ= ess --=20 2.38.1