USB bluetooth device rump component.
This is a curious driver in the sense that unlike all other current device drivers, it does not require vfs. This is because the driver is controlled via bluetooth, which is controlled via PF_BLUETOOTH sockets (as opposed to a /dev node).
This commit is contained in:
parent
5f0c4c358e
commit
9a702d8fe4
|
@ -1,7 +1,7 @@
|
|||
# $NetBSD: Makefile.rumpdev,v 1.9 2010/02/11 02:22:09 pooka Exp $
|
||||
# $NetBSD: Makefile.rumpdev,v 1.10 2010/03/22 12:14:51 pooka Exp $
|
||||
#
|
||||
|
||||
RUMPDEVLIST= bpf cgd disk dm netsmb raidframe rnd sysmon ucom \
|
||||
RUMPDEVLIST= bpf cgd disk dm netsmb raidframe rnd sysmon ubt ucom \
|
||||
ugenhc ulpt umass usb wscons
|
||||
|
||||
|
||||
|
|
|
@ -0,0 +1,16 @@
|
|||
# $NetBSD: Makefile,v 1.1 2010/03/22 12:14:51 pooka Exp $
|
||||
#
|
||||
|
||||
.PATH: ${.CURDIR}/../../../../dev/usb
|
||||
|
||||
LIB= rumpdev_ubt
|
||||
IOCONF= UBT.ioconf
|
||||
|
||||
SRCS= ubt.c
|
||||
|
||||
SRCS+= ubt_at_usb.c
|
||||
|
||||
CPPFLAGS+= -I${RUMPTOP}/net/lib/libnetbt
|
||||
|
||||
.include <bsd.lib.mk>
|
||||
.include <bsd.klinks.mk>
|
|
@ -0,0 +1,14 @@
|
|||
# $NetBSD: UBT.ioconf,v 1.1 2010/03/22 12:14:51 pooka Exp $
|
||||
#
|
||||
|
||||
ioconf ubt
|
||||
|
||||
include "conf/files"
|
||||
include "dev/usb/files.usb"
|
||||
include "rump/dev/files.rump"
|
||||
|
||||
pseudo-root uhub*
|
||||
|
||||
# Bluetooth USB Controllers
|
||||
ubt* at uhub? port ?
|
||||
bthub* at ubt?
|
|
@ -0,0 +1,4 @@
|
|||
# $NetBSD: shlib_version,v 1.1 2010/03/22 12:14:51 pooka Exp $
|
||||
#
|
||||
major=0
|
||||
minor=0
|
|
@ -0,0 +1,28 @@
|
|||
/* $NetBSD: ubt_at_usb.c,v 1.1 2010/03/22 12:14:51 pooka Exp $ */
|
||||
|
||||
#include <sys/param.h>
|
||||
#include <sys/types.h>
|
||||
#include <sys/conf.h>
|
||||
#include <sys/device.h>
|
||||
#include <sys/kmem.h>
|
||||
|
||||
#include "ioconf.c"
|
||||
|
||||
#include "rump_private.h"
|
||||
#include "rump_dev_private.h"
|
||||
|
||||
#define FLAWLESSCALL(call) \
|
||||
do { \
|
||||
int att_error; \
|
||||
if ((att_error = call) != 0) \
|
||||
panic("\"%s\" failed", #call); \
|
||||
} while (/*CONSTCOND*/0)
|
||||
|
||||
RUMP_COMPONENT(RUMP_COMPONENT_DEV)
|
||||
{
|
||||
|
||||
FLAWLESSCALL(config_cfdata_attach(cfdata_ubt, 0));
|
||||
|
||||
FLAWLESSCALL(config_cfdriver_attach(&ubt_cd));
|
||||
FLAWLESSCALL(config_cfattach_attach("ubt", &ubt_ca));
|
||||
}
|
Loading…
Reference in New Issue