aboutsummaryrefslogtreecommitdiff
path: root/drivers/usb/cdns3/cdns3-imx.c
diff options
context:
space:
mode:
authorMichael Grzeschik <[email protected]>2022-05-30 00:38:46 +0200
committerGreg Kroah-Hartman <[email protected]>2022-06-10 11:50:54 +0200
commit87d76b5f1d8eeb49efa16e2018e188864cbb9401 (patch)
tree4be9e56ba05d2f5f7d942fad83267ea3cb118c97 /drivers/usb/cdns3/cdns3-imx.c
parente84e3e99256e2aedab5f45f8e02bc98c891b9188 (diff)
usb: gadget: uvc: calculate the number of request depending on framesize
The current limitation of possible number of requests being handled is dependent on the gadget speed. It makes more sense to depend on the typical frame size when calculating the number of requests. This patch is changing this and is using the previous limits as boundaries for reasonable minimum and maximum number of requests. For a 1080p jpeg encoded video stream with a maximum imagesize of e.g. 800kB with a maxburst of 8 and an multiplier of 1 the resulting number of requests is calculated to 49. 800768 1 nreqs = ------ * -------------- ~= 49 2 (1024 * 8 * 1) Tested-by: Dan Vacura <[email protected]> Signed-off-by: Michael Grzeschik <[email protected]> Link: https://lore.kernel.org/r/[email protected] Signed-off-by: Greg Kroah-Hartman <[email protected]>
Diffstat (limited to 'drivers/usb/cdns3/cdns3-imx.c')
0 files changed, 0 insertions, 0 deletions