Re: [PATCH 2/6] dri/intel: Split out DRI2 buffer update code to separate function

2013-11-05 Thread Kristian Høgsberg
ri/i965/brw_context.c | 22 ++-- > 2 files changed, 68 insertions(+), 44 deletions(-) Reviewed-by: Kristian Høgsberg > diff --git a/src/mesa/drivers/dri/i915/intel_context.c > b/src/mesa/drivers/dri/i915/intel_context.c > index 2748514..1798bc7 100644 > --- a/src/mesa/driv

Re: [PATCH 1/6] drivers/dri/common: A few dri2 functions are not actually DRI2 specific

2013-11-05 Thread Kristian Høgsberg
on/dri_util.c | 50 > +- > 1 file changed, 25 insertions(+), 25 deletions(-) Reviewed-by: Kristian Høgsberg > diff --git a/src/mesa/drivers/dri/common/dri_util.c > b/src/mesa/drivers/dri/common/dri_util.c > index c28b0fc..539fb4b 100644 > --- a/src/mesa/drivers/dri/common/dri

Re: [Intel-gfx] [PATCH 2/7] drm: delay vblank cleanup until after driver unload

2010-03-28 Thread Kristian Høgsberg
de the same patch a while ago, and it fixed module unload for me. I sent it to the list and it fell through the cracks, because "vblank is hard" or something. Reviewed-by: Kristian Høgsberg > Signed-off-by: Jesse Barnes > --- >  drivers/gpu/drm/drm_stub.c |    4 ++-- >  1 fi

Re: [PATCH 2/3] libdrm_nouveau requires libdrm

2010-02-26 Thread Kristian Høgsberg
2010/2/26 Julien Cristau : > On Fri, Feb 26, 2010 at 13:38:59 -0500, Kristian Høgsberg wrote: > >> On Fri, Feb 26, 2010 at 1:07 PM, Julien Cristau wrote: >> > nouveau_drmif.h includes xf86drm.h. >> >> If it's a source level dependency it shoul

Re: [PATCH 2/3] libdrm_nouveau requires libdrm

