hc
2024-02-20 102a0743326a03cd1a1202ceda21e175b7d3575c
kernel/drivers/input/rmi4/rmi_f12.c
....@@ -1,9 +1,6 @@
1
+// SPDX-License-Identifier: GPL-2.0-only
12 /*
23 * Copyright (c) 2012-2016 Synaptics Incorporated
3
- *
4
- * This program is free software; you can redistribute it and/or modify it
5
- * under the terms of the GNU General Public License version 2 as published by
6
- * the Free Software Foundation.
74 */
85 #include <linux/input.h>
96 #include <linux/input/mt.h>
....@@ -76,7 +73,6 @@
7673 int pitch_y = 0;
7774 int rx_receivers = 0;
7875 int tx_receivers = 0;
79
- int sensor_flags = 0;
8076
8177 item = rmi_get_register_desc_item(&f12->control_reg_desc, 8);
8278 if (!item) {
....@@ -132,10 +128,9 @@
132128 offset += 2;
133129 }
134130
135
- if (rmi_register_desc_has_subpacket(item, 4)) {
136
- sensor_flags = buf[offset];
131
+ /* Skip over sensor flags */
132
+ if (rmi_register_desc_has_subpacket(item, 4))
137133 offset += 1;
138
- }
139134
140135 sensor->x_mm = (pitch_x * rx_receivers) >> 12;
141136 sensor->y_mm = (pitch_y * tx_receivers) >> 12;