OSDN Git Service

android-x86/external-libdrm.git
16 years agoi915: Re-report breadcrumbs on poll to the fence manager,
Thomas Hellstrom [Tue, 5 Feb 2008 09:35:56 +0000 (10:35 +0100)]
i915: Re-report breadcrumbs on poll to the fence manager,

since a breadcrumb may actually turn up before a corresponding fence object
has been placed on the fence ring.

16 years agonouveau: make nv34 work every time, not just every 2nd time
Stuart Bennett [Mon, 28 Jan 2008 22:59:26 +0000 (22:59 +0000)]
nouveau: make nv34 work every time, not just every 2nd time

And make nv30_graph_init a bit more like mmio-traces

16 years agonouveau: NV40 can/should now be able to run after the blob.
Maarten Maathuis [Sat, 2 Feb 2008 11:46:31 +0000 (12:46 +0100)]
nouveau: NV40 can/should now be able to run after the blob.

- Moved the fix from the ddx to drm, because it seemed more appropriate.
- Don't be shy, report if it works for you or not.

16 years agoAdd an fence_class_manager::last_queued_sequence member, since a
Thomas Hellstrom [Thu, 31 Jan 2008 13:11:12 +0000 (14:11 +0100)]
Add an fence_class_manager::last_queued_sequence member, since a
sequence number may actually turn up before the corresponding fence
object has been queued on the ring.

Fence drivers can use this member to determine whether a
sequence number must be re-reported.

16 years agoi915: Avoid calling drm_fence_flush_old excessively.
Thomas Hellstrom [Wed, 30 Jan 2008 21:14:02 +0000 (22:14 +0100)]
i915: Avoid calling drm_fence_flush_old excessively.

16 years agoSimplify the fencing code and differentiate between flushes and
Thomas Hellstrom [Wed, 30 Jan 2008 21:06:02 +0000 (22:06 +0100)]
Simplify the fencing code and differentiate between flushes and
waiting types.
Add a "command_stream_barrier" method to the bo driver.

16 years agonv40: some more nv67 changes
Ben Skeggs [Wed, 30 Jan 2008 00:40:13 +0000 (11:40 +1100)]
nv40: some more nv67 changes

With some luck the drm-side will be OK now for this chipset.

16 years agoAdd new RV380 pci id
Mirko [Tue, 29 Jan 2008 15:11:27 +0000 (10:11 -0500)]
Add new RV380 pci id

bug 14289

16 years agoFix hibernate save/restore of VGA attribute regs
Jesse Barnes [Tue, 29 Jan 2008 05:05:22 +0000 (21:05 -0800)]
Fix hibernate save/restore of VGA attribute regs

In hibernate, we may end up calling the VGA save regs function twice, so we
need to make sure it's idempotent.  That means leaving ARX in index mode after
the first save operation.  Fixes hibernate on 965.

16 years agodrm: add initial rs690 support for drm.
Maciej Cencora [Sun, 27 Jan 2008 02:50:31 +0000 (12:50 +1000)]
drm: add initial rs690 support for drm.

This adds support for configuring the RS690 GART.

16 years agomach64: fix after vblank-rework
George Sapountzis [Fri, 25 Jan 2008 14:54:29 +0000 (16:54 +0200)]
mach64: fix after vblank-rework

don't disable vblank interrupts (similar to r128)

16 years agoFixup modeset ioctl number & typedef usage
Jesse Barnes [Fri, 25 Jan 2008 04:59:51 +0000 (20:59 -0800)]
Fixup modeset ioctl number & typedef usage

Should be 0x08 rather than 0xa0, and shouldn't use typedefs.

16 years agoMerge commit 'airlied/i915-ttm-cfu'
Eric Anholt [Thu, 24 Jan 2008 20:32:08 +0000 (12:32 -0800)]
Merge commit 'airlied/i915-ttm-cfu'

This requires updated Mesa to handle the new relocation format.

16 years agoRemove broken 'in vblank' accounting
Jesse Barnes [Thu, 24 Jan 2008 16:57:04 +0000 (08:57 -0800)]
Remove broken 'in vblank' accounting

