Skip to contentSkip to conversation

usbip: vhci_hcd: print correct info in default case

PATCH New Pei Zhang 1 participant 1 message Dec 6, 2017

Subsystems (2)
lore
Share & tools
lore

Pei Zhang

author
#0 lore raw

PATCH 1/1 usbip: vhci_hcd: print correct info in default case

In this switch-case logical, 2 cases will goes to default case. The default log should exclude the upper 2 cases.

---
 drivers/usb/usbip/vhci_hcd.c | 4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)
drivers/usb/usbip/vhci_hcd.c +3 -1
index 0585078..b0057ac 100644
@@ -406,7 +406,9 @@ static int vhci_hub_control(struct usb_hcd *hcd, u16 typeReq, u16 wValue,
 
 			/* FALLTHROUGH */
 		default:
-			usbip_dbg_vhci_rh(" SetPortFeature: default %d\n",
+			if (wValue != USB_PORT_FEAT_SUSPEND &&
+				wValue != USB_PORT_FEAT_RESET)
+				usbip_dbg_vhci_rh(" SetPortFeature: default %d\n",
 					  wValue);
 			dum->port_status[rhport] |= (1 << wValue);
 			break;
Signature · 1 line
2.7.4