* [PATCH] drm: gem-cma: Fix warnings due to improper printk formats
@ 2014-03-04 18:10 Laurent Pinchart
2014-04-03 0:21 ` Laurent Pinchart
0 siblings, 1 reply; 4+ messages in thread
From: Laurent Pinchart @ 2014-03-04 18:10 UTC (permalink / raw)
To: dri-devel
Use the %pad printk specifier to print dma_addr_t variables. This fixes
warnings on platforms where dma_addr_t has a different size than int or
size_t.
Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
---
drivers/gpu/drm/drm_gem_cma_helper.c | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/drivers/gpu/drm/drm_gem_cma_helper.c b/drivers/gpu/drm/drm_gem_cma_helper.c
index 6b51bf9..c049e5b 100644
--- a/drivers/gpu/drm/drm_gem_cma_helper.c
+++ b/drivers/gpu/drm/drm_gem_cma_helper.c
@@ -292,9 +292,9 @@ void drm_gem_cma_describe(struct drm_gem_cma_object *cma_obj, struct seq_file *m
off = drm_vma_node_start(&obj->vma_node);
- seq_printf(m, "%2d (%2d) %08llx %08Zx %p %d",
+ seq_printf(m, "%2d (%2d) %08llx %pad %p %d",
obj->name, obj->refcount.refcount.counter,
- off, cma_obj->paddr, cma_obj->vaddr, obj->size);
+ off, &cma_obj->paddr, cma_obj->vaddr, obj->size);
seq_printf(m, "\n");
}
@@ -342,7 +342,7 @@ drm_gem_cma_prime_import_sg_table(struct drm_device *dev, size_t size,
cma_obj->paddr = sg_dma_address(sgt->sgl);
cma_obj->sgt = sgt;
- DRM_DEBUG_PRIME("dma_addr = 0x%x, size = %zu\n", cma_obj->paddr, size);
+ DRM_DEBUG_PRIME("dma_addr = %pad, size = %zu\n", &cma_obj->paddr, size);
return &cma_obj->base;
}
--
Regards,
Laurent Pinchart
^ permalink raw reply related [flat|nested] 4+ messages in thread
* Re: [PATCH] drm: gem-cma: Fix warnings due to improper printk formats
2014-03-04 18:10 [PATCH] drm: gem-cma: Fix warnings due to improper printk formats Laurent Pinchart
@ 2014-04-03 0:21 ` Laurent Pinchart
2014-04-03 22:01 ` Dave Airlie
0 siblings, 1 reply; 4+ messages in thread
From: Laurent Pinchart @ 2014-04-03 0:21 UTC (permalink / raw)
To: Dave Airlie; +Cc: dri-devel
Hi Dave,
Could you please take this patch in your tree ?
What's the expected process when sending patches to the mailing list by the
way ? Do you track them somehow, or always expect pull requests ?
On Tuesday 04 March 2014 19:10:17 Laurent Pinchart wrote:
> Use the %pad printk specifier to print dma_addr_t variables. This fixes
> warnings on platforms where dma_addr_t has a different size than int or
> size_t.
>
> Signed-off-by: Laurent Pinchart <laurent.pinchart+renesas@ideasonboard.com>
> ---
> drivers/gpu/drm/drm_gem_cma_helper.c | 6 +++---
> 1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/drm_gem_cma_helper.c
> b/drivers/gpu/drm/drm_gem_cma_helper.c index 6b51bf9..c049e5b 100644
> --- a/drivers/gpu/drm/drm_gem_cma_helper.c
> +++ b/drivers/gpu/drm/drm_gem_cma_helper.c
> @@ -292,9 +292,9 @@ void drm_gem_cma_describe(struct drm_gem_cma_object
> *cma_obj, struct seq_file *m
>
> off = drm_vma_node_start(&obj->vma_node);
>
> - seq_printf(m, "%2d (%2d) %08llx %08Zx %p %d",
> + seq_printf(m, "%2d (%2d) %08llx %pad %p %d",
> obj->name, obj->refcount.refcount.counter,
> - off, cma_obj->paddr, cma_obj->vaddr, obj->size);
> + off, &cma_obj->paddr, cma_obj->vaddr, obj->size);
>
> seq_printf(m, "\n");
> }
> @@ -342,7 +342,7 @@ drm_gem_cma_prime_import_sg_table(struct drm_device
> *dev, size_t size, cma_obj->paddr = sg_dma_address(sgt->sgl);
> cma_obj->sgt = sgt;
>
> - DRM_DEBUG_PRIME("dma_addr = 0x%x, size = %zu\n", cma_obj->paddr, size);
> + DRM_DEBUG_PRIME("dma_addr = %pad, size = %zu\n", &cma_obj->paddr, size);
>
> return &cma_obj->base;
> }
--
Regards,
Laurent Pinchart
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] drm: gem-cma: Fix warnings due to improper printk formats
2014-04-03 0:21 ` Laurent Pinchart
@ 2014-04-03 22:01 ` Dave Airlie
2014-04-03 22:13 ` Laurent Pinchart
0 siblings, 1 reply; 4+ messages in thread
From: Dave Airlie @ 2014-04-03 22:01 UTC (permalink / raw)
To: Laurent Pinchart; +Cc: dri-devel
On Thu, Apr 3, 2014 at 10:21 AM, Laurent Pinchart
<laurent.pinchart@ideasonboard.com> wrote:
> Hi Dave,
>
> Could you please take this patch in your tree ?
>
> What's the expected process when sending patches to the mailing list by the
> way ? Do you track them somehow, or always expect pull requests ?
I generally pick up things with reviewed tags if I can, other stuff I
pick up in cycles from patchwork, but since patchwork is mostly
unmaintained sometimes things fall through the cracks,
so pull reqs of reviewed patches generally always win, but for fixes
like this I don't mind pull reqs if they've hit the list and haven't
cause much discussion.
Dave.
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [PATCH] drm: gem-cma: Fix warnings due to improper printk formats
2014-04-03 22:01 ` Dave Airlie
@ 2014-04-03 22:13 ` Laurent Pinchart
0 siblings, 0 replies; 4+ messages in thread
From: Laurent Pinchart @ 2014-04-03 22:13 UTC (permalink / raw)
To: Dave Airlie; +Cc: dri-devel
Hi Dave,
On Friday 04 April 2014 08:01:15 Dave Airlie wrote:
> On Thu, Apr 3, 2014 at 10:21 AM, Laurent Pinchart wrote:
> > Hi Dave,
> >
> > Could you please take this patch in your tree ?
> >
> > What's the expected process when sending patches to the mailing list by
> > the way ? Do you track them somehow, or always expect pull requests ?
>
> I generally pick up things with reviewed tags if I can, other stuff I
> pick up in cycles from patchwork, but since patchwork is mostly
> unmaintained sometimes things fall through the cracks,
>
> so pull reqs of reviewed patches generally always win, but for fixes
> like this I don't mind pull reqs if they've hit the list and haven't
> cause much discussion.
Thank you for the clarification. I assume you'll take this one manually, I'll
send pull requests in the future.
--
Regards,
Laurent Pinchart
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2014-04-03 22:11 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2014-03-04 18:10 [PATCH] drm: gem-cma: Fix warnings due to improper printk formats Laurent Pinchart
2014-04-03 0:21 ` Laurent Pinchart
2014-04-03 22:01 ` Dave Airlie
2014-04-03 22:13 ` Laurent Pinchart
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.