diff options
| author | Dmitry Torokhov <dmitry.torokhov@gmail.com> | 2017-08-01 15:38:01 -0700 |
|---|---|---|
| committer | Gerrit - the friendly Code Review server <code-review@localhost> | 2020-12-19 02:17:41 -0800 |
| commit | e2a50d2caa289793db3aa2a2e94b00b8a57e352d (patch) | |
| tree | eff05b666c6fc6a37edb57b06422fb7313a09d2b /include | |
| parent | 64c3aa489100705188fa8c73ad671b899803a344 (diff) | |
UPSTREAM: HID: input: map digitizer battery usage
We already mapped battery strength reports from the generic device
control page, but we did not update capacity from input reports, nor we
mapped the battery strength report from the digitizer page, so let's
implement this now.
Batteries driven by the input reports will now start in "unknown" state,
and will get updated once we receive first report containing battery
strength from the device.
Signed-off-by: Dmitry Torokhov <dmitry.torokhov@gmail.com>
Signed-off-by: Jiri Kosina <jkosina@suse.cz>
Bug: 146590412
Signed-off-by: Siarhei Vishniakou <svv@google.com>
Change-Id: I15f2e1c1349e2cf044c45a6697015b95596ce760
Git-commit: 5e88a0aa262f12c609b99571811acdaf19149f65
Git-repo: https://source.codeaurora.org/quic/la/kernel/msm-4.4
Signed-off-by: Swetha Chikkaboraiah <schikk@codeaurora.org>
Diffstat (limited to 'include')
| -rw-r--r-- | include/linux/hid.h | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/include/linux/hid.h b/include/linux/hid.h index 2a6dc0ab9b88..2f5435653459 100644 --- a/include/linux/hid.h +++ b/include/linux/hid.h @@ -529,10 +529,12 @@ struct hid_device { /* device report descriptor */ * battery is non-NULL. */ struct power_supply *battery; + __s32 battery_capacity; __s32 battery_min; __s32 battery_max; __s32 battery_report_type; __s32 battery_report_id; + bool battery_reported; #endif unsigned int status; /* see STAT flags above */ |