We need to return an accurate vblank count to the callers of
->get_vblank_counter, and in the Intel case the actual frame count
register isn't udpated until the next active line is displayed, so we
need to return one more than the frame count register if we're currently
in a vblank period.

However, none of the various ways of doing this is working yet, so
disable the logic for now.  This may result in a few missed events, but
should fix the hangs some people have seen due to the current code
tripping the wraparound logic in drm_update_vblank_count.

16 years agoi915: fix missing header when copying data from userspace
Dave Airlie [Thu, 24 Jan 2008 05:18:09 +0000 (15:18 +1000)]
i915: fix missing header when copying data from userspace

16 years agoi915 make relocs use copy from user
Dave Airlie [Thu, 24 Jan 2008 04:37:40 +0000 (14:37 +1000)]
i915 make relocs use copy from user

Switch relocs to using copy from user and remove index and pass buffer
handles in instead.

16 years agoFix thinko in get_vblank_counter
Jesse Barnes [Wed, 23 Jan 2008 16:39:57 +0000 (08:39 -0800)]
Fix thinko in get_vblank_counter

Should use vtotal not htotal to figure out if we're in a vblank period.

16 years agoFix IS_I915G macro
Jesse Barnes [Wed, 23 Jan 2008 16:38:01 +0000 (08:38 -0800)]
Fix IS_I915G macro

One to many parantheses...

16 years agonouveau: Fix warning in nouveau_mem.c
Maarten Maathuis [Wed, 23 Jan 2008 15:40:19 +0000 (16:40 +0100)]
nouveau: Fix warning in nouveau_mem.c

16 years agoi915/flush: get the ret the right way around
Dave Airlie [Wed, 23 Jan 2008 06:45:09 +0000 (16:45 +1000)]
i915/flush: get the ret the right way around

16 years agodrm/i915: add support for E7221
Dave Airlie [Wed, 23 Jan 2008 06:44:51 +0000 (16:44 +1000)]
drm/i915: add support for E7221

16 years agoCorrect vblank count value
Jesse Barnes [Tue, 22 Jan 2008 23:16:01 +0000 (15:16 -0800)]
Correct vblank count value

The frame count registers don't increment until the start of the next
frame, so make sure we return an incremented count if called during the
actual vblank period.

16 years agoi915 irq fixes
Jesse Barnes [Tue, 22 Jan 2008 21:11:29 +0000 (13:11 -0800)]
i915 irq fixes

Ack the IRQs correctly (PIPExSTAT first followed by IIR).  Don't read
vblank counter registers on disabled pipes (might hang otherwise).  And
deal with flipped pipe/plane mappings if present.

16 years agoMerge branch 'master' into vblank-rework, including mach64 support
Jesse Barnes [Tue, 22 Jan 2008 17:42:37 +0000 (09:42 -0800)]
Merge branch 'master' into vblank-rework, including mach64 support

Conflicts:

linux-core/drmP.h
linux-core/drm_drv.c
shared-core/i915_drv.h
shared-core/i915_irq.c
shared-core/mga_irq.c
shared-core/radeon_irq.c
shared-core/via_irq.c

Mostly trivial conflicts.

mach64 support from Mathieu Bérard.

16 years agoRevert "Fix pipe<->plane mapping vs. vblank handling (again)"
Dave Airlie [Tue, 22 Jan 2008 03:39:28 +0000 (14:39 +1100)]
Revert "Fix pipe<->plane mapping vs. vblank handling (again)"

This reverts commit bfc29606e4a818897eebca46a5e23bbe7bc3ce25.

This regresses i915 here for me I can't get greater than 0.333 fps with gears

16 years agonouveau: don't forget NV80.
Stephane Marchesin [Mon, 21 Jan 2008 20:11:47 +0000 (21:11 +0100)]
nouveau: don't forget NV80.

16 years agonouveau: new card family for old card designs.
Stephane Marchesin [Mon, 21 Jan 2008 20:01:28 +0000 (21:01 +0100)]
nouveau: new card family for old card designs.

