Commit 864050c7 authored by Jyri Sarha's avatar Jyri Sarha Committed by Tomi Valkeinen

drm/omap: Rename enum omap_plane to enum omap_plane_id

The enum omap_plane conflicted with the same struct name for omapdrm
plane private data. This rename should solve the conflict.

The rename was implement with this very simple coccinelle patch:
------------------------
@@
@@
enum
-omap_plane
+omap_plane_id
------------------------
The patch was applied like this:
spatch --sp-file <cocci_file> --all-includes --in-place --dir drivers/gpu/drm/omapdrm

The above patch did not rename the actual enum definition. That was
added manually on top of the spatch changes.
Signed-off-by: default avatarJyri Sarha <jsarha@ti.com>
Acked-by: default avatarLaurent Pinchart <laurent.pinchart@ideasonboard.com>
Signed-off-by: default avatarTomi Valkeinen <tomi.valkeinen@ti.com>
parent f1118b89
This diff is collapsed.
......@@ -353,7 +353,7 @@ static inline u16 DISPC_CPR_COEF_B(enum omap_channel channel)
}
/* DISPC overlay register base addresses */
static inline u16 DISPC_OVL_BASE(enum omap_plane plane)
static inline u16 DISPC_OVL_BASE(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -373,7 +373,7 @@ static inline u16 DISPC_OVL_BASE(enum omap_plane plane)
}
/* DISPC overlay register offsets */
static inline u16 DISPC_BA0_OFFSET(enum omap_plane plane)
static inline u16 DISPC_BA0_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -389,7 +389,7 @@ static inline u16 DISPC_BA0_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_BA1_OFFSET(enum omap_plane plane)
static inline u16 DISPC_BA1_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -405,7 +405,7 @@ static inline u16 DISPC_BA1_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_BA0_UV_OFFSET(enum omap_plane plane)
static inline u16 DISPC_BA0_UV_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -425,7 +425,7 @@ static inline u16 DISPC_BA0_UV_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_BA1_UV_OFFSET(enum omap_plane plane)
static inline u16 DISPC_BA1_UV_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -445,7 +445,7 @@ static inline u16 DISPC_BA1_UV_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_POS_OFFSET(enum omap_plane plane)
static inline u16 DISPC_POS_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -460,7 +460,7 @@ static inline u16 DISPC_POS_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_SIZE_OFFSET(enum omap_plane plane)
static inline u16 DISPC_SIZE_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -476,7 +476,7 @@ static inline u16 DISPC_SIZE_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_ATTR_OFFSET(enum omap_plane plane)
static inline u16 DISPC_ATTR_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -493,7 +493,7 @@ static inline u16 DISPC_ATTR_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_ATTR2_OFFSET(enum omap_plane plane)
static inline u16 DISPC_ATTR2_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -513,7 +513,7 @@ static inline u16 DISPC_ATTR2_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_FIFO_THRESH_OFFSET(enum omap_plane plane)
static inline u16 DISPC_FIFO_THRESH_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -530,7 +530,7 @@ static inline u16 DISPC_FIFO_THRESH_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_FIFO_SIZE_STATUS_OFFSET(enum omap_plane plane)
static inline u16 DISPC_FIFO_SIZE_STATUS_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -547,7 +547,7 @@ static inline u16 DISPC_FIFO_SIZE_STATUS_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_ROW_INC_OFFSET(enum omap_plane plane)
static inline u16 DISPC_ROW_INC_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -564,7 +564,7 @@ static inline u16 DISPC_ROW_INC_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_PIX_INC_OFFSET(enum omap_plane plane)
static inline u16 DISPC_PIX_INC_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -581,7 +581,7 @@ static inline u16 DISPC_PIX_INC_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_WINDOW_SKIP_OFFSET(enum omap_plane plane)
static inline u16 DISPC_WINDOW_SKIP_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -597,7 +597,7 @@ static inline u16 DISPC_WINDOW_SKIP_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_TABLE_BA_OFFSET(enum omap_plane plane)
static inline u16 DISPC_TABLE_BA_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -613,7 +613,7 @@ static inline u16 DISPC_TABLE_BA_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_FIR_OFFSET(enum omap_plane plane)
static inline u16 DISPC_FIR_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -631,7 +631,7 @@ static inline u16 DISPC_FIR_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_FIR2_OFFSET(enum omap_plane plane)
static inline u16 DISPC_FIR2_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -651,7 +651,7 @@ static inline u16 DISPC_FIR2_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_PIC_SIZE_OFFSET(enum omap_plane plane)
static inline u16 DISPC_PIC_SIZE_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -670,7 +670,7 @@ static inline u16 DISPC_PIC_SIZE_OFFSET(enum omap_plane plane)
}
static inline u16 DISPC_ACCU0_OFFSET(enum omap_plane plane)
static inline u16 DISPC_ACCU0_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -688,7 +688,7 @@ static inline u16 DISPC_ACCU0_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_ACCU2_0_OFFSET(enum omap_plane plane)
static inline u16 DISPC_ACCU2_0_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -708,7 +708,7 @@ static inline u16 DISPC_ACCU2_0_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_ACCU1_OFFSET(enum omap_plane plane)
static inline u16 DISPC_ACCU1_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -726,7 +726,7 @@ static inline u16 DISPC_ACCU1_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_ACCU2_1_OFFSET(enum omap_plane plane)
static inline u16 DISPC_ACCU2_1_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -747,7 +747,7 @@ static inline u16 DISPC_ACCU2_1_OFFSET(enum omap_plane plane)
}
/* coef index i = {0, 1, 2, 3, 4, 5, 6, 7} */
static inline u16 DISPC_FIR_COEF_H_OFFSET(enum omap_plane plane, u16 i)
static inline u16 DISPC_FIR_COEF_H_OFFSET(enum omap_plane_id plane, u16 i)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -766,7 +766,7 @@ static inline u16 DISPC_FIR_COEF_H_OFFSET(enum omap_plane plane, u16 i)
}
/* coef index i = {0, 1, 2, 3, 4, 5, 6, 7} */
static inline u16 DISPC_FIR_COEF_H2_OFFSET(enum omap_plane plane, u16 i)
static inline u16 DISPC_FIR_COEF_H2_OFFSET(enum omap_plane_id plane, u16 i)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -787,7 +787,7 @@ static inline u16 DISPC_FIR_COEF_H2_OFFSET(enum omap_plane plane, u16 i)
}
/* coef index i = {0, 1, 2, 3, 4, 5, 6, 7} */
static inline u16 DISPC_FIR_COEF_HV_OFFSET(enum omap_plane plane, u16 i)
static inline u16 DISPC_FIR_COEF_HV_OFFSET(enum omap_plane_id plane, u16 i)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -806,7 +806,7 @@ static inline u16 DISPC_FIR_COEF_HV_OFFSET(enum omap_plane plane, u16 i)
}
/* coef index i = {0, 1, 2, 3, 4, 5, 6, 7} */
static inline u16 DISPC_FIR_COEF_HV2_OFFSET(enum omap_plane plane, u16 i)
static inline u16 DISPC_FIR_COEF_HV2_OFFSET(enum omap_plane_id plane, u16 i)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -827,7 +827,7 @@ static inline u16 DISPC_FIR_COEF_HV2_OFFSET(enum omap_plane plane, u16 i)
}
/* coef index i = {0, 1, 2, 3, 4,} */
static inline u16 DISPC_CONV_COEF_OFFSET(enum omap_plane plane, u16 i)
static inline u16 DISPC_CONV_COEF_OFFSET(enum omap_plane_id plane, u16 i)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -845,7 +845,7 @@ static inline u16 DISPC_CONV_COEF_OFFSET(enum omap_plane plane, u16 i)
}
/* coef index i = {0, 1, 2, 3, 4, 5, 6, 7} */
static inline u16 DISPC_FIR_COEF_V_OFFSET(enum omap_plane plane, u16 i)
static inline u16 DISPC_FIR_COEF_V_OFFSET(enum omap_plane_id plane, u16 i)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -865,7 +865,7 @@ static inline u16 DISPC_FIR_COEF_V_OFFSET(enum omap_plane plane, u16 i)
}
/* coef index i = {0, 1, 2, 3, 4, 5, 6, 7} */
static inline u16 DISPC_FIR_COEF_V2_OFFSET(enum omap_plane plane, u16 i)
static inline u16 DISPC_FIR_COEF_V2_OFFSET(enum omap_plane_id plane, u16 i)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -885,7 +885,7 @@ static inline u16 DISPC_FIR_COEF_V2_OFFSET(enum omap_plane plane, u16 i)
}
}
static inline u16 DISPC_PRELOAD_OFFSET(enum omap_plane plane)
static inline u16 DISPC_PRELOAD_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......@@ -902,7 +902,7 @@ static inline u16 DISPC_PRELOAD_OFFSET(enum omap_plane plane)
}
}
static inline u16 DISPC_MFLAG_THRESHOLD_OFFSET(enum omap_plane plane)
static inline u16 DISPC_MFLAG_THRESHOLD_OFFSET(enum omap_plane_id plane)
{
switch (plane) {
case OMAP_DSS_GFX:
......
......@@ -359,8 +359,9 @@ int dispc_calc_clock_rates(unsigned long dispc_fclk_rate,
struct dispc_clock_info *cinfo);
void dispc_ovl_set_fifo_threshold(enum omap_plane plane, u32 low, u32 high);
void dispc_ovl_compute_fifo_thresholds(enum omap_plane plane,
void dispc_ovl_set_fifo_threshold(enum omap_plane_id plane, u32 low,
u32 high);
void dispc_ovl_compute_fifo_thresholds(enum omap_plane_id plane,
u32 *fifo_low, u32 *fifo_high, bool use_fifomerge,
bool manual_update);
......
......@@ -800,17 +800,17 @@ enum omap_dss_output_id dss_feat_get_supported_outputs(enum omap_channel channel
return omap_current_dss_features->supported_outputs[channel];
}
enum omap_color_mode dss_feat_get_supported_color_modes(enum omap_plane plane)
enum omap_color_mode dss_feat_get_supported_color_modes(enum omap_plane_id plane)
{
return omap_current_dss_features->supported_color_modes[plane];
}
enum omap_overlay_caps dss_feat_get_overlay_caps(enum omap_plane plane)
enum omap_overlay_caps dss_feat_get_overlay_caps(enum omap_plane_id plane)
{
return omap_current_dss_features->overlay_caps[plane];
}
bool dss_feat_color_mode_supported(enum omap_plane plane,
bool dss_feat_color_mode_supported(enum omap_plane_id plane,
enum omap_color_mode color_mode)
{
return omap_current_dss_features->supported_color_modes[plane] &
......
......@@ -88,8 +88,8 @@ enum dss_range_param {
/* DSS Feature Functions */
unsigned long dss_feat_get_param_min(enum dss_range_param param);
unsigned long dss_feat_get_param_max(enum dss_range_param param);
enum omap_overlay_caps dss_feat_get_overlay_caps(enum omap_plane plane);
bool dss_feat_color_mode_supported(enum omap_plane plane,
enum omap_overlay_caps dss_feat_get_overlay_caps(enum omap_plane_id plane);
bool dss_feat_color_mode_supported(enum omap_plane_id plane,
enum omap_color_mode color_mode);
u32 dss_feat_get_buffer_size_unit(void); /* in bytes */
......@@ -106,6 +106,6 @@ enum omap_dss_output_id dss_feat_get_supported_outputs(enum omap_channel channel
int dss_feat_get_num_mgrs(void);
int dss_feat_get_num_ovls(void);
enum omap_color_mode dss_feat_get_supported_color_modes(enum omap_plane plane);
enum omap_color_mode dss_feat_get_supported_color_modes(enum omap_plane_id plane);
#endif
......@@ -76,7 +76,7 @@ enum omap_display_type {
OMAP_DISPLAY_TYPE_DVI = 1 << 6,
};
enum omap_plane {
enum omap_plane_id {
OMAP_DSS_GFX = 0,
OMAP_DSS_VIDEO1 = 1,
OMAP_DSS_VIDEO2 = 2,
......@@ -338,7 +338,7 @@ struct omap_overlay {
/* static fields */
const char *name;
enum omap_plane id;
enum omap_plane_id id;
enum omap_color_mode supported_modes;
enum omap_overlay_caps caps;
......@@ -785,7 +785,7 @@ const char *omapdss_get_default_display_name(void);
int dss_feat_get_num_mgrs(void);
int dss_feat_get_num_ovls(void);
enum omap_color_mode dss_feat_get_supported_color_modes(enum omap_plane plane);
enum omap_color_mode dss_feat_get_supported_color_modes(enum omap_plane_id plane);
......@@ -923,14 +923,15 @@ struct dispc_ops {
const struct drm_color_lut *lut,
unsigned int length);
int (*ovl_enable)(enum omap_plane plane, bool enable);
bool (*ovl_enabled)(enum omap_plane plane);
void (*ovl_set_channel_out)(enum omap_plane plane,
int (*ovl_enable)(enum omap_plane_id plane, bool enable);
bool (*ovl_enabled)(enum omap_plane_id plane);
void (*ovl_set_channel_out)(enum omap_plane_id plane,
enum omap_channel channel);
int (*ovl_setup)(enum omap_plane plane, const struct omap_overlay_info *oi,
int (*ovl_setup)(enum omap_plane_id plane,
const struct omap_overlay_info *oi,
const struct videomode *vm, bool mem_to_mem);
enum omap_color_mode (*ovl_get_color_modes)(enum omap_plane plane);
enum omap_color_mode (*ovl_get_color_modes)(enum omap_plane_id plane);
};
void dispc_set_ops(const struct dispc_ops *o);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment