From: Andrew Cooper <andrew.cooper3@citrix.com>
To: Ian Campbell <ian.campbell@citrix.com>
Cc: Ian Jackson <Ian.Jackson@eu.citrix.com>,
Xen-devel <xen-devel@lists.xen.org>
Subject: Re: [PATCH] tools/libxc: Introduce typesafe and side-effect safe min()/max() macros
Date: Thu, 10 Jul 2014 10:41:13 +0100 [thread overview]
Message-ID: <53BE5FB9.9060502@citrix.com> (raw)
In-Reply-To: <1404984956.32404.2.camel@hastur.hellion.org.uk>
On 10/07/14 10:35, Ian Campbell wrote:
> On Wed, 2014-07-09 at 16:54 +0100, Ian Campbell wrote:
>> On Tue, 2014-07-08 at 14:21 +0100, Andrew Cooper wrote:
>>> Replace the current users, and remove scattered re-definitions.
>>>
>>> Signed-off-by: Andrew Cooper <andrew.cooper3@citrix.com>
>> Acked-by: Ian Campbell <Ian.Campbell@citrix.com>
>>
>>> - unsigned long sz = MIN(chunk_bytes, sizeof(xen_pfn_t));
>>> + unsigned long sz = min((size_t)chunk_bytes, sizeof(xen_pfn_t));
>> FWIW on the hyperevisor side we have max_t and min_t to handle these
>> cases where a cast is needed.
> Which I've just noticed/remembered I promoted to xc_private.h in my ARM
> p2m superpages series!
I noticed that. I guess it depends which patch gets committed first.
This patch is a prerequisite of the writev() patch, which is a
prerequisite for my migration v2.
If you wish, I can do a v2 which moves min_t/max_t at the same time and
uses them in preference.
~Andrew
next prev parent reply other threads:[~2014-07-10 9:41 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2014-07-08 13:21 [PATCH] tools/libxc: Introduce typesafe and side-effect safe min()/max() macros Andrew Cooper
2014-07-09 15:54 ` Ian Campbell
2014-07-10 9:35 ` Ian Campbell
2014-07-10 9:41 ` Andrew Cooper [this message]
2014-07-10 10:34 ` Ian Campbell
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=53BE5FB9.9060502@citrix.com \
--to=andrew.cooper3@citrix.com \
--cc=Ian.Jackson@eu.citrix.com \
--cc=ian.campbell@citrix.com \
--cc=xen-devel@lists.xen.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.