dri-devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Eric Anholt <eric-WhKQ6XTQaPysTnJN9+BGXg@public.gmane.org>
To: Jesse Barnes <jbarnes-Y1mF5jBUw70BENJcbMCuUQ@public.gmane.org>,
	dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org,
	xorg-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org
Subject: Re: [PATCH] DRI2/GLX: fix swap event handling
Date: Thu, 28 Apr 2011 14:37:15 -0700	[thread overview]
Message-ID: <87vcxyhxbo.fsf@pollan.anholt.net> (raw)
In-Reply-To: <1304022442-8070-5-git-send-email-jbarnes-Y1mF5jBUw70BENJcbMCuUQ@public.gmane.org>


[-- Attachment #1.1: Type: text/plain, Size: 1206 bytes --]

On Thu, 28 Apr 2011 13:27:22 -0700, Jesse Barnes <jbarnes-Y1mF5jBUw70BENJcbMCuUQ@public.gmane.org> wrote:
> Use the new swap event structure packing and send it to the client if
> possible.  This means tracking client version information when clients
> connect.  If they don't support the new packing, they'll get the old
> bits and fill junk into their sbc values when they receive the event.
> If they do support the new packing, send off the right data.

> --- a/glx/glxdri2.c
> +++ b/glx/glxdri2.c
> @@ -192,8 +192,17 @@ __glXdriSwapEvent(ClientPtr client, void *data, int type, CARD64 ust,
>      wire.ust_lo = ust & 0xffffffff;
>      wire.msc_hi = msc >> 32;
>      wire.msc_lo = msc & 0xffffffff;
> -    wire.sbc_hi = sbc >> 32;
> -    wire.sbc_lo = sbc & 0xffffffff;
> +    wire.sbc_hi = 0;

was that supposed to be wire.sbc_lo and not whacking wire.sbc_hi?

At first I was confused by this whole thing -- why not rearrange the
structure a bit if we're messing things up?  Then I realized that this
let the server emit the mostly-the-same event structure and only steal
the other half of event_type for clients that understand the new 8-bit
event_type protocol.  Seems like a reasonable approach.

[-- Attachment #1.2: Type: application/pgp-signature, Size: 197 bytes --]

[-- Attachment #2: Type: text/plain, Size: 219 bytes --]

_______________________________________________
xorg-devel-go0+a7rfsptAfugRpC6u6w@public.gmane.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: http://lists.x.org/mailman/listinfo/xorg-devel

  parent reply	other threads:[~2011-04-28 21:37 UTC|newest]

Thread overview: 15+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2011-04-28 20:27 [RFC] swap event handling fixes Jesse Barnes
2011-04-28 20:27 ` [PATCH] Pack swap complete bits into an XEvent Jesse Barnes
2011-04-28 21:33   ` Eric Anholt
     [not found]     ` <87y62uhxh5.fsf-NuZ+OHacjZctnJUoGz2Qal6hYfS7NtTn@public.gmane.org>
2011-04-28 21:34       ` Jesse Barnes
2011-04-28 22:01   ` Keith Packard
2011-04-28 20:27 ` [PATCH] GLX/DRI2: fix swap complete handling Jesse Barnes
2011-04-28 20:27 ` [PATCH] DRI2/GLX: fix swap event handling Jesse Barnes
     [not found]   ` <1304022442-8070-5-git-send-email-jbarnes-Y1mF5jBUw70BENJcbMCuUQ@public.gmane.org>
2011-04-28 21:37     ` Eric Anholt [this message]
2011-04-29  6:52   ` Michel Dänzer
2011-04-29  7:20   ` Julien Cristau
2011-04-29 15:24     ` Jesse Barnes
     [not found] ` <1304022442-8070-1-git-send-email-jbarnes-Y1mF5jBUw70BENJcbMCuUQ@public.gmane.org>
2011-04-28 20:27   ` [PATCH] Fix swap complete event size Jesse Barnes
2011-04-29 21:37   ` [RFC] swap event handling fixes Jesse Barnes
2011-04-29 23:10     ` Mario Kleiner
2011-05-02 20:09       ` Jesse Barnes

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=87vcxyhxbo.fsf@pollan.anholt.net \
    --to=eric-whkq6xtqapystnjn9+bgxg@public.gmane.org \
    --cc=dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
    --cc=jbarnes-Y1mF5jBUw70BENJcbMCuUQ@public.gmane.org \
    --cc=xorg-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox