summaryrefslogtreecommitdiff
path: root/static/freebsd/man4/agp.4 3.html
blob: f812f887219a7ee1738d10df6f21a6818608c115 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
<table class="head">
  <tr>
    <td class="head-ltitle">AGP(4)</td>
    <td class="head-vol">Device Drivers Manual</td>
    <td class="head-rtitle">AGP(4)</td>
  </tr>
</table>
<div class="manual-text">
<section class="Sh">
<h1 class="Sh" id="NAME"><a class="permalink" href="#NAME">NAME</a></h1>
<p class="Pp"><code class="Nm">agp</code> &#x2014; <span class="Nd">generic
    interface to the Accelerated Graphics Port (AGP)</span></p>
</section>
<section class="Sh">
<h1 class="Sh" id="SYNOPSIS"><a class="permalink" href="#SYNOPSIS">SYNOPSIS</a></h1>
<p class="Pp"><code class="Cd">device agp</code></p>
</section>
<section class="Sh">
<h1 class="Sh" id="DEPRECATION_NOTICE"><a class="permalink" href="#DEPRECATION_NOTICE">DEPRECATION
  NOTICE</a></h1>
<p class="Pp">The <code class="Nm">agp</code> driver is slated to be removed in
    <span class="Ux">FreeBSD 16.0</span>.</p>
</section>
<section class="Sh">
<h1 class="Sh" id="DESCRIPTION"><a class="permalink" href="#DESCRIPTION">DESCRIPTION</a></h1>
<p class="Pp">The <code class="Nm">agp</code> driver provides uniform, abstract
    methods for controlling the following devices:</p>
<p class="Pp"></p>
<dl class="Bl-tag Bl-compact">
  <dt>Ali:</dt>
  <dd>M1541, M1621 and M1671 host to AGP bridges</dd>
  <dt>AMD:</dt>
  <dd>751, 761 and 762 host to AGP bridges</dd>
  <dt>ATI:</dt>
  <dd>RS100, RS200, RS250 and RS300 AGP bridges</dd>
  <dt>Intel:</dt>
  <dd>i820, i840, i845, i850, and i860 host to AGP bridges</dd>
  <dt>Intel:</dt>
  <dd>i810, i810-DC100, i810E, i815, 830M, 845G, 845M, 852GM, 852GME, 855GM,
      855GME, 865G, 915G and 915GM SVGA controllers</dd>
  <dt>Intel:</dt>
  <dd>82443BX, 82443GX, 82443LX, 82815, 82820, 82830, 82840, 82845, 82845G,
      82850, 82855, 82855GM, 82860, 82865, 82875P, E7205 and E7505 host to AGP
      bridges</dd>
  <dt>NVIDIA:</dt>
  <dd>nForce and nForce2 AGP controllers</dd>
  <dt>SiS:</dt>
  <dd>530, 540, 550, 620, 630, 645, 645DX, 648, 650, 651, 655, 661, 730, 735,
      740, 741, 745, 746, 760 and 5591 host to AGP bridges</dd>
  <dt>VIA:</dt>
  <dd>3296, 82C597, 82C598, 82C691, 82C694X, 82C8363, 8235, 8237, 8361, 8367,
      8371, 8377, 8501, 8601, 862x, 8633, 8653, 8703, 8753, 8754, 8763, 8783,
      KT880, PM800, PM880, PN800, PN880, PT880, XM266 and XN266 host to PCI
      bridges</dd>
</dl>
<p class="Pp">The most common application of <code class="Nm">agp</code> is for
    running <a class="Xr">X(7)</a> (<span class="Pa">ports/x11/xorg-docs</span>)
    on the Intel i81x controllers.</p>
</section>
<section class="Sh">
<h1 class="Sh" id="IOCTLS"><a class="permalink" href="#IOCTLS">IOCTLS</a></h1>
<p class="Pp">The following <a class="Xr">ioctl(2)</a> operations can be
    performed on <span class="Pa">/dev/agpgart</span>, which are defined in
    <code class="In">&lt;<a class="In">sys/agpio.h</a>&gt;</code>:</p>
