Skip to contentSkip to conversation

Bluetooth: Expose hardware error code as debugfs entry

PATCH Applied Marcel Holtmann 2 participants 2 messages Feb 1, 2015

Subsystems (2)
lore
Share & tools
lore

Marcel Holtmann

author maintainer
#0 lore raw

PATCH 1/1 Bluetooth: Expose hardware error code as debugfs entry

When the Hardware Error event is send by the controller, the Bluetooth core stores the error code. Expose it via debugfs so it can be retrieved later on.

---
 net/bluetooth/hci_debugfs.c | 3 +++
 1 file changed, 3 insertions(+)
net/bluetooth/hci_debugfs.c +3 -0
index 2272384755d5..5353f6ec8d68 100644
@@ -256,6 +256,9 @@ void hci_debugfs_create_common(struct hci_dev *hdev)
 			   &hdev->manufacturer);
 	debugfs_create_u8("hci_version", 0444, hdev->debugfs, &hdev->hci_ver);
 	debugfs_create_u16("hci_revision", 0444, hdev->debugfs, &hdev->hci_rev);
+	debugfs_create_u8("hardware_error", 0444, hdev->debugfs,
+			  &hdev->hw_error_code);
+
 	debugfs_create_file("device_list", 0444, hdev->debugfs, hdev,
 			    &device_list_fops);
 	debugfs_create_file("blacklist", 0444, hdev->debugfs, hdev,
Signature · 1 line
2.1.0
#1 lore raw

Hi Marcel,

Quoted 8 lines · Marcel Holtmann

When the Hardware Error event is send by the controller, the Bluetooth core stores the error code. Expose it via debugfs so it can be retrieved later on.

---
 net/bluetooth/hci_debugfs.c | 3 +++
 1 file changed, 3 insertions(+)

Applied to bluetooth-next. Thanks.

Johan