Commit e0d795e4f36c ("usb: irda: cleanup on ir-usb module") added a USB IrDA header with common defines, but mistakingly switched to using the class-descriptor baud-rate bitmask values for the outbound header. This broke link-speed handling for rates above 9600 baud, but a device would also be able to operate at the default 9600 baud until a link-speed request was issued (e.g. using the TCGETS ioctl).
Showing the changes to include/linux (1 of 2 files). Show all
Unified · Split
| @@ -119,11 +119,22 @@ struct usb_irda_cs_descriptor { · 118 unmodified lines | |||
| 119 | * 6 - 115200 bps | 119 | * 6 - 115200 bps |
| 120 | * 7 - 576000 bps | 120 | * 7 - 576000 bps |
| 121 | * 8 - 1.152 Mbps | 121 | * 8 - 1.152 Mbps |
| 122 | * 9 - 5 mbps | 122 | * 9 - 4 Mbps |
| 123 | * 10..15 - Reserved | 123 | * 10..15 - Reserved |
| 124 | */ | 124 | */ |
| 125 | #define USB_IRDA_STATUS_LINK_SPEED 0x0f | 125 | #define USB_IRDA_STATUS_LINK_SPEED 0x0f |
| 126 | 126 | ||
| 127 | #define USB_IRDA_LS_NO_CHANGE 0 | ||
| 128 | #define USB_IRDA_LS_2400 1 | ||
| 129 | #define USB_IRDA_LS_9600 2 | ||
| 130 | #define USB_IRDA_LS_19200 3 | ||
| 131 | #define USB_IRDA_LS_38400 4 | ||
| 132 | #define USB_IRDA_LS_57600 5 | ||
| 133 | #define USB_IRDA_LS_115200 6 | ||
| 134 | #define USB_IRDA_LS_576000 7 | ||
| 135 | #define USB_IRDA_LS_1152000 8 | ||
| 136 | #define USB_IRDA_LS_4000000 9 | ||
| 137 | |||
| 127 | /* The following is a 4-bit value used only for | 138 | /* The following is a 4-bit value used only for |
| 128 | * outbound header: | 139 | * outbound header: |
| 129 | * | 140 | * |