diff options
author | Tom Rini <trini@konsulko.com> | 2017-09-27 09:39:48 -0400 |
---|---|---|
committer | Tom Rini <trini@konsulko.com> | 2017-09-27 09:39:48 -0400 |
commit | 6e9b109aa9bcdd094e77da9fb03de8b44da8eb9d (patch) | |
tree | 84c35261edc472d88660f6599d472b1fb347924e /include | |
parent | 9241265f29f3670e380a9859a343ddc14873c46f (diff) | |
parent | a939af0c748e2ea1eeb8cf47fa9771a95786de70 (diff) |
Merge git://git.denx.de/u-boot-usb
Diffstat (limited to 'include')
-rw-r--r-- | include/usb.h | 22 |
1 files changed, 21 insertions, 1 deletions
diff --git a/include/usb.h b/include/usb.h index fad04016a3..0ddc0822b4 100644 --- a/include/usb.h +++ b/include/usb.h @@ -766,6 +766,14 @@ struct dm_usb_ops { * representation of this hub can be updated (xHCI) */ int (*update_hub_device)(struct udevice *bus, struct usb_device *udev); + + /** + * get_max_xfer_size() - Get HCD's maximum transfer bytes + * + * The HCD may have limitation on the maximum bytes to be transferred + * in a USB transfer. USB class driver needs to be aware of this. + */ + int (*get_max_xfer_size)(struct udevice *bus, size_t *size); }; #define usb_get_ops(dev) ((struct dm_usb_ops *)(dev)->driver->ops) @@ -939,7 +947,7 @@ int usb_new_device(struct usb_device *dev); int usb_alloc_device(struct usb_device *dev); /** - * update_hub_device() - Update HCD's internal representation of hub + * usb_update_hub_device() - Update HCD's internal representation of hub * * After a hub descriptor is fetched, notify HCD so that its internal * representation of this hub can be updated. @@ -950,6 +958,18 @@ int usb_alloc_device(struct usb_device *dev); int usb_update_hub_device(struct usb_device *dev); /** + * usb_get_max_xfer_size() - Get HCD's maximum transfer bytes + * + * The HCD may have limitation on the maximum bytes to be transferred + * in a USB transfer. USB class driver needs to be aware of this. + * + * @dev: USB device + * @size: maximum transfer bytes + * @return 0 if OK, -ve on error + */ +int usb_get_max_xfer_size(struct usb_device *dev, size_t *size); + +/** * usb_emul_setup_device() - Set up a new USB device emulation * * This is normally called when a new emulation device is bound. It tells |