Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932216AbbFWL6f (ORCPT ); Tue, 23 Jun 2015 07:58:35 -0400 Received: from userp1040.oracle.com ([156.151.31.81]:50464 "EHLO userp1040.oracle.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752259AbbFWL60 convert rfc822-to-8bit (ORCPT ); Tue, 23 Jun 2015 07:58:26 -0400 User-Agent: K-9 Mail for Android In-Reply-To: <5589179F0200007800087E6E@mail.emea.novell.com> References: <558762C4.2000002@oracle.com> <1434981360-29794-1-git-send-email-konrad.wilk@oracle.com> <5589179F0200007800087E6E@mail.emea.novell.com> MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8BIT Subject: Re: [Xen-devel] [PATCH] drivers: xen-blkfront: only talk_to_blkback() when in XenbusStateInitialising From: Konrad Rzeszutek Wilk Date: Tue, 23 Jun 2015 07:57:43 -0400 To: Jan Beulich CC: david.vrabel@citrix.com, julien.grall@citrix.com, marcus.granado@citrix.com, Paul.Durrant@citrix.com, Rafal.Mielniczuk@citrix.com, roger.pau@citrix.com, xen-devel@lists.xenproject.org, justing@spectralogic.com, linux-kernel@vger.kernel.org Message-ID: <64AE53A3-12FC-44C0-8AAA-12E99DA3C5A3@oracle.com> X-Source-IP: aserv0021.oracle.com [141.146.126.233] Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1010 Lines: 29 On June 23, 2015 2:23:59 AM EDT, Jan Beulich wrote: >>>> On 22.06.15 at 15:56, wrote: >> --- a/drivers/block/xen-blkfront.c >> +++ b/drivers/block/xen-blkfront.c >> @@ -1951,6 +1951,8 @@ static void blkback_changed(struct >xenbus_device *dev, >> >> switch (backend_state) { >> case XenbusStateInitWait: >> + if (dev->state != XenbusStateInitialising) >> + break; > >If, as you say in a subsequent reply, all other drivers already have >such a check, wouldn't it make more sense to put this into xenbus' >backend_changed() or even xenbus_otherend_changed()? Good idea. Let me spin an cleanup patch for the race handling - but put this in the Jens branch as the merge window is happening right now. > >Jan -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/