summaryrefslogtreecommitdiffstats
path: root/net/bluetooth/hci_sysfs.c
Commit message (Collapse)AuthorAgeFilesLines
* Bluetooth: Fix format arguments warningMarcel Holtmann2008-11-301-1/+1
| | | | | | | | | | | | Newer GCC versions are a little bit picky about how to deal with format arguments: net/bluetooth/hci_sysfs.c: In function ‘hci_register_sysfs’: net/bluetooth/hci_sysfs.c:418: warning: format not a string literal and no format arguments It is simple enough to fix and makes the compiler happy. Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* Bluetooth: Enable per-module dynamic debug messagesMarcel Holtmann2008-11-301-5/+0
| | | | | | | | | | | With the introduction of CONFIG_DYNAMIC_PRINTK_DEBUG it is possible to allow debugging without having to recompile the kernel. This patch turns all BT_DBG() calls into pr_debug() to support dynamic debug messages. As a side effect all CONFIG_BT_*_DEBUG statements are now removed and some broken debug entries have been fixed. Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* net: struct device - replace bus_id with dev_name(), dev_set_name()Kay Sievers2008-11-101-4/+3
| | | | | | | Acked-by: Marcel Holtmann <marcel@holtmann.org> Acked-by: Greg Kroah-Hartman <gregkh@suse.de> Signed-off-by: Kay Sievers <kay.sievers@vrfy.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* [Bluetooth] Fix userspace breakage due missing class linksMarcel Holtmann2008-08-181-187/+189
| | | | | | | | | | | | | | | The Bluetooth adapters and connections are best presented via a class in sysfs. The removal of the links inside the Bluetooth class broke assumptions by userspace programs on how to find attached adapters. This patch creates adapters and connections as part of the Bluetooth class, but it uses different device types to distinguish them. The userspace programs can now easily navigate in the sysfs device tree. The unused platform device and bus have been removed to keep the code simple and clean. Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* bluetooth: remove improper bluetooth class symlinks.Greg Kroah-Hartman2008-07-211-7/+0
| | | | | | | | | | | | Don't create symlinks in a class to a device that is not owned by the class. If the bluetooth subsystem really wants to point to all of the devices it controls, it needs to create real devices, not fake symlinks. Cc: Maxim Krasnyansky <maxk@qualcomm.com> Cc: Kay Sievers <kay.sievers@vrfy.org> Acked-by: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* [Bluetooth] Use a more unique bus name for connectionsMarcel Holtmann2008-07-141-6/+2
| | | | | | | | | | | | | | When attaching Bluetooth low-level connections to the bus, the bus name is constructed from the remote address since at that time the connection handle is not assigned yet. This has worked so far, but also caused a lot of troubles. It is better to postpone the creation of the sysfs entry to the time when the connection actually has been established and then use its connection handle as unique identifier. This also fixes the case where two different adapters try to connect to the same remote device. Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* [Bluetooth] Export remote Simple Pairing mode via sysfsMarcel Holtmann2008-07-141-4/+19
| | | | | | | | Since the remote Simple Pairing mode is stored together with the inquiry cache, it makes sense to show it together with the other information. Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* bluetooth: do not move child device other than rfcommDave Young2008-02-181-7/+6
| | | | | | | | hci conn child devices other than rfcomm tty should not be moved here. This is my lost, thanks for Barnaby's reporting and testing. Signed-off-by: Dave Young <hidave.darkstar@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* bluetooth: put hci dev after del connDave Young2008-02-181-0/+3
| | | | | | | Move hci_dev_put to del_conn to avoid hci dev going away before hci conn. Signed-off-by: Dave Young <hidave.darkstar@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* [BLUETOOTH] hci_sysfs.c: Kill build warning.David S. Miller2008-02-181-2/+6
| | | | | | | net/bluetooth/hci_sysfs.c: In function ‘del_conn’: net/bluetooth/hci_sysfs.c:339: warning: suggest parentheses around assignment used as truth value Signed-off-by: David S. Miller <davem@davemloft.net>
* [BLUETOOTH]: Fix bugs in previous conn add/del workqueue changes.Dave Young2008-01-311-2/+6
| | | | | | | | Jens Axboe noticed that we were queueing &conn->work on both btaddconn and keventd_wq. Signed-off-by: Dave Young <hidave.darkstar@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* [BLUETOOTH]: Add conn add/del workqueues to avoid connection fail.Dave Young2008-01-311-11/+37
| | | | | | | | | | | | The bluetooth hci_conn sysfs add/del executed in the default workqueue. If the del_conn is executed after the new add_conn with same target, add_conn will failed with warning of "same kobject name". Here add btaddconn & btdelconn workqueues, flush the btdelconn workqueue in the add_conn function to avoid the issue. Signed-off-by: Dave Young <hidave.darkstar@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* [BLUETOOTH]: Move children of connection device to NULL before connection down.Dave Young2008-01-231-0/+17
| | | | | | | | | | | | The rfcomm tty device will possibly retain even when conn is down, and sysfs doesn't support zombie device moving, so this patch move the tty device before conn device is destroyed. For the bug refered please see : http://lkml.org/lkml/2007/12/28/87 Signed-off-by: Dave Young <hidave.darkstar@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* [BLUETOOTH]: put_device before device_del fixDave Young2007-12-291-0/+1
| | | | | | | | Because of workqueue delay, the put_device could be called before device_del, so move it to del_conn. Signed-off-by: Dave Young <hidave.darkstar@gmail.com> Signed-off-by: David S. Miller <davem@davemloft.net>
* [Bluetooth] Switch from OGF+OCF to using only opcodesMarcel Holtmann2007-10-221-0/+37
| | | | | | | | | | | | The Bluetooth HCI commands are divided into logical OGF groups for easier identification of their purposes. While this still makes sense for the written specification, its makes the code only more complex and harder to read. So instead of using separate OGF and OCF values to identify the commands, use a common 16-bit opcode that combines both values. As a side effect this also reduces the complexity of OGF and OCF calculations during command header parsing. Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* Fix bluetooth HCI sysfs compileLinus Torvalds2007-05-071-2/+2
| | | | | | | More fallout from the removal of "struct subsystem" from the core device model. Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
* [Bluetooth] Attach host adapters to the Bluetooth busMarcel Holtmann2007-05-051-1/+8
| | | | | | | | | | | The Bluetooth host adapters are attached to the Bluetooth class and the low-level connections are children of these class devices. Having class devices as parent of bus devices breaks a lot of reasonable assumptions about sysfs. The host adapters should be attached to the Bluetooth bus to simplify the dependency resolving. For compatibility an additional symlink from the Bluetooth class will be used. Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* [Bluetooth] Handle device registration failuresMarcel Holtmann2007-01-091-1/+6
| | | | | | | | In the case the device registration for a new Bluetooth low-level connection fails there is no need to unregister it when the temporary data structure has been removed. Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* WorkStruct: make allyesconfigDavid Howells2006-11-221-6/+6
| | | | | | Fix up for make allyesconfig. Signed-Off-By: David Howells <dhowells@redhat.com>
* [Bluetooth] Attach low-level connections to the Bluetooth busMarcel Holtmann2006-11-211-1/+3
| | | | | | | | To receive uvents for the low-level ACL and SCO links, they must be assigned to a subsystem. It is enough to attach them to the already established Bluetooth bus. Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* [Bluetooth] Make use of virtual devices treeMarcel Holtmann2006-10-151-5/+1
| | | | | | | | The Bluetooth subsystem currently uses a platform device for devices with no parent. It is a better idea to use the new virtual devices tree for these. Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* [Bluetooth] Handle return values from driver core functionsMarcel Holtmann2006-10-151-3/+8
| | | | | | | Some return values of the driver core register and create functions are not handled and so might cause unexpected problems. Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* [Bluetooth]: Fix section mismatch of bt_sysfs_cleanup()Arnaud Patard2006-09-281-1/+1
| | | | | | | | | | The bt_sysfs_cleanup() is marked with __exit attribute, but it will be called from an __init function in the error case. So the __exit attribute must be removed. Signed-off-by: Arnaud Patard <arnaud.patard@rtp-net.org> Signed-off-by: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* [Bluetooth] Read local version information on device initMarcel Holtmann2006-09-281-0/+24
| | | | | | | | The local version information are needed to identify certain feature sets of devices. They must be read on device init and stored for later use. It is also possible to access them through the device model. Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* [Bluetooth] Add HCI device identifier for SDIO cardsMarcel Holtmann2006-09-281-1/+3
| | | | | | | This patch assigns the next free HCI device identifier to Bluetooth devices based on the SDIO interface. Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* [Bluetooth] Integrate low-level connections into the driver modelMarcel Holtmann2006-09-281-2/+77
| | | | | | | | This patch integrates the low-level connections (ACL and SCO) into the driver model. Every connection is presented as device with the parent set to its host controller device. Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* [Bluetooth] Remove unused host controller attributesMarcel Holtmann2006-09-281-17/+19
| | | | | | | This patch removes the unused device attribute entries for the Bluetooth host controllers. Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* [Bluetooth] Use real devices for host controllersMarcel Holtmann2006-07-031-87/+65
| | | | | | | | This patch converts the Bluetooth class devices into real devices. The Bluetooth class is kept and the driver core provides the appropriate symlinks for backward compatibility. Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* [Bluetooth] Add platform device for virtual and serial devicesMarcel Holtmann2006-07-031-2/+37
| | | | | | | This patch adds a generic Bluetooth platform device that can be used as parent device by virtual and serial devices. Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* [Bluetooth] Add automatic sniff mode supportMarcel Holtmann2006-07-031-0/+88
| | | | | | | | This patch introduces the automatic sniff mode feature. This allows the host to switch idle connections into sniff mode to safe power. Signed-off-by: Ulisses Furquim <ulissesf@gmail.com> Signed-off-by: Marcel Holtmann <marcel@holtmann.org>
* Remove obsolete #include <linux/config.h>Jörn Engel2006-06-301-1/+0
| | | | | Signed-off-by: Jörn Engel <joern@wohnheim.fh-wedel.de> Signed-off-by: Adrian Bunk <bunk@stusta.de>
* [PATCH] driver core: replace "hotplug" by "uevent"Kay Sievers2006-01-041-2/+2
| | | | | | | | | Leave the overloaded "hotplug" word to susbsystems which are handling real devices. The driver core does not "plug" anything, it just exports the state to userspace and generates events. Signed-off-by: Kay Sievers <kay.sievers@suse.de> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
* [Bluetooth]: Remove the usage of /proc completelyMarcel Holtmann2005-11-081-1/+3
| | | | | | | | | This patch removes all relics of the /proc usage from the Bluetooth subsystem core and its upper layers. All the previous information are now available via /sys/class/bluetooth through appropriate functions. Signed-off-by: Marcel Holtmann <marcel@holtmann.org> Signed-off-by: David S. Miller <davem@davemloft.net>
* Linux-2.6.12-rc2v2.6.12-rc2Linus Torvalds2005-04-161-0/+153
Initial git repository build. I'm not bothering with the full history, even though we have it. We can create a separate "historical" git archive of that later if we want to, and in the meantime it's about 3.2GB when imported into git - space that would just make the early git days unnecessarily complicated, when we don't have a lot of good infrastructure for it. Let it rip!
OpenPOWER on IntegriCloud