* avoid calling the TSC stop and start functions as the TSC
* isn't yet clocked.
*/
- mutex_lock(&input->mutex);
+ guard(mutex)(&input->mutex);
if (input_device_enabled(input)) {
if (device_may_wakeup(dev))
lpc32xx_stop_tsc(tsc);
}
- mutex_unlock(&input->mutex);
-
return 0;
}
struct lpc32xx_tsc *tsc = dev_get_drvdata(dev);
struct input_dev *input = tsc->dev;
- mutex_lock(&input->mutex);
+ guard(mutex)(&input->mutex);
if (input_device_enabled(input)) {
if (device_may_wakeup(dev))
lpc32xx_setup_tsc(tsc);
}
- mutex_unlock(&input->mutex);
-
return 0;
}