qemu-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Qemu-devel] usb-ohci: td.cbp incorrectly updated near page end


From: Gerd Hoffmann
Subject: Re: [Qemu-devel] usb-ohci: td.cbp incorrectly updated near page end
Date: Fri, 06 Jan 2012 10:47:06 +0100
User-agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.24) Gecko/20111104 Red Hat/3.1.16-2.el6_1 Thunderbird/3.1.16

On 12/22/11 10:34, Andriy Gapon wrote:
> The current code that updates the cbp value after a transfer looks like this:
> td.cbp += ret;
> if ((td.cbp & 0xfff) + ret > 0xfff) {
>       <handle page overflow>
> because the 'ret' value is effectively added twice the check may fire too 
> early
> when the overflow hasn't happened yet.

Patch added to usb patch queue.

thanks,
  Gerd



reply via email to

[Prev in Thread] Current Thread [Next in Thread]