mouse_cpi.sh: Adjust trackball/touchpad fake-CPI settings for new curves

We changed the mouse accel curves, which are great for mice. For fake
mice, though, we have a hard-coded list of fake CPI settings. These
need adjustment to feel good with the new acceleration curves that
went into R38.

BUG=chromium:415778
TEST=Tested two trackballs with Benson with an old M36 machine vs
ToT. Made sure to get the speeds more or less the same before and
after.

Change-Id: I2b4d5f81584d9731fdc0b9fb28a3ee20b7b15477
Reviewed-on: https://chromium-review.googlesource.com/218931
Reviewed-by: Charles Mooney <charliemooney@chromium.org>
Tested-by: Andrew de los Reyes <adlr@chromium.org>
Commit-Queue: Andrew de los Reyes <adlr@chromium.org>
Commit-Queue: Aviv Keshet <akeshet@chromium.org>
diff --git a/mouse_cpi.sh b/mouse_cpi.sh
index cd132fa..40dbe05 100755
--- a/mouse_cpi.sh
+++ b/mouse_cpi.sh
@@ -18,12 +18,12 @@
   local trackpoint_cpi=400;  # Approximate, since CPI doesn't exactly apply
   case "$vp" in
     "0002:000a") cpi=$trackpoint_cpi;;  # PS/2 IBM Trackpoint
-    "045e:0024") cpi=400;;  # Microsoft Corp. Trackball Explorer*
+    "045e:0024") cpi=800;;  # Microsoft Corp. Trackball Explorer*
     "045e:0040") cpi=416;;  # Microsoft Corp. Wheel Mouse Optical
     "0461:4d22") cpi=474;;  # Standard Dell
-    "046d:1028") cpi=600;;  # M570 trackball[u]
-    "046d:400e") cpi=400;;  # K400 touchpad[u]
-    "046d:4024") cpi=400;;  # K400r touchpad[u]
+    "046d:1028") cpi=1200;;  # M570 trackball[u]
+    "046d:400e") cpi=800;;  # K400 touchpad[u]
+    "046d:4024") cpi=800;;  # K400r touchpad[u]
     "046d:c00f") cpi=385;;  # Logitech MouseMan Traveler/Mobile
     "046d:c00"*) cpi=385;;  # Old Logitech Mice (copying 0xc00f setting)
     "046d:c014") cpi=425;;  # HP branded "Logitech Optical USB Mouse"
@@ -33,28 +33,28 @@
     "046d:c03e") cpi=464;;  # Logitech Premium Optical Wheel Mouse (M-BT58)
     "046d:c077") cpi=580;;  # HP branded "Logitech USB Optical Mouse"
     # According to http://www.linux-usb.org/usb.ids , these are 4 trackballs:
-    "046d:c40"*) cpi=300;;  # Logitech Trackballs*
-    "046d:c508") cpi=300;;  # Cordless Trackball
-    "047d:1002") cpi=300;;  # Kensington Turbo Mouse Pro (trackball)*
-    "047d:1003") cpi=300;;  # Kensington Orbit TrackBall (trackball)*
-    "047d:1005") cpi=300;;  # Kensington TurboBall (trackball)*
-    "047d:1006") cpi=300;;  # Kensington TurboRing (trackball)*
-    "047d:1009") cpi=300;;  # Kensington Orbit TrackBall for Mac (trackball)*
-    "047d:1020") cpi=300;;  # Kensington Expert Mouse (trackball)*
-    "047d:2041") cpi=300;;  # Kensington SlimBlade Trackball (trackball)*
-    "04d9:2519") cpi=400;;  # FAVI Wireless Keyboard (TouchPad)*
+    "046d:c40"*) cpi=600;;  # Logitech Trackballs*
+    "046d:c508") cpi=600;;  # Cordless Trackball
+    "047d:1002") cpi=600;;  # Kensington Turbo Mouse Pro (trackball)*
+    "047d:1003") cpi=600;;  # Kensington Orbit TrackBall (trackball)*
+    "047d:1005") cpi=600;;  # Kensington TurboBall (trackball)*
+    "047d:1006") cpi=600;;  # Kensington TurboRing (trackball)*
+    "047d:1009") cpi=600;;  # Kensington Orbit TrackBall for Mac (trackball)*
+    "047d:1020") cpi=600;;  # Kensington Expert Mouse (trackball)*
+    "047d:2041") cpi=600;;  # Kensington SlimBlade Trackball (trackball)*
+    "04d9:2519") cpi=800;;  # FAVI Wireless Keyboard (TouchPad)*
     "05ac:0304") cpi=400;;  # Apple USB Optical Mouse (Mighty Mouse)
     "05ac:030c") cpi=400;;  # Apple BT Optical Mouse (Mighty Mouse)
     "05ac:030d") cpi=1780;; # Apple magicmouse (BT)
     "05ac:"*)    cpi=373;;  # Apple mice (other)
     "06cb:0009") cpi=$trackpoint_cpi;;  # USB IBM Trackpoint
-    "0a5c:8502") cpi=400;;  # FAVI Wireless Keyboard (TouchPad), Bluetooth*
-    "0c45:7000") cpi=400;;  # FAVI Entertainment Wireless Keyboard (TouchPad)*
+    "0a5c:8502") cpi=800;;  # FAVI Wireless Keyboard (TouchPad), Bluetooth*
+    "0c45:7000") cpi=800;;  # FAVI Entertainment Wireless Keyboard (TouchPad)*
     "1532:0016") cpi=1714;; # Razer USA, Ltd DeathAdder RZ01-0015
     "17ef:6009") cpi=$trackpoint_cpi;;  # Lenovo ThinkPad Keyboard w/ TrackPoint
-    "17ef:6014") cpi=400;;  # Lenovo N5901 multimedia keyboard/trackball*
-    "17ef:602b") cpi=400;;  # Lenovo N5902 multimedia keyboard/OFN*
-    "1997:0409") cpi=400;;  # Riitek Rii Mote i6 (TouchPad)*
+    "17ef:6014") cpi=800;;  # Lenovo N5901 multimedia keyboard/trackball*
+    "17ef:602b") cpi=800;;  # Lenovo N5902 multimedia keyboard/OFN*
+    "1997:0409") cpi=800;;  # Riitek Rii Mote i6 (TouchPad)*
     "413c:3012") cpi=502;;  # Dell Computer Corp. Optical Wheel Mouse
   esac
   # * Trackball/touchpad measurements are approximate