From patchwork Fri Aug 26 11:27:12 2011 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: David Herrmann X-Patchwork-Id: 1102062 X-Patchwork-Delegate: jikos@jikos.cz Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by demeter2.kernel.org (8.14.4/8.14.4) with ESMTP id p7QBRa7w012281 for ; Fri, 26 Aug 2011 11:27:36 GMT Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751929Ab1HZL1e (ORCPT ); Fri, 26 Aug 2011 07:27:34 -0400 Received: from mail-fx0-f46.google.com ([209.85.161.46]:45306 "EHLO mail-fx0-f46.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1750917Ab1HZL1c (ORCPT ); Fri, 26 Aug 2011 07:27:32 -0400 Received: by fxh19 with SMTP id 19so2460956fxh.19 for ; Fri, 26 Aug 2011 04:27:31 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=googlemail.com; s=gamma; h=from:to:cc:subject:date:message-id:x-mailer; bh=vvteq053D2d2jSO8uh3uhMiTR19YfIl9FMY/fai0xMw=; b=MnX5MZf/gQrrFHpaUbOdg6sp49OSv5fD4ysqX9NpSP3LJ/nhfCTn4BxVfhRmbuPcux RpwIDjMClFg2Xmho/qMR68jj3Y0x0hxEVlkk9ObShSGvN7JCWORyS6uWzfWlJczFFWqV uRX+ZdYRkhKCRrX/4Yu2n22EAIFU67ENDrvQI= Received: by 10.223.62.134 with SMTP id x6mr1474112fah.39.1314358051521; Fri, 26 Aug 2011 04:27:31 -0700 (PDT) Received: from localhost.localdomain (stgt-5f70d8ee.pool.mediaWays.net [95.112.216.238]) by mx.google.com with ESMTPS id c7sm1247224fac.36.2011.08.26.04.27.29 (version=TLSv1/SSLv3 cipher=OTHER); Fri, 26 Aug 2011 04:27:30 -0700 (PDT) From: David Herrmann To: linux-bluetooth@vger.kernel.org Cc: padovan@profusion.mobi, linux-input@vger.kernel.org, David Herrmann Subject: [PATCH] Bluetooth: hidp: Add support for NO_INIT_REPORTS quirk Date: Fri, 26 Aug 2011 13:27:12 +0200 Message-Id: <1314358032-23513-1-git-send-email-dh.herrmann@googlemail.com> X-Mailer: git-send-email 1.7.6 Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org X-Greylist: IP, sender and recipient auto-whitelisted, not delayed by milter-greylist-4.2.6 (demeter2.kernel.org [140.211.167.43]); Fri, 26 Aug 2011 11:27:36 +0000 (UTC) During setup the host initializes all HID reports. Some devices do not support this. If this quirk is set, we skip the initialization. See also usbhid_init_reports() for this quirk. Signed-off-by: David Herrmann --- net/bluetooth/hidp/core.c | 3 +++ 1 files changed, 3 insertions(+), 0 deletions(-) diff --git a/net/bluetooth/hidp/core.c b/net/bluetooth/hidp/core.c index 43b4c2d..4423e3a 100644 --- a/net/bluetooth/hidp/core.c +++ b/net/bluetooth/hidp/core.c @@ -870,6 +870,9 @@ static int hidp_start(struct hid_device *hid) struct hidp_session *session = hid->driver_data; struct hid_report *report; + if (hid->quirks & HID_QUIRK_NO_INIT_REPORTS) + return 0; + list_for_each_entry(report, &hid->report_enum[HID_INPUT_REPORT]. report_list, list) hidp_send_report(session, report);