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

Re: [Xen-devel] ring.h notification hold-off question


  • To: Daniel Stodden <stodden@xxxxxxxxxx>, Xen Developers <xen-devel@xxxxxxxxxxxxxxxxxxx>
  • From: Keir Fraser <Keir.Fraser@xxxxxxxxxxxx>
  • Date: Sat, 10 Nov 2007 09:40:19 +0000
  • Delivery-date: Sat, 10 Nov 2007 01:35:08 -0800
  • List-id: Xen developer discussion <xen-devel.lists.xensource.com>
  • Thread-index: AcgjfbS58znVko9wEdyTmQAWy6hiGQ==
  • Thread-topic: [Xen-devel] ring.h notification hold-off question

On 10/11/07 05:37, "Daniel Stodden" <stodden@xxxxxxxxxx> wrote:

> b) if __old were UINT_MAX, then the consumer side might/would
>    set req_event to 0 after catching up right? (req_cons(== req_prod)+1)
>    now assume __new  ==  __old + 2 then we had
> 
> req_event [0] < __new [1] < __old [INT_MAX]
> 
>    i.e.
> __new - req_event [1] > __new - __old [-1]
> 
>    i.e. _notify=false, which i believe skips a wanted notification.

No. req_event==0, new==1, old==UINT_MAX. Then new-req_event==1, new-old==2.
Hence a notification will be sent.

Case (c) you are also wrong because after the subtractions we cast to an
unsigned integer. Hence in the case old<new<req_event, new-req_event will be
a large +ve integer, not a small -ve one.

 -- Keir



_______________________________________________
Xen-devel mailing list
Xen-devel@xxxxxxxxxxxxxxxxxxx
http://lists.xensource.com/xen-devel


 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.