return make_usb_string(kbuf, klen, str, slen);
}
-/* cp210x_has_setmfg
- * Returns 1 if the CP210X part includes firmware that allows setting the
- * USB MFG descriptor, else 0. As of this writing, no CP210X firmware allows
- * this. SiLabs has suggested this may change in future firmware versions or
- * parts.
- */
-static inline int cp210x_has_setmfg(void)
-{
- return 0;
-}
-
/*
* cp210x_ctlmsg
* A generic usb control message interface.
}
break;
- case CP210x_IOCTL_SETMFG:
- if (cp210x_has_setmfg()) {
- char usbstr[USBSTRLEN(CP210x_MAX_MFG_STRLEN)];
- size_t len = cp210x_usbstr_from_user(usbstr, arg,
- sizeof(usbstr));
- if (len && cp210x_setstr(port, 0x00, usbstr) == len)
- return 0;
- }
- return -EFAULT;
- break;
-
case CP210x_IOCTL_SETPRODUCT:
{
char usbstr[USBSTRLEN(CP210x_MAX_PRODUCT_STRLEN)];