History log of /freebsd-current/sys/dev/agp/agp_via.c
Revision Date Author Comments
# fdafd315 24-Nov-2023 Warner Losh <imp@FreeBSD.org>

sys: Automated cleanup of cdefs and other formatting

Apply the following automated changes to try to eliminate
no-longer-needed sys/cdefs.h includes as well as now-empty
blank lines in a row.

Remove /^#if.*\n#endif.*\n#include\s+<sys/cdefs.h>.*\n/
Remove /\n+#include\s+<sys/cdefs.h>.*\n+#if.*\n#endif.*\n+/
Remove /\n+#if.*\n#endif.*\n+/
Remove /^#if.*\n#endif.*\n/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/types.h>/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/param.h>/
Remove /\n+#include\s+<sys/cdefs.h>\n#include\s+<sys/capsicum.h>/

Sponsored by: Netflix


# 685dc743 16-Aug-2023 Warner Losh <imp@FreeBSD.org>

sys: Remove $FreeBSD$: one-line .c pattern

Remove /^[\s*]*__FBSDID\("\$FreeBSD\$"\);?\s*\n/


# 4d846d26 10-May-2023 Warner Losh <imp@FreeBSD.org>

spdx: The BSD-2-Clause-FreeBSD identifier is obsolete, drop -FreeBSD

The SPDX folks have obsoleted the BSD-2-Clause-FreeBSD identifier. Catch
up to that fact and revert to their recommended match of BSD-2-Clause.

Discussed with: pfg
MFC After: 3 days
Sponsored by: Netflix


# 74f84981 06-May-2022 John Baldwin <jhb@FreeBSD.org>

agp: Remove unused devclass arguments to DRIVER_MODULE.


# 4ce60b65 01-Sep-2020 Mateusz Guzik <mjg@FreeBSD.org>

agp: clean up empty lines in .c and .h files


# 718cf2cc 27-Nov-2017 Pedro F. Giffuni <pfg@FreeBSD.org>

sys/dev: further adoption of SPDX licensing ID tags.

Mainly focus on files that use BSD 2-Clause license, however the tool I
was using misidentified many licenses so this was mostly a manual - error
prone - task.

The Software Package Data Exchange (SPDX) group provides a specification
to make it easier for automated tools to detect and summarize well known
opensource licenses. We are gradually adopting the specification, noting
that the tags are considered only advisory and do not, in any way,
superceed or replace the license texts.


# dfa4d7fd 01-Jan-2013 Antoine Brodin <antoine@FreeBSD.org>

Remove unneeded semicolons.

Reviewed by: md5 of the object files


# 9e93aa23 15-Nov-2012 Eitan Adler <eadler@FreeBSD.org>

Remove unneeded header from agp: opt_bus.h

Tested with "make universe"

Approved by: cperciva
MFC after: 1 week


# a8de37b0 22-Oct-2012 Eitan Adler <eadler@FreeBSD.org>

This isn't functionally identical. In some cases a hint to disable
unit 0 would in fact disable all units.

This reverts r241856

Approved by: cperciva (implicit)


# 76b75122 21-Oct-2012 Eitan Adler <eadler@FreeBSD.org>

Now that device disabling is generic, remove extraneous code from the
device drivers that used to provide this feature.

Reviewed by: des
Approved by: cperciva
MFC after: 1 week


# a7d5f7eb 19-Oct-2010 Jamie Gritton <jamie@FreeBSD.org>

A new jail(8) with a configuration file, to replace the work currently done
by /etc/rc.d/jail.


# c79d8f1f 23-Jan-2010 Robert Noland <rnoland@FreeBSD.org>

MFC r200764

Fix a handful of issues with via agp support.

* Read the pci capability register to identify AGP 3 support
* Add missing smaller aperture sizes for AGP3 chips.
* Fix the aperture size calculation on AGP2 chips.
All sizes between 32M and 256M reported as 256M.
* Add \n to error string.


# 66ab1230 20-Dec-2009 Robert Noland <rnoland@FreeBSD.org>

Fix a handful of issues with via agp support.

* Read the pci capability register to identify AGP 3 support
* Add missing smaller aperture sizes for AGP3 chips.
* Fix the aperture size calculation on AGP2 chips.
All sizes between 32M and 256M reported as 256M.
* Add \n to error string.

This all seems to get the CLE266 EPIA-M board agp working properly, now
back to work on drm.

MFC after: 2 weeks


# 45d0290a 20-Mar-2009 Robert Noland <rnoland@FreeBSD.org>

vm_offset_t is unsigned and therefore can not be negative.
Avoid unnessecary compares.

