Skip to contentSkip to conversation

linux-next: build failure after merge of the drm-misc tree

PATCH New Stephen Rothwell 5 participants 13 messages Apr 1, 2019 – Apr 3, 2019

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

Hi all,

After merging the drm-misc tree, today's linux-next build (x86_64 allmodconfig) failed like this:

In file included from include/linux/kernel.h:7,

                 from include/asm-generic/bug.h:18,
                 from arch/x86/include/asm/bug.h:83,
                 from include/linux/bug.h:5,
                 from include/linux/mmdebug.h:5,
                 from include/linux/gfp.h:5,
                 from include/linux/slab.h:15,
                 from drivers/gpu/drm/lima/lima_ctx.c:4:
drivers/gpu/drm/lima/lima_ctx.c: In function 'lima_ctx_create':
include/linux/limits.h:13:18: warning: passing argument 3 of 'xa_alloc' makes pointer from integer without a cast [-Wint-conversion]
 #define UINT_MAX (~0U)
                  ^~~~~
drivers/gpu/drm/lima/lima_ctx.c:26:36: note: in expansion of macro 'UINT_MAX'
  err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
                                    ^~~~~~~~

In file included from include/linux/radix-tree.h:31,
from include/linux/idr.h:15,
from include/drm/drm_device.h:7,
from drivers/gpu/drm/lima/lima_device.h:7,
from drivers/gpu/drm/lima/lima_ctx.c:6:
include/linux/xarray.h:817:9: note: expected 'void *' but argument is of type 'unsigned int'
void *entry, struct xa_limit limit, gfp_t gfp)
~~~~~~^~~~~
drivers/gpu/drm/lima/lima_ctx.c:26:46: error: incompatible type for argument 4 of 'xa_alloc'

  err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
                                              ^~~

In file included from include/linux/radix-tree.h:31,
from include/linux/idr.h:15,
from include/drm/drm_device.h:7,
from drivers/gpu/drm/lima/lima_device.h:7,
from drivers/gpu/drm/lima/lima_ctx.c:6:
include/linux/xarray.h:817:32: note: expected 'struct xa_limit' but argument is of type 'struct lima_ctx *'
void *entry, struct xa_limit limit, gfp_t gfp)

                ~~~~~~~~~~~~~~~~^~~~~

Caused by commit

a1d2a6339961 ("drm/lima: driver for ARM Mali4xx GPUs")

interacting with commit

a3e4d3f97ec8 ("XArray: Redesign xa_alloc API")

from Linus' tree (v5.1-rc1).

I have applied the following patch for today. It could be applied as part of a merge of v5.1-rc1 into drm-misc.

From: Stephen Rothwell <[email protected]>
Date: Tue, 2 Apr 2019 10:45:32 +1100
Subject: [PATCH] drm/lima: update for xa_alloc API change

---
 drivers/gpu/drm/lima/lima_ctx.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/lima/lima_ctx.c +1 -1
index c8d12f7c6894..bafa00d74cc5 100644
@@ -23,7 +23,7 @@ int lima_ctx_create(struct lima_device *dev, struct lima_ctx_mgr *mgr, u32 *id)
 			goto err_out0;
 	}
 
-	err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
+	err = xa_alloc(&mgr->handles, id, ctx, XA_LIMIT(*id, UINT_MAX), GFP_KERNEL);
 	if (err < 0)
 		goto err_out0;
 
Signature · 5 lines
2.20.1

-- 
Cheers,
Stephen Rothwell

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

maintainer Reviewed-by
#1 lore raw

Thanks, patch is:

Regards,
Qiang

Quoted 82 lines · Stephen Rothwell

Hi all,

After merging the drm-misc tree, today's linux-next build (x86_64 allmodconfig) failed like this:

In file included from include/linux/kernel.h:7,

                 from include/asm-generic/bug.h:18,
                 from arch/x86/include/asm/bug.h:83,
                 from include/linux/bug.h:5,
                 from include/linux/mmdebug.h:5,
                 from include/linux/gfp.h:5,
                 from include/linux/slab.h:15,
                 from drivers/gpu/drm/lima/lima_ctx.c:4:
drivers/gpu/drm/lima/lima_ctx.c: In function 'lima_ctx_create':
include/linux/limits.h:13:18: warning: passing argument 3 of 'xa_alloc' makes pointer from integer without a cast [-Wint-conversion]
 #define UINT_MAX (~0U)
                  ^~~~~
drivers/gpu/drm/lima/lima_ctx.c:26:36: note: in expansion of macro 'UINT_MAX'
  err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
                                    ^~~~~~~~

In file included from include/linux/radix-tree.h:31,
from include/linux/idr.h:15,
from include/drm/drm_device.h:7,
from drivers/gpu/drm/lima/lima_device.h:7,
from drivers/gpu/drm/lima/lima_ctx.c:6:
include/linux/xarray.h:817:9: note: expected 'void *' but argument is of type 'unsigned int'
void *entry, struct xa_limit limit, gfp_t gfp)
~~~~~~^~~~~
drivers/gpu/drm/lima/lima_ctx.c:26:46: error: incompatible type for argument 4 of 'xa_alloc'

  err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
                                              ^~~

In file included from include/linux/radix-tree.h:31,
from include/linux/idr.h:15,
from include/drm/drm_device.h:7,
from drivers/gpu/drm/lima/lima_device.h:7,
from drivers/gpu/drm/lima/lima_ctx.c:6:
include/linux/xarray.h:817:32: note: expected 'struct xa_limit' but argument is of type 'struct lima_ctx *'
void *entry, struct xa_limit limit, gfp_t gfp)

                ~~~~~~~~~~~~~~~~^~~~~

Caused by commit

a1d2a6339961 ("drm/lima: driver for ARM Mali4xx GPUs")

interacting with commit

