All of lore.kernel.org
 help / color / mirror / Atom feed
From: Juergen Gross <jgross@suse.com>
To: Jan Beulich <jbeulich@suse.com>
Cc: "Andrew Cooper" <andrew.cooper3@citrix.com>,
	"Roger Pau Monné" <roger.pau@citrix.com>, "Wei Liu" <wl@xen.org>,
	"Anthony PERARD" <anthony.perard@citrix.com>,
	xen-devel@lists.xenproject.org
Subject: Re: [PATCH v4 2/5] tools: get rid of additional min() and max() definitions
Date: Wed, 22 Mar 2023 14:10:01 +0100	[thread overview]
Message-ID: <164268c2-5392-4a91-5ac7-969ca9f62b6f@suse.com> (raw)
In-Reply-To: <cd1b5f73-aa57-938d-8453-9c2e7b0895cd@suse.com>


[-- Attachment #1.1.1: Type: text/plain, Size: 1411 bytes --]

On 22.03.23 13:38, Jan Beulich wrote:
> On 22.03.2023 13:08, Juergen Gross wrote:
>> --- a/tools/tests/vpci/emul.h
>> +++ b/tools/tests/vpci/emul.h
>> @@ -106,22 +106,6 @@ typedef union {
>>   #define BUG() assert(0)
>>   #define ASSERT_UNREACHABLE() assert(0)
>>   
>> -#define min(x, y) ({                    \
>> -        const typeof(x) tx = (x);       \
>> -        const typeof(y) ty = (y);       \
>> -                                        \
>> -        (void) (&tx == &ty);            \
>> -        tx < ty ? tx : ty;              \
>> -})
>> -
>> -#define max(x, y) ({                    \
>> -        const typeof(x) tx = (x);       \
>> -        const typeof(y) ty = (y);       \
>> -                                        \
>> -        (void) (&tx == &ty);            \
>> -        tx > ty ? tx : ty;              \
>> -})
> 
> The new include is added to this file by the first patch. How do things
> build warning-free before these macros (functionally compatible but
> different in the specific tokens used) are removed, i.e. before this
> patch is (also) applied?

Oh, I seem to have failed to make a test build of the tools/tests directory
after applying only the first patch.

It would be probably be the best to switch patches 1 and 2 while keeping the
"#include <xen-tools/common-macros.h>" in tools/tests/vpci/emul.h in the first
patch.


Juergen


[-- Attachment #1.1.2: OpenPGP public key --]
[-- Type: application/pgp-keys, Size: 3149 bytes --]

[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 495 bytes --]

  reply	other threads:[~2023-03-22 13:10 UTC|newest]

Thread overview: 12+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-03-22 12:08 [PATCH v4 0/5] tools: use xen-tools/libs.h for common definitions Juergen Gross
2023-03-22 12:08 ` [PATCH v4 1/5] tools: add container_of() macro to xen-tools/common-macros.h Juergen Gross
2023-03-22 12:34   ` Jan Beulich
2023-03-22 12:44     ` Juergen Gross
2023-03-22 12:08 ` [PATCH v4 2/5] tools: get rid of additional min() and max() definitions Juergen Gross
2023-03-22 12:38   ` Jan Beulich
2023-03-22 13:10     ` Juergen Gross [this message]
2023-03-22 12:08 ` [PATCH v4 3/5] tools/hvmloader: remove private offsetof() definition Juergen Gross
2023-03-22 12:42   ` Jan Beulich
2023-03-22 12:47     ` Juergen Gross
2023-03-22 12:08 ` [PATCH v4 4/5] tools/libfsimage: " Juergen Gross
2023-03-22 12:08 ` [PATCH v4 5/5] tools/libs/vchan: " Juergen Gross

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=164268c2-5392-4a91-5ac7-969ca9f62b6f@suse.com \
    --to=jgross@suse.com \
    --cc=andrew.cooper3@citrix.com \
    --cc=anthony.perard@citrix.com \
    --cc=jbeulich@suse.com \
    --cc=roger.pau@citrix.com \
    --cc=wl@xen.org \
    --cc=xen-devel@lists.xenproject.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.