From: SF Markus Elfring <elfring@users.sourceforge.net>
To: dri-devel@lists.freedesktop.org, linaro-mm-sig@lists.linaro.org,
linux-media@vger.kernel.org,
Gustavo Padovan <gustavo@padovan.org>,
Sumit Semwal <sumit.semwal@linaro.org>
Cc: LKML <linux-kernel@vger.kernel.org>, kernel-janitors@vger.kernel.org
Subject: [PATCH 1/4] dma-buf: Combine two function calls into one in dma_buf_debug_show()
Date: Mon, 8 May 2017 11:11:37 +0200 [thread overview]
Message-ID: <b8a85220-039a-e4bb-c74b-d76baab234e8@users.sourceforge.net> (raw)
In-Reply-To: <3d972fa2-787a-d1f2-ff86-5c05494e00d3@users.sourceforge.net>
From: Markus Elfring <elfring@users.sourceforge.net>
Date: Mon, 8 May 2017 10:32:44 +0200
A bit of data was put into a sequence by two separate function calls.
Print the same data by a single function call instead.
This issue was detected by using the Coccinelle software.
Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
---
drivers/dma-buf/dma-buf.c | 4 +---
1 file changed, 1 insertion(+), 3 deletions(-)
diff --git a/drivers/dma-buf/dma-buf.c b/drivers/dma-buf/dma-buf.c
index 512bdbc23bbb..53257c166f4d 100644
--- a/drivers/dma-buf/dma-buf.c
+++ b/drivers/dma-buf/dma-buf.c
@@ -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++;
}
--
2.12.2
next prev parent reply other threads:[~2017-05-08 9:11 UTC|newest]
Thread overview: 10+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-05-08 9:10 [PATCH 0/4] DMA-buf: Fine-tuning for four function implementations SF Markus Elfring
2017-05-08 9:11 ` SF Markus Elfring [this message]
2017-05-08 14:31 ` [PATCH 1/4] dma-buf: Combine two function calls into one in dma_buf_debug_show() Gustavo Padovan
2017-05-08 9:12 ` [PATCH 2/4] dma-buf: Improve a size determination in dma_buf_attach() SF Markus Elfring
2017-05-08 14:31 ` Gustavo Padovan
2017-05-08 9:13 ` [PATCH 3/4] dma-buf: Adjust a null pointer check " SF Markus Elfring
2017-05-08 14:32 ` Gustavo Padovan
2017-05-08 9:14 ` [PATCH 4/4] dma-buf: Use seq_putc() in two functions SF Markus Elfring
2017-05-08 14:33 ` Gustavo Padovan
2017-05-09 4:18 ` [PATCH 0/4] DMA-buf: Fine-tuning for four function implementations Sumit Semwal
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=b8a85220-039a-e4bb-c74b-d76baab234e8@users.sourceforge.net \
--to=elfring@users.sourceforge.net \
--cc=dri-devel@lists.freedesktop.org \
--cc=gustavo@padovan.org \
--cc=kernel-janitors@vger.kernel.org \
--cc=linaro-mm-sig@lists.linaro.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=sumit.semwal@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).