via_sii164.h revision ad01e365
1/*
2 * Copyright 2016 Kevin Brace
3 * Copyright 2016 The OpenChrome Project
4 *                [https://www.freedesktop.org/wiki/Openchrome]
5 * Copyright 2014 SHS SERVICES GmbH
6 * Copyright 2006-2009 Luc Verhaegen.
7 *
8 * Permission is hereby granted, free of charge, to any person obtaining a
9 * copy of this software and associated documentation files (the "Software"),
10 * to deal in the Software without restriction, including without limitation
11 * the rights to use, copy, modify, merge, publish, distribute, sub license,
12 * and/or sell copies of the Software, and to permit persons to whom the
13 * Software is furnished to do so, subject to the following conditions:
14 *
15 * The above copyright notice and this permission notice (including the
16 * next paragraph) shall be included in all copies or substantial portions
17 * of the Software.
18 *
19 * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
20 * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
21 * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL
22 * THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
23 * LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING
24 * FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER
25 * DEALINGS IN THE SOFTWARE.
26 */
27
28#ifndef _VIA_SII164_H_
29#define _VIA_SII164_H_ 1
30
31#define VIA_SII164_VEN  0x20
32#define VIA_SII164_HEN  0x10
33#define VIA_SII164_DSEL 0x08
34#define VIA_SII164_BSEL 0x04
35#define VIA_SII164_EDGE 0x02
36#define VIA_SII164_PDB  0x01
37
38typedef struct _viaSiI164 {
39	I2CDevPtr SiI164I2CDev;
40
41	int DotclockMin;
42	int DotclockMax;
43	CARD8 Register08;
44	CARD8 Register09;
45	CARD8 Register0A;
46	CARD8 Register0C;
47} viaSiI164Rec, *viaSiI164RecPtr;
48
49
50extern const xf86OutputFuncsRec via_sii164_funcs;
51
52Bool viaSiI164Init(ScrnInfoPtr pScrn, I2CBusPtr pI2CBus);
53
54#endif /* _VIA_SII164_H_ */
55