003 File Manager
Current Path:
/usr/src/sys/dev/agp
usr
/
src
/
sys
/
dev
/
agp
/
📁
..
📄
agp.c
(24.2 KB)
📄
agp_ali.c
(6.83 KB)
📄
agp_amd.c
(10.51 KB)
📄
agp_amd64.c
(13.35 KB)
📄
agp_apple.c
(7.57 KB)
📄
agp_ati.c
(9.93 KB)
📄
agp_i810.c
(61.38 KB)
📄
agp_i810.h
(3.96 KB)
📄
agp_if.m
(3.81 KB)
📄
agp_intel.c
(11.72 KB)
📄
agp_nvidia.c
(12.05 KB)
📄
agp_sis.c
(7.31 KB)
📄
agp_via.c
(11.22 KB)
📄
agppriv.h
(3.83 KB)
📄
agpreg.h
(12.58 KB)
📄
agpvar.h
(4.37 KB)
Editing: agp_if.m
#- # Copyright (c) 2000 Doug Rabson # All rights reserved. # # Redistribution and use in source and binary forms, with or without # modification, are permitted provided that the following conditions # are met: # 1. Redistributions of source code must retain the above copyright # notice, this list of conditions and the following disclaimer. # 2. Redistributions in binary form must reproduce the above copyright # notice, this list of conditions and the following disclaimer in the # documentation and/or other materials provided with the distribution. # # THIS SOFTWARE IS PROVIDED BY THE AUTHOR AND CONTRIBUTORS ``AS IS'' AND # ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE # IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE # ARE DISCLAIMED. IN NO EVENT SHALL THE AUTHOR OR CONTRIBUTORS BE LIABLE # FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL # DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS # OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS INTERRUPTION) # HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN CONTRACT, STRICT # LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY # OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF # SUCH DAMAGE. # # $FreeBSD$ # #include <sys/bus.h> # # The AGP interface is used internally to the agp driver to isolate the # differences between various AGP chipsets into chipset mini drivers. It # should not be used outside the AGP driver. The kernel api for accessing # AGP functionality is described in <dev/agp/agpvar.h> # INTERFACE agp; CODE { static int null_agp_chipset_flush(device_t dev) { return (ENXIO); } }; # # Return the current aperture size. # METHOD u_int32_t get_aperture { device_t dev; }; # # Set the size of the aperture. Return EINVAL on error or 0 on success. # METHOD int set_aperture { device_t dev; u_int32_t aperture; }; # # Bind a single page in the AGP aperture to a given physical address. # The offset is a byte offset within the aperture which must be # aligned to an AGP page boundary. # METHOD int bind_page { device_t dev; vm_offset_t offset; vm_offset_t physical; }; # # Unbind a single page in the AGP aperture. # METHOD int unbind_page { device_t dev; vm_offset_t offset; }; # # Flush the GATT TLB. This is used after a call to bind_page to # ensure that any mappings cached in the chipset are discarded. # METHOD void flush_tlb { device_t dev; }; # # Enable the agp hardware with the relavent mode. The mode bits are # defined in <dev/agp/agpreg.h> # METHOD int enable { device_t dev; u_int32_t mode; }; # # Allocate memory of a given type. The type is a chipset-specific # code which is used by certain integrated agp graphics chips # (basically just the i810 for now) to access special features of # the chipset. An opaque handle representing the memory region is # returned and can be used as an argument to free_memory, bind_memory # and unbind_memory. # # The size is specified in bytes but must be a multiple of the AGP # page size. # METHOD struct agp_memory * alloc_memory { device_t dev; int type; vm_size_t size; }; # # Free a memory region previously allocated with alloc_memory. Return # EBUSY if the memory is bound. # METHOD int free_memory { device_t dev; struct agp_memory *mem; }; # # Bind a memory region to a specific byte offset within the chipset's # AGP aperture. This effectively defines a range of contiguous # physical address which alias the (possibly uncontiguous) pages in # the memory region. # METHOD int bind_memory { device_t dev; struct agp_memory *mem; vm_offset_t offset; }; # # Unbind a memory region bound with bind_memory. # METHOD int unbind_memory { device_t dev; struct agp_memory *handle; }; METHOD int chipset_flush { device_t dev; } DEFAULT null_agp_chipset_flush;
Upload File
Create Folder