[OpenBSD]

Manual Page Search Parameters

AGP(4) Device Drivers Manual AGP(4)

NAME

agpaccelerated graphics port driver

SYNOPSIS

agp* at vga?

DESCRIPTION

The agp driver provides support for programming the AGP GART through ioctl(2). This support is used by the X server on some architectures.
The following ioctl(2) operations can be performed on /dev/agp*, and are defined in ⟨sys/agpio.h⟩:
 
 
AGPIOC_INFO
Returns information about the AGP subsystem. The result is a pointer to the following structure:
typedef struct _agp_info { 
	agp_version version;  /* version of driver (unused)   */ 
	u_int32_t bridge_id;  /* bridge vendor/device         */ 
	u_int32_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;
    
 
 
AGPIOC_ACQUIRE
Acquire control of the AGP chipset for use by this client. Returns EBUSY if the AGP chipset is already acquired by another client.
 
 
AGPIOC_RELEASE
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.
 
 
AGPIOC_SETUP
Enable the AGP hardware with the relevant mode. This ioctl(2) takes the following structure:
typedef struct _agp_setup { 
	u_int32_t agp_mode;   /* mode info of bridge */ 
} agp_setup;
    
The mode bits are defined in ⟨sys/agpio.h⟩.
 
 
AGPIOC_ALLOCATE
Allocate physical memory suitable for mapping into the AGP aperture. This ioctl(2) takes the following structure:
typedef struct _agp_allocate { 
	int key;              /* tag of allocation            */ 
	size_t pg_count;      /* number of pages              */ 
	u_int32_t type;       /* 0 == normal, other devspec   */ 
	u_int32_t physical;   /* device specific (some devices 
			       * need a phys address of the 
			       * actual page behind the gatt 
			       * table)                       */ 
} agp_allocate;
    
It returns a handle to the allocated memory.
 
 
AGPIOC_DEALLOCATE
Free the previously allocated memory associated with the handle passed.
 
 
AGPIOC_BIND
Bind the allocated memory at a given offset with the AGP aperture. Returns EINVAL if the memory is already bound or the offset is not at an AGP page boundary. This ioctl(2) takes the following structure:
typedef struct _agp_bind { 
	int key;         /* tag of allocation            */ 
	off_t pg_start;  /* starting page to populate    */ 
} agp_bind;
    
The tag of allocation is the handle returned by AGPIOC_ALLOCATE.
 
 
AGPIOC_UNBIND
Unbind memory from the AGP aperture. Returns EINVAL if the memory is not bound. This ioctl(2) takes the following structure:
typedef struct _agp_unbind { 
	int key;                /* tag of allocation         */ 
	u_int32_t priority;     /* priority for paging out   */ 
} agp_unbind;
    

FILES

/dev/agp?
AGP GART device special files.
/dev/agpgart
AGP GART device special file.

SEE ALSO

ioctl(2), vga(4)

HISTORY

The agp driver first appeared in FreeBSD 4.1. It was adopted in NetBSD 1.6. The driver was then ported in parts to OpenBSD, and fully integrated in OpenBSD 4.3.
March 16, 2008 OpenBSD-5.4