]> rtime.felk.cvut.cz Git - sojka/nv-tegra/linux-3.10.git/commitdiff
video: tegra: nvmap: fix compiler warnings
authorJon Mayo <jmayo@nvidia.com>
Fri, 8 Nov 2013 20:37:24 +0000 (12:37 -0800)
committerJon Mayo <jmayo@nvidia.com>
Mon, 11 Nov 2013 22:42:11 +0000 (14:42 -0800)
Fix phys_addr_t/dma_addr_t related warnings by using new %pa printk format.

Change-Id: I52f6bfb9a97c30a172ad0bb26fb50bc9e1e01e1c
Signed-off-by: Jon Mayo <jmayo@nvidia.com>
Reviewed-on: http://git-master/r/328431
Reviewed-by: Automatic_Commit_Validation_User
GVS: Gerrit_Virtual_Submit
Reviewed-by: Hiroshi Doyu <hdoyu@nvidia.com>
Tested-by: Hiroshi Doyu <hdoyu@nvidia.com>
drivers/video/tegra/nvmap/nvmap_dev.c
drivers/video/tegra/nvmap/nvmap_dmabuf.c
drivers/video/tegra/nvmap/nvmap_heap.c

index a8d3b7ca8c06f144fd1de822de4645840d93b6e5..a730e21212953cd4e79e3a7e76ed92f1e19c321b 100644 (file)
@@ -1359,8 +1359,8 @@ static int nvmap_probe(struct platform_device *pdev)
                if (!co->size)
                        continue;
 
-               dev_info(&pdev->dev, "heap (%s) base (0x%x) size (%d)\n",
-                       co->name, node->base, node->size);
+               dev_info(&pdev->dev, "heap (%s) base (%pa) size (%d)\n",
+                       co->name, &node->base, node->size);
 
                node->carveout = nvmap_heap_create(dev->dev_user.this_device,
                                   co->name, node->base, node->size, node);
@@ -1390,7 +1390,7 @@ static int nvmap_probe(struct platform_device *pdev)
                                debugfs_create_file("allocations", S_IRUGO,
                                    heap_root, node, &debug_allocations_fops);
                                debugfs_create_x32("base", S_IRUGO,
-                                   heap_root, &node->base);
+                                   heap_root, (u32 *)&node->base);
                                debugfs_create_x32("size", S_IRUGO,
                                    heap_root, &node->size);
                        }
index a9b4789148ee3cdc8414065f3df65aed2d1f77ca..1c762c35d57c3cefb9a0e9ecf263f1401e1f9214 100644 (file)
@@ -741,6 +741,7 @@ static int __nvmap_dmabuf_stashes_show(struct seq_file *s, void *data)
        struct nvmap_handle *handle;
        struct nvmap_client *client;
        const char *name;
+       phys_addr_t addr;
 
        mutex_lock(&nvmap_stashed_maps_lock);
        list_for_each_entry(nvmap_sgt, &nvmap_stashed_maps, stash_entry) {
@@ -761,8 +762,9 @@ static int __nvmap_dmabuf_stashes_show(struct seq_file *s, void *data)
 
                seq_printf(s, "  device = %s\n",
                           dev_name(handle->attachment->dev));
-               seq_printf(s, "  IO addr = 0x%08x + 0x%x\n",
-                          sg_dma_address(nvmap_sgt->sgt->sgl), handle->size);
+               addr = sg_dma_address(nvmap_sgt->sgt->sgl);
+               seq_printf(s, "  IO addr = 0x%pa + 0x%x\n",
+                       &addr, handle->size);
 
                /* Cleanup. */
                nvmap_client_put(client);
index 4c2583470f9d49d7561582fb22ed5e3d0a9d6ede..0946823f2fc5e8fbc05fa3a967c1eee4f1f6a1b8 100644 (file)
@@ -235,8 +235,8 @@ static struct nvmap_heap_block *do_heap_alloc(struct nvmap_heap *heap,
                        __func__, dev_name(&heap->dev));
                goto fail_dma_alloc;
        }
-       pr_debug("dma_alloc_coherent base (0x%x) size (%d) heap (%s)\n",
-               dev_base, len, heap->name);
+       pr_debug("dma_alloc_coherent base (%pa) size (%d) heap (%s)\n",
+               &dev_base, len, heap->name);
 
        heap_block->block.base = dev_base;
        heap_block->orig_addr = dev_base;