From owner-freebsd-bluetooth@FreeBSD.ORG Wed Feb 15 14:52:27 2006 Return-Path: X-Original-To: freebsd-bluetooth@freebsd.org Delivered-To: freebsd-bluetooth@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id F27A916A420; Wed, 15 Feb 2006 14:52:26 +0000 (GMT) (envelope-from markus@brueffer.de) Received: from mailout10.sul.t-online.com (mailout10.sul.t-online.com [194.25.134.21]) by mx1.FreeBSD.org (Postfix) with ESMTP id 4AB3243D45; Wed, 15 Feb 2006 14:52:26 +0000 (GMT) (envelope-from markus@brueffer.de) Received: from fwd26.aul.t-online.de by mailout10.sul.t-online.com with smtp id 1F9O12-0001Cw-03; Wed, 15 Feb 2006 15:52:24 +0100 Received: from ramses.kicks-ass.net (ZYd41cZEweuVy6PjRmMQyZzLNdiEYJGo0eEKp7WKAFNgUweccyfhUw@[80.143.250.85]) by fwd26.sul.t-online.de with esmtp id 1F9O0x-0yeNo80; Wed, 15 Feb 2006 15:52:19 +0100 Received: from localhost (dslb-084-061-054-045.pools.arcor-ip.net [84.61.54.45]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by ramses.kicks-ass.net (Postfix) with ESMTP id 25A75B833; Wed, 15 Feb 2006 15:52:22 +0100 (CET) From: Markus Brueffer To: freebsd-usb@freebsd.org Date: Wed, 15 Feb 2006 15:51:20 +0100 User-Agent: KMail/1.9.1 MIME-Version: 1.0 Content-Type: multipart/signed; boundary="nextPart1515827.EJBHUV7QcL"; protocol="application/pgp-signature"; micalg=pgp-sha1 Content-Transfer-Encoding: 7bit Message-Id: <200602151551.27188.markus@brueffer.de> X-ID: ZYd41cZEweuVy6PjRmMQyZzLNdiEYJGo0eEKp7WKAFNgUweccyfhUw@t-dialin.net X-TOI-MSGID: 04423a6b-709a-402f-90d6-8b764d0a1eab Cc: freebsd-bluetooth@freebsd.org Subject: [Patch] Fix collection entry parsing in libusbhid X-BeenThere: freebsd-bluetooth@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Using Bluetooth in FreeBSD environments List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 15 Feb 2006 14:52:27 -0000 --nextPart1515827.EJBHUV7QcL Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Content-Disposition: inline Hi, here is a patch for libusbhid which fixes parsing of collection entries if = the=20 collection has only non-variable Input/Output/Feature entries: http://people.freebsd.org/~markus/bt/parse.c.diff The problem ist that the output of collection pages has to be deferred unti= l=20 the report id is known. Without the patch, deferred collection pages are on= ly=20 reported correctly if variable Input/Output/Feature entries are present. The effect can be seen here (output of the hid descriptor dump of a Logitec= h=20 MX5000 keyboard using bthidcontrol): http://people.freebsd.org/~markus/bt/mx5000_before.txt http://people.freebsd.org/~markus/bt/mx5000_after.txt =46urthermore I have removed the loop in REPORT_SAVED_COLL. If someone know= s why=20 it was there in the first place, please share your wisdom :) Third change is the removal of REPORT_SAVED_COLL if the end of a collection= is=20 reached. All collection entries should have been reported by then. Ok to commit? Markus =2D-=20 Markus Brueffer =A0 =A0| GPG-Key: http://people.FreeBSD.org/~markus/markus.= asc markus@brueffer.de | FP: 3F9B EBE8 F290 E5CC 1447 8760 D48D 1072 78F8 A8D4 markus@FreeBSD.org | FreeBSD: The Power to Serve! --nextPart1515827.EJBHUV7QcL Content-Type: application/pgp-signature -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.2 (FreeBSD) iD8DBQBD8z/v1I0Qcnj4qNQRAkjSAKDCBidrz0FyH8W6P16KEix76s5A0wCfXMlQ 9AOrEWxkT9hLGdKcoAAisRQ= =Q0xs -----END PGP SIGNATURE----- --nextPart1515827.EJBHUV7QcL--