#include <glib.h>
#include <peripheral_io.h>
#include <libsyscommon/list.h>
-#include <hal/hal-haptic-interface.h>
+#include <hal/hal-device-haptic-interface.h>
#include </hal/include/device/hal-backend-common.h>
static int haptic_init(void **data)
{
- hal_backend_haptic_funcs *haptic_funcs;
+ hal_backend_device_haptic_funcs *device_haptic_funcs;
- haptic_funcs = calloc(1, sizeof(hal_backend_haptic_funcs));
- if (!haptic_funcs)
+ device_haptic_funcs = calloc(1, sizeof(hal_backend_device_haptic_funcs));
+ if (!device_haptic_funcs)
return -ENOMEM;
- haptic_funcs->get_device_count = gpio_haptic_get_device_count;
- haptic_funcs->open_device = gpio_haptic_open_device;
- haptic_funcs->close_device = gpio_haptic_close_device;
- haptic_funcs->vibrate_monotone = gpio_haptic_vibrate_monotone;
- haptic_funcs->stop_device = gpio_haptic_stop_device;
- haptic_funcs->is_valid = is_valid;
+ device_haptic_funcs->get_device_count = gpio_haptic_get_device_count;
+ device_haptic_funcs->open_device = gpio_haptic_open_device;
+ device_haptic_funcs->close_device = gpio_haptic_close_device;
+ device_haptic_funcs->vibrate_monotone = gpio_haptic_vibrate_monotone;
+ device_haptic_funcs->stop_device = gpio_haptic_stop_device;
+ device_haptic_funcs->is_valid = is_valid;
- *data = (void *)haptic_funcs;
+ *data = (void *)device_haptic_funcs;
return 0;
}