[PATCH 008/008] USB: serial: suppress log entry

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Subject: [PATCH 008/008] USB: serial: suppress log entry 
From: Elina Pasheva <epasheva@xxxxxxxxxxxxxxxxxx>

The following is summary of changes we have made to sierra.c driver in
[PATCH 008/008] from the series dealing with improving urb handling:
- Suppress an entry in logs by not re-submitting an urb when  usb_submit_urb()
returns -EPERM, as this shows that usb_kill_urb() is running
(as suggested by Oliver Neukum )
Signed-off-by: Elina Pasheva <epasheva@xxxxxxxxxxxxxxxxxx>
---

 drivers/usb/serial/sierra.c |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)
 
--- a/drivers/usb/serial/sierra.c	2009-05-04 19:02:22.000000000 -0700
+++ b/drivers/usb/serial/sierra.c	2009-05-05 10:46:20.000000000 -0700
@@ -514,7 +514,8 @@ static void sierra_indat_callback(struct
 	}
 
 	/* Resubmit urb so we continue receiving */
-	if (port->port.count && status != -ESHUTDOWN && status != -ENOENT) {
+	if (port->port.count && status != -ESHUTDOWN && status != -ENOENT &&
+			status != -EPERM) {
 		err = usb_submit_urb(urb, GFP_ATOMIC);
 		if (err)
 			dev_err(&port->dev, "resubmit read urb failed."
@@ -575,7 +576,8 @@ static void sierra_instat_callback(struc
 		dev_dbg(&port->dev, "%s: error %d\n", __func__, status);
 
 	/* Resubmit urb so we continue receiving IRQ data */
-	if (port->port.count && status != -ESHUTDOWN && status != -ENOENT) {
+	if (port->port.count && status != -ESHUTDOWN && status != -ENOENT &&
+			status != -EPERM) {
 		urb->dev = serial->dev;
 		err = usb_submit_urb(urb, GFP_ATOMIC);
 		if (err)



--
To unsubscribe from this list: send the line "unsubscribe linux-usb" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html

[Index of Archives]     [Linux Media]     [Linux Input]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]     [Old Linux USB Devel Archive]

  Powered by Linux