All of lore.kernel.org
 help / color / mirror / Atom feed
From: Keyur Patel <iamkeyur96@gmail.com>
To: unlisted-recipients:; (no To-header on input)
Cc: iamkeyur96@gmail.com, David Lin <dtwlin@gmail.com>,
	Johan Hovold <johan@kernel.org>, Alex Elder <elder@kernel.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	greybus-dev@lists.linaro.org, devel@driverdev.osuosl.org,
	linux-kernel@vger.kernel.org
Subject: [PATCH] staging: greybus: add logging statement when kfifo_alloc fails
Date: Wed, 10 Jul 2019 08:20:17 -0400	[thread overview]
Message-ID: <20190710122018.2250-1-iamkeyur96@gmail.com> (raw)

Added missing logging statement when kfifo_alloc fails, to improve
debugging.

Signed-off-by: Keyur Patel <iamkeyur96@gmail.com>
---
 drivers/staging/greybus/uart.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/greybus/uart.c b/drivers/staging/greybus/uart.c
index b3bffe91ae99..86a395ae177d 100644
--- a/drivers/staging/greybus/uart.c
+++ b/drivers/staging/greybus/uart.c
@@ -856,8 +856,10 @@ static int gb_uart_probe(struct gbphy_device *gbphy_dev,
 
 	retval = kfifo_alloc(&gb_tty->write_fifo, GB_UART_WRITE_FIFO_SIZE,
 			     GFP_KERNEL);
-	if (retval)
+	if (retval) {
+		pr_err("kfifo_alloc failed\n");
 		goto exit_buf_free;
+	}
 
 	gb_tty->credits = GB_UART_FIRMWARE_CREDITS;
 	init_completion(&gb_tty->credits_complete);
-- 
2.22.0


WARNING: multiple messages have this Message-ID (diff)
From: Keyur Patel <iamkeyur96@gmail.com>
Cc: devel@driverdev.osuosl.org, Alex Elder <elder@kernel.org>,
	Greg Kroah-Hartman <gregkh@linuxfoundation.org>,
	Johan Hovold <johan@kernel.org>, David Lin <dtwlin@gmail.com>,
	greybus-dev@lists.linaro.org, linux-kernel@vger.kernel.org,
	iamkeyur96@gmail.com
Subject: [PATCH] staging: greybus: add logging statement when kfifo_alloc fails
Date: Wed, 10 Jul 2019 08:20:17 -0400	[thread overview]
Message-ID: <20190710122018.2250-1-iamkeyur96@gmail.com> (raw)

Added missing logging statement when kfifo_alloc fails, to improve
debugging.

Signed-off-by: Keyur Patel <iamkeyur96@gmail.com>
---
 drivers/staging/greybus/uart.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

diff --git a/drivers/staging/greybus/uart.c b/drivers/staging/greybus/uart.c
index b3bffe91ae99..86a395ae177d 100644
--- a/drivers/staging/greybus/uart.c
+++ b/drivers/staging/greybus/uart.c
@@ -856,8 +856,10 @@ static int gb_uart_probe(struct gbphy_device *gbphy_dev,
 
 	retval = kfifo_alloc(&gb_tty->write_fifo, GB_UART_WRITE_FIFO_SIZE,
 			     GFP_KERNEL);
-	if (retval)
+	if (retval) {
+		pr_err("kfifo_alloc failed\n");
 		goto exit_buf_free;
+	}
 
 	gb_tty->credits = GB_UART_FIRMWARE_CREDITS;
 	init_completion(&gb_tty->credits_complete);
-- 
2.22.0

_______________________________________________
devel mailing list
devel@linuxdriverproject.org
http://driverdev.linuxdriverproject.org/mailman/listinfo/driverdev-devel

             reply	other threads:[~2019-07-10 16:20 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-07-10 12:20 Keyur Patel [this message]
2019-07-10 12:20 ` [PATCH] staging: greybus: add logging statement when kfifo_alloc fails Keyur Patel
2019-07-10 16:35 ` Greg Kroah-Hartman
2019-07-10 16:35   ` Greg Kroah-Hartman
2019-07-10 14:24   ` Keyur Patel
2019-07-10 14:24     ` Keyur Patel
2019-07-11  7:00     ` Greg Kroah-Hartman
2019-07-11  7:00       ` Greg Kroah-Hartman

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=20190710122018.2250-1-iamkeyur96@gmail.com \
    --to=iamkeyur96@gmail.com \
    --cc=devel@driverdev.osuosl.org \
    --cc=dtwlin@gmail.com \
    --cc=elder@kernel.org \
    --cc=gregkh@linuxfoundation.org \
    --cc=greybus-dev@lists.linaro.org \
    --cc=johan@kernel.org \
    --cc=linux-kernel@vger.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 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.