git: ae2013c2e4d0 - stable/15 - linuxkpi: Add <linux/font.h>
- Go to: [ bottom of page ] [ top of archives ] [ this month ]
Date: Wed, 22 Apr 2026 21:08:15 UTC
The branch stable/15 has been updated by bz:
URL: https://cgit.FreeBSD.org/src/commit/?id=ae2013c2e4d075988c93d55f3f2f4c31556aea87
commit ae2013c2e4d075988c93d55f3f2f4c31556aea87
Author: Jean-Sébastien Pédron <dumbbell@FreeBSD.org>
AuthorDate: 2025-08-12 22:00:10 +0000
Commit: Bjoern A. Zeeb <bz@FreeBSD.org>
CommitDate: 2026-04-22 20:56:56 +0000
linuxkpi: Add <linux/font.h>
The header defines the minimum to allow the DRM generic code to build.
The only function used so far is `get_default_font()`, as part of a
DRM-specific panic handler. We do not use this panic handler on FreeBSD.
For now, it returns a NULL value. It should probably map to a vt(4)
font.
The DRM generic code started to use it in Linux 6.10 as part of the
panic handler.
Reviewed by: bz, christos
Sponsored by: The FreeBSD Foundation
Differential Revision: https://reviews.freebsd.org/D54491
(cherry picked from commit 514d37fa268b8b181e3632d7f138bd09aa15683c)
---
sys/compat/linuxkpi/common/include/linux/font.h | 33 +++++++++++++++++++++++++
1 file changed, 33 insertions(+)
diff --git a/sys/compat/linuxkpi/common/include/linux/font.h b/sys/compat/linuxkpi/common/include/linux/font.h
new file mode 100644
index 000000000000..45daa00b61f0
--- /dev/null
+++ b/sys/compat/linuxkpi/common/include/linux/font.h
@@ -0,0 +1,33 @@
+/*
+ * SPDX-License-Identifier: BSD-2-Clause
+ *
+ * Copyright (c) 2025-2026 The FreeBSD Foundation
+ * Copyright (c) 2025-2026 Jean-Sébastien Pédron <dumbbell@FreeBSD.org>
+ *
+ * This software was developed by Jean-Sébastien Pédron under sponsorship
+ * from the FreeBSD Foundation.
+ */
+
+#ifndef _LINUXKPI_LINUX_FONT_H_
+#define _LINUXKPI_LINUX_FONT_H_
+
+#include <linux/types.h>
+
+struct font_desc {
+ const char *name;
+ const void *data;
+ int idx;
+ unsigned int width;
+ unsigned int height;
+ unsigned int charcount;
+ int pref;
+};
+
+static inline const struct font_desc *
+get_default_font(int xres, int yres, unsigned long *font_w,
+ unsigned long *font_h)
+{
+ return (NULL);
+}
+
+#endif