Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux

cdc-acm: Add support of ATOL FPrint fiscal printers

ATOL FPrint fiscal printers require usb_clear_halt to be executed
to work properly. Add quirk to fix the issue.

Signed-off-by: Alexey Sokolov <sokolov@7pikes.com>
Cc: stable <stable@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>

authored by

Alexey Sokolov and committed by
Greg Kroah-Hartman
15bf722e 19915e62

+10
+9
drivers/usb/class/cdc-acm.c
··· 1467 1467 goto alloc_fail8; 1468 1468 } 1469 1469 1470 + if (quirks & CLEAR_HALT_CONDITIONS) { 1471 + usb_clear_halt(usb_dev, usb_rcvbulkpipe(usb_dev, epread->bEndpointAddress)); 1472 + usb_clear_halt(usb_dev, usb_sndbulkpipe(usb_dev, epwrite->bEndpointAddress)); 1473 + } 1474 + 1470 1475 return 0; 1471 1476 alloc_fail8: 1472 1477 if (acm->country_codes) { ··· 1749 1744 }, 1750 1745 { USB_DEVICE(0x1576, 0x03b1), /* Maretron USB100 */ 1751 1746 .driver_info = NO_UNION_NORMAL, /* reports zero length descriptor */ 1747 + }, 1748 + 1749 + { USB_DEVICE(0x2912, 0x0001), /* ATOL FPrint */ 1750 + .driver_info = CLEAR_HALT_CONDITIONS, 1752 1751 }, 1753 1752 1754 1753 /* Nokia S60 phones expose two ACM channels. The first is
+1
drivers/usb/class/cdc-acm.h
··· 133 133 #define NO_DATA_INTERFACE BIT(4) 134 134 #define IGNORE_DEVICE BIT(5) 135 135 #define QUIRK_CONTROL_LINE_STATE BIT(6) 136 + #define CLEAR_HALT_CONDITIONS BIT(7)