diff options
author | Anthony Liguori <aliguori@us.ibm.com> | 2007-11-07 15:49:24 -0600 |
---|---|---|
committer | Rusty Russell <rusty@rustcorp.com.au> | 2007-11-12 13:59:09 +1100 |
commit | 1bc4953ed44454c7f53d0b609445d1534981ee75 (patch) | |
tree | 05f67206d6978261ad2569d3a0030f0299331191 /usr | |
parent | 4d125de3a5d130054df2285e542c1491d214d3e8 (diff) | |
download | kernel_samsung_tuna-1bc4953ed44454c7f53d0b609445d1534981ee75.zip kernel_samsung_tuna-1bc4953ed44454c7f53d0b609445d1534981ee75.tar.gz kernel_samsung_tuna-1bc4953ed44454c7f53d0b609445d1534981ee75.tar.bz2 |
virtio: Fix used_idx wrap-around
The more_used() function compares the vq->vring.used->idx with last_used_idx.
Since vq->vring.used->idx is a 16-bit integer, and last_used_idx is an
unsigned int, this results in unpredictable behavior when vq->vring.used->idx
wraps around.
This patch corrects this by changing last_used_idx to the correct type.
Signed-off-by: Anthony Liguori <aliguori@us.ibm.com>
Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Diffstat (limited to 'usr')
0 files changed, 0 insertions, 0 deletions