hpc common files are moved to dev/hpc.

This commit is contained in:
uch 2001-02-22 18:37:54 +00:00
parent 114133a1f0
commit 659f65e0ee
41 changed files with 365 additions and 345 deletions

View File

@ -1,4 +1,4 @@
# $NetBSD: files.hpcmips,v 1.50 2001/02/21 16:34:00 uch Exp $
# $NetBSD: files.hpcmips,v 1.51 2001/02/22 18:37:57 uch Exp $
# maxpartitions must be first item in files.${ARCH}.
maxpartitions 8
@ -56,46 +56,19 @@ file arch/hpcmips/hpcmips/procfs_machdep.c procfs
# H/PC Platform common files.
#
include "arch/hpc/conf/files.hpc"
include "dev/hpc/files.bicons"
file arch/hpc/hpc/disksubr.c disk
include "dev/hpc/files.bicons"
include "dev/hpc/files.hpcfb"
include "dev/hpc/files.hpckbd"
include "dev/hpc/files.hpctp"
# Console autoconfiguration code: selects between a framebuffers
file dev/cons.c
# Raster operations
include "dev/rasops/files.rasops"
include "dev/wsfont/files.wsfont"
#
# Workstation Console
#
include "dev/wscons/files.wscons"
file dev/pckbc/wskbdmap_mfii.c btnmgr | hpckbd
file arch/hpcmips/dev/pckbd_encode.c btnmgr | hpckbd
defopt PCKBD_LAYOUT
# Simple framebuffer interface for wsdisplay
define hpcfbif {}
device hpcfb: wsemuldisplaydev, rasops1, rasops2, rasops4, rasops8, rasops15, rasops16
attach hpcfb at hpcfbif
file arch/hpcmips/dev/hpcfb.c hpcfb needs-flag
# Simple keyboard interface for wskbd
device hpckbdif {}
device hpckbd: wskbddev
attach hpckbd at hpckbdif
file arch/hpcmips/dev/hpckbd.c hpckbd
device bivideo: hpcfbif
file arch/hpcmips/dev/bivideo.c bivideo needs-flag
file arch/hpcmips/dev/hpccmap.c bivideo
attach bivideo at mainbus
device btnmgr: wskbddev
attach btnmgr at mainbus
file arch/hpcmips/dev/btnmgr.c btnmgr
file arch/hpcmips/dev/video_subr.c tx3912video | plumvideo
#
# power management
@ -169,10 +142,6 @@ device vrled
attach vrled at vrip
file arch/hpcmips/vr/vrled.c vrled needs-flag
define tpcalib
file arch/hpcmips/dev/tpcalib.c tpcalib
file arch/hpcmips/dev/mra.c tpcalib
device vrpiu: wsmousedev
attach vrpiu at vrip: tpcalib
file arch/hpcmips/vr/vrpiu.c vrpiu
@ -341,6 +310,8 @@ file arch/hpcmips/dev/plumohci.c plumohci needs-flag
#attach txisab at txcsbus
#file arch/hpcmips/isa/txisa_machdep.c txisab
file dev/hpc/video_subr.c tx3912video | plumvideo
#
# Real-time clock (not optional)
#

View File

@ -1,63 +0,0 @@
/* $NetBSD: hpckbdvar.h,v 1.1 2000/09/21 14:17:29 takemura Exp $ */
/*
* Copyright (c) 1999, by UCHIYAMA Yasushi
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. The name of the developer may NOT be used to endorse or promote products
* derived from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
*/
/*
* chip interface
*/
struct hpckbd_if;
struct hpckbd_ic_if {
void *hii_ctx;
int (*hii_establish) __P((void*, struct hpckbd_if *));
int (*hii_poll) __P((void*));
};
#define hpckbd_ic_establish(ic, kbdif) \
(*(ic)->hii_establish)((ic)->hii_ctx, (kbdif))
#define hpckbd_ic_poll(ic) \
(*(ic)->hii_poll)((ic)->hii_ctx)
/*
* hpckbd interface
*/
struct hpckbd_if {
void *hi_ctx;
void (*hi_input_hook) __P((void*));
int (*hi_input) __P((void*, int, int));
};
#define hpckbd_input_hook(i) \
(*(i)->hi_input_hook)((i)->hi_ctx)
#define hpckbd_input(i, f, a) \
(*(i)->hi_input)((i)->hi_ctx, (f), (a))
struct hpckbd_attach_args {
struct hpckbd_ic_if *haa_ic;
};
int hpckbd_print __P((void*, const char*));
int hpckbd_cnattach __P((struct hpckbd_ic_if*));

View File

