]> git.kernelconcepts.de Git - karo-tx-linux.git/blobdiff - drivers/dma-buf/dma-buf.c
Merge tag 'xfs-4.13-merge-5' of git://git.kernel.org/pub/scm/fs/xfs/xfs-linux
[karo-tx-linux.git] / drivers / dma-buf / dma-buf.c
index 512bdbc23bbb43b85e9da8badbe24bcd64a66872..4a038dcf53612c888cf55ec3668871964b8f8001 100644 (file)
@@ -558,8 +558,8 @@ struct dma_buf_attachment *dma_buf_attach(struct dma_buf *dmabuf,
        if (WARN_ON(!dmabuf || !dev))
                return ERR_PTR(-EINVAL);
 
-       attach = kzalloc(sizeof(struct dma_buf_attachment), GFP_KERNEL);
-       if (attach == NULL)
+       attach = kzalloc(sizeof(*attach), GFP_KERNEL);
+       if (!attach)
                return ERR_PTR(-ENOMEM);
 
        attach->dev = dev;
@@ -1122,9 +1122,7 @@ static int dma_buf_debug_show(struct seq_file *s, void *unused)
                attach_count = 0;
 
                list_for_each_entry(attach_obj, &buf_obj->attachments, node) {
-                       seq_puts(s, "\t");
-
-                       seq_printf(s, "%s\n", dev_name(attach_obj->dev));
+                       seq_printf(s, "\t%s\n", dev_name(attach_obj->dev));
                        attach_count++;
                }