Lines Matching refs:desc

59 	u8 ifnum = intf->cur_altsetting->desc.bInterfaceNumber;  in gud_usb_control_msg()
79 struct gud_display_descriptor_req *desc) in gud_get_display_descriptor() argument
84 buf = kmalloc(sizeof(*desc), GFP_KERNEL); in gud_get_display_descriptor()
88 ret = gud_usb_control_msg(intf, true, GUD_REQ_GET_DESCRIPTOR, 0, buf, sizeof(*desc)); in gud_get_display_descriptor()
89 memcpy(desc, buf, sizeof(*desc)); in gud_get_display_descriptor()
93 if (ret != sizeof(*desc)) in gud_get_display_descriptor()
96 if (desc->magic != le32_to_cpu(GUD_DISPLAY_MAGIC)) in gud_get_display_descriptor()
101 desc->version, le32_to_cpu(desc->flags), desc->compression, in gud_get_display_descriptor()
102 le32_to_cpu(desc->max_buffer_size)); in gud_get_display_descriptor()
104 if (!desc->version || !desc->max_width || !desc->max_height || in gud_get_display_descriptor()
105 le32_to_cpu(desc->min_width) > le32_to_cpu(desc->max_width) || in gud_get_display_descriptor()
106 le32_to_cpu(desc->min_height) > le32_to_cpu(desc->max_height)) in gud_get_display_descriptor()
381 .desc = "Generic USB Display",
431 struct gud_display_descriptor_req desc; in gud_probe() local
444 ret = gud_get_display_descriptor(intf, &desc); in gud_probe()
450 if (desc.version > 1) { in gud_probe()
451 dev_err(dev, "Protocol version %u is not supported\n", desc.version); in gud_probe()
465 gdrm->flags = le32_to_cpu(desc.flags); in gud_probe()
466 gdrm->compression = desc.compression & GUD_COMPRESSION_LZ4; in gud_probe()
480 drm->mode_config.min_width = le32_to_cpu(desc.min_width); in gud_probe()
481 drm->mode_config.max_width = le32_to_cpu(desc.max_width); in gud_probe()
482 drm->mode_config.min_height = le32_to_cpu(desc.min_height); in gud_probe()
483 drm->mode_config.max_height = le32_to_cpu(desc.max_height); in gud_probe()
561 if (desc.max_buffer_size) in gud_probe()
562 max_buffer_size = le32_to_cpu(desc.max_buffer_size); in gud_probe()