Input: alps - process_bitmap: add alps_get_bitmap_points() helper function

Factor out the identical code for getting the bitmap points for x and y into
a helper function.

Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
This commit is contained in:
Hans de Goede
2014-07-25 22:38:51 -07:00
committed by Dmitry Torokhov
parent 40e8f53bff
commit 036e6c7b54
2 changed files with 35 additions and 45 deletions

View File

@@ -65,6 +65,11 @@ struct alps_nibble_commands {
unsigned char data;
};
struct alps_bitmap_point {
int start_bit;
int num_bits;
};
/**
* struct alps_fields - decoded version of the report packet
* @x_map: Bitmap of active X positions for MT.