@ -1,4 +1,4 @@
/* $NetBSD: ite8181.c,v 1.6 2001/02/15 09:17:18 sato Exp $ */
/* $NetBSD: ite8181.c,v 1.7 2001/02/22 18:38:00 uch Exp $ */
/*-
* Copyright (c) 2000 SATO Kazumi
@ -49,10 +49,9 @@
#include <hpcmips/dev/ite8181var.h>
#include "bivideo.h"
#if NBIVIDEO > 0
#include <hpcmips/dev/bivideovar.h>
#include <dev/hpc/bivideovar.h>
#endif
#include <hpcmips/dev/hpccmapvar.h>
#include <dev/hpc/hpccmapvar.h>
#define ITE8181DEBUG
#ifdef ITE8181DEBUG

View File

@ -1,4 +1,4 @@
/* $NetBSD: ite8181var.h,v 1.1 2000/10/02 03:57:54 sato Exp $ */
/* $NetBSD: ite8181var.h,v 1.2 2001/02/22 18:38:00 uch Exp $ */
/*-
* Copyright (c) 2000 SATO Kazumi
@ -33,8 +33,8 @@
#include <dev/wscons/wsdisplayvar.h>
#include <dev/rasops/rasops.h>
#include <arch/hpcmips/dev/hpcfbvar.h>
#include <arch/hpcmips/dev/hpcfbio.h>
#include <dev/hpc/hpcfbvar.h>
#include <dev/hpc/hpcfbio.h>
struct ite8181_softc {
struct device sc_dev;

View File

@ -1,29 +1,39 @@
/* $NetBSD: m38813c.c,v 1.3 2000/09/21 14:17:29 takemura Exp $ */
/* $NetBSD: m38813c.c,v 1.4 2001/02/22 18:38:00 uch Exp $ */
/*
* Copyright (c) 1999, 2000, by UCHIYAMA Yasushi
/*-
* Copyright (c) 1999, 2001 The NetBSD Foundation, Inc.
* All rights reserved.
*
* This code is derived from software contributed to The NetBSD Foundation
* by UCHIYAMA Yasushi.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. The name of the developer may NOT be used to endorse or promote products
* derived from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* 3. All advertising materials mentioning features or use of this software
* must display the following acknowledgement:
* This product includes software developed by the NetBSD
* Foundation, Inc. and its contributors.
* 4. Neither the name of The NetBSD Foundation nor the names of its
* contributors may be used to endorse or promote products derived
* from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
* ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
* TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
* BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/
/*
@ -40,11 +50,11 @@
#include <machine/bus.h>
#include <machine/intr.h>
#include <dev/hpc/hpckbdvar.h>
#include <hpcmips/tx/tx39var.h>
#include <hpcmips/tx/txcsbusvar.h>
#include <hpcmips/dev/m38813cvar.h>
#include <hpcmips/dev/hpckbdvar.h>
struct m38813c_chip {
bus_space_tag_t scc_cst;

View File

@ -1,4 +1,4 @@
/* $NetBSD: mq200.c,v 1.8 2001/02/15 09:17:18 sato Exp $ */
/* $NetBSD: mq200.c,v 1.9 2001/02/22 18:38:00 uch Exp $ */
/*-
* Copyright (c) 2000 Takemura Shin
@ -50,7 +50,7 @@
#include <hpcmips/dev/mq200var.h>
#include "bivideo.h"
#if NBIVIDEO > 0
#include <hpcmips/dev/bivideovar.h>
#include <dev/hpc/bivideovar.h>
#endif
#define MQ200DEBUG

View File

@ -1,4 +1,4 @@
/* $NetBSD: mq200var.h,v 1.1 2000/07/22 08:53:37 takemura Exp $ */
/* $NetBSD: mq200var.h,v 1.2 2001/02/22 18:38:00 uch Exp $ */
/*-
* Copyright (c) 2000 Takemura Shin
@ -35,8 +35,8 @@
#include <dev/wscons/wsdisplayvar.h>
#include <dev/rasops/rasops.h>
#include <arch/hpcmips/dev/hpcfbvar.h>
#include <arch/hpcmips/dev/hpcfbio.h>
#include <dev/hpc/hpcfbvar.h>
#include <dev/hpc/hpcfbio.h>
struct mq200_softc {
struct device sc_dev;

View File

@ -1,4 +1,4 @@
/* $NetBSD: plumvideo.c,v 1.16 2000/12/03 13:43:40 takemura Exp $ */
/* $NetBSD: plumvideo.c,v 1.17 2001/02/22 18:38:01 uch Exp $ */
/*-
* Copyright (c) 1999, 2000 The NetBSD Foundation, Inc.
@ -64,11 +64,11 @@
#include <dev/wscons/wsdisplayvar.h>
#include <dev/rasops/rasops.h>
#include <arch/hpcmips/dev/video_subr.h>
#include <dev/hpc/video_subr.h>
#include <dev/wscons/wsconsio.h>
#include <arch/hpcmips/dev/hpcfbvar.h>
#include <arch/hpcmips/dev/hpcfbio.h>
#include <dev/hpc/hpcfbvar.h>
#include <dev/hpc/hpcfbio.h>
#ifdef PLUMVIDEODEBUG
int plumvideo_debug = 1;

View File

@ -1,29 +1,39 @@
/* $NetBSD: tc5165buf.c,v 1.6 2000/09/21 14:17:29 takemura Exp $ */
/* $NetBSD: tc5165buf.c,v 1.7 2001/02/22 18:38:01 uch Exp $ */
/*
* Copyright (c) 1999, 2000, by UCHIYAMA Yasushi
/*-
* Copyright (c) 1999-2001 The NetBSD Foundation, Inc.
* All rights reserved.
*
* This code is derived from software contributed to The NetBSD Foundation
* by UCHIYAMA Yasushi.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. The name of the developer may NOT be used to endorse or promote products
* derived from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* 3. All advertising materials mentioning features or use of this software
* must display the following acknowledgement:
* This product includes software developed by the NetBSD
* Foundation, Inc. and its contributors.
* 4. Neither the name of The NetBSD Foundation nor the names of its
* contributors may be used to endorse or promote products derived
* from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
* ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
* TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
* BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/
/*
@ -42,11 +52,11 @@
#include <machine/bus.h>
#include <machine/intr.h>
#include <dev/hpc/hpckbdvar.h>
#include <hpcmips/tx/tx39var.h>
#include <hpcmips/tx/txcsbusvar.h>
#include <hpcmips/dev/tc5165bufvar.h>
#include <hpcmips/dev/hpckbdvar.h>
#define TC5165_ROW_MAX 16
#define TC5165_COLUMN_MAX 8

View File

@ -1,7 +1,11 @@
/* $NetBSD: ucbtp.c,v 1.4 2000/05/22 17:17:45 uch Exp $ */
/* $NetBSD: ucbtp.c,v 1.5 2001/02/22 18:38:02 uch Exp $ */
/*-
* Copyright (c) 2000 UCHIYAMA Yasushi. All rights reserved.
* Copyright (c) 2000, 2001 The NetBSD Foundation, Inc.
* All rights reserved.
*
* This code is derived from software contributed to The NetBSD Foundation
* by UCHIYAMA Yasushi.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@ -11,19 +15,25 @@
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* 3. The name of the author may not be used to endorse or promote products
* derived from this software without specific prior written permission.
* 3. All advertising materials mentioning features or use of this software
* must display the following acknowledgement:
* This product includes software developed by the NetBSD
* Foundation, Inc. and its contributors.
* 4. Neither the name of The NetBSD Foundation nor the names of its
* contributors may be used to endorse or promote products derived
* from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
* IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
* NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
* THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
* ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
* TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
* BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/
/*
@ -46,7 +56,7 @@
#include <dev/wscons/wsconsio.h>
#include <dev/wscons/wsmousevar.h>
#include <hpcmips/dev/tpcalibvar.h>
#include <dev/hpc/tpcalibvar.h>
#include <hpcmips/tx/tx39var.h>
#include <hpcmips/tx/tx39sibvar.h>
@ -57,7 +67,7 @@
#include <hpcmips/dev/ucb1200reg.h>
#include <hpcmips/tx/txsnd.h>
#include <hpcmips/dev/video_subr.h> /* debug */
#include <dev/hpc/video_subr.h> /* debug */
#ifdef UCBTPDEBUG
int ucbtp_debug = 0;