a3e4d3f97ec8 ("XArray: Redesign xa_alloc API")

from Linus' tree (v5.1-rc1).

I have applied the following patch for today. It could be applied as part of a merge of v5.1-rc1 into drm-misc.

From: Stephen Rothwell <[email protected]>
Date: Tue, 2 Apr 2019 10:45:32 +1100
Subject: [PATCH] drm/lima: update for xa_alloc API change

---
 drivers/gpu/drm/lima/lima_ctx.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/lima/lima_ctx.c +1 -2
index c8d12f7c6894..bafa00d74cc5 100644
@@ -23,7 +23,7 @@ int lima_ctx_create(struct lima_device *dev, struct lima_ctx_mgr *mgr, u32 *id)
                        goto err_out0;
        }
 
-       err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
+       err = xa_alloc(&mgr->handles, id, ctx, XA_LIMIT(*id, UINT_MAX), GFP_KERNEL);
        if (err < 0)
                goto err_out0;
 
--

2.20.1

--
Cheers,
Stephen Rothwell

#2 lore raw
Quoted 2 lines · Qiang Yu

Thanks, patch is:

Good time to get started with committing patches? In general it's kinda confusing if the maintainer r-bs a patch, but doesn't say whether/when/how it gets merged. Big chance the patch will get lost in limbo and fall through cracks.
-Daniel

Quoted 87 lines

Regards,
Qiang

Quoted 82 lines · Stephen Rothwell

Hi all,

After merging the drm-misc tree, today's linux-next build (x86_64 allmodconfig) failed like this:

In file included from include/linux/kernel.h:7,

                 from include/asm-generic/bug.h:18,
                 from arch/x86/include/asm/bug.h:83,
                 from include/linux/bug.h:5,
                 from include/linux/mmdebug.h:5,
                 from include/linux/gfp.h:5,
                 from include/linux/slab.h:15,
                 from drivers/gpu/drm/lima/lima_ctx.c:4:
drivers/gpu/drm/lima/lima_ctx.c: In function 'lima_ctx_create':
include/linux/limits.h:13:18: warning: passing argument 3 of 'xa_alloc' makes pointer from integer without a cast [-Wint-conversion]
 #define UINT_MAX (~0U)
                  ^~~~~
drivers/gpu/drm/lima/lima_ctx.c:26:36: note: in expansion of macro 'UINT_MAX'
  err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
                                    ^~~~~~~~

In file included from include/linux/radix-tree.h:31,
from include/linux/idr.h:15,
from include/drm/drm_device.h:7,
from drivers/gpu/drm/lima/lima_device.h:7,
from drivers/gpu/drm/lima/lima_ctx.c:6:
include/linux/xarray.h:817:9: note: expected 'void *' but argument is of type 'unsigned int'
void *entry, struct xa_limit limit, gfp_t gfp)
~~~~~~^~~~~
drivers/gpu/drm/lima/lima_ctx.c:26:46: error: incompatible type for argument 4 of 'xa_alloc'

  err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
                                              ^~~

In file included from include/linux/radix-tree.h:31,
from include/linux/idr.h:15,
from include/drm/drm_device.h:7,
from drivers/gpu/drm/lima/lima_device.h:7,
from drivers/gpu/drm/lima/lima_ctx.c:6:
include/linux/xarray.h:817:32: note: expected 'struct xa_limit' but argument is of type 'struct lima_ctx *'
void *entry, struct xa_limit limit, gfp_t gfp)

                ~~~~~~~~~~~~~~~~^~~~~

Caused by commit

a1d2a6339961 ("drm/lima: driver for ARM Mali4xx GPUs")

interacting with commit

a3e4d3f97ec8 ("XArray: Redesign xa_alloc API")

from Linus' tree (v5.1-rc1).

I have applied the following patch for today. It could be applied as part of a merge of v5.1-rc1 into drm-misc.

From: Stephen Rothwell <[email protected]>
Date: Tue, 2 Apr 2019 10:45:32 +1100
Subject: [PATCH] drm/lima: update for xa_alloc API change

---
 drivers/gpu/drm/lima/lima_ctx.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/lima/lima_ctx.c +1 -2
index c8d12f7c6894..bafa00d74cc5 100644
@@ -23,7 +23,7 @@ int lima_ctx_create(struct lima_device *dev, struct lima_ctx_mgr *mgr, u32 *id)
                        goto err_out0;
        }
 
-       err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
+       err = xa_alloc(&mgr->handles, id, ctx, XA_LIMIT(*id, UINT_MAX), GFP_KERNEL);
        if (err < 0)
                goto err_out0;
 
--

2.20.1

--
Cheers,
Stephen Rothwell

Signature · 3 lines
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
maintainer
#3 lore raw
Quoted 9 lines · Daniel Vetter
Quoted 2 lines · Qiang Yu

Thanks, patch is:

Good time to get started with committing patches? In general it's kinda confusing if the maintainer r-bs a patch, but doesn't say whether/when/how it gets merged. Big chance the patch will get lost in limbo and fall through cracks.

Thanks for the remind, this patch should only be applied to drm-misc-next branch when 5.1-rcx branch gets merged to drm-misc-next for the new xa_alloc API. So I expect the guy who do the 5.1-rcx merge should apply this patch. Who will do the merge?

Regards,
Qiang

Quoted 93 lines
Quoted 82 lines

Regards,
Qiang

Quoted 76 lines · Stephen Rothwell

Hi all,

After merging the drm-misc tree, today's linux-next build (x86_64 allmodconfig) failed like this:

In file included from include/linux/kernel.h:7,

                 from include/asm-generic/bug.h:18,
                 from arch/x86/include/asm/bug.h:83,
                 from include/linux/bug.h:5,
                 from include/linux/mmdebug.h:5,
                 from include/linux/gfp.h:5,
                 from include/linux/slab.h:15,
                 from drivers/gpu/drm/lima/lima_ctx.c:4:
