summaryrefslogtreecommitdiff
path: root/include/linux/xarray.h
diff options
context:
space:
mode:
authorDmitry Torokhov <dmitry.torokhov@gmail.com>2022-05-28 02:40:01 +0300
committerDmitry Torokhov <dmitry.torokhov@gmail.com>2022-05-28 02:40:01 +0300
commit690e179059e7e89040d1cd564e39761567a8d5dc (patch)
treeb6a64fc5ca4fd862e17559c46676258ae17c87d5 /include/linux/xarray.h
parent5f76955ab1e43e5795a9631b22ca4f918a0ae986 (diff)
parent4b0986a3613c92f4ec1bdc7f60ec66fea135991f (diff)
downloadlinux-690e179059e7e89040d1cd564e39761567a8d5dc.tar.xz
Merge tag 'v5.18' into next
Sync up with mainline to get updates to OMAP4 keypad driver and other upstream goodies.
Diffstat (limited to 'include/linux/xarray.h')
-rw-r--r--include/linux/xarray.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/include/linux/xarray.h b/include/linux/xarray.h
index d6d5da6ed735..72feab5ea8d4 100644
--- a/include/linux/xarray.h
+++ b/include/linux/xarray.h
@@ -9,6 +9,7 @@
* See Documentation/core-api/xarray.rst for how to use the XArray.
*/
+#include <linux/bitmap.h>
#include <linux/bug.h>
#include <linux/compiler.h>
#include <linux/gfp.h>
@@ -1317,6 +1318,7 @@ struct xa_state {
struct xa_node *xa_node;
struct xa_node *xa_alloc;
xa_update_node_t xa_update;
+ struct list_lru *xa_lru;
};
/*
@@ -1336,7 +1338,8 @@ struct xa_state {
.xa_pad = 0, \
.xa_node = XAS_RESTART, \
.xa_alloc = NULL, \
- .xa_update = NULL \
+ .xa_update = NULL, \
+ .xa_lru = NULL, \
}
/**
@@ -1631,6 +1634,11 @@ static inline void xas_set_update(struct xa_state *xas, xa_update_node_t update)
xas->xa_update = update;
}
+static inline void xas_set_lru(struct xa_state *xas, struct list_lru *lru)
+{
+ xas->xa_lru = lru;
+}
+
/**
* xas_next_entry() - Advance iterator to next present entry.
* @xas: XArray operation state.