Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/dev/wsfb Provide a wsdisplay_accessops.pollc
details: https://anonhg.NetBSD.org/src/rev/9163ebad2358
branches: trunk
changeset: 326234:9163ebad2358
user: skrll <skrll%NetBSD.org@localhost>
date: Wed Jan 22 18:47:11 2014 +0000
description:
Provide a wsdisplay_accessops.pollc
This makes sure that the screen gets painted properly during early boot
input (e.g. boot -a) on the Raspberry PI.
diffstat:
sys/dev/wsfb/genfb.c | 22 ++++++++++++++++++++--
1 files changed, 20 insertions(+), 2 deletions(-)
diffs (57 lines):
diff -r d3b6ae76cda9 -r 9163ebad2358 sys/dev/wsfb/genfb.c
--- a/sys/dev/wsfb/genfb.c Wed Jan 22 18:47:03 2014 +0000
+++ b/sys/dev/wsfb/genfb.c Wed Jan 22 18:47:11 2014 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: genfb.c,v 1.51 2013/10/09 17:20:54 macallan Exp $ */
+/* $NetBSD: genfb.c,v 1.52 2014/01/22 18:47:11 skrll Exp $ */
/*-
* Copyright (c) 2007 Michael Lorenz
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: genfb.c,v 1.51 2013/10/09 17:20:54 macallan Exp $");
+__KERNEL_RCSID(0, "$NetBSD: genfb.c,v 1.52 2014/01/22 18:47:11 skrll Exp $");
#include <sys/param.h>
#include <sys/systm.h>
@@ -68,6 +68,8 @@
static int genfb_ioctl(void *, void *, u_long, void *, int, struct lwp *);
static paddr_t genfb_mmap(void *, void *, off_t, int);
+static void genfb_pollc(void *, int);
+
static void genfb_init_screen(void *, struct vcons_screen *, int, long *);
static int genfb_putcmap(struct genfb_softc *, struct wsdisplay_cmap *);
@@ -234,6 +236,7 @@
sc->sc_accessops.ioctl = genfb_ioctl;
sc->sc_accessops.mmap = genfb_mmap;
+ sc->sc_accessops.pollc = genfb_pollc;
#ifdef GENFB_SHADOWFB
sc->sc_shadowfb = kmem_alloc(sc->sc_fbsize, KM_SLEEP);
@@ -485,6 +488,21 @@
}
static void
+genfb_pollc(void *v, int on)
+{
+ struct vcons_data *vd = v;
+ struct genfb_softc *sc = vd->cookie;
+
+ if (sc == NULL)
+ return;
+
+ if (on)
+ genfb_enable_polling(sc->sc_dev);
+ else
+ genfb_disable_polling(sc->sc_dev);
+}
+
+static void
genfb_init_screen(void *cookie, struct vcons_screen *scr,
int existing, long *defattr)
{
Home |
Main Index |
Thread Index |
Old Index