summaryrefslogtreecommitdiffstats
path: root/sys/arch/sgi/dev/impact.c
diff options
context:
space:
mode:
authormiod <miod@openbsd.org>2013-10-21 10:36:09 +0000
committermiod <miod@openbsd.org>2013-10-21 10:36:09 +0000
commit8327574203d035ec92ee82b60a49304b5668bca1 (patch)
treef0b777af1236443d3ceecbf74cf03fd3dbc77b9a /sys/arch/sgi/dev/impact.c
parent- trivial and/or obvious bug fix (diff)
downloadwireguard-openbsd-8327574203d035ec92ee82b60a49304b5668bca1.tar.xz
wireguard-openbsd-8327574203d035ec92ee82b60a49304b5668bca1.zip
Add load_font and list_font accessops to all rasops-based wsdisplay drivers.
Trivial except for tga(4) and gpx(4/vax) which need a bit more care setting up a new font.
Diffstat (limited to 'sys/arch/sgi/dev/impact.c')
-rw-r--r--sys/arch/sgi/dev/impact.c26
1 files changed, 24 insertions, 2 deletions
diff --git a/sys/arch/sgi/dev/impact.c b/sys/arch/sgi/dev/impact.c
index 748f117880a..58b0ffb73bf 100644
--- a/sys/arch/sgi/dev/impact.c
+++ b/sys/arch/sgi/dev/impact.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: impact.c,v 1.4 2013/10/20 20:07:24 miod Exp $ */
+/* $OpenBSD: impact.c,v 1.5 2013/10/21 10:36:16 miod Exp $ */
/*
* Copyright (c) 2010, 2012 Miodrag Vallat.
@@ -118,6 +118,8 @@ int impact_alloc_screen(void *, const struct wsscreen_descr *, void **,
void impact_free_screen(void *, void *);
int impact_show_screen(void *, void *, int, void (*)(void *, int, int),
void *);
+int impact_load_font(void *, void *, struct wsdisplay_font *);
+int impact_list_font(void *, struct wsdisplay_font *);
static struct impact_screen impact_cons;
@@ -126,7 +128,9 @@ struct wsdisplay_accessops impact_accessops = {
.mmap = impact_mmap,
.alloc_screen = impact_alloc_screen,
.free_screen = impact_free_screen,
- .show_screen = impact_show_screen
+ .show_screen = impact_show_screen,
+ .load_font = impact_load_font,
+ .list_font = impact_list_font
};
int
@@ -466,6 +470,24 @@ impact_show_screen(void *v, void *cookie, int waitok,
return 0;
}
+int
+impact_load_font(void *v, void *emulcookie, struct wsdisplay_font *font)
+{
+ struct impact_screen *scr = (struct impact_screen *)v;
+ struct rasops_info *ri = &scr->ri;
+
+ return rasops_load_font(ri, emulcookie, font);
+}
+
+int
+impact_list_font(void *v, struct wsdisplay_font *font)
+{
+ struct impact_screen *scr = (struct impact_screen *)v;
+ struct rasops_info *ri = &scr->ri;
+
+ return rasops_list_font(ri, font);
+}
+
/*
* Hardware accelerated functions.
*/