Found with: Coverity Prevent(tm)
CID: 2362,4215,4214,4209,4208,2363,4211,4210,4213,4212

MFC after: 3 days


# cd6d5177 09-Mar-2009 Warner Losh <imp@FreeBSD.org>

Fix prototypes to be consistent.


# 129dec42 23-Jan-2009 Jung-uk Kim <jkim@FreeBSD.org>

- Add few VIA bridges to agp_via.c and connect it to amd64 build
as they support Intel Core/Core 2 and VIA Nano processors.
- Align "optional agp" in conf/files.* for consistency while I am here.


# d7f03759 19-Oct-2008 Ulf Lilleengen <lulf@FreeBSD.org>

- Import the HEAD csup code which is the basis for the cvsmode work.


# dbac8ff4 12-Nov-2007 John Baldwin <jhb@FreeBSD.org>

Move the agp(4) driver from sys/pci to sys/dev/agp. __FreeBSD_version was
bumped to 800004 to note the change though userland apps should not be
affected since they use <sys/agpio.h> rather than the headers in
sys/dev/agp.

Discussed with: anholt
Repocopy by: simon


# f82a1d49 30-Oct-2007 John Baldwin <jhb@FreeBSD.org>

Split agp_generic_detach() up into two routines: agp_free_cdev() destroys
/dev/agpgart and agp_free_res() frees resources like the BAR for the
aperture. Splitting this up lets chipset-specific detach routines
manipulate the aperture during their detach routines without panicing.

MFC after: 1 week
Reviewed by: anholt


# d332abba 20-Sep-2007 Kevin Lo <kevlo@FreeBSD.org>

- Add the device ID for the VIA VT3324 (CX700) chipset.
- Set and Get aperture size correctly for VIA's AGP3 chipsets.

Approved by: re (kensmith)


# c626f1fe 20-Dec-2005 John Baldwin <jhb@FreeBSD.org>

Change the various AGP drivers that attach to the Host-PCI bridge device to
attach to the hostb driver instead. This means that agp can now be loaded
at runtime (in theory at least). Also, the drivers no longer have to
explicity call device_verbose() to cancel out any earlier calls to
device_quiet() by the hostb(4) driver (this shows a limitation in new-bus,
drivers really shouldn't be doing device_quiet() until they know they are
going to drive that device, i.e. in attach).


# 11b0d582 25-Jun-2005 Eric Anholt <anholt@FreeBSD.org>

Make the initialization in the AGPv3 case match that of Linux. Fixes hangs on
X startup with DRI enabled, with a v3-capable card.

Tested by: Tom McLaughlin <tmclaugh@sdf.lonestar.org>
Approved by: re (scottl)


# d701c913 24-Feb-2005 Warner Losh <imp@FreeBSD.org>

Return BUS_PROBE_DEFAULT instead of 0.


# 124cfec0 30-Dec-2004 Eric Anholt <anholt@FreeBSD.org>

[1] Remove the generic bridge support from those drivers that had it. The
generic bridge support was biting us more than it helped, whenever a new chipset
came out from a vendor and misprogramming it caused strange hangs or corruption.
[2] Add a large number of PCI IDs based on what the linux drivers support.
Note that the new PCI IDs haven't been tested, they're just *likely* to work.
In particular the VIA AGP 8x chipsets are concerning, due to lack of testing,
possible issues (kern/69953), and not having a nice "does this bridge say it
would do 8x" function. However, this shouldn't make the situation worse, since
these chips would have probed in the past anyway.


# f49f2ca6 19-Aug-2004 David E. O'Brien <obrien@FreeBSD.org>

Unconditionally support the AMD64 GART HW.


# 3c749e3f 15-Aug-2004 David E. O'Brien <obrien@FreeBSD.org>

AMD64 on-CPU GART support.
This also applies to AMD64 HW running 'i386' OS.

Submitted by: Jung-uk Kim <jkim@niksun.com>
Integration by: obrien


# b6e05739 09-Aug-2004 Eric Anholt <anholt@FreeBSD.org>

Minimal fix to prevent crashes when an AGP v2 card is used with the new v3 VIA
chipsets, based on Linux's via-agp.c. On boot, the system selects which AGP
version to use based on the inserted card. If v2 was chosen, the chipset
needs to be programmed with the v2 registers still. Also included in kern/69953
are changes to make the programming of the v3 registers match linux, but that
will be left out until the need to do so is confirmed (want specs or a tester).

PR: kern/69953
Submitted by: Oleg Sharoiko <os@rsu.ru>
Tested by: Oleg Sharoiko <os@rsu.ru>, Geoff Speicher <geoff@speicher.org>
(full version from PR)