View File

@ -1,4 +1,4 @@
/* $NetBSD: tx3912video.c,v 1.21 2000/12/03 13:43:40 takemura Exp $ */
/* $NetBSD: tx3912video.c,v 1.22 2001/02/22 18:38:04 uch Exp $ */
/*-
* Copyright (c) 1999, 2000 The NetBSD Foundation, Inc.
@ -64,11 +64,11 @@
/* CLUT */
#include <dev/wscons/wsdisplayvar.h>
#include <dev/rasops/rasops.h>
#include <arch/hpcmips/dev/video_subr.h>
#include <dev/hpc/video_subr.h>
#include <dev/wscons/wsconsio.h>
#include <arch/hpcmips/dev/hpcfbvar.h>
#include <arch/hpcmips/dev/hpcfbio.h>
#include <dev/hpc/hpcfbvar.h>
#include <dev/hpc/hpcfbio.h>
#ifdef TX3912VIDEO_DEBUG
int tx3912video_debug = 1;

View File

@ -1,4 +1,4 @@
/* $NetBSD: ite8181_vrip.c,v 1.1 2000/10/02 04:14:59 sato Exp $ */
/* $NetBSD: ite8181_vrip.c,v 1.2 2001/02/22 18:38:04 uch Exp $ */
/*-
* Copyright (c) 2000 SATO Kazumi
@ -41,7 +41,7 @@
#include <hpcmips/dev/ite8181var.h>
#include "bivideo.h"
#if NBIVIDEO > 0
#include <hpcmips/dev/bivideovar.h>
#include <dev/hpc/bivideovar.h>
#endif
#include "locators.h"

View File

@ -1,4 +1,4 @@
/* $NetBSD: mq200_vrip.c,v 1.2 2000/10/02 04:15:51 sato Exp $ */
/* $NetBSD: mq200_vrip.c,v 1.3 2001/02/22 18:38:04 uch Exp $ */
/*-
* Copyright (c) 2000 Takemura Shin
@ -41,7 +41,7 @@
#include <hpcmips/dev/mq200var.h>
#include "bivideo.h"
#if NBIVIDEO > 0
#include <hpcmips/dev/bivideovar.h>
#include <dev/hpc/bivideovar.h>
#endif

View File

@ -1,4 +1,4 @@
/* $NetBSD: vr.c,v 1.19 2000/07/22 06:02:46 takemura Exp $ */
/* $NetBSD: vr.c,v 1.20 2001/02/22 18:38:04 uch Exp $ */
/*-
* Copyright (c) 1999
@ -95,7 +95,7 @@
#endif
#if NHPCFB > 0
#include <arch/hpcmips/dev/hpcfbvar.h>
#include <dev/hpc/hpcfbvar.h>
#endif
#if NVRKIU > 0

View File

@ -1,4 +1,4 @@
/* $NetBSD: vrkiu.c,v 1.25 2000/09/21 14:17:35 takemura Exp $ */
/* $NetBSD: vrkiu.c,v 1.26 2001/02/22 18:38:05 uch Exp $ */
/*-
* Copyright (c) 1999 SASAKI Takesi All rights reserved.
@ -54,7 +54,7 @@
#include <hpcmips/vr/vrkiuvar.h>
#include <hpcmips/vr/vrkiureg.h>
#include <hpcmips/vr/icureg.h>
#include <hpcmips/dev/hpckbdvar.h>
#include <dev/hpc/hpckbdvar.h>
#include "opt_wsdisplay_compat.h"
#include "opt_pckbd_layout.h"
@ -64,7 +64,7 @@
#include <dev/wscons/wsksymvar.h>
#include <dev/pckbc/wskbdmap_mfii.h>
#ifdef WSDISPLAY_COMPAT_RAWKBD
#include <hpcmips/dev/pckbd_encode.h>
#include <dev/hpc/pckbd_encode.h>
#endif
#define VRKIUDEBUG

View File

@ -1,4 +1,4 @@
/* $NetBSD: vrpiu.c,v 1.10 2001/01/21 05:00:28 takemura Exp $ */
/* $NetBSD: vrpiu.c,v 1.11 2001/02/22 18:38:05 uch Exp $ */
/*
* Copyright (c) 1999 Shin Takemura All rights reserved.
@ -47,9 +47,9 @@
#include <machine/platid_mask.h>
#include <machine/config_hook.h>
#include <hpcmips/hpcmips/machdep.h>
#include <hpcmips/dev/tpcalibvar.h>
#include <dev/hpc/tpcalibvar.h>
#include <hpcmips/hpcmips/machdep.h>
#include <hpcmips/vr/vripvar.h>
#include <hpcmips/vr/cmureg.h>
#include <hpcmips/vr/vrpiuvar.h>

View File

@ -1,4 +1,4 @@
/* $NetBSD: bivideo.c,v 1.17 2001/02/15 09:17:18 sato Exp $ */
/* $NetBSD: bivideo.c,v 1.1 2001/02/22 18:37:54 uch Exp $ */
/*-
* Copyright (c) 1999
@ -37,7 +37,7 @@
static const char _copyright[] __attribute__ ((unused)) =
"Copyright (c) 1999 Shin Takemura. All rights reserved.";
static const char _rcsid[] __attribute__ ((unused)) =
"$Id: bivideo.c,v 1.17 2001/02/15 09:17:18 sato Exp $";
"$Id: bivideo.c,v 1.1 2001/02/22 18:37:54 uch Exp $";
#include <sys/param.h>
#include <sys/systm.h>
@ -63,10 +63,10 @@ static const char _rcsid[] __attribute__ ((unused)) =
#include <dev/rasops/rasops.h>
#include <arch/hpcmips/dev/hpcfbvar.h>
#include <arch/hpcmips/dev/hpcfbio.h>
#include <arch/hpcmips/dev/bivideovar.h>
#include <arch/hpcmips/dev/hpccmapvar.h>
#include <dev/hpc/hpcfbvar.h>
#include <dev/hpc/hpcfbio.h>
#include <dev/hpc/bivideovar.h>
#include <dev/hpc/hpccmapvar.h>
#define VPRINTF(arg) do { if (bootverbose) printf arg; } while(0);

View File

@ -1,4 +1,4 @@
/* $NetBSD: bivideovar.h,v 1.2 2000/07/22 08:53:35 takemura Exp $ */
/* $NetBSD: bivideovar.h,v 1.1 2001/02/22 18:37:54 uch Exp $ */
/*
* Copyright (c) 2000 Takemura Shin

View File

@ -1,4 +1,4 @@
/* $NetBSD: btnmgr.c,v 1.11 2001/01/26 03:44:33 sato Exp $ */
/* $NetBSD: btnmgr.c,v 1.1 2001/02/22 18:37:54 uch Exp $ */
/*-
* Copyright (c) 1999
@ -48,7 +48,7 @@
#include <dev/wscons/wskbdvar.h>
#include <dev/wscons/wsksymdef.h>
#ifdef WSDISPLAY_COMPAT_RAWKBD
#include <hpcmips/dev/pckbd_encode.h>
#include <dev/hpc/pckbd_encode.h>
#endif
#include <machine/bus.h>

View File

@ -1,7 +1,8 @@
# $NetBSD: files.bicons,v 1.2 2001/02/12 17:55:09 uch Exp $
# $NetBSD: files.bicons,v 1.3 2001/02/22 18:37:54 uch Exp $
# H/PC builtin console
defpseudo biconsdev
file dev/hpc/biconsdev.c biconsdev needs-count
file dev/hpc/bicons.c biconsdev
file dev/hpc/bifont.c biconsdev

17
sys/dev/hpc/files.hpcfb Normal file
View File

@ -0,0 +1,17 @@
# $NetBSD: files.hpcfb,v 1.1 2001/02/22 18:37:54 uch Exp $
# H/PC framebuffer interface for wsdisplay
# Raster operations
include "dev/rasops/files.rasops"
include "dev/wsfont/files.wsfont"
define hpcfbif {}
device hpcfb: wsemuldisplaydev, rasops1, rasops2, rasops4, rasops8, rasops15, rasops16
attach hpcfb at hpcfbif
file dev/hpc/hpcfb.c hpcfb needs-flag
device bivideo: hpcfbif
attach bivideo at mainbus
file dev/hpc/bivideo.c bivideo needs-flag
file dev/hpc/hpccmap.c bivideo

16
sys/dev/hpc/files.hpckbd Normal file
View File

@ -0,0 +1,16 @@
# $NetBSD: files.hpckbd,v 1.1 2001/02/22 18:37:55 uch Exp $
# H/PC keyboard interface for wskbd
defopt PCKBD_LAYOUT
device hpckbdif {}
device hpckbd: wskbddev
attach hpckbd at hpckbdif
file dev/hpc/hpckbd.c hpckbd
device btnmgr: wskbddev
attach btnmgr at mainbus
file dev/hpc/btnmgr.c btnmgr
file dev/pckbc/wskbdmap_mfii.c btnmgr | hpckbd
file dev/hpc/pckbd_encode.c btnmgr | hpckbd

7
sys/dev/hpc/files.hpctp Normal file
View File

@ -0,0 +1,7 @@
# $NetBSD: files.hpctp,v 1.1 2001/02/22 18:37:55 uch Exp $
# H/PC touch panel interface.
define tpcalib
file dev/hpc/tpcalib.c tpcalib
file dev/hpc/mra.c tpcalib

View File

@ -1,4 +1,4 @@
/* $NetBSD: fontconv.c,v 1.2 2000/01/05 18:49:13 ad Exp $ */
/* $NetBSD: fontconv.c,v 1.1 2001/02/22 18:37:55 uch Exp $ */
#include <stdio.h>

