Lines Matching defs:dev
11 static void bt_link_release(struct device *dev)
13 struct hci_conn *conn = to_hci_conn(dev);
27 static int __match_tty(struct device *dev, void *data)
29 return !strncmp(dev_name(dev), "rfcomm", 6);
38 conn->dev.type = &bt_link;
39 conn->dev.class = bt_class;
40 conn->dev.parent = &hdev->dev;
42 device_initialize(&conn->dev);
51 if (device_is_registered(&conn->dev))
54 dev_set_name(&conn->dev, "%s:%d", hdev->name, conn->handle);
56 if (device_add(&conn->dev) < 0)
66 if (!device_is_registered(&conn->dev)) {
70 put_device(&conn->dev);
75 struct device *dev;
77 dev = device_find_child(&conn->dev, NULL, __match_tty);
78 if (!dev)
80 device_move(dev, NULL, DPM_ORDER_DEV_LAST);
81 put_device(dev);
84 device_unregister(&conn->dev);
87 static void bt_host_release(struct device *dev)
89 struct hci_dev *hdev = to_hci_dev(dev);
104 struct device *dev = &hdev->dev;
106 dev->type = &bt_host;
107 dev->class = bt_class;
110 device_initialize(dev);