From: SF Markus Elfring <elfring@users.sourceforge.net>
To: linux-media@vger.kernel.org, Andy Walls <awalls@md.metrocast.net>,
Mauro Carvalho Chehab <mchehab@kernel.org>
Cc: LKML <linux-kernel@vger.kernel.org>, kernel-janitors@vger.kernel.org
Subject: [PATCH 1/3] [media] cx18: Delete an error message for a failed memory allocation in cx18_probe()
Date: Sat, 2 Sep 2017 20:41:03 +0200 [thread overview]
Message-ID: <a47013ab-7738-b07b-5e01-1f3435d45a43@users.sourceforge.net> (raw)
In-Reply-To: <016d4c9c-1d8e-e277-5d7c-f433553cf0fa@users.sourceforge.net>
From: Markus Elfring <elfring@users.sourceforge.net>
Date: Sat, 2 Sep 2017 19:39:56 +0200
Omit an extra message for a memory allocation failure in this function.
This issue was detected by using the Coccinelle software.
Signed-off-by: Markus Elfring <elfring@users.sourceforge.net>
---
drivers/media/pci/cx18/cx18-driver.c | 6 ++----
1 file changed, 2 insertions(+), 4 deletions(-)
diff --git a/drivers/media/pci/cx18/cx18-driver.c b/drivers/media/pci/cx18/cx18-driver.c
index 8bce49cdad46..b267590e0877 100644
--- a/drivers/media/pci/cx18/cx18-driver.c
+++ b/drivers/media/pci/cx18/cx18-driver.c
@@ -913,8 +913,6 @@ static int cx18_probe(struct pci_dev *pci_dev,
- if (cx == NULL) {
- printk(KERN_ERR "cx18: cannot manage card %d, out of memory\n",
- i);
+ if (!cx)
return -ENOMEM;
- }
+
cx->pci_dev = pci_dev;
cx->instance = i;
--
2.14.1
next prev parent reply other threads:[~2017-09-02 18:41 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2017-09-02 18:40 [PATCH 0/3] [media] cx18: Adjustments for seven function implementations SF Markus Elfring
2017-09-02 18:41 ` SF Markus Elfring [this message]
2017-09-02 18:42 ` [PATCH 2/3] [media] cx18: Improve a size determination in cx18_probe() SF Markus Elfring
2017-09-02 18:43 ` [PATCH 3/3] [media] cx18: Adjust ten checks for null pointers SF Markus Elfring
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=a47013ab-7738-b07b-5e01-1f3435d45a43@users.sourceforge.net \
--to=elfring@users.sourceforge.net \
--cc=awalls@md.metrocast.net \
--cc=kernel-janitors@vger.kernel.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-media@vger.kernel.org \
--cc=mchehab@kernel.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
Powered by JetHome