1/*-
2 * Copyright (c) 2000 Doug Rabson
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright
--- 9 unchanged lines hidden (view full) ---
18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 *
26 * $FreeBSD: head/sys/dev/agp/agp.c 111815 2003-03-03 12:15:54Z phk $
27 */
28
29#include "opt_bus.h"
30
31#include <sys/param.h>
32#include <sys/systm.h>
33#include <sys/malloc.h>
34#include <sys/kernel.h>
--- 30 unchanged lines hidden (view full) ---
65#define CDEV_MAJOR 148
66 /* agp_drv.c */
67static d_open_t agp_open;
68static d_close_t agp_close;
69static d_ioctl_t agp_ioctl;
70static d_mmap_t agp_mmap;
71
72static struct cdevsw agp_cdevsw = {
73 .d_open = agp_open,
74 .d_close = agp_close,
75 .d_ioctl = agp_ioctl,
76 .d_mmap = agp_mmap,
77 .d_name = "agp",
78 .d_maj = CDEV_MAJOR,
79 .d_flags = D_TTY,
80};
81
82static devclass_t agp_devclass;
83#define KDEV2DEV(kdev) devclass_get_device(agp_devclass, minor(kdev))
84
85/* Helper functions for implementing chipset mini drivers. */
86
87void
--- 724 unchanged lines hidden ---
2 * Copyright (c) 2000 Doug Rabson
3 * All rights reserved.
4 *
5 * Redistribution and use in source and binary forms, with or without
6 * modification, are permitted provided that the following conditions
7 * are met:
8 * 1. Redistributions of source code must retain the above copyright
--- 9 unchanged lines hidden (view full) ---
18 * FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL
19 * DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS
20 * OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION)
21 * HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT
22 * LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY
23 * OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
24 * SUCH DAMAGE.
25 *
26 * $FreeBSD: head/sys/dev/agp/agp.c 111815 2003-03-03 12:15:54Z phk $
27 */
28
29#include "opt_bus.h"
30
31#include <sys/param.h>
32#include <sys/systm.h>
33#include <sys/malloc.h>
34#include <sys/kernel.h>
--- 30 unchanged lines hidden (view full) ---
65#define CDEV_MAJOR 148
66 /* agp_drv.c */
67static d_open_t agp_open;
68static d_close_t agp_close;
69static d_ioctl_t agp_ioctl;
70static d_mmap_t agp_mmap;
71
72static struct cdevsw agp_cdevsw = {
73 .d_open = agp_open,
74 .d_close = agp_close,
75 .d_ioctl = agp_ioctl,
76 .d_mmap = agp_mmap,
77 .d_name = "agp",
78 .d_maj = CDEV_MAJOR,
79 .d_flags = D_TTY,
80};
81
82static devclass_t agp_devclass;
83#define KDEV2DEV(kdev) devclass_get_device(agp_devclass, minor(kdev))
84
85/* Helper functions for implementing chipset mini drivers. */
86
87void
--- 724 unchanged lines hidden ---