18c2ecf20Sopenharmony_ci/*
28c2ecf20Sopenharmony_ci * Copyright (C) 2010 Francisco Jerez.
38c2ecf20Sopenharmony_ci * All Rights Reserved.
48c2ecf20Sopenharmony_ci *
58c2ecf20Sopenharmony_ci * Permission is hereby granted, free of charge, to any person obtaining
68c2ecf20Sopenharmony_ci * a copy of this software and associated documentation files (the
78c2ecf20Sopenharmony_ci * "Software"), to deal in the Software without restriction, including
88c2ecf20Sopenharmony_ci * without limitation the rights to use, copy, modify, merge, publish,
98c2ecf20Sopenharmony_ci * distribute, sublicense, and/or sell copies of the Software, and to
108c2ecf20Sopenharmony_ci * permit persons to whom the Software is furnished to do so, subject to
118c2ecf20Sopenharmony_ci * the following conditions:
128c2ecf20Sopenharmony_ci *
138c2ecf20Sopenharmony_ci * The above copyright notice and this permission notice (including the
148c2ecf20Sopenharmony_ci * next paragraph) shall be included in all copies or substantial
158c2ecf20Sopenharmony_ci * portions of the Software.
168c2ecf20Sopenharmony_ci *
178c2ecf20Sopenharmony_ci * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
188c2ecf20Sopenharmony_ci * EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
198c2ecf20Sopenharmony_ci * MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
208c2ecf20Sopenharmony_ci * IN NO EVENT SHALL THE COPYRIGHT OWNER(S) AND/OR ITS SUPPLIERS BE
218c2ecf20Sopenharmony_ci * LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
228c2ecf20Sopenharmony_ci * OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
238c2ecf20Sopenharmony_ci * WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
248c2ecf20Sopenharmony_ci *
258c2ecf20Sopenharmony_ci */
268c2ecf20Sopenharmony_ci
278c2ecf20Sopenharmony_ci#ifndef __DRM_I2C_SIL164_H__
288c2ecf20Sopenharmony_ci#define __DRM_I2C_SIL164_H__
298c2ecf20Sopenharmony_ci
308c2ecf20Sopenharmony_ci/**
318c2ecf20Sopenharmony_ci * struct sil164_encoder_params
328c2ecf20Sopenharmony_ci *
338c2ecf20Sopenharmony_ci * Describes how the sil164 is connected to the GPU. It should be used
348c2ecf20Sopenharmony_ci * as the @params parameter of its @set_config method.
358c2ecf20Sopenharmony_ci *
368c2ecf20Sopenharmony_ci * See "http://www.siliconimage.com/docs/SiI-DS-0021-E-164.pdf".
378c2ecf20Sopenharmony_ci */
388c2ecf20Sopenharmony_cistruct sil164_encoder_params {
398c2ecf20Sopenharmony_ci	enum {
408c2ecf20Sopenharmony_ci		SIL164_INPUT_EDGE_FALLING = 0,
418c2ecf20Sopenharmony_ci		SIL164_INPUT_EDGE_RISING
428c2ecf20Sopenharmony_ci	} input_edge;
438c2ecf20Sopenharmony_ci
448c2ecf20Sopenharmony_ci	enum {
458c2ecf20Sopenharmony_ci		SIL164_INPUT_WIDTH_12BIT = 0,
468c2ecf20Sopenharmony_ci		SIL164_INPUT_WIDTH_24BIT
478c2ecf20Sopenharmony_ci	} input_width;
488c2ecf20Sopenharmony_ci
498c2ecf20Sopenharmony_ci	enum {
508c2ecf20Sopenharmony_ci		SIL164_INPUT_SINGLE_EDGE = 0,
518c2ecf20Sopenharmony_ci		SIL164_INPUT_DUAL_EDGE
528c2ecf20Sopenharmony_ci	} input_dual;
538c2ecf20Sopenharmony_ci
548c2ecf20Sopenharmony_ci	enum {
558c2ecf20Sopenharmony_ci		SIL164_PLL_FILTER_ON = 0,
568c2ecf20Sopenharmony_ci		SIL164_PLL_FILTER_OFF,
578c2ecf20Sopenharmony_ci	} pll_filter;
588c2ecf20Sopenharmony_ci
598c2ecf20Sopenharmony_ci	int input_skew; /** < Allowed range [-4, 3], use 0 for no de-skew. */
608c2ecf20Sopenharmony_ci	int duallink_skew; /** < Allowed range [-4, 3]. */
618c2ecf20Sopenharmony_ci};
628c2ecf20Sopenharmony_ci
638c2ecf20Sopenharmony_ci#endif
64