# b68c582e 01-Jul-2004 John Baldwin <jhb@FreeBSD.org>

Add support for the VIA Apollo KT400/400A/600 AGP host bridges which use
the VIA v3 register offsets.

PR: 68545
Submitted by: Ariff Abdullah <skywizard@mybsd.org.my>


# f11d01c3 30-May-2004 Poul-Henning Kamp <phk@FreeBSD.org>

Add missing <sys/module.h> includes


# d8a821e8 22-May-2004 Maxime Henrion <mux@FreeBSD.org>

Get rid of a lockmgr consumer by making agp(4) use a standard mutex,
since it's always acquiring the lock exclusively. This was tested
with X on an SMP box, with and without WITNESS.


# 92cb9c9b 13-May-2004 John Baldwin <jhb@FreeBSD.org>

Different VIA host bridges use different offsets to their AGP config
registers, so add a register offset array to the softc. We key off the
device ID to determine which set of register offsets. Currently the 8385
host bridge used on amd64 is the only bridge to use the AGP3_VIA_*
register offsets and all other bridges use the AGP_VIA_* offsets. It is
currently unclear if the AGP3_VIA_* offsets are for VIA bridges that
implement AGP 3.0 bridges or just for amd64 bridges.

Submitted by: Kenneth Culver culverk at sweetdreamsracing dot biz


# 25128fcc 03-Apr-2004 Nate Lawson <njl@FreeBSD.org>

Add the ability to disable agp devices at the loader prompt. Usage is
hint.agp.0.disabled="1"

Submitted by: jhb


# 19b7ffd1 22-Aug-2003 Warner Losh <imp@FreeBSD.org>

Prefer new location of pci include files (which have only been in the
tree for two or more years now), except in a few places where there's
code to be compatible with older versions of FreeBSD.


# fcccbacd 27-Jun-2003 John Baldwin <jhb@FreeBSD.org>

Sort the list of PCI ID's in numerical order and fix a whitespace bogon.


# 829ecb80 23-Jun-2003 Matthew N. Dodd <mdodd@FreeBSD.org>

Add a PCI ID for the Apollo Pro 133A.

PR: kern/46983
Submitted by: David Holm <david@realityrift.com>


# f4636c59 11-Jun-2003 David E. O'Brien <obrien@FreeBSD.org>

Use __FBSDID().


# f246e4a1 15-Apr-2003 Matthew N. Dodd <mdodd@FreeBSD.org>

- Express hard dependencies on bus (pci, isa, pccard) and
network layer (ether).
- Don't abuse module names to facilitate ifconfig module loading;
such abuse isn't really needed. (And if we do need type information
associated with a module then we should make it explicit and not
use hacks.)


# 7617255f 13-Nov-2002 Maxime Henrion <mux@FreeBSD.org>

Remove a bunch of #include "opt_pci.h".


# 7e9e7dc4 27-Aug-2002 Bruce Evans <bde@FreeBSD.org>

Include <sys/lockmgr.h> for old lock interfaces instead of depending on
namespace pollution in <sys/lock.h>.


# 7e59bf67 30-Aug-2001 Doug Rabson <dfr@FreeBSD.org>

Recognise VIA Apollo KT133A bridge.

PR: 30061
Submitted by: John Merryweather Cooper <jmcoopr@webmail.bmi.net>
MFC after: 1 week


# 52b3919d 05-Jul-2001 John Baldwin <jhb@FreeBSD.org>

Make these compile again by adding proc.h include for GIANT_REQUIRED
that is in included vm headers.


# 23955314 18-May-2001 Alfred Perlstein <alfred@FreeBSD.org>

Introduce a global lock for the vm subsystem (vm_mtx).

vm_mtx does not recurse and is required for most low level
vm operations.

faults can not be taken without holding Giant.

Memory subsystems can now call the base page allocators safely.

Almost all atomic ops were removed as they are covered under the
vm mutex.

Alpha and ia64 now need to catch up to i386's trap handlers.

FFS and NFS have been tested, other filesystems will need minor
changes (grabbing the vm lock when twiddling page properties).

Reviewed (partially) by: jake, jhb


# 59747216 09-Jun-2000 Doug Rabson <dfr@FreeBSD.org>

A driver for programming the AGP hardware. This is only very lightly
tested on Intel BX chipsets only. The other agp minidrivers are totally
untested.

The programming api is a subset of the Linux api and is only intended to
be enough for the X server to use. There is also an in-kernel api for the
use of other kernel modules such as the 3D DRI.