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 list_for_each_entry_fr...
details: https://anonhg.NetBSD.org/src/rev/9494a34b33c4
branches: trunk
changeset: 1028380:9494a34b33c4
user: riastradh <riastradh%NetBSD.org@localhost>
date: Sun Dec 19 10:51:09 2021 +0000
description:
list_for_each_entry_from_reverse
diffstat:
sys/external/bsd/common/include/linux/list.h | 7 ++++++-
1 files changed, 6 insertions(+), 1 deletions(-)
diffs (21 lines):
diff -r 73f4214ed6cc -r 9494a34b33c4 sys/external/bsd/common/include/linux/list.h
--- a/sys/external/bsd/common/include/linux/list.h Sun Dec 19 10:51:01 2021 +0000
+++ b/sys/external/bsd/common/include/linux/list.h Sun Dec 19 10:51:09 2021 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: list.h,v 1.26 2021/12/19 10:39:35 riastradh Exp $ */
+/* $NetBSD: list.h,v 1.27 2021/12/19 10:51:09 riastradh Exp $ */
/*-
* Copyright (c) 2013 The NetBSD Foundation, Inc.
@@ -307,6 +307,11 @@
(&(VAR)->FIELD != (HEAD)); \
(VAR) = list_next_entry((VAR), FIELD))
+#define list_for_each_entry_from_reverse(VAR, HEAD, FIELD) \
+ for (; \
+ (&(VAR)->FIELD != (HEAD)); \
+ (VAR) = list_prev_entry((VAR), FIELD))
+
#define list_for_each_entry_safe_from(VAR, NEXT, HEAD, FIELD) \
for (; \
(&(VAR)->FIELD != (HEAD)) && \
Home |
Main Index |
Thread Index |
Old Index