summaryrefslogtreecommitdiff
path: root/include/linux/usb
diff options
context:
space:
mode:
authorChunfeng Yun <chunfeng.yun@mediatek.com>2021-03-08 10:52:05 +0800
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2021-03-10 09:37:17 +0100
commitfb95c7cf5600b7b74412f27dfb39a1e13fd8a90d (patch)
treea26adef0d2e1159293afa37941a1970bd206d2a5 /include/linux/usb
parent14295a150050acfc3a1260ee3d2114b0b824199f (diff)
usb: common: add function to get interval expressed in us unit
Add a new function to convert bInterval into the time expressed in 1us unit. Signed-off-by: Chunfeng Yun <chunfeng.yun@mediatek.com> Link: https://lore.kernel.org/r/25c8a09b055f716c1e5bf11fea72c3418f844482.1615170625.git.chunfeng.yun@mediatek.com Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/usb')
-rw-r--r--include/linux/usb/ch9.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/linux/usb/ch9.h b/include/linux/usb/ch9.h
index abdd310c77f0..74debc824645 100644
--- a/include/linux/usb/ch9.h
+++ b/include/linux/usb/ch9.h
@@ -90,6 +90,9 @@ extern enum usb_ssp_rate usb_get_maximum_ssp_rate(struct device *dev);
*/
extern const char *usb_state_string(enum usb_device_state state);
+unsigned int usb_decode_interval(const struct usb_endpoint_descriptor *epd,
+ enum usb_device_speed speed);
+
#ifdef CONFIG_TRACING
/**
* usb_decode_ctrl - Returns human readable representation of control request.