wacom->wacom_wac.pen_registered = false;
wacom->wacom_wac.touch_registered = false;
wacom->wacom_wac.pad_registered = false;
- wacom_destroy_leds(wacom);
}
static int wacom_allocate_inputs(struct wacom *wacom)
if (error)
goto fail_register_pad_input;
wacom_wac->pad_registered = true;
-
- error = wacom_initialize_leds(wacom);
- if (error)
- goto fail_leds;
}
return 0;
-fail_leds:
- input_unregister_device(pad_input_dev);
- pad_input_dev = NULL;
- wacom_wac->pad_registered = false;
fail_register_pad_input:
if (touch_input_dev)
input_unregister_device(touch_input_dev);
goto fail_register_inputs;
if (wacom->wacom_wac.features.device_type & WACOM_DEVICETYPE_PAD) {
+ error = wacom_initialize_leds(wacom);
+ if (error)
+ goto fail_leds;
+
error = wacom_initialize_remote(wacom);
if (error)
goto fail_remote;
fail_hw_start:
kobject_put(wacom->remote_dir);
fail_remote:
+ wacom_destroy_leds(wacom);
+fail_leds:
wacom_clean_inputs(wacom);
fail_register_inputs:
wacom_destroy_battery(wacom);
hdev1 = usb_get_intfdata(usbdev->config->interface[1]);
wacom1 = hid_get_drvdata(hdev1);
wacom_wac1 = &(wacom1->wacom_wac);
+ wacom_destroy_leds(wacom1);
wacom_clean_inputs(wacom1);
/* Touch interface */
hdev2 = usb_get_intfdata(usbdev->config->interface[2]);
wacom2 = hid_get_drvdata(hdev2);
wacom_wac2 = &(wacom2->wacom_wac);
+ wacom_destroy_leds(wacom2);
wacom_clean_inputs(wacom2);
if (wacom_wac->pid == 0) {
return;
fail:
+ wacom_destroy_leds(wacom1);
wacom_clean_inputs(wacom1);
+ wacom_destroy_leds(wacom2);
wacom_clean_inputs(wacom2);
return;
}
cancel_work_sync(&wacom->work);
kobject_put(wacom->remote_dir);
+ wacom_destroy_leds(wacom);
wacom_clean_inputs(wacom);
if (hdev->bus == BUS_BLUETOOTH)
device_remove_file(&hdev->dev, &dev_attr_speed);