View File

@ -1,4 +1,4 @@
/* $Id: hpccmap.c,v 1.1 2000/03/20 10:47:33 takemura Exp $ */
/* $Id: hpccmap.c,v 1.1 2001/02/22 18:37:55 uch Exp $ */
/*-
* Copyright (c) 1999
@ -37,7 +37,7 @@
* Do not edit.
* This file is automatically generated by hpccmap_gen.
*/
#include <arch/hpcmips/dev/hpccmapvar.h>
#include <dev/hpc/hpccmapvar.h>
unsigned char bivideo_cmap_r[256] = {
0,127, 0,127, 0,127, 0,199,127,255, 0,255, 0,255, 0,255,
0, 17, 34, 51, 68, 85,102,119,136,153,170,187,204,221,238,255,

View File

@ -1,4 +1,4 @@
/* $Id: hpccmap_gen.c,v 1.1 2000/03/20 10:47:33 takemura Exp $ */
/* $Id: hpccmap_gen.c,v 1.1 2001/02/22 18:37:55 uch Exp $ */
/*-
* Copyright (c) 1999
@ -56,7 +56,7 @@ main(ac, av)
printf(" * Do not edit.\n");
printf(" * This file is automatically generated by hpccmap_gen.\n");
printf(" */\n");
printf("#include <arch/hpcmips/dev/hpccmapar.h>\n");
printf("#include <dev/hpc/hpccmapar.h>\n");
for (i = 0; i < 3; i++) {
printf("unsigned char bivideo_cmap_%c[256] = {\n", rgb[i]);
cmap_gen(rgb_separate_out, (void*)i);

View File

@ -1,4 +1,4 @@
/* $Id: hpccmapvar.h,v 1.1 2000/03/20 10:47:33 takemura Exp $ */
/* $Id: hpccmapvar.h,v 1.1 2001/02/22 18:37:55 uch Exp $ */
/*-
* Copyright (c) 1999

View File

@ -1,4 +1,4 @@
/* $NetBSD: hpcfb.c,v 1.38 2001/02/02 08:31:04 sato Exp $ */
/* $NetBSD: hpcfb.c,v 1.1 2001/02/22 18:37:55 uch Exp $ */
/*-
* Copyright (c) 1999
@ -46,7 +46,7 @@
static const char _copyright[] __attribute__ ((unused)) =
"Copyright (c) 1999 Shin Takemura. All rights reserved.";
static const char _rcsid[] __attribute__ ((unused)) =
"$Id: hpcfb.c,v 1.38 2001/02/02 08:31:04 sato Exp $";
"$Id: hpcfb.c,v 1.1 2001/02/22 18:37:55 uch Exp $";
#include <sys/param.h>
#include <sys/systm.h>
@ -75,12 +75,12 @@ static const char _rcsid[] __attribute__ ((unused)) =
#include <dev/wsfont/wsfont.h>
#include <dev/rasops/rasops.h>
#include <arch/hpcmips/dev/hpcfbvar.h>
#include <arch/hpcmips/dev/hpcfbio.h>
#include <dev/hpc/hpcfbvar.h>
#include <dev/hpc/hpcfbio.h>
#include "bivideo.h"
#if NBIVIDEO > 0
#include <arch/hpcmips/dev/bivideovar.h>
#include <dev/hpc/bivideovar.h>
#endif
#ifdef FBDEBUG

View File

@ -1,4 +1,4 @@
/* $NetBSD: hpcfbio.h,v 1.2 2000/12/03 13:43:40 takemura Exp $ */
/* $NetBSD: hpcfbio.h,v 1.1 2001/02/22 18:37:55 uch Exp $ */
/*-
* Copyright (c) 1999

View File

@ -1,4 +1,4 @@
/* $NetBSD: hpcfbvar.h,v 1.6 2000/12/25 10:09:31 sato Exp $ */
/* $NetBSD: hpcfbvar.h,v 1.1 2001/02/22 18:37:55 uch Exp $ */
/*-
* Copyright (c) 1999

View File

@ -1,7 +1,11 @@
/* $NetBSD: hpckbd.c,v 1.5 2001/01/10 08:43:13 sato Exp $ */
/* $NetBSD: hpckbd.c,v 1.1 2001/02/22 18:37:55 uch Exp $ */
/*-
* Copyright (c) 1999, 2000 UCHIYAMA Yasushi. All rights reserved.
* Copyright (c) 1999-2001 The NetBSD Foundation, Inc.
* All rights reserved.
*
* This code is derived from software contributed to The NetBSD Foundation
* by UCHIYAMA Yasushi.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
@ -11,21 +15,26 @@
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* 3. The name of the author may not be used to endorse or promote products
* derived from this software without specific prior written permission.
* 3. All advertising materials mentioning features or use of this software
* must display the following acknowledgement:
* This product includes software developed by the NetBSD
* Foundation, Inc. and its contributors.
* 4. Neither the name of The NetBSD Foundation nor the names of its
* contributors may be used to endorse or promote products derived
* from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
* IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
* OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
* IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
* INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
* NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
* DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
* THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
* (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE
* OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
* THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
* ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
* TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
* BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/
#include "opt_tx39xx.h"
#include <sys/param.h>
#include <sys/systm.h>
@ -49,16 +58,11 @@
#include <dev/wscons/wsksymvar.h>
#include <dev/pckbc/wskbdmap_mfii.h>
#ifdef WSDISPLAY_COMPAT_RAWKBD
#include <hpcmips/dev/pckbd_encode.h>
#include <dev/hpc/pckbd_encode.h>
#endif
#include <hpcmips/dev/hpckbdvar.h>
#include <hpcmips/dev/hpckbdkeymap.h>
#ifdef TX39XX
#include <hpcmips/tx/tx39var.h>
#include <hpcmips/tx/txsnd.h>
#endif
#include <dev/hpc/hpckbdvar.h>
#include <dev/hpc/hpckbdkeymap.h>
struct hpckbd_softc;
@ -93,32 +97,31 @@ struct hpckbd_softc {
struct hpckbd_core sc_coredata;
};
int hpckbd_match __P((struct device*, struct cfdata*, void*));
void hpckbd_attach __P((struct device*, struct device*, void*));
int hpckbd_match(struct device *, struct cfdata *, void *);
void hpckbd_attach(struct device *, struct device *, void *);
void hpckbd_initcore __P((struct hpckbd_core*, struct hpckbd_ic_if*,
int));
void hpckbd_initif __P((struct hpckbd_core*));
int hpckbd_getevent __P((struct hpckbd_core*, u_int*, int*));
int hpckbd_putevent __P((struct hpckbd_core*, u_int, int));
void hpckbd_keymap_lookup __P((struct hpckbd_core*));
void hpckbd_keymap_setup __P((struct hpckbd_core *, const keysym_t *, int));
int __hpckbd_input __P((void*, int, int));
void __hpckbd_input_hook __P((void*));
void hpckbd_initcore(struct hpckbd_core *, struct hpckbd_ic_if *, int);
void hpckbd_initif(struct hpckbd_core *);
int hpckbd_getevent(struct hpckbd_core *, u_int *, int *);
int hpckbd_putevent(struct hpckbd_core *, u_int, int);
void hpckbd_keymap_lookup(struct hpckbd_core*);
void hpckbd_keymap_setup(struct hpckbd_core *, const keysym_t *, int);
int __hpckbd_input(void *, int, int);
void __hpckbd_input_hook(void*);
struct cfattach hpckbd_ca = {
sizeof(struct hpckbd_softc), hpckbd_match, hpckbd_attach
};
/* wskbd accessopts */
int hpckbd_enable __P((void *, int));
void hpckbd_set_leds __P((void *, int));
int hpckbd_ioctl __P((void *, u_long, caddr_t, int, struct proc *));
int hpckbd_enable(void *, int);
void hpckbd_set_leds(void *, int);
int hpckbd_ioctl(void *, u_long, caddr_t, int, struct proc *);
/* consopts */
struct hpckbd_core hpckbd_consdata;
void hpckbd_cngetc __P((void*, u_int*, int*));
void hpckbd_cnpollc __P((void *, int));
void hpckbd_cngetc(void *, u_int *, int*);
void hpckbd_cnpollc(void *, int);
const struct wskbd_accessops hpckbd_accessops = {
hpckbd_enable,
@ -141,19 +144,13 @@ struct wskbd_mapdata hpckbd_keymapdata = {
};
int
hpckbd_match(parent, cf, aux)
struct device *parent;
struct cfdata *cf;
void *aux;
hpckbd_match(struct device *parent, struct cfdata *cf, void *aux)
{
return (1);
}
void
hpckbd_attach(parent, self, aux)
struct device *parent;
struct device *self;
void *aux;
hpckbd_attach(struct device *parent, struct device *self, void *aux)
{
struct hpckbd_attach_args *haa = aux;
struct hpckbd_softc *sc = (void*)self;
@ -192,18 +189,13 @@ hpckbd_attach(parent, self, aux)
}
int
hpckbd_print(aux, pnp)
void *aux;
const char *pnp;
hpckbd_print(void *aux, const char *pnp)
{
return (pnp ? QUIET : UNCONF);
}
void
hpckbd_initcore(hc, ic, console)
struct hpckbd_core *hc;
struct hpckbd_ic_if *ic;
int console;
hpckbd_initcore(struct hpckbd_core *hc, struct hpckbd_ic_if *ic, int console)
{
hc->hc_polling = 0;
hc->hc_console = console;
@ -217,8 +209,7 @@ hpckbd_initcore(hc, ic, console)
}
void
hpckbd_initif(hc)
struct hpckbd_core *hc;
hpckbd_initif(struct hpckbd_core *hc)
{
struct hpckbd_if *kbdif = &hc->hc_if;
@ -229,10 +220,7 @@ hpckbd_initif(hc)
}
int
hpckbd_putevent(hc, type, data)
struct hpckbd_core* hc;
u_int type;
int data;
hpckbd_putevent(struct hpckbd_core* hc, u_int type, int data)
{
if (hc->hc_nevents == NEVENTQ)
return (0); /* queue is full */
@ -247,10 +235,7 @@ hpckbd_putevent(hc, type, data)
}
int
hpckbd_getevent(hc, type, data)
struct hpckbd_core* hc;
u_int *type;
int *data;
hpckbd_getevent(struct hpckbd_core* hc, u_int *type, int *data)
{
if (hc->hc_nevents == 0)
return (0); /* queue is empty */
@ -265,10 +250,7 @@ hpckbd_getevent(hc, type, data)
}
void
hpckbd_keymap_setup(hc, map, mapsize)
struct hpckbd_core *hc;
const keysym_t *map;
int mapsize;
hpckbd_keymap_setup(struct hpckbd_core *hc, const keysym_t *map, int mapsize)
{
int i;
struct wscons_keydesc *desc;
@ -286,8 +268,7 @@ hpckbd_keymap_setup(hc, map, mapsize)
}
void
hpckbd_keymap_lookup(hc)
struct hpckbd_core *hc;
hpckbd_keymap_lookup(struct hpckbd_core *hc)
{
const struct hpckbd_keymap_table *tab;
platid_mask_t mask;
@ -324,8 +305,7 @@ hpckbd_keymap_lookup(hc)
}
void
__hpckbd_input_hook(arg)
void *arg;
__hpckbd_input_hook(void *arg)
{
#if 0
struct hpckbd_core *hc = arg;
@ -337,17 +317,12 @@ __hpckbd_input_hook(arg)
}
int
__hpckbd_input(arg, flag, scancode)
void *arg;
int flag, scancode;
__hpckbd_input(void *arg, int flag, int scancode)
{
struct hpckbd_core *hc = arg;
int type, key;
if (flag) {
#ifdef TX39XX
tx_sound_click(tx_conf_get_tag());
#endif
type = WSCONS_EVENT_KEY_DOWN;
} else {
type = WSCONS_EVENT_KEY_UP;
@ -403,8 +378,7 @@ __hpckbd_input(arg, flag, scancode)
* console support routines
*/
int
hpckbd_cnattach(ic)
struct hpckbd_ic_if *ic;
hpckbd_cnattach(struct hpckbd_ic_if *ic)
{
struct hpckbd_core *hc = &hpckbd_consdata;
@ -420,10 +394,7 @@ hpckbd_cnattach(ic)
}
void
hpckbd_cngetc(arg, type, data)
void *arg;
u_int *type;
int *data;
hpckbd_cngetc(void *arg, u_int *type, int *data)
{
struct hpckbd_core *hc = arg;
int s;
@ -438,9 +409,7 @@ hpckbd_cngetc(arg, type, data)
}
void
hpckbd_cnpollc(arg, on)
void *arg;
int on;
hpckbd_cnpollc(void *arg, int on)
{
struct hpckbd_core *hc = arg;
int s = splimp();
@ -451,9 +420,7 @@ hpckbd_cnpollc(arg, on)
}
int
hpckbd_enable(arg, on)
void *arg;
int on;
hpckbd_enable(void *arg, int on)
{
struct hpckbd_core *hc = arg;
@ -471,20 +438,13 @@ hpckbd_enable(arg, on)
}
void
hpckbd_set_leds(arg, leds)
void *arg;
int leds;
hpckbd_set_leds(void *arg, int leds)
{
/* Can you find any LED which tells you about keyboard? */
}
int
hpckbd_ioctl(arg, cmd, data, flag, p)
void *arg;
u_long cmd;
caddr_t data;
int flag;
struct proc *p;
hpckbd_ioctl(void *arg, u_long cmd, caddr_t data, int flag, struct proc *p)
{
#ifdef WSDISPLAY_COMPAT_RAWKBD
struct hpckbd_core *hc = arg;

View File

@ -1,7 +1,7 @@
/* $NetBSD: hpckbdkeymap.h,v 1.6 2000/10/19 01:08:15 takemura Exp $ */
/* $NetBSD: hpckbdkeymap.h,v 1.1 2001/02/22 18:37:56 uch Exp $ */
/*
* Copyright (c) 1999, 2000, by UCHIYAMA Yasushi
/*-
* Copyright (c) 1999-2001 The NetBSD Foundation, Inc.
* All rights reserved.
*
* Redistribution and use in source and binary forms, with or without
@ -9,22 +9,30 @@
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. The name of the developer may NOT be used to endorse or promote products
* derived from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND
* ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
* IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
* ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
* FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
* DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
* OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
* HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
* LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* 3. All advertising materials mentioning features or use of this software
* must display the following acknowledgement:
* This product includes software developed by the NetBSD
* Foundation, Inc. and its contributors.
* 4. Neither the name of The NetBSD Foundation nor the names of its
* contributors may be used to endorse or promote products derived
* from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
* ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
* TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
* BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/
#define UNK 255 /* unknown */
#define IGN 254 /* ignore */
#define SPL 253 /* special key */
@ -60,6 +68,7 @@ const int default_special_keymap[] = {
[KEY_SPECIAL_LIGHT] = -1
};
#ifdef hpcmips
const u_int8_t tc5165_mobilon_keymap[] = {
/* 0 1 2 3 4 5 6 7 */
/* 0 */ 37 , 45 , 44 , UNK, 9 , 51 , 23 , UNK,
@ -412,6 +421,7 @@ static const keysym_t sigmarion_cmdmap[] = {
KC(52), KS_Cmd_ContrastUp, KS_period, KS_greater,
KC(57), KS_Cmd_BacklightToggle,KS_space,
};
#endif /* hpcmips */
const struct hpckbd_keymap_table {
platid_t *ht_platform;
@ -423,6 +433,7 @@ const struct hpckbd_keymap_table {
} ht_cmdmap;
kbd_t ht_layout;
} hpckbd_keymap_table[] = {
#ifdef hpcmips
{ &platid_mask_MACH_COMPAQ_C,
tc5165_compaq_c_jp_keymap,
tc5165_compaq_c_jp_special_keymap,
@ -508,5 +519,6 @@ const struct hpckbd_keymap_table {
NULL,
NULLCMDMAP,
KB_JP },
#endif /* hpcmips */
{ NULL } /* end mark */
};

73
sys/dev/hpc/hpckbdvar.h Normal file
View File

@ -0,0 +1,73 @@
/* $NetBSD: hpckbdvar.h,v 1.1 2001/02/22 18:37:56 uch Exp $ */
/*-
* Copyright (c) 1999-2001 The NetBSD Foundation, Inc.
* All rights reserved.
*
* This code is derived from software contributed to The NetBSD Foundation
* by UCHIYAMA Yasushi.
*
* Redistribution and use in source and binary forms, with or without
* modification, are permitted provided that the following conditions
* are met:
* 1. Redistributions of source code must retain the above copyright
* notice, this list of conditions and the following disclaimer.
* 2. Redistributions in binary form must reproduce the above copyright
* notice, this list of conditions and the following disclaimer in the
* documentation and/or other materials provided with the distribution.
* 3. All advertising materials mentioning features or use of this software
* must display the following acknowledgement:
* This product includes software developed by the NetBSD
* Foundation, Inc. and its contributors.
* 4. Neither the name of The NetBSD Foundation nor the names of its
* contributors may be used to endorse or promote products derived
* from this software without specific prior written permission.
*
* THIS SOFTWARE IS PROVIDED BY THE NETBSD FOUNDATION, INC. AND CONTRIBUTORS
* ``AS IS'' AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED
* TO, THE IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR
* PURPOSE ARE DISCLAIMED. IN NO EVENT SHALL THE FOUNDATION OR CONTRIBUTORS
* BE LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
* CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
* SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
* INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
* CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
* ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
* POSSIBILITY OF SUCH DAMAGE.
*/
/*
* chip interface
*/
struct hpckbd_if;
struct hpckbd_ic_if {
void *hii_ctx;
int (*hii_establish)(void *, struct hpckbd_if *);
int (*hii_poll)(void *);
};
#define hpckbd_ic_establish(ic, kbdif) \
(*(ic)->hii_establish)((ic)->hii_ctx, (kbdif))
#define hpckbd_ic_poll(ic) \
(*(ic)->hii_poll)((ic)->hii_ctx)
/*
* hpckbd interface
*/
struct hpckbd_if {
void *hi_ctx;
void (*hi_input_hook)(void *);
int (*hi_input)(void *, int, int);
};
#define hpckbd_input_hook(i) \
(*(i)->hi_input_hook)((i)->hi_ctx)
#define hpckbd_input(i, f, a) \
(*(i)->hi_input)((i)->hi_ctx, (f), (a))
struct hpckbd_attach_args {
struct hpckbd_ic_if *haa_ic;
};
int hpckbd_print(void *, const char *);
int hpckbd_cnattach(struct hpckbd_ic_if *);

View File

@ -1,4 +1,4 @@
/* $NetBSD: mra.c,v 1.1 2000/01/10 14:07:58 takemura Exp $ */
/* $NetBSD: mra.c,v 1.1 2001/02/22 18:37:56 uch Exp $ */
/*
* Copyright (c) 1999 Shin Takemura All rights reserved.

View File

@ -1,4 +1,4 @@
/* $NetBSD: pckbd_encode.c,v 1.1 2000/05/04 08:20:26 takemura Exp $ */
/* $NetBSD: pckbd_encode.c,v 1.1 2001/02/22 18:37:56 uch Exp $ */
/*-
* Copyright (c) 2000 TAKEMRUA, Shin All rights reserved.
@ -39,16 +39,13 @@
#include <sys/param.h>
#include <dev/wscons/wsconsio.h>
#include <dev/pckbc/pckbdreg.h>
#include <hpcmips/dev/pckbd_encode.h>
#include <dev/hpc/pckbd_encode.h>
/*
* pckbd_encode() is inverse function of pckbd_decode() in dev/pckbc/pckbd.c.
*/
int
pckbd_encode(type, datain, dataout)
u_int type;
int datain;
u_char *dataout;
pckbd_encode(u_int type, int datain, u_char *dataout)
{
int res;
u_char updown;

View File

@ -1,4 +1,4 @@
/* $NetBSD: pckbd_encode.h,v 1.1 2000/05/04 08:20:26 takemura Exp $ */
/* $NetBSD: pckbd_encode.h,v 1.1 2001/02/22 18:37:56 uch Exp $ */
/*-
* Copyright (c) 2000 TAKEMRUA, Shin All rights reserved.
@ -33,4 +33,4 @@
*
*/
extern int pckbd_encode __P((u_int, int, u_char *));
extern int pckbd_encode(u_int, int, u_char *);

View File

@ -1,4 +1,4 @@
/* $NetBSD: tpcalib.c,v 1.3 2000/02/28 12:34:32 takemura Exp $ */
/* $NetBSD: tpcalib.c,v 1.1 2001/02/22 18:37:56 uch Exp $ */
/*
* Copyright (c) 1999 Shin Takemura All rights reserved.
@ -32,7 +32,7 @@
#include <sys/device.h>
#include <sys/kernel.h>
#include <dev/wscons/wsconsio.h>
#include <hpcmips/dev/tpcalibvar.h>
#include <dev/hpc/tpcalibvar.h>
#define TPCALIBDEBUG
#ifdef TPCALIBDEBUG

View File

@ -1,4 +1,4 @@
/* $NetBSD: tpcalibvar.h,v 1.1 2000/01/10 14:08:00 takemura Exp $ */
/* $NetBSD: tpcalibvar.h,v 1.1 2001/02/22 18:37:56 uch Exp $ */
/*
* Copyright (c) 1999 Shin Takemura All rights reserved.

View File

@ -1,4 +1,4 @@
/* $NetBSD: video_subr.c,v 1.3 2000/10/22 10:33:01 uch Exp $ */
/* $NetBSD: video_subr.c,v 1.1 2001/02/22 18:37:56 uch Exp $ */
/*-
* Copyright (c) 2000 The NetBSD Foundation, Inc.
@ -42,7 +42,7 @@
#include <machine/bootinfo.h>
#include <arch/hpcmips/dev/video_subr.h>
#include <dev/hpc/video_subr.h>
#define BPP2 ({ \
u_int8_t bitmap; \

View File

@ -1,4 +1,4 @@
/* $NetBSD: video_subr.h,v 1.4 2000/10/22 10:33:01 uch Exp $ */
/* $NetBSD: video_subr.h,v 1.1 2001/02/22 18:37:57 uch Exp $ */
/*-
* Copyright (c) 2000 The NetBSD Foundation, Inc.
@ -46,7 +46,7 @@ void cmap_work_free(u_int8_t *, u_int8_t *, u_int8_t *, u_int32_t *);
void rgb24_compose(u_int32_t *, u_int8_t *, u_int8_t *, u_int8_t *, int);
void rgb24_decompose(u_int32_t *, u_int8_t *, u_int8_t *, u_int8_t *, int);
/* debug function for TX. VR will need `line bytes' */
/* debug function */
struct video_chip;
struct video_chip {
void *vc_v; /* CPU/chipset dependent goo */