drivers/gpu/drm/lima/lima_ctx.c: In function 'lima_ctx_create':
include/linux/limits.h:13:18: warning: passing argument 3 of 'xa_alloc' makes pointer from integer without a cast [-Wint-conversion]
 #define UINT_MAX (~0U)
                  ^~~~~
drivers/gpu/drm/lima/lima_ctx.c:26:36: note: in expansion of macro 'UINT_MAX'
  err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
                                    ^~~~~~~~

In file included from include/linux/radix-tree.h:31,
from include/linux/idr.h:15,
from include/drm/drm_device.h:7,
from drivers/gpu/drm/lima/lima_device.h:7,
from drivers/gpu/drm/lima/lima_ctx.c:6:
include/linux/xarray.h:817:9: note: expected 'void *' but argument is of type 'unsigned int'
void *entry, struct xa_limit limit, gfp_t gfp)
~~~~~~^~~~~
drivers/gpu/drm/lima/lima_ctx.c:26:46: error: incompatible type for argument 4 of 'xa_alloc'

  err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
                                              ^~~

In file included from include/linux/radix-tree.h:31,
from include/linux/idr.h:15,
from include/drm/drm_device.h:7,
from drivers/gpu/drm/lima/lima_device.h:7,
from drivers/gpu/drm/lima/lima_ctx.c:6:
include/linux/xarray.h:817:32: note: expected 'struct xa_limit' but argument is of type 'struct lima_ctx *'
void *entry, struct xa_limit limit, gfp_t gfp)

                ~~~~~~~~~~~~~~~~^~~~~

Caused by commit

a1d2a6339961 ("drm/lima: driver for ARM Mali4xx GPUs")

interacting with commit

a3e4d3f97ec8 ("XArray: Redesign xa_alloc API")

from Linus' tree (v5.1-rc1).

I have applied the following patch for today. It could be applied as part of a merge of v5.1-rc1 into drm-misc.

From: Stephen Rothwell <[email protected]>
Date: Tue, 2 Apr 2019 10:45:32 +1100
Subject: [PATCH] drm/lima: update for xa_alloc API change

---
 drivers/gpu/drm/lima/lima_ctx.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/lima/lima_ctx.c +1 -1
index c8d12f7c6894..bafa00d74cc5 100644
@@ -23,7 +23,7 @@ int lima_ctx_create(struct lima_device *dev, struct lima_ctx_mgr *mgr, u32 *id)
                        goto err_out0;
        }
 
-       err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
+       err = xa_alloc(&mgr->handles, id, ctx, XA_LIMIT(*id, UINT_MAX), GFP_KERNEL);
        if (err < 0)
                goto err_out0;
 
Quoted 6 lines
Quoted 6 lines

--
2.20.1

--
Cheers,
Stephen Rothwell

--
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch

#4 lore raw
Quoted 11 lines · Qiang Yu
Quoted 9 lines · Daniel Vetter
Quoted 2 lines · Qiang Yu

Thanks, patch is:

Good time to get started with committing patches? In general it's kinda confusing if the maintainer r-bs a patch, but doesn't say whether/when/how it gets merged. Big chance the patch will get lost in limbo and fall through cracks.

Quoted 4 lines

Thanks for the remind, this patch should only be applied to drm-misc-next branch when 5.1-rcx branch gets merged to drm-misc-next for the new xa_alloc API. So I expect the guy who do the 5.1-rcx merge should apply this patch. Who will do the merge?

Oh right, I was kinda not yet awake :-)

Yeah Dave/me and drm-misc maintainers will resolve this when drm-misc lands in drm-next. Might then need a backmerge in drm-misc to roll forward.
-Daniel

Quoted 97 lines

Regards,
Qiang

Quoted 93 lines
Quoted 82 lines

Regards,
Qiang

Quoted 76 lines · Stephen Rothwell

Hi all,

After merging the drm-misc tree, today's linux-next build (x86_64 allmodconfig) failed like this:

In file included from include/linux/kernel.h:7,

                 from include/asm-generic/bug.h:18,
                 from arch/x86/include/asm/bug.h:83,
                 from include/linux/bug.h:5,
                 from include/linux/mmdebug.h:5,
                 from include/linux/gfp.h:5,
                 from include/linux/slab.h:15,
                 from drivers/gpu/drm/lima/lima_ctx.c:4:
drivers/gpu/drm/lima/lima_ctx.c: In function 'lima_ctx_create':
include/linux/limits.h:13:18: warning: passing argument 3 of 'xa_alloc' makes pointer from integer without a cast [-Wint-conversion]
 #define UINT_MAX (~0U)
                  ^~~~~
drivers/gpu/drm/lima/lima_ctx.c:26:36: note: in expansion of macro 'UINT_MAX'
  err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
                                    ^~~~~~~~

In file included from include/linux/radix-tree.h:31,
from include/linux/idr.h:15,
from include/drm/drm_device.h:7,
from drivers/gpu/drm/lima/lima_device.h:7,
from drivers/gpu/drm/lima/lima_ctx.c:6:
include/linux/xarray.h:817:9: note: expected 'void *' but argument is of type 'unsigned int'
void *entry, struct xa_limit limit, gfp_t gfp)
~~~~~~^~~~~
drivers/gpu/drm/lima/lima_ctx.c:26:46: error: incompatible type for argument 4 of 'xa_alloc'

  err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
                                              ^~~

In file included from include/linux/radix-tree.h:31,
from include/linux/idr.h:15,
from include/drm/drm_device.h:7,
from drivers/gpu/drm/lima/lima_device.h:7,
from drivers/gpu/drm/lima/lima_ctx.c:6:
include/linux/xarray.h:817:32: note: expected 'struct xa_limit' but argument is of type 'struct lima_ctx *'
void *entry, struct xa_limit limit, gfp_t gfp)

                ~~~~~~~~~~~~~~~~^~~~~

