]> git.baikalelectronics.ru Git - kernel.git/commit
Input: synaptics-rmi4 - clean up F30 implementation
authorDmitry Torokhov <dmitry.torokhov@gmail.com>
Wed, 8 Feb 2017 20:02:07 +0000 (12:02 -0800)
committerDmitry Torokhov <dmitry.torokhov@gmail.com>
Thu, 9 Feb 2017 21:01:33 +0000 (13:01 -0800)
commitca003346b377c3b608c38b305dec3bc94d5075af
treeec769b5cce72393a5a6cbfa30750123ff6bd606b
parent2726def47cf7457529a2467d2e526aa146d36030
Input: synaptics-rmi4 - clean up F30 implementation

This patch does several cleanup changes to F30 code

- switch to using BIT() macro
- use DIV_ROUND_UP() where appropriate
- factor out code setting up and reporting buttons
- use single loop when reporting buttons: arithmetic is cheap compared to
  conditionals and associated branch misprediction.

Tested-By: Benjamin Tissoires <benjamin.tissoires@redhat.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
drivers/input/rmi4/rmi_f30.c