2010-02-26 Thread Kristian Høgsberg
On Fri, Feb 26, 2010 at 1:07 PM, Julien Cristau wrote: > nouveau_drmif.h includes xf86drm.h. If it's a source level dependency it should be a regular Requires: in the .pc. Requires.private: is only for private libraries you link to but don't expose their API in your header files. The idea is (A

Re: [PATCH] Some fixes for dri2proto.txt

2010-02-17 Thread Kristian Høgsberg
Thanks, applied. On Tue, Feb 16, 2010 at 5:03 PM, Mike Stroyan wrote: >  In studying dri2proto.txt I noticed that it has several places that don't > mention the events that have been added. > >  I also noticed a couple of typos and a reference to a 'group' field > that does not exist. > > Here ar

Re: vmwgfx + VMWare 7.0 -> libdrm modetest.c

2010-02-09 Thread Kristian Høgsberg
On Tue, Feb 9, 2010 at 8:05 AM, Peter Hanzel wrote: > Hello. > > I have a question about libdrm/libkms and test/modetest/modetest.c. > I am now working with vmwgfx + VMWare 7.0, where vmwgfx had correctly > initialized framebuffer and also now using fbcon. > Now I want to test it woth modetest.c >

Re: Removal of mach64

2010-02-07 Thread Kristian Høgsberg
On Sun, Feb 7, 2010 at 1:32 AM, Catalin Patulea wrote: > Hello, > > I am interested in getting DRI working on my ATI Rage XL card under > 2.6.31-14 with mach64_drv 6.8.2 (Xorg 1.6.3 from Ubuntu Karmic koala). > Git says that the mach64 driver was deleted, along with shared-code, > linux-core, etc,

Re: [PATCH] libdrm compile warnings fixes

2010-02-04 Thread Kristian Høgsberg
On Thu, Feb 4, 2010 at 2:23 PM, Matthew W. S. Bell wrote: > Hi, > > I've fixed up some compile warnings in the attached patch; I think a > couple of cases may actually have been bugs. One case I have not touched > is converting between void * (64 bit here) and drm_handle_t (32 bit > here), as I do

Re: RFC: xfree: dri2: libdrm as optional

2010-01-19 Thread Kristian Høgsberg
On Tue, Jan 19, 2010 at 2:18 PM, Tiago Vignatti wrote: > Some drivers use DRI2 protocol but implement their own kernel rendering > mananger. For these drivers, libdrm becomes useless. Yeah, I think this could be ok. The drm usage in DRI2 does stick out a bit, and should probably be pushed to the

[PATCH] drm/i915: Clean up vblank data after lastclose and unload

2010-01-05 Thread Kristian Høgsberg
Otherwise we end up waking up a freed waitqueue. Signed-off-by: Kristian Høgsberg --- Resend. This didn't get picked up earlier, so this time I'll try sending to the right mailing list. drivers/gpu/drm/drm_stub.c |4 ++-- 1 files changed, 2 insertions(+), 2 deletions(-) di

[ANNOUNCE] libdrm 2.4.16

2009-12-04 Thread Kristian Høgsberg
ference_final. Francisco Jerez (1): nouveau: Update some nouveau_class.h definitions from renouveau.xml. Julien Cristau (1): Only install libdrm_intel.pc if we build libdrm_intel Kristian Høgsberg (18): Add support for vblank events Add makefile rule to copy headers fro

[PATCH] drm: Add compatibility #ifdefs for *BSD

2009-12-02 Thread Kristian Høgsberg
This let's use use the linux drm headers as the canonical source for libdrm on all platforms. Signed-off-by: Kristian Høgsberg --- Second try, now with the #defines added to drmP.h that was missing in the first patch. include/drm/drm.h| 29 +++-- includ

Re: [PATCH] drm: Add compatibility #ifdefs for *BSD

2009-12-02 Thread Kristian Høgsberg
2009/12/2 Robert Noland : > On Wed, 2009-12-02 at 11:36 -0500, Kristian Høgsberg wrote: >> This let's use use the linux drm headers as the canonical source for >> libdrm on all platforms. >> >> Signed-off-by: Kristian Høgsberg >> --- >> >> This

[PATCH] drm: Add compatibility #ifdefs for *BSD

2009-12-02 Thread Kristian Høgsberg
This let's use use the linux drm headers as the canonical source for libdrm on all platforms. Signed-off-by: Kristian Høgsberg --- This is the patch to sync the linux kernel headers with what's in libdrm now. With this patch upstream, we can copy headers from the kernel into the l

Re: [PATCH] drm/i915: Add intel implementation of the pageflip ioctl

2009-11-30 Thread Kristian Høgsberg
t/plain; charset=utf-8 > Content-Transfer-Encoding: 8bit > > Acked-by: Jakob Bornecrantz > Acked-by: Thomas Hellström > Review-by: Chris Wilson > Signed-off-by: Jesse "Orange Smoothie" Barnes > Signed-off-by: Kristian Høgsberg Hmm, I'm already the author of

Re: [PATCH 2/2] drm: use page flip event to signal flip completion

2009-11-30 Thread Kristian Høgsberg
me number the flip will complete on, so > userspace needs a specific flip notification to tell it when the last flip > completed. > > Signed-off-by: Jesse Barnes Acked-by: Kristian Høgsberg > --- >  drivers/gpu/drm/drm_crtc.c |    2 +- >  include/drm/drm.h          |    1 + >

Re: RFC: libdrm repo

2009-11-28 Thread Kristian Høgsberg
On Sat, Nov 28, 2009 at 1:41 PM, Robert Noland wrote: > On Fri, 2009-11-27 at 17:23 -0800, vehemens wrote: ... >> > I think we pissed one person off, not people, as I said, there are two >> > people registered as BSD maintainers for drm code, oga and rnoland, >> > neither of them cared. I'm not su

[PATCH] drm: Add minimal BSD #ifdefs so we can share the drm.h unchanged

2009-11-24 Thread Kristian Høgsberg
We ship a copy of drm.h in the libdrm repo. By adding these couple of ifdefs, we can share the drm.h header file between kernel source and libdrm on linux and the BSDs. Signed-off-by: Kristian Høgsberg --- include/drm/drm.h| 29 +++-- include/drm/drmP.h

Re: libdrm headers (Re: RFC: libdrm repo)

2009-11-23 Thread Kristian Høgsberg
On Mon, Nov 23, 2009 at 11:50 AM, Pekka Paalanen wrote: > On Mon, 23 Nov 2009 17:12:07 +0100 > Michel Dänzer wrote: > >> On Mon, 2009-11-23 at 10:55 -0500, Kristian Høgsberg wrote: >> > The headers in include/drm will be installed and libdrm_radeon >> > shoul

Re: RFC: libdrm repo

2009-11-23 Thread Kristian Høgsberg
2009/11/23 Michel Dänzer : > On Mon, 2009-11-23 at 10:55 -0500, Kristian Høgsberg wrote: >> 2009/11/23 Michel Dänzer : >> > On Fri, 2009-11-20 at 17:20 -0500, Kristian Høgsberg wrote: >> >> 2009/11/19 Eric Anholt : >> >> > On Tue, 2009-11-17 at 11:33

Re: RFC: libdrm repo

2009-11-23 Thread Kristian Høgsberg
2009/11/23 Michel Dänzer : > On Fri, 2009-11-20 at 17:20 -0500, Kristian Høgsberg wrote: >> 2009/11/19 Eric Anholt : >> > On Tue, 2009-11-17 at 11:33 -0500, Kristian Høgsberg wrote: >> >> 2009/11/6 Kristian Høgsberg : >> >> > Hi, >> >> &

Re: RFC: libdrm repo

2009-11-20 Thread Kristian Høgsberg
2009/11/19 Eric Anholt : > On Tue, 2009-11-17 at 11:33 -0500, Kristian Høgsberg wrote: >> 2009/11/6 Kristian Høgsberg : >> > Hi, >> > >> > This has come up a few time and it's something I think makes a lot of >> > sense.  Since all driver develop

[PATCH 2/2 v2] drm/i915: Add intel implementation of the pageflip ioctl

2009-11-18 Thread Kristian Høgsberg
Acked-by: Jakob Bornecrantz Acked-by: Thomas Hellström Review-by: Chris Wilson Signed-off-by: Jesse "Orange Smoothie" Barnes Signed-off-by: Kristian Høgsberg --- Resend to add missing acks and sob's and to fix checkpatch errors. cheers, Kristian drivers/gpu/drm/i915/i915_dr

[PATCH 2/2] Add intel implementation of the pageflip ioctl

2009-11-17 Thread Kristian Høgsberg
Signed-off-by: Kristian Høgsberg --- drivers/gpu/drm/i915/i915_drv.h | 12 ++ drivers/gpu/drm/i915/i915_gem.c | 64 +- drivers/gpu/drm/i915/i915_irq.c | 10 ++ drivers/gpu/drm/i915/i915_reg.h |2 + drivers/gpu/drm/i915/intel_display.c | 233

[PATCH 1/2] drm/i915: Add page flipping ioctl

2009-11-17 Thread Kristian Høgsberg
ne. After submitting a page flip, any execbuffer involving the old front buffer will block until the flip is completed. Optionally, a vblank event can be generated when the swap eventually happens. Signed-off-by: Kristian Høgsberg Reviewed-by: Chris Wilson --- drivers/gpu/drm/drm_crt

Re: RFC: libdrm repo

2009-11-17 Thread Kristian Høgsberg
2009/11/17 Stephane Marchesin : > 2009/11/17 Kristian Høgsberg : >> 2009/11/6 Kristian Høgsberg : >>> Hi, >>> >>> This has come up a few time and it's something I think makes a lot of >>> sense.  Since all driver development (afaik) now happens in

Re: RFC: libdrm repo

2009-11-17 Thread Kristian Høgsberg
2009/11/6 Kristian Høgsberg : > Hi, > > This has come up a few time and it's something I think makes a lot of > sense.  Since all driver development (afaik) now happens in linux > kernel tree, it makes sense to drop the driver bits from the drm.git > repo. Ok, here'

Re: [PATCH] drm/i915: Add page flipping ioctl

2009-11-16 Thread Kristian Høgsberg
2009/11/14 Thomas Hellström : > Kristian Høgsberg wrote: >> This adds a page flipping ioctl to the KMS API.  The ioctl takes an fb ID >> and a ctrc ID and flips the crtc to the given fb at the next vblank. >> The ioctl returns immediately but the flip doesn't happen un

Re: [PATCH] drm/i915: Add page flipping ioctl

2009-11-16 Thread Kristian Høgsberg
2009/11/12 Jakob Bornecrantz : > On 12 nov 2009, at 17.44, Kristian Høgsberg wrote: >> >> This adds a page flipping ioctl to the KMS API.  The ioctl takes an fb ID >> and a ctrc ID and flips the crtc to the given fb at the next vblank. >> The ioctl returns immediately

[PATCH] drm/i915: Add page flipping ioctl

2009-11-12 Thread Kristian Høgsberg
ne. After submitting a page flip, any execbuffer involving the old front buffer will block until the flip is completed. Optionally, a vblank event can be generated when the swap eventually happens. Signed-off-by: Kristian Høgsberg Reviewed-by: Chris Wilson --- Okay, here we go again. Page

Re: [RFC] DRI2 synchronization and swap bits

2009-11-01 Thread Kristian Høgsberg
On Fri, Oct 30, 2009 at 1:42 PM, Eric Anholt wrote: > On Fri, 2009-10-30 at 10:59 -0700, Jesse Barnes wrote: >> I've put up some trees (after learning my lesson about working in the >> main tree) with the latest DRI2 sync/swap bits: >>   git://git.freedesktop.org/home/jbarnes/xserver master branch

[PATCH] drm: Add async event synchronization for drmWaitVblank

2009-09-11 Thread Kristian Høgsberg
sequence can be specified relatively or absolutely, and works for primary and seconday crtc. The signal field of the vblank request is used to provide user data, which will be sent back to user space in the vblank event. Signed-off-by: Kristian Høgsberg --- drivers/gpu/drm/drm_fops.c | 99

Re: [PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-31 Thread Kristian Høgsberg
Thomas, What you describe sounds reasonable and I'll look into updating the patch. I'm not too keen on the driver specific flag you suggest, since it makes it hard to use the ioctl in generic code. Maybe drivers that can do pageflip from one of several fifos can expose a driver specific ioctl to

Re: [PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-28 Thread Kristian Høgsberg
This mail is getting out of control... too many sub-threads going on... maybe we shold break it out and talk about events vs kernel scheduling and wait with the patch review until we've figured something out. 2009/8/28 Thomas Hellström : > Kristian Høgsberg skrev: >> >&

Re: [PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-28 Thread Kristian Høgsberg
On Fri, Aug 28, 2009 at 5:19 AM, Michel Dänzer wrote: > On Thu, 2009-08-27 at 17:33 -0400, Kristian Høgsberg wrote: >> 2009/8/27 Thomas Hellström : >> > >> > b) It requires the master to act as a scheduler, and circumvents the DRM >> > command submission

Re: [PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-27 Thread Kristian Høgsberg
2009/8/27 Thomas Hellström : > Kristian Høgsberg skrev: >> --- >> >> Okay, here's the patch again with the locking fixed.  Everything else is >> the same.  As for the potential problem with polling on the drm fd with >> both dri1 and dri2 enabled, I suggest

[PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-26 Thread Kristian Høgsberg
. The event includes the time of the flip, the frame counter and a 64 bit opaque token provided by user space in the ioctl. Based on work and suggestions from Jesse Barnes , Jakob Bornecrantz , Chris Wilson Signed-off-by: Kristian Høgsberg Signed-off-by: Jesse Barnes

Re: [PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-18 Thread Kristian Høgsberg
On Tue, Aug 18, 2009 at 6:31 PM, Thomas Hellström wrote: > Jesse Barnes wrote: >> >> Anyway, to me this discussion is more of a "future directions" one than >> a blocker for this particular patchset.  AFAICT the only thing that >> needs fixing with this patch is my lock confusion (struct_mutex vs >

Re: [PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-18 Thread Kristian Høgsberg
On Tue, Aug 18, 2009 at 7:12 PM, Luc Verhaegen wrote: > And on the flip side of this, what you do is purely technical, always. > > #dri-devel 00:05 <+airlied> krh: you've been smirled Yeah, I was wondering about that, I thought the word was smirl-rolled :D cheers, Kristian --

Re: [PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-18 Thread Kristian Høgsberg
On Tue, Aug 18, 2009 at 6:12 PM, Thomas Hellström wrote: > Kristian Høgsberg wrote: >> >> On Tue, Aug 18, 2009 at 5:03 PM, Dave Airlie wrote: >> >>> >>> On Wed, Aug 19, 2009 at 2:12 AM, Keith Whitwell wrote: >>> >>>> >>>>

Re: [PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-18 Thread Kristian Høgsberg
On Tue, Aug 18, 2009 at 5:03 PM, Dave Airlie wrote: > On Wed, Aug 19, 2009 at 2:12 AM, Keith Whitwell wrote: >> I think the bug in question was because somebody (Jon Smirl??) removed the >> empty & apparently unused poll implementation from the drm fd, only to >> discover that the X server was ac

Re: [PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-18 Thread Kristian Høgsberg
On Tue, Aug 18, 2009 at 1:36 PM, Thomas Hellström wrote: > Kristian Høgsberg wrote: >> >> On Tue, Aug 18, 2009 at 3:52 AM, Thomas Hellström >> wrote: >> >>> >>> Kristian Høgsberg wrote: >>> >>>> >>>> By sending an event

Re: [PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-18 Thread Kristian Høgsberg
On Tue, Aug 18, 2009 at 2:08 AM, Thomas Hellström wrote: > Kristian Høgsberg wrote: >> Perhaps TTM bo read/write could use ioctls like the gem pwrite/pread >> ioctls?  The only way we can get asynchronous notifications from the >> drm to userspace is through readable event

Re: [PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-18 Thread Kristian Høgsberg
On Tue, Aug 18, 2009 at 3:52 AM, Thomas Hellström wrote: > Kristian Høgsberg wrote: >> By sending an event back on the file descriptor we allow users of the >> API to wait on the flip to finish in a standard poll or select >> mainloop, where it can handle input from other

Re: [PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-18 Thread Kristian Høgsberg
>> I'm a little fuzzy on the details, this part of the patch was carried >> over from Jesse's original work.  I believe set_base is supposed to be >> called with the struct mutex held. >> >> > > We shouldn't be this sloppy about locking, and in particular we shouldn't > protect a callback with a lo

Re: [PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-17 Thread Kristian Høgsberg
On Mon, Aug 17, 2009 at 7:14 PM, Dave Airlie wrote: >>> >>> A couple of years ago, any attempt to return anything else than 0 from >>> drm poll resulted in an X server error. >>> http://freedesktop.org/bugzilla/show_bug.cgi?id=1505. The fix mentioned >>> in the bug was actually to return 0 from drm

Re: [PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-17 Thread Kristian Høgsberg
On Mon, Aug 17, 2009 at 4:36 PM, Jesse Barnes wrote: > On Mon, 17 Aug 2009 22:22:34 +0200 > Thomas Hellström wrote: > >> Kristian Høgsberg wrote: >> > This patch adds a vblank synced pageflip ioctl for to the >> > modesetting family of ioctls.  The ioctl takes a

Re: [PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-17 Thread Kristian Høgsberg
2009/8/17 Thomas Hellström : > Kristian Høgsberg wrote: >> This patch adds a vblank synced pageflip ioctl for to the modesetting >> family of ioctls.  The ioctl takes a crtc and an fb and schedules a >> pageflip to the new fb at the next coming vertical blank event.  This >

[PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-17 Thread Kristian Høgsberg
. The event includes the time of the flip, the frame counter and a 64 bit opaque token provided by user space in the ioctl. Based on work and suggestions from Jesse Barnes , Jakob Bornecrantz , Chris Wilson Signed-off-by: Kristian Høgsberg Signed-off-by: Jesse Barnes

[PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-08-17 Thread Kristian Høgsberg
. The event includes the time of the flip, the frame counter and a 64 bit opaque token provided by user space in the ioctl. Based on work and suggestions from Jesse Barnes , Jakob Bornecrantz , Chris Wilson Signed-off-by: Kristian Høgsberg Signed-off-by: Jesse Barnes

Re: [PATCH 2/3] drm/ttm: Add a virtual ttm sysfs device.

2009-08-17 Thread Kristian Høgsberg
On Mon, Aug 17, 2009 at 10:28 AM, Thomas Hellstrom wrote: > The device directory will be the base directory of the > sysfs representation of other ttm subsystems. > > Signed-off-by: Thomas Hellstrom > --- >  drivers/gpu/drm/ttm/ttm_module.c |   56 > +- >  1 fil

Re: drm sysfs questions

2009-08-13 Thread Kristian Høgsberg
2009/8/13 Thomas Hellström : > Kristian Høgsberg wrote: >> 2009/8/11 Thomas Hellström : >> >>> Jesse Barnes wrote: >>> >>>> On Tue, 11 Aug 2009 11:23:09 +0200 >>>> Thomas Hellström wrote: >>>> >>>> >

Re: drm sysfs questions

2009-08-12 Thread Kristian Høgsberg
2009/8/11 Thomas Hellström : > Jesse Barnes wrote: >> On Tue, 11 Aug 2009 11:23:09 +0200 >> Thomas Hellström wrote: >> >> >>> Hi! >>> >>> I'm wondering why we are using a struct device as a sysfs >>> representation for connectors instead of a struct kobject? >>> >>> In particular, what stops the d

[PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-07-16 Thread Kristian Høgsberg
From: Kristian Høgsberg This patch adds a vblank synced pageflip ioctl for to the modesetting family of ioctls. The ioctl takes a crtc and an fb and schedules a pageflip to the new fb at the next coming vertical blank event. This feature lets userspace implement tear-free updating of the

Re: [PATCH] drm: remove root requirement from DRM_IOCTL_SET_VERSION

2009-07-03 Thread Kristian Høgsberg
On Fri, Jul 3, 2009 at 5:47 AM, Daniel Stone wrote: > On Wed, Jul 01, 2009 at 09:39:17PM -0400, Kristian Høgsberg wrote: >> If we want to do better (and if we care about security enhanced X in a >> [... snipped for brevity ...] >> session server is a client of a system disp

Re: [PATCH] drm: remove root requirement from DRM_IOCTL_SET_VERSION

2009-07-01 Thread Kristian Høgsberg
On Wed, Jul 1, 2009 at 12:55 PM, Jesse Barnes wrote: > On Tue, 30 Jun 2009 23:43:19 -0700 > Eric Anholt wrote: > >> On Mon, 2009-06-29 at 16:52 -0700, Jesse Barnes wrote: >> > Just a DRM_MASTER flag is sufficient here, though maybe this call is >> > totally deprecated anyway (xf86-video-intel stil

Re: [Intel-gfx] [PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-06-30 Thread Kristian Høgsberg
On Tue, Jun 30, 2009 at 2:37 PM, Chris Wilson wrote: > I've just got around to playing with the modesetting page-flip ioctl and > found a nasty rendering glitch where the flip occurred before the > rendering was flushed. This appears to be because the finish of the > pending_flip is queued at the s

Re: GLX makeCurrent in glean vs broken X server glxAllContexts linked list

2009-06-10 Thread Kristian Høgsberg
On Wed, 2009-06-10 at 15:20 +1000, Dave Airlie wrote: > Hi Kristian et al > > So you wrote YALL for glxAllContexts and like all good linked list > re-implementations it didn't work :-) Well that's how we do data structures in the X server, open coded and badly. > So the attached patch fixes the

[PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-05-14 Thread Kristian Høgsberg
From: Kristian Høgsberg This patch adds a vblank synced pageflip ioctl for to the modesetting family of ioctls. The ioctl takes a crtc and an fb and schedules a pageflip to the new fb at the next coming vertical blank event. This feature lets userspace implement tear-free updating of the

[PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-05-10 Thread Kristian Høgsberg
From: Kristian Høgsberg This patch adds a vblank synced pageflip ioctl for to the modesetting family of ioctls. The ioctl takes a crtc and an fb and schedules a pageflip to the new fb at the next coming vertical blank event. This feature lets userspace implement tear-free updating of the

[PATCH] libdrm: add KMS page flip interface

2009-05-08 Thread Kristian Høgsberg
From: Jesse Barnes Sits on top of KMS page flipping ioctl. --- Userspace side of the async pageflip ioctl plus a test case added to modetest.c libdrm/xf86drmMode.c | 13 libdrm/xf86drmMode.h |4 +- shared-core/drm.h | 26 - shared-core/drm_mode.h|

[PATCH] Add modesetting pageflip ioctl and corresponding drm event

2009-05-08 Thread Kristian Høgsberg
From: Kristian Høgsberg This patch adds a vblank synced pageflip ioctl for to the modesetting family of ioctls. The ioctl takes a crtc and an fb and schedules a pageflip to the new fb at the next coming vertical blank event. This feature lets userspace implement tear-free updating of the

Re: [Intel-gfx] [RFC] DRI2 swapbuffers (yes yet again)

2009-05-07 Thread Kristian Høgsberg
On Tue, May 5, 2009 at 2:34 PM, Jesse Barnes wrote: > On Tue, 05 May 2009 11:24:29 -0700 > Ian Romanick wrote: > >> -BEGIN PGP SIGNED MESSAGE- >> Hash: SHA1 >> >> Kristian Høgsberg wrote: >> > On Tue, May 5, 2009 at 12:20 PM, Jesse Barnes >&

Re: [Intel-gfx] [RFC] DRI2 swapbuffers (yes yet again)

2009-05-07 Thread Kristian Høgsberg
2009/5/5 Ian Romanick : > -BEGIN PGP SIGNED MESSAGE- > Hash: SHA1 > > Kristian Høgsberg wrote: >> On Tue, May 5, 2009 at 12:20 PM, Jesse Barnes >> wrote: >>> On Mon, 04 May 2009 19:14:29 -0700 >>> Ian Romanick wrote: >>> >&g

Re: [Intel-gfx] [RFC] DRI2 swapbuffers (yes yet again)

2009-05-05 Thread Kristian Høgsberg
On Tue, May 5, 2009 at 12:20 PM, Jesse Barnes wrote: > On Mon, 04 May 2009 19:14:29 -0700 > Ian Romanick wrote: > >> -BEGIN PGP SIGNED MESSAGE- >> Hash: SHA1 >> >> Jesse Barnes wrote: >> > On Mon, 04 May 2009 14:45:07 -0700 >> > Ian Romanick wrote: >> > >> >> There's a problem in dri2Swa

Re: generic libdrm memory manager

2009-04-23 Thread Kristian Høgsberg
On Thu, Apr 23, 2009 at 7:23 AM, Abraham Varricatt wrote: ... > Thank you for your reply Jerome. > > I was hoping that I could join in the development of the API or > something, but if it's more than a year old ... > > The test applications in libdrm bug me. I can understand that > development was

Re: [PATCH] Remove code for tracking per-drawable cliprects.

2009-04-08 Thread Kristian Høgsberg
On Wed, Apr 08, 2009 at 09:29:04AM -0400, Kristian Høgsberg wrote: > On Wed, 2009-04-08 at 04:11 +0100, Dave Airlie wrote: > > > > Do you want to pick it up then or do you want Dave to take it? > > > > > > Since it wasn't in my driver, I was assuming airli

Re: [PATCH] Remove code for tracking per-drawable cliprects.

2009-04-08 Thread Kristian Høgsberg
On Wed, 2009-04-08 at 04:11 +0100, Dave Airlie wrote: > > > Do you want to pick it up then or do you want Dave to take it? > > > > Since it wasn't in my driver, I was assuming airlied would pick it up. > > Yup I'll grab it, I was going to leave it for the next merge window as I > dislike doing a

Re: [PATCH] Remove code for tracking per-drawable cliprects.

2009-04-07 Thread Kristian Høgsberg
On Fri, Apr 3, 2009 at 11:56 AM, Kristian Høgsberg wrote: > 2009/4/2 Eric Anholt : >> On Thu, 2009-04-02 at 14:41 -0400, Kristian Høgsberg wrote: >>> This was only used by the i915 driver for the swapbuffer vsync tasklet. >>> That functionality is now gone and n

Re: [PATCH] Remove code for tracking per-drawable cliprects.

2009-04-03 Thread Kristian Høgsberg
2009/4/2 Eric Anholt : > On Thu, 2009-04-02 at 14:41 -0400, Kristian Høgsberg wrote: >> This was only used by the i915 driver for the swapbuffer vsync tasklet. >> That functionality is now gone and nothing uses the kernel side >> cliprects anymore.  Just stub out the ioc

[PATCH] Remove code for tracking per-drawable cliprects.

2009-04-02 Thread Kristian Høgsberg
This was only used by the i915 driver for the swapbuffer vsync tasklet. That functionality is now gone and nothing uses the kernel side cliprects anymore. Just stub out the ioctls, but make sure we return a non-zero handle in the DRM_IOCTL_ADD_DRAW case. Signed-off-by: Kristian Høgsberg

Re: [PATCH] libdrm: speed up connector & mode fetching

2009-03-31 Thread Kristian Høgsberg
2009/3/31 Eric Anholt : > On Fri, 2009-03-27 at 15:48 -0700, Jesse Barnes wrote: >> On Fri, 27 Mar 2009 22:53:00 +0100 >> Jakob Bornecrantz wrote: >> >> > On Fri, Mar 27, 2009 at 8:58 PM, Jesse Barnes >> > wrote: >> > > This patch speeds up drmModeGetConnector by pre-allocating mode & >> > > prop

Re: DRI2 + buffer creation

2009-03-31 Thread Kristian Høgsberg
2009/3/31 Dave Airlie : > 2009/3/31 Kristian Høgsberg : >> On Tue, Mar 31, 2009 at 4:46 AM, Alan Hourihane wrote: >>> On Tue, 2009-03-31 at 15:43 +1000, Dave Airlie wrote: >>>> So I've been playing a bit more with DRI2 and I'm having trouble >>>&g

Re: DRI2 + buffer creation

2009-03-31 Thread Kristian Høgsberg
On Tue, Mar 31, 2009 at 4:46 AM, Alan Hourihane wrote: > On Tue, 2009-03-31 at 15:43 +1000, Dave Airlie wrote: >> So I've been playing a bit more with DRI2 and I'm having trouble >> finding how the buffer creation was meant to work for depth buffers. >> >> If my app uses a visual >> 0xbc 24 tc  0

Re: [PATCH] Fix deadlock in drm_setmaster_ioctl

2009-03-04 Thread Kristian Høgsberg
On Wed, Mar 4, 2009 at 6:50 AM, Dave Airlie wrote: > >> Fix deadlock in drm_setmaster_ioctl > > Wow, I have this right in my rawhide tree, I must have retyped this when > I ported it back. We need to bump the dri version for this so we don't deadlock on older kernels when the 2d drivers start usi

Re: changes to upstreaming process for Linux code.

2009-02-27 Thread Kristian Høgsberg
On Fri, Feb 27, 2009 at 4:40 PM, Dave Airlie wrote: > > Prompted by how well it worked with Intel, and changes in my personal life > leading to reduced time availability (except at 4am...) I'm going to > clarify the process for getting patches upstream now. (a...@amd also > trialed this to get r60

Re: [Intel-gfx] [PATCH] mesa/intel: add DRI2 swapbuffers interface

2009-02-27 Thread Kristian Høgsberg
On Fri, Feb 27, 2009 at 2:22 PM, Jesse Barnes wrote: > On Thursday, February 26, 2009 1:31:03 pm Jesse Barnes wrote: >> Add support to Mesa and the intel driver for the new DRI2 swapbuffers >> interface.  Uses the new flush hook to make sure any outstanding rendering >> is complete before sending

Re: [Mesa3d-dev] DRI2 flush extension

2009-02-20 Thread Kristian Høgsberg
On Thu, Feb 19, 2009 at 8:46 PM, Alan Hourihane wrote: > Attached is a new DRI2 flush extension that allows the driver to perform > a "real flush" before dispatching a swap or Xserver copy operation. > > Currently we do this before a DRI2CopyRegion() call. > > This allows drivers a real "end of sc

Re: [PATCH] drm: Take mmap_sem up front to avoid lock order violations.

2009-02-19 Thread Kristian Høgsberg
On Thu, 2009-02-19 at 16:17 +0100, Nick Piggin wrote: > On Thu, Feb 19, 2009 at 09:49:40AM -0500, Kristian Høgsberg wrote: > > > > > Secondly, mmap_sem is not a recursive lock (very few kernel locks are, > > > and we generally frown upon recursive locking schemes), this

Re: [PATCH] drm: Take mmap_sem up front to avoid lock order violations.

2009-02-19 Thread Kristian Høgsberg
On Thu, 2009-02-19 at 11:33 +0100, Peter Zijlstra wrote: > On Thu, 2009-02-19 at 10:19 +0100, Peter Zijlstra wrote: > > On Wed, 2009-02-18 at 11:38 -0500, k...@bitplanet.net wrote: > > > From: Kristian Høgsberg > > > > > > A number of GEM operations (and l

Re: [PATCH] drm: Take mmap_sem up front to avoid lock order violations.

2009-02-18 Thread Kristian Høgsberg
On Wed, Feb 18, 2009 at 5:42 PM, Thomas Hellström wrote: > Kristian Høgsberg wrote: >> >> On Wed, Feb 18, 2009 at 12:36 PM, Eric Anholt wrote: >> >>> >>> On Wed, 2009-02-18 at 11:02 -0500, k...@bitplanet.net wrote: >>> >>>> >>>

Re: [PATCH] drm: Take mmap_sem up front to avoid lock order violations.

2009-02-18 Thread Kristian Høgsberg
On Wed, Feb 18, 2009 at 12:36 PM, Eric Anholt wrote: > On Wed, 2009-02-18 at 11:02 -0500, k...@bitplanet.net wrote: >> From: Kristian Høgsberg >> >> A number of GEM operations (and legacy drm ones) want to copy data to >> or from userspace while holding the struc

[PATCH 4/4] drm: Use spread spectrum when the bios tells us it's ok.

2009-02-13 Thread Kristian Høgsberg
Lifted from the DDX modesetting. Signed-off-by: Kristian Høgsberg --- drivers/gpu/drm/i915/i915_drv.h |2 ++ drivers/gpu/drm/i915/intel_bios.c|8 drivers/gpu/drm/i915/intel_display.c | 20 ++-- 3 files changed, 24 insertions(+), 6 deletions(-) diff

[PATCH 3/4] drm: Collapse identical i8xx_clock() and i9xx_clock().

2009-02-13 Thread Kristian Høgsberg
They used to be different. Now they're identical. Signed-off-by: Kristian Høgsberg --- drivers/gpu/drm/i915/intel_display.c | 33 ++--- 1 files changed, 6 insertions(+), 27 deletions(-) diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm

[PATCH 2/4] drm: Bring PLL limits in sync with DDX values.

2009-02-13 Thread Kristian Høgsberg
Signed-off-by: Kristian Høgsberg --- drivers/gpu/drm/i915/intel_display.c |6 +++--- 1 files changed, 3 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915/intel_display.c index 94c7c09..4f54ac5 100644 --- a/drivers/gpu/drm/i915

[PATCH 1/4] drm: Add locking around cursor gem operations.

2009-02-13 Thread Kristian Høgsberg
We need to hold the struct_mutex around pinning and the phys object operations. Signed-off-by: Kristian Høgsberg --- drivers/gpu/drm/i915/intel_display.c |9 + 1 files changed, 5 insertions(+), 4 deletions(-) diff --git a/drivers/gpu/drm/i915/intel_display.c b/drivers/gpu/drm/i915

[PATCH] [drm] Release user fbs in drm_release

2009-02-12 Thread Kristian Høgsberg
Avoids leaking fbs and associated buffers on release. Signed-off-by: Kristian Høgsberg --- drivers/gpu/drm/drm_crtc.c |3 +-- drivers/gpu/drm/drm_fops.c |3 +++ include/drm/drm_crtc.h |2 +- 3 files changed, 5 insertions(+), 3 deletions(-) diff --git a/drivers/gpu/drm

Re: [PATCH] Restore kernelfb mode for all crtcs.

2009-02-09 Thread Kristian Høgsberg
Hi, Is there anything holding this back now? I was hoping that this would get into the next pull request, it just a simple bug fix... cheers, Kristian On Wed, Feb 4, 2009 at 1:35 PM, Jesse Barnes wrote: > On Tuesday, February 3, 2009 12:07 pm Kristian Høgsberg wrote: >> Record and re

[PATCH] Restore kernelfb mode for all crtcs.

2009-02-03 Thread Kristian Høgsberg
Record and restore the kernel framebuffer for all crtc on panic and lastclose. Signed-off-by: Kristian Høgsberg --- drivers/gpu/drm/i915/intel_fb.c | 19 ++- 1 files changed, 14 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/i915/intel_fb.c b/drivers/gpu/drm/i915

Re: [PATCH] drm: Drop unused and broken dri_library_name sysfs attribute.

2009-01-30 Thread Kristian Høgsberg
point is that it's *not* the kernels jobs to track this. cheers, Kristian [1] Could be done like this: http://cgit.freedesktop.org/~krh/eagle/tree/eagle.c#n249 > /Thomas > > > Kristian Høgsberg wrote: > > Hey; comments on this? Can we put it in one of the git tree so it

Re: [PATCH] drm: Drop unused and broken dri_library_name sysfs attribute.

2009-01-29 Thread Kristian Høgsberg
h this. cheers, Kristian On Mon, Jan 5, 2009 at 4:10 PM, Kristian Høgsberg wrote: > The kernel shouldn't be in the business of telling user space which > driver to load. The kernel defers mapping PCI IDs to module names > to user space and we should do the same for DRI drivers. > &

Re: [PATCH] Claim PCI device when running in modesetting mode.

2009-01-29 Thread Kristian Høgsberg
Heya, ping again. We're a real driver now, can we please claim the PCI device. Can one of you please add it to your git tree, either current rc or next merge window so we don't drop this on the floor? thanks, Kristian On Tue, Jan 13, 2009 at 9:42 AM, Kristian Høgsberg wrote: >

[PATCH] drm: Drop unused and broken dri_library_name sysfs attribute.

2009-01-05 Thread Kristian Høgsberg
e, and the attribute is in fact broken. For intel devices, it falls back to the default behaviour of returning the kernel module name as the DRI driver name, which doesn't work for i965 devices. Nobody has ever hit this problem or filed a bug about this. Signed-off-by: Kristian Høgsberg ---

[PATCH] Claim PCI device when running in modesetting mode.

2009-01-04 Thread Kristian Høgsberg
-off-by: Kristian Høgsberg --- drivers/gpu/drm/drm_drv.c | 67 +- drivers/gpu/drm/drm_stub.c | 85 -- drivers/gpu/drm/drm_sysfs.c |8 +++- drivers/gpu/drm/i915/i915_drv.c | 38 + include/drm

[PATCH] Claim PCI device when running in modesetting mode.

2009-01-04 Thread Kristian Høgsberg
-off-by: Kristian Høgsberg --- drivers/gpu/drm/drm_drv.c | 67 +- drivers/gpu/drm/drm_stub.c | 85 -- drivers/gpu/drm/drm_sysfs.c |8 +++- drivers/gpu/drm/i915/i915_drv.c | 38 + include/drm

Re: [PATCH] Pin cursor bo and unpin old bo when setting cursor.

2008-12-25 Thread Kristian Høgsberg
s one is a semantic change that we should get into the tree before we merge it for 2.6.29. cheers, Kristian On Thu, Dec 18, 2008 at 4:14 AM, Kristian Høgsberg wrote: > We also didn't track the cursor bo before and would leak a reference > when the cursor image was change. > > Signe

[PATCH] Pin new and unpin old buffer when setting a mode.

2008-12-17 Thread Kristian Høgsberg
This removes the requirement for user space to pin a buffer before setting a mode that is backed by the pixels from that buffer. Signed-off-by: Kristian Høgsberg --- drivers/gpu/drm/drm_crtc_helper.c| 20 ++- drivers/gpu/drm/i915/intel_display.c | 44

[PATCH] Drop DRM_IOCTL_MODE_REPLACEFB, add+remove works just as well.

2008-12-17 Thread Kristian Høgsberg
The replace fb ioctl replaces the backing buffer object for a modesetting framebuffer object. This can be acheived by just creating a new framebuffer backed by the new buffer object, setting that for the crtcs in question and then removing the old framebuffer object. Signed-off-by: Kristian

[PATCH] Pin cursor bo and unpin old bo when setting cursor.

2008-12-17 Thread Kristian Høgsberg
We also didn't track the cursor bo before and would leak a reference when the cursor image was change. Signed-off-by: Kristian Høgsberg --- drivers/gpu/drm/i915/intel_display.c | 29 + drivers/gpu/drm/i915/intel_drv.h |1 + 2 files changed, 22 inser

  1   2   >