From nobody Sun Feb 8 18:29:57 2026 Delivered-To: importer@patchew.org Received-SPF: pass (zohomail.com: domain of redhat.com designates 170.10.129.124 as permitted sender) client-ip=170.10.129.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.129.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=1670510241; cv=none; d=zohomail.com; s=zohoarc; b=h5mFNV5TZoxaDbjRQpQ8u2S+7CF3+pNsY7gfllZbob5YElNk1WIdaGDM3+b7ZjeT55QBduubdnIuWV5LjCfckFUZ4b99fvsIkvxM9d8DjCcb3vhDHRzAeTHptWWGelzrUbEYv+DqSAqPjuq+8GwTNDgseyE8d8F9S9natOGd0mA= ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=zohomail.com; s=zohoarc; t=1670510241; 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=cx5N1Vn8UsG3bvXZTTLUlhHmMANhz/52f8agGoKPsfE=; b=Tj1k2sDGcFW44WXSEtiHFaxLs2OQ9ao5ALs6woLESsxgFhfudRXCSdCcY4ura3Z9w0BAjwbldHa5rjvRSKDMUz8Uehq2lUo07xFmrTjX/FJ4LwzvoYLujuRRh/e9Owg8kYZ5g8SZOvSsgCJUM9acZrqq6RtOXZBtAhClJ1Gaa+Y= ARC-Authentication-Results: i=1; mx.zohomail.com; dkim=pass; spf=pass (zohomail.com: domain of redhat.com designates 170.10.129.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.129.124]) by mx.zohomail.com with SMTPS id 1670510241396623.8415937004172; Thu, 8 Dec 2022 06:37:21 -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-175-kkcEcrEcPSeLBdJt8BUkGA-1; Thu, 08 Dec 2022 09:36:35 -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 483C58065FC; Thu, 8 Dec 2022 14:36:00 +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 31E93492B04; Thu, 8 Dec 2022 14:36:00 +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 EE7821946A7C; Thu, 8 Dec 2022 14:35:59 +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 B485F194704B for ; Thu, 8 Dec 2022 14:35:51 +0000 (UTC) Received: by smtp.corp.redhat.com (Postfix) id 99A772023A16; Thu, 8 Dec 2022 14:35:48 +0000 (UTC) Received: from localhost.localdomain.com (unknown [10.33.36.117]) by smtp.corp.redhat.com (Postfix) with ESMTP id 1062D2028E8F; Thu, 8 Dec 2022 14:35:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=redhat.com; s=mimecast20190719; t=1670510239; 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=cx5N1Vn8UsG3bvXZTTLUlhHmMANhz/52f8agGoKPsfE=; b=LafgRMVSkVp5YEr/SrJ5bpuJnB9oVZyLzts3CfL1EGbMvq8neApA0OGebmC9GCVOkHpwnc hXKlb9uUgz97JTsX5+73BbBPf7JVWRUYz/qyfV2M2FL5RLGsmUN8eR0c21bO8bZ2gKAKiQ 35WIu7+Tg9vckqKRZf9AQGlX1tukrIc= X-MC-Unique: kkcEcrEcPSeLBdJt8BUkGA-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 20/21] meson: remove obsolete check for BPF_PROG_QUERY Date: Thu, 8 Dec 2022 14:35:24 +0000 Message-Id: <20221208143525.1731853-21-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: 1670510242775100001 The BPF_PROG_QUERY constant was introduced to Linux in commit defd9c476fa6b01b4eb5450452bfd202138decb7 Author: Alexei Starovoitov Date: Mon Oct 2 22:50:26 2017 -0700 libbpf: sync bpf.h This is old enough that all our supported platforms can be assumed to have this feature. Signed-off-by: Daniel P. Berrang=C3=A9 --- meson.build | 1 - src/util/virbpf.c | 6 +++--- src/util/virbpf.h | 6 +++--- 3 files changed, 6 insertions(+), 7 deletions(-) diff --git a/meson.build b/meson.build index 95bc89ec52..790d52ec8d 100644 --- a/meson.build +++ b/meson.build @@ -647,7 +647,6 @@ symbols =3D [ if host_machine.system() =3D=3D 'linux' symbols +=3D [ # Check if we have new enough kernel to support BPF devices for cgroup= s v2 - [ 'linux/bpf.h', 'BPF_PROG_QUERY' ], [ 'linux/bpf.h', 'BPF_CGROUP_DEVICE' ], ] endif diff --git a/src/util/virbpf.c b/src/util/virbpf.c index 1169b99d07..34abf6f9b4 100644 --- a/src/util/virbpf.c +++ b/src/util/virbpf.c @@ -24,7 +24,7 @@ VIR_LOG_INIT("util.bpf"); =20 #define VIR_FROM_THIS VIR_FROM_BPF =20 -#if WITH_SYS_SYSCALL_H && WITH_DECL_BPF_PROG_QUERY +#ifdef __linux__ # include # include =20 @@ -292,7 +292,7 @@ virBPFDeleteElem(int mapfd, } =20 =20 -#else /* !WITH_SYS_SYSCALL_H || !WITH_DECL_BPF_PROG_QUERY */ +#else /* ! __linux__ */ =20 =20 int @@ -420,4 +420,4 @@ virBPFDeleteElem(int mapfd G_GNUC_UNUSED, errno =3D ENOSYS; return -1; } -#endif /* !WITH_SYS_SYSCALL_H || !WITH_DECL_BPF_PROG_QUERY */ +#endif /* !__linux__ */ diff --git a/src/util/virbpf.h b/src/util/virbpf.h index 1eafce86c0..cf21ac2d40 100644 --- a/src/util/virbpf.h +++ b/src/util/virbpf.h @@ -18,7 +18,7 @@ =20 #pragma once =20 -#if WITH_DECL_BPF_PROG_QUERY +#ifdef __linux__ =20 # include =20 @@ -171,7 +171,7 @@ .imm =3D 0, \ }) =20 -#else /* WITH_DECL_BPF_PROG_QUERY */ +#else /* ! __linux__ */ =20 struct bpf_prog_info; struct bpf_map_info; @@ -191,7 +191,7 @@ struct bpf_insn; # define VIR_BPF_CALL_INSN(func) # define VIR_BPF_EXIT_INSN() =20 -#endif /* WITH_DECL_BPF_PROG_QUERY */ +#endif /* ! __linux__ */ =20 int virBPFCreateMap(unsigned int mapType, --=20 2.38.1