[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20060718.133924.71552173.davem@davemloft.net>
Date: Tue, 18 Jul 2006 13:39:24 -0700 (PDT)
From: David Miller <davem@...emloft.net>
To: chrisw@...s-sol.org
Cc: linux-kernel@...r.kernel.org, virtualization@...ts.osdl.org,
xen-devel@...ts.xensource.com, jeremy@...p.org, ak@...e.de,
akpm@...l.org, rusty@...tcorp.com.au, zach@...are.com,
ian.pratt@...source.com, Christian.Limpach@...cam.ac.uk
Subject: Re: [RFC PATCH 23/33] subarch TLB support
From: Chris Wright <chrisw@...s-sol.org>
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.
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@...r.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/
Powered by blists - more mailing lists