Commit Graph

1810 Commits (b47de8d5a3dbfc669c7ba9c6cb66a7491c30b537)

Author SHA1 Message Date
Robert Noland 957b10695b Move vblank_init to driver load time. 2009-02-27 18:16:17 -06:00
Robert Noland 948af0bd9b i915: Backport jbarnes gm45 vblank counter patch. 2009-02-25 14:20:52 -06:00
Robert Noland a44b4ca820 i915: A few whitespace cleanups. 2009-02-24 14:01:38 -06:00
Robert Noland 6870780428 radeon: Prepare radeon for msi support. 2009-02-24 12:28:42 -06:00
Robert Noland d45bc6667c i915: This was part of a sync to the intel driver at some point
-Remove the old TTM interface
	-Move register definitions to i915_reg.h
	-Rework the irq handler
2009-02-24 12:24:29 -06:00
Robert Noland 9f94e39f0d i915: Rip out the use of vblank_swap 2009-02-23 22:39:07 -06:00
Matthew Garrett 96ce587e8b nouveau: Add in-kernel backlight control support
Several nvidia-based systems don't support backlight control via the
standard ACPI control mechanisms. Instead, it's necessary for the driver
to modify the backlight control registers directly. This patch adds
support for determining whether the registers appear to be in use, and
if so registers a kernel backlight device to control them. The backlight
can then be controlled via existing userspace tools.

Signed-off-by: Matthew Garrett <mjg@redhat.com>
Signed-off-by: Ben Skeggs <bskeggs@redhat.com>
2009-02-18 13:48:33 +10:00
Ben Skeggs 084e143d0c nv40: fail completely if we don't have a ctxprog for the chipset 2009-02-15 22:06:18 +10:00
Ben Skeggs a4ac60a102 nv50: context info for chipset 0xa0 2009-02-15 21:52:19 +10:00
Ben Skeggs bc92c0edf3 drm/nv50: fix nv9x chipsets
NVIDIA do this fun little sequence after updating the PRAMIN page tables.

On 9xxx chips, none of the PRAMIN BAR bindings (except the initial one)
worked, hence the majority of the setup needed to create a channel
ended up in the wrong place, causing all sorts of fun.

This is done by NVIDIA on nv8x chips also, so we'll do it for them too,
even though they appear to work without it.
2009-02-11 11:22:41 +10:00
Ben Skeggs 7bbd605a21 drm/nv50: add context info for nv98
It won't work yet, just like the other 9xxx chips.  Real soon now :)
2009-02-11 10:12:43 +10:00
Ben Skeggs efcef2c2bc drm/nv50: use a slightly different initial context for nv96
I'm not 100% sure that the nv94 one we were using won't work.  The context
layouts are identical (well.. same ctxprog, so of course!), only a couple
of registers differ.  But, be safe until we actually get some 9xxx chips
working.
2009-02-10 09:11:41 +10:00
Ben Skeggs f43039c52c drm/nv50: correct ramfc pointer in channel header
Suprisingly the card still worked without this...
2009-02-10 09:11:35 +10:00
Ben Skeggs 889b811e31 drm/nv50: let the card handle the initial context switch
Our PFIFO/PGRAPH context save/load functions don't really work well
(at all?) on nv5x yet.  Depending on what random state the card is
in before the drm loads, fbcon probably won't work correctly.

Luckily we've setup the GPU in such a way that it'll actually do a
hw context switch for the first context.  Not sure of how successful
this'd be currently on the older chips (actually, pretty sure it won't
work), so NV50 only for now.
2009-02-10 09:11:27 +10:00
Stuart Bennett 9c8d634e68 nouveau: don't try to traverse non-existent lists
Fixes nouveau_ioctl_mem_free Oops
2009-02-07 21:20:17 +00:00
Ben Skeggs cb85630c02 nouveau: bring in new mm api definitions, without the actual mm code
Use of the new bits is guarded with a mm_enabled=0 hardcode.
2009-02-04 13:22:56 +10:00
Stephane Marchesin 39755db856 Remove the "nv" driver. 2009-02-02 23:47:11 +01:00
Stuart Bennett 854bd8f2ca nouveau: don't save channel context if it has recently become invalid
Bug exposed by DDX change d9da090c
2009-01-29 23:59:47 +00:00
Stuart Bennett 408fc85a21 nouveau: no suspend support for nv50+ 2009-01-29 23:53:01 +00:00
Jesse Barnes 2fa5f28eee intel: libdrm support for fence management in execbuf
This patch tries to use the available fence count to figure out whether a
given batch can succeed or not (just like the aperture check).

