[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Message-ID: <alpine.LNX.2.00.1603181734540.3656@cbobk.fhfr.pm>
Date: Fri, 18 Mar 2016 17:37:43 +0100 (CET)
From: Jiri Kosina <jikos@...nel.org>
To: David Herrmann <dh.herrmann@...il.com>
cc: Cyan Ogilvie <cyan.ogilvie@...il.com>,
David Herrmann <dh.herrmann@...glemail.com>,
Benjamin Tissoires <benjamin.tissoires@...hat.com>,
"open list:HID CORE LAYER" <linux-input@...r.kernel.org>,
linux-kernel <linux-kernel@...r.kernel.org>
Subject: Re: [PATCH] HID: wiimote: Fix wiimote mp scale linearization
On Thu, 17 Mar 2016, David Herrmann wrote:
> > @@ -2070,15 +2072,15 @@ static void wiimod_mp_in_mp(struct wiimote_data *wdata, const __u8 *ext)
> > z -= 8192;
> >
> > if (!(ext[3] & 0x02))
> > - x *= 18;
> > + x = (x * 2000 * 9) / 440;
> > else
> > x *= 9;
> > if (!(ext[4] & 0x02))
> > - y *= 18;
> > + y = (y * 2000 * 9) / 440;
> > else
> > y *= 9;
> > if (!(ext[3] & 0x01))
> > - z *= 18;
> > + z = (z * 2000 * 9) / 440;
>
> So 2000/440 ~= 4.5, so this is exactly what the initial comment said.
> Patch looks good to me:
>
> Reviewed-by: David Herrmann <dh.herrmann@...il.com>
Appplied to for-4.6/upstream-fixes. Thanks,
--
Jiri Kosina
SUSE Labs
Powered by blists - more mailing lists