From: Keyur Patel <iamkeyur96@gmail.com> To: unlisted-recipients:; (no To-header on input) Cc: iamkeyur96@gmail.com, Greg Kroah-Hartman <gregkh@linuxfoundation.org>, Christian Gromm <christian.gromm@microchip.com>, Suresh Udipi <sudipi@jp.adit-jv.com>, Colin Ian King <colin.king@canonical.com>, devel@driverdev.osuosl.org, linux-kernel@vger.kernel.org Subject: [PATCH v3] staging: most: remove redundant print statement when kfifo_alloc fails Date: Thu, 11 Jul 2019 13:50:52 -0400 [thread overview] Message-ID: <20190711175055.25157-1-iamkeyur96@gmail.com> (raw) In-Reply-To: <20190711173915.24200-1-iamkeyur96@gmail.com> This print statement is redundant as kfifo_alloc just calls kmalloc_array and without the __GFP_NOWARN flag, already does a dump_stack(). Signed-off-by: Keyur Patel <iamkeyur96@gmail.com> Changes in v3: - fix checkpatch warrning --- drivers/staging/most/cdev/cdev.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/staging/most/cdev/cdev.c b/drivers/staging/most/cdev/cdev.c index d0cc0b746107..724d098aeef0 100644 --- a/drivers/staging/most/cdev/cdev.c +++ b/drivers/staging/most/cdev/cdev.c @@ -463,10 +463,8 @@ static int comp_probe(struct most_interface *iface, int channel_id, spin_lock_init(&c->unlink); INIT_KFIFO(c->fifo); retval = kfifo_alloc(&c->fifo, cfg->num_buffers, GFP_KERNEL); - if (retval) { - pr_info("failed to alloc channel kfifo"); + if (retval) goto err_del_cdev_and_free_channel; - } init_waitqueue_head(&c->wq); mutex_init(&c->io_mutex); spin_lock_irqsave(&ch_list_lock, cl_flags); -- 2.22.0
WARNING: multiple messages have this Message-ID (diff)
From: Keyur Patel <iamkeyur96@gmail.com> Cc: devel@driverdev.osuosl.org, Greg Kroah-Hartman <gregkh@linuxfoundation.org>, linux-kernel@vger.kernel.org, Suresh Udipi <sudipi@jp.adit-jv.com>, Christian Gromm <christian.gromm@microchip.com>, Colin Ian King <colin.king@canonical.com>, iamkeyur96@gmail.com Subject: [PATCH v3] staging: most: remove redundant print statement when kfifo_alloc fails Date: Thu, 11 Jul 2019 13:50:52 -0400 [thread overview] Message-ID: <20190711175055.25157-1-iamkeyur96@gmail.com> (raw) In-Reply-To: <20190711173915.24200-1-iamkeyur96@gmail.com> This print statement is redundant as kfifo_alloc just calls kmalloc_array and without the __GFP_NOWARN flag, already does a dump_stack(). Signed-off-by: Keyur Patel <iamkeyur96@gmail.com> Changes in v3: - fix checkpatch warrning --- drivers/staging/most/cdev/cdev.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) diff --git a/drivers/staging/most/cdev/cdev.c b/drivers/staging/most/cdev/cdev.c index d0cc0b746107..724d098aeef0 100644 --- a/drivers/staging/most/cdev/cdev.c +++ b/drivers/staging/most/cdev/cdev.c @@ -463,10 +463,8 @@ static int comp_probe(struct most_interface *iface, int channel_id, spin_lock_init(&c->unlink); INIT_KFIFO(c->fifo); retval = kfifo_alloc(&c->fifo, cfg->num_buffers, GFP_KERNEL); - if (retval) { - pr_info("failed to alloc channel kfifo"); + if (retval) goto err_del_cdev_and_free_channel; - } init_waitqueue_head(&c->wq); mutex_init(&c->io_mutex); spin_lock_irqsave(&ch_list_lock, cl_flags); -- 2.22.0 _______________________________________________ devel mailing list devel@linuxdriverproject.org http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel
next prev parent reply other threads:[~2019-07-11 17:51 UTC|newest] Thread overview: 42+ messages / expand[flat|nested] mbox.gz Atom feed top 2019-07-11 11:08 [PATCH 2/2] staging: most: remove redundant print statement when kfifo_alloc fails Keyur Patel 2019-07-11 11:08 ` Keyur Patel 2019-07-11 17:39 ` [PATCH v2] staging: most: remove redundant print statement when Keyur Patel 2019-07-11 17:39 ` Keyur Patel 2019-07-11 17:50 ` Keyur Patel [this message] 2019-07-11 17:50 ` [PATCH v3] staging: most: remove redundant print statement when kfifo_alloc fails Keyur Patel 2019-07-14 14:42 ` [v3] " Markus Elfring 2019-07-14 14:42 ` Markus Elfring 2019-07-14 14:42 ` Markus Elfring 2019-07-14 15:05 ` [PATCH v4] " Keyur Patel 2019-07-14 15:05 ` Keyur Patel 2019-07-14 15:23 ` [v4] " Markus Elfring 2019-07-14 15:23 ` Markus Elfring 2019-07-14 15:23 ` Markus Elfring 2019-07-14 15:45 ` Keyur Patel 2019-07-14 15:45 ` Keyur Patel 2019-07-14 15:45 ` Keyur Patel 2019-07-14 15:47 ` Keyur Patel 2019-07-14 15:47 ` Keyur Patel 2019-07-14 15:47 ` Keyur Patel 2019-07-14 16:20 ` Markus Elfring 2019-07-14 16:20 ` Markus Elfring 2019-07-14 16:20 ` Markus Elfring 2019-07-15 7:32 ` Greg Kroah-Hartman 2019-07-15 7:32 ` Greg Kroah-Hartman 2019-07-15 7:32 ` Greg Kroah-Hartman 2019-07-14 16:41 ` [PATCH v4] staging: most: Delete an error message for a failed memory allocation Keyur Patel 2019-07-14 16:41 ` Keyur Patel 2019-07-14 16:55 ` [v4] " Markus Elfring 2019-07-14 16:55 ` Markus Elfring 2019-07-14 16:55 ` Markus Elfring 2019-07-14 17:04 ` Keyur Patel 2019-07-14 17:04 ` Keyur Patel 2019-07-14 17:04 ` Keyur Patel 2019-07-14 17:12 ` Markus Elfring 2019-07-14 17:12 ` Markus Elfring 2019-07-14 17:12 ` Markus Elfring 2019-07-14 17:27 ` [PATCH v5] " Keyur Patel 2019-07-14 17:27 ` Keyur Patel 2019-07-14 17:38 ` [v5] " Markus Elfring 2019-07-14 17:38 ` Markus Elfring 2019-07-14 17:38 ` 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=20190711175055.25157-1-iamkeyur96@gmail.com \ --to=iamkeyur96@gmail.com \ --cc=christian.gromm@microchip.com \ --cc=colin.king@canonical.com \ --cc=devel@driverdev.osuosl.org \ --cc=gregkh@linuxfoundation.org \ --cc=linux-kernel@vger.kernel.org \ --cc=sudipi@jp.adit-jv.com \ /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: linkBe sure your reply has a Subject: header at the top and a blank line before the message body.
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.