mirror of
https://github.com/torvalds/linux.git
synced 2024-11-08 13:11:45 +00:00
16844fb1e6
This patch renames check_timing to check_mode and removes the unnecessary conversion of drm_display_mode to/from fb_videomode in the hdmi driver. v4: 1) Changed the commit message to add information related to renaming the callbacks to check_mode. 2) Changed debug message to print 1/0 for interlace mode. v3: 1) Replaced check_timing callbacks with check_mode. 2) Change the type of second parameter of check_mode callback from void pointer paramenter to struct drm_display_mode pointer. v2: 1) Removed convert_to_video_timing(). 2) Corrected DRM_DEBUG_KMS to print the resolution properly. Signed-off-by: Rahul Sharma <rahul.sharma@samsung.com> Signed-off-by: Inki Dae <inki.dae@samsung.com>
68 lines
2.0 KiB
C
68 lines
2.0 KiB
C
/* exynos_drm_hdmi.h
|
|
*
|
|
* Copyright (c) 2011 Samsung Electronics Co., Ltd.
|
|
* Authoer: Inki Dae <inki.dae@samsung.com>
|
|
*
|
|
* This program is free software; you can redistribute it and/or modify it
|
|
* under the terms of the GNU General Public License as published by the
|
|
* Free Software Foundation; either version 2 of the License, or (at your
|
|
* option) any later version.
|
|
*/
|
|
|
|
#ifndef _EXYNOS_DRM_HDMI_H_
|
|
#define _EXYNOS_DRM_HDMI_H_
|
|
|
|
#define MIXER_WIN_NR 3
|
|
#define MIXER_DEFAULT_WIN 0
|
|
|
|
/*
|
|
* exynos hdmi common context structure.
|
|
*
|
|
* @drm_dev: pointer to drm_device.
|
|
* @ctx: pointer to the context of specific device driver.
|
|
* this context should be hdmi_context or mixer_context.
|
|
*/
|
|
struct exynos_drm_hdmi_context {
|
|
struct drm_device *drm_dev;
|
|
void *ctx;
|
|
};
|
|
|
|
struct exynos_hdmi_ops {
|
|
/* display */
|
|
bool (*is_connected)(void *ctx);
|
|
struct edid *(*get_edid)(void *ctx,
|
|
struct drm_connector *connector);
|
|
int (*check_mode)(void *ctx, struct drm_display_mode *mode);
|
|
int (*power_on)(void *ctx, int mode);
|
|
|
|
/* manager */
|
|
void (*mode_set)(void *ctx, struct drm_display_mode *mode);
|
|
void (*get_max_resol)(void *ctx, unsigned int *width,
|
|
unsigned int *height);
|
|
void (*commit)(void *ctx);
|
|
void (*dpms)(void *ctx, int mode);
|
|
};
|
|
|
|
struct exynos_mixer_ops {
|
|
/* manager */
|
|
int (*iommu_on)(void *ctx, bool enable);
|
|
int (*enable_vblank)(void *ctx, int pipe);
|
|
void (*disable_vblank)(void *ctx);
|
|
void (*wait_for_vblank)(void *ctx);
|
|
void (*dpms)(void *ctx, int mode);
|
|
|
|
/* overlay */
|
|
void (*win_mode_set)(void *ctx, struct exynos_drm_overlay *overlay);
|
|
void (*win_commit)(void *ctx, int zpos);
|
|
void (*win_disable)(void *ctx, int zpos);
|
|
|
|
/* display */
|
|
int (*check_mode)(void *ctx, struct drm_display_mode *mode);
|
|
};
|
|
|
|
void exynos_hdmi_drv_attach(struct exynos_drm_hdmi_context *ctx);
|
|
void exynos_mixer_drv_attach(struct exynos_drm_hdmi_context *ctx);
|
|
void exynos_hdmi_ops_register(struct exynos_hdmi_ops *ops);
|
|
void exynos_mixer_ops_register(struct exynos_mixer_ops *ops);
|
|
#endif
|