Lines Matching full:udi
71 struct usb_device_info udi; in copy_info_hidraw() local
76 memset(&udi, 0, sizeof(udi)); in copy_info_hidraw()
83 if (ioctl(fd, IOCTL_REQ(USB_GET_DEVICEINFO), &udi) == -1) { in copy_info_hidraw()
94 (di->manufacturer = strdup(udi.udi_vendor)) == NULL || in copy_info_hidraw()
95 (di->product = strdup(udi.udi_product)) == NULL) in copy_info_hidraw()
97 di->vendor_id = (int16_t)udi.udi_vendorNo; in copy_info_hidraw()
98 di->product_id = (int16_t)udi.udi_productNo; in copy_info_hidraw()
122 struct usb_device_info udi; in copy_info_uhid() local
125 memset(&udi, 0, sizeof(udi)); in copy_info_uhid()
130 if (ioctl(fd, IOCTL_REQ(USB_GET_DEVICEINFO), &udi) == -1) { in copy_info_uhid()
132 strlcpy(udi.udi_vendor, UHID_VENDOR, sizeof(udi.udi_vendor)); in copy_info_uhid()
133 strlcpy(udi.udi_product, "uhid(4)", sizeof(udi.udi_product)); in copy_info_uhid()
134 udi.udi_vendorNo = 0x0b5d; /* stolen from PCI_VENDOR_OPENBSD */ in copy_info_uhid()
138 (di->manufacturer = strdup(udi.udi_vendor)) == NULL || in copy_info_uhid()
139 (di->product = strdup(udi.udi_product)) == NULL) in copy_info_uhid()
141 di->vendor_id = (int16_t)udi.udi_vendorNo; in copy_info_uhid()
142 di->product_id = (int16_t)udi.udi_productNo; in copy_info_uhid()