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 NetBSD-ify sglist, updat...



details:   https://anonhg.NetBSD.org/src/rev/628dd94f7385
branches:  trunk
changeset: 1028621:628dd94f7385
user:      riastradh <riastradh%NetBSD.org@localhost>
date:      Sun Dec 19 11:31:19 2021 +0000

description:
NetBSD-ify sglist, update netbsd goo to newer struct


Author: Maya Rashish <maya%NetBSD.org@localhost>
Committer: Taylor R Campbell <riastradh%NetBSD.org@localhost>

diffstat:

 sys/external/bsd/drm2/dist/drm/i915/i915_gem_fence_reg.c |  18 ++++++++++++---
 1 files changed, 14 insertions(+), 4 deletions(-)

diffs (64 lines):

diff -r 52c6216e62aa -r 628dd94f7385 sys/external/bsd/drm2/dist/drm/i915/i915_gem_fence_reg.c
--- a/sys/external/bsd/drm2/dist/drm/i915/i915_gem_fence_reg.c  Sun Dec 19 11:31:11 2021 +0000
+++ b/sys/external/bsd/drm2/dist/drm/i915/i915_gem_fence_reg.c  Sun Dec 19 11:31:19 2021 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: i915_gem_fence_reg.c,v 1.2 2021/12/18 23:45:28 riastradh Exp $ */
+/*     $NetBSD: i915_gem_fence_reg.c,v 1.3 2021/12/19 11:31:19 riastradh Exp $ */
 
 /*
  * Copyright © 2008-2015 Intel Corporation
@@ -24,7 +24,7 @@
  */
 
 #include <sys/cdefs.h>
-__KERNEL_RCSID(0, "$NetBSD: i915_gem_fence_reg.c,v 1.2 2021/12/18 23:45:28 riastradh Exp $");
+__KERNEL_RCSID(0, "$NetBSD: i915_gem_fence_reg.c,v 1.3 2021/12/19 11:31:19 riastradh Exp $");
 
 #include <drm/i915_drm.h>
 
@@ -782,8 +782,13 @@
  * by swapping them out and back in again).
  */
 void
+#ifdef __NetBSD__
+i915_gem_object_do_bit_17_swizzle(struct drm_i915_gem_object *obj,
+                                 struct pglist *pages)
+#else
 i915_gem_object_do_bit_17_swizzle(struct drm_i915_gem_object *obj,
                                  struct sg_table *pages)
+#endif
 {
 #ifdef __NetBSD__
        struct vm_page *page;
@@ -798,7 +803,7 @@
 
 #ifdef __NetBSD__
        i = 0;
-       TAILQ_FOREACH(page, &obj->pageq, pageq.queue) {
+       TAILQ_FOREACH(page, &obj->mm.pageq, pageq.queue) {
                unsigned char new_bit_17 = VM_PAGE_TO_PHYS(page) >> 17;
                if ((new_bit_17 & 0x1) !=
                    (test_bit(i, obj->bit_17) != 0)) {
@@ -833,8 +838,13 @@
  * be called before the backing storage can be unpinned.
  */
 void
+#ifdef __NetBSD__
+i915_gem_object_save_bit_17_swizzle(struct drm_i915_gem_object *obj,
+                                   struct pglist *pages)
+#else
 i915_gem_object_save_bit_17_swizzle(struct drm_i915_gem_object *obj,
                                    struct sg_table *pages)
+#endif
 {
 #ifdef __NetBSD__
        struct vm_page *page;
@@ -857,7 +867,7 @@
        i = 0;
 
 #ifdef __NetBSD__
-       TAILQ_FOREACH(page, &obj->pageq, pageq.queue) {
+       TAILQ_FOREACH(page, &obj->mm.pageq, pageq.queue) {
                if (ISSET(VM_PAGE_TO_PHYS(page), __BIT(17)))
                        __set_bit(i, obj->bit_17);
                else



Home | Main Index | Thread Index | Old Index