16 years agoi915: fix invalid opcode exception on cpus without clflush
Kyle McMartin [Thu, 17 Jan 2008 23:51:56 +0000 (18:51 -0500)]
i915: fix invalid opcode exception on cpus without clflush

i915_flush_ttm was unconditionally executing a clflush instruction
to (obviously) flush the cache. Instead, check if the cpu supports
clflush, and if not, fall back to calling wbinvd to flush the entire
cache.

Signed-off-by: Kyle McMartin <kmcmartin@redhat.com>
16 years agoAdd additional explanation of DRM_BO_FLAG_CACHED_MAPPED before I forget again.
Eric Anholt [Mon, 7 Jan 2008 21:10:50 +0000 (13:10 -0800)]
Add additional explanation of DRM_BO_FLAG_CACHED_MAPPED before I forget again.

16 years agoi915: Add chipset id for Intel Integrated Graphics Device
Zhenyu Wang [Wed, 9 Jan 2008 03:30:35 +0000 (11:30 +0800)]
i915: Add chipset id for Intel Integrated Graphics Device

This adds new chipset id in drm.

Signed-off-by: Zhenyu Wang <zhenyu.z.wang@intel.com>
16 years agoProperly propagate the user-space fence flags.
Thomas Hellstrom [Tue, 15 Jan 2008 09:03:41 +0000 (10:03 +0100)]
Properly propagate the user-space fence flags.
This avoids a sync flush when user-space has already programmed
and MI_FLUSH in the batchbuffer.

16 years agoDefine i915_compat.c upper_32_bits for kernels < 2.6.21
Thomas Hellstrom [Tue, 15 Jan 2008 08:46:59 +0000 (09:46 +0100)]
Define i915_compat.c upper_32_bits for kernels < 2.6.21

16 years ago this is to fix a deadloop in drm hang system issue.
Zou Nan hai [Tue, 15 Jan 2008 01:19:02 +0000 (09:19 +0800)]
 this is to fix a deadloop in drm hang system issue.
 (1 << bits) is an undefined value when bits == 32.
 gcc may generate 1 with this expression
 which will lead to an infinite retry loop in
 drm_ht_just_insert_please.
 Because of the different implement of hash_long,
 this  issue is more frequenly see on 64 bit system

16 years agofixup i915 compat resource allocation
Dave Airlie [Mon, 14 Jan 2008 09:36:10 +0000 (19:36 +1000)]
fixup i915 compat resource allocation

16 years agonouveau: make mem alloc debug a little more verbose.
Stephane Marchesin [Mon, 14 Jan 2008 02:16:40 +0000 (03:16 +0100)]
nouveau: make mem alloc debug a little more verbose.

16 years agonv05: enable ctx/op methods, and ignore patch valid failures.
Ben Skeggs [Fri, 11 Jan 2008 01:51:08 +0000 (12:51 +1100)]
nv05: enable ctx/op methods, and ignore patch valid failures.

Yes, I'm quite aware "real" nv04 doesn't support this, hopefully the GPU
will just ignore those PGRAPH_DEBUG_3 bits on that hw.

16 years agonouveau: AGP reset correction - don't touch FW bit
Stuart Bennett [Mon, 7 Jan 2008 17:38:18 +0000 (17:38 +0000)]
nouveau: AGP reset correction - don't touch FW bit

16 years agonv50: more small changes
Ben Skeggs [Mon, 7 Jan 2008 07:56:44 +0000 (18:56 +1100)]
nv50: more small changes

16 years agonv50: oops, lost some state saving along the way somewhere.
Ben Skeggs [Mon, 7 Jan 2008 07:18:51 +0000 (18:18 +1100)]
nv50: oops, lost some state saving along the way somewhere.

xf86-video-nv will now work again after nouveau.

16 years agonv50: hook up timer funcs...
Ben Skeggs [Mon, 7 Jan 2008 06:23:31 +0000 (17:23 +1100)]
nv50: hook up timer funcs...

