From: Andiry Xu Date: Mon, 5 Mar 2012 09:49:34 +0000 (+0800) Subject: xHCI: count free TRBs on transfer ring X-Git-Tag: v3.4-rc1~184^2~21^2~7 X-Git-Url: http://git.openpandora.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b008df60c6369ba0290fa7daa177375407a12e07;p=pandora-kernel.git xHCI: count free TRBs on transfer ring In the past, the room_on_ring() check was implemented by walking all over the ring, which is wasteful and complicated. Count the number of free TRBs instead. The free TRBs number should be updated when enqueue/dequeue pointer is updated, or upon the completion of a set dequeue pointer command. Signed-off-by: Andiry Xu Signed-off-by: Sarah Sharp Tested-by: Paul Zimmerman --- Reading git-diff-tree failed