Source-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[src/trunk]: src/sys/external/bsd/drm2/dist/drm/i915 i915: Allow duplicates i...



details:   https://anonhg.NetBSD.org/src/rev/55eb3376d118
branches:  trunk
changeset: 1028852:55eb3376d118
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Sun Dec 19 12:12:39 2021 +0000

description:
i915: Allow duplicates in active tree, sorted by kva.

Upstream looks like it uses insertion order, but that's not really
convenient.

diffstat:

 sys/external/bsd/drm2/dist/drm/i915/i915_active.c |  8 ++++++--
 1 files changed, 6 insertions(+), 2 deletions(-)

diffs (29 lines):

diff -r ab923424dc2a -r 55eb3376d118 sys/external/bsd/drm2/dist/drm/i915/i915_active.c
--- a/sys/external/bsd/drm2/dist/drm/i915/i915_active.c Sun Dec 19 12:12:31 2021 +0000
+++ b/sys/external/bsd/drm2/dist/drm/i915/i915_active.c Sun Dec 19 12:12:39 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: i915_active.c,v 1.8 2021/12/19 12:11:14 riastradh Exp $        */
+/*     $NetBSD: i915_active.c,v 1.9 2021/12/19 12:12:39 riastradh Exp $        */
 
 /*
  * SPDX-License-Identifier: MIT
@@ -7,7 +7,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: i915_active.c,v 1.8 2021/12/19 12:11:14 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: i915_active.c,v 1.9 2021/12/19 12:12:39 riastradh Exp $");
 
 #include <linux/debugobjects.h>
 
@@ -143,6 +143,10 @@
                return -1;
        if (a->timeline > b->timeline)
                return +1;
+       if ((uintptr_t)a < (uintptr_t)b)
+               return -1;
+       if ((uintptr_t)a > (uintptr_t)b)
+               return +1;
        return 0;
 }
 



Home | Main Index | Thread Index | Old Index