Lines Matching refs:mode
160 const struct drm_display_mode *mode) in vtg_set_output_window() argument
166 u32 xstart = sti_vtg_get_pixel_number(*mode, 0); in vtg_set_output_window()
167 u32 ystart = sti_vtg_get_line_number(*mode, 0); in vtg_set_output_window()
168 u32 xstop = sti_vtg_get_pixel_number(*mode, mode->hdisplay - 1); in vtg_set_output_window()
169 u32 ystop = sti_vtg_get_line_number(*mode, mode->vdisplay - 1); in vtg_set_output_window()
187 const struct drm_display_mode *mode) in vtg_set_hsync_vsync_pos() argument
193 clocksperline = mode->htotal; in vtg_set_hsync_vsync_pos()
197 stop = mode->hsync_end - mode->hsync_start; in vtg_set_hsync_vsync_pos()
218 fallsync_top += mode->vsync_end - mode->vsync_start; in vtg_set_hsync_vsync_pos()
223 risesync_top = mode->vtotal; in vtg_set_hsync_vsync_pos()
224 fallsync_top = mode->vsync_end - mode->vsync_start; in vtg_set_hsync_vsync_pos()
241 const struct drm_display_mode *mode) in vtg_set_mode() argument
246 writel(mode->htotal, vtg->regs + VTG_CLKLN); in vtg_set_mode()
249 writel(mode->vtotal * 2, vtg->regs + VTG_HLFLN); in vtg_set_mode()
252 vtg_set_output_window(vtg->regs, mode); in vtg_set_mode()
255 vtg_set_hsync_vsync_pos(&sync[VTG_SYNC_ID_HDMI - 1], HDMI_DELAY, mode); in vtg_set_mode()
258 vtg_set_hsync_vsync_pos(&sync[VTG_SYNC_ID_HDDCS - 1], 0, mode); in vtg_set_mode()
261 vtg_set_hsync_vsync_pos(&sync[VTG_SYNC_ID_HDF - 1], AWG_DELAY_HD, mode); in vtg_set_mode()
264 vtg_set_hsync_vsync_pos(&sync[VTG_SYNC_ID_DVO - 1], DVO_DELAY, mode); in vtg_set_mode()
293 const struct drm_display_mode *mode) in sti_vtg_set_config() argument
296 vtg_set_mode(vtg, VTG_MODE_MASTER, vtg->sync_params, mode); in sti_vtg_set_config()
315 u32 sti_vtg_get_line_number(struct drm_display_mode mode, int y) in sti_vtg_get_line_number() argument
317 u32 start_line = mode.vtotal - mode.vsync_start + 1; in sti_vtg_get_line_number()
319 if (mode.flags & DRM_MODE_FLAG_INTERLACE) in sti_vtg_get_line_number()
335 u32 sti_vtg_get_pixel_number(struct drm_display_mode mode, int x) in sti_vtg_get_pixel_number() argument
337 return mode.htotal - mode.hsync_start + x; in sti_vtg_get_pixel_number()