Signed-off-by: Jesse Barnes <jbarnes@virtuousgeek.org>
Signed-off-by: Eric Anholt <eric@anholt.net>
2009-01-27 17:23:42 -08:00
Ben Skeggs e6a062c21a nv50: support chipset NV96
ctxprog seen in okias' trace identical to one we use on NV94, assuming
the initial context values for NV94 will work here too.
2009-01-27 08:36:33 +10:00
Ben Skeggs 753d4c39ff nv04-nv40: correct RAMHT size 2009-01-27 08:36:08 +10:00
Ben Skeggs ac8b3308b9 nv50: ack nsource to prevent continuous protection fault irqs 2009-01-12 10:33:48 +10:00
Robert Noland 58d557c73b [FreeBSD] Fix build on FreeBSD after modesetting import. 2008-12-23 13:56:23 -05:00
Dave Airlie b48bd3a036 radeon: only write irq regs if irq is enabled 2008-12-23 11:30:37 +10:00
Eric Anholt dfd7fdafd8 intel: Rename plane[AB]* back to pipe[AB]*.
The values are really going to continue meaning pipe, not plane, and that's
what they're called in the kernel copy of the header.  Userland hasn't ever
made the switch to pipe!=plane, since userland checks are based on DRM
version, which is still stuck at 1.6.  However, Mesa did start using
plane[AB] names, so provide a compat define.
2008-12-22 16:03:35 -08:00
Eric Anholt d221e00105 intel: Sync GEM ioctl comments for easier diffing against the kernel. 2008-12-22 16:03:35 -08:00
Jesse Barnes 731cd5526e libdrm: add mode setting files
Add mode setting files to libdrm, including xf86drmMode.* and the new
drm_mode.h header.  Also add a couple of tests to sanity check the
kernel interfaces and update code to support them.
2008-12-17 10:11:37 -08:00
Jesse Barnes 9583c099b4 Revert "Merge branch 'modesetting-gem'"
This reverts commit 6656db1055.

We really just want the libdrm and ioctl bits, not all the driver
stuff.
2008-12-10 15:50:22 -08:00
Jesse Barnes d5d5aca7f9 Merge branch 'master' into modesetting-gem 2008-12-03 11:53:36 -08:00
Ben Skeggs 7e4e0fbbb8 nv50: support NV94 chipset 2008-11-23 18:49:09 +11:00
Ben Skeggs 52232ad702 nv50: update context-related tables for original 8800GTS
I either messed up when I pulled these from a mmio-trace last time, or
the previous values didn't work on my card.  Hopefully it's the former!

In any case, at least one of the original NV50 chipsets work now.
2008-11-21 13:18:58 +11:00
Jesse Barnes 2e2fd6c632 DRM: make drm_map_type match upstream kernel
Since the TTM type isn't upstream yet, we need to make sure libdrm uses
what the kernel uses, which is _DRM_GEM = 6.
2008-11-20 11:00:29 -08:00
Jesse Barnes 5923831baf DRM: make drm_map_type match kernel
GEM is upstream, but TTM isn't, so _DRM_GEM needs to be 6, not 7.
2008-11-20 10:57:33 -08:00
Stephane Marchesin c029ed2510 Unbreak drm build. 2008-11-19 23:17:27 +01:00
Jesse Barnes c67a83dfe1 Merge branch 'modesetting-gem' of ssh://git.freedesktop.org/git/mesa/drm into modesetting-gem 2008-11-19 12:42:49 -08:00
Jerome Glisse 7270731a8b radeon: protect cs ioctl atomic part with a mutex
A small subset of CS need to be atomic (relocation+IB commit to
ring) right now, because of the way relocation are handled, we
need to protect the whole ioctl.
2008-11-16 18:11:00 +01:00
Jesse Barnes 965b4d662a Merge branch 'master' into modesetting-gem
Conflicts:

	libdrm/Makefile.am
	libdrm/intel/intel_bufmgr.h
	libdrm/intel/intel_bufmgr_fake.c
	libdrm/intel/intel_bufmgr_gem.c
	shared-core/drm.h
	shared-core/i915_dma.c
	shared-core/i915_irq.c
	shared-core/radeon_cp.c
	shared-core/radeon_drv.h
2008-11-13 15:30:06 -08:00
Jesse Barnes 276c07d885 libdrm: add support for i915 GTT mapping ioctl
Add a drm_intel_gem_bo_map_gtt() function for mapping a buffer object
through the aperture rather than directly to its CPU cacheable memory.
2008-11-13 13:52:04 -08:00
Jakob Bornecrantz 9a4cb7eab4 mode: Minor reodering and renaming 2008-11-12 19:17:18 +01:00
Jakob Bornecrantz 17789a409d mode: Reorder the ioctls and numbering
This is to fill in the gaps left by the removal of
	the hotplug ioctls. And they also look better :)
2008-11-12 19:10:50 +01:00
Jakob Bornecrantz 1ead45c8f0 mode: Remove hotplug support from ioctl interface 2008-11-12 18:40:04 +01:00
Jakob Bornecrantz 13948c635d mode: Unify types for ids and strings 2008-11-12 18:16:38 +01:00
Dave Airlie 15464f5181 radeon: add gart useable size to report to userspace 2008-11-10 15:38:32 +10:00
Dave Airlie 994f240503 radeon: fix ring tail overflow issue since alignment 2008-11-10 15:25:27 +10:00
Dave Airlie 758376e6eb radeon: disable HDP read cache for now 2008-11-10 15:25:12 +10:00
Dave Airlie 08ef5b5e67 radeon: force all ring writes to 16-dword alignment. 2008-11-10 15:24:42 +10:00
Jerome Glisse 7abb8416a7 radeon: add more packet3 relocations handling 2008-11-09 18:48:46 +01:00
Dave Airlie 68fcb7770e radeon: make build again 2008-11-03 09:58:12 +10:00
Dave Airlie 0e1df6216e radeon: add mtrr support for VRAM aperture. 2008-11-03 09:52:25 +10:00