162306a36Sopenharmony_ci/*
262306a36Sopenharmony_ci * Copyright 2009 Advanced Micro Devices, Inc.
362306a36Sopenharmony_ci * Copyright 2009 Red Hat Inc.
462306a36Sopenharmony_ci *
562306a36Sopenharmony_ci * Permission is hereby granted, free of charge, to any person obtaining a
662306a36Sopenharmony_ci * copy of this software and associated documentation files (the "Software"),
762306a36Sopenharmony_ci * to deal in the Software without restriction, including without limitation
862306a36Sopenharmony_ci * the rights to use, copy, modify, merge, publish, distribute, sublicense,
962306a36Sopenharmony_ci * and/or sell copies of the Software, and to permit persons to whom the
1062306a36Sopenharmony_ci * Software is furnished to do so, subject to the following conditions:
1162306a36Sopenharmony_ci *
1262306a36Sopenharmony_ci * The above copyright notice and this permission notice shall be included in
1362306a36Sopenharmony_ci * all copies or substantial portions of the Software.
1462306a36Sopenharmony_ci *
1562306a36Sopenharmony_ci * THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
1662306a36Sopenharmony_ci * IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
1762306a36Sopenharmony_ci * FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.  IN NO EVENT SHALL
1862306a36Sopenharmony_ci * THE COPYRIGHT HOLDER(S) OR AUTHOR(S) BE LIABLE FOR ANY CLAIM, DAMAGES OR
1962306a36Sopenharmony_ci * OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE,
2062306a36Sopenharmony_ci * ARISING FROM, OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR
2162306a36Sopenharmony_ci * OTHER DEALINGS IN THE SOFTWARE.
2262306a36Sopenharmony_ci *
2362306a36Sopenharmony_ci * Authors: Dave Airlie
2462306a36Sopenharmony_ci *          Alex Deucher
2562306a36Sopenharmony_ci *          Jerome Glisse
2662306a36Sopenharmony_ci */
2762306a36Sopenharmony_ci#ifndef AVIVOD_H
2862306a36Sopenharmony_ci#define AVIVOD_H
2962306a36Sopenharmony_ci
3062306a36Sopenharmony_ci
3162306a36Sopenharmony_ci#define	D1CRTC_CONTROL					0x6080
3262306a36Sopenharmony_ci#define		CRTC_EN						(1 << 0)
3362306a36Sopenharmony_ci#define	D1CRTC_STATUS					0x609c
3462306a36Sopenharmony_ci#define	D1CRTC_UPDATE_LOCK				0x60E8
3562306a36Sopenharmony_ci#define	D1GRPH_PRIMARY_SURFACE_ADDRESS			0x6110
3662306a36Sopenharmony_ci#define	D1GRPH_SECONDARY_SURFACE_ADDRESS		0x6118
3762306a36Sopenharmony_ci
3862306a36Sopenharmony_ci#define	D2CRTC_CONTROL					0x6880
3962306a36Sopenharmony_ci#define	D2CRTC_STATUS					0x689c
4062306a36Sopenharmony_ci#define	D2CRTC_UPDATE_LOCK				0x68E8
4162306a36Sopenharmony_ci#define	D2GRPH_PRIMARY_SURFACE_ADDRESS			0x6910
4262306a36Sopenharmony_ci#define	D2GRPH_SECONDARY_SURFACE_ADDRESS		0x6918
4362306a36Sopenharmony_ci
4462306a36Sopenharmony_ci#define	D1VGA_CONTROL					0x0330
4562306a36Sopenharmony_ci#define		DVGA_CONTROL_MODE_ENABLE			(1 << 0)
4662306a36Sopenharmony_ci#define		DVGA_CONTROL_TIMING_SELECT			(1 << 8)
4762306a36Sopenharmony_ci#define		DVGA_CONTROL_SYNC_POLARITY_SELECT		(1 << 9)
4862306a36Sopenharmony_ci#define		DVGA_CONTROL_OVERSCAN_TIMING_SELECT		(1 << 10)
4962306a36Sopenharmony_ci#define		DVGA_CONTROL_OVERSCAN_COLOR_EN			(1 << 16)
5062306a36Sopenharmony_ci#define		DVGA_CONTROL_ROTATE				(1 << 24)
5162306a36Sopenharmony_ci#define D2VGA_CONTROL					0x0338
5262306a36Sopenharmony_ci
5362306a36Sopenharmony_ci#define	VGA_HDP_CONTROL					0x328
5462306a36Sopenharmony_ci#define		VGA_MEM_PAGE_SELECT_EN				(1 << 0)
5562306a36Sopenharmony_ci#define		VGA_MEMORY_DISABLE				(1 << 4)
5662306a36Sopenharmony_ci#define		VGA_RBBM_LOCK_DISABLE				(1 << 8)
5762306a36Sopenharmony_ci#define		VGA_SOFT_RESET					(1 << 16)
5862306a36Sopenharmony_ci#define	VGA_MEMORY_BASE_ADDRESS				0x0310
5962306a36Sopenharmony_ci#define	VGA_RENDER_CONTROL				0x0300
6062306a36Sopenharmony_ci#define		VGA_VSTATUS_CNTL_MASK				0x00030000
6162306a36Sopenharmony_ci
6262306a36Sopenharmony_ci#endif
63