From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from lists.xenproject.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id D291DCA1015 for ; Thu, 4 Sep 2025 13:51:00 +0000 (UTC) Received: from list by lists.xenproject.org with outflank-mailman.1110232.1459497 (Exim 4.92) (envelope-from ) id 1uuAMO-000065-AY; Thu, 04 Sep 2025 13:50:44 +0000 X-Outflank-Mailman: Message body and most headers restored to incoming version Received: by outflank-mailman (output) from mailman id 1110232.1459497; Thu, 04 Sep 2025 13:50:44 +0000 Received: from localhost ([127.0.0.1] helo=lists.xenproject.org) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1uuAMO-00005y-6J; Thu, 04 Sep 2025 13:50:44 +0000 Received: by outflank-mailman (input) for mailman id 1110232; Thu, 04 Sep 2025 13:50:43 +0000 Received: from mail.xenproject.org ([104.130.215.37]) by lists.xenproject.org with esmtp (Exim 4.92) (envelope-from ) id 1uuAMN-00005r-4E for xen-devel@lists.xenproject.org; Thu, 04 Sep 2025 13:50:43 +0000 Received: from xenbits.xenproject.org ([104.239.192.120]) by mail.xenproject.org with esmtp (Exim 4.96) (envelope-from ) id 1uuAML-006HO8-3D; Thu, 04 Sep 2025 13:50:42 +0000 Received: from [2a01:cb15:80df:da00:d2b0:117d:791c:30c0] (helo=l14) by xenbits.xenproject.org with esmtpsa (TLS1.3) tls TLS_ECDHE_RSA_WITH_AES_256_GCM_SHA384 (Exim 4.96) (envelope-from ) id 1uuAML-00FhpW-1x; Thu, 04 Sep 2025 13:50:41 +0000 X-BeenThere: xen-devel@lists.xenproject.org List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Errors-To: xen-devel-bounces@lists.xenproject.org Precedence: list Sender: "Xen-devel" DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=xenproject.org; s=20200302mail; h=In-Reply-To:Content-Type:MIME-Version: References:Message-ID:Subject:Cc:To:From:Date; bh=PJHhQ3H+JmhApB2mrrcegAdSDYOEPR9jp4epF8Fwyrc=; b=seTSi5vVo+NK7DKlhNRn8QjLXP tGVfx5K2TFBzWihR5wYvLU7RyWmYgrvvhChcXiKog3Ds9FmZtxLc9yJ+iupP/WW6lxzl/s+LUBF9M SXvsD0ry8Uf2SmfZDlEo0kjDnDrCgqt8F706QPYBQvTBPTXkQgIZazRWtDFtuvqnDbB4=; Date: Thu, 4 Sep 2025 15:50:38 +0200 From: Anthony PERARD To: dmukhin@xen.org Cc: xen-devel@lists.xenproject.org, andrew.cooper3@citrix.com, anthony.perard@vates.tech, jbeulich@suse.com, julien@xen.org, michal.orzel@amd.com, roger.pau@citrix.com, sstabellini@kernel.org, dmukhin@ford.com Subject: Re: [PATCH v17 3/4] tools/tests: introduce unit tests for domain ID allocator Message-ID: References: <20250829232132.3460081-1-dmukhin@ford.com> <20250829232132.3460081-4-dmukhin@ford.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20250829232132.3460081-4-dmukhin@ford.com> On Fri, Aug 29, 2025 at 04:21:31PM -0700, dmukhin@xen.org wrote: > diff --git a/tools/tests/domid/Makefile b/tools/tests/domid/Makefile > new file mode 100644 > index 000000000000..22f1f15d11db > --- /dev/null > +++ b/tools/tests/domid/Makefile > +# NB: $1 cannot be a list Why not? It would be the same as writing the rule multiple time for different targets. Is about my comment on "prerequisite" on v16? In this rule, "harness.h" is a prerequisite. > +define emit-harness-nested-rule > +$(1): $(CURDIR)/harness.h > + mkdir -p $$(@D); > + ln -sf $$< $$@; > + > +endef > diff --git a/tools/tests/domid/test-domid.c b/tools/tests/domid/test-domid.c > new file mode 100644 > index 000000000000..5915c4699a5c > --- /dev/null > +++ b/tools/tests/domid/test-domid.c > + > +#include > + > +#include "harness.h" > + > +#define verify(exp, fmt, args...) \ > +while (!(exp)) { \ > + printf(fmt, ## args); \ > + exit(EX_SOFTWARE); \ We never used any of "EX_*" macro, or even . I'm not sure it's a good idea to introduce such use where exit(1) would have been more than enough but sysexits.h seems to be available on BSD so it's probably fine. It would be nice to change that to exit(1) and remove sysexits.h. Anyway, patch looks good enough so: Reviewed-by: Anthony PERARD Thanks, -- Anthony PERARD