From owner-freebsd-bluetooth@FreeBSD.ORG Tue Mar 6 18:11:34 2007 Return-Path: X-Original-To: freebsd-bluetooth@freebsd.org Delivered-To: freebsd-bluetooth@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 05E6E16A402 for ; Tue, 6 Mar 2007 18:11:33 +0000 (UTC) (envelope-from pietro.cerutti@gmail.com) Received: from an-out-0708.google.com (an-out-0708.google.com [209.85.132.240]) by mx1.freebsd.org (Postfix) with ESMTP id A95A513C46B for ; Tue, 6 Mar 2007 18:11:33 +0000 (UTC) (envelope-from pietro.cerutti@gmail.com) Received: by an-out-0708.google.com with SMTP id c24so1720908ana for ; Tue, 06 Mar 2007 10:11:33 -0800 (PST) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=sVAWnx0PuS+Ph+6DWx0svYdQtuzr/vB7L8ydLUHFxWA/c6F6Rsm3myGWfZqcsAE+loZ4giuUCXV3/2WadlPCTrmhLM7cmjgyK4NSfAmmbEy9+fhODC/bYb7zn6Dh9NQBftgUK3WX8xzBoVOMTlpXrwjPn//NogkKml48TtjyGfk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:mime-version:content-type:content-transfer-encoding:content-disposition; b=nYZ9YM2tw8mIUfwLrbq0ctpcOfGTSyhGKSWslzh7bVcAGY+CJ6WlRwhXCCIigYLzQBsZzx/mRHmN/h6ZOkZw+ehdCG1SO4quzqo1i+iM7nJJ4IclpTUsUPO0kzyg1QuYXvcvvYVfaYScKodfC2IBUJ85gOcRuVDqLPfiv21lwSY= Received: by 10.100.195.10 with SMTP id s10mr3711975anf.1173203071880; Tue, 06 Mar 2007 09:44:31 -0800 (PST) Received: by 10.100.33.5 with HTTP; Tue, 6 Mar 2007 09:44:31 -0800 (PST) Message-ID: Date: Tue, 6 Mar 2007 18:44:31 +0100 From: "Pietro Cerutti" To: freebsd-bluetooth@freebsd.org MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline Subject: which modules are mandatory? X-BeenThere: freebsd-bluetooth@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Using Bluetooth in FreeBSD environments List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 Mar 2007 18:11:34 -0000 Hi list, I have this built-in bluetooth dongle on my laptop: ubt0: vendor 0x0a12 product 0x0001, rev 2.00/15.93, addr 2 ubt0: vendor 0x0a12 product 0x0001, rev 2.00/15.93, addr 2 ubt0: Interface 0 endpoints: interrupt=0x81, bulk-in=0x82, bulk-out=0x2 ubt0: Interface 1 (alt.config 5) endpoints: isoc-in=0x83, isoc-out=0x3; wMaxPacketSize=49; nframes=6, buffer size=294 My laptop is a MSI-1034 (http://www.msicomputer.com/NB/product_spec.asp?model=MS-1034_(Core2_Duo)) but unfortunately the manufacturer doesn't give many information about the bluetooth device. I would like to keep my kernel at a minimum, and thus I'd like to know which parts of it should be built in order for bluetooth to work. The thing that's misleading me is the following: if I compile my kernel with only the /sys/modules/netgraph/netgraph and /sys/modules/netgraph/bluetooth modules, I get the following error while trying to enable bluetooth: # sh -x /etc/rc.bluetooth start ubt0 + logger=/usr/bin/logger -i -s -p user.err + kldstat=/sbin/kldstat + kldload=/sbin/kldload + sysctl=/sbin/sysctl + ngctl=/usr/sbin/ngctl + hcseriald=/usr/sbin/hcseriald + hccontrol=/usr/sbin/hccontrol + hci_debug_level=3 + l2cap_debug_level=3 + [ 2 -lt 2 ] + startstop=start + shift + dev=ubt0 + shift + load_module ng_bluetooth + module=ng_bluetooth + shift + /sbin/kldstat -n ng_bluetooth + [ 0 -ne 0 ] + load_module ng_hci + module=ng_hci + shift + /sbin/kldstat -n ng_hci + [ 0 -ne 0 ] + load_module ng_l2cap + module=ng_l2cap + shift + /sbin/kldstat -n ng_l2cap + [ 0 -ne 0 ] + load_module ng_btsocket + module=ng_btsocket + shift + /sbin/kldstat -n ng_btsocket + [ 0 -ne 0 ] + /etc/rc.bluetooth stop ubt0 + hook=hook + expr ubt0 : ubt\([0-9]\{1,\}\) + unit=0 + [ -z 0 ] + setup_stack ubt0 hook + dev=ubt0 + shift + hook=hook + shift + /usr/sbin/ngctl mkpeer ubt0: hci hook drv ngctl: can't create node: No such file or directory + exit 1 On the other hand, if I compile and install the whole /sys/modules/netgraph directory, the output is the following, and bluetooth works like a charm! # sh -x /etc/rc.bluetooth start ubt0 + logger=/usr/bin/logger -i -s -p user.err + kldstat=/sbin/kldstat + kldload=/sbin/kldload + sysctl=/sbin/sysctl + ngctl=/usr/sbin/ngctl + hcseriald=/usr/sbin/hcseriald + hccontrol=/usr/sbin/hccontrol + hci_debug_level=3 + l2cap_debug_level=3 + [ 2 -lt 2 ] + startstop=start + shift + dev=ubt0 + shift + load_module ng_bluetooth + module=ng_bluetooth + shift + /sbin/kldstat -n ng_bluetooth + [ 0 -ne 0 ] + load_module ng_hci + module=ng_hci + shift + /sbin/kldstat -n ng_hci + [ 0 -ne 0 ] + load_module ng_l2cap + module=ng_l2cap + shift + /sbin/kldstat -n ng_l2cap + [ 0 -ne 0 ] + load_module ng_btsocket + module=ng_btsocket + shift + /sbin/kldstat -n ng_btsocket + [ 0 -ne 0 ] + /etc/rc.bluetooth stop ubt0 + hook=hook + expr ubt0 : ubt\([0-9]\{1,\}\) + unit=0 + [ -z 0 ] + setup_stack ubt0 hook + dev=ubt0 + shift + hook=hook + shift + /usr/sbin/ngctl mkpeer ubt0: hci hook drv + /usr/sbin/ngctl name ubt0:hook ubt0hci + /usr/sbin/ngctl msg ubt0hci: set_debug 3 + /usr/sbin/ngctl mkpeer ubt0hci: l2cap acl hci + /usr/sbin/ngctl name ubt0hci:acl ubt0l2cap + /usr/sbin/ngctl msg ubt0l2cap: set_debug 3 + /usr/sbin/ngctl connect ubt0hci: btsock_hci_raw: raw ubt0raw + /usr/sbin/ngctl connect ubt0l2cap: btsock_l2c_raw: ctl ubt0ctl + /usr/sbin/ngctl connect ubt0l2cap: btsock_l2c: l2c ubt0l2c + /usr/sbin/hccontrol -n ubt0hci reset + /usr/sbin/hccontrol -n ubt0hci read_bd_addr BD_ADDR: 00:0d:f0:2d:1d:e9 + /usr/sbin/hccontrol -n ubt0hci read_local_supported_features Features: 0xff 0xff 0x8f 0xf8 0x18 0x18 00 0x80 <3-Slot> <5-Slot> + /usr/sbin/hccontrol -n ubt0hci read_buffer_size Max. ACL packet size: 192 bytes Number of ACL packets: 8 Max. SCO packet size: 64 bytes Number of SCO packets: 8 + /usr/sbin/hccontrol -n ubt0hci write_scan_enable 3 + /usr/sbin/hccontrol -n ubt0hci write_class_of_device ff:01:0c + uname -n + /usr/sbin/hccontrol -n ubt0hci change_local_name gahrtop.localhost (ubt0) + /usr/sbin/hccontrol -n ubt0hci initialize Now, the weird thing is that in both cases, the kernel modules being loaded are the same: 8 1 0xc727f000 7000 ng_ubt.ko 9 4 0xc7286000 b000 netgraph.ko 10 4 0xc7295000 2000 ng_bluetooth.ko 11 1 0xc7297000 d000 ng_hci.ko 12 1 0xc72a4000 10000 ng_l2cap.ko 13 1 0xc72b4000 19000 ng_btsocket.ko and also the relevant outputs in /var/log/messages are the same: ubt0: vendor 0x0a12 product 0x0001, rev 2.00/15.93, addr 2 ubt0: vendor 0x0a12 product 0x0001, rev 2.00/15.93, addr 2 ubt0: Interface 0 endpoints: interrupt=0x81, bulk-in=0x82, bulk-out=0x2 ubt0: Interface 1 (alt.config 5) endpoints: isoc-in=0x83, isoc-out=0x3; wMaxPacketSize=49; nframes=6, buffer size=294 What I would like to know is: 1) why doesn't netgraph/netgraph and netgraph/bluetooth suffice? 2) what else should I include, if I want to avoid compiling the whole /sys/modules/netgraph directory? Thanks in advance! Please CC me since I'm not on the list! -- Pietro Cerutti - ASCII Ribbon Campaign - against HTML e-mail and proprietary attachments www.asciiribbon.org From owner-freebsd-bluetooth@FreeBSD.ORG Tue Mar 6 19:34:17 2007 Return-Path: X-Original-To: freebsd-bluetooth@freebsd.org Delivered-To: freebsd-bluetooth@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 038C516A401 for ; Tue, 6 Mar 2007 19:34:17 +0000 (UTC) (envelope-from maksim.yevmenkin@gmail.com) Received: from wr-out-0506.google.com (wr-out-0506.google.com [64.233.184.228]) by mx1.freebsd.org (Postfix) with ESMTP id B62A413C442 for ; Tue, 6 Mar 2007 19:34:16 +0000 (UTC) (envelope-from maksim.yevmenkin@gmail.com) Received: by wr-out-0506.google.com with SMTP id 71so2668315wri for ; Tue, 06 Mar 2007 11:34:15 -0800 (PST) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=FIJ47sdOjuxi1eob9+sy9gjSaGUp7iH3ftf4bz+UrZ+xd0ZVEOM34H4Gsmd+CRlXVpJ86/JcnI8ybIojuO2r7KOz/K5tP3ZBNSN3I0S/xXqGt1KfNhrPEbJm6jawIu6rWUTg8RtAV7MzQNJAiJ4BMtEPQ+MJLQ8mS2YAukFUrOA= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=PQDrc/QK1uTz+UT/bLkeA5yWSgyjE5GBJNy+lKEjKSRtvW+eHjrgfQC6+jBvMM0LkkJjVYQ6efw902s+6v4xJISXkw4thrXwmS9j/xhUwK/T/kWsvwxIvbEX9f6tdeXbjq/lX4QmmVRFslYfQXoeAagYvRSCHlKJCvUoqQEulN8= Received: by 10.114.93.1 with SMTP id q1mr1883599wab.1173209655219; Tue, 06 Mar 2007 11:34:15 -0800 (PST) Received: by 10.114.192.17 with HTTP; Tue, 6 Mar 2007 11:34:15 -0800 (PST) Message-ID: Date: Tue, 6 Mar 2007 11:34:15 -0800 From: "Maksim Yevmenkin" To: "Pietro Cerutti" In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: Cc: freebsd-bluetooth@freebsd.org Subject: Re: which modules are mandatory? X-BeenThere: freebsd-bluetooth@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Using Bluetooth in FreeBSD environments List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 Mar 2007 19:34:17 -0000 Pietro, [...] > I would like to keep my kernel at a minimum, and thus I'd like to know > which parts of it should be built in order for bluetooth to work. ng_ubt(4) - driver for usb bluetooth devices (options NETGRAPH_BLUETOOTH_UBT) ng_bluetooth(4) - generic code (options NETGRAPH_BLUETOOTH) ng_hci(4) - bluetooth host controller interface (hci) (options NETGRAPH_BLUETOOTH_HCI) ng_l2cap(4) - bluetooth link layer control and adaptation protocol (l2cap) (options NETGRAPH_BLUETOOTH_L2CAP) ng_btsocket(4) - bluetooth sockets/rfcomm (options NETGRAPH_BLUETOOTH_SOCKET) all of this of course depends on netgraph(4) framework (options NETGRAPH) thanks, max From owner-freebsd-bluetooth@FreeBSD.ORG Tue Mar 6 19:40:25 2007 Return-Path: X-Original-To: freebsd-bluetooth@freebsd.org Delivered-To: freebsd-bluetooth@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [69.147.83.52]) by hub.freebsd.org (Postfix) with ESMTP id 361E016A407 for ; Tue, 6 Mar 2007 19:40:25 +0000 (UTC) (envelope-from pietro.cerutti@gmail.com) Received: from an-out-0708.google.com (an-out-0708.google.com [209.85.132.248]) by mx1.freebsd.org (Postfix) with ESMTP id E62DB13C4B2 for ; Tue, 6 Mar 2007 19:40:24 +0000 (UTC) (envelope-from pietro.cerutti@gmail.com) Received: by an-out-0708.google.com with SMTP id c24so1745788ana for ; Tue, 06 Mar 2007 11:40:24 -0800 (PST) DKIM-Signature: a=rsa-sha1; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=AIaPUsYmNzMsoHfWj2TIPw7JfVmXplPhSgD5nRJ9RNgKxqAhzNq6+WGl9/vUkYppZqog9XID5Q29YUIJmjVit5d349JPtuLEfdKHT9x4GtxH2TXD6Dh+uEUmHo/xUvF4vu+GBNMATFiiFoK9kdlxtcxfFpigt9rzY9FOKGp6KAE= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=Rw4IJZGo2j7kI9mDujQCI+yqBQ65AwsJJZN6kaxcDZZbADDWHuu5Yhaw5Cmx+T0fDkOJfl9uAkVmwSRDdj/RuHKZopYk/EY2ANWpj7o8z3eXgDJ6hYR+oVyr3F4QZu2tICtQGIUYCPKipYlgADcKBYWOnHymx1Avj2MnOXln408= Received: by 10.100.136.13 with SMTP id j13mr5685818and.1173210023949; Tue, 06 Mar 2007 11:40:23 -0800 (PST) Received: by 10.100.33.5 with HTTP; Tue, 6 Mar 2007 11:40:23 -0800 (PST) Message-ID: Date: Tue, 6 Mar 2007 20:40:23 +0100 From: "Pietro Cerutti" To: "Maksim Yevmenkin" In-Reply-To: MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit Content-Disposition: inline References: Cc: freebsd-bluetooth@freebsd.org Subject: Re: which modules are mandatory? X-BeenThere: freebsd-bluetooth@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Using Bluetooth in FreeBSD environments List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 06 Mar 2007 19:40:25 -0000 On 3/6/07, Maksim Yevmenkin wrote: > Pietro, > > [...] > > > I would like to keep my kernel at a minimum, and thus I'd like to know > > which parts of it should be built in order for bluetooth to work. > > ng_ubt(4) - driver for usb bluetooth devices > (options NETGRAPH_BLUETOOTH_UBT) > > ng_bluetooth(4) - generic code > (options NETGRAPH_BLUETOOTH) > > ng_hci(4) - bluetooth host controller interface (hci) > (options NETGRAPH_BLUETOOTH_HCI) > > ng_l2cap(4) - bluetooth link layer control and adaptation protocol (l2cap) > (options NETGRAPH_BLUETOOTH_L2CAP) > > ng_btsocket(4) - bluetooth sockets/rfcomm > (options NETGRAPH_BLUETOOTH_SOCKET) > They're all included by the /sys/modules/netgraph/bluetooth's Makefile. > all of this of course depends on netgraph(4) framework > (options NETGRAPH) I have this one, too. So, do you see any difference in building those parts by including the relevant OPTIONS in the kernel config file, versus simply make'ing and make install'ing in their subdirectories? At this point, my configuration seems to be ok. Do you see any other problems? > > thanks, Thanx, > max > -- Pietro Cerutti - ASCII Ribbon Campaign - against HTML e-mail and proprietary attachments www.asciiribbon.org