#define ALIGN_TO_64KB(x) ((((x) + (1 << 16) - 1) >> 16) << 16)
#define RETURN_VAL_IF_FAIL(cond, val) {\
- if (!(cond)) {\
- TDM_ERR("'%s' failed", #cond);\
- return val;\
- }\
+ if (!(cond)) {\
+ TDM_ERR("'%s' failed", #cond);\
+ return val;\
+ }\
}
#define GOTO_IF_FAIL(cond, val) {\
- if (!(cond)) {\
- TDM_ERR("'%s' failed", #cond);\
- goto val;\
- }\
+ if (!(cond)) {\
+ TDM_ERR("'%s' failed", #cond);\
+ goto val;\
+ }\
}
typedef struct _tdm_nexell_data
{
- tdm_display *dpy;
+ tdm_display *dpy;
- int drm_fd;
+ int drm_fd;
#if LIBDRM_MAJOR_VERSION >= 2 && LIBDRM_MINOR_VERSION >= 4 && LIBDRM_MICRO_VERSION >= 47
- int has_universal_plane;
+ int has_universal_plane;
#endif
#if HAVE_UDEV
- struct udev_monitor *uevent_monitor;
- tdm_event_loop_source *uevent_source;
+ struct udev_monitor *uevent_monitor;
+ tdm_event_loop_source *uevent_source;
#endif
- drmModeResPtr mode_res;
- drmModePlaneResPtr plane_res;
+ drmModeResPtr mode_res;
+ drmModePlaneResPtr plane_res;
- struct list_head output_list;
- struct list_head buffer_list;
+ struct list_head output_list;
+ struct list_head buffer_list;
} tdm_nexell_data;
uint32_t tdm_nexell_format_to_drm_format(tbm_format format);