16 years agonv50: abort on chips without ctx ucode
Ben Skeggs [Mon, 7 Jan 2008 06:10:36 +0000 (17:10 +1100)]
nv50: abort on chips without ctx ucode

16 years agonv50: some needed ctx vals
Ben Skeggs [Mon, 7 Jan 2008 06:07:59 +0000 (17:07 +1100)]
nv50: some needed ctx vals

16 years agonv50: use dummy page in gart tables
Ben Skeggs [Mon, 7 Jan 2008 05:55:20 +0000 (16:55 +1100)]
nv50: use dummy page in gart tables

Just to be safe, we don't really know exactly how the tables work yet, so
we can't be certain there's a way to say "page not present".

16 years agonv50: some cleanups + small changes
Ben Skeggs [Mon, 7 Jan 2008 05:52:47 +0000 (16:52 +1100)]
nv50: some cleanups + small changes

16 years agoNouveau: ppc oops.
Stephane Marchesin [Mon, 7 Jan 2008 05:11:33 +0000 (06:11 +0100)]
Nouveau: ppc oops.

16 years agoNouveau: move PPC bios copy to firstopen.
Stephane Marchesin [Mon, 7 Jan 2008 04:54:05 +0000 (05:54 +0100)]
Nouveau: move PPC bios copy to firstopen.

16 years agonouveau: Add ctx_voodoo for NV86
Jeremy Kolb [Sun, 6 Jan 2008 15:09:47 +0000 (10:09 -0500)]
nouveau: Add ctx_voodoo for NV86

16 years agodrm: One forgotten rename of 'mask' to 'proposed_flags'.
Pekka Paalanen [Fri, 4 Jan 2008 21:47:57 +0000 (23:47 +0200)]
drm: One forgotten rename of 'mask' to 'proposed_flags'.

Due to commit d1187641d64f442968a3b9ea6a19de6cdd45acd4.

16 years agovia: add P4M900 pci id.
Xavier Bachelot [Fri, 4 Jan 2008 06:29:04 +0000 (16:29 +1000)]
via: add P4M900 pci id.

bug 12108

16 years ago[PATCH] nouveau: reset AGP on init for < nv40
Stuart Bennett [Thu, 3 Jan 2008 16:57:55 +0000 (16:57 +0000)]
[PATCH] nouveau: reset AGP on init for < nv40

This is necessary for AGP to work after running bios init scripts on nv3x, and
is seen in mmio traces of all cards (nv04-nv4x)

I'm not making the equivalent change to nv40_mc.c, as early cards (6200, 6800gt)
use the 0x000018XX PBUS and later cards use the 0x000880XX PBUS and I don't know
the effects of using the wrong one

16 years ago[PATCH] nouveau: Fix nv20/30 context loading
Stuart Bennett [Thu, 27 Dec 2007 01:10:52 +0000 (01:10 +0000)]
[PATCH] nouveau: Fix nv20/30 context loading

Don't set the context as valid until it has been loaded

16 years agomach64: some more minor cleanups
Dave Airlie [Thu, 3 Jan 2008 07:44:04 +0000 (17:44 +1000)]
mach64: some more minor cleanups

16 years agomach64: cleanup some of the macro formatting
Dave Airlie [Thu, 3 Jan 2008 07:10:30 +0000 (17:10 +1000)]
mach64: cleanup some of the macro formatting

16 years agodrm: cleanup DRM_DEBUG() parameters
Márton Németh [Thu, 3 Jan 2008 06:56:04 +0000 (16:56 +1000)]
drm: cleanup DRM_DEBUG() parameters

As DRM_DEBUG macro already prints out the __FUNCTION__ string (see
drivers/char/drm/drmP.h), it is not worth doing this again. At some
other places the ending "\n" was added.

airlied:- I cleaned up a few that this patch missed also

16 years agoMerge branch 'r500-support'
Dave Airlie [Thu, 3 Jan 2008 06:05:13 +0000 (16:05 +1000)]
Merge branch 'r500-support'

