Received: by 10.213.65.68 with SMTP id h4csp165307imn; Fri, 23 Mar 2018 01:45:19 -0700 (PDT) X-Google-Smtp-Source: AG47ELuoDhQmv+eqA4MI14pDn70SbJ65hgN2Fw4eucWNEkT/cDJ7WYYAFY91pzuIaeZHFWQP+ZdG X-Received: by 2002:a17:902:5845:: with SMTP id f5-v6mr29118623plj.164.1521794719938; Fri, 23 Mar 2018 01:45:19 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1521794719; cv=none; d=google.com; s=arc-20160816; b=QUoDxplhVU0BOr4WRcGqG+sbL9EWZLCg703A+Gja5FYGKPkphJqiQqYThvmb8FdlUO a5Hi+Ot06M5L9U6d6082ZSc3kdJ7iMAhoC5+JtTMNDKEi4epPf+4byF7cRAE6CX3wpv1 0CtYE5tyHF2ZwsCWdPZ/06ZEsOll03ck2XqdYjwdk47kKO4tehiOat615zH8eUVFArXF 9vq7RFnGrJDnB/jA+RJhiZbb5CsfTZueAzrKSO1RSgFyfIfQZ5dTIus8BcCVUy5K4IQr K5pE/zfUuFMYk92bvRehErByR4bM4viPL2PgKpucdp1GECfKghtvXnVPmLJ3DKITwBdy e/1Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:cc:to:subject:message-id:date :thread-index:mime-version:in-reply-to:references:from :dkim-signature:arc-authentication-results; bh=5yiQEV9+IRvnmrdbkaCPG8sSBgVoHpVAxSf4GJZ8mmg=; b=FXjxPHA4CO0XzY0Oz+ztvLTTNBTV6KeV9gq9WNyM/4d3OkoYMKg+G7N5yFvBpJKA9v HdzFt3peTTMWpyTD9ejU0eMTmRnw5sXrR9+t/8VpOTW5OW1qbl4gb/1pWoU96X/ByU+1 jVRykfvjW6Rs1t4TQMkdgT/fNa6XO4TzZUSYisaALc+2XuZ+jjj1knYMoM7vpQE6q5Uu R6f+LmTE3cgHuhWjyTl8qEmg878zZAipykOacOA3Zz0W0+Ypv7FbBgxWsmVM4o658Q31 SS9g5gXVhzIY5W/49cifoEfqZMW3+IzMuvkxj5dOKXur+tFzDetRG7hxdl01dNqoFWv8 PK5w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@broadcom.com header.s=google header.b=ED767KPP; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=broadcom.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id i64-v6si8138595pli.78.2018.03.23.01.45.05; Fri, 23 Mar 2018 01:45:19 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@broadcom.com header.s=google header.b=ED767KPP; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=QUARANTINE sp=QUARANTINE dis=NONE) header.from=broadcom.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751872AbeCWIoJ (ORCPT + 99 others); Fri, 23 Mar 2018 04:44:09 -0400 Received: from mail-oi0-f47.google.com ([209.85.218.47]:37974 "EHLO mail-oi0-f47.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751675AbeCWIoH (ORCPT ); Fri, 23 Mar 2018 04:44:07 -0400 Received: by mail-oi0-f47.google.com with SMTP id c3-v6so9688515oib.5 for ; Fri, 23 Mar 2018 01:44:07 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=broadcom.com; s=google; h=from:references:in-reply-to:mime-version:thread-index:date :message-id:subject:to:cc; bh=5yiQEV9+IRvnmrdbkaCPG8sSBgVoHpVAxSf4GJZ8mmg=; b=ED767KPPhTHWTUYX2xwkQRcQVMT2IXWDP73/rILottZIMsxFmHU9YJy+KW4gGTEFwb KYJIDy6MHl00XnbJNcrtayBHJUJBX+bYK9NhzmvWhA620J6xMWRrOTqaOtqtScScjhfE zH+HjzUjhsxqWwOuaiprqNKa9k813ma5zGz9U= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:references:in-reply-to:mime-version :thread-index:date:message-id:subject:to:cc; bh=5yiQEV9+IRvnmrdbkaCPG8sSBgVoHpVAxSf4GJZ8mmg=; b=iaXGvbKiLc5f5i3166Rtpfe4Pnn9n9BPQBmkAFPpIJnNvoftyrRupRHeJ5IcwXpGr5 Kr9PbajkaHuWqxZzJfLHYF7zcJB+zt4K8AAGqSh3kiUqUkUaobkTmEYgnMtBPYVzaS4u iImZ6Npdu/2ZsiQgv0f1oV+sXJF8XK7i1W/Da53NB6HogyZwLXl7m5sSbC+mM0K4KOwh 99RIXDrzjciGuaalqLYiTQDrkDZSmtKGuM5lSSP4O2V549KjbBL+3ibPjGVNaWEEJDVG EtVmqc5GGuKGCMh4PTqKdJDC6goLYzu/1TS0dfaVpnDD2j42tX5N8RyE6L+8jzw2wU+X eQAg== X-Gm-Message-State: AElRT7HsTTNh2guk2+BHI2lJkrY1q0KPT9/YYk3PqXoLHGF170EmmYP2 M3f99pgFGZ3IRxb0jnyc/hLr2rYV0lssaDA0ujVh7g== X-Received: by 10.202.96.9 with SMTP id u9mr15440392oib.326.1521794646851; Fri, 23 Mar 2018 01:44:06 -0700 (PDT) From: Srinath Mannam References: <744877924.5841545.1521630049567.JavaMail.zimbra@kalray.eu> <20180321115037.GA26083@ming.t460p> <464125757.5843583.1521634231341.JavaMail.zimbra@kalray.eu> <20180321154807.GD22254@ming.t460p> <20180321160238.GF12909@localhost.localdomain> <1220434088.5871933.1521648656789.JavaMail.zimbra@kalray.eu> <20180321215308.GH38649@bhelgaas-glaptop.roam.corp.google.com> <2116255963.5924726.1521790087788.JavaMail.zimbra@kalray.eu> In-Reply-To: <2116255963.5924726.1521790087788.JavaMail.zimbra@kalray.eu> MIME-Version: 1.0 X-Mailer: Microsoft Outlook 15.0 Thread-Index: AQKUEOnFU2UVDrc3r39WZEWgKrnm8AKa1mcNAbL50P0Csp/JAgJw335UAsJU8eUBaw44cAHD2XPLoeHPMTA= Date: Fri, 23 Mar 2018 14:14:05 +0530 Message-ID: <0b37cdbe43a350e46057efa197ba471a@mail.gmail.com> Subject: RE: [RFC PATCH] nvme: avoid race-conditions when enabling devices To: Marta Rybczynska , Bjorn Helgaas Cc: Keith Busch , Ming Lei , axboe@fb.com, hch@lst.de, sagi@grimberg.me, linux-nvme@lists.infradead.org, linux-kernel@vger.kernel.org, bhelgaas@google.com, linux-pci@vger.kernel.org, Pierre-Yves Kerbrat Content-Type: text/plain; charset="UTF-8" Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Marta, I could not get time to work on this. The present patch works for our platforms. so we continue with that. I will update new changes little later. If you have time, please try the same patch and let us know if any issue you see. Regards, Srinath. -----Original Message----- From: Marta Rybczynska [mailto:mrybczyn@kalray.eu] Sent: Friday, March 23, 2018 12:58 PM To: Bjorn Helgaas Cc: Keith Busch ; Ming Lei ; axboe@fb.com; hch@lst.de; sagi@grimberg.me; linux-nvme@lists.infradead.org; linux-kernel@vger.kernel.org; bhelgaas@google.com; linux-pci@vger.kernel.org; Pierre-Yves Kerbrat ; Srinath Mannam Subject: Re: [RFC PATCH] nvme: avoid race-conditions when enabling devices > On Wed, Mar 21, 2018 at 05:10:56PM +0100, Marta Rybczynska wrote: >> >> The problem may happen also with other device doing its probe and >> nvme running its workqueue (and we probably have seen it in practice >> too). We were thinking about a lock in the pci generic code too, >> that's why I've put the linux-pci@ list in copy. > > Yes, this is a generic problem in the PCI core. We've tried to fix it > in the past but haven't figured it out yet. > > See 40f11adc7cd9 ("PCI: Avoid race while enabling upstream bridges") > and 0f50a49e3008 ("Revert "PCI: Avoid race while enabling upstream > bridges""). > > It's not trivial, but if you figure out a good way to fix this, I'd be > thrilled. > Bjorn, Srinath, are you aware of anyone working on an updated fix for this one? Marta