xen-devel
[Xen-devel] Re: [RFC PATCH 23/33] subarch TLB support
To: |
David Miller <davem@xxxxxxxxxxxxx> |
Subject: |
[Xen-devel] Re: [RFC PATCH 23/33] subarch TLB support |
From: |
Chris Wright <chrisw@xxxxxxxxxxxx> |
Date: |
Tue, 18 Jul 2006 14:00:58 -0700 |
Cc: |
akpm@xxxxxxxx, zach@xxxxxxxxxx, jeremy@xxxxxxxx, xen-devel@xxxxxxxxxxxxxxxxxxx, ian.pratt@xxxxxxxxxxxxx, rusty@xxxxxxxxxxxxxxx, linux-kernel@xxxxxxxxxxxxxxx, ak@xxxxxxx, chrisw@xxxxxxxxxxxx, virtualization@xxxxxxxxxxxxxx, Christian.Limpach@xxxxxxxxxxxx |
Delivery-date: |
Tue, 18 Jul 2006 14:01:05 -0700 |
Envelope-to: |
www-data@xxxxxxxxxxxxxxxxxx |
In-reply-to: |
<20060718.133924.71552173.davem@xxxxxxxxxxxxx> |
List-help: |
<mailto:xen-devel-request@lists.xensource.com?subject=help> |
List-id: |
Xen developer discussion <xen-devel.lists.xensource.com> |
List-post: |
<mailto:xen-devel@lists.xensource.com> |
List-subscribe: |
<http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=subscribe> |
List-unsubscribe: |
<http://lists.xensource.com/cgi-bin/mailman/listinfo/xen-devel>, <mailto:xen-devel-request@lists.xensource.com?subject=unsubscribe> |
References: |
<20060718091807.467468000@xxxxxxxxxxxx> <20060718091954.271792000@xxxxxxxxxxxx> <20060718.133924.71552173.davem@xxxxxxxxxxxxx> |
Sender: |
xen-devel-bounces@xxxxxxxxxxxxxxxxxxx |
User-agent: |
Mutt/1.4.2.1i |
* David Miller (davem@xxxxxxxxxxxxx) wrote:
> From: Chris Wright <chrisw@xxxxxxxxxxxx>
> Date: Tue, 18 Jul 2006 00:00:23 -0700
>
> > + BUG_ON(HYPERVISOR_mmuext_op(&op, 1, NULL, DOMID_SELF) < 0);
>
> Although it happens to work currently, I think we should get out of
> the habit of putting operations with wanted side effects into BUG_ON()
> calls. The following is therefore more preferable:
>
> ret = HYPERVISOR_mmuext_op(&op, 1, NULL, DOMID_SELF);
> BUG_ON(ret < 0);
>
> If this were ASSERT() in userspace, turning off debugging at build
> time would make the evaluations inside of the macro never occur. It
> is my opinion that BUG_ON() should behave similarly.
Good point, I'll clean those up.
thanks,
-chris
_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel
|
|
|