Caused by commit

a1d2a6339961 ("drm/lima: driver for ARM Mali4xx GPUs")

interacting with commit

a3e4d3f97ec8 ("XArray: Redesign xa_alloc API")

from Linus' tree (v5.1-rc1).

I have applied the following patch for today. It could be applied as part of a merge of v5.1-rc1 into drm-misc.

From: Stephen Rothwell <[email protected]>
Date: Tue, 2 Apr 2019 10:45:32 +1100
Subject: [PATCH] drm/lima: update for xa_alloc API change

---
 drivers/gpu/drm/lima/lima_ctx.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/lima/lima_ctx.c +1 -1
index c8d12f7c6894..bafa00d74cc5 100644
@@ -23,7 +23,7 @@ int lima_ctx_create(struct lima_device *dev, struct lima_ctx_mgr *mgr, u32 *id)
                        goto err_out0;
        }
 
-       err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
+       err = xa_alloc(&mgr->handles, id, ctx, XA_LIMIT(*id, UINT_MAX), GFP_KERNEL);
        if (err < 0)
                goto err_out0;
 
Quoted 6 lines
Quoted 6 lines

--
2.20.1

--
Cheers,
Stephen Rothwell

--
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch

Signature · 7 lines
Daniel Vetter
Software Engineer, Intel Corporation
http://blog.ffwll.ch
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
#5 lore raw
In reply to Qiang Yu
Quoted 2 lines · Qiang Yu

Thanks, patch is:

This looks like a fairly naive conversion from the old IDR API to the XArray API. You should be able to remove mgr->lock entirely, relying on the xa_lock for synchronising free and get. If you think it's worth it, you could even use kfree_rcu() to free the ctx and kref_get_unless_zero() and then your get path would be lock-free.

maintainer
#6 lore raw
Quoted 8 lines · Matthew Wilcox
Quoted 2 lines · Qiang Yu

Thanks, patch is:

This looks like a fairly naive conversion from the old IDR API to the XArray API. You should be able to remove mgr->lock entirely, relying on the xa_lock for synchronising free and get.

I'm afraid the a little complex free path may involve some might sleep functions so use a mutex lock instead of spinlock.

Quoted 3 lines

If you think it's worth it,
you could even use kfree_rcu() to free the ctx and kref_get_unless_zero() and then your get path would be lock-free.

I can take a look this way, thanks.

#7 lore raw
Quoted 6 lines · Qiang Yu
Quoted 5 lines · Matthew Wilcox
Quoted 2 lines · Qiang Yu

Thanks, patch is:

Quoted 6 lines
Quoted 3 lines

This looks like a fairly naive conversion from the old IDR API to the XArray API. You should be able to remove mgr->lock entirely, relying on the xa_lock for synchronising free and get.

I'm afraid the a little complex free path may involve some might sleep functions so use a mutex lock instead of spinlock.

Ah, good call ...

+       mutex_lock(&mgr->lock);
+       ctx = xa_erase(&mgr->handles, id);
+       if (ctx)

+ kref_put(&ctx->refcnt, lima_ctx_do_release);
+ else
+ ret = -EINVAL;
+ mutex_unlock(&mgr->lock);

+static void lima_ctx_do_release(struct kref *ref) +{
+ struct lima_ctx *ctx = container_of(ref, struct lima_ctx, refcnt);
+ int i;
+
+ for (i = 0; i < lima_pipe_num; i++)
+ lima_sched_context_fini(ctx->dev->pipe + i, ctx->context + i);
+ kfree(ctx);
+}

+void lima_sched_context_fini(struct lima_sched_pipe *pipe,
+ struct lima_sched_context *context)
+{
+ drm_sched_entity_fini(&context->base);
+}

and drm_sched_entity_fini() can call kthread_park(), which does sleep.

Quoted 5 lines
Quoted 3 lines

If you think it's worth it,
you could even use kfree_rcu() to free the ctx and kref_get_unless_zero() and then your get path would be lock-free.

I can take a look this way, thanks.

I think that's the only way you can get rid of the mutex, given the sleeping functions called in the free path.

#8 lore raw
In reply to Stephen Rothwell

drivers/gpu/drm/lima/lima_ctx.c int lima_ctx_create(struct lima_device *dev, struct lima_ctx_mgr *mgr, u32 *id) · line 28

Quoted 9 lines · Stephen Rothwell

+++ b/drivers/gpu/drm/lima/lima_ctx.c

drivers/gpu/drm/lima/lima_ctx.c +1 -1
@@ -23,7 +23,7 @@ int lima_ctx_create(struct lima_device *dev, struct lima_ctx_mgr *mgr, u32 *id)
 			goto err_out0;
 	}
 
-	err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
+	err = xa_alloc(&mgr->handles, id, ctx, XA_LIMIT(*id, UINT_MAX), GFP_KERNEL);
 	if (err < 0)
 		goto err_out0;

I agree that this is an exact translation of what the code was doing, but I don't think it's what the author intended the code to do. They almost certainly meant:

	err = xa_alloc(&mgr->handles, id, ctx, xa_limit_32b, GFP_KERNEL);

I'm basing this on:

+struct drm_lima_ctx_create {

+       __u32 id;          /* out, context handle */
+       __u32 _pad;        /* pad, must be zero */

+};

(and this confusion is exactly why I changed the API ...)
_______________________________________________
Intel-gfx mailing list [email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

maintainer
#9 lore raw
Quoted 25 lines · Matthew Wilcox

drivers/gpu/drm/lima/lima_ctx.c int lima_ctx_create(struct lima_device *dev, struct lima_ctx_mgr *mgr, u32 *id) · line 28

Quoted 9 lines · Stephen Rothwell

+++ b/drivers/gpu/drm/lima/lima_ctx.c

drivers/gpu/drm/lima/lima_ctx.c +1 -1
@@ -23,7 +23,7 @@ int lima_ctx_create(struct lima_device *dev, struct lima_ctx_mgr *mgr, u32 *id)
                      goto err_out0;
      }
 
