Skip to content

Commit a90d84a

Browse files
committed
USB: ftdi_sio: fix max-packet-size warning
Promote max-packet-size-override message to warning level and use the port device for logging, while using actual endpoint numbers in the message itself. Signed-off-by: Johan Hovold <[email protected]>
1 parent af6f9e8 commit a90d84a

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

drivers/usb/serial/ftdi_sio.c

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1563,8 +1563,6 @@ static void ftdi_set_max_packet_size(struct usb_serial_port *port)
15631563
{
15641564
struct ftdi_private *priv = usb_get_serial_port_data(port);
15651565
struct usb_serial *serial = port->serial;
1566-
struct usb_device *udev = serial->dev;
1567-
15681566
struct usb_interface *interface = serial->interface;
15691567
struct usb_endpoint_descriptor *ep_desc;
15701568

@@ -1583,7 +1581,8 @@ static void ftdi_set_max_packet_size(struct usb_serial_port *port)
15831581
ep_desc = &interface->cur_altsetting->endpoint[i].desc;
15841582
if (ep_desc->wMaxPacketSize == 0) {
15851583
ep_desc->wMaxPacketSize = cpu_to_le16(0x40);
1586-
dev_info(&udev->dev, "Overriding wMaxPacketSize on endpoint %d\n", i);
1584+
dev_warn(&port->dev, "Overriding wMaxPacketSize on endpoint %d\n",
1585+
usb_endpoint_num(ep_desc));
15871586
}
15881587
}
15891588

0 commit comments

Comments
 (0)