Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/rump/librump/rumpdev define the incredible FLAWLESSCALL ...



details:   https://anonhg.NetBSD.org/src/rev/f58fceae49f1
branches:  trunk
changeset: 753392:f58fceae49f1
user:      pooka <pooka%NetBSD.org@localhost>
date:      Thu Mar 25 19:54:19 2010 +0000

description:
define the incredible FLAWLESSCALL macro in one place

diffstat:

 sys/rump/librump/rumpdev/rump_dev_private.h |  9 ++++++++-
 1 files changed, 8 insertions(+), 1 deletions(-)

diffs (21 lines):

diff -r cca72b2a9467 -r f58fceae49f1 sys/rump/librump/rumpdev/rump_dev_private.h
--- a/sys/rump/librump/rumpdev/rump_dev_private.h       Thu Mar 25 19:54:08 2010 +0000
+++ b/sys/rump/librump/rumpdev/rump_dev_private.h       Thu Mar 25 19:54:19 2010 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: rump_dev_private.h,v 1.10 2010/03/01 13:12:20 pooka Exp $      */
+/*     $NetBSD: rump_dev_private.h,v 1.11 2010/03/25 19:54:19 pooka Exp $      */
 
 /*
  * Copyright (c) 2009 Antti Kantee.  All Rights Reserved.
@@ -39,4 +39,11 @@
        int maa_unit;
 };
 
+#define FLAWLESSCALL(call)                                             \
+do {                                                                   \
+       int att_error;                                                  \
+       if ((att_error = call) != 0)                                    \
+               panic("\"%s\" failed", #call);                          \
+} while (/*CONSTCOND*/0)
+
 #endif /* _SYS_RUMP_DEV_PRIVATE_H_ */



Home | Main Index | Thread Index | Old Index