<dl class="Bl-tag">
  <dt id="AGPIOC_INFO"><a class="permalink" href="#AGPIOC_INFO"><code class="Dv">AGPIOC_INFO</code></a></dt>
  <dd>Returns state of the <code class="Nm">agp</code> system. The result is a
      pointer to the following structure:
    <div class="Bd Pp Li">
    <pre>typedef struct _agp_info {
	agp_version version;  /* version of the driver        */
	uint32_t bridge_id;   /* bridge vendor/device         */
	uint32_t agp_mode;    /* mode info of bridge          */
	off_t aper_base;      /* base of aperture             */
	size_t aper_size;     /* size of aperture             */
	size_t pg_total;      /* max pages (swap + system)    */
	size_t pg_system;     /* max pages (system)           */
	size_t pg_used;       /* current pages used           */
} agp_info;</pre>
    </div>
  </dd>
  <dt id="AGPIOC_ACQUIRE"><a class="permalink" href="#AGPIOC_ACQUIRE"><code class="Dv">AGPIOC_ACQUIRE</code></a></dt>
  <dd>Acquire control of the AGP chipset for use by this client. Returns
      <code class="Er">EBUSY</code> if the AGP chipset is already acquired by
      another client.</dd>
  <dt id="AGPIOC_RELEASE"><a class="permalink" href="#AGPIOC_RELEASE"><code class="Dv">AGPIOC_RELEASE</code></a></dt>
  <dd>Release control of the AGP chipset. This does not unbind or free any
      allocated memory, which is the responsibility of the client to handle if
      necessary.</dd>
  <dt id="AGPIOC_SETUP"><a class="permalink" href="#AGPIOC_SETUP"><code class="Dv">AGPIOC_SETUP</code></a></dt>
  <dd>Enable the AGP hardware with the relevant mode. This
      <a class="Xr">ioctl(2)</a> takes the following structure:
    <div class="Bd Pp Li">
    <pre>typedef struct _agp_setup {
	uint32_t agp_mode;    /* mode info of bridge */
} agp_setup;</pre>
    </div>
    <p class="Pp">The mode bits are defined in
        <code class="In">&lt;<a class="In">sys/agpio.h</a>&gt;</code>.</p>
  </dd>
  <dt id="AGPIOC_ALLOCATE"><a class="permalink" href="#AGPIOC_ALLOCATE"><code class="Dv">AGPIOC_ALLOCATE</code></a></dt>
  <dd>Allocate physical memory suitable for mapping into the AGP aperture. This
      <a class="Xr">ioctl(2)</a> takes the following structure:
    <div class="Bd Pp Li">
    <pre>typedef struct _agp_allocate {
	int key;              /* tag of allocation            */
	size_t pg_count;      /* number of pages              */
	uint32_t type;        /* 0 == normal, other devspec   */
	uint32_t physical;    /* device specific (some devices
			       * need a phys address of the
			       * actual page behind the gatt
			       * table)                       */
} agp_allocate;</pre>
    </div>
    <p class="Pp">Returns a handle to the allocated memory.</p>
  </dd>
  <dt id="AGPIOC_DEALLOCATE"><a class="permalink" href="#AGPIOC_DEALLOCATE"><code class="Dv">AGPIOC_DEALLOCATE</code></a></dt>
  <dd>Free the previously allocated memory associated with the handle
    passed.</dd>
  <dt id="AGPIOC_BIND"><a class="permalink" href="#AGPIOC_BIND"><code class="Dv">AGPIOC_BIND</code></a></dt>
  <dd>Bind the allocated memory at given offset with the AGP aperture. Returns
      <code class="Er">EINVAL</code> if the memory is already bound or the
      offset is not at AGP page boundary. This <a class="Xr">ioctl(2)</a> takes
      the following structure:
    <div class="Bd Pp Li">
    <pre>typedef struct _agp_bind {
	int key;         /* tag of allocation            */
	off_t pg_start;  /* starting page to populate    */
} agp_bind;</pre>
    </div>
    <p class="Pp">The tag of allocation is the handle returned by
        <code class="Dv">AGPIOC_ALLOCATE</code>.</p>
  </dd>
  <dt id="AGPIOC_UNBIND"><a class="permalink" href="#AGPIOC_UNBIND"><code class="Dv">AGPIOC_UNBIND</code></a></dt>
  <dd>Unbind memory from the AGP aperture. Returns
      <code class="Er">EINVAL</code> if the memory is not bound. This
      <a class="Xr">ioctl(2)</a> takes the following structure:
    <div class="Bd Pp Li">
    <pre>typedef struct _agp_unbind {
	int key;                /* tag of allocation         */
	uint32_t priority;      /* priority for paging out   */
} agp_unbind;</pre>
    </div>
  </dd>
</dl>
</section>
<section class="Sh">
<h1 class="Sh" id="FILES"><a class="permalink" href="#FILES">FILES</a></h1>
<dl class="Bl-tag Bl-compact">
  <dt><span class="Pa">/dev/agpgart</span></dt>
  <dd>AGP device node.</dd>
</dl>
</section>
<section class="Sh">
<h1 class="Sh" id="SEE_ALSO"><a class="permalink" href="#SEE_ALSO">SEE
  ALSO</a></h1>
<p class="Pp"><a class="Xr">X(7)</a>
  (<span class="Pa">ports/x11/xorg</span>)</p>
</section>
<section class="Sh">
<h1 class="Sh" id="HISTORY"><a class="permalink" href="#HISTORY">HISTORY</a></h1>
<p class="Pp">The <code class="Nm">agp</code> driver first appeared in
    <span class="Ux">FreeBSD 4.1</span>.</p>
</section>
</div>
<table class="foot">
  <tr>
    <td class="foot-date">October 24, 2025</td>
    <td class="foot-os">FreeBSD 15.0</td>
  </tr>
</table>