From: "Ky Srinivasan" Subject: Re: [PATCH] concurrency control issues in netback Date: Mon, 05 Jun 2006 08:13:47 -0600 Message-ID: <44840400.E57C.0030.0@novell.com> References: <44833D240200003000016CD3@victor.provo.novell.com> <44834E360200003000016CDE@victor.provo.novell.com> <44836985.E57C.0030.0@novell.com> Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit Return-path: In-Reply-To: Content-Disposition: inline List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , Sender: xen-devel-bounces@lists.xensource.com Errors-To: xen-devel-bounces@lists.xensource.com To: Keir Fraser Cc: xen-devel@lists.xensource.com List-Id: xen-devel@lists.xenproject.org >>> On Mon, Jun 5, 2006 at 9:48 AM, in message , Keir Fraser wrote: > On 5 Jun 2006, at 04:18, Ky Srinivasan wrote: > >> I have been looking at the netback code (netback.c) and I think there >> may be a bug in the way concurrency is managed here. Specifically, the >> function that cleans up completed requests (net_tx_action_dealloc()) is >> executed only from within a tasklet and hence does not acquire any >> locks >> to manipulate global state that could potentially be modified from >> other >> cpus. The code seems to assume writes are ordered without explicitly >> forcing the ordering. The problematic global state is the index that >> keeps track of the last valid index to be dealloced (dealloc_prod). >> This >> could potentially be manipulated outside of the tasklet. > > That's a good catch! Does your patch fix the network problems that you > guys have been seeing? I am hoping it will fix the problem! The machines needed to reproduce the problem are in our Provo labs. We will get the tests going this morning. We will keep you posted. > > The patch needs cleaning up: at least to rename the lock, but actually > just explicitly forcing the ordering we need is probably better. I'll Agreed. > sort that out and check in a suitable fix. > > Thanks! > Keir > Regards, K. Y _______________________________________________ > Xen- devel mailing list > Xen- devel@lists.xensource.com > http://lists.xensource.com/xen- devel