aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/usb/gadget/printer.c
diff options
context:
space:
mode:
Diffstat (limited to 'drivers/usb/gadget/printer.c')
-rw-r--r--drivers/usb/gadget/printer.c18
1 files changed, 9 insertions, 9 deletions
diff --git a/drivers/usb/gadget/printer.c b/drivers/usb/gadget/printer.c
index 5a3034fdfe47..29500154d00c 100644
--- a/drivers/usb/gadget/printer.c
+++ b/drivers/usb/gadget/printer.c
@@ -225,12 +225,12 @@ module_param(qlen, uint, S_IRUGO|S_IWUSR);
225static struct usb_device_descriptor device_desc = { 225static struct usb_device_descriptor device_desc = {
226 .bLength = sizeof device_desc, 226 .bLength = sizeof device_desc,
227 .bDescriptorType = USB_DT_DEVICE, 227 .bDescriptorType = USB_DT_DEVICE,
228 .bcdUSB = __constant_cpu_to_le16(0x0200), 228 .bcdUSB = cpu_to_le16(0x0200),
229 .bDeviceClass = USB_CLASS_PER_INTERFACE, 229 .bDeviceClass = USB_CLASS_PER_INTERFACE,
230 .bDeviceSubClass = 0, 230 .bDeviceSubClass = 0,
231 .bDeviceProtocol = 0, 231 .bDeviceProtocol = 0,
232 .idVendor = __constant_cpu_to_le16(PRINTER_VENDOR_NUM), 232 .idVendor = cpu_to_le16(PRINTER_VENDOR_NUM),
233 .idProduct = __constant_cpu_to_le16(PRINTER_PRODUCT_NUM), 233 .idProduct = cpu_to_le16(PRINTER_PRODUCT_NUM),
234 .iManufacturer = STRING_MANUFACTURER, 234 .iManufacturer = STRING_MANUFACTURER,
235 .iProduct = STRING_PRODUCT, 235 .iProduct = STRING_PRODUCT,
236 .iSerialNumber = STRING_SERIALNUM, 236 .iSerialNumber = STRING_SERIALNUM,
@@ -299,20 +299,20 @@ static struct usb_endpoint_descriptor hs_ep_in_desc = {
299 .bLength = USB_DT_ENDPOINT_SIZE, 299 .bLength = USB_DT_ENDPOINT_SIZE,
300 .bDescriptorType = USB_DT_ENDPOINT, 300 .bDescriptorType = USB_DT_ENDPOINT,
301 .bmAttributes = USB_ENDPOINT_XFER_BULK, 301 .bmAttributes = USB_ENDPOINT_XFER_BULK,
302 .wMaxPacketSize = __constant_cpu_to_le16(512) 302 .wMaxPacketSize = cpu_to_le16(512)
303}; 303};
304 304
305static struct usb_endpoint_descriptor hs_ep_out_desc = { 305static struct usb_endpoint_descriptor hs_ep_out_desc = {
306 .bLength = USB_DT_ENDPOINT_SIZE, 306 .bLength = USB_DT_ENDPOINT_SIZE,
307 .bDescriptorType = USB_DT_ENDPOINT, 307 .bDescriptorType = USB_DT_ENDPOINT,
308 .bmAttributes = USB_ENDPOINT_XFER_BULK, 308 .bmAttributes = USB_ENDPOINT_XFER_BULK,
309 .wMaxPacketSize = __constant_cpu_to_le16(512) 309 .wMaxPacketSize = cpu_to_le16(512)
310}; 310};
311 311
312static struct usb_qualifier_descriptor dev_qualifier = { 312static struct usb_qualifier_descriptor dev_qualifier = {
313 .bLength = sizeof dev_qualifier, 313 .bLength = sizeof dev_qualifier,
314 .bDescriptorType = USB_DT_DEVICE_QUALIFIER, 314 .bDescriptorType = USB_DT_DEVICE_QUALIFIER,
315 .bcdUSB = __constant_cpu_to_le16(0x0200), 315 .bcdUSB = cpu_to_le16(0x0200),
316 .bDeviceClass = USB_CLASS_PRINTER, 316 .bDeviceClass = USB_CLASS_PRINTER,
317 .bNumConfigurations = 1 317 .bNumConfigurations = 1
318}; 318};
@@ -1406,16 +1406,16 @@ printer_bind(struct usb_gadget *gadget)
1406 gadget->name); 1406 gadget->name);
1407 /* unrecognized, but safe unless bulk is REALLY quirky */ 1407 /* unrecognized, but safe unless bulk is REALLY quirky */
1408 device_desc.bcdDevice = 1408 device_desc.bcdDevice =
1409 __constant_cpu_to_le16(0xFFFF); 1409 cpu_to_le16(0xFFFF);
1410 } 1410 }
1411 snprintf(manufacturer, sizeof(manufacturer), "%s %s with %s", 1411 snprintf(manufacturer, sizeof(manufacturer), "%s %s with %s",
1412 init_utsname()->sysname, init_utsname()->release, 1412 init_utsname()->sysname, init_utsname()->release,
1413 gadget->name); 1413 gadget->name);
1414 1414
1415 device_desc.idVendor = 1415 device_desc.idVendor =
1416 __constant_cpu_to_le16(PRINTER_VENDOR_NUM); 1416 cpu_to_le16(PRINTER_VENDOR_NUM);
1417 device_desc.idProduct = 1417 device_desc.idProduct =
1418 __constant_cpu_to_le16(PRINTER_PRODUCT_NUM); 1418 cpu_to_le16(PRINTER_PRODUCT_NUM);
1419 1419
1420 /* support optional vendor/distro customization */ 1420 /* support optional vendor/distro customization */
1421 if (idVendor) { 1421 if (idVendor) {