1/*
2 * Copyright (c) 1988 University of Utah.
3 * Copyright (c) 1991 The Regents of the University of California.
4 * All rights reserved.
5 *
6 * This code is derived from software contributed to Berkeley by
7 * the Systems Programming Group of the University of Utah Computer
8 * Science Department.
--- 22 unchanged lines hidden (view full) ---
31 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
32 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
33 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
36 * SUCH DAMAGE.
37 *
38 * from: @(#)cons.c 7.2 (Berkeley) 5/9/91
39 * $FreeBSD: head/sys/kern/tty_cons.c 111194 2003-02-20 20:54:45Z phk $
40 */
41
42#include "opt_ddb.h"
43
44#include <sys/param.h>
45#include <sys/systm.h>
46#include <sys/conf.h>
47#include <sys/cons.h>
--- 18 unchanged lines hidden (view full) ---
66static d_read_t cnread;
67static d_write_t cnwrite;
68static d_ioctl_t cnioctl;
69static d_poll_t cnpoll;
70static d_kqfilter_t cnkqfilter;
71
72#define CDEV_MAJOR 0
73static struct cdevsw cn_cdevsw = {
74 /* open */ cnopen,
75 /* close */ cnclose,
76 /* read */ cnread,
77 /* write */ cnwrite,
78 /* ioctl */ cnioctl,
79 /* poll */ cnpoll,
80 /* mmap */ nommap,
81 /* strategy */ nostrategy,
82 /* name */ "console",
83 /* maj */ CDEV_MAJOR,
84 /* dump */ nodump,
85 /* psize */ nopsize,
86 /* flags */ D_TTY | D_KQFILTER,
87 /* kqfilter */ cnkqfilter,
88};
89
90struct cn_device {
91 STAILQ_ENTRY(cn_device) cnd_next;
92 char cnd_name[16];
93 struct vnode *cnd_vp;
94 struct consdev *cnd_cn;
95};
--- 503 unchanged lines hidden ---
2 * Copyright (c) 1988 University of Utah.
3 * Copyright (c) 1991 The Regents of the University of California.
4 * All rights reserved.
5 *
6 * This code is derived from software contributed to Berkeley by
7 * the Systems Programming Group of the University of Utah Computer
8 * Science Department.
--- 22 unchanged lines hidden (view full) ---
31 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
32 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
33 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
34 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
35 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
36 * SUCH DAMAGE.
37 *
38 * from: @(#)cons.c 7.2 (Berkeley) 5/9/91
39 * $FreeBSD: head/sys/kern/tty_cons.c 111194 2003-02-20 20:54:45Z phk $
40 */
41
42#include "opt_ddb.h"
43
44#include <sys/param.h>
45#include <sys/systm.h>
46#include <sys/conf.h>
47#include <sys/cons.h>
--- 18 unchanged lines hidden (view full) ---
66static d_read_t cnread;
67static d_write_t cnwrite;
68static d_ioctl_t cnioctl;
69static d_poll_t cnpoll;
70static d_kqfilter_t cnkqfilter;
71
72#define CDEV_MAJOR 0
73static struct cdevsw cn_cdevsw = {
74 /* open */ cnopen,
75 /* close */ cnclose,
76 /* read */ cnread,
77 /* write */ cnwrite,
78 /* ioctl */ cnioctl,
79 /* poll */ cnpoll,
80 /* mmap */ nommap,
81 /* strategy */ nostrategy,
82 /* name */ "console",
83 /* maj */ CDEV_MAJOR,
84 /* dump */ nodump,
85 /* psize */ nopsize,
86 /* flags */ D_TTY | D_KQFILTER,
87 /* kqfilter */ cnkqfilter,
88};
89
90struct cn_device {
91 STAILQ_ENTRY(cn_device) cnd_next;
92 char cnd_name[16];
93 struct vnode *cnd_vp;
94 struct consdev *cnd_cn;
95};
--- 503 unchanged lines hidden ---