IPC: Correct VirtQueue_getAvailBuf based on review
authorG Anthony <a0783926@ti.com>
Thu, 3 May 2012 20:30:12 +0000 (15:30 -0500)
committerSuman Anna <s-anna@ti.com>
Wed, 23 May 2012 05:22:53 +0000 (00:22 -0500)
commitf5ad67e3d2308f26cdf70fc0e417a0ad6d65b50f
tree76d2292a004c70e2a81feef0228db8e7c04798ef
parent35ce4f0c3387382bca34356358ed0760f4bd7348
IPC: Correct VirtQueue_getAvailBuf based on review

A review of VirtQueue revealed the index to the available ring
buffer was being calculated differently than lguest from which
it was modelled. It worked given the current usage model, but
to be more correct, it should be updated to match what Linux
side does.

This change was verified to work by asserting that head index
was the same in both cases under sample tests. A minor trace
change to display the ring.avail addr is also added.

Signed-off-by: G Anthony <a0783926@ti.com>
Signed-off-by: Juan Gutierrez <jgutierrez@ti.com>
Signed-off-by: Suman Anna <s-anna@ti.com>
src/ti/ipc/rpmsg/VirtQueue.c