Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp3194427imu; Fri, 23 Nov 2018 23:49:11 -0800 (PST) X-Google-Smtp-Source: AFSGD/XaEv+r5CCKawrtgExvK4ncXVsHE/R2PE+Gdqbww/qAe8QwKf/8XY1wAP2iZICAztShZtm5 X-Received: by 2002:a17:902:4c08:: with SMTP id a8mr19248361ple.74.1543045750968; Fri, 23 Nov 2018 23:49:10 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1543045750; cv=none; d=google.com; s=arc-20160816; b=Qz4txei37eMbwLEUluGbWs9uH/SMm2MmvLwun1ii3Kr5Fm1gTNXeb2S5Ezaa2SN6+i y44kIaz9YXQfije64EaQC/X0WCXNBDvNKQ1ZSR+uSqvFucQRwpVnRZcF0ZRLPYTvvrcF 5UCOjS28jOqFTiScsvpOmy6J3wKXy68BJjdgf53tVTctgM3mrUF2Dr6HcYtGuKvXYP01 FUZTYrDySP84g1k1F+29gw7WqFTIZF8TvsMD/wMhEML/OTBlie3Yc4DP45WSCLhIruE0 FErj6lr5HkHG5W6kgANOaartgv7TYN2tSjAW2/VOG1Ls7n3xxyvemcczqBTKZH0nAadr sptw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date:dkim-signature:dkim-signature; bh=pX6Lv5cP506QxUAXtsqODHmJkIDR6zkzsA3KWQI1Bro=; b=YbDgoEA5wxv/RCZBjys4kL8P03v3vcaIJ3TUWM/79L8tRkJxjrCMerq+ZAGdtqrqq1 6YC3OFYO4pKvWnI2ODx5x3WvlXMCztSWDJK0d5Za1aTSbVDtET/8w/0QvngIrc4eF722 lM8TbzSnGrFVz2kMzE17EHnfm8cxOr7TvXsqZ0Qn/GgOUHtGrk0w50kUUwbVh2QuT1r1 8qs0UC6jxlu4cgygUG2FZj8svE6SyRkzr3+kfOX+q+rNsYVubMH1uhdmrn0R3KQTX/R/ s/i+7/1dkNCcvYP/TP8ScFKMi17dzpnujXHztaFehZmrNLU2A7JE0Vcz/qUmrDdi/7H6 z5ng== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@who-t.net header.s=fm1 header.b=d91khf9a; dkim=pass header.i=@messagingengine.com header.s=fm1 header.b=aDLp7BT0; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id f1si22739504pgq.553.2018.11.23.23.48.57; Fri, 23 Nov 2018 23:49:10 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@who-t.net header.s=fm1 header.b=d91khf9a; dkim=pass header.i=@messagingengine.com header.s=fm1 header.b=aDLp7BT0; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S2439089AbeKWKKd (ORCPT + 99 others); Fri, 23 Nov 2018 05:10:33 -0500 Received: from out4-smtp.messagingengine.com ([66.111.4.28]:51821 "EHLO out4-smtp.messagingengine.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S2439035AbeKWKKc (ORCPT ); Fri, 23 Nov 2018 05:10:32 -0500 Received: from compute3.internal (compute3.nyi.internal [10.202.2.43]) by mailout.nyi.internal (Postfix) with ESMTP id 24F2221EF6; Thu, 22 Nov 2018 18:28:48 -0500 (EST) Received: from mailfrontend1 ([10.202.2.162]) by compute3.internal (MEProxy); Thu, 22 Nov 2018 18:28:48 -0500 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=who-t.net; h= date:from:to:cc:subject:message-id:references:mime-version :content-type:in-reply-to; s=fm1; bh=pX6Lv5cP506QxUAXtsqODHmJkID R6zkzsA3KWQI1Bro=; b=d91khf9a/wpkfvqsVnJeykyyJnhFUQOiVK2cK6TLOj5 ACyhehoYAjlOdH9Zek3eqY2Zj+XyQVDlabW9jbzPgkj5rqxJmaFSDSWYwzl48HgU Ne05R1+5LO0lZs5klJs+Hvs9S/IIK0Oo5wg/DmNDy4c0dyzhel44LRW5CvjMDFNr ySIdrWpoEkL7FHs+ylJ53Dg6mCYrehfScPOK84O3K7DSZcKqyU/3A/AMeOiv+kl2 g+RCPwJQX7u9kfTC2KgrqiC5wkcdLOXBJ4iv9n3OcgowJF7wq+eJyLL5dA1/mq6L OU3twtJP6sUhR42lRAFiSEPg9M0p8d5/8yQ6AkkrbGw== DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d= messagingengine.com; h=cc:content-type:date:from:in-reply-to :message-id:mime-version:references:subject:to:x-me-proxy :x-me-proxy:x-me-sender:x-me-sender:x-sasl-enc; s=fm1; bh=pX6Lv5 cP506QxUAXtsqODHmJkIDR6zkzsA3KWQI1Bro=; b=aDLp7BT0KlgSfxjgKtyS6y +E5bagPZKJ/CxLXF6r89nFBADc3AOlxhkc8hU0RWw/P8Fpq7iNj3rJfUlKpYO79s UxRP4LdkQmIlUMoavoLkNPnB2cM7BgF/U1rru7QvXT+CIW3dnAK0mrF2lIb57voK UglA+ka1k/pQOHu6eDdYayos59/NfIJ8DElII2hWQaa5LxAAo3yp6C8z81EKXeAS Wj4cxI9qwFwEJSwgLD/7tb4iOFW5oxiUuf4uLjTATk0jnnALEyxXTp/PVDS+EeK7 ildq/Ir2373tDR7Fvjy15DkBxB8dKKhzqzJ692K8rMSB+QgeP4f/HaOVJliME6SA == X-ME-Sender: X-ME-Proxy: Received: from jelly (167-179-166-29.a7b3a6.bne.nbn.aussiebb.net [167.179.166.29]) by mail.messagingengine.com (Postfix) with ESMTPA id B1241E48FA; Thu, 22 Nov 2018 18:28:44 -0500 (EST) Date: Fri, 23 Nov 2018 09:28:39 +1000 From: Peter Hutterer To: linux-input@vger.kernel.org Cc: Dmitry Torokhov , Jiri Kosina , Harry Cutts , torvalds@linux-foundation.org, Nestor Lopez Casado , linux-kernel@vger.kernel.org, Benjamin Tissoires Subject: Re: [PATCH 4/8] HID: input: use the Resolution Multiplier for high-resolution scrolling Message-ID: <20181122232839.GA10747@jelly> References: <20181122063409.15816-1-peter.hutterer@who-t.net> <20181122063409.15816-5-peter.hutterer@who-t.net> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20181122063409.15816-5-peter.hutterer@who-t.net> User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Thu, Nov 22, 2018 at 04:34:05PM +1000, Peter Hutterer wrote: > Windows uses a magic number of 120 for a wheel click. High-resolution > scroll wheels are supposed to use a fraction of 120 to signal smaller > scroll steps. This is implemented by the Resolution Multiplier in the > device itself. I scooped a dirty old MS Wireless Mobile Mouse 4000 out of a mate's bin and it breaks this assumption. The resolution multiplier is 16 which isn't an integer fraction of 120. Real multiplier is 7.5. The device sends hi-res values of 4, so it should end up as REL_WHEEL_HI_RES 30. We are getting 28 instead which doesn't add up to a nice 120. Basic assumption: MS uses something other than plain 120 internally. The choices we have now are: - use 1200 or 12000 internally and divide by 10 before sending the final value - just make the evdev API use 1200 or 12000 and let userspace deal with it. much simpler. Any suggestions/comments? Cheers, Peter