-     err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
+     err = xa_alloc(&mgr->handles, id, ctx, XA_LIMIT(*id, UINT_MAX), GFP_KERNEL);
      if (err < 0)
              goto err_out0;

I agree that this is an exact translation of what the code was doing, but I don't think it's what the author intended the code to do. They almost certainly meant:

        err = xa_alloc(&mgr->handles, id, ctx, xa_limit_32b, GFP_KERNEL);

I'm basing this on:

(quoted diff) +4 -0
+struct drm_lima_ctx_create {
+       __u32 id;          /* out, context handle */
+       __u32 _pad;        /* pad, must be zero */
+};
Quoted 1 line

(and this confusion is exactly why I changed the API ...)

Right, I plan to send out a patch like yours after drm-misc-next merge 5.1 changes, as this is a build fix patch and already applied to somewhere. I can send out another patch now if merge guys could use the new one directly.

maintainer
#10 lore raw

PATCH 1/1 drm/lima: adopt xa_alloc API change

Cc Stephen Rothwell <[email protected]>
Cc Matthew Wilcox <[email protected]>
Cc Daniel Vetter <[email protected]>
---
 drivers/gpu/drm/lima/lima_ctx.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/lima/lima_ctx.c +1 -1
index c8d12f7c6894..22fff6caa961 100644
@@ -23,7 +23,7 @@ int lima_ctx_create(struct lima_device *dev, struct lima_ctx_mgr *mgr, u32 *id)
 			goto err_out0;
 	}
 
-	err = xa_alloc(&mgr->handles, id, UINT_MAX, ctx, GFP_KERNEL);
+	err = xa_alloc(&mgr->handles, id, ctx, xa_limit_32b, GFP_KERNEL);
 	if (err < 0)
 		goto err_out0;
 
Signature · 1 line
2.17.1
#11 lore raw

✓ Fi.CI.BAT: success for linux-next: build failure after merge of the drm-misc tree (rev2)

In reply to Stephen Rothwell
== Series Details ==

== Series Details ==

Series: linux-next: build failure after merge of the drm-misc tree (rev2)
URL : https://patchwork.freedesktop.org/series/58857/
State : success

== Summary ==

CI Bug Log - changes from CI_DRM_5856 -> Patchwork_12658
====================================================

Summary
-------

**SUCCESS**

No regressions found.

External URL: https://patchwork.freedesktop.org/api/1.0/series/58857/revisions/2/mbox/

Known issues
------------

Here are the changes found in Patchwork_12658 that come from known issues:

### IGT changes ###

#### Issues hit ####

