1*6bb51422Spooka /* $NetBSD: putter_component.c,v 1.2 2016/01/26 23:12:16 pooka Exp $ */
2518e3e16Spooka
3518e3e16Spooka /*-
4518e3e16Spooka * Copyright (c) 2009 Antti Kantee. All Rights Reserved.
5518e3e16Spooka *
6518e3e16Spooka * Redistribution and use in source and binary forms, with or without
7518e3e16Spooka * modification, are permitted provided that the following conditions
8518e3e16Spooka * are met:
9518e3e16Spooka * 1. Redistributions of source code must retain the above copyright
10518e3e16Spooka * notice, this list of conditions and the following disclaimer.
11518e3e16Spooka * 2. Redistributions in binary form must reproduce the above copyright
12518e3e16Spooka * notice, this list of conditions and the following disclaimer in the
13518e3e16Spooka * documentation and/or other materials provided with the distribution.
14518e3e16Spooka *
15518e3e16Spooka * THIS SOFTWARE IS PROVIDED BY THE AUTHOR ``AS IS'' AND ANY EXPRESS
16518e3e16Spooka * OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED
17518e3e16Spooka * WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE ARE
18518e3e16Spooka * DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE
19518e3e16Spooka * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
20518e3e16Spooka * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR
21518e3e16Spooka * SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
22518e3e16Spooka * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
23518e3e16Spooka * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
24518e3e16Spooka * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
25518e3e16Spooka * SUCH DAMAGE.
26518e3e16Spooka */
27518e3e16Spooka
28518e3e16Spooka #include <sys/cdefs.h>
29*6bb51422Spooka __KERNEL_RCSID(0, "$NetBSD: putter_component.c,v 1.2 2016/01/26 23:12:16 pooka Exp $");
30518e3e16Spooka
31518e3e16Spooka #include <sys/param.h>
32518e3e16Spooka #include <sys/conf.h>
33518e3e16Spooka #include <sys/device.h>
34518e3e16Spooka #include <sys/stat.h>
35518e3e16Spooka
36*6bb51422Spooka #include <rump-sys/kern.h>
37*6bb51422Spooka #include <rump-sys/vfs.h>
38518e3e16Spooka
RUMP_COMPONENT(RUMP_COMPONENT_DEV)39518e3e16Spooka RUMP_COMPONENT(RUMP_COMPONENT_DEV)
40518e3e16Spooka {
41518e3e16Spooka int error;
42518e3e16Spooka
43518e3e16Spooka if ((error = rump_vfs_makeonedevnode(S_IFCHR,
44518e3e16Spooka "/dev/putter", 178, 0)) != 0)
45518e3e16Spooka panic("cannot create /dev/putter: %d", error);
46518e3e16Spooka }
47