aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--drivers/hid/wacom_wac.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/hid/wacom_wac.c b/drivers/hid/wacom_wac.c
index 1eae13cdc502..d6746caf71cb 100644
--- a/drivers/hid/wacom_wac.c
+++ b/drivers/hid/wacom_wac.c
@@ -2125,6 +2125,7 @@ static int wacom_bamboo_pad_irq(struct wacom_wac *wacom, size_t len)
2125 2125
2126static int wacom_wireless_irq(struct wacom_wac *wacom, size_t len) 2126static int wacom_wireless_irq(struct wacom_wac *wacom, size_t len)
2127{ 2127{
2128 struct wacom *w = container_of(wacom, struct wacom, wacom_wac);
2128 unsigned char *data = wacom->data; 2129 unsigned char *data = wacom->data;
2129 int connected; 2130 int connected;
2130 2131
@@ -2152,7 +2153,7 @@ static int wacom_wireless_irq(struct wacom_wac *wacom, size_t len)
2152 wacom_schedule_work(wacom); 2153 wacom_schedule_work(wacom);
2153 } 2154 }
2154 2155
2155 if (wacom->shared->type) 2156 if (w->battery)
2156 wacom_notify_battery(wacom, battery, charging, 1, 0); 2157 wacom_notify_battery(wacom, battery, charging, 1, 0);
2157 2158
2158 } else if (wacom->pid != 0) { 2159 } else if (wacom->pid != 0) {