lkml.org 
[lkml]   [2003]   [Oct]   [27]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] PS/2 mouse rate setting

On Mon, 27 Oct 2003, Andi Kleen wrote:
> static void psmouse_set_rate(struct psmouse *psmouse)
> {
> - unsigned char rates[] = { 200, 100, 80, 60, 40, 20, 10, 0 };
> + static unsigned char rates[] = { 200, 100, 80, 60, 40, 20, 10, 0 };
> int i = 0;
>
> - while (rates[i] > psmouse_rate) i++;
> + if (!psmouse_rate)
> + return;
> +
> + while (rates[i] >= psmouse_rate) i++;

Ok, explain that ">=" to me. It looked more right the way it used to be.

In particular, if you want a rate of 200, you will now make "i" be _1_, so
we send a command to set the rate to 100.

Which makes no sense.

Linus

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2009-11-18 23:46    [W:0.093 / U:1.472 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site