Received: by 2002:a25:f815:0:0:0:0:0 with SMTP id u21csp3196377ybd; Fri, 28 Jun 2019 04:36:26 -0700 (PDT) X-Google-Smtp-Source: APXvYqwvFosh/oRKIT/WmWYd/6LCeWdWMVmN9mIFi1qb0ZP+lYO7k1eyJQC5hGF8Cugs1vNHn4Xp X-Received: by 2002:a63:e156:: with SMTP id h22mr8751814pgk.370.1561721786377; Fri, 28 Jun 2019 04:36:26 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1561721786; cv=none; d=google.com; s=arc-20160816; b=my+PQihEjaibqukHaVJ1At0JrebZzAWHx04Vh2Tb8VcWVuQcJq1ssbcw7guOSFkFUA VVd4NJtIMvyN0xgptCGfaKNBr8Jm3CpXUIE9WQrN7XfBOy7S3lS7hdrhb2cj20PC6dbg HErqLpsdLlDFfQWw0Ug0oPBEYnAyUeQXJamBbiwvit4dJ99SedBB9g5kk4MnwGBVKsVg ewHWOHjd220tyCedvdgSElCsw0fJEszlrJ3LHpiOjD726ZFoa7h9/5nlY9QLRkWH8ewj uaGaeK1jBn32hgstc+gVGPjdRDIcpysNycAw9HPR1hfoEtUThDaZpVZSLYocND3d+iuw LOvQ== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=dhWfgAk3LeDbzbTkQVpt4qDNuHVHU82s+e2jj9w/KFQ=; b=tGuPnTd1HBKU6mUhf8fgcUHP5FzZfAuYycwnln2p2q3/bGNw47OiHEyAkELnoBkNnR Xc8EAMuX9WqJzeFB96XrjAlLGrG8d8j0xqPenoUckQ+EPG2GrUxZ/bwYvnPN/eBA8fei k1l8EiReqwAxDNvimzGkqBhiAaRB0Xqz2+pazHsArT9NFWmU6PjS13m+Diz/Mcsw0roo Kj+2gJZsr+Jbik0hp9mX8c1Q2/QyXS07OlDVomV6rsEmIyNO6Yn87WZh7vVXhZ8OWR0m LLCeMD237F0PFQ8RIzNKM0L9LLBN3X5njGh9I+C9JMI8UqNPYb63I2M0813zuBZ0vxOR 5/gA== ARC-Authentication-Results: i=1; mx.google.com; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id b20si1874688pls.24.2019.06.28.04.36.09; Fri, 28 Jun 2019 04:36:26 -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; 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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726674AbfF1LgF (ORCPT + 99 others); Fri, 28 Jun 2019 07:36:05 -0400 Received: from foss.arm.com ([217.140.110.172]:45856 "EHLO foss.arm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726514AbfF1LgF (ORCPT ); Fri, 28 Jun 2019 07:36:05 -0400 Received: from usa-sjc-imap-foss1.foss.arm.com (unknown [10.121.207.14]) by usa-sjc-mx-foss1.foss.arm.com (Postfix) with ESMTP id 036A728; Fri, 28 Jun 2019 04:36:04 -0700 (PDT) Received: from e121166-lin.cambridge.arm.com (unknown [10.1.196.255]) by usa-sjc-imap-foss1.foss.arm.com (Postfix) with ESMTPSA id F40DC3F718; Fri, 28 Jun 2019 04:36:01 -0700 (PDT) Date: Fri, 28 Jun 2019 12:35:55 +0100 From: Lorenzo Pieralisi To: "Z.q. Hou" Cc: "linux-pci@vger.kernel.org" , "linux-arm-kernel@lists.infradead.org" , "devicetree@vger.kernel.org" , "linux-kernel@vger.kernel.org" , "bhelgaas@google.com" , "robh+dt@kernel.org" , "mark.rutland@arm.com" , "l.subrahmanya@mobiveil.co.in" , "shawnguo@kernel.org" , Leo Li , "catalin.marinas@arm.com" , "will.deacon@arm.com" , Mingkai Hu , "M.h. Lian" , Xiaowei Bao Subject: Re: [PATCHv5 04/20] PCI: mobiveil: Remove the flag MSI_FLAG_MULTI_PCI_MSI Message-ID: <20190628113555.GA21829@e121166-lin.cambridge.arm.com> References: <20190412083635.33626-1-Zhiqiang.Hou@nxp.com> <20190412083635.33626-5-Zhiqiang.Hou@nxp.com> <20190611165935.GA22836@redmoon> <20190612130813.GA15747@redmoon> <20190617093337.GD18020@e121166-lin.cambridge.arm.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.9.4 (2018-02-28) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Mon, Jun 17, 2019 at 10:34:35AM +0000, Z.q. Hou wrote: [...] > > There is nothing obvious. Write what you are fixing in the commit log and I will > > apply the patch, I won't write the commit log for you. Anyone should be able > > to understand why a patch was needed by reading the commit log, it is as > > important as writing the code itself. > > With the flag MSI_FLAG_MULTI_PCI_MSI, when the Endpoint allocates > multiple MSI, it will trigger the "WARN_ON(nr_irqs != 1);" in > mobiveil_irq_msi_domain_alloc(), this is the issue this patch want to > fix. And that's wrong. Marc explained why this controller does not support Multi MSI and that's what should go in the commit log, triggering a WARN_ON is the least of the problems (and the WARN_ON can even be removed after this patch is applied), if it was used as a bandaid to prevent allocating Multi MSI it is even more broken. Lorenzo > Thanks, > Zhiqiang > > > > > Thanks, > > Lorenzo > > > > > Thanks, > > > Zhiqiang > > > > > > > > > > > Lorenzo > > > > > > > > > Subbu, did you test with Endpoint supporting multi MSI? > > > > > > > > > > Thanks, > > > > > Zhiqiang > > > > > > > > > > > > > > > > > Thanks, > > > > > > Lorenzo > > > > > > > > > > > > > Fixes: 1e913e58335f ("PCI: mobiveil: Add MSI support") > > > > > > > Signed-off-by: Hou Zhiqiang > > > > > > > Reviewed-by: Minghuan Lian > > > > > > > --- > > > > > > > V5: > > > > > > > - Corrected the subject. > > > > > > > > > > > > > > drivers/pci/controller/pcie-mobiveil.c | 2 +- > > > > > > > 1 file changed, 1 insertion(+), 1 deletion(-) > > > > > > > > > > > > > > diff --git a/drivers/pci/controller/pcie-mobiveil.c > > > > > > > b/drivers/pci/controller/pcie-mobiveil.c > > > > > > > index 563210e731d3..a0dd337c6214 100644 > > > > > > > --- a/drivers/pci/controller/pcie-mobiveil.c > > > > > > > +++ b/drivers/pci/controller/pcie-mobiveil.c > > > > > > > @@ -703,7 +703,7 @@ static struct irq_chip > > > > > > > mobiveil_msi_irq_chip = { > > > > > > > > > > > > > > static struct msi_domain_info mobiveil_msi_domain_info = { > > > > > > > .flags = (MSI_FLAG_USE_DEF_DOM_OPS | > > > > > > MSI_FLAG_USE_DEF_CHIP_OPS | > > > > > > > - MSI_FLAG_MULTI_PCI_MSI | MSI_FLAG_PCI_MSIX), > > > > > > > + MSI_FLAG_PCI_MSIX), > > > > > > > .chip = &mobiveil_msi_irq_chip, > > > > > > > }; > > > > > > > > > > > > > > -- > > > > > > > 2.17.1 > > > > > > >