Source-Changes-HG archive

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

[src/trunk]: src/sys/external/bsd/common/include/linux Define min3/max3. XXX...



details:   https://anonhg.NetBSD.org/src/rev/e7e6e1aa23d3
branches:  trunk
changeset: 992535:e7e6e1aa23d3
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Mon Aug 27 06:55:32 2018 +0000

description:
Define min3/max3.  XXX: Multiple evaluation.  Hope it's OK!

diffstat:

 sys/external/bsd/common/include/linux/kernel.h |  5 ++++-
 1 files changed, 4 insertions(+), 1 deletions(-)

diffs (19 lines):

diff -r 4ed19082ef36 -r e7e6e1aa23d3 sys/external/bsd/common/include/linux/kernel.h
--- a/sys/external/bsd/common/include/linux/kernel.h    Mon Aug 27 06:55:23 2018 +0000
+++ b/sys/external/bsd/common/include/linux/kernel.h    Mon Aug 27 06:55:32 2018 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: kernel.h,v 1.15 2018/08/27 06:53:55 riastradh Exp $    */
+/*     $NetBSD: kernel.h,v 1.16 2018/08/27 06:55:32 riastradh Exp $    */
 
 /*-
  * Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -76,6 +76,9 @@
 #define        clamp_t(T, X, MIN, MAX) min_t(T, max_t(T, X, MIN), MAX)
 #define        clamp(X, MN, MX)        MIN(MAX(X, MN), MX)
 
+#define        min3(X, Y, Z)   MIN(X, MIN(Y, Z))
+#define        max3(X, Y, Z)   MAX(X, MAX(Y, Z))
+
 /*
  * Rounding to nearest.
  */



Home | Main Index | Thread Index | Old Index