Linux Input/HID development
 help / color / mirror / Atom feed
* [PATCH] HID : core : fix hid delimiter local tag parsing.
@ 2013-07-07 16:35 pchavent
  2013-07-12 10:40 ` Jiri Kosina
  0 siblings, 1 reply; 2+ messages in thread
From: pchavent @ 2013-07-07 16:35 UTC (permalink / raw)
  To: jkosina, linux-input; +Cc: paul.chavent

[-- Attachment #1: Type: text/plain, Size: 318 bytes --]

Hi.

When i plug an USB HID device with the DELIMITER tag in its report 
descriptor, the device doesn't load.

The problem comes from the "return 1" in the DELIMITER switch of the 
local tags parsing.

I join a trivial patch that return no error when encounter the 
DELIMITER tag.

Please review it.


Regards.

Paul.

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: 0001-HID-core-fix-hid-delimiter-local-tag-parsing.patch --]
[-- Type: text/x-c; name=0001-HID-core-fix-hid-delimiter-local-tag-parsing.patch, Size: 674 bytes --]

From d34e7be36d6c392578ac9c81614325f9bff9de93 Mon Sep 17 00:00:00 2001
From: Paul Chavent <paul.chavent@onera.fr>
Date: Sun, 7 Jul 2013 17:43:56 +0200
Subject: [PATCH] HID : core : fix hid delimiter local tag parsing.

---
 drivers/hid/hid-core.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/hid/hid-core.c b/drivers/hid/hid-core.c
index 36668d1..1e23ae9 100644
--- a/drivers/hid/hid-core.c
+++ b/drivers/hid/hid-core.c
@@ -450,7 +450,7 @@ static int hid_parser_local(struct hid_parser *parser, struct hid_item *item)
 			}
 			parser->local.delimiter_depth--;
 		}
-		return 1;
+		return 0;
 
 	case HID_LOCAL_ITEM_TAG_USAGE:
 
-- 
1.7.12.1


^ permalink raw reply related	[flat|nested] 2+ messages in thread

end of thread, other threads:[~2013-07-12 10:40 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2013-07-07 16:35 [PATCH] HID : core : fix hid delimiter local tag parsing pchavent
2013-07-12 10:40 ` Jiri Kosina

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox