[PATCH 1/1] dix/dispatch: Fix SmartScheduleClient interval adjustment to use best rather than pClient

2016-09-11 Thread Jeremy Huddleston Sequoia
pClient does not contain a live value after the transition to lists

https://bugs.freedesktop.org/show_bug.cgi?id=97765

Application Specific Information:
X.Org X Server 1.18.99.1 Build Date: 20160910
=
==16921==ERROR: AddressSanitizer: global-buffer-overflow on address 
0x000108ce3834 at pc 0x000108880766 bp 0x745f76c0 sp 0x745f76b8
READ of size 4 at 0x000108ce3834 thread T6
#0 0x108880765 in SmartScheduleClient dispatch.c:365
#1 0x10887ecc5 in Dispatch dispatch.c:422
#2 0x1088c05f1 in dix_main main.c:301
#3 0x1082aabba in server_thread quartzStartup.c:66
#4 0x7fffc5f16aaa in _pthread_body (libsystem_pthread.dylib+0x3aaa)
#5 0x7fffc5f169f6 in _pthread_start (libsystem_pthread.dylib+0x39f6)
#6 0x7fffc5f161fc in thread_start (libsystem_pthread.dylib+0x31fc)

Regressed-in: 8f1edf4bd3a1f050ce9eeb5eac45dd1a8f7a6d5e
Signed-off-by: Jeremy Huddleston Sequoia 
---
 dix/dispatch.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/dix/dispatch.c b/dix/dispatch.c
index 3b9600e..f1a074d 100644
--- a/dix/dispatch.c
+++ b/dix/dispatch.c
@@ -360,7 +360,7 @@ SmartScheduleClient(void)
  * has run, bump the slice up to get maximal
  * performance from a single client
  */
-if ((now - pClient->smart_start_tick) > 1000 &&
+if ((now - best->smart_start_tick) > 1000 &&
 SmartScheduleSlice < SmartScheduleMaxSlice) {
 SmartScheduleSlice += SmartScheduleInterval;
 }
-- 
2.9.3

___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Re: [PATCH 1/1] dix/dispatch: Fix SmartScheduleClient interval adjustment to use best rather than pClient

2016-09-15 Thread Keith Packard
Jeremy Huddleston Sequoia  writes:

> pClient does not contain a live value after the transition to lists
>
> https://bugs.freedesktop.org/show_bug.cgi?id=97765
>
> Application Specific Information:
> X.Org X Server 1.18.99.1 Build Date: 20160910
> =
> ==16921==ERROR: AddressSanitizer: global-buffer-overflow on address 
> 0x000108ce3834 at pc 0x000108880766 bp 0x745f76c0 sp 0x745f76b8
> READ of size 4 at 0x000108ce3834 thread T6
> #0 0x108880765 in SmartScheduleClient dispatch.c:365
> #1 0x10887ecc5 in Dispatch dispatch.c:422
> #2 0x1088c05f1 in dix_main main.c:301
> #3 0x1082aabba in server_thread quartzStartup.c:66
> #4 0x7fffc5f16aaa in _pthread_body (libsystem_pthread.dylib+0x3aaa)
> #5 0x7fffc5f169f6 in _pthread_start (libsystem_pthread.dylib+0x39f6)
> #6 0x7fffc5f161fc in thread_start (libsystem_pthread.dylib+0x31fc)
>
> Regressed-in: 8f1edf4bd3a1f050ce9eeb5eac45dd1a8f7a6d5e
> Signed-off-by: Jeremy Huddleston Sequoia 

Reviewed-by: Keith Packard 

-- 
-keith


signature.asc
Description: PGP signature
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel

Re: [PATCH 1/1] dix/dispatch: Fix SmartScheduleClient interval adjustment to use best rather than pClient

2016-09-15 Thread Keith Packard
Keith Packard  writes:
>> Regressed-in: 8f1edf4bd3a1f050ce9eeb5eac45dd1a8f7a6d5e
>> Signed-off-by: Jeremy Huddleston Sequoia 
>
> Reviewed-by: Keith Packard 

Merged.
   265c4e6..d81f9ce  master -> master

-- 
-keith


signature.asc
Description: PGP signature
___
xorg-devel@lists.x.org: X.Org development
Archives: http://lists.x.org/archives/xorg-devel
Info: https://lists.x.org/mailman/listinfo/xorg-devel