16 years agoremove duplicate pciids
Dave Airlie [Thu, 3 Jan 2008 06:03:05 +0000 (16:03 +1000)]
remove duplicate pciids

16 years agoi915: return fence argument from i915_execbuffer ioctl32 routine
Xiang, Haihao [Wed, 26 Dec 2007 09:13:58 +0000 (17:13 +0800)]
i915: return fence argument from i915_execbuffer ioctl32 routine

16 years agoi915: i915_execbuffer ioctl32 routine, fix #13732
Xiang, Haihao [Tue, 25 Dec 2007 08:57:14 +0000 (16:57 +0800)]
i915: i915_execbuffer ioctl32 routine, fix #13732

16 years agoChange drm_bo_type_dc to drm_bo_type_device and comment usage of this value.
Keith Packard [Mon, 17 Dec 2007 06:00:45 +0000 (22:00 -0800)]
Change drm_bo_type_dc to drm_bo_type_device and comment usage of this value.

I couldn't figure out what drm_bo_type_dc was for; Dave Airlie finally clued
me in that it was the 'normal' buffer objects with kernel allocated pages
that could be mmapped from the drm device file.

I thought that 'drm_bo_type_device' was a more descriptive name.

I also added a bunch of comments describing the use of the type enum values and
the functions that use them.

16 years agoRename inappropriately named 'mask' fields to 'proposed_flags' instead.
Keith Packard [Mon, 17 Dec 2007 04:16:50 +0000 (20:16 -0800)]
Rename inappropriately named 'mask' fields to 'proposed_flags' instead.

Flags pending validation were stored in a misleadingly named field, 'mask'.
As 'mask' is already used to indicate pieces of a flags field which are
changing, it seems better to use a name reflecting the actual purpose of
this field. I chose 'proposed_flags' as they may not actually end up in
'flags', and in an case will be modified when they are moved over.

This affects the API, but not ABI of the user-mode interface.

16 years agoUse dummy_read_page for unpopulated kernel-allocated ttm pages.
Keith Packard [Sun, 16 Dec 2007 09:47:51 +0000 (01:47 -0800)]
Use dummy_read_page for unpopulated kernel-allocated ttm pages.

Previously, dummy_read_page was used only for read-only user allocations; it
filled in pages that were not present in the user address map (presumably,
these were allocated but never written to pages).

This patch allows them to be used for read-only ttms allocated from the
kernel, so that applications can over-allocate buffers without forcing every
page to be allocated.

16 years agoMove dummy_read_page from drm_ttm_set_user to drm_ttm_create.
Keith Packard [Sun, 16 Dec 2007 09:12:07 +0000 (01:12 -0800)]
Move dummy_read_page from drm_ttm_set_user to drm_ttm_create.

I'm hoping to use the dummy_read_page for kernel allocated buffers to avoid
allocating extra pages for read-only buffers (like vertex and batch buffers).
This also eliminates the 'write' parameter to drm_ttm_set_user and just
has DRM_TTM_PAGE_WRITE passed into drm_ttm_create.

16 years agoClean up and document drm_ttm.c APIs. drm_bind_ttm -> drm_ttm_bind.
Keith Packard [Sun, 16 Dec 2007 08:54:25 +0000 (00:54 -0800)]
Clean up and document drm_ttm.c APIs. drm_bind_ttm -> drm_ttm_bind.

Aside from changing drm_bind_ttm to drm_ttm_bind, this patch
adds only documentation and fixes the functions inside drm_ttm.c
to all be prefixed with drm_ttm_.

16 years agodrm: don't cast a pointer to pointer of list_head
Li Zefan [Sun, 16 Dec 2007 23:50:45 +0000 (09:50 +1000)]
drm: don't cast a pointer to pointer of list_head

The casting is safe only when the list_head member is the first member of
the structure.

16 years agoWhile reading some code I stumbled across the use of 'err' in
Jesper Juhl [Sun, 16 Dec 2007 23:45:03 +0000 (09:45 +1000)]
While reading some code I stumbled across the use of 'err' in
drivers/char/drm/mga_dma.c::mga_do_cleanup_dma() and I think there's a small
problem.

