Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/arm/allwinner make the full amount of reserved vide...
details: https://anonhg.NetBSD.org/src/rev/804b2f7c8e29
branches: trunk
changeset: 334671:804b2f7c8e29
user: jmcneill <jmcneill%NetBSD.org@localhost>
date: Sun Nov 30 20:25:54 2014 +0000
description:
make the full amount of reserved video memory available to userland
diffstat:
sys/arch/arm/allwinner/awin_fb.c | 10 ++++++----
1 files changed, 6 insertions(+), 4 deletions(-)
diffs (39 lines):
diff -r 567a97b65d8a -r 804b2f7c8e29 sys/arch/arm/allwinner/awin_fb.c
--- a/sys/arch/arm/allwinner/awin_fb.c Sun Nov 30 20:04:57 2014 +0000
+++ b/sys/arch/arm/allwinner/awin_fb.c Sun Nov 30 20:25:54 2014 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: awin_fb.c,v 1.7 2014/11/30 19:15:53 jmcneill Exp $ */
+/* $NetBSD: awin_fb.c,v 1.8 2014/11/30 20:25:54 jmcneill Exp $ */
/*-
* Copyright (c) 2014 Jared D. McNeill <jmcneill%invisible.ca@localhost>
@@ -27,7 +27,7 @@
*/
#include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: awin_fb.c,v 1.7 2014/11/30 19:15:53 jmcneill Exp $");
+__KERNEL_RCSID(0, "$NetBSD: awin_fb.c,v 1.8 2014/11/30 20:25:54 jmcneill Exp $");
#include <sys/param.h>
#include <sys/bus.h>
@@ -143,8 +143,10 @@
fbi = data;
ri = &sc->sc_gen.vd.active->scr_ri;
error = wsdisplayio_get_fbinfo(ri, fbi);
- if (error == 0)
+ if (error == 0) {
fbi->fbi_flags |= WSFB_VRAM_IS_RAM;
+ fbi->fbi_fbsize = sc->sc_dmasegs[0].ds_len;
+ }
return error;
case WSDISPLAYIO_SVIDEO:
case WSDISPLAYIO_GVIDEO:
@@ -163,7 +165,7 @@
{
struct awin_fb_softc *sc = v;
- if (off < 0 || off >= sc->sc_gen.sc_fbsize)
+ if (off < 0 || off >= sc->sc_dmasegs[0].ds_len)
return -1;
return bus_dmamem_mmap(sc->sc_dmat, sc->sc_dmasegs, sc->sc_ndmasegs,
Home |
Main Index |
Thread Index |
Old Index