lkml.org 
[lkml]   [2010]   [Mar]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
SubjectRe: [PATCH 1/1] integer overflow issue in 'appletouch' driver
From
Date
On Fri, 2010-03-05 at 11:47 -0800, Vadim Zaliva wrote:
> This small patch is fixing an integer overflow issue in 'appletouch' driver.
>
> In particular, reading data from Geyser 2 touchpads used on post Oct
> 2005 Apple PowerBooks the driver was casting X and Y coordinates
> values to 'signed char'. Testing on one of such PowerBooks I have
> noticed that touchpad always generates positive values, but some of
> them are greater that 127, and thus, when cast to 'signed char' being
> interpreted as a negative.
>
> Such bigger values have been observed infrequently, closer to the
> edges of a touchpad, so the problem was not very visible.
> Nevertheless, the patch would potentially improve touchpad
> driver accuracy.

Hmm, you're probably right, and I cannot test with my powerbook as I'm
about to leave on travel and it's at my parents.

johannes



\
 
 \ /
  Last update: 2010-03-08 08:45    [W:0.098 / U:0.064 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site