The variable is only used inside #if __OS_HAS_AGP which is fine, but all
that
ever happens is an assignment to the variable - it is never actually used
for
anything.  The variable is nicely initialized to zero which is also what the
return statement at the end of function returns (always at the moment).

It looks to me like that function should be returning 'err' instead of
always
just returning 0.  Here's a patch to do that.

Signed-off-by: Jesper Juhl <jesper.juhl@gmail.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
16 years agoDocument drm_ttm_set_user.
Keith Packard [Fri, 14 Dec 2007 21:19:35 +0000 (13:19 -0800)]
Document drm_ttm_set_user.

Add a comment explaining the parameters for this function

16 years agoDocument drm_buffer_object_validate function.
Keith Packard [Fri, 14 Dec 2007 21:19:09 +0000 (13:19 -0800)]
Document drm_buffer_object_validate function.

Just add documentation for this function, no code changes.

16 years agoDocument fence_class mess in drm_bo_setstatus_ioctl
Keith Packard [Fri, 14 Dec 2007 20:49:22 +0000 (12:49 -0800)]
Document fence_class mess in drm_bo_setstatus_ioctl

drmBOSetStatus does not bother to set the fence_class parameter.
Fortunately, drm_bo_setstatus_ioctl doesn't end up using it as it
calls drm_bo_handle_validate with use_old_fence_class = 1.

16 years agoDocument drm_bo_handle_validate. Match drm_bo_do_validate parameter order.
Keith Packard [Fri, 14 Dec 2007 20:45:55 +0000 (12:45 -0800)]
Document drm_bo_handle_validate. Match drm_bo_do_validate parameter order.

Document parameters and usage for drm_bo_handle_validate. Change parameter
order to match drm_bo_do_validate (fence_class has been moved to after
flags, hint and mask values). Existing users of this function have been
changed, but out-of-tree users must be modified separately.

16 years agoDocument drm_bo_do_validate. Remove spurious 'do_wait' parameter.
Keith Packard [Fri, 14 Dec 2007 20:33:35 +0000 (12:33 -0800)]
Document drm_bo_do_validate. Remove spurious 'do_wait' parameter.

Add comments about the parameters to drm_bo_do_validate, along
with comments for the DRM_BO_HINT options. Remove the 'do_wait'
parameter as it is duplicated by DRM_BO_HINT_DONT_BLOCK.

16 years agoMake ttm create/destroy APIs consistent. Pass page_flags in create.
Keith Packard [Fri, 14 Dec 2007 19:42:17 +0000 (11:42 -0800)]
Make ttm create/destroy APIs consistent. Pass page_flags in create.

Creating a ttm was done with drm_ttm_init while destruction was done with
drm_destroy_ttm. Renaming these to drm_ttm_create and drm_ttm_destroy makes
their use clearer. Passing page_flags to the create function will allow that
to know whether user or kernel pages are needed, with the goal of allowing
kernel ttms to be saved for later reuse.

16 years agoRevert "nouveau: nv30: missing ramin init, does it brake other hw?"
Patrice Mandin [Sat, 15 Dec 2007 09:23:30 +0000 (10:23 +0100)]
Revert "nouveau: nv30: missing ramin init, does it brake other hw?"

This reverts commit 46235ea4595152d8dd5f016c18c6845a77db30b0.

16 years agocatch an out of memory condition
Alan Hourihane [Thu, 13 Dec 2007 10:40:36 +0000 (10:40 +0000)]
catch an out of memory condition

16 years agoMake relocation validate client computed values when debugging
Keith Packard [Wed, 12 Dec 2007 04:21:23 +0000 (20:21 -0800)]
Make relocation validate client computed values when debugging

16 years agoi915: wait for buffer idle before writing relocations
Keith Packard [Thu, 6 Dec 2007 23:12:21 +0000 (15:12 -0800)]
i915: wait for buffer idle before writing relocations

