diff options
| author | Jean-Sébastien Pédron <dumbbell@FreeBSD.org> | 2026-04-11 15:18:06 +0000 |
|---|---|---|
| committer | Jean-Sébastien Pédron <dumbbell@FreeBSD.org> | 2026-04-22 18:09:53 +0000 |
| commit | 373871696d3da5f9fe1dcd23c83be95dbaa1b41d (patch) | |
| tree | f87b9adc3748e8205e13b00b2af1ba10bafb819a | |
| parent | 84fc57a369dfac882cb9e9333635aaa11978948f (diff) | |
linuxkpi: Define `fd_file()`
This macro simply returns the `file` field of the `struct fd`.
The DRM generic code and the amdgpu driver started to use it in
Linux 6.12.
Reviewed by: bz
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D56440
| -rw-r--r-- | sys/compat/linuxkpi/common/include/linux/file.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/sys/compat/linuxkpi/common/include/linux/file.h b/sys/compat/linuxkpi/common/include/linux/file.h index be12d5f1bccf..4d8f8fba7fab 100644 --- a/sys/compat/linuxkpi/common/include/linux/file.h +++ b/sys/compat/linuxkpi/common/include/linux/file.h @@ -184,6 +184,8 @@ static inline struct fd fdget(unsigned int fd) return (struct fd){f}; } +#define fd_file(fd) ((fd).linux_file) + #define file linux_file #define fget(...) linux_fget(__VA_ARGS__) |
