Thread (13 messages) 13 messages, 5 authors, 2008-11-14

Re: [PATCH] HID: don't grab devices with no input

From: Andi Kleen <hidden>
Date: 2008-11-13 22:12:50
Also in: lkml

On Thu, Nov 13, 2008 at 11:05:09PM +0100, Jiri Slaby wrote:
On 11/13/2008 10:37 PM, Alan Stern wrote:
quoted
quoted
+	for (n = 0; n < interface->desc.bNumEndpoints; n++)
+		if (usb_endpoint_dir_in(&interface->endpoint[n].desc))
+			has_in++;
+	if (!has_in) {
+		dev_err(&intf->dev, "couldn't find an input interrupt "
+				"endpoint");
+		return -ENODEV;
+	}
+
Do you want to use usb_endpoint_is_int_in() instead?  It matches the 
error message more closely.
Yes, good catch, thanks.
Should I test it with that change or the original version?

-Andi

-- 
ak@linux.intel.com
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help