Date: Mon, 05 Jan 2026 20:09:33 +0000 From: Jean-=?utf-8?Q?S=C3=A9bast?==?utf-8?Q?ien P=C3=A9?=dron <dumbbell@FreeBSD.org> To: src-committers@FreeBSD.org, dev-commits-src-all@FreeBSD.org, dev-commits-src-main@FreeBSD.org Subject: git: 4c89b333808a - main - linuxkpi: Add `radix_tree_deref_slot()` Message-ID: <695c1a7d.8013.62c10f5@gitrepo.freebsd.org>
index | next in thread | raw e-mail
The branch main has been updated by dumbbell: URL: https://cgit.FreeBSD.org/src/commit/?id=4c89b333808a7eae0dad595b13686e9cf60bd4e6 commit 4c89b333808a7eae0dad595b13686e9cf60bd4e6 Author: Jean-Sébastien Pédron <dumbbell@FreeBSD.org> AuthorDate: 2025-09-07 13:45:10 +0000 Commit: Jean-Sébastien Pédron <dumbbell@FreeBSD.org> CommitDate: 2026-01-05 19:32:50 +0000 linuxkpi: Add `radix_tree_deref_slot()` We don't do reference counting, we only dereference the pointer and retunr the value. The amdgpu DRM driver started to use it in Linux 6.10. Reviewed by: bz Sponsored by: The FreeBSD Foundation Differential Revision: https://reviews.freebsd.org/D54502 --- sys/compat/linuxkpi/common/include/linux/radix-tree.h | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/sys/compat/linuxkpi/common/include/linux/radix-tree.h b/sys/compat/linuxkpi/common/include/linux/radix-tree.h index 1019697303db..55f0fc949807 100644 --- a/sys/compat/linuxkpi/common/include/linux/radix-tree.h +++ b/sys/compat/linuxkpi/common/include/linux/radix-tree.h @@ -68,6 +68,12 @@ struct radix_tree_iter { for ((iter)->index = (start); \ radix_tree_iter_find(root, iter, &(slot)); (iter)->index++) +static inline void * +radix_tree_deref_slot(void **slot) +{ + return (*slot); +} + static inline int radix_tree_exception(void *arg) {home | help
Want to link to this message? Use this
URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?695c1a7d.8013.62c10f5>