When writing a relocation entry, make sure the target buffer is idle,
otherwise the GPU may see inconsistent data.

16 years agoBump driver minor for relocation optimzations
Keith Packard [Wed, 5 Dec 2007 04:54:53 +0000 (20:54 -0800)]
Bump driver minor for relocation optimzations

16 years agoAllow relocation to be skipped when buffers don't move.
Keith Packard [Tue, 4 Dec 2007 20:22:30 +0000 (12:22 -0800)]
Allow relocation to be skipped when buffers don't move.

One of the costs of superioctl has been the need to perform relocations
inside the kernel. The cost of mapping the buffers to the CPU and writing
data is fairly high, especially if those buffers have been mapped and read
by the GPU.

If we assume that buffers don't move around very often, we can have the
client compute the relocations itself using the previous GPU address. When
that object doesn't move, the kernel can skip computing and writing the
updated data.

Here's a patch which adds a new field to struct drm_bo_info_req called
'presumed_offset', and a new DRM_BO_HINT_PRESUMED_OFFSET that is set when
this field has been filled in by the client.

There are two separate optimizations performed when the presumed_offset is
correct:

 1. i915_exec_reloc checks to see if all previous buffer offsets were guessed
    correctly. If so, there's no need for it to look at *any* of the
    relocations for a buffer. When this happens, it skips the whole
    relocation process, simply returning success.

 2. i915_apply_reloc checks to see if the target buffer offset was guessed
    correctly. If so, it skips mapping the relocatee, computing the
    relocation and writing the value. If no relocations are needed, the
    relocatee should never be mapped to the CPU, and so the kernel shouldn't
    need to wait for any fences to pass.

16 years agoMerge branch 'master' into r500-support
Dave Airlie [Mon, 10 Dec 2007 05:53:59 +0000 (15:53 +1000)]
Merge branch 'master' into r500-support

16 years agodrm: move agp include outside CONFIG_AGP as it isn't dependant on agp in kernel
Dave Airlie [Mon, 10 Dec 2007 00:13:52 +0000 (10:13 +1000)]
drm: move agp include outside CONFIG_AGP as it isn't dependant on agp in kernel

16 years agomach64: comment bus master / ring buffer behavior and security
José Fonseca [Sat, 8 Dec 2007 19:21:27 +0000 (19:21 +0000)]
mach64: comment bus master / ring buffer behavior and security

16 years agoFix pipe<->plane mapping vs. vblank handling (again)
Jesse Barnes [Fri, 7 Dec 2007 22:24:45 +0000 (14:24 -0800)]
Fix pipe<->plane mapping vs. vblank handling (again)

If drmMinor >= 6, the intel DDX driver will enable vblank events on both
pipes.  If drmMinor >= 10 on pre-965 chipsets, the intel DDX driver will
swap the pipe<->plane mapping to allow for framebuffer compression on
laptop screens.  This means the secondary vblank counter (corresponding
to pipe B) will be incremented when vblank interrupts occur.

Now Mesa waits for vblank events on whichever plane has a greater
portion of the displayed window.  So it will happly ask to wait for the
primary counter even though that one won't increment.

So we can fix this in either the DDX driver, Mesa or the kernel (though
I thought we already had several times).

Since current (and previous) userspace assumes it's talking about a pipe
== plane situation and now uses planes when talking to the kernel, we
should probably just hide the mapping details there (indeed they already
are hidden there for vblank swaps), which this patch does.

So as far as userland is concerned, whether we call things planes or
pipes is irrelevant, as long as kernel developers understand that
userland hands them planes and they have to figure out which pipe that
corresponds to (which will typically be the same on 965+ hardware and
reversed on pre-965 mobile chips).

16 years agotake down stuff after asking driver to unload
Dave Airlie [Thu, 6 Dec 2007 06:03:28 +0000 (16:03 +1000)]
take down stuff after asking driver to unload

16 years agomach64: make buffer emission macros normal functions
José Fonseca [Wed, 5 Dec 2007 22:53:02 +0000 (22:53 +0000)]
mach64: make buffer emission macros normal functions

