xref: /openbsd/sys/arch/hppa/stand/boot/conf.c (revision 610f49f8)
1 /*	$OpenBSD: conf.c,v 1.13 2002/02/02 21:25:35 mickey Exp $	*/
2 
3 /*
4  * Copyright (c) 1998 Michael Shalayeff
5  * All rights reserved.
6  *
7  * Redistribution and use in source and binary forms, with or without
8  * modification, are permitted provided that the following conditions
9  * are met:
10  * 1. Redistributions of source code must retain the above copyright
11  *    notice, this list of conditions and the following disclaimer.
12  * 2. Redistributions in binary form must reproduce the above copyright
13  *    notice, this list of conditions and the following disclaimer in the
14  *    documentation and/or other materials provided with the distribution.
15  * 3. All advertising materials mentioning features or use of this software
16  *    must display the following acknowledgement:
17  *	This product includes software developed by Michael Shalayeff.
18  * 4. The name of the author may not be used to endorse or promote products
19  *    derived from this software without specific prior written permission.
20  *
21  * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS OR
22  * IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES
23  * OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE DISCLAIMED.
24  * IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR ANY DIRECT, INDIRECT,
25  * INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT
26  * NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE,
27  * DATA, OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY
28  * THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT
29  * (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF
30  * THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
31  */
32 
33 #include <sys/types.h>
34 #include <libsa.h>
35 #include <lib/libsa/ufs.h>
36 #include <lib/libsa/cd9660.h>
37 #include <lib/libsa/exec.h>
38 #include <dev/cons.h>
39 
40 const char version[] = "0.6";
41 int	debug = 0;
42 
43 const struct x_sw execsw[] = {
44 	{ "elf", elf_probe,	elf_load,	elf_ldsym },
45 /*	{ "som", som_probe,	som_load,	som_ldsym }, */
46 	{ ""   , NULL,		NULL,		NULL },
47 };
48 
49 struct fs_ops file_system[] = {
50 	{ lif_open,    lif_close,    lif_read,    lif_write,    lif_seek,
51 	  lif_stat,    lif_readdir    },
52 	{ ufs_open,    ufs_close,    ufs_read,    ufs_write,    ufs_seek,
53 	  ufs_stat,    ufs_readdir    },
54 	{ cd9660_open, cd9660_close, cd9660_read, cd9660_write, cd9660_seek,
55 	  cd9660_stat, cd9660_readdir },
56 };
57 int nfsys = NENTS(file_system);
58 
59 struct devsw devsw[] = {
60 	{ "ct",	iodcstrategy, ctopen, ctclose, noioctl },
61 	{ "dk",	iodcstrategy, dkopen, dkclose, noioctl },
62 	{ "lf", iodcstrategy, lfopen, lfclose, noioctl }
63 };
64 int	ndevs = NENTS(devsw);
65 
66 struct consdev	constab[] = {
67 	{ ite_probe, ite_init, ite_getc, ite_putc },
68 	{ NULL }
69 };
70 struct consdev *cn_tab;
71 
72