Thread (24 messages) flat view 24 messages, 4 authors, 2014-12-23

bluetooth: Add hci_h4p driver

From: Pavel Machek <hidden>
Date: 2014-12-18 19:32:00
Also in: linux-bluetooth, linux-omap, lkml

Hi!
quoted
+	h4p_simple_send_frame(info, skb);
+
+	if (!wait_for_completion_interruptible_timeout(&info->init_completion,
+						       msecs_to_jiffies(1000))) {
+		printk("h4p: negotiation did not return\n");
Memory leak in the error case
And memory leak in the normal case, too, no? Fixed.
quoted
+	case H4_ACL_PKT:
+		acl_hdr = (struct hci_acl_hdr *)skb->data;
+		retval = le16_to_cpu(acl_hdr->dlen);
Could you explain, why only this needs endianness converted?
This one is 16 bit, the others I checked are 8 bit.
quoted
+static void h4p_rx_tasklet(unsigned long data)
+{
+	u8 byte;
+	struct h4p_info *info = (struct h4p_info *)data;
+
+	BT_DBG("tasklet woke up");
+	BT_DBG("rx_tasklet woke up");
Isn't this a bit redundant?
Fixed.
quoted
+	struct sk_buff *skb;
+	struct h4p_info *info = (struct h4p_info *)data;
+
+	BT_DBG("tasklet woke up");
+	BT_DBG("tx_tasklet woke up");
Doubled?
Fixed.

Thanks,
									Pavel

-- 
(english) http://www.livejournal.com/~pavelmachek
(cesky, pictures) http://atrey.karlin.mff.cuni.cz/~pavel/picture/horses/blog.html
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help