xref: /onnv-gate/usr/src/uts/common/sys/agp/agpamd64gart_io.h (revision 0:68f95e015346)
1*0Sstevel@tonic-gate /*
2*0Sstevel@tonic-gate  * Copyright 2005 Sun Microsystems, Inc.  All rights reserved.
3*0Sstevel@tonic-gate  * Use is subject to license terms.
4*0Sstevel@tonic-gate  */
5*0Sstevel@tonic-gate 
6*0Sstevel@tonic-gate #ifndef	_SYS_AGPAMD64GART_IO_H
7*0Sstevel@tonic-gate #define	_SYS_AGPAMD64GART_IO_H
8*0Sstevel@tonic-gate 
9*0Sstevel@tonic-gate #pragma ident	"%Z%%M%	%I%	%E% SMI"
10*0Sstevel@tonic-gate 
11*0Sstevel@tonic-gate #ifdef __cplusplus
12*0Sstevel@tonic-gate extern "C" {
13*0Sstevel@tonic-gate #endif
14*0Sstevel@tonic-gate 
15*0Sstevel@tonic-gate #ifdef _KERNEL
16*0Sstevel@tonic-gate 
17*0Sstevel@tonic-gate #define	AMD64GART_NAME		"amd64_gart"
18*0Sstevel@tonic-gate #define	CPUGART_DEVLINK		"/dev/agp/cpugart"
19*0Sstevel@tonic-gate 
20*0Sstevel@tonic-gate #define	AGPAMD64GARTIOC_BASE	'M'
21*0Sstevel@tonic-gate 
22*0Sstevel@tonic-gate #define	AMD64_GET_INFO		_IOR(AGPAMD64GARTIOC_BASE, 50, amdgart_info_t)
23*0Sstevel@tonic-gate #define	AMD64_SET_GART_ADDR	_IOW(AGPAMD64GARTIOC_BASE, 51, uint32_t)
24*0Sstevel@tonic-gate #define	AMD64_FLUSH_GTLB	_IO(AGPAMD64GARTIOC_BASE, 52)
25*0Sstevel@tonic-gate #define	AMD64_CONFIGURE		_IO(AGPAMD64GARTIOC_BASE, 53)
26*0Sstevel@tonic-gate #define	AMD64_UNCONFIG		_IO(AGPAMD64GARTIOC_BASE, 54)
27*0Sstevel@tonic-gate 
28*0Sstevel@tonic-gate /* Used to retrieve attributes of the amd64 gart device */
29*0Sstevel@tonic-gate typedef struct amdgart_info {
30*0Sstevel@tonic-gate 	uint64_t	cgart_aperbase;
31*0Sstevel@tonic-gate 	size_t		cgart_apersize;
32*0Sstevel@tonic-gate } amdgart_info_t;
33*0Sstevel@tonic-gate 
34*0Sstevel@tonic-gate #endif /* _KERNEL */
35*0Sstevel@tonic-gate 
36*0Sstevel@tonic-gate #ifdef __cplusplus
37*0Sstevel@tonic-gate }
38*0Sstevel@tonic-gate #endif
39*0Sstevel@tonic-gate 
40*0Sstevel@tonic-gate #endif /* _SYS_AGPAMD64GART_IO_H */
41