Added support ioctl(WSDISPLAYIO_LINEBYTES).
(XFree86 wsfb driver uses it.)
This commit is contained in:
parent
d69f0db1d1
commit
399c27c752
@ -1,4 +1,4 @@
|
||||
/* $NetBSD: pxa2x0_lcd.c,v 1.20 2007/06/28 14:37:36 nonaka Exp $ */
|
||||
/* $NetBSD: pxa2x0_lcd.c,v 1.21 2007/06/28 14:41:49 nonaka Exp $ */
|
||||
|
||||
/*
|
||||
* Copyright (c) 2002 Genetec Corporation. All rights reserved.
|
||||
@ -38,7 +38,7 @@
|
||||
*/
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
__KERNEL_RCSID(0, "$NetBSD: pxa2x0_lcd.c,v 1.20 2007/06/28 14:37:36 nonaka Exp $");
|
||||
__KERNEL_RCSID(0, "$NetBSD: pxa2x0_lcd.c,v 1.21 2007/06/28 14:41:49 nonaka Exp $");
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/systm.h>
|
||||
@ -818,6 +818,7 @@ pxa2x0_lcd_ioctl(void *v, void *vs, u_long cmd, void *data, int flag,
|
||||
struct lwp *l)
|
||||
{
|
||||
struct pxa2x0_lcd_softc *sc = v;
|
||||
struct pxa2x0_lcd_screen *scr = sc->active; /* ??? */
|
||||
struct wsdisplay_fbinfo *wsdisp_info;
|
||||
uint32_t ccr0;
|
||||
|
||||
@ -828,13 +829,16 @@ pxa2x0_lcd_ioctl(void *v, void *vs, u_long cmd, void *data, int flag,
|
||||
|
||||
case WSDISPLAYIO_GINFO:
|
||||
wsdisp_info = (struct wsdisplay_fbinfo *)data;
|
||||
|
||||
wsdisp_info->height = sc->geometry->panel_height;
|
||||
wsdisp_info->width = sc->geometry->panel_width;
|
||||
wsdisp_info->depth = sc->active->depth;
|
||||
wsdisp_info->depth = scr->depth;
|
||||
wsdisp_info->cmsize = 0;
|
||||
return 0;
|
||||
|
||||
case WSDISPLAYIO_LINEBYTES:
|
||||
*(u_int *)data = scr->rinfo.ri_stride;
|
||||
return 0;
|
||||
|
||||
case WSDISPLAYIO_GETCMAP:
|
||||
case WSDISPLAYIO_PUTCMAP:
|
||||
return EPASSTHROUGH; /* XXX Colormap */
|
||||
|
Loading…
Reference in New Issue
Block a user