diff options
author | Miod Vallat <miod@cvs.openbsd.org> | 2013-10-21 10:36:27 +0000 |
---|---|---|
committer | Miod Vallat <miod@cvs.openbsd.org> | 2013-10-21 10:36:27 +0000 |
commit | 22a7a58bc34bd99e322e4e872add0cd82855128a (patch) | |
tree | 3571a1fe1f892c698c714629e9ccd90e1fc13156 /sys/arch/sgi/gio | |
parent | ceead45789cad670a4e79b8e53502af204c5f1ad (diff) |
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/gio')
-rw-r--r-- | sys/arch/sgi/gio/grtwo.c | 24 | ||||
-rw-r--r-- | sys/arch/sgi/gio/newport.c | 26 |
2 files changed, 47 insertions, 3 deletions
diff --git a/sys/arch/sgi/gio/grtwo.c b/sys/arch/sgi/gio/grtwo.c index 34c890d1abb..74f59754099 100644 --- a/sys/arch/sgi/gio/grtwo.c +++ b/sys/arch/sgi/gio/grtwo.c @@ -1,4 +1,4 @@ -/* $OpenBSD: grtwo.c,v 1.6 2013/06/11 18:15:55 deraadt Exp $ */ +/* $OpenBSD: grtwo.c,v 1.7 2013/10/21 10:36:17 miod Exp $ */ /* $NetBSD: grtwo.c,v 1.11 2009/11/22 19:09:15 mbalmer Exp $ */ /* @@ -132,6 +132,8 @@ int grtwo_alloc_screen(void *, const struct wsscreen_descr *, void **, void grtwo_free_screen(void *, void *); int grtwo_show_screen(void *, void *, int, void (*)(void *, int, int), void *); +int grtwo_load_font(void *, void *, struct wsdisplay_font *); +int grtwo_list_font(void *, struct wsdisplay_font *); static struct wsdisplay_accessops grtwo_accessops = { .ioctl = grtwo_ioctl, @@ -139,6 +141,8 @@ static struct wsdisplay_accessops grtwo_accessops = { .alloc_screen = grtwo_alloc_screen, .free_screen = grtwo_free_screen, .show_screen = grtwo_show_screen, + .load_font = grtwo_load_font, + .list_font = grtwo_list_font }; int grtwo_cursor(void *, int, int, int); @@ -848,3 +852,21 @@ grtwo_mmap(void *v, off_t offset, int prot) { return -1; } + +int +grtwo_load_font(void *v, void *emulcookie, struct wsdisplay_font *font) +{ + struct grtwo_devconfig *dc = v; + struct rasops_info *ri = &dc->dc_ri; + + return rasops_load_font(ri, emulcookie, font); +} + +int +grtwo_list_font(void *v, struct wsdisplay_font *font) +{ + struct grtwo_devconfig *dc = v; + struct rasops_info *ri = &dc->dc_ri; + + return rasops_list_font(ri, font); +} diff --git a/sys/arch/sgi/gio/newport.c b/sys/arch/sgi/gio/newport.c index 74d038bf191..ec39ce09223 100644 --- a/sys/arch/sgi/gio/newport.c +++ b/sys/arch/sgi/gio/newport.c @@ -1,4 +1,4 @@ -/* $OpenBSD: newport.c,v 1.7 2013/10/20 20:07:24 miod Exp $ */ +/* $OpenBSD: newport.c,v 1.8 2013/10/21 10:36:17 miod Exp $ */ /* $NetBSD: newport.c,v 1.15 2009/05/12 23:51:25 macallan Exp $ */ /* @@ -117,13 +117,17 @@ int newport_alloc_screen(void *, const struct wsscreen_descr *, void **, void newport_free_screen(void *, void *); int newport_show_screen(void *, void *, int, void (*)(void *, int, int), void *); +int newport_load_font(void *, void *, struct wsdisplay_font *); +int newport_list_font(void *, struct wsdisplay_font *); struct wsdisplay_accessops newport_accessops = { .ioctl = newport_ioctl, .mmap = newport_mmap, .alloc_screen = newport_alloc_screen, .free_screen = newport_free_screen, - .show_screen = newport_show_screen + .show_screen = newport_show_screen, + .load_font = newport_load_font, + .list_font = newport_list_font }; int newport_do_cursor(struct rasops_info *); @@ -887,3 +891,21 @@ newport_mmap(void *v, off_t offset, int prot) { return -1; } + +int +newport_load_font(void *v, void *emulcookie, struct wsdisplay_font *font) +{ + struct newport_devconfig *dc = v; + struct rasops_info *ri = &dc->dc_ri; + + return rasops_load_font(ri, emulcookie, font); +} + +int +newport_list_font(void *v, struct wsdisplay_font *font) +{ + struct newport_devconfig *dc = v; + struct rasops_info *ri = &dc->dc_ri; + + return rasops_list_font(ri, font); +} |