16 years agomach64: use utf-8
José Fonseca [Wed, 5 Dec 2007 00:10:39 +0000 (00:10 +0000)]
mach64: use utf-8

16 years agoRemove references to the sarea_priv perf_boxes field.
Kristian Høgsberg [Wed, 5 Dec 2007 19:43:22 +0000 (14:43 -0500)]
Remove references to the sarea_priv perf_boxes field.

This field isn't touched or read by any other code in the stack so it's
time to retire these last few references.

16 years agopatch from -mm kernel to use upper_32_bits
Dave Airlie [Tue, 4 Dec 2007 18:54:58 +0000 (04:54 +1000)]
patch from -mm kernel to use upper_32_bits

16 years agobsd: Replace other occurrences of msleep with mtx_sleep
Robert Noland [Sun, 2 Dec 2007 06:45:09 +0000 (01:45 -0500)]
bsd: Replace other occurrences of msleep with mtx_sleep

16 years agobsd: Now make secondary vblank work
Robert Noland [Sun, 2 Dec 2007 06:23:11 +0000 (01:23 -0500)]
bsd: Now make secondary vblank work

We needed to specifically check for driver support and test the correct
vbl_received value.  Also pulled over support for _DRM_VBLANK_NEXTONMISS
from the linux code.

16 years agobsd: Hook secondary vblank support.
Robert Noland [Sat, 1 Dec 2007 22:09:49 +0000 (17:09 -0500)]
bsd: Hook secondary vblank support.

16 years agobsd: Fix typo in i915_drv.c
Robert Noland [Sat, 1 Dec 2007 21:35:48 +0000 (16:35 -0500)]
bsd: Fix typo in i915_drv.c

16 years agomtx_sleep is preferred to msleep
Robert Noland [Sun, 25 Nov 2007 17:54:31 +0000 (12:54 -0500)]
mtx_sleep is preferred to msleep

Calling semantics are the same and both were introduced in 5.0

16 years agoClarify order of operations
Robert Noland [Sun, 25 Nov 2007 17:50:07 +0000 (12:50 -0500)]
Clarify order of operations

16 years agoDRM_DEBUG already prints the function name.
Robert Noland [Sat, 24 Nov 2007 06:56:05 +0000 (01:56 -0500)]
DRM_DEBUG already prints the function name.

16 years agodrm: Add _DRM_DRIVER map flag.
Robert Noland [Sat, 1 Dec 2007 07:40:13 +0000 (02:40 -0500)]
drm: Add _DRM_DRIVER map flag.

This flag indicates that the driver is responsible for the map.

16 years agobsd: Move counter initialization to load time.
Robert Noland [Sat, 1 Dec 2007 07:32:23 +0000 (02:32 -0500)]
bsd: Move counter initialization to load time.

16 years agonouveau: Properly identify NV40 and NV44 generation.
Maarten Maathuis [Fri, 30 Nov 2007 21:50:34 +0000 (22:50 +0100)]
nouveau: Properly identify NV40 and NV44 generation.

16 years agoBeside the emitted warning, the added cast (u64 -> unsigned) strips out
Jiri Slaby [Wed, 28 Nov 2007 23:55:38 +0000 (09:55 +1000)]
Beside the emitted warning, the added cast (u64 -> unsigned) strips out
part of address on 64 bit. Cast to unsigned long instead.

Signed-off-by: Jiri Slaby <jirislaby@gmail.com>
16 years agodrm: enable udev node creation
Dave Airlie [Wed, 28 Nov 2007 23:47:24 +0000 (09:47 +1000)]
drm: enable udev node creation

16 years agodrm: oops not a cleanup..
Dave Airlie [Wed, 28 Nov 2007 23:46:02 +0000 (09:46 +1000)]
drm: oops not a cleanup..

16 years agoFix up drm_ati_pcigart_info
Robert C. Noland III [Wed, 28 Nov 2007 05:33:42 +0000 (00:33 -0500)]
Fix up drm_ati_pcigart_info