* igt@amdgpu/amd_cs_nop@fork-compute0:
- fi-icl-y: NOTRUN -> SKIP [fdo#109315] +17

* igt@amdgpu/amd_cs_nop@fork-gfx0:
- fi-icl-u2: NOTRUN -> SKIP [fdo#109315] +17

* igt@gem_exec_basic@basic-bsd2:
- fi-kbl-7500u: NOTRUN -> SKIP [fdo#109271] +9
- fi-icl-y: NOTRUN -> SKIP [fdo#109276] +7

* igt@gem_exec_basic@readonly-bsd1:
- fi-icl-u2: NOTRUN -> SKIP [fdo#109276] +7

* igt@gem_exec_parse@basic-allowed:
- fi-icl-u2: NOTRUN -> SKIP [fdo#109289] +1

* igt@gem_exec_parse@basic-rejected:
- fi-icl-y: NOTRUN -> SKIP [fdo#109289] +1

* igt@i915_selftest@live_contexts:
- fi-icl-u2: NOTRUN -> DMESG-FAIL [fdo#108569]
- fi-icl-y: NOTRUN -> DMESG-FAIL [fdo#108569]

* igt@i915_selftest@live_execlists:
- fi-apl-guc: NOTRUN -> INCOMPLETE [fdo#103927] / [fdo#109720]

* igt@kms_chamelium@dp-crc-fast:
- fi-kbl-7500u: NOTRUN -> DMESG-WARN [fdo#103841]
- fi-icl-y: NOTRUN -> SKIP [fdo#109284] +8

* igt@kms_chamelium@dp-edid-read:
- fi-icl-u2: NOTRUN -> SKIP [fdo#109316] +2

* igt@kms_chamelium@vga-hpd-fast:
- fi-icl-u2: NOTRUN -> SKIP [fdo#109309] +1

* igt@kms_force_connector_basic@force-load-detect:
- fi-icl-y: NOTRUN -> SKIP [fdo#109285] +3

* igt@kms_force_connector_basic@prune-stale-modes:
- fi-icl-u2: NOTRUN -> SKIP [fdo#109285] +3

* igt@kms_frontbuffer_tracking@basic:
- fi-icl-u2: NOTRUN -> FAIL [fdo#103167]

* igt@kms_pipe_crc_basic@nonblocking-crc-pipe-a-frame-sequence:
- fi-byt-clapper: PASS -> FAIL [fdo#103191] / [fdo#107362] +1

* igt@kms_psr@primary_mmap_gtt:
- fi-icl-y: NOTRUN -> SKIP [fdo#110189] +3
- fi-byt-clapper: NOTRUN -> SKIP [fdo#109271] +23

* igt@kms_psr@primary_page_flip:
- fi-apl-guc: NOTRUN -> SKIP [fdo#109271] +50

* igt@prime_vgem@basic-fence-flip:
- fi-icl-y: NOTRUN -> SKIP [fdo#109294]

* igt@runner@aborted:
- fi-kbl-7500u: NOTRUN -> FAIL [fdo#103841]
- fi-apl-guc: NOTRUN -> FAIL [fdo#108622] / [fdo#109720]

#### Possible fixes ####

* igt@i915_selftest@live_contexts:
- fi-bdw-gvtdvm: DMESG-FAIL [fdo#110235 ] -> PASS
- fi-skl-gvtdvm: DMESG-FAIL [fdo#110235 ] -> PASS

* igt@i915_selftest@live_uncore:
- fi-skl-gvtdvm: DMESG-FAIL [fdo#110210] -> PASS

* igt@kms_pipe_crc_basic@nonblocking-crc-pipe-b:
- fi-byt-clapper: FAIL [fdo#107362] -> PASS

* igt@kms_pipe_crc_basic@read-crc-pipe-b-frame-sequence:
- fi-byt-clapper: FAIL [fdo#103191] / [fdo#107362] -> PASS

* igt@kms_pipe_crc_basic@suspend-read-crc-pipe-a:
- fi-byt-clapper: INCOMPLETE [fdo#102657] -> PASS

#### Warnings ####

* igt@i915_selftest@live_contexts:
- fi-icl-u3: INCOMPLETE [fdo#108569] -> DMESG-FAIL [fdo#108569]

[fdo#102657]: https://bugs.freedesktop.org/show_bug.cgi?id=102657
[fdo#103167]: https://bugs.freedesktop.org/show_bug.cgi?id=103167
[fdo#103191]: https://bugs.freedesktop.org/show_bug.cgi?id=103191
[fdo#103841]: https://bugs.freedesktop.org/show_bug.cgi?id=103841
[fdo#103927]: https://bugs.freedesktop.org/show_bug.cgi?id=103927
[fdo#107362]: https://bugs.freedesktop.org/show_bug.cgi?id=107362
[fdo#108569]: https://bugs.freedesktop.org/show_bug.cgi?id=108569
[fdo#108622]: https://bugs.freedesktop.org/show_bug.cgi?id=108622
[fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
[fdo#109276]: https://bugs.freedesktop.org/show_bug.cgi?id=109276
[fdo#109284]: https://bugs.freedesktop.org/show_bug.cgi?id=109284
[fdo#109285]: https://bugs.freedesktop.org/show_bug.cgi?id=109285
[fdo#109289]: https://bugs.freedesktop.org/show_bug.cgi?id=109289
[fdo#109294]: https://bugs.freedesktop.org/show_bug.cgi?id=109294
[fdo#109309]: https://bugs.freedesktop.org/show_bug.cgi?id=109309
[fdo#109315]: https://bugs.freedesktop.org/show_bug.cgi?id=109315
[fdo#109316]: https://bugs.freedesktop.org/show_bug.cgi?id=109316
[fdo#109720]: https://bugs.freedesktop.org/show_bug.cgi?id=109720
[fdo#110189]: https://bugs.freedesktop.org/show_bug.cgi?id=110189
[fdo#110210]: https://bugs.freedesktop.org/show_bug.cgi?id=110210
[fdo#110235 ]: https://bugs.freedesktop.org/show_bug.cgi?id=110235

Participating hosts (43 -> 43)
------------------------------

Additional (4): fi-icl-y fi-icl-u2 fi-apl-guc fi-kbl-7500u
Missing (4): fi-ilk-m540 fi-byt-squawks fi-skl-6260u fi-bdw-samus

Build changes
-------------

* Linux: CI_DRM_5856 -> Patchwork_12658

CI_DRM_5856: 55074bd825098a71779cf65a69786547f0eccbe9 @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_4922: e941e4a29438c7130554492e4daf52afbc99ffdf @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
Patchwork_12658: d3a8d7507f421fbdd1157c1df0e3d3a484c56eff @ git://anongit.freedesktop.org/gfx-ci/linux

== Linux commits ==

d3a8d7507f42 drm/lima: adopt xa_alloc API change

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_12658/
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx

#12 lore raw

✓ Fi.CI.IGT: success for linux-next: build failure after merge of the drm-misc tree (rev2)

In reply to Stephen Rothwell
== Series Details ==

== Series Details ==

Series: linux-next: build failure after merge of the drm-misc tree (rev2)
URL : https://patchwork.freedesktop.org/series/58857/
State : success

== Summary ==

CI Bug Log - changes from CI_DRM_5856_full -> Patchwork_12658_full
====================================================

Summary
-------

**SUCCESS**

No regressions found.

Known issues
------------

Here are the changes found in Patchwork_12658_full that come from known issues:

### IGT changes ###

#### Issues hit ####

* igt@gem_ctx_isolation@vecs0-s3:
- shard-skl: PASS -> INCOMPLETE [fdo#104108] / [fdo#107773]

* igt@gem_exec_schedule@preempt-self-bsd1:
- shard-iclb: NOTRUN -> SKIP [fdo#109276]

* igt@gem_exec_store@cachelines-bsd2:
- shard-glk: NOTRUN -> SKIP [fdo#109271] +20

* igt@gem_pwrite@stolen-normal:
- shard-skl: NOTRUN -> SKIP [fdo#109271] +93

* igt@gem_stolen@stolen-no-mmap:
- shard-iclb: NOTRUN -> SKIP [fdo#109277]

* igt@i915_pm_rpm@gem-mmap-cpu:
- shard-skl: PASS -> INCOMPLETE [fdo#107807]

* igt@i915_pm_rpm@system-suspend-execbuf:
- shard-iclb: PASS -> DMESG-WARN [fdo#109638]

* igt@i915_pm_sseu@full-enable:
- shard-iclb: NOTRUN -> SKIP [fdo#109288]

* igt@i915_selftest@live_workarounds:
- shard-iclb: PASS -> DMESG-FAIL [fdo#108954]

* igt@kms_available_modes_crc@available_mode_test_crc:
- shard-snb: NOTRUN -> FAIL [fdo#106641]

* igt@kms_busy@basic-modeset-e:
- shard-kbl: NOTRUN -> SKIP [fdo#109271] / [fdo#109278]

* igt@kms_busy@extended-modeset-hang-newfb-with-reset-render-a:
- shard-skl: NOTRUN -> DMESG-WARN [fdo#110222]

* igt@kms_busy@extended-modeset-hang-oldfb-render-e:
- shard-skl: NOTRUN -> SKIP [fdo#109271] / [fdo#109278] +9

* igt@kms_concurrent@pipe-f:
- shard-iclb: NOTRUN -> SKIP [fdo#109278] +1

* igt@kms_fbcon_fbt@psr-suspend:
- shard-skl: NOTRUN -> FAIL [fdo#103833]

* igt@kms_flip@2x-wf_vblank-ts-check:
- shard-snb: NOTRUN -> SKIP [fdo#109271] +73

* igt@kms_force_connector_basic@force-connector-state:
- shard-iclb: NOTRUN -> SKIP [fdo#109285]

* igt@kms_frontbuffer_tracking@fbc-1p-primscrn-pri-indfb-draw-render:
- shard-iclb: PASS -> FAIL [fdo#103167] +1

* igt@kms_frontbuffer_tracking@fbcpsr-2p-primscrn-cur-indfb-draw-mmap-cpu:
- shard-iclb: NOTRUN -> SKIP [fdo#109280] +1

* igt@kms_frontbuffer_tracking@fbcpsr-2p-primscrn-cur-indfb-draw-mmap-wc:
- shard-kbl: NOTRUN -> SKIP [fdo#109271] +24

* igt@kms_frontbuffer_tracking@fbcpsr-rgb101010-draw-pwrite:
- shard-iclb: PASS -> FAIL [fdo#105682] / [fdo#109247]

* igt@kms_frontbuffer_tracking@fbcpsr-stridechange:
- shard-skl: NOTRUN -> FAIL [fdo#105683]

* igt@kms_frontbuffer_tracking@psr-1p-primscrn-pri-shrfb-draw-render:
- shard-skl: NOTRUN -> FAIL [fdo#103167]

* igt@kms_frontbuffer_tracking@psr-rgb101010-draw-blt:
- shard-iclb: PASS -> FAIL [fdo#109247] +23

* igt@kms_lease@atomic_implicit_crtc:
- shard-kbl: NOTRUN -> FAIL [fdo#110279]
- shard-skl: NOTRUN -> FAIL [fdo#110279]

* igt@kms_plane_alpha_blend@pipe-a-alpha-7efc:
- shard-skl: NOTRUN -> FAIL [fdo#107815] / [fdo#108145] +2
- shard-kbl: NOTRUN -> FAIL [fdo#108145] / [fdo#108590]

* igt@kms_plane_alpha_blend@pipe-c-coverage-7efc:
- shard-skl: PASS -> FAIL [fdo#107815]

* igt@kms_plane_scaling@pipe-a-scaler-with-clipping-clamping:
- shard-glk: PASS -> SKIP [fdo#109271] / [fdo#109278] +1

* igt@kms_plane_scaling@pipe-b-scaler-with-clipping-clamping:
- shard-glk: NOTRUN -> SKIP [fdo#109271] / [fdo#109278] +2

* igt@kms_psr2_su@page_flip:
- shard-iclb: PASS -> SKIP [fdo#109642]

* igt@kms_psr@psr2_primary_mmap_cpu:
- shard-iclb: PASS -> SKIP [fdo#109441] +1

* igt@kms_psr@suspend:
- shard-iclb: PASS -> FAIL [fdo#107383] / [fdo#110215]

* igt@kms_rotation_crc@multiplane-rotation:
- shard-kbl: PASS -> DMESG-FAIL [fdo#105763]

* igt@kms_setmode@basic:

    - shard-apl:          PASS -> FAIL [fdo#99912]
    - shard-iclb:         NOTRUN -> FAIL [fdo#99912]
    - shard-kbl:          PASS -> FAIL [fdo#99912]

* igt@kms_vblank@pipe-a-ts-continuation-dpms-rpm:
- shard-snb: NOTRUN -> SKIP [fdo#109271] / [fdo#109278] +9

* igt@perf@blocking:
- shard-iclb: PASS -> FAIL [fdo#108587] +1

#### Possible fixes ####

* igt@gem_create@create-clear:
- shard-snb: INCOMPLETE [fdo#105411] -> PASS

* igt@gem_ppgtt@blt-vs-render-ctxn:
- shard-iclb: INCOMPLETE [fdo#109801] -> PASS

* igt@gem_tiled_swapping@non-threaded:
- shard-iclb: DMESG-WARN [fdo#108686] -> PASS

* igt@kms_cursor_legacy@2x-long-nonblocking-modeset-vs-cursor-atomic:
- shard-glk: FAIL [fdo#106509] / [fdo#107409] -> PASS

* igt@kms_flip_tiling@flip-to-x-tiled:
- shard-iclb: FAIL [fdo#108134] -> PASS

* igt@kms_frontbuffer_tracking@fbc-1p-offscren-pri-indfb-draw-mmap-gtt:
- shard-iclb: FAIL [fdo#103167] -> PASS +16

* igt@kms_frontbuffer_tracking@fbcpsr-1p-offscren-pri-indfb-draw-blt:
- shard-iclb: FAIL [fdo#109247] -> PASS +17

* igt@kms_frontbuffer_tracking@fbcpsr-rgb101010-draw-mmap-wc:
- shard-iclb: FAIL [fdo#105682] / [fdo#109247] -> PASS +1

* igt@kms_plane@pixel-format-pipe-c-planes-source-clamping:
- shard-glk: SKIP [fdo#109271] -> PASS

* igt@kms_plane_alpha_blend@pipe-b-constant-alpha-min:
- shard-skl: FAIL [fdo#108145] -> PASS

* igt@kms_plane_scaling@pipe-c-scaler-with-rotation:
- shard-glk: SKIP [fdo#109271] / [fdo#109278] -> PASS

* igt@kms_psr@no_drrs:
- shard-iclb: FAIL [fdo#108341] -> PASS

* igt@kms_psr@psr2_cursor_mmap_cpu:
- shard-iclb: SKIP [fdo#109441] -> PASS +1

* igt@kms_psr@sprite_blt:
- shard-iclb: FAIL [fdo#107383] / [fdo#110215] -> PASS +5

* igt@kms_setmode@basic:
- shard-skl: FAIL [fdo#99912] -> PASS

* igt@kms_vblank@pipe-a-ts-continuation-dpms-suspend:
- shard-kbl: INCOMPLETE [fdo#103665] -> PASS

* igt@kms_vblank@pipe-c-ts-continuation-suspend:
- shard-iclb: FAIL [fdo#104894] -> PASS

#### Warnings ####

* igt@i915_pm_rpm@modeset-non-lpsp:
- shard-skl: INCOMPLETE [fdo#107807] -> SKIP [fdo#109271]

[fdo#103167]: https://bugs.freedesktop.org/show_bug.cgi?id=103167
[fdo#103665]: https://bugs.freedesktop.org/show_bug.cgi?id=103665
[fdo#103833]: https://bugs.freedesktop.org/show_bug.cgi?id=103833
[fdo#104108]: https://bugs.freedesktop.org/show_bug.cgi?id=104108
[fdo#104894]: https://bugs.freedesktop.org/show_bug.cgi?id=104894
[fdo#105411]: https://bugs.freedesktop.org/show_bug.cgi?id=105411
[fdo#105682]: https://bugs.freedesktop.org/show_bug.cgi?id=105682
[fdo#105683]: https://bugs.freedesktop.org/show_bug.cgi?id=105683
[fdo#105763]: https://bugs.freedesktop.org/show_bug.cgi?id=105763
[fdo#106509]: https://bugs.freedesktop.org/show_bug.cgi?id=106509
[fdo#106641]: https://bugs.freedesktop.org/show_bug.cgi?id=106641
[fdo#107383]: https://bugs.freedesktop.org/show_bug.cgi?id=107383
[fdo#107409]: https://bugs.freedesktop.org/show_bug.cgi?id=107409
[fdo#107773]: https://bugs.freedesktop.org/show_bug.cgi?id=107773
[fdo#107807]: https://bugs.freedesktop.org/show_bug.cgi?id=107807
[fdo#107815]: https://bugs.freedesktop.org/show_bug.cgi?id=107815
[fdo#108134]: https://bugs.freedesktop.org/show_bug.cgi?id=108134
[fdo#108145]: https://bugs.freedesktop.org/show_bug.cgi?id=108145
[fdo#108341]: https://bugs.freedesktop.org/show_bug.cgi?id=108341
[fdo#108587]: https://bugs.freedesktop.org/show_bug.cgi?id=108587
[fdo#108590]: https://bugs.freedesktop.org/show_bug.cgi?id=108590
[fdo#108686]: https://bugs.freedesktop.org/show_bug.cgi?id=108686
[fdo#108954]: https://bugs.freedesktop.org/show_bug.cgi?id=108954
[fdo#109247]: https://bugs.freedesktop.org/show_bug.cgi?id=109247
[fdo#109271]: https://bugs.freedesktop.org/show_bug.cgi?id=109271
[fdo#109276]: https://bugs.freedesktop.org/show_bug.cgi?id=109276
[fdo#109277]: https://bugs.freedesktop.org/show_bug.cgi?id=109277
[fdo#109278]: https://bugs.freedesktop.org/show_bug.cgi?id=109278
[fdo#109280]: https://bugs.freedesktop.org/show_bug.cgi?id=109280
[fdo#109285]: https://bugs.freedesktop.org/show_bug.cgi?id=109285
[fdo#109288]: https://bugs.freedesktop.org/show_bug.cgi?id=109288
[fdo#109441]: https://bugs.freedesktop.org/show_bug.cgi?id=109441
[fdo#109638]: https://bugs.freedesktop.org/show_bug.cgi?id=109638
[fdo#109642]: https://bugs.freedesktop.org/show_bug.cgi?id=109642
[fdo#109801]: https://bugs.freedesktop.org/show_bug.cgi?id=109801
[fdo#110215]: https://bugs.freedesktop.org/show_bug.cgi?id=110215
[fdo#110222]: https://bugs.freedesktop.org/show_bug.cgi?id=110222
[fdo#110279]: https://bugs.freedesktop.org/show_bug.cgi?id=110279
[fdo#99912]: https://bugs.freedesktop.org/show_bug.cgi?id=99912

Participating hosts (10 -> 9)
------------------------------

Missing (1): shard-hsw

Build changes
-------------

* Linux: CI_DRM_5856 -> Patchwork_12658

CI_DRM_5856: 55074bd825098a71779cf65a69786547f0eccbe9 @ git://anongit.freedesktop.org/gfx-ci/linux
IGT_4922: e941e4a29438c7130554492e4daf52afbc99ffdf @ git://anongit.freedesktop.org/xorg/app/intel-gpu-tools
Patchwork_12658: d3a8d7507f421fbdd1157c1df0e3d3a484c56eff @ git://anongit.freedesktop.org/gfx-ci/linux
piglit_4509: fdc5a4ca11124ab8413c7988896eec4c97336694 @ git://anongit.freedesktop.org/piglit

== Logs ==

For more details see: https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_12658/
_______________________________________________
Intel-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/intel-gfx