]> git.karo-electronics.de Git - mv-sheeva.git/commit
[ALSA] usb-audio - avoid unnecessary double buffering
authorClemens Ladisch <clemens@ladisch.de>
Fri, 13 May 2005 05:50:28 +0000 (07:50 +0200)
committerJaroslav Kysela <perex@suse.cz>
Sun, 29 May 2005 08:08:53 +0000 (10:08 +0200)
commit29b16931f936fdbcd78995e66d0f5626f3afbda8
tree938e0d682b0977d093690481a842132fb5a22718
parent50cdbf1519a891bec4ce306c7bae397a0d8e7246
[ALSA] usb-audio - avoid unnecessary double buffering

USB generic driver
When a USB packet boundary falls exactly on a buffer boundary, hwptr
remains at the end of the buffer which causes an overflow in the next
iteration and triggers double buffering although the next packet would
actually be contiguous.

This patch ensures that hwptr is always smaller than buffer_size.

Signed-off-by: Clemens Ladisch <clemens@ladisch.